tx · DSfKH1do9BwzncYAhLvsVzayW1XWiXcL69PvRDss2T6G 3N4vqUXWw8tf23LDWDbSEpJZH6dent3ETFu: -0.04000000 Waves 2022.04.16 18:52 [2011315] smart account 3N4vqUXWw8tf23LDWDbSEpJZH6dent3ETFu > SELF 0.00000000 Waves
{ "type": 13, "id": "DSfKH1do9BwzncYAhLvsVzayW1XWiXcL69PvRDss2T6G", "fee": 4000000, "feeAssetId": null, "timestamp": 1650124329715, "version": 2, "chainId": 84, "sender": "3N4vqUXWw8tf23LDWDbSEpJZH6dent3ETFu", "senderPublicKey": "D4v2S9mjah7eEEmuQVBNd4WipC3scs8V4PjuDBweWatE", "proofs": [ "3cHACZW8osZMzk1xJsqt5MGQRokHJZPfLiQRjsqyt357kPqbWDxfBg6tTdCqzhiLtcAs7QjsUrVdBpUzyCAXeSA" ], "script": "base64:AAIFAAAAAAAAACoIAhIFCgMICAgSBAoCCAgSBQoDCAgIEgYKBAgICAgSBAoCCAESBAoCCAgAAAARAAAAAARDT0xTAAAAAAAAAAQAAAAAAARST1dTAAAAAAAAAAQAAAAAAAluZnREb21haW4CAAAAGGh0dHBzOi8vbmZ0LmdyaWRnYW5nLmlvLwAAAAAVYWRkT3duZXJBbmRBbW91bnRGdW5jAgAAABFhZGRPd25lckFuZEFtb3VudAAAAAAFREVCVUcGAAAAABFtaW5Gb3JTYWxlV2F2bGV0cwAAAAAABfXhAAAAAAAQbWluUHVyY2hhc2VQcmljZQAAAAAAAA9CQAAAAAAEZGFwcAIAAAAjM012VXl6UXhOR213RXhBY0tkaG9qZktlbTNYd2tYZGtCeUgAAAAAC2RhcHBBZGRyZXNzCQEAAAAHQWRkcmVzcwAAAAEJAAJZAAAAAQUAAAAEZGFwcAAAAAARaG9sZGluZ3NQdWJsaWNLZXkCAAAALDJlaXhxTERLSjVranVZOGltSDRIRzJGQkpkdVQ2UXNqeExMY2gxaWFBYWR4AAAAAAhob2xkaW5ncwIAAAAjM01wRnRjZGhhQjY2TkIzOHRXMk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AAAAAAAAAAAAgFAAAAAnR4AAAAD3NlbmRlclB1YmxpY0tleQYJAAAAAAAAAgkBAAAAFGFkZHJlc3NGcm9tUHVibGljS2V5AAAAAQgFAAAAAnR4AAAAD3NlbmRlclB1YmxpY0tleQUAAAAPaG9sZGluZ3NBZGRyZXNzBgkAAAAAAAACCQEAAAAUYWRkcmVzc0Zyb21QdWJsaWNLZXkAAAABCAUAAAACdHgAAAAPc2VuZGVyUHVibGljS2V5BQAAAAtkYXBwQWRkcmVzcyfW994=", "height": 2011315, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 9usH3PwWz2L24HfqnU77kom8LCik438hckcpW4286acA Next: none Diff:
Old | New | Differences | |
---|---|---|---|
15 | 15 | ||
16 | 16 | let minPurchasePrice = 1000000 | |
17 | 17 | ||
18 | - | let dapp = " | |
18 | + | let dapp = "3MvUyzQxNGmwExAcKdhojfKem3XwkXdkByH" | |
19 | 19 | ||
20 | 20 | let dappAddress = Address(fromBase58String(dapp)) | |
21 | 21 | ||
22 | - | let holdingsPublicKey = " | |
22 | + | let holdingsPublicKey = "2eixqLDKJ5kjuY8imH4HG2FBJduT6QsjxLLch1iaAadx" | |
23 | 23 | ||
24 | - | let holdings = " | |
24 | + | let holdings = "3MpFtcdhaB66NB38tW2APSiaVqaAoWoPvRJ" | |
25 | 25 | ||
26 | 26 | let holdingsAddress = Address(fromBase58String(holdings)) | |
27 | 27 | ||
69 | 69 | ||
70 | 70 | ||
71 | 71 | @Callable(i) | |
72 | - | func purchase (x,y) = { | |
72 | + | func purchase (x,y,userText) = { | |
73 | 73 | let prefix = getDataKeyPrefix(x, y, "1") | |
74 | 74 | let paymentAmount = valueOrElse(i.payments[0].amount, 0) | |
75 | 75 | let existingAssetId = match getString(this, (prefix + "_assetId")) { | |
85 | 85 | else { | |
86 | 86 | let ownerId = toBase58String(i.caller.bytes) | |
87 | 87 | let transactionId = toBase58String(i.transactionId) | |
88 | - | let $ | |
89 | - | let asset = $ | |
90 | - | let assetId = $ | |
91 | - | let assetUrl = $ | |
92 | - | let dataKeyPrefix = $ | |
93 | - | [asset, StringEntry((dataKeyPrefix + "_assetId"), toBase58String(assetId)), StringEntry((dataKeyPrefix + "_asset"), assetUrl), StringEntry((dataKeyPrefix + "_owner"), ownerId), StringEntry(transactionId, dataKeyPrefix), ScriptTransfer(i.caller, 1, assetId)] | |
88 | + | let $t022332328 = claimSquare(x, y, "1", ownerId, transactionId) | |
89 | + | let asset = $t022332328._1 | |
90 | + | let assetId = $t022332328._2 | |
91 | + | let assetUrl = $t022332328._3 | |
92 | + | let dataKeyPrefix = $t022332328._4 | |
93 | + | [asset, StringEntry((dataKeyPrefix + "_assetId"), toBase58String(assetId)), StringEntry((dataKeyPrefix + "_asset"), assetUrl), StringEntry((dataKeyPrefix + "_owner"), ownerId), StringEntry(transactionId, dataKeyPrefix), StringEntry(ownerId, userText), ScriptTransfer(i.caller, 1, assetId)] | |
94 | 94 | } | |
95 | 95 | } | |
96 | 96 | ||
105 | 105 | then throw("This can only be triggering internally") | |
106 | 106 | else { | |
107 | 107 | let transactionId = toBase58String(i.transactionId) | |
108 | - | let $ | |
109 | - | let asset = $ | |
110 | - | let assetId = $ | |
111 | - | let assetUrl = $ | |
112 | - | let dataKeyPrefix = $ | |
108 | + | let $t029433039 = claimSquare(x, y, "1", holdings, transactionId) | |
109 | + | let asset = $t029433039._1 | |
110 | + | let assetId = $t029433039._2 | |
111 | + | let assetUrl = $t029433039._3 | |
112 | + | let dataKeyPrefix = $t029433039._4 | |
113 | 113 | let assetIdStr = toBase58String(assetId) | |
114 | 114 | let res = invoke(holdingsAddress, addOwnerAndAmountFunc, [holdings, assetIdStr, 3], [AttachedPayment(unit, 0)]) | |
115 | 115 | if ((res == res)) | |
127 | 127 | then throw("This can only be triggering internally") | |
128 | 128 | else { | |
129 | 129 | let transactionId = toBase58String(i.transactionId) | |
130 | - | let $ | |
131 | - | let asset = $ | |
132 | - | let assetId = $ | |
133 | - | let assetUrl = $ | |
134 | - | let dataKeyPrefix = $ | |
130 | + | let $t037953900 = claimSquare(x, y, "1", desinationAddress, transactionId) | |
131 | + | let asset = $t037953900._1 | |
132 | + | let assetId = $t037953900._2 | |
133 | + | let assetUrl = $t037953900._3 | |
134 | + | let dataKeyPrefix = $t037953900._4 | |
135 | 135 | let assetIdStr = toBase58String(assetId) | |
136 | 136 | [asset, StringEntry((dataKeyPrefix + "_assetId"), assetIdStr), StringEntry((dataKeyPrefix + "_asset"), assetUrl), StringEntry((dataKeyPrefix + "_owner"), desinationAddress), StringEntry(transactionId, dataKeyPrefix), ScriptTransfer(Address(fromBase58String(desinationAddress)), 1, assetId)] | |
137 | 137 | } | |
146 | 146 | then throw("This can only be triggering internally") | |
147 | 147 | else { | |
148 | 148 | let transactionId = toBase58String(i.transactionId) | |
149 | - | let $ | |
150 | - | let asset = $ | |
151 | - | let assetId = $ | |
152 | - | let assetUrl = $ | |
153 | - | let dataKeyPrefix = $ | |
149 | + | let $t046264721 = claimSquare(x, y, gen, ownerId, transactionId) | |
150 | + | let asset = $t046264721._1 | |
151 | + | let assetId = $t046264721._2 | |
152 | + | let assetUrl = $t046264721._3 | |
153 | + | let dataKeyPrefix = $t046264721._4 | |
154 | 154 | [asset, StringEntry((dataKeyPrefix + "_assetId"), toBase58String(assetId)), StringEntry((dataKeyPrefix + "_asset"), assetUrl), StringEntry((dataKeyPrefix + "_owner"), ownerId), StringEntry(transactionId, dataKeyPrefix), ScriptTransfer(Address(fromBase58String(ownerId)), 1, assetId)] | |
155 | 155 | } | |
156 | 156 | } |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 5 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let COLS = 1024 | |
5 | 5 | ||
6 | 6 | let ROWS = 1024 | |
7 | 7 | ||
8 | 8 | let nftDomain = "https://nft.gridgang.io/" | |
9 | 9 | ||
10 | 10 | let addOwnerAndAmountFunc = "addOwnerAndAmount" | |
11 | 11 | ||
12 | 12 | let DEBUG = true | |
13 | 13 | ||
14 | 14 | let minForSaleWavlets = 100000000 | |
15 | 15 | ||
16 | 16 | let minPurchasePrice = 1000000 | |
17 | 17 | ||
18 | - | let dapp = " | |
18 | + | let dapp = "3MvUyzQxNGmwExAcKdhojfKem3XwkXdkByH" | |
19 | 19 | ||
20 | 20 | let dappAddress = Address(fromBase58String(dapp)) | |
21 | 21 | ||
22 | - | let holdingsPublicKey = " | |
22 | + | let holdingsPublicKey = "2eixqLDKJ5kjuY8imH4HG2FBJduT6QsjxLLch1iaAadx" | |
23 | 23 | ||
24 | - | let holdings = " | |
24 | + | let holdings = "3MpFtcdhaB66NB38tW2APSiaVqaAoWoPvRJ" | |
25 | 25 | ||
26 | 26 | let holdingsAddress = Address(fromBase58String(holdings)) | |
27 | 27 | ||
28 | 28 | func getAssetName (x,y) = { | |
29 | 29 | let name = ((x + ",") + y) | |
30 | 30 | name | |
31 | 31 | } | |
32 | 32 | ||
33 | 33 | ||
34 | 34 | func getDataKeyPrefix (x,y,gen) = { | |
35 | 35 | let name = getAssetName(x, y) | |
36 | 36 | let prefix = ((name + ",") + gen) | |
37 | 37 | prefix | |
38 | 38 | } | |
39 | 39 | ||
40 | 40 | ||
41 | 41 | func getXYGenFromName (name) = { | |
42 | 42 | let parts = split(name, ",") | |
43 | 43 | let tuple = $Tuple3(parts[0], parts[1], parts[2]) | |
44 | 44 | tuple | |
45 | 45 | } | |
46 | 46 | ||
47 | 47 | ||
48 | 48 | func getDataKeyPrefixFromAssetName (name) = { | |
49 | 49 | let $t010011041 = getXYGenFromName(name) | |
50 | 50 | let x = $t010011041._1 | |
51 | 51 | let y = $t010011041._2 | |
52 | 52 | let gen = $t010011041._3 | |
53 | 53 | let prefix = getDataKeyPrefix(x, y, gen) | |
54 | 54 | prefix | |
55 | 55 | } | |
56 | 56 | ||
57 | 57 | ||
58 | 58 | func claimSquare (x,y,gen,ownerId,transactionId) = { | |
59 | 59 | let resolvedXStr = x | |
60 | 60 | let resolvedYStr = y | |
61 | 61 | let resolvedGenStr = gen | |
62 | 62 | let assetName = getAssetName(resolvedXStr, resolvedYStr) | |
63 | 63 | let assetUrl = ((nftDomain + transactionId) + ".png") | |
64 | 64 | let asset = Issue(((assetName + ",") + resolvedGenStr), assetUrl, 1, 0, false) | |
65 | 65 | let assetId = calculateAssetId(asset) | |
66 | 66 | let dataKeyPrefix = getDataKeyPrefix(resolvedXStr, resolvedYStr, gen) | |
67 | 67 | $Tuple4(asset, assetId, assetUrl, dataKeyPrefix) | |
68 | 68 | } | |
69 | 69 | ||
70 | 70 | ||
71 | 71 | @Callable(i) | |
72 | - | func purchase (x,y) = { | |
72 | + | func purchase (x,y,userText) = { | |
73 | 73 | let prefix = getDataKeyPrefix(x, y, "1") | |
74 | 74 | let paymentAmount = valueOrElse(i.payments[0].amount, 0) | |
75 | 75 | let existingAssetId = match getString(this, (prefix + "_assetId")) { | |
76 | 76 | case _: Unit => | |
77 | 77 | "unset" | |
78 | 78 | case err: String => | |
79 | 79 | throw("This square has already been purchased") | |
80 | 80 | case _ => | |
81 | 81 | throw("Match error") | |
82 | 82 | } | |
83 | 83 | if ((minPurchasePrice > paymentAmount)) | |
84 | 84 | then throw((("You need to send at least " + toString(minPurchasePrice)) + "WAVLETS to purchase a square")) | |
85 | 85 | else { | |
86 | 86 | let ownerId = toBase58String(i.caller.bytes) | |
87 | 87 | let transactionId = toBase58String(i.transactionId) | |
88 | - | let $ | |
89 | - | let asset = $ | |
90 | - | let assetId = $ | |
91 | - | let assetUrl = $ | |
92 | - | let dataKeyPrefix = $ | |
93 | - | [asset, StringEntry((dataKeyPrefix + "_assetId"), toBase58String(assetId)), StringEntry((dataKeyPrefix + "_asset"), assetUrl), StringEntry((dataKeyPrefix + "_owner"), ownerId), StringEntry(transactionId, dataKeyPrefix), ScriptTransfer(i.caller, 1, assetId)] | |
88 | + | let $t022332328 = claimSquare(x, y, "1", ownerId, transactionId) | |
89 | + | let asset = $t022332328._1 | |
90 | + | let assetId = $t022332328._2 | |
91 | + | let assetUrl = $t022332328._3 | |
92 | + | let dataKeyPrefix = $t022332328._4 | |
93 | + | [asset, StringEntry((dataKeyPrefix + "_assetId"), toBase58String(assetId)), StringEntry((dataKeyPrefix + "_asset"), assetUrl), StringEntry((dataKeyPrefix + "_owner"), ownerId), StringEntry(transactionId, dataKeyPrefix), StringEntry(ownerId, userText), ScriptTransfer(i.caller, 1, assetId)] | |
94 | 94 | } | |
95 | 95 | } | |
96 | 96 | ||
97 | 97 | ||
98 | 98 | ||
99 | 99 | @Callable(i) | |
100 | 100 | func autoBuy (x,y) = { | |
101 | 101 | let callerId = toBase58String(i.caller.bytes) | |
102 | 102 | if (if ((callerId != holdings)) | |
103 | 103 | then (callerId != dapp) | |
104 | 104 | else false) | |
105 | 105 | then throw("This can only be triggering internally") | |
106 | 106 | else { | |
107 | 107 | let transactionId = toBase58String(i.transactionId) | |
108 | - | let $ | |
109 | - | let asset = $ | |
110 | - | let assetId = $ | |
111 | - | let assetUrl = $ | |
112 | - | let dataKeyPrefix = $ | |
108 | + | let $t029433039 = claimSquare(x, y, "1", holdings, transactionId) | |
109 | + | let asset = $t029433039._1 | |
110 | + | let assetId = $t029433039._2 | |
111 | + | let assetUrl = $t029433039._3 | |
112 | + | let dataKeyPrefix = $t029433039._4 | |
113 | 113 | let assetIdStr = toBase58String(assetId) | |
114 | 114 | let res = invoke(holdingsAddress, addOwnerAndAmountFunc, [holdings, assetIdStr, 3], [AttachedPayment(unit, 0)]) | |
115 | 115 | if ((res == res)) | |
116 | 116 | then [asset, StringEntry((dataKeyPrefix + "_assetId"), assetIdStr), StringEntry((dataKeyPrefix + "_asset"), assetUrl), StringEntry((dataKeyPrefix + "_owner"), holdings), StringEntry(transactionId, dataKeyPrefix), ScriptTransfer(holdingsAddress, 1, assetId)] | |
117 | 117 | else throw("Strict value is not equal to itself.") | |
118 | 118 | } | |
119 | 119 | } | |
120 | 120 | ||
121 | 121 | ||
122 | 122 | ||
123 | 123 | @Callable(i) | |
124 | 124 | func promotionPurchase (x,y,desinationAddress) = { | |
125 | 125 | let callerId = toBase58String(i.caller.bytes) | |
126 | 126 | if ((callerId != holdings)) | |
127 | 127 | then throw("This can only be triggering internally") | |
128 | 128 | else { | |
129 | 129 | let transactionId = toBase58String(i.transactionId) | |
130 | - | let $ | |
131 | - | let asset = $ | |
132 | - | let assetId = $ | |
133 | - | let assetUrl = $ | |
134 | - | let dataKeyPrefix = $ | |
130 | + | let $t037953900 = claimSquare(x, y, "1", desinationAddress, transactionId) | |
131 | + | let asset = $t037953900._1 | |
132 | + | let assetId = $t037953900._2 | |
133 | + | let assetUrl = $t037953900._3 | |
134 | + | let dataKeyPrefix = $t037953900._4 | |
135 | 135 | let assetIdStr = toBase58String(assetId) | |
136 | 136 | [asset, StringEntry((dataKeyPrefix + "_assetId"), assetIdStr), StringEntry((dataKeyPrefix + "_asset"), assetUrl), StringEntry((dataKeyPrefix + "_owner"), desinationAddress), StringEntry(transactionId, dataKeyPrefix), ScriptTransfer(Address(fromBase58String(desinationAddress)), 1, assetId)] | |
137 | 137 | } | |
138 | 138 | } | |
139 | 139 | ||
140 | 140 | ||
141 | 141 | ||
142 | 142 | @Callable(i) | |
143 | 143 | func evolve (x,y,gen,ownerId) = { | |
144 | 144 | let callerId = toBase58String(i.caller.bytes) | |
145 | 145 | if ((callerId != holdings)) | |
146 | 146 | then throw("This can only be triggering internally") | |
147 | 147 | else { | |
148 | 148 | let transactionId = toBase58String(i.transactionId) | |
149 | - | let $ | |
150 | - | let asset = $ | |
151 | - | let assetId = $ | |
152 | - | let assetUrl = $ | |
153 | - | let dataKeyPrefix = $ | |
149 | + | let $t046264721 = claimSquare(x, y, gen, ownerId, transactionId) | |
150 | + | let asset = $t046264721._1 | |
151 | + | let assetId = $t046264721._2 | |
152 | + | let assetUrl = $t046264721._3 | |
153 | + | let dataKeyPrefix = $t046264721._4 | |
154 | 154 | [asset, StringEntry((dataKeyPrefix + "_assetId"), toBase58String(assetId)), StringEntry((dataKeyPrefix + "_asset"), assetUrl), StringEntry((dataKeyPrefix + "_owner"), ownerId), StringEntry(transactionId, dataKeyPrefix), ScriptTransfer(Address(fromBase58String(ownerId)), 1, assetId)] | |
155 | 155 | } | |
156 | 156 | } | |
157 | 157 | ||
158 | 158 | ||
159 | 159 | ||
160 | 160 | @Callable(i) | |
161 | 161 | func putForSale (assetId,amount) = { | |
162 | 162 | let callerId = toBase58String(i.caller.bytes) | |
163 | 163 | let assetData = match assetInfo(fromBase58String(assetId)) { | |
164 | 164 | case ass: Asset => | |
165 | 165 | ass | |
166 | 166 | case _ => | |
167 | 167 | throw("Asset not found") | |
168 | 168 | } | |
169 | 169 | let dataPrefix = getDataKeyPrefixFromAssetName(assetData.name) | |
170 | 170 | let ownerId = match getString(this, (dataPrefix + "_owner")) { | |
171 | 171 | case s: String => | |
172 | 172 | s | |
173 | 173 | case _ => | |
174 | 174 | throw("Owner not found in data") | |
175 | 175 | } | |
176 | 176 | if ((minForSaleWavlets > amount)) | |
177 | 177 | then throw("Amount needs to be more than 1 wave") | |
178 | 178 | else if (if ((callerId != ownerId)) | |
179 | 179 | then (callerId != holdings) | |
180 | 180 | else false) | |
181 | 181 | then throw("You are not able to put this asset up for sale") | |
182 | 182 | else { | |
183 | 183 | let res = invoke(holdingsAddress, addOwnerAndAmountFunc, [callerId, assetId, amount], [AttachedPayment(unit, 0)]) | |
184 | 184 | if ((res == res)) | |
185 | 185 | then [ScriptTransfer(holdingsAddress, 1, fromBase58String(assetId))] | |
186 | 186 | else throw("Strict value is not equal to itself.") | |
187 | 187 | } | |
188 | 188 | } | |
189 | 189 | ||
190 | 190 | ||
191 | 191 | ||
192 | 192 | @Callable(i) | |
193 | 193 | func finalizeSale (assetId,ownerId) = { | |
194 | 194 | let callerId = toBase58String(i.caller.bytes) | |
195 | 195 | if ((callerId != holdings)) | |
196 | 196 | then throw("This can only be triggering internally") | |
197 | 197 | else { | |
198 | 198 | let prefix = match assetInfo(fromBase58String(assetId)) { | |
199 | 199 | case asset: Asset => | |
200 | 200 | asset.name | |
201 | 201 | case _ => | |
202 | 202 | throw("Can't find asset") | |
203 | 203 | } | |
204 | 204 | [StringEntry((prefix + "_owner"), ownerId)] | |
205 | 205 | } | |
206 | 206 | } | |
207 | 207 | ||
208 | 208 | ||
209 | 209 | @Verifier(tx) | |
210 | 210 | func verify () = if (if (sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey)) | |
211 | 211 | then true | |
212 | 212 | else (addressFromPublicKey(tx.senderPublicKey) == holdingsAddress)) | |
213 | 213 | then true | |
214 | 214 | else (addressFromPublicKey(tx.senderPublicKey) == dappAddress) | |
215 | 215 |
github/deemru/w8io/026f985 40.94 ms ◑