Skip to content
This repository has been archived by the owner on Sep 1, 2023. It is now read-only.

ERC2981 Royalty for Specific Token IDs #98

Open
radleypr opened this issue Feb 22, 2023 · 2 comments
Open

ERC2981 Royalty for Specific Token IDs #98

radleypr opened this issue Feb 22, 2023 · 2 comments

Comments

@radleypr
Copy link

Hi, we are trying to implement an ERC2981 standard NFT, where the royalty receiver is different for every token IDs. After testing on OpenSea, it seems that only the minter of the first NFT is set as the royalty receiver for all token IDs, which can be seen from the creator fee:

image

In the contract we implemented _setTokenRoyalty(tokenId, to, defaultRoyalty)

    function mintNFT(
        address to,
        string memory uri
    ) public onlyRole(DEFAULT_ADMIN_ROLE) returns (uint256) {
        require(!hasRole(DEFAULT_ADMIN_ROLE, to), "Admins cannot receive NFTs");
        uint256 tokenId = _tokenIdCounter.current();
        _tokenIdCounter.increment();
        _safeMint(to, tokenId);
        _setTokenURI(tokenId, uri);
        _setTokenRoyalty(tokenId, to, defaultRoyalty);
        return tokenId;
    }

Please advise if it is possible to have dynamic creator fee royalty, thank you.

@VanTan291
Copy link

I have the same problem here.

@Toomaie
Copy link

Toomaie commented Apr 14, 2023

OS does not support this part of the EIP-2981. You cannot define multiple receivers for different token ids.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants