Transaction

b8fc72ab5aca9e55687ec2ee6ced1b22d88e57f908a69db5a11d3e16946ae995
2023-11-20 15:10:27
0.00000032 BSV
(
0.19982293 BSV
-
0.19982261 BSV
)
5.006 sat/KB
1
91,703
6,392 B

5 Outputs

Total Output:
0.19982261 BSV
  • jrunM¼{"in":0,"ref":["native://Jig"],"out":["6af39d98578522b05aa4cd9e25a65983b263e80f6476f972846d191e78f90570","9d67db2743e2fc2d44e8d3b3af7eb3125d407a95cd050f266f705628dd31d36b","cb17d4f8fef22d0ee5afa39b98ffe6d8de190466582583270d9f41a22fbfc2f4"],"del":[],"cre":["1x3eET27pzXboWKmeEggfGFkXtsnXuK4Z","1EjpgL9N3eXud9Fi7Ztf9XCptTZGcaby4n","1HZCyw6qi9xBnDgASBkHhgPZ1SWsrbGek6"],"exec":[{"op":"DEPLOY","data":["class Collection extends Jig {\n init(jigCount, maxE, collectionName, to) {\n this.minted = {};\n this.maxE = maxE;\n this.maxN = jigCount;\n this.maxX = 10;\n this.e = 0;\n this.n = 0;\n this.x = 0;\n this.spent = false;\n this.collectionName = collectionName;\n this.owner = to;\n }\n mint(to) {\n if (this.spent)\n return this;\n if (parseInt(`${this.n}${this.x}${'0'.repeat(this.maxE - this.e)}`, 10) >= this.maxN) {\n this.spent = true;\n return this;\n }\n this.newMinted = new Minter(this.e, this.n, this.x, this.maxE, this.maxN, this.maxX, this.collectionName, this.origin, to);\n this.minted[this.x] = true;\n this.x += 1;\n if (this.x >= this.maxX) {\n this.spent = true;\n }\n return this.minted[this.x - 1];\n }\n retrieve(x) {\n if (!this.minted[x])\n throw new Error('Does not exist');\n return this.minted[x];\n }\n }",{"deps":{"Jig":{"$jig":0},"Minter":{"$jig":2},"NFT":{"$jig":3}}},"class Minter extends Jig {\n init(e, n, x, maxE, maxN, maxX, collectionName, collection, to) {\n if (!(caller instanceof Collection) && !(caller instanceof Minter))\n throw new Error('Only Collection and Minter classes can create minters');\n this.e = e + 1;\n this.n = parseInt(`${n}${x}`, 10);\n this.x = 0;\n this.maxE = maxE;\n this.maxN = maxN;\n this.maxX = maxX;\n this.minted = {};\n this.spent = false;\n this.collectionName = collectionName;\n this.collection = collection;\n this.owner = to;\n }\n mint(to) {\n if (this.spent)\n return this;\n if (this.e === this.maxE) {\n if (parseInt(`${this.n}${this.x}`, 10) >= this.maxN) {\n this.spent = true;\n return this;\n }\n this.newMinted = new NFT(this.n, this.x, this.collectionName, this.collection, to);\n this.minted[this.x] = true;\n this.x += 1;\n }\n else if (this.e < this.maxE) {\n if (parseInt(`${this.n}${this.x}${'0'.repeat(this.maxE - this.e)}`, 10) >= this.maxN) {\n this.spent = true;\n return this;\n }\n this.newMinted = new Minter(this.e, this.n, this.x, this.maxE, this.maxN, this.maxX, this.collectionName, this.collection, to);\n this.minted[this.x] = true;\n this.x += 1;\n }\n if (this.x >= this.maxX) {\n this.spent = true;\n }\n return this;\n }\n retrieve(x) {\n if (this.minted[x])\n throw new Error('Does not exist');\n return this.minted[x];\n }\n }",{"deps":{"Collection":{"$jig":1},"Jig":{"$dup":["1","deps","Jig"]},"NFT":{"$dup":["1","deps","NFT"]}}},"class NFT extends Jig {\n init(n, x, collectionName, collection, to) {\n if (!(caller instanceof Minter))\n throw new Error('Only Minter instances may create NFTs.');\n this.serial = parseInt(`${n}${x}`, 10);\n this.minted = {};\n this.properties = {};\n this.collectionName = collectionName;\n this.collection = collection;\n this.owner = to;\n }\n send(to) {\n this.owner = to;\n }\n retrieve(c) {\n if (this.minted[c])\n throw new Error('Does not exist');\n return this.minted[c];\n }\n update(collection, properties, to) {\n if (collection.origin !== this.collection)\n throw new Error('Only Collection instances may update NFTs.');\n this.properties = Object.assign(this.properties, properties);\n this.owner = to;\n return this;\n }\n }",{"deps":{"Collection":{"$dup":["3","deps","Collection"]},"Jig":{"$dup":["1","deps","Jig"]},"Minter":{"$dup":["1","deps","Minter"]}}}]}]}
    https://whatsonchain.com/tx/b8fc72ab5aca9e55687ec2ee6ced1b22d88e57f908a69db5a11d3e16946ae995