Open brossetti1 opened 2 years ago
@mjohnson518 do you have a preference on the type of 998 to implement - i imagine top down for now.
Yep, top down seems like the appropriate interface for us to look at
https://github.com/mattlockyer/composables-998
an implemented 998
ok, things we have to keep track of for these child contracts... 1)token id. 2) parent contract address.
mostly if we're assigning an nft to a parent nft that comes from a different contract we have to store that contract address somewhere.
all the queries of the childnft's need the contract address and the tokenid
998 works. trying to fix the mintChildNft function to actually mint a token to another token. but the mintParentNFT function works and you can just mint everything as a parent right now and then transfer it to whatever NFT you want to own it.
also there's a rootOwnerOf function that returns a bytes32 string that is 66 digits long where the last 44 are an eth address of the rootOwner. however I can't seem to get that root address out of the string to actually use as an address which would be very convinient.
998 165
Specification ERC721 ERC998ERC721 top-down, ERC998ERC20 top-down, and ERC998ERC721 bottom-up composable contracts must implement the ERC-721 interface.
ERC20 ERC998ERC20 bottom-up composable contracts must implement the ERC-20 interface.
ERC165 The ERC-165 standard must be applied to each ERC998 interface that is used.
An ERC998ERC721 top-down composable is an ERC721 token with additional functionality for owning other ERC721 tokens. An ERC998ERC20 top-down composable is an ERC721 token with additional functionality for owning ERC20 tokens. An ERC998ERC721 bottom-up composable is an ERC721 token with additional functionality for being owned by an ERC721 token. An ERC998ERC20 bottom-up composable is an ERC20 token with additional functionality for being owned by an ERC721 token.