tx · 9usH3PwWz2L24HfqnU77kom8LCik438hckcpW4286acA 3N4vqUXWw8tf23LDWDbSEpJZH6dent3ETFu: -0.04000000 Waves 2022.03.29 19:39 [1985470] smart account 3N4vqUXWw8tf23LDWDbSEpJZH6dent3ETFu > SELF 0.00000000 Waves
{ "type": 13, "id": "9usH3PwWz2L24HfqnU77kom8LCik438hckcpW4286acA", "fee": 4000000, "feeAssetId": null, "timestamp": 1648571978800, "version": 2, "chainId": 84, "sender": "3N4vqUXWw8tf23LDWDbSEpJZH6dent3ETFu", "senderPublicKey": "D4v2S9mjah7eEEmuQVBNd4WipC3scs8V4PjuDBweWatE", "proofs": [ "5EySJb5o7mJpnM5TjeBYDLJyE9MujVEotT2iArgAXzVHMPAgPRqCayMZUNtUdH2oQ4FW1GMV1eShXiJ8zcQLP8rj" ], "script": "base64:AAIFAAAAAAAAACkIAhIECgIICBIECgIICBIFCgMICAgSBgoECAgICBIECgIIARIECgIICAAAABEAAAAABENPTFMAAAAAAAAABAAAAAAABFJPV1MAAAAAAAAABAAAAAAACW5mdERvbWFpbgIAAAAYaHR0cHM6Ly9uZnQuZ3JpZGdhbmcuaW8vAAAAABVhZGRPd25lckFuZEFtb3VudEZ1bmMCAAAAEWFkZE93bmVyQW5kQW1vdW50AAAAAAVERUJVRwYAAAAAEW1pbkZvclNhbGVXYXZsZXRzAAAAAAAF9eEAAAAAABBtaW5QdXJjaGFzZVByaWNlAAAAAAAAD0JAAAAAAARkYXBwAgAAACMzTjR2cVVYV3c4dGYyM0xEV0RiU0VwSlpINmRlbnQzRVRGdQAAAAALZGFwcEFkZHJlc3MJAQAAAAdBZGRyZXNzAAAAAQkAAlkAAAABBQAAAARkYXBwAAAAABFob2xkaW5nc1B1YmxpY0tleQIAAAAsR1VIdzFqa3N0TldUczlTWDFLTTNwTXRxOUhYanVwdnhpVGQxdXJOaE5veVkAAAAACGhvbGRpbmdzAgAAACMzTjlSN3U0NDlaMWI3NlFwSnA5dTNnelBqTVlRWW5wM1Y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AACdHgAAAAPc2VuZGVyUHVibGljS2V5BQAAAA9ob2xkaW5nc0FkZHJlc3MGCQAAAAAAAAIJAQAAABRhZGRyZXNzRnJvbVB1YmxpY0tleQAAAAEIBQAAAAJ0eAAAAA9zZW5kZXJQdWJsaWNLZXkFAAAAC2RhcHBBZGRyZXNza+OINQ==", "height": 1985470, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 56xuKEbeLjsPGAXgLgRiza8ZGDCd3FUcDKjo9XnMp6tf Next: DSfKH1do9BwzncYAhLvsVzayW1XWiXcL69PvRDss2T6G Diff:
Old | New | Differences | |
---|---|---|---|
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 $t028872983 = claimSquare(x, y, "1", holdings, transactionId) | |
109 | + | let asset = $t028872983._1 | |
110 | + | let assetId = $t028872983._2 | |
111 | + | let assetUrl = $t028872983._3 | |
112 | + | let dataKeyPrefix = $t028872983._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 $t037393844 = claimSquare(x, y, "1", desinationAddress, transactionId) | |
131 | + | let asset = $t037393844._1 | |
132 | + | let assetId = $t037393844._2 | |
133 | + | let assetUrl = $t037393844._3 | |
134 | + | let dataKeyPrefix = $t037393844._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 $t045074602 = claimSquare(x, y, gen, ownerId, transactionId) | |
150 | + | let asset = $t045074602._1 | |
151 | + | let assetId = $t045074602._2 | |
152 | + | let assetUrl = $t045074602._3 | |
153 | + | let dataKeyPrefix = $t045074602._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 | } | |
188 | 188 | } | |
189 | 189 | ||
190 | 190 | ||
191 | + | ||
192 | + | @Callable(i) | |
193 | + | func finalizeSale (assetId,ownerId) = { | |
194 | + | let callerId = toBase58String(i.caller.bytes) | |
195 | + | if ((callerId != holdings)) | |
196 | + | then throw("This can only be triggering internally") | |
197 | + | else { | |
198 | + | let prefix = match assetInfo(fromBase58String(assetId)) { | |
199 | + | case asset: Asset => | |
200 | + | asset.name | |
201 | + | case _ => | |
202 | + | throw("Can't find asset") | |
203 | + | } | |
204 | + | [StringEntry((prefix + "_owner"), ownerId)] | |
205 | + | } | |
206 | + | } | |
207 | + | ||
208 | + | ||
191 | 209 | @Verifier(tx) | |
192 | 210 | func verify () = if (if (sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey)) | |
193 | 211 | then true |
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 | 18 | let dapp = "3N4vqUXWw8tf23LDWDbSEpJZH6dent3ETFu" | |
19 | 19 | ||
20 | 20 | let dappAddress = Address(fromBase58String(dapp)) | |
21 | 21 | ||
22 | 22 | let holdingsPublicKey = "GUHw1jkstNWTs9SX1KM3pMtq9HXjupvxiTd1urNhNoyY" | |
23 | 23 | ||
24 | 24 | let holdings = "3N9R7u449Z1b76QpJp9u3gzPjMYQYnp3V7r" | |
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 | 72 | func purchase (x,y) = { | |
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 | 88 | let $t022152310 = claimSquare(x, y, "1", ownerId, transactionId) | |
89 | 89 | let asset = $t022152310._1 | |
90 | 90 | let assetId = $t022152310._2 | |
91 | 91 | let assetUrl = $t022152310._3 | |
92 | 92 | let dataKeyPrefix = $t022152310._4 | |
93 | 93 | [asset, StringEntry((dataKeyPrefix + "_assetId"), toBase58String(assetId)), StringEntry((dataKeyPrefix + "_asset"), assetUrl), StringEntry((dataKeyPrefix + "_owner"), ownerId), StringEntry(transactionId, dataKeyPrefix), 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 $t028872983 = claimSquare(x, y, "1", holdings, transactionId) | |
109 | + | let asset = $t028872983._1 | |
110 | + | let assetId = $t028872983._2 | |
111 | + | let assetUrl = $t028872983._3 | |
112 | + | let dataKeyPrefix = $t028872983._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 $t037393844 = claimSquare(x, y, "1", desinationAddress, transactionId) | |
131 | + | let asset = $t037393844._1 | |
132 | + | let assetId = $t037393844._2 | |
133 | + | let assetUrl = $t037393844._3 | |
134 | + | let dataKeyPrefix = $t037393844._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 $t045074602 = claimSquare(x, y, gen, ownerId, transactionId) | |
150 | + | let asset = $t045074602._1 | |
151 | + | let assetId = $t045074602._2 | |
152 | + | let assetUrl = $t045074602._3 | |
153 | + | let dataKeyPrefix = $t045074602._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 | + | ||
192 | + | @Callable(i) | |
193 | + | func finalizeSale (assetId,ownerId) = { | |
194 | + | let callerId = toBase58String(i.caller.bytes) | |
195 | + | if ((callerId != holdings)) | |
196 | + | then throw("This can only be triggering internally") | |
197 | + | else { | |
198 | + | let prefix = match assetInfo(fromBase58String(assetId)) { | |
199 | + | case asset: Asset => | |
200 | + | asset.name | |
201 | + | case _ => | |
202 | + | throw("Can't find asset") | |
203 | + | } | |
204 | + | [StringEntry((prefix + "_owner"), ownerId)] | |
205 | + | } | |
206 | + | } | |
207 | + | ||
208 | + | ||
191 | 209 | @Verifier(tx) | |
192 | 210 | func verify () = if (if (sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey)) | |
193 | 211 | then true | |
194 | 212 | else (addressFromPublicKey(tx.senderPublicKey) == holdingsAddress)) | |
195 | 213 | then true | |
196 | 214 | else (addressFromPublicKey(tx.senderPublicKey) == dappAddress) | |
197 | 215 |
github/deemru/w8io/026f985 81.54 ms ◑