tx · 6Fsf4AyN7k7jZsBU6N3xK5o4xTobqC8gFWEDqCM1oMfM 3MumkGGztCKAXpWDqxkddofqXSUbqQkvSJy: -0.01000000 Waves 2023.01.19 13:42 [2411705] smart account 3MumkGGztCKAXpWDqxkddofqXSUbqQkvSJy > SELF 0.00000000 Waves
{ "type": 13, "id": "6Fsf4AyN7k7jZsBU6N3xK5o4xTobqC8gFWEDqCM1oMfM", "fee": 1000000, "feeAssetId": null, "timestamp": 1674124971583, "version": 2, "chainId": 84, "sender": "3MumkGGztCKAXpWDqxkddofqXSUbqQkvSJy", "senderPublicKey": "C3PaRKeL8AUKbwUqdniMQtThgcTh5DYHV1777Hkxy7rp", "proofs": [ "2QRbfY7nuftiDhCpEPN4RNN3TMv3yj31Ghtv9DS2i7a7J1SVd939bhfiJjYgWitCKZ5GzqQwV1K8eyvonbrGG3L5" ], "script": "base64:BgITCAISAwoBCBIECgIICBIECgIICCQABWNoYWluCQDJAQIJAMoBAggFBHRoaXMFYnl0ZXMAAQABAAt1c2RuQXNzZXRJZAQHJG1hdGNoMAUFY2hhaW4DCQAAAgEBVwUHJG1hdGNoMAEgtiYpwwT1zlORpA5LdSQvZIxRsfrfr1QpvUjSHSqyqtEDCQAAAgEBVAUHJG1hdGNoMAEg93bq9/eDymXbbhPuAjvPWCmVqcHRjfJL2mzYHWKAyN4JAAIBAg1Vbmtub3duIGNoYWluAA9lY29ub215Q29udHJhY3QJARFAZXh0ck5hdGl2ZSgxMDYyKQEEByRtYXRjaDAFBWNoYWluAwkAAAIBAVcFByRtYXRjaDACIzNQMnNrMUtuY1N4UmFaczhiNENXR1B3MmprdnZhdjc0dTREAwkAAAIBAVQFByRtYXRjaDACIzNOOHk0d3hYM0pDNFRkckNKQlhYMTZTaldmNlgyNTZocmVwCQACAQINVW5rbm93biBjaGFpbgAPc3Rha2luZ0NvbnRyYWN0CQERQGV4dHJOYXRpdmUoMTA2MikBBAckbWF0Y2gwBQVjaGFpbgMJAAACAQFXBQckbWF0Y2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fCQCkAwEIBQxwcm9kdWN0aXZpdHkCXzEJAMwIAgkAuQkCCQDMCAICBCVzJXMJAMwIAgINbGFuZEFydGVmYWN0cwkAzAgCCQCsAgICCFBSRVNBTEU6CQCkAwEIBQxwcm9kdWN0aXZpdHkCXzIFA25pbAUDU0VQCQDMCAIJAKwCAgIQJXMlc19fYXZhaWxSZXNfXwUGcmVzU3RyCQDMCAIJAKwCAgIUJXMlc19fbmVlZE1hdGVyaWFsX18FCm5lZWRNYXRTdHIJAMwIAgkArAICAhMlcyVzX19kdWNrQXNzZXRJZF9fCAUIZHVja0luZm8CXzEJAMwIAgkArAICAhAlcyVzX19sb2NhdGlvbl9fCAUIZHVja0luZm8CXzIJAMwIAgkArAICAg4lcyVkX19oZWFsdGhfXwkApAMBCAUIZHVja0luZm8CXzMJAMwIAgkArAICAhAlcyVzX19iYWNrUGFja19fCAUIZHVja0luZm8CXzQJAMwIAgkAuQkCCQDMCAICBiVzJWQlZAkAzAgCAgZ3YWxsZXQJAMwIAgkApAMBCQCRAwIFCGJhbGFuY2VzAAAJAMwIAgkApAMBCQCRAwIFCGJhbGFuY2VzAAEFA25pbAUDU0VQBQNuaWwArQG37A==", "height": 2411705, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 5KcT4xXUZVYQvXbnho3Vpc9Qt8aJnW7u3fDe8r8y7Ch6 Next: CNjDxuPevRC6iUYR6Ym6yWH57kkKV7NWCpwpCpgSF6mF Diff:
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | - | let a = | |
4 | + | let a = take(drop(this.bytes, 1), 1) | |
5 | 5 | ||
6 | 6 | let b = { | |
7 | 7 | let c = a | |
8 | - | if (( | |
8 | + | if ((base58'2W' == c)) | |
9 | 9 | then base58'DG2xFkPdDwKUoBkzGAhQtLpSGzfXLiCYPEzeKH2Ad24p' | |
10 | - | else if (( | |
10 | + | else if ((base58'2T' == c)) | |
11 | 11 | then base58'HezsdQuRDtzksAYUy97gfhKy7Z1NW2uXYSHA3bgqenNZ' | |
12 | 12 | else throw("Unknown chain") | |
13 | 13 | } | |
14 | 14 | ||
15 | 15 | let d = addressFromStringValue({ | |
16 | 16 | let c = a | |
17 | - | if (( | |
17 | + | if ((base58'2W' == c)) | |
18 | 18 | then "3P2sk1KncSxRaZs8b4CWGPw2jkvvav74u4D" | |
19 | - | else if (( | |
19 | + | else if ((base58'2T' == c)) | |
20 | 20 | then "3N8y4wxX3JC4TdrCJBXX16SjWf6X256hrep" | |
21 | 21 | else throw("Unknown chain") | |
22 | 22 | }) | |
23 | 23 | ||
24 | 24 | let e = addressFromStringValue({ | |
25 | 25 | let c = a | |
26 | - | if (( | |
26 | + | if ((base58'2W' == c)) | |
27 | 27 | then "3PLncXtS1U83D6cQbFD3H8rBHPLgzxSFKZ1" | |
28 | - | else if (( | |
28 | + | else if ((base58'2T' == c)) | |
29 | 29 | then "3NDCyBG5q85JuaRiigUeEtainyjCQT3XpZm" | |
30 | 30 | else throw("Unknown chain") | |
31 | 31 | }) | |
32 | 32 | ||
33 | 33 | let f = { | |
34 | 34 | let c = a | |
35 | - | if (( | |
35 | + | if ((base58'2W' == c)) | |
36 | 36 | then 6307198406 | |
37 | - | else if (( | |
37 | + | else if ((base58'2T' == c)) | |
38 | 38 | then 63071984 | |
39 | 39 | else throw("Unknown chain") | |
40 | 40 | } | |
247 | 247 | } | |
248 | 248 | else $Tuple4("", "", -1, "") | |
249 | 249 | let ap = ac(ad) | |
250 | - | $Tuple2(nil, [("%s%d__stakedTime__" + toString(ar)), ("%s%s__owner__" + as), ("%s%s__description__" + az), ("%s%d__infraLevel__" + toString(aA._1)), ("%s% | |
250 | + | $Tuple2(nil, [("%s%d__stakedTime__" + toString(ar)), ("%s%s__owner__" + as), ("%s%s__description__" + az), ("%s%d__infraLevel__" + toString(aA._1)), makeString(["%s%s", "landArtefacts", ("PRESALE:" + toString(aA._2))], i), ("%s%s__availRes__" + aD), ("%s%s__needMaterial__" + aF), ("%s%s__duckAssetId__" + aG._1), ("%s%s__location__" + aG._2), ("%s%d__health__" + toString(aG._3)), ("%s%s__backPack__" + aG._4), makeString(["%s%d%d", "wallet", toString(ap[0]), toString(ap[1])], i)]) | |
251 | 251 | } | |
252 | 252 | } | |
253 | 253 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | - | let a = | |
4 | + | let a = take(drop(this.bytes, 1), 1) | |
5 | 5 | ||
6 | 6 | let b = { | |
7 | 7 | let c = a | |
8 | - | if (( | |
8 | + | if ((base58'2W' == c)) | |
9 | 9 | then base58'DG2xFkPdDwKUoBkzGAhQtLpSGzfXLiCYPEzeKH2Ad24p' | |
10 | - | else if (( | |
10 | + | else if ((base58'2T' == c)) | |
11 | 11 | then base58'HezsdQuRDtzksAYUy97gfhKy7Z1NW2uXYSHA3bgqenNZ' | |
12 | 12 | else throw("Unknown chain") | |
13 | 13 | } | |
14 | 14 | ||
15 | 15 | let d = addressFromStringValue({ | |
16 | 16 | let c = a | |
17 | - | if (( | |
17 | + | if ((base58'2W' == c)) | |
18 | 18 | then "3P2sk1KncSxRaZs8b4CWGPw2jkvvav74u4D" | |
19 | - | else if (( | |
19 | + | else if ((base58'2T' == c)) | |
20 | 20 | then "3N8y4wxX3JC4TdrCJBXX16SjWf6X256hrep" | |
21 | 21 | else throw("Unknown chain") | |
22 | 22 | }) | |
23 | 23 | ||
24 | 24 | let e = addressFromStringValue({ | |
25 | 25 | let c = a | |
26 | - | if (( | |
26 | + | if ((base58'2W' == c)) | |
27 | 27 | then "3PLncXtS1U83D6cQbFD3H8rBHPLgzxSFKZ1" | |
28 | - | else if (( | |
28 | + | else if ((base58'2T' == c)) | |
29 | 29 | then "3NDCyBG5q85JuaRiigUeEtainyjCQT3XpZm" | |
30 | 30 | else throw("Unknown chain") | |
31 | 31 | }) | |
32 | 32 | ||
33 | 33 | let f = { | |
34 | 34 | let c = a | |
35 | - | if (( | |
35 | + | if ((base58'2W' == c)) | |
36 | 36 | then 6307198406 | |
37 | - | else if (( | |
37 | + | else if ((base58'2T' == c)) | |
38 | 38 | then 63071984 | |
39 | 39 | else throw("Unknown chain") | |
40 | 40 | } | |
41 | 41 | ||
42 | 42 | let g = "LAND" | |
43 | 43 | ||
44 | 44 | let h = "DUCK" | |
45 | 45 | ||
46 | 46 | let i = "__" | |
47 | 47 | ||
48 | 48 | let j = "PRESALE" | |
49 | 49 | ||
50 | 50 | let k = 3456000 | |
51 | 51 | ||
52 | 52 | let l = 86400000 | |
53 | 53 | ||
54 | 54 | let m = 6 | |
55 | 55 | ||
56 | 56 | let n = 25 | |
57 | 57 | ||
58 | 58 | let o = 100 | |
59 | 59 | ||
60 | 60 | let p = 225 | |
61 | 61 | ||
62 | 62 | let q = 400 | |
63 | 63 | ||
64 | 64 | let r = 625 | |
65 | 65 | ||
66 | 66 | let s = 0 | |
67 | 67 | ||
68 | 68 | let t = 1 | |
69 | 69 | ||
70 | 70 | let u = 2 | |
71 | 71 | ||
72 | 72 | let v = 3 | |
73 | 73 | ||
74 | 74 | func w (x) = ("duckOwner_" + x) | |
75 | 75 | ||
76 | 76 | ||
77 | 77 | func y (x) = ("stakedTime_" + x) | |
78 | 78 | ||
79 | 79 | ||
80 | 80 | func z (A) = ("stakedDuckByOwner_" + A) | |
81 | 81 | ||
82 | 82 | ||
83 | 83 | func B (C,x,A) = ((((("stakedTimeByTypeAssetIdAndOwner_" + C) + "_") + x) + "_") + A) | |
84 | 84 | ||
85 | 85 | ||
86 | 86 | func D (E) = ("backPack_" + E) | |
87 | 87 | ||
88 | 88 | ||
89 | 89 | func F (E) = ("duckLocation_" + E) | |
90 | 90 | ||
91 | 91 | ||
92 | 92 | func G (E) = ("duckHealth_" + E) | |
93 | 93 | ||
94 | 94 | ||
95 | 95 | func H (x) = ("nftOwner_" + x) | |
96 | 96 | ||
97 | 97 | ||
98 | 98 | func I (x) = ("infraLevel_" + x) | |
99 | 99 | ||
100 | 100 | ||
101 | 101 | func J (K,x) = makeString(["landArtStatus", K, x], "_") | |
102 | 102 | ||
103 | 103 | ||
104 | 104 | func L (x) = ("presaleArtActivated_" + x) | |
105 | 105 | ||
106 | 106 | ||
107 | 107 | func M (N) = { | |
108 | 108 | let c = N | |
109 | 109 | if ($isInstanceOf(c, "List[Any]")) | |
110 | 110 | then { | |
111 | 111 | let O = c | |
112 | 112 | if ((size(O) != m)) | |
113 | 113 | then throw(("Array size is " + toString(size(O)))) | |
114 | 114 | else { | |
115 | 115 | func P (Q,R) = { | |
116 | 116 | let S = R | |
117 | 117 | if ($isInstanceOf(S, "Int")) | |
118 | 118 | then { | |
119 | 119 | let T = S | |
120 | 120 | (Q :+ toString(T)) | |
121 | 121 | } | |
122 | 122 | else throw("List type is not Int") | |
123 | 123 | } | |
124 | 124 | ||
125 | 125 | let U = { | |
126 | 126 | let V = O | |
127 | 127 | let W = size(V) | |
128 | 128 | let X = nil | |
129 | 129 | func Y (Z,aa) = if ((aa >= W)) | |
130 | 130 | then Z | |
131 | 131 | else P(Z, V[aa]) | |
132 | 132 | ||
133 | 133 | func ab (Z,aa) = if ((aa >= W)) | |
134 | 134 | then Z | |
135 | 135 | else throw("List size exceeds 6") | |
136 | 136 | ||
137 | 137 | ab(Y(Y(Y(Y(Y(Y(X, 0), 1), 2), 3), 4), 5), 6) | |
138 | 138 | } | |
139 | 139 | makeString(U, "_") | |
140 | 140 | } | |
141 | 141 | } | |
142 | 142 | else throw("fail to cast into List") | |
143 | 143 | } | |
144 | 144 | ||
145 | 145 | ||
146 | 146 | func ac (ad) = { | |
147 | 147 | let ae = addressFromString(ad) | |
148 | 148 | let af = if (isDefined(ae)) | |
149 | 149 | then wavesBalance(value(ae)) | |
150 | 150 | else BalanceDetails(0, 0, 0, 0) | |
151 | 151 | let ag = if (isDefined(ae)) | |
152 | 152 | then assetBalance(value(ae), b) | |
153 | 153 | else 0 | |
154 | 154 | [af.available, ag] | |
155 | 155 | } | |
156 | 156 | ||
157 | 157 | ||
158 | 158 | func ah (ai,aj) = { | |
159 | 159 | let ak = valueOrElse(getInteger(e, I(ai)), 0) | |
160 | 160 | let al = valueOrElse(getInteger(e, J(j, ai)), if (valueOrElse(getBoolean(e, L(ai)), false)) | |
161 | 161 | then aj | |
162 | 162 | else 0) | |
163 | 163 | $Tuple3(ak, al, ((k + fraction(k, ak, 4)) + fraction(k, (al * 3), (aj * 20)))) | |
164 | 164 | } | |
165 | 165 | ||
166 | 166 | ||
167 | 167 | func am (an) = { | |
168 | 168 | let c = an | |
169 | 169 | if (("S" == c)) | |
170 | 170 | then n | |
171 | 171 | else if (("M" == c)) | |
172 | 172 | then o | |
173 | 173 | else if (("L" == c)) | |
174 | 174 | then p | |
175 | 175 | else if (("XL" == c)) | |
176 | 176 | then q | |
177 | 177 | else if (("XXL" == c)) | |
178 | 178 | then r | |
179 | 179 | else throw("Unknown land size") | |
180 | 180 | } | |
181 | 181 | ||
182 | 182 | ||
183 | 183 | @Callable(ao) | |
184 | 184 | func walletInfoREADONLY (ad) = { | |
185 | 185 | let ap = ac(ad) | |
186 | 186 | $Tuple2(nil, makeString(["%s%d%d", "wallet", toString(ap[0]), toString(ap[1])], i)) | |
187 | 187 | } | |
188 | 188 | ||
189 | 189 | ||
190 | 190 | ||
191 | 191 | @Callable(ao) | |
192 | 192 | func duckInfoREADONLY (E,ad) = { | |
193 | 193 | let ae = addressFromString(ad) | |
194 | 194 | let aq = fromBase58String(E) | |
195 | 195 | if ((E == "")) | |
196 | 196 | then throw("duckAssetId is required") | |
197 | 197 | else { | |
198 | 198 | let ar = valueOrElse(getInteger(e, y(E)), 0) | |
199 | 199 | let as = if ((ar > 0)) | |
200 | 200 | then value(getString(e, w(E))) | |
201 | 201 | else if (if (isDefined(ae)) | |
202 | 202 | then (assetBalance(value(ae), aq) == 1) | |
203 | 203 | else false) | |
204 | 204 | then ad | |
205 | 205 | else throw("unknown owner") | |
206 | 206 | let at = value(assetInfo(aq)) | |
207 | 207 | let au = at.name | |
208 | 208 | let av = valueOrElse(getString(e, F(E)), "") | |
209 | 209 | let aw = valueOrElse(getInteger(e, G(E)), -1) | |
210 | 210 | let ax = valueOrElse(getString(e, D(E)), "0:0_0_0_0_0_0:0_0_0_0_0_0:") | |
211 | 211 | let ap = ac(ad) | |
212 | 212 | $Tuple2(nil, [("%s%d__stakedTime__" + toString(ar)), ("%s%s__owner__" + as), ("%s%s__name__" + au), ("%s%s__location__" + av), ("%s%d__health__" + toString(aw)), ("%s%s__backPack__" + ax), makeString(["%s%d%d", "wallet", toString(ap[0]), toString(ap[1])], i)]) | |
213 | 213 | } | |
214 | 214 | } | |
215 | 215 | ||
216 | 216 | ||
217 | 217 | ||
218 | 218 | @Callable(ao) | |
219 | 219 | func landInfoREADONLY (ai,ad) = { | |
220 | 220 | let ae = addressFromString(ad) | |
221 | 221 | let ay = fromBase58String(ai) | |
222 | 222 | if ((ai == "")) | |
223 | 223 | then throw("landAssetId is required") | |
224 | 224 | else { | |
225 | 225 | let ar = valueOrElse(getInteger(e, y(ai)), 0) | |
226 | 226 | let as = if ((ar > 0)) | |
227 | 227 | then value(getString(e, H(ai))) | |
228 | 228 | else if (if (isDefined(ae)) | |
229 | 229 | then (assetBalance(value(ae), ay) == 1) | |
230 | 230 | else false) | |
231 | 231 | then ad | |
232 | 232 | else "" | |
233 | 233 | let az = value(assetInfo(ay)).description | |
234 | 234 | let aj = am(split(az, "_")[t]) | |
235 | 235 | let aA = ah(ai, aj) | |
236 | 236 | let aB = (lastBlock.timestamp - ar) | |
237 | 237 | let aC = fraction(aB, (aA._3 * aj), l) | |
238 | 238 | let aD = if ((ar > 0)) | |
239 | 239 | then M(invoke(e, "splitByProportionsREADONLY", [aC], nil)) | |
240 | 240 | else "" | |
241 | 241 | let aE = fraction(f, (aj * (aA._1 + 1)), n) | |
242 | 242 | let aF = M(invoke(e, "splitByProportionsREADONLY", [aE], nil)) | |
243 | 243 | let aG = if (isDefined(ae)) | |
244 | 244 | then { | |
245 | 245 | let E = value(getString(e, z(ad))) | |
246 | 246 | $Tuple4(E, valueOrElse(getString(e, F(E)), ""), valueOrElse(getInteger(e, G(E)), -1), valueOrElse(getString(e, D(E)), "0:0_0_0_0_0_0:0_0_0_0_0_0:")) | |
247 | 247 | } | |
248 | 248 | else $Tuple4("", "", -1, "") | |
249 | 249 | let ap = ac(ad) | |
250 | - | $Tuple2(nil, [("%s%d__stakedTime__" + toString(ar)), ("%s%s__owner__" + as), ("%s%s__description__" + az), ("%s%d__infraLevel__" + toString(aA._1)), ("%s% | |
250 | + | $Tuple2(nil, [("%s%d__stakedTime__" + toString(ar)), ("%s%s__owner__" + as), ("%s%s__description__" + az), ("%s%d__infraLevel__" + toString(aA._1)), makeString(["%s%s", "landArtefacts", ("PRESALE:" + toString(aA._2))], i), ("%s%s__availRes__" + aD), ("%s%s__needMaterial__" + aF), ("%s%s__duckAssetId__" + aG._1), ("%s%s__location__" + aG._2), ("%s%d__health__" + toString(aG._3)), ("%s%s__backPack__" + aG._4), makeString(["%s%d%d", "wallet", toString(ap[0]), toString(ap[1])], i)]) | |
251 | 251 | } | |
252 | 252 | } | |
253 | 253 | ||
254 | 254 |
github/deemru/w8io/026f985 46.14 ms ◑