@opcat-labs/cat-sdk 3.3.0 → 3.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/artifacts/.templates/cat20/minters/cat20OpenMinter.scrypt.map +1 -1
- package/artifacts/.templates/cat20/minters/cat20OpenMinter.scrypt.tpl +1 -0
- package/artifacts/cat20/cat20.json +35 -35
- package/artifacts/cat20/cat20.scrypt +18 -18
- package/artifacts/cat20/cat20Admin.json +35 -35
- package/artifacts/cat20/cat20Admin.scrypt +30 -30
- package/artifacts/cat20/cat20GuardStateLib.json +22 -22
- package/artifacts/cat20/cat20GuardStateLib.scrypt +5 -5
- package/artifacts/cat20/cat20Guard_12_12_2.json +34 -34
- package/artifacts/cat20/cat20Guard_12_12_2.scrypt +29 -29
- package/artifacts/cat20/cat20Guard_12_12_4.json +34 -34
- package/artifacts/cat20/cat20Guard_12_12_4.scrypt +29 -29
- package/artifacts/cat20/cat20Guard_6_6_2.json +34 -34
- package/artifacts/cat20/cat20Guard_6_6_2.scrypt +29 -29
- package/artifacts/cat20/cat20Guard_6_6_4.json +34 -34
- package/artifacts/cat20/cat20Guard_6_6_4.scrypt +29 -29
- package/artifacts/cat20/cat20StateLib.json +23 -23
- package/artifacts/cat20/cat20StateLib.scrypt +5 -5
- package/artifacts/cat20/minters/cat20ClosedMinter.json +33 -33
- package/artifacts/cat20/minters/cat20ClosedMinter.scrypt +22 -22
- package/artifacts/cat20/minters/cat20OpenMinter.json +35 -35
- package/artifacts/cat20/minters/cat20OpenMinter.scrypt +19 -18
- package/artifacts/cat20/types.json +5 -5
- package/artifacts/cat20/types.scrypt +5 -5
- package/artifacts/cat721/cat721.json +35 -35
- package/artifacts/cat721/cat721.scrypt +18 -18
- package/artifacts/cat721/cat721GuardStateLib.json +22 -22
- package/artifacts/cat721/cat721GuardStateLib.scrypt +5 -5
- package/artifacts/cat721/cat721Guard_12_12_2.json +33 -33
- package/artifacts/cat721/cat721Guard_12_12_2.scrypt +26 -26
- package/artifacts/cat721/cat721Guard_12_12_4.json +33 -33
- package/artifacts/cat721/cat721Guard_12_12_4.scrypt +26 -26
- package/artifacts/cat721/cat721Guard_6_6_2.json +33 -33
- package/artifacts/cat721/cat721Guard_6_6_2.scrypt +26 -26
- package/artifacts/cat721/cat721Guard_6_6_4.json +33 -33
- package/artifacts/cat721/cat721Guard_6_6_4.scrypt +26 -26
- package/artifacts/cat721/cat721StateLib.json +23 -23
- package/artifacts/cat721/cat721StateLib.scrypt +5 -5
- package/artifacts/cat721/minters/cat721ClosedMinter.json +33 -33
- package/artifacts/cat721/minters/cat721ClosedMinter.scrypt +18 -18
- package/artifacts/cat721/minters/cat721OpenMintInfo.json +5 -5
- package/artifacts/cat721/minters/cat721OpenMintInfo.scrypt +4 -4
- package/artifacts/cat721/minters/cat721OpenMinter.json +38 -38
- package/artifacts/cat721/minters/cat721OpenMinter.scrypt +22 -22
- package/artifacts/cat721/minters/cat721OpenMinterMerkleTree.json +20 -20
- package/artifacts/cat721/minters/cat721OpenMinterMerkleTree.scrypt +6 -6
- package/artifacts/cat721/types.json +5 -5
- package/artifacts/cat721/types.scrypt +5 -5
- package/artifacts/constants.json +2 -2
- package/artifacts/constants.scrypt +1 -1
- package/artifacts/scrypt-ts-opcat/assets/smart-contract/builtin-libs/backtrace.scrypt +13 -13
- package/artifacts/scrypt-ts-opcat/assets/smart-contract/builtin-libs/contextUtils.scrypt +16 -16
- package/artifacts/scrypt-ts-opcat/assets/smart-contract/builtin-libs/stateUtils.scrypt +1 -1
- package/artifacts/scrypt-ts-opcat/assets/smart-contract/builtin-libs/stdUtils.scrypt +13 -13
- package/artifacts/scrypt-ts-opcat/assets/smart-contract/builtin-libs/txHashPreimageUtils.scrypt +7 -7
- package/artifacts/scrypt-ts-opcat/assets/smart-contract/builtin-libs/txUtils.scrypt +12 -12
- package/artifacts/scrypt-ts-opcat/assets/smart-contract/types/structs.scrypt +9 -9
- package/artifacts/types.json +2 -2
- package/artifacts/types.scrypt +2 -2
- package/artifacts/utils/ownerUtils.json +15 -15
- package/artifacts/utils/ownerUtils.scrypt +3 -3
- package/artifacts/utils/safeMath.json +15 -15
- package/artifacts/utils/safeMath.scrypt +1 -1
- package/dist/artifacts/cat20/cat20.json +35 -35
- package/dist/artifacts/cat20/cat20.scrypt +18 -18
- package/dist/artifacts/cat20/cat20Admin.json +35 -35
- package/dist/artifacts/cat20/cat20Admin.scrypt +30 -30
- package/dist/artifacts/cat20/cat20GuardStateLib.json +22 -22
- package/dist/artifacts/cat20/cat20GuardStateLib.scrypt +5 -5
- package/dist/artifacts/cat20/cat20Guard_12_12_2.json +34 -34
- package/dist/artifacts/cat20/cat20Guard_12_12_2.scrypt +29 -29
- package/dist/artifacts/cat20/cat20Guard_12_12_4.json +34 -34
- package/dist/artifacts/cat20/cat20Guard_12_12_4.scrypt +29 -29
- package/dist/artifacts/cat20/cat20Guard_6_6_2.json +34 -34
- package/dist/artifacts/cat20/cat20Guard_6_6_2.scrypt +29 -29
- package/dist/artifacts/cat20/cat20Guard_6_6_4.json +34 -34
- package/dist/artifacts/cat20/cat20Guard_6_6_4.scrypt +29 -29
- package/dist/artifacts/cat20/cat20StateLib.json +23 -23
- package/dist/artifacts/cat20/cat20StateLib.scrypt +5 -5
- package/dist/artifacts/cat20/minters/cat20ClosedMinter.json +33 -33
- package/dist/artifacts/cat20/minters/cat20ClosedMinter.scrypt +22 -22
- package/dist/artifacts/cat20/minters/cat20OpenMinter.json +35 -35
- package/dist/artifacts/cat20/minters/cat20OpenMinter.scrypt +19 -18
- package/dist/artifacts/cat20/types.json +5 -5
- package/dist/artifacts/cat20/types.scrypt +5 -5
- package/dist/artifacts/cat721/cat721.json +35 -35
- package/dist/artifacts/cat721/cat721.scrypt +18 -18
- package/dist/artifacts/cat721/cat721GuardStateLib.json +22 -22
- package/dist/artifacts/cat721/cat721GuardStateLib.scrypt +5 -5
- package/dist/artifacts/cat721/cat721Guard_12_12_2.json +33 -33
- package/dist/artifacts/cat721/cat721Guard_12_12_2.scrypt +26 -26
- package/dist/artifacts/cat721/cat721Guard_12_12_4.json +33 -33
- package/dist/artifacts/cat721/cat721Guard_12_12_4.scrypt +26 -26
- package/dist/artifacts/cat721/cat721Guard_6_6_2.json +33 -33
- package/dist/artifacts/cat721/cat721Guard_6_6_2.scrypt +26 -26
- package/dist/artifacts/cat721/cat721Guard_6_6_4.json +33 -33
- package/dist/artifacts/cat721/cat721Guard_6_6_4.scrypt +26 -26
- package/dist/artifacts/cat721/cat721StateLib.json +23 -23
- package/dist/artifacts/cat721/cat721StateLib.scrypt +5 -5
- package/dist/artifacts/cat721/minters/cat721ClosedMinter.json +33 -33
- package/dist/artifacts/cat721/minters/cat721ClosedMinter.scrypt +18 -18
- package/dist/artifacts/cat721/minters/cat721OpenMintInfo.json +5 -5
- package/dist/artifacts/cat721/minters/cat721OpenMintInfo.scrypt +4 -4
- package/dist/artifacts/cat721/minters/cat721OpenMinter.json +38 -38
- package/dist/artifacts/cat721/minters/cat721OpenMinter.scrypt +22 -22
- package/dist/artifacts/cat721/minters/cat721OpenMinterMerkleTree.json +20 -20
- package/dist/artifacts/cat721/minters/cat721OpenMinterMerkleTree.scrypt +6 -6
- package/dist/artifacts/cat721/types.json +5 -5
- package/dist/artifacts/cat721/types.scrypt +5 -5
- package/dist/artifacts/constants.json +2 -2
- package/dist/artifacts/constants.scrypt +1 -1
- package/dist/artifacts/scrypt-ts-opcat/assets/smart-contract/builtin-libs/backtrace.scrypt +13 -13
- package/dist/artifacts/scrypt-ts-opcat/assets/smart-contract/builtin-libs/contextUtils.scrypt +16 -16
- package/dist/artifacts/scrypt-ts-opcat/assets/smart-contract/builtin-libs/stateUtils.scrypt +1 -1
- package/dist/artifacts/scrypt-ts-opcat/assets/smart-contract/builtin-libs/stdUtils.scrypt +13 -13
- package/dist/artifacts/scrypt-ts-opcat/assets/smart-contract/builtin-libs/txHashPreimageUtils.scrypt +7 -7
- package/dist/artifacts/scrypt-ts-opcat/assets/smart-contract/builtin-libs/txUtils.scrypt +12 -12
- package/dist/artifacts/scrypt-ts-opcat/assets/smart-contract/types/structs.scrypt +9 -9
- package/dist/artifacts/types.json +2 -2
- package/dist/artifacts/types.scrypt +2 -2
- package/dist/artifacts/utils/ownerUtils.json +15 -15
- package/dist/artifacts/utils/ownerUtils.scrypt +3 -3
- package/dist/artifacts/utils/safeMath.json +15 -15
- package/dist/artifacts/utils/safeMath.scrypt +1 -1
- package/dist/cjs/contracts/cat20/minters/cat20OpenMinter.js +1 -0
- package/dist/cjs/contracts/cat20/minters/cat20OpenMinter.js.map +1 -1
- package/dist/cjs/utils/index.js +1 -1
- package/dist/cjs/utils/index.js.map +1 -1
- package/dist/esm/contracts/cat20/minters/cat20OpenMinter.js +1 -0
- package/dist/esm/contracts/cat20/minters/cat20OpenMinter.js.map +1 -1
- package/dist/esm/utils/index.js +1 -1
- package/dist/esm/utils/index.js.map +1 -1
- package/dist/types/contracts/cat20/minters/cat20OpenMinter.d.ts.map +1 -1
- package/package.json +4 -4
- package/scrypt.index.json +1 -1
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 10,
|
|
3
3
|
"compilerVersion": "1.22.0+commit.47800da",
|
|
4
|
-
"contract": "
|
|
4
|
+
"contract": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMinter",
|
|
5
5
|
"md5": "f8b9356972dbbd891da9f10d90e0ed32",
|
|
6
6
|
"structs": [
|
|
7
7
|
{
|
|
8
|
-
"name": "
|
|
8
|
+
"name": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMintInfoState",
|
|
9
9
|
"params": [
|
|
10
10
|
{
|
|
11
11
|
"name": "localId",
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
"genericTypes": []
|
|
20
20
|
},
|
|
21
21
|
{
|
|
22
|
-
"name": "
|
|
22
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__TxOut",
|
|
23
23
|
"params": [
|
|
24
24
|
{
|
|
25
25
|
"name": "scriptHash",
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
"genericTypes": []
|
|
38
38
|
},
|
|
39
39
|
{
|
|
40
|
-
"name": "
|
|
40
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__TxIn",
|
|
41
41
|
"params": [
|
|
42
42
|
{
|
|
43
43
|
"name": "prevTxHash",
|
|
@@ -59,7 +59,7 @@
|
|
|
59
59
|
"genericTypes": []
|
|
60
60
|
},
|
|
61
61
|
{
|
|
62
|
-
"name": "
|
|
62
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__TxHashPreimage",
|
|
63
63
|
"params": [
|
|
64
64
|
{
|
|
65
65
|
"name": "version",
|
|
@@ -81,11 +81,11 @@
|
|
|
81
81
|
"genericTypes": []
|
|
82
82
|
},
|
|
83
83
|
{
|
|
84
|
-
"name": "
|
|
84
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__BacktraceInfo",
|
|
85
85
|
"params": [
|
|
86
86
|
{
|
|
87
87
|
"name": "prevTxInput",
|
|
88
|
-
"type": "
|
|
88
|
+
"type": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__TxIn"
|
|
89
89
|
},
|
|
90
90
|
{
|
|
91
91
|
"name": "prevTxInputIndex",
|
|
@@ -93,13 +93,13 @@
|
|
|
93
93
|
},
|
|
94
94
|
{
|
|
95
95
|
"name": "prevPrevTxPreimage",
|
|
96
|
-
"type": "
|
|
96
|
+
"type": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__TxHashPreimage"
|
|
97
97
|
}
|
|
98
98
|
],
|
|
99
99
|
"genericTypes": []
|
|
100
100
|
},
|
|
101
101
|
{
|
|
102
|
-
"name": "
|
|
102
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__SHPreimage",
|
|
103
103
|
"params": [
|
|
104
104
|
{
|
|
105
105
|
"name": "nVersion",
|
|
@@ -161,7 +161,7 @@
|
|
|
161
161
|
"genericTypes": []
|
|
162
162
|
},
|
|
163
163
|
{
|
|
164
|
-
"name": "
|
|
164
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__Outpoint",
|
|
165
165
|
"params": [
|
|
166
166
|
{
|
|
167
167
|
"name": "txHash",
|
|
@@ -175,7 +175,7 @@
|
|
|
175
175
|
"genericTypes": []
|
|
176
176
|
},
|
|
177
177
|
{
|
|
178
|
-
"name": "
|
|
178
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__ChangeInfo",
|
|
179
179
|
"params": [
|
|
180
180
|
{
|
|
181
181
|
"name": "pubkeyhash",
|
|
@@ -193,7 +193,7 @@
|
|
|
193
193
|
"genericTypes": []
|
|
194
194
|
},
|
|
195
195
|
{
|
|
196
|
-
"name": "
|
|
196
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__ReadVarintResult",
|
|
197
197
|
"params": [
|
|
198
198
|
{
|
|
199
199
|
"name": "data",
|
|
@@ -207,7 +207,7 @@
|
|
|
207
207
|
"genericTypes": []
|
|
208
208
|
},
|
|
209
209
|
{
|
|
210
|
-
"name": "
|
|
210
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__ChainTxVerifyResponse",
|
|
211
211
|
"params": [
|
|
212
212
|
{
|
|
213
213
|
"name": "prevPrevScript",
|
|
@@ -221,7 +221,7 @@
|
|
|
221
221
|
"genericTypes": []
|
|
222
222
|
},
|
|
223
223
|
{
|
|
224
|
-
"name": "
|
|
224
|
+
"name": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721GuardConstState",
|
|
225
225
|
"params": [
|
|
226
226
|
{
|
|
227
227
|
"name": "deployerAddr",
|
|
@@ -243,7 +243,7 @@
|
|
|
243
243
|
"genericTypes": []
|
|
244
244
|
},
|
|
245
245
|
{
|
|
246
|
-
"name": "
|
|
246
|
+
"name": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721State",
|
|
247
247
|
"params": [
|
|
248
248
|
{
|
|
249
249
|
"name": "ownerAddr",
|
|
@@ -257,7 +257,7 @@
|
|
|
257
257
|
"genericTypes": []
|
|
258
258
|
},
|
|
259
259
|
{
|
|
260
|
-
"name": "
|
|
260
|
+
"name": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721ClosedMinterState",
|
|
261
261
|
"params": [
|
|
262
262
|
{
|
|
263
263
|
"name": "nftScriptHash",
|
|
@@ -275,7 +275,7 @@
|
|
|
275
275
|
"genericTypes": []
|
|
276
276
|
},
|
|
277
277
|
{
|
|
278
|
-
"name": "
|
|
278
|
+
"name": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721MerkleLeaf",
|
|
279
279
|
"params": [
|
|
280
280
|
{
|
|
281
281
|
"name": "contentDataHash",
|
|
@@ -293,7 +293,7 @@
|
|
|
293
293
|
"genericTypes": []
|
|
294
294
|
},
|
|
295
295
|
{
|
|
296
|
-
"name": "
|
|
296
|
+
"name": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMinterState",
|
|
297
297
|
"params": [
|
|
298
298
|
{
|
|
299
299
|
"name": "nftScriptHash",
|
|
@@ -313,63 +313,63 @@
|
|
|
313
313
|
],
|
|
314
314
|
"library": [
|
|
315
315
|
{
|
|
316
|
-
"name": "
|
|
316
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__TxHashPreimageUtils",
|
|
317
317
|
"params": [],
|
|
318
318
|
"properties": [],
|
|
319
319
|
"genericTypes": []
|
|
320
320
|
},
|
|
321
321
|
{
|
|
322
|
-
"name": "
|
|
322
|
+
"name": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMintInfo",
|
|
323
323
|
"params": [],
|
|
324
324
|
"properties": [],
|
|
325
325
|
"genericTypes": [],
|
|
326
|
-
"stateType": "
|
|
326
|
+
"stateType": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMintInfoState"
|
|
327
327
|
},
|
|
328
328
|
{
|
|
329
|
-
"name": "
|
|
329
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__TxUtils",
|
|
330
330
|
"params": [],
|
|
331
331
|
"properties": [],
|
|
332
332
|
"genericTypes": []
|
|
333
333
|
},
|
|
334
334
|
{
|
|
335
|
-
"name": "
|
|
335
|
+
"name": "_opcat_labs_cat_sdk_3_4_0__rs__OwnerUtils",
|
|
336
336
|
"params": [],
|
|
337
337
|
"properties": [],
|
|
338
338
|
"genericTypes": []
|
|
339
339
|
},
|
|
340
340
|
{
|
|
341
|
-
"name": "
|
|
341
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__ContextUtils",
|
|
342
342
|
"params": [],
|
|
343
343
|
"properties": [],
|
|
344
344
|
"genericTypes": []
|
|
345
345
|
},
|
|
346
346
|
{
|
|
347
|
-
"name": "
|
|
347
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__StdUtils",
|
|
348
348
|
"params": [],
|
|
349
349
|
"properties": [],
|
|
350
350
|
"genericTypes": []
|
|
351
351
|
},
|
|
352
352
|
{
|
|
353
|
-
"name": "
|
|
353
|
+
"name": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721StateLib",
|
|
354
354
|
"params": [],
|
|
355
355
|
"properties": [],
|
|
356
356
|
"genericTypes": [],
|
|
357
|
-
"stateType": "
|
|
357
|
+
"stateType": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721State"
|
|
358
358
|
},
|
|
359
359
|
{
|
|
360
|
-
"name": "
|
|
360
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__Backtrace",
|
|
361
361
|
"params": [],
|
|
362
362
|
"properties": [],
|
|
363
363
|
"genericTypes": []
|
|
364
364
|
},
|
|
365
365
|
{
|
|
366
|
-
"name": "
|
|
366
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__StateUtils",
|
|
367
367
|
"params": [],
|
|
368
368
|
"properties": [],
|
|
369
369
|
"genericTypes": []
|
|
370
370
|
},
|
|
371
371
|
{
|
|
372
|
-
"name": "
|
|
372
|
+
"name": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMinterMerkleTree",
|
|
373
373
|
"params": [],
|
|
374
374
|
"properties": [],
|
|
375
375
|
"genericTypes": []
|
|
@@ -384,11 +384,11 @@
|
|
|
384
384
|
"params": [
|
|
385
385
|
{
|
|
386
386
|
"name": "nftMint",
|
|
387
|
-
"type": "
|
|
387
|
+
"type": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721State"
|
|
388
388
|
},
|
|
389
389
|
{
|
|
390
390
|
"name": "openMintInfo",
|
|
391
|
-
"type": "
|
|
391
|
+
"type": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMintInfoState"
|
|
392
392
|
},
|
|
393
393
|
{
|
|
394
394
|
"name": "proof",
|
|
@@ -416,11 +416,11 @@
|
|
|
416
416
|
},
|
|
417
417
|
{
|
|
418
418
|
"name": "backtraceInfo",
|
|
419
|
-
"type": "
|
|
419
|
+
"type": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__BacktraceInfo"
|
|
420
420
|
},
|
|
421
421
|
{
|
|
422
422
|
"name": "__scrypt_ts_shPreimage",
|
|
423
|
-
"type": "
|
|
423
|
+
"type": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__SHPreimage"
|
|
424
424
|
},
|
|
425
425
|
{
|
|
426
426
|
"name": "__scrypt_ts_preimageSig",
|
|
@@ -428,11 +428,11 @@
|
|
|
428
428
|
},
|
|
429
429
|
{
|
|
430
430
|
"name": "__scrypt_ts_changeInfo",
|
|
431
|
-
"type": "
|
|
431
|
+
"type": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__ChangeInfo"
|
|
432
432
|
},
|
|
433
433
|
{
|
|
434
434
|
"name": "__scrypt_ts_curState",
|
|
435
|
-
"type": "
|
|
435
|
+
"type": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMinterState"
|
|
436
436
|
},
|
|
437
437
|
{
|
|
438
438
|
"name": "__scrypt_ts_prevouts",
|
|
@@ -452,7 +452,7 @@
|
|
|
452
452
|
},
|
|
453
453
|
{
|
|
454
454
|
"name": "__scrypt_ts_prevTxHashPreimage",
|
|
455
|
-
"type": "
|
|
455
|
+
"type": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__TxHashPreimage"
|
|
456
456
|
}
|
|
457
457
|
]
|
|
458
458
|
},
|
|
@@ -479,7 +479,7 @@
|
|
|
479
479
|
}
|
|
480
480
|
],
|
|
481
481
|
"stateProps": [],
|
|
482
|
-
"stateType": "
|
|
482
|
+
"stateType": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMinterState",
|
|
483
483
|
"buildType": "release",
|
|
484
484
|
"file": "../cat721OpenMinter.scrypt",
|
|
485
485
|
"hex": "0176018801a901ac2102ba79df5f8ae7604a9830f03c7933028186aede0675a16f025dc4f8be8eec038220836c4b45ab7a625549ca7c799b02d3304adf996557929ee809613e602d26c1f800000000<genesisOutpoint><max><premine><preminerAddr>5379587a75577a577a577a577a577a577a577a5279577a75567a567a567a567a567a567a78567a757171557a76557a75547a547a547a547a6d6d01187901197982778c7f75007f770127790127790127790127790127790127790127790127790127790127790127790127790127790127795d798277549d5c79827701209d5b79827701209d5a79827701209d597900a26958798277549d5779827701209d5679827701209d5579827701209d5479827701209d5379827701209d527900a2697800a26976519c6476529c6751686476539c67516864760281009c67516864760282009c67516864760283009c675168695d795d797e5c797e5b797e5a79767600a2637609ffffffffffffffff00a16700686976586e8b806e7c7f75007f6b6d6d6d6c7e59797e58797e57797e56797e55797e54797e5379546e8b806e7c7f75007f6b6d6d6c7e5279546e8b806e7c7f75007f6b6d6d6c7e7854807e6b6d6d6d6d6d6d6d6ca85779ba630118795679ac67006869607901217978aa7888785878827d77527997009d6e7c966b6d6d6c77011279012779011e7970aa5379886e9f69765479012478827d77527997009d6e7c967777779d537952798b0124957f7552790124957f7d7701207f75007f777801247f7501207f77768277549d767601007e817777726d726d7b7501117901237954795279aa527988765379012078827d77527997009d6e7c967777779d6d7501127901227954795279aa527988765379012078827d77527997009d6e7c967777779d6d75011779011779011779012179011b79011b79011b7952798277528053797e5279827752807e52797e78827752807e787e5379a95379a97e5279a97ea97ea87777770117797653798b0120957f7553790120957f775279886d75011379011379011379011379011b79012679557955795579557953798277549d5279014878827d77527997009d6e7c967777775279014878827d77527997009d6e7c96777777557952790000527902fd009f637551675279030000019f6301fd7b757c52776752790500000000019f6301fe7b757c54776701ff7b757c587768686878537952796e8b806e7c7f75007f6b6d6d6c7e7777777e55797e780000527902fd009f637551675279030000019f6301fd7b757c52776752790500000000019f6301fe7b757c54776701ff7b757c587768686878537952796e8b806e7c7f75007f6b6d6d6c7e7777777e54797e53797eaa6b6d6d6d6c76700124950120937f7553790124957f77886d6d6d75013579013579013579013579013579013579013579013579013579011279011e79012c798b0120957f75012c790120957f77011d795b795b795b795b795b795b795b795b795b7959797656798b0148957f7556790148957f775a795a795a795a795379827701209d76827701209d707600a2637605ffffffff00a16700686976546e8b806e7c7f75007f6b6d6d6c777e787e52797600a2637605ffffffff00a16700686976546e8b806e7c7f75007f6b6d6d6c777e6b6d6d6c88597976567956795679567953798277549d5279014878827d77527997009d6e7c967777775279014878827d77527997009d6e7c96777777557952790000527902fd009f637551675279030000019f6301fd7b757c52776752790500000000019f6301fe7b757c54776701ff7b757c587768686878537952796e8b806e7c7f75007f6b6d6d6c7e7777777e55797e780000527902fd009f637551675279030000019f6301fd7b757c52776752790500000000019f6301fe7b757c54776701ff7b757c587768686878537952796e8b806e7c7f75007f6b6d6d6c7e7777777e54797e53797eaa6b6d6d6d6c8853795a7901489558930120937f755a7901489558937f77785b797600a2637605ffffffff00a16700686976546e8b806e7c7f75007f6b6d6d6c777e787c726d726d726d726d726d726d7655798763780119798868765579876478547987675168696d6d6d6d6d6d6d51787759799f69012179009d011579516e8b0120957f75780120957f77777776015a7988011679526e8b0120957f75780120957f77777776015c79015c79788277528052797e78827752807e787e5279a95279a97ea97ea8777788015b79015d799d015a79015c79006f6f5279827701209d7800a2696d755178776351670100685379a95379a97e78a97e6b6d6d6ca9777777015b79015d79516f6f5279827701209d7800a2696d755178776351670100685379a95379a97e78a97e6b6d6d6ca9777777015b79015b79015b79015b79015b79015b79015b79015b79015b79015b79015b79015b79015b79015b79015b79015b79015b79015b79015b79015b79015b79015b79015b79015b79015b79015b79015b79015b79015b79015b790123790120790120790111766b796c7563780121766b796c757ea97b757c760121766b796c757ea977670120766b796c7552797ea97b757c0120766b796c75787ea9776860766b796c7563780120766b796c757ea97b757c760120766b796c757ea97767011f766b796c7552797ea97b757c011f766b796c75787ea977685f766b796c756378011f766b796c757ea97b757c76011f766b796c757ea97767011e766b796c7552797ea97b757c011e766b796c75787ea977685e766b796c756378011e766b796c757ea97b757c76011e766b796c757ea97767011d766b796c7552797ea97b757c011d766b796c75787ea977685d766b796c756378011d766b796c757ea97b757c76011d766b796c757ea97767011c766b796c7552797ea97b757c011c766b796c75787ea977685c766b796c756378011c766b796c757ea97b757c76011c766b796c757ea97767011b766b796c7552797ea97b757c011b766b796c75787ea977685b766b796c756378011b766b796c757ea97b757c76011b766b796c757ea97767011a766b796c7552797ea97b757c011a766b796c75787ea977685a766b796c756378011a766b796c757ea97b757c76011a766b796c757ea977670119766b796c7552797ea97b757c0119766b796c75787ea9776859766b796c7563780119766b796c757ea97b757c760119766b796c757ea977670118766b796c7552797ea97b757c0118766b796c75787ea9776858766b796c7563780118766b796c757ea97b757c760118766b796c757ea977670117766b796c7552797ea97b757c0117766b796c75787ea9776857766b796c7563780117766b796c757ea97b757c760117766b796c757ea977670116766b796c7552797ea97b757c0116766b796c75787ea9776856766b796c7563780116766b796c757ea97b757c760116766b796c757ea977670115766b796c7552797ea97b757c0115766b796c75787ea9776855766b796c7563780115766b796c757ea97b757c760115766b796c757ea977670114766b796c7552797ea97b757c0114766b796c75787ea9776854766b796c7563780114766b796c757ea97b757c760114766b796c757ea977670113766b796c7552797ea97b757c0113766b796c75787ea97768785379886b6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6c53798b00785e799f6376013079013e795a795679567952798277528053797e5279827752807e52797e78827752807e787e5379a95379a97e5279a97ea97ea8777777527982777882777801209d7601209d537900a2695379767600a2637609ffffffffffffffff00a16700686976586e8b806e7c7f75007f6b6d6d6d6c55797e53797e6b6d6d6c777e77680160790160797876827d7701199c647601209c675168696d51787700a2696d015f7956799d765879013d79016379016379788277528052797e78827752807e787e5279a95279a97ea97ea87777527982777882777801209d7601209d537900a2695379767600a2637609ffffffffffffffff00a16700686976586e8b806e7c7f75007f6b6d6d6d6c55797e53797e6b6d6d6c777e77015f795d799f63013e795c79787676827701219d750376a91478a97e0288ac7e7778886d013d79013f79ad687601227900a0630123790116790115797e01147e787e0116797e0114797e77a8012379012379527982777882777801209d7601209d537900a2695379767600a2637609ffffffffffffffff00a16700686976586e8b806e7c7f75007f6b6d6d6d6c55797e53797e6b6d6d6c776700687e7d77aa012879876b6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6d6c77"
|
|
@@ -13,7 +13,7 @@ import "../../scrypt-ts-opcat/assets/smart-contract/builtin-libs/stateUtils.scry
|
|
|
13
13
|
|
|
14
14
|
|
|
15
15
|
|
|
16
|
-
contract
|
|
16
|
+
contract _opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMinter {
|
|
17
17
|
bytes genesisOutpoint;
|
|
18
18
|
int max;
|
|
19
19
|
int premine;
|
|
@@ -24,52 +24,52 @@ contract _opcat_labs_cat_sdk_3_3_0__rs__CAT721OpenMinter {
|
|
|
24
24
|
this.premine = premine;
|
|
25
25
|
this.preminerAddr = preminerAddr;
|
|
26
26
|
}
|
|
27
|
-
public function mint(
|
|
28
|
-
require(checkDataSig(Sig(__scrypt_ts_preimageSig[0 : len(__scrypt_ts_preimageSig) - 1]), sha256(
|
|
27
|
+
public function mint(_opcat_labs_cat_sdk_3_4_0__rs__CAT721State nftMint, _opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMintInfoState openMintInfo, bytes[15] proof, bool[15] proofNodePos, PubKey preminerPubKey, Sig preminerSig, int minterSatoshis, int nftSatoshis, _opcat_labs_scrypt_ts_opcat_3_4_0__rs__BacktraceInfo backtraceInfo, _opcat_labs_scrypt_ts_opcat_3_4_0__rs__SHPreimage __scrypt_ts_shPreimage, Sig __scrypt_ts_preimageSig, _opcat_labs_scrypt_ts_opcat_3_4_0__rs__ChangeInfo __scrypt_ts_changeInfo, _opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMinterState __scrypt_ts_curState, bytes __scrypt_ts_prevouts, bytes __scrypt_ts_spentAmounts, bytes __scrypt_ts_spentDataHashes, bytes __scrypt_ts_spentScriptHashes, _opcat_labs_scrypt_ts_opcat_3_4_0__rs__TxHashPreimage __scrypt_ts_prevTxHashPreimage) {
|
|
28
|
+
require(checkDataSig(Sig(__scrypt_ts_preimageSig[0 : len(__scrypt_ts_preimageSig) - 1]), sha256(_opcat_labs_scrypt_ts_opcat_3_4_0__rs__ContextUtils.serializeSHPreimage(__scrypt_ts_shPreimage)), _opcat_labs_scrypt_ts_opcat_3_4_0__rs__ContextUtils.pubKey) && checkSig(__scrypt_ts_preimageSig, _opcat_labs_scrypt_ts_opcat_3_4_0__rs__ContextUtils.pubKey));
|
|
29
29
|
|
|
30
|
-
int __scrypt_ts_inputCount =
|
|
30
|
+
int __scrypt_ts_inputCount = _opcat_labs_scrypt_ts_opcat_3_4_0__rs__ContextUtils.checkSpentAmounts(__scrypt_ts_spentAmounts, __scrypt_ts_shPreimage.hashSpentAmounts);
|
|
31
31
|
|
|
32
|
-
|
|
32
|
+
_opcat_labs_scrypt_ts_opcat_3_4_0__rs__Outpoint __scrypt_ts_prevout = _opcat_labs_scrypt_ts_opcat_3_4_0__rs__ContextUtils.checkPrevouts(__scrypt_ts_prevouts, __scrypt_ts_shPreimage.hashPrevouts, __scrypt_ts_shPreimage.inputIndex, __scrypt_ts_inputCount);
|
|
33
33
|
|
|
34
|
-
|
|
34
|
+
_opcat_labs_scrypt_ts_opcat_3_4_0__rs__ContextUtils.checkSpentScripts(__scrypt_ts_spentScriptHashes, __scrypt_ts_shPreimage.hashSpentScriptHashes, __scrypt_ts_inputCount);
|
|
35
35
|
|
|
36
|
-
|
|
36
|
+
_opcat_labs_scrypt_ts_opcat_3_4_0__rs__ContextUtils.checkSpentDataHashes(__scrypt_ts_spentDataHashes, __scrypt_ts_shPreimage.hashSpentDataHashes, __scrypt_ts_inputCount);
|
|
37
37
|
|
|
38
|
-
|
|
38
|
+
_opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMinterState __scrypt_ts_nextState = __scrypt_ts_curState;
|
|
39
39
|
|
|
40
|
-
|
|
40
|
+
_opcat_labs_scrypt_ts_opcat_3_4_0__rs__StateUtils.checkInputState(__scrypt_ts_shPreimage.inputIndex, _opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMinter.stateHash(__scrypt_ts_curState), __scrypt_ts_spentDataHashes);
|
|
41
41
|
|
|
42
|
-
|
|
42
|
+
_opcat_labs_scrypt_ts_opcat_3_4_0__rs__Backtrace.checkPrevTxHashPreimage(__scrypt_ts_prevTxHashPreimage, __scrypt_ts_prevouts, __scrypt_ts_shPreimage.inputIndex);
|
|
43
43
|
|
|
44
|
-
|
|
44
|
+
_opcat_labs_scrypt_ts_opcat_3_4_0__rs__Backtrace.verifyFromOutpoint(backtraceInfo, this.genesisOutpoint, __scrypt_ts_spentScriptHashes[__scrypt_ts_shPreimage.inputIndex * 32 : (__scrypt_ts_shPreimage.inputIndex + 1) * 32], __scrypt_ts_prevTxHashPreimage.inputList);
|
|
45
45
|
require(__scrypt_ts_nextState.nextLocalId < this.max);
|
|
46
46
|
require(__scrypt_ts_shPreimage.inputIndex == 0);
|
|
47
|
-
bytes input1StateHash =
|
|
47
|
+
bytes input1StateHash = _opcat_labs_scrypt_ts_opcat_3_4_0__rs__ContextUtils.getSpentDataHash(__scrypt_ts_spentDataHashes, 1);
|
|
48
48
|
require(input1StateHash == openMintInfo.contentDataHash);
|
|
49
|
-
bytes input2StateHash =
|
|
50
|
-
require(input2StateHash ==
|
|
49
|
+
bytes input2StateHash = _opcat_labs_scrypt_ts_opcat_3_4_0__rs__ContextUtils.getSpentDataHash(__scrypt_ts_spentDataHashes, 2);
|
|
50
|
+
require(input2StateHash == _opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMintInfo.stateHash(openMintInfo));
|
|
51
51
|
require(openMintInfo.localId == nftMint.localId);
|
|
52
|
-
bytes merkleRoot =
|
|
52
|
+
bytes merkleRoot = _opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMinterMerkleTree.updateLeaf(_opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMinterMerkleTree.leafStateHash({openMintInfo.contentDataHash, openMintInfo.localId, false}), _opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMinterMerkleTree.leafStateHash({openMintInfo.contentDataHash, openMintInfo.localId, true}), proof, proofNodePos, __scrypt_ts_nextState.merkleRoot);
|
|
53
53
|
int nextLocalId = __scrypt_ts_nextState.nextLocalId + 1;
|
|
54
54
|
bytes outputs = b'';
|
|
55
55
|
if(nextLocalId < this.max) {
|
|
56
|
-
outputs +=
|
|
56
|
+
outputs += _opcat_labs_scrypt_ts_opcat_3_4_0__rs__TxUtils.buildDataOutput(__scrypt_ts_shPreimage.spentScriptHash, minterSatoshis, _opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMinter.stateHash({__scrypt_ts_nextState.nftScriptHash, merkleRoot, nextLocalId}));
|
|
57
57
|
}
|
|
58
|
-
|
|
58
|
+
_opcat_labs_cat_sdk_3_4_0__rs__CAT721StateLib.checkState(nftMint);
|
|
59
59
|
require(nftMint.localId == __scrypt_ts_nextState.nextLocalId);
|
|
60
|
-
outputs +=
|
|
60
|
+
outputs += _opcat_labs_scrypt_ts_opcat_3_4_0__rs__TxUtils.buildDataOutput(__scrypt_ts_nextState.nftScriptHash, nftSatoshis, _opcat_labs_cat_sdk_3_4_0__rs__CAT721StateLib.stateHash(nftMint));
|
|
61
61
|
if(nftMint.localId < this.premine) {
|
|
62
|
-
|
|
62
|
+
_opcat_labs_cat_sdk_3_4_0__rs__OwnerUtils.checkUserOwner(preminerPubKey, this.preminerAddr);
|
|
63
63
|
require(checkSig(preminerSig, preminerPubKey));
|
|
64
64
|
}
|
|
65
65
|
outputs +=
|
|
66
|
-
(__scrypt_ts_changeInfo.satoshis > 0 ?
|
|
66
|
+
(__scrypt_ts_changeInfo.satoshis > 0 ? _opcat_labs_scrypt_ts_opcat_3_4_0__rs__TxUtils.buildDataOutput(sha256(_opcat_labs_scrypt_ts_opcat_3_4_0__rs__TxUtils.buildP2PKHScript(__scrypt_ts_changeInfo.pubkeyhash)), __scrypt_ts_changeInfo.satoshis, __scrypt_ts_changeInfo.dataHash) : b'');
|
|
67
67
|
require(hash256(outputs) == __scrypt_ts_shPreimage.hashOutputs);
|
|
68
68
|
}
|
|
69
|
-
static function serializeState(
|
|
69
|
+
static function serializeState(_opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMinterState __scrypt_ts_curState): bytes {
|
|
70
70
|
return num2bin(len(__scrypt_ts_curState.nftScriptHash), 2) + __scrypt_ts_curState.nftScriptHash + num2bin(len(__scrypt_ts_curState.merkleRoot), 2) + __scrypt_ts_curState.merkleRoot + num2bin(len(pack(__scrypt_ts_curState.nextLocalId)), 2) + pack(__scrypt_ts_curState.nextLocalId) + hash160(hash160(__scrypt_ts_curState.nftScriptHash) + hash160(__scrypt_ts_curState.merkleRoot) + hash160(pack(__scrypt_ts_curState.nextLocalId)));
|
|
71
71
|
}
|
|
72
|
-
static function stateHash(
|
|
72
|
+
static function stateHash(_opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMinterState __scrypt_ts_curState): bytes {
|
|
73
73
|
return sha256(num2bin(len(__scrypt_ts_curState.nftScriptHash), 2) + __scrypt_ts_curState.nftScriptHash + num2bin(len(__scrypt_ts_curState.merkleRoot), 2) + __scrypt_ts_curState.merkleRoot + num2bin(len(pack(__scrypt_ts_curState.nextLocalId)), 2) + pack(__scrypt_ts_curState.nextLocalId) + hash160(hash160(__scrypt_ts_curState.nftScriptHash) + hash160(__scrypt_ts_curState.merkleRoot) + hash160(pack(__scrypt_ts_curState.nextLocalId))));
|
|
74
74
|
}
|
|
75
75
|
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 10,
|
|
3
3
|
"compilerVersion": "1.22.0+commit.47800da",
|
|
4
|
-
"contract": "
|
|
4
|
+
"contract": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMinterMerkleTree",
|
|
5
5
|
"md5": "d41d8cd98f00b204e9800998ecf8427e",
|
|
6
6
|
"structs": [
|
|
7
7
|
{
|
|
8
|
-
"name": "
|
|
8
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__TxOut",
|
|
9
9
|
"params": [
|
|
10
10
|
{
|
|
11
11
|
"name": "scriptHash",
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
"genericTypes": []
|
|
24
24
|
},
|
|
25
25
|
{
|
|
26
|
-
"name": "
|
|
26
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__TxIn",
|
|
27
27
|
"params": [
|
|
28
28
|
{
|
|
29
29
|
"name": "prevTxHash",
|
|
@@ -45,7 +45,7 @@
|
|
|
45
45
|
"genericTypes": []
|
|
46
46
|
},
|
|
47
47
|
{
|
|
48
|
-
"name": "
|
|
48
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__TxHashPreimage",
|
|
49
49
|
"params": [
|
|
50
50
|
{
|
|
51
51
|
"name": "version",
|
|
@@ -67,11 +67,11 @@
|
|
|
67
67
|
"genericTypes": []
|
|
68
68
|
},
|
|
69
69
|
{
|
|
70
|
-
"name": "
|
|
70
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__BacktraceInfo",
|
|
71
71
|
"params": [
|
|
72
72
|
{
|
|
73
73
|
"name": "prevTxInput",
|
|
74
|
-
"type": "
|
|
74
|
+
"type": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__TxIn"
|
|
75
75
|
},
|
|
76
76
|
{
|
|
77
77
|
"name": "prevTxInputIndex",
|
|
@@ -79,13 +79,13 @@
|
|
|
79
79
|
},
|
|
80
80
|
{
|
|
81
81
|
"name": "prevPrevTxPreimage",
|
|
82
|
-
"type": "
|
|
82
|
+
"type": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__TxHashPreimage"
|
|
83
83
|
}
|
|
84
84
|
],
|
|
85
85
|
"genericTypes": []
|
|
86
86
|
},
|
|
87
87
|
{
|
|
88
|
-
"name": "
|
|
88
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__SHPreimage",
|
|
89
89
|
"params": [
|
|
90
90
|
{
|
|
91
91
|
"name": "nVersion",
|
|
@@ -147,7 +147,7 @@
|
|
|
147
147
|
"genericTypes": []
|
|
148
148
|
},
|
|
149
149
|
{
|
|
150
|
-
"name": "
|
|
150
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__Outpoint",
|
|
151
151
|
"params": [
|
|
152
152
|
{
|
|
153
153
|
"name": "txHash",
|
|
@@ -161,7 +161,7 @@
|
|
|
161
161
|
"genericTypes": []
|
|
162
162
|
},
|
|
163
163
|
{
|
|
164
|
-
"name": "
|
|
164
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__ChangeInfo",
|
|
165
165
|
"params": [
|
|
166
166
|
{
|
|
167
167
|
"name": "pubkeyhash",
|
|
@@ -179,7 +179,7 @@
|
|
|
179
179
|
"genericTypes": []
|
|
180
180
|
},
|
|
181
181
|
{
|
|
182
|
-
"name": "
|
|
182
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__ReadVarintResult",
|
|
183
183
|
"params": [
|
|
184
184
|
{
|
|
185
185
|
"name": "data",
|
|
@@ -193,7 +193,7 @@
|
|
|
193
193
|
"genericTypes": []
|
|
194
194
|
},
|
|
195
195
|
{
|
|
196
|
-
"name": "
|
|
196
|
+
"name": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721GuardConstState",
|
|
197
197
|
"params": [
|
|
198
198
|
{
|
|
199
199
|
"name": "deployerAddr",
|
|
@@ -215,7 +215,7 @@
|
|
|
215
215
|
"genericTypes": []
|
|
216
216
|
},
|
|
217
217
|
{
|
|
218
|
-
"name": "
|
|
218
|
+
"name": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721State",
|
|
219
219
|
"params": [
|
|
220
220
|
{
|
|
221
221
|
"name": "ownerAddr",
|
|
@@ -229,7 +229,7 @@
|
|
|
229
229
|
"genericTypes": []
|
|
230
230
|
},
|
|
231
231
|
{
|
|
232
|
-
"name": "
|
|
232
|
+
"name": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721ClosedMinterState",
|
|
233
233
|
"params": [
|
|
234
234
|
{
|
|
235
235
|
"name": "nftScriptHash",
|
|
@@ -247,7 +247,7 @@
|
|
|
247
247
|
"genericTypes": []
|
|
248
248
|
},
|
|
249
249
|
{
|
|
250
|
-
"name": "
|
|
250
|
+
"name": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721MerkleLeaf",
|
|
251
251
|
"params": [
|
|
252
252
|
{
|
|
253
253
|
"name": "contentDataHash",
|
|
@@ -265,7 +265,7 @@
|
|
|
265
265
|
"genericTypes": []
|
|
266
266
|
},
|
|
267
267
|
{
|
|
268
|
-
"name": "
|
|
268
|
+
"name": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMinterState",
|
|
269
269
|
"params": [
|
|
270
270
|
{
|
|
271
271
|
"name": "nftScriptHash",
|
|
@@ -285,25 +285,25 @@
|
|
|
285
285
|
],
|
|
286
286
|
"library": [
|
|
287
287
|
{
|
|
288
|
-
"name": "
|
|
288
|
+
"name": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMinterMerkleTree",
|
|
289
289
|
"params": [],
|
|
290
290
|
"properties": [],
|
|
291
291
|
"genericTypes": []
|
|
292
292
|
},
|
|
293
293
|
{
|
|
294
|
-
"name": "
|
|
294
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__TxUtils",
|
|
295
295
|
"params": [],
|
|
296
296
|
"properties": [],
|
|
297
297
|
"genericTypes": []
|
|
298
298
|
},
|
|
299
299
|
{
|
|
300
|
-
"name": "
|
|
300
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__ContextUtils",
|
|
301
301
|
"params": [],
|
|
302
302
|
"properties": [],
|
|
303
303
|
"genericTypes": []
|
|
304
304
|
},
|
|
305
305
|
{
|
|
306
|
-
"name": "
|
|
306
|
+
"name": "_opcat_labs_scrypt_ts_opcat_3_4_0__rs__StdUtils",
|
|
307
307
|
"params": [],
|
|
308
308
|
"properties": [],
|
|
309
309
|
"genericTypes": []
|
|
@@ -5,7 +5,7 @@ import "../../scrypt-ts-opcat/assets/smart-contract/builtin-libs/contextUtils.sc
|
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
|
|
8
|
-
library
|
|
8
|
+
library _opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMinterMerkleTree {
|
|
9
9
|
static function updateLeaf(bytes oldLeaf, bytes newLeaf, bytes[15] proof, bool[15] proofNodePos, bytes merkleRoot) : bytes {
|
|
10
10
|
bytes oldRoot = oldLeaf;
|
|
11
11
|
bytes newRoot = newLeaf;
|
|
@@ -21,16 +21,16 @@ library _opcat_labs_cat_sdk_3_3_0__rs__CAT721OpenMinterMerkleTree {
|
|
|
21
21
|
require(oldRoot == merkleRoot);
|
|
22
22
|
return newRoot;
|
|
23
23
|
}
|
|
24
|
-
static function leafStateHash(
|
|
25
|
-
return hash160(
|
|
24
|
+
static function leafStateHash(_opcat_labs_cat_sdk_3_4_0__rs__CAT721MerkleLeaf leaf) : bytes {
|
|
25
|
+
return hash160(_opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMinterMerkleTree.leafPropHashes(leaf));
|
|
26
26
|
}
|
|
27
|
-
static function checkLeaf(
|
|
27
|
+
static function checkLeaf(_opcat_labs_cat_sdk_3_4_0__rs__CAT721MerkleLeaf leaf) : bool {
|
|
28
28
|
require(len(leaf.contentDataHash) == 32);
|
|
29
29
|
require(leaf.localId >= 0);
|
|
30
30
|
return true;
|
|
31
31
|
}
|
|
32
|
-
static function leafPropHashes(
|
|
33
|
-
|
|
32
|
+
static function leafPropHashes(_opcat_labs_cat_sdk_3_4_0__rs__CAT721MerkleLeaf leaf) : bytes {
|
|
33
|
+
_opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMinterMerkleTree.checkLeaf(leaf);
|
|
34
34
|
bytes isMined = leaf.isMined ? b'01' : b'00';
|
|
35
35
|
return hash160(leaf.contentDataHash) + hash160(pack(leaf.localId)) + hash160(isMined);
|
|
36
36
|
}
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
"md5": "d41d8cd98f00b204e9800998ecf8427e",
|
|
6
6
|
"structs": [
|
|
7
7
|
{
|
|
8
|
-
"name": "
|
|
8
|
+
"name": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721GuardConstState",
|
|
9
9
|
"params": [
|
|
10
10
|
{
|
|
11
11
|
"name": "deployerAddr",
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
"genericTypes": []
|
|
28
28
|
},
|
|
29
29
|
{
|
|
30
|
-
"name": "
|
|
30
|
+
"name": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721State",
|
|
31
31
|
"params": [
|
|
32
32
|
{
|
|
33
33
|
"name": "ownerAddr",
|
|
@@ -41,7 +41,7 @@
|
|
|
41
41
|
"genericTypes": []
|
|
42
42
|
},
|
|
43
43
|
{
|
|
44
|
-
"name": "
|
|
44
|
+
"name": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721ClosedMinterState",
|
|
45
45
|
"params": [
|
|
46
46
|
{
|
|
47
47
|
"name": "nftScriptHash",
|
|
@@ -59,7 +59,7 @@
|
|
|
59
59
|
"genericTypes": []
|
|
60
60
|
},
|
|
61
61
|
{
|
|
62
|
-
"name": "
|
|
62
|
+
"name": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721MerkleLeaf",
|
|
63
63
|
"params": [
|
|
64
64
|
{
|
|
65
65
|
"name": "contentDataHash",
|
|
@@ -77,7 +77,7 @@
|
|
|
77
77
|
"genericTypes": []
|
|
78
78
|
},
|
|
79
79
|
{
|
|
80
|
-
"name": "
|
|
80
|
+
"name": "_opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMinterState",
|
|
81
81
|
"params": [
|
|
82
82
|
{
|
|
83
83
|
"name": "nftScriptHash",
|
|
@@ -1,31 +1,31 @@
|
|
|
1
1
|
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
struct
|
|
4
|
+
struct _opcat_labs_cat_sdk_3_4_0__rs__CAT721GuardConstState {
|
|
5
5
|
bytes deployerAddr;
|
|
6
6
|
bytes[4] nftScriptHashes;
|
|
7
7
|
bytes nftBurnMasks;
|
|
8
8
|
bytes nftScriptIndexes;
|
|
9
9
|
}
|
|
10
10
|
|
|
11
|
-
struct
|
|
11
|
+
struct _opcat_labs_cat_sdk_3_4_0__rs__CAT721State {
|
|
12
12
|
bytes ownerAddr;
|
|
13
13
|
int localId;
|
|
14
14
|
}
|
|
15
15
|
|
|
16
|
-
struct
|
|
16
|
+
struct _opcat_labs_cat_sdk_3_4_0__rs__CAT721ClosedMinterState {
|
|
17
17
|
bytes nftScriptHash;
|
|
18
18
|
int maxLocalId;
|
|
19
19
|
int nextLocalId;
|
|
20
20
|
}
|
|
21
21
|
|
|
22
|
-
struct
|
|
22
|
+
struct _opcat_labs_cat_sdk_3_4_0__rs__CAT721MerkleLeaf {
|
|
23
23
|
bytes contentDataHash;
|
|
24
24
|
int localId;
|
|
25
25
|
bool isMined;
|
|
26
26
|
}
|
|
27
27
|
|
|
28
|
-
struct
|
|
28
|
+
struct _opcat_labs_cat_sdk_3_4_0__rs__CAT721OpenMinterState {
|
|
29
29
|
bytes nftScriptHash;
|
|
30
30
|
bytes merkleRoot;
|
|
31
31
|
int nextLocalId;
|