You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: content/developer/blog/starcoin_merkle_nft.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -78,7 +78,7 @@ The logic of MerkleNFTDistributor is concise. It implements NFT registration and
78
78
- The register function calls the register of the NFT protocol to register the metadata of the NFT;
79
79
- The function mint_with_cap is the NFT required by mint users and the function also calls the NFT protocol. It is important to note that the user needs to pass MerkleTree-related parameters such as merkle_proof, and the verify of the MerkleProof module will be called for verification, and only the verification is passed,an mint is succeed;
80
80
81
-
The MerkleProof module and MerkleNFTDistributor module are the core implementations of MerkleNFT. The whole logic is very clear and concise. The design uses MerkleTree ingeniously to reduce the logic complexity. It is an interesting application scenario of the NFT protocol. Those who interested can view [the complete source code](https://github.com/starcoinorg/starcoin/blob/master/vm/stdlib/sources/MerkleNFT.move).
81
+
The MerkleProof module and MerkleNFTDistributor module are the core implementations of MerkleNFT. The whole logic is very clear and concise. The design uses MerkleTree ingeniously to reduce the logic complexity. It is an interesting application scenario of the NFT protocol. Those who interested can view [the complete source code](https://github.com/starcoinorg/starcoin-framework/tree/main/sources/MerkleNFT.move).
Copy file name to clipboardExpand all lines: content/developer/blog/starcoin_nft_application.md
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -68,7 +68,7 @@ Here we don't discuss what kind of cards L1Card and L2Card represent, nor discus
68
68
- The function "init" calls the NFT::register_v2 function in the Starcoin standard NFT protocol to register the two types of NFTs, L1Card and L2Card.
69
69
- The mint_l1 function and mint_l2 function both call the NFT::mint_with_cap_v2 function in the Starcoin standard NFT protocol mint real NFT
70
70
71
-
The Starcoin standard NFT protocol design is very simple and efficient, and it can be used directly. In the example, the NFT card game only calls the two functions of the protocol, NFT::register_v2 and NFT::mint_with_cap_v2, which combines NFT with the game very easily. The entire contract is less than 100 lines of code. On the basis of ensuring the security of NFT, it implements the flexible combination of NFT. Those who interested can view [the complete code](https://github.com/starcoinorg/starcoin/blob/master/vm/transactional-tests/tests/testsuite/nft/nft_card.move).
71
+
The Starcoin standard NFT protocol design is very simple and efficient, and it can be used directly. In the example, the NFT card game only calls the two functions of the protocol, NFT::register_v2 and NFT::mint_with_cap_v2, which combines NFT with the game very easily. The entire contract is less than 100 lines of code. On the basis of ensuring the security of NFT, it implements the flexible combination of NFT. Those who interested can view [the complete code](https://github.com/starcoinorg/starcoin-framework/blob/main/spectests/nft/nft_card.move).
72
72
73
73
74
74
@@ -105,7 +105,7 @@ Here we focus on the logic of NFT as a membership:
105
105
- The quit function calls IdentifierNFT::revoke to recover the member’s NFT credentials, and destroys the NFT through NFT::burn_with_cap
106
106
- do_membership_action calls IdentifierNFT::is_owns to determine the user's membership
107
107
108
-
The above is an example of using NFT as a member ID, which uses both the standard NFT protocol of Starcoin and the IdentifierNFT module. Although there are only about 100 lines of code, from initializing the NFT to casting, using and destroying the NFT, it covers the entire NFT's life cycle. The contract logic is simple and clear. More importantly, it guarantees the security of NFT and Token. If you are interested, you can view [the complete contract code](https://github.com/starcoinorg/starcoin/blob/master/vm/transactional-tests/tests/testsuite/nft/identifier_nft.move).
108
+
The above is an example of using NFT as a member ID, which uses both the standard NFT protocol of Starcoin and the IdentifierNFT module. Although there are only about 100 lines of code, from initializing the NFT to casting, using and destroying the NFT, it covers the entire NFT's life cycle. The contract logic is simple and clear. More importantly, it guarantees the security of NFT and Token. If you are interested, you can view [the complete contract code](https://github.com/starcoinorg/starcoin-framework/blob/main/spectests/nft/identifier_nft.move).
@@ -134,7 +134,7 @@ The above code segement is the main logic of the BoxMiner module:
134
134
- The init function is the initialization function, calling NFT::register_v2 to register the NFT type of BoxMiner
135
135
- The mint function is used for users to purchase NFT, call NFT::mint_with_cap_v2 to cast NFT
136
136
137
-
The entire contract is about 50 lines, which not only implements the complete business logic, but also guarantees the safety and reliability of the NFT. If you are interested, you can view [the complete contract code](https://github.com/starcoinorg/starcoin/blob/master/vm/transactional-tests/tests/testsuite/nft/nft_boxminer.move).
137
+
The entire contract is about 50 lines, which not only implements the complete business logic, but also guarantees the safety and reliability of the NFT. If you are interested, you can view [the complete contract code](https://github.com/starcoinorg/starcoin-framework/blob/main/spectests/nft/nft_boxminer.move).
Copy file name to clipboardExpand all lines: content/developer/blog/starcoin_stdlib_config.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -113,7 +113,7 @@ RewardConfig is stored under GENESIS_ADDRESS (Genesis Account is the genesis acc
113
113
114
114
## Summarize
115
115
116
-
Config is a global module, any account can be used to store and manage the configuration in its own address. In order to avoid the problem of large arrays, Config does not use arrays to implement it, which is safe and reliable. Some global configurations of Starcoin are saved under the Genesis Account account using the Config contract. Those interested can view [the complete code](https://github.com/starcoinorg/starcoin/blob/master/vm/stdlib/sources/Config.move).
116
+
Config is a global module, any account can be used to store and manage the configuration in its own address. In order to avoid the problem of large arrays, Config does not use arrays to implement it, which is safe and reliable. Some global configurations of Starcoin are saved under the Genesis Account account using the Config contract. Those interested can view [the complete code](https://github.com/starcoinorg/starcoin-framework/tree/main/sources/Config.move).
Copy file name to clipboardExpand all lines: content/developer/blog/starcoin_token_proto.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -120,7 +120,7 @@ TokenCode is the only way to distinguish between different Tokens. Same value o
120
120
121
121
The above function covers the whole Token life cycle: registration, minting, destruction, recharge, and withdrawal.
122
122
123
-
Starcoin's Token protocol takes advantage of Move, and has designed a secure Token type and TokenInfo type. By passing generic parameters, it is guaranteed that Token can be arbitrarily combined and the protocol can be expanded. Click to view [the complete code](https://github.com/starcoinorg/starcoin/blob/master/vm/stdlib/sources/Token.move).
123
+
Starcoin's Token protocol takes advantage of Move, and has designed a secure Token type and TokenInfo type. By passing generic parameters, it is guaranteed that Token can be arbitrarily combined and the protocol can be expanded. Click to view [the complete code](https://github.com/starcoinorg/starcoin-framework/tree/main/sources/Token.move).
0 commit comments