Environment
Details
Code to reproduce
Hi guys i have a question of ERC1155:
when i create a simply smart contract like this:
pragma solidity ^0.6.0;
import "https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/contracts/token/ERC1155/ERC1155.sol";
contract Collections is ERC1155 {
address operator = msg.sender;
uint256 private constant collect1 = 0;
uint256 private constant collect2 = 1;
uint256 private constant collect3 = 2;
uint256[] listIds = [collect1,collect2,collect3];
constructor() public ERC1155('https://5ea012a211b078001679d41f.mockapi.io/tokens/{id}'){
}
function createToken(address account, uint256[] memory ids, uint256[] memory amounts, bytes memory data) public {
ids = listIds;
_mintBatch(account, ids, amounts, data);
}
function getIds() public view returns(uint256[] memory){
return listIds;
}
}
when i mint the token i send this token to another account unlike operator address, but i can’t see the balance of token of account on etherscan, why? (i just use ropsten)
2 question: how to decide the mint of non-fungible token or fungible token? how to do this in _mint function??