SC CODE: Function InitializePrivate(collection String, metadataFormat String, metadata String) Uint64
1 IF EXISTS("minter") == 1 THEN GOTO 11
2 STORE("minter", SIGNER())
3 STORE("type", "G45-NFT")
4 STORE("owner", "")
5 STORE("timestamp", BLOCK_TIMESTAMP())
6 SEND_ASSET_TO_ADDRESS(SIGNER(), 1, SCID())
7 STORE("collection", collection)
8 STORE("metadataFormat", metadataFormat)
9 STORE("metadata", metadata)
10 RETURN 0
11 RETURN 1
End Function
Function DisplayNFT() Uint64
1 IF ADDRESS_STRING(SIGNER()) == "" THEN GOTO 5
2 IF ASSETVALUE(SCID()) != 1 THEN GOTO 5
3 STORE("owner", ADDRESS_STRING(SIGNER()))
4 RETURN 0
5 RETURN 1
End Function
Function RetrieveNFT() Uint64
1 IF LOAD("owner") != ADDRESS_STRING(SIGNER()) THEN GOTO 5
2 SEND_ASSET_TO_ADDRESS(SIGNER(), 1, SCID())
3 STORE("owner", "")
4 RETURN 0
5 RETURN 1
End Function |
SC Arguments: [Name:SC_ACTION Type:uint64 Value:'1' Name:SC_CODE Type:string Value:'Function InitializePrivate(collection String, metadataFormat String, metadata String) Uint64
1 IF EXISTS("minter") == 1 THEN GOTO 11
2 STORE("minter", SIGNER())
3 STORE("type", "G45-NFT")
4 STORE("owner", "")
5 STORE("timestamp", BLOCK_TIMESTAMP())
6 SEND_ASSET_TO_ADDRESS(SIGNER(), 1, SCID())
7 STORE("collection", collection)
8 STORE("metadataFormat", metadataFormat)
9 STORE("metadata", metadata)
10 RETURN 0
11 RETURN 1
End Function
Function DisplayNFT() Uint64
1 IF ADDRESS_STRING(SIGNER()) == "" THEN GOTO 5
2 IF ASSETVALUE(SCID()) != 1 THEN GOTO 5
3 STORE("owner", ADDRESS_STRING(SIGNER()))
4 RETURN 0
5 RETURN 1
End Function
Function RetrieveNFT() Uint64
1 IF LOAD("owner") != ADDRESS_STRING(SIGNER()) THEN GOTO 5
2 SEND_ASSET_TO_ADDRESS(SIGNER(), 1, SCID())
3 STORE("owner", "")
4 RETURN 0
5 RETURN 1
End Function' Name:collection Type:string Value:'fbfac059ac10bce6a3e303f08cc8ae22c3697c09cd3b2e86ff26ad10a61e5bfc' Name:metadata Type:string Value:'{"attributes":{"Background":"Dark","Description":"The 1st release into the Nested Treasures Collection a vividly elegant nesting doll that exudes an air of mystery and sophistication. This doll is crafted in the style of highly detailed illustrations, with a unique look that blends the appearance of liquid metal and colorful woodcarvings. The doll is meticulously painted in a precision style, with a stunning combination of dark black and light aquamarine and turquoise hues that accentuate its beauty. The precision painting technique adds depth and dimension to the doll, making it a true work of art. Classic tattoo motifs adorn the doll, adding to its allure and mystery. With its unique blend of styles, this nesting doll is sure to captivate and impress all who behold its exquisite beauty. Introducing the exquisite Nested Treasures NFT collection, featuring a series of one - of -a - kind digital art pieces inspired by the timeless beauty of the traditional Matryoshka doll.Each NFT in this collection showcases a unique interpretation of the matryoshka design,with different themes and intricate patterns, that truly bring this universally beloved symbol to life.With only a limited number of pieces available, the Nested Treasures collection is a rare and highly sought - after addition to any digital art collection.Don 't miss your chance to own a piece of this stunning art in form of a truly unique NFT.","Mood":"Mysterious","Motifs":"Classic Tattoo","Painting Style":"Precision Painting","Pattern":"Floral","Primary Color":"Turquoise"},"id":1,"image":"ipfs://QmSwNdYenoetX12qLi8wGSmZcG8sGMavFoPmNtEXCbR7fp/nested-treasures-1.jpg","name":"Nested Treasures #1"}' Name:metadataFormat Type:string Value:'json'] |