tx · 8BxwmeViHPzVizosVW5M3V4xLwkVece7uM5UAkcPQT7T 3N7HtrKeFFLz5oy6PfGv1Lg3GwPk4gCPdGy: -0.01100000 Waves 2023.06.29 23:31 [2644416] smart account 3N7HtrKeFFLz5oy6PfGv1Lg3GwPk4gCPdGy > SELF 0.00000000 Waves
{ "type": 13, "id": "8BxwmeViHPzVizosVW5M3V4xLwkVece7uM5UAkcPQT7T", "fee": 1100000, "feeAssetId": null, "timestamp": 1688070733104, "version": 2, "chainId": 84, "sender": "3N7HtrKeFFLz5oy6PfGv1Lg3GwPk4gCPdGy", "senderPublicKey": "FsR18761ZAsUqsTd7TK3XmR6bhihs1UXVmpHYxz5JzQ1", "proofs": [ "4ZRYaYBJg91JqUUZ7dj5domM5p3GMQ8r95rz6WBXHfBVH4pYXdtqpb3ecHbze2jbPjfwLsSdMLQcQf98D2cdDCFD" ], "script": "base64:BgIZCAISBQoDCAgIEgASABIAEgMKAQgSAwoBCEIBCmtleUJsb2NrZWQAAhBjb250cmFjdHNCbG9ja2VkAAtJZHhFZmZUb3RhbAAAAApJZHhFZmZVc2VyAAEABWNoYWluCQDJAQIJAMoBAggFBHRoaXMFYnl0ZXMAAQABAAt1c2R0QXNzZXRJZAQHJG1hdGNoMAUFY2hhaW4DCQAAAgEBVwUHJG1hdGNoMAEghNp6sggDP07Ru8qO7ouTvMmC3Qtd+geWqNQj+agP/7kDCQAAAgEBVAUHJG1hdGNoMAEgVbHYn3KHgu/l41uNrAWrZd6aQ6EvFrsF8xq3h6XxxRgJAAIBAg1Vbmtub3duIGNoYWluABVkZWZhdWx0UmVzdEFkZHJlc3NTdHIEByRtYXRjaDAFBWNoYWluAwkAAAIBAVcFByRtYXRjaDACIzNQUUN1dkZidmg0TGtQVW5yblUxejNqbmJBMXA5bTNXTmh2AwkAAAIBAVQFByRtYXRjaDACIzNNdW1rR0d6dENLQVhwV0RxeGtkZG9mcVhTVWJxUWt2U0p5CQACAQINVW5rbm93biBjaGFpbgAOYXJiaXR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yYWN0CQACAQIRUGVybWlzc2lvbiBkZW5pZWQJAJQKAgkAzAgCCQELRGVsZXRlRW50cnkBCQEYa2V5TGFzdENsYWltZWRUaW1lQnlVc2VyAQUEYWRkcgUDbmlsAAAArlmLqw==", "height": 2644416, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 3RGwQj4cUoEMVvJbuDmiiqREfYbdCAdSFUape7GHDtVY Next: AHMNGC3CAwwpLGD94tHVmMCM7HjxvbZtfp87jUJ3gu2m Diff:
Old | New | Differences | |
---|---|---|---|
98 | 98 | ||
99 | 99 | let N = "wlg_issuedAmount" | |
100 | 100 | ||
101 | - | let O = | |
101 | + | let O = "wlg_assetId" | |
102 | 102 | ||
103 | - | let P = | |
103 | + | let P = valueOrErrorMessage(getBinary(O), "Not initialized yet") | |
104 | 104 | ||
105 | - | let Q = | |
105 | + | let Q = 0 | |
106 | 106 | ||
107 | - | func R (S) = { | |
108 | - | let f = S | |
107 | + | let R = 1 | |
108 | + | ||
109 | + | let S = 2 | |
110 | + | ||
111 | + | func T (U) = { | |
112 | + | let f = U | |
109 | 113 | if ($isInstanceOf(f, "Int")) | |
110 | 114 | then { | |
111 | - | let | |
112 | - | | |
115 | + | let V = f | |
116 | + | V | |
113 | 117 | } | |
114 | 118 | else throw("fail to cast into Int") | |
115 | 119 | } | |
116 | 120 | ||
117 | 121 | ||
118 | - | func | |
119 | - | let f = | |
122 | + | func W (X) = { | |
123 | + | let f = X | |
120 | 124 | if (("S" == f)) | |
121 | 125 | then l | |
122 | 126 | else if (("M" == f)) | |
131 | 135 | } | |
132 | 136 | ||
133 | 137 | ||
134 | - | func | |
135 | - | let | |
136 | - | func | |
138 | + | func Y (Z) = { | |
139 | + | let aa = split(valueOrElse(getString(F, K()), "0_0_0_0_0_0"), "_") | |
140 | + | func ab (ac,ad) = (ac + parseIntValue(ad)) | |
137 | 141 | ||
138 | - | let | |
139 | - | let | |
140 | - | let | |
141 | - | let | |
142 | - | func | |
143 | - | then | |
144 | - | else | |
142 | + | let ae = { | |
143 | + | let af = aa | |
144 | + | let ag = size(af) | |
145 | + | let ah = 0 | |
146 | + | func ai (aj,ak) = if ((ak >= ag)) | |
147 | + | then aj | |
148 | + | else ab(aj, af[ak]) | |
145 | 149 | ||
146 | - | func | |
147 | - | then | |
150 | + | func al (aj,ak) = if ((ak >= ag)) | |
151 | + | then aj | |
148 | 152 | else throw("List size exceeds 6") | |
149 | 153 | ||
150 | - | | |
154 | + | al(ai(ai(ai(ai(ai(ai(ah, 0), 1), 2), 3), 4), 5), 6) | |
151 | 155 | } | |
152 | - | let | |
156 | + | let am = if ((Z == "")) | |
153 | 157 | then 0 | |
154 | 158 | else { | |
155 | - | let | |
156 | - | let | |
157 | - | then split_51C(value( | |
159 | + | let an = getString(F, L(Z)) | |
160 | + | let ao = if (isDefined(an)) | |
161 | + | then split_51C(value(an), "_") | |
158 | 162 | else nil | |
159 | - | func | |
160 | - | let | |
161 | - | let | |
162 | - | ( | |
163 | + | func ap (ac,aq) = { | |
164 | + | let ar = value(assetInfo(fromBase58String(aq))) | |
165 | + | let X = split(ar.description, "_")[J] | |
166 | + | (ac + W(X)) | |
163 | 167 | } | |
164 | 168 | ||
165 | - | let | |
166 | - | let | |
167 | - | let | |
168 | - | func | |
169 | - | then | |
170 | - | else | |
169 | + | let af = ao | |
170 | + | let ag = size(af) | |
171 | + | let ah = 0 | |
172 | + | func as (aj,ak) = if ((ak >= ag)) | |
173 | + | then aj | |
174 | + | else ap(aj, af[ak]) | |
171 | 175 | ||
172 | - | func | |
173 | - | then | |
176 | + | func at (aj,ak) = if ((ak >= ag)) | |
177 | + | then aj | |
174 | 178 | else throw("List size exceeds 100") | |
175 | 179 | ||
176 | - | | |
180 | + | at(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(ah, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20), 21), 22), 23), 24), 25), 26), 27), 28), 29), 30), 31), 32), 33), 34), 35), 36), 37), 38), 39), 40), 41), 42), 43), 44), 45), 46), 47), 48), 49), 50), 51), 52), 53), 54), 55), 56), 57), 58), 59), 60), 61), 62), 63), 64), 65), 66), 67), 68), 69), 70), 71), 72), 73), 74), 75), 76), 77), 78), 79), 80), 81), 82), 83), 84), 85), 86), 87), 88), 89), 90), 91), 92), 93), 94), 95), 96), 97), 98), 99), 100) | |
177 | 181 | } | |
178 | - | [ | |
182 | + | [ae, am] | |
179 | 183 | } | |
180 | 184 | ||
181 | 185 | ||
182 | - | func | |
183 | - | let | |
184 | - | let | |
185 | - | let | |
186 | - | let | |
187 | - | let | |
188 | - | let | |
189 | - | [ | |
186 | + | func au () = { | |
187 | + | let av = valueOrErrorMessage(getInteger(H, N), "WLGOLD is not issued yet") | |
188 | + | let aw = assetBalance(G, e) | |
189 | + | let ax = assetBalance(E, e) | |
190 | + | let ay = assetBalance(H, e) | |
191 | + | let az = assetBalance(I, e) | |
192 | + | let aA = (((aw + ax) + ay) + az) | |
193 | + | [av, fraction(aA, k, av), aA, aw, ax, ay, az] | |
190 | 194 | } | |
191 | 195 | ||
192 | 196 | ||
193 | - | let az = 100000000000000 | |
194 | - | ||
195 | - | let aA = 100000 | |
196 | - | ||
197 | - | let aB = 200000 | |
197 | + | let aB = 100000000000000 | |
198 | 198 | ||
199 | 199 | let aC = 100000 | |
200 | 200 | ||
201 | - | let aD = | |
201 | + | let aD = 200000 | |
202 | 202 | ||
203 | - | let aE = | |
203 | + | let aE = 100000 | |
204 | 204 | ||
205 | - | let aF = | |
205 | + | let aF = 400000 | |
206 | 206 | ||
207 | - | let aG = | |
207 | + | let aG = 31557600000 | |
208 | 208 | ||
209 | - | let aH = | |
209 | + | let aH = 604800000 | |
210 | 210 | ||
211 | - | let aI = | |
211 | + | let aI = 156 | |
212 | 212 | ||
213 | - | let aJ = | |
213 | + | let aJ = 100000000 | |
214 | 214 | ||
215 | - | let aK = | |
215 | + | let aK = 50000000 | |
216 | 216 | ||
217 | - | let aL = " | |
217 | + | let aL = "wlg_issueTime" | |
218 | 218 | ||
219 | - | let aM = " | |
219 | + | let aM = "marketingAddr" | |
220 | 220 | ||
221 | - | let aN = " | |
221 | + | let aN = "teamAddr" | |
222 | 222 | ||
223 | - | let aO = "lastClaimedTime_ | |
223 | + | let aO = "lastClaimedTime_marketing" | |
224 | 224 | ||
225 | - | let aP = "lastClaimedTime_ | |
225 | + | let aP = "lastClaimedTime_team" | |
226 | 226 | ||
227 | - | func aQ (aR) = ("lastClaimedTimeUser_" + aR) | |
227 | + | let aQ = "lastClaimedTime_activities" | |
228 | + | ||
229 | + | func aR (aS) = ("lastClaimedTimeUser_" + aS) | |
228 | 230 | ||
229 | 231 | ||
230 | - | func | |
232 | + | func aT (aS) = ("lastArbTimeUser_" + aS) | |
231 | 233 | ||
232 | 234 | ||
233 | - | let | |
235 | + | let aU = "stakersAmountLeft" | |
234 | 236 | ||
235 | - | let | |
237 | + | let aV = "stakersAmountPaidTotal" | |
236 | 238 | ||
237 | - | func | |
239 | + | func aW (aS) = ("stakersAmountPaidUser_" + aS) | |
238 | 240 | ||
239 | - | ||
240 | - | let aW = valueOrErrorMessage(getBinary(aJ), "Not initialized yet") | |
241 | 241 | ||
242 | 242 | func aX () = if (valueOrElse(getBoolean(F, a()), false)) | |
243 | 243 | then throw("Contracts are under maintenance") | |
244 | - | else | |
244 | + | else T(invoke(F, "saveLastTx", nil, nil)) | |
245 | 245 | ||
246 | 246 | ||
247 | - | func aY ( | |
248 | - | let aZ = valueOrElse(getInteger(aS | |
247 | + | func aY (aS) = { | |
248 | + | let aZ = valueOrElse(getInteger(aT(aS)), 0) | |
249 | 249 | let ba = lastBlock.timestamp | |
250 | 250 | if ((h > (ba - aZ))) | |
251 | 251 | then throw("Arbitrages are possible once a 10 minutes") | |
252 | 252 | else { | |
253 | - | let bb = | |
254 | - | let bc = pow(bb, 0, | |
255 | - | fraction( | |
253 | + | let bb = Y(aS)[c] | |
254 | + | let bc = pow(bb, 0, aK, 8, 8, CEILING) | |
255 | + | fraction(aJ, bc, k) | |
256 | 256 | } | |
257 | 257 | } | |
258 | 258 | ||
260 | 260 | @Callable(bd) | |
261 | 261 | func constructorV1 (be,bf,bg) = if ((bd.caller != this)) | |
262 | 262 | then throw("Permission denied") | |
263 | - | else if (isDefined(getBinary( | |
263 | + | else if (isDefined(getBinary(O))) | |
264 | 264 | then throw("Already initialized") | |
265 | 265 | else { | |
266 | - | let | |
267 | - | let bh = Issue("WLGOLD", "WavesLands Gold investment token", | |
266 | + | let av = aB | |
267 | + | let bh = Issue("WLGOLD", "WavesLands Gold investment token", av, 8, true, unit, 0) | |
268 | 268 | let bi = calculateAssetId(bh) | |
269 | - | [bh, IntegerEntry( | |
269 | + | [bh, IntegerEntry(aL, lastBlock.timestamp), IntegerEntry(N, av), IntegerEntry(aV, 0), IntegerEntry(aU, fraction(aB, aF, j)), BinaryEntry(O, bi), StringEntry(y(), be), StringEntry(aM, bf), StringEntry(aN, bg)] | |
270 | 270 | } | |
271 | 271 | ||
272 | 272 | ||
284 | 284 | then throw("USDT payments only!") | |
285 | 285 | else { | |
286 | 286 | let bn = bd.caller | |
287 | - | let | |
288 | - | let bo = aY( | |
287 | + | let aS = toString(bn) | |
288 | + | let bo = aY(aS) | |
289 | 289 | if ((bl > bo)) | |
290 | 290 | then throw((("You can spend max " + toString(bo)) + " USDT")) | |
291 | 291 | else { | |
292 | - | let bp = | |
293 | - | let bq = bp[ | |
294 | - | let br = fraction(bp[ | |
292 | + | let bp = au() | |
293 | + | let bq = bp[Q] | |
294 | + | let br = fraction(bp[R], 6, 5) | |
295 | 295 | let bs = fraction(bl, k, br) | |
296 | - | let bt = fraction(bl, bq, (bp[ | |
297 | - | $Tuple2([Reissue( | |
296 | + | let bt = fraction(bl, bq, (bp[S] - bl)) | |
297 | + | $Tuple2([Reissue(P, bt, true), IntegerEntry(N, (bq + bt)), IntegerEntry(aT(aS), lastBlock.timestamp), ScriptTransfer(bn, bs, P)], bj) | |
298 | 298 | } | |
299 | 299 | } | |
300 | 300 | } | |
311 | 311 | let bk = bd.payments[0] | |
312 | 312 | let bu = bk.amount | |
313 | 313 | let bm = valueOrErrorMessage(bk.assetId, "WAVES can't be used as payment") | |
314 | - | if ((bm != | |
314 | + | if ((bm != P)) | |
315 | 315 | then throw("WLGOLD payments only!") | |
316 | 316 | else { | |
317 | 317 | let bn = bd.caller | |
318 | - | let | |
319 | - | let bo = aY( | |
320 | - | let bp = | |
321 | - | let bq = (bp[ | |
322 | - | let bv = fraction(bp[ | |
318 | + | let aS = toString(bn) | |
319 | + | let bo = aY(aS) | |
320 | + | let bp = au() | |
321 | + | let bq = (bp[Q] - bu) | |
322 | + | let bv = fraction(bp[R], 4, 5) | |
323 | 323 | let bw = fraction(bu, bv, k) | |
324 | 324 | if ((bw > bo)) | |
325 | 325 | then throw((("You can get max " + toString(bo)) + " USDT")) | |
326 | 326 | else { | |
327 | - | let bx = fraction(bw, bq, bp[ | |
328 | - | $Tuple2([Burn( | |
327 | + | let bx = fraction(bw, bq, bp[S]) | |
328 | + | $Tuple2([Burn(P, bx), IntegerEntry(N, (bq - bx)), IntegerEntry(aT(aS), lastBlock.timestamp), ScriptTransfer(bn, bw, e)], bj) | |
329 | 329 | } | |
330 | 330 | } | |
331 | 331 | } | |
339 | 339 | let bn = bd.caller | |
340 | 340 | let by = toString(bn) | |
341 | 341 | let ba = lastBlock.timestamp | |
342 | - | let bz = valueOrErrorMessage(getInteger( | |
343 | - | let bA = valueOrElse(getInteger( | |
344 | - | let bf = addressFromStringValue(value(getString( | |
345 | - | let bB = fraction(fraction( | |
346 | - | let bC = valueOrElse(getInteger( | |
347 | - | let bg = addressFromStringValue(value(getString( | |
348 | - | let bD = fraction(fraction( | |
349 | - | let bE = valueOrElse(getInteger( | |
350 | - | let bF = fraction(fraction( | |
351 | - | let bG = ((ba - bz) / | |
352 | - | if ((bG > ( | |
342 | + | let bz = valueOrErrorMessage(getInteger(aL), "Not initialized") | |
343 | + | let bA = valueOrElse(getInteger(aO), bz) | |
344 | + | let bf = addressFromStringValue(value(getString(aM))) | |
345 | + | let bB = fraction(fraction(aB, aC, j), (ba - bA), aG) | |
346 | + | let bC = valueOrElse(getInteger(aP), bz) | |
347 | + | let bg = addressFromStringValue(value(getString(aN))) | |
348 | + | let bD = fraction(fraction(aB, aD, j), (ba - bC), (3 * aG)) | |
349 | + | let bE = valueOrElse(getInteger(aQ), bz) | |
350 | + | let bF = fraction(fraction(aB, aE, j), (ba - bE), (3 * aG)) | |
351 | + | let bG = ((ba - bz) / aH) | |
352 | + | if ((bG > (aI / 2))) | |
353 | 353 | then throw("Please modify contract for next 1.5 years, according to stats") | |
354 | 354 | else { | |
355 | - | let bH = | |
355 | + | let bH = Y(by) | |
356 | 356 | let bI = bH[b] | |
357 | - | let bJ = valueOrElse(getInteger( | |
358 | - | let bK = fraction(bJ, (2 * bI), (bI + (max([100000, bI]) * ( | |
359 | - | let bL = | |
357 | + | let bJ = valueOrElse(getInteger(aU), 0) | |
358 | + | let bK = fraction(bJ, (2 * bI), (bI + (max([100000, bI]) * (aI - bG)))) | |
359 | + | let bL = aR(by) | |
360 | 360 | let bM = valueOrElse(getInteger(bL), bz) | |
361 | - | let bN = fraction(fraction(bK, bH[c], bI), (ba - bM), (3 * | |
362 | - | let bO = | |
363 | - | $Tuple2([ScriptTransfer(bf, bB, | |
361 | + | let bN = fraction(fraction(bK, bH[c], bI), (ba - bM), (3 * aG)) | |
362 | + | let bO = aW(by) | |
363 | + | $Tuple2([ScriptTransfer(bf, bB, P), ScriptTransfer(bg, bD, P), ScriptTransfer(E, bF, P), ScriptTransfer(bn, bN, P), IntegerEntry(bO, (valueOrElse(getInteger(bO), 0) + bN)), IntegerEntry(aV, (valueOrElse(getInteger(aV), 0) + bN)), IntegerEntry(aU, (bJ - bN)), IntegerEntry(aO, ba), IntegerEntry(aP, ba), IntegerEntry(aQ, ba), IntegerEntry(bL, ba)], bj) | |
364 | 364 | } | |
365 | 365 | } | |
366 | 366 | ||
367 | 367 | ||
368 | 368 | ||
369 | 369 | @Callable(bd) | |
370 | - | func onStakeLand ( | |
370 | + | func onStakeLand (aS) = if ((bd.caller != F)) | |
371 | 371 | then throw("Permission denied") | |
372 | - | else $Tuple2([IntegerEntry( | |
372 | + | else $Tuple2([IntegerEntry(aR(aS), lastBlock.timestamp)], lastBlock.timestamp) | |
373 | 373 | ||
374 | 374 | ||
375 | 375 | ||
376 | 376 | @Callable(bd) | |
377 | - | func onUnstakeLand ( | |
377 | + | func onUnstakeLand (aS) = if ((bd.caller != F)) | |
378 | 378 | then throw("Permission denied") | |
379 | - | else $Tuple2([DeleteEntry( | |
379 | + | else $Tuple2([DeleteEntry(aR(aS))], 0) | |
380 | 380 | ||
381 | 381 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | func a () = "contractsBlocked" | |
5 | 5 | ||
6 | 6 | ||
7 | 7 | let b = 0 | |
8 | 8 | ||
9 | 9 | let c = 1 | |
10 | 10 | ||
11 | 11 | let d = take(drop(this.bytes, 1), 1) | |
12 | 12 | ||
13 | 13 | let e = { | |
14 | 14 | let f = d | |
15 | 15 | if ((base58'2W' == f)) | |
16 | 16 | then base58'9wc3LXNA4TEBsXyKtoLE9mrbDD7WMHXvXrCjZvabLAsi' | |
17 | 17 | else if ((base58'2T' == f)) | |
18 | 18 | then base58'6mWwf9mZBjVgkC54idpyaZLQfAosD914wT8fGf2iiY63' | |
19 | 19 | else throw("Unknown chain") | |
20 | 20 | } | |
21 | 21 | ||
22 | 22 | let g = { | |
23 | 23 | let f = d | |
24 | 24 | if ((base58'2W' == f)) | |
25 | 25 | then "3PQCuvFbvh4LkPUnrnU1z3jnbA1p9m3WNhv" | |
26 | 26 | else if ((base58'2T' == f)) | |
27 | 27 | then "3MumkGGztCKAXpWDqxkddofqXSUbqQkvSJy" | |
28 | 28 | else throw("Unknown chain") | |
29 | 29 | } | |
30 | 30 | ||
31 | 31 | let h = { | |
32 | 32 | let f = d | |
33 | 33 | if ((base58'2W' == f)) | |
34 | 34 | then 600000 | |
35 | 35 | else if ((base58'2T' == f)) | |
36 | 36 | then 60000 | |
37 | 37 | else throw("Unknown chain") | |
38 | 38 | } | |
39 | 39 | ||
40 | 40 | let i = "__" | |
41 | 41 | ||
42 | 42 | let j = 1000000 | |
43 | 43 | ||
44 | 44 | let k = 100000000 | |
45 | 45 | ||
46 | 46 | let l = 25 | |
47 | 47 | ||
48 | 48 | let m = 100 | |
49 | 49 | ||
50 | 50 | let n = 225 | |
51 | 51 | ||
52 | 52 | let o = 400 | |
53 | 53 | ||
54 | 54 | let p = 625 | |
55 | 55 | ||
56 | 56 | func q (r,s) = valueOrErrorMessage(getString(r, s), makeString(["mandatory ", toString(r), ".", s, " is not defined"], "")) | |
57 | 57 | ||
58 | 58 | ||
59 | 59 | let t = 1 | |
60 | 60 | ||
61 | 61 | let u = 2 | |
62 | 62 | ||
63 | 63 | let v = 4 | |
64 | 64 | ||
65 | 65 | let w = 5 | |
66 | 66 | ||
67 | 67 | func x () = "%s__restConfig" | |
68 | 68 | ||
69 | 69 | ||
70 | 70 | func y () = "%s__restAddr" | |
71 | 71 | ||
72 | 72 | ||
73 | 73 | func z (A) = split_4C(q(A, x()), i) | |
74 | 74 | ||
75 | 75 | ||
76 | 76 | func B (C,D) = valueOrErrorMessage(addressFromString(C[D]), ("Rest cfg doesn't contain address at index " + toString(D))) | |
77 | 77 | ||
78 | 78 | ||
79 | 79 | let E = addressFromStringValue(valueOrElse(getString(this, y()), g)) | |
80 | 80 | ||
81 | 81 | let C = z(E) | |
82 | 82 | ||
83 | 83 | let F = B(C, t) | |
84 | 84 | ||
85 | 85 | let G = B(C, u) | |
86 | 86 | ||
87 | 87 | let H = B(C, v) | |
88 | 88 | ||
89 | 89 | let I = B(C, w) | |
90 | 90 | ||
91 | 91 | let J = 1 | |
92 | 92 | ||
93 | 93 | func K () = "resTypesProportions" | |
94 | 94 | ||
95 | 95 | ||
96 | 96 | func L (M) = ("stakedLandsByOwner_" + M) | |
97 | 97 | ||
98 | 98 | ||
99 | 99 | let N = "wlg_issuedAmount" | |
100 | 100 | ||
101 | - | let O = | |
101 | + | let O = "wlg_assetId" | |
102 | 102 | ||
103 | - | let P = | |
103 | + | let P = valueOrErrorMessage(getBinary(O), "Not initialized yet") | |
104 | 104 | ||
105 | - | let Q = | |
105 | + | let Q = 0 | |
106 | 106 | ||
107 | - | func R (S) = { | |
108 | - | let f = S | |
107 | + | let R = 1 | |
108 | + | ||
109 | + | let S = 2 | |
110 | + | ||
111 | + | func T (U) = { | |
112 | + | let f = U | |
109 | 113 | if ($isInstanceOf(f, "Int")) | |
110 | 114 | then { | |
111 | - | let | |
112 | - | | |
115 | + | let V = f | |
116 | + | V | |
113 | 117 | } | |
114 | 118 | else throw("fail to cast into Int") | |
115 | 119 | } | |
116 | 120 | ||
117 | 121 | ||
118 | - | func | |
119 | - | let f = | |
122 | + | func W (X) = { | |
123 | + | let f = X | |
120 | 124 | if (("S" == f)) | |
121 | 125 | then l | |
122 | 126 | else if (("M" == f)) | |
123 | 127 | then m | |
124 | 128 | else if (("L" == f)) | |
125 | 129 | then n | |
126 | 130 | else if (("XL" == f)) | |
127 | 131 | then o | |
128 | 132 | else if (("XXL" == f)) | |
129 | 133 | then p | |
130 | 134 | else throw("Unknown land size") | |
131 | 135 | } | |
132 | 136 | ||
133 | 137 | ||
134 | - | func | |
135 | - | let | |
136 | - | func | |
138 | + | func Y (Z) = { | |
139 | + | let aa = split(valueOrElse(getString(F, K()), "0_0_0_0_0_0"), "_") | |
140 | + | func ab (ac,ad) = (ac + parseIntValue(ad)) | |
137 | 141 | ||
138 | - | let | |
139 | - | let | |
140 | - | let | |
141 | - | let | |
142 | - | func | |
143 | - | then | |
144 | - | else | |
142 | + | let ae = { | |
143 | + | let af = aa | |
144 | + | let ag = size(af) | |
145 | + | let ah = 0 | |
146 | + | func ai (aj,ak) = if ((ak >= ag)) | |
147 | + | then aj | |
148 | + | else ab(aj, af[ak]) | |
145 | 149 | ||
146 | - | func | |
147 | - | then | |
150 | + | func al (aj,ak) = if ((ak >= ag)) | |
151 | + | then aj | |
148 | 152 | else throw("List size exceeds 6") | |
149 | 153 | ||
150 | - | | |
154 | + | al(ai(ai(ai(ai(ai(ai(ah, 0), 1), 2), 3), 4), 5), 6) | |
151 | 155 | } | |
152 | - | let | |
156 | + | let am = if ((Z == "")) | |
153 | 157 | then 0 | |
154 | 158 | else { | |
155 | - | let | |
156 | - | let | |
157 | - | then split_51C(value( | |
159 | + | let an = getString(F, L(Z)) | |
160 | + | let ao = if (isDefined(an)) | |
161 | + | then split_51C(value(an), "_") | |
158 | 162 | else nil | |
159 | - | func | |
160 | - | let | |
161 | - | let | |
162 | - | ( | |
163 | + | func ap (ac,aq) = { | |
164 | + | let ar = value(assetInfo(fromBase58String(aq))) | |
165 | + | let X = split(ar.description, "_")[J] | |
166 | + | (ac + W(X)) | |
163 | 167 | } | |
164 | 168 | ||
165 | - | let | |
166 | - | let | |
167 | - | let | |
168 | - | func | |
169 | - | then | |
170 | - | else | |
169 | + | let af = ao | |
170 | + | let ag = size(af) | |
171 | + | let ah = 0 | |
172 | + | func as (aj,ak) = if ((ak >= ag)) | |
173 | + | then aj | |
174 | + | else ap(aj, af[ak]) | |
171 | 175 | ||
172 | - | func | |
173 | - | then | |
176 | + | func at (aj,ak) = if ((ak >= ag)) | |
177 | + | then aj | |
174 | 178 | else throw("List size exceeds 100") | |
175 | 179 | ||
176 | - | | |
180 | + | at(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(as(ah, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20), 21), 22), 23), 24), 25), 26), 27), 28), 29), 30), 31), 32), 33), 34), 35), 36), 37), 38), 39), 40), 41), 42), 43), 44), 45), 46), 47), 48), 49), 50), 51), 52), 53), 54), 55), 56), 57), 58), 59), 60), 61), 62), 63), 64), 65), 66), 67), 68), 69), 70), 71), 72), 73), 74), 75), 76), 77), 78), 79), 80), 81), 82), 83), 84), 85), 86), 87), 88), 89), 90), 91), 92), 93), 94), 95), 96), 97), 98), 99), 100) | |
177 | 181 | } | |
178 | - | [ | |
182 | + | [ae, am] | |
179 | 183 | } | |
180 | 184 | ||
181 | 185 | ||
182 | - | func | |
183 | - | let | |
184 | - | let | |
185 | - | let | |
186 | - | let | |
187 | - | let | |
188 | - | let | |
189 | - | [ | |
186 | + | func au () = { | |
187 | + | let av = valueOrErrorMessage(getInteger(H, N), "WLGOLD is not issued yet") | |
188 | + | let aw = assetBalance(G, e) | |
189 | + | let ax = assetBalance(E, e) | |
190 | + | let ay = assetBalance(H, e) | |
191 | + | let az = assetBalance(I, e) | |
192 | + | let aA = (((aw + ax) + ay) + az) | |
193 | + | [av, fraction(aA, k, av), aA, aw, ax, ay, az] | |
190 | 194 | } | |
191 | 195 | ||
192 | 196 | ||
193 | - | let az = 100000000000000 | |
194 | - | ||
195 | - | let aA = 100000 | |
196 | - | ||
197 | - | let aB = 200000 | |
197 | + | let aB = 100000000000000 | |
198 | 198 | ||
199 | 199 | let aC = 100000 | |
200 | 200 | ||
201 | - | let aD = | |
201 | + | let aD = 200000 | |
202 | 202 | ||
203 | - | let aE = | |
203 | + | let aE = 100000 | |
204 | 204 | ||
205 | - | let aF = | |
205 | + | let aF = 400000 | |
206 | 206 | ||
207 | - | let aG = | |
207 | + | let aG = 31557600000 | |
208 | 208 | ||
209 | - | let aH = | |
209 | + | let aH = 604800000 | |
210 | 210 | ||
211 | - | let aI = | |
211 | + | let aI = 156 | |
212 | 212 | ||
213 | - | let aJ = | |
213 | + | let aJ = 100000000 | |
214 | 214 | ||
215 | - | let aK = | |
215 | + | let aK = 50000000 | |
216 | 216 | ||
217 | - | let aL = " | |
217 | + | let aL = "wlg_issueTime" | |
218 | 218 | ||
219 | - | let aM = " | |
219 | + | let aM = "marketingAddr" | |
220 | 220 | ||
221 | - | let aN = " | |
221 | + | let aN = "teamAddr" | |
222 | 222 | ||
223 | - | let aO = "lastClaimedTime_ | |
223 | + | let aO = "lastClaimedTime_marketing" | |
224 | 224 | ||
225 | - | let aP = "lastClaimedTime_ | |
225 | + | let aP = "lastClaimedTime_team" | |
226 | 226 | ||
227 | - | func aQ (aR) = ("lastClaimedTimeUser_" + aR) | |
227 | + | let aQ = "lastClaimedTime_activities" | |
228 | + | ||
229 | + | func aR (aS) = ("lastClaimedTimeUser_" + aS) | |
228 | 230 | ||
229 | 231 | ||
230 | - | func | |
232 | + | func aT (aS) = ("lastArbTimeUser_" + aS) | |
231 | 233 | ||
232 | 234 | ||
233 | - | let | |
235 | + | let aU = "stakersAmountLeft" | |
234 | 236 | ||
235 | - | let | |
237 | + | let aV = "stakersAmountPaidTotal" | |
236 | 238 | ||
237 | - | func | |
239 | + | func aW (aS) = ("stakersAmountPaidUser_" + aS) | |
238 | 240 | ||
239 | - | ||
240 | - | let aW = valueOrErrorMessage(getBinary(aJ), "Not initialized yet") | |
241 | 241 | ||
242 | 242 | func aX () = if (valueOrElse(getBoolean(F, a()), false)) | |
243 | 243 | then throw("Contracts are under maintenance") | |
244 | - | else | |
244 | + | else T(invoke(F, "saveLastTx", nil, nil)) | |
245 | 245 | ||
246 | 246 | ||
247 | - | func aY ( | |
248 | - | let aZ = valueOrElse(getInteger(aS | |
247 | + | func aY (aS) = { | |
248 | + | let aZ = valueOrElse(getInteger(aT(aS)), 0) | |
249 | 249 | let ba = lastBlock.timestamp | |
250 | 250 | if ((h > (ba - aZ))) | |
251 | 251 | then throw("Arbitrages are possible once a 10 minutes") | |
252 | 252 | else { | |
253 | - | let bb = | |
254 | - | let bc = pow(bb, 0, | |
255 | - | fraction( | |
253 | + | let bb = Y(aS)[c] | |
254 | + | let bc = pow(bb, 0, aK, 8, 8, CEILING) | |
255 | + | fraction(aJ, bc, k) | |
256 | 256 | } | |
257 | 257 | } | |
258 | 258 | ||
259 | 259 | ||
260 | 260 | @Callable(bd) | |
261 | 261 | func constructorV1 (be,bf,bg) = if ((bd.caller != this)) | |
262 | 262 | then throw("Permission denied") | |
263 | - | else if (isDefined(getBinary( | |
263 | + | else if (isDefined(getBinary(O))) | |
264 | 264 | then throw("Already initialized") | |
265 | 265 | else { | |
266 | - | let | |
267 | - | let bh = Issue("WLGOLD", "WavesLands Gold investment token", | |
266 | + | let av = aB | |
267 | + | let bh = Issue("WLGOLD", "WavesLands Gold investment token", av, 8, true, unit, 0) | |
268 | 268 | let bi = calculateAssetId(bh) | |
269 | - | [bh, IntegerEntry( | |
269 | + | [bh, IntegerEntry(aL, lastBlock.timestamp), IntegerEntry(N, av), IntegerEntry(aV, 0), IntegerEntry(aU, fraction(aB, aF, j)), BinaryEntry(O, bi), StringEntry(y(), be), StringEntry(aM, bf), StringEntry(aN, bg)] | |
270 | 270 | } | |
271 | 271 | ||
272 | 272 | ||
273 | 273 | ||
274 | 274 | @Callable(bd) | |
275 | 275 | func buyWlg () = { | |
276 | 276 | let bj = aX() | |
277 | 277 | if ((size(bd.payments) != 1)) | |
278 | 278 | then throw("exactly 1 payment must be attached") | |
279 | 279 | else { | |
280 | 280 | let bk = bd.payments[0] | |
281 | 281 | let bl = bk.amount | |
282 | 282 | let bm = valueOrErrorMessage(bk.assetId, "WAVES can't be used as payment") | |
283 | 283 | if ((bm != e)) | |
284 | 284 | then throw("USDT payments only!") | |
285 | 285 | else { | |
286 | 286 | let bn = bd.caller | |
287 | - | let | |
288 | - | let bo = aY( | |
287 | + | let aS = toString(bn) | |
288 | + | let bo = aY(aS) | |
289 | 289 | if ((bl > bo)) | |
290 | 290 | then throw((("You can spend max " + toString(bo)) + " USDT")) | |
291 | 291 | else { | |
292 | - | let bp = | |
293 | - | let bq = bp[ | |
294 | - | let br = fraction(bp[ | |
292 | + | let bp = au() | |
293 | + | let bq = bp[Q] | |
294 | + | let br = fraction(bp[R], 6, 5) | |
295 | 295 | let bs = fraction(bl, k, br) | |
296 | - | let bt = fraction(bl, bq, (bp[ | |
297 | - | $Tuple2([Reissue( | |
296 | + | let bt = fraction(bl, bq, (bp[S] - bl)) | |
297 | + | $Tuple2([Reissue(P, bt, true), IntegerEntry(N, (bq + bt)), IntegerEntry(aT(aS), lastBlock.timestamp), ScriptTransfer(bn, bs, P)], bj) | |
298 | 298 | } | |
299 | 299 | } | |
300 | 300 | } | |
301 | 301 | } | |
302 | 302 | ||
303 | 303 | ||
304 | 304 | ||
305 | 305 | @Callable(bd) | |
306 | 306 | func sellWlg () = { | |
307 | 307 | let bj = aX() | |
308 | 308 | if ((size(bd.payments) != 1)) | |
309 | 309 | then throw("exactly 1 payment must be attached") | |
310 | 310 | else { | |
311 | 311 | let bk = bd.payments[0] | |
312 | 312 | let bu = bk.amount | |
313 | 313 | let bm = valueOrErrorMessage(bk.assetId, "WAVES can't be used as payment") | |
314 | - | if ((bm != | |
314 | + | if ((bm != P)) | |
315 | 315 | then throw("WLGOLD payments only!") | |
316 | 316 | else { | |
317 | 317 | let bn = bd.caller | |
318 | - | let | |
319 | - | let bo = aY( | |
320 | - | let bp = | |
321 | - | let bq = (bp[ | |
322 | - | let bv = fraction(bp[ | |
318 | + | let aS = toString(bn) | |
319 | + | let bo = aY(aS) | |
320 | + | let bp = au() | |
321 | + | let bq = (bp[Q] - bu) | |
322 | + | let bv = fraction(bp[R], 4, 5) | |
323 | 323 | let bw = fraction(bu, bv, k) | |
324 | 324 | if ((bw > bo)) | |
325 | 325 | then throw((("You can get max " + toString(bo)) + " USDT")) | |
326 | 326 | else { | |
327 | - | let bx = fraction(bw, bq, bp[ | |
328 | - | $Tuple2([Burn( | |
327 | + | let bx = fraction(bw, bq, bp[S]) | |
328 | + | $Tuple2([Burn(P, bx), IntegerEntry(N, (bq - bx)), IntegerEntry(aT(aS), lastBlock.timestamp), ScriptTransfer(bn, bw, e)], bj) | |
329 | 329 | } | |
330 | 330 | } | |
331 | 331 | } | |
332 | 332 | } | |
333 | 333 | ||
334 | 334 | ||
335 | 335 | ||
336 | 336 | @Callable(bd) | |
337 | 337 | func claim () = { | |
338 | 338 | let bj = aX() | |
339 | 339 | let bn = bd.caller | |
340 | 340 | let by = toString(bn) | |
341 | 341 | let ba = lastBlock.timestamp | |
342 | - | let bz = valueOrErrorMessage(getInteger( | |
343 | - | let bA = valueOrElse(getInteger( | |
344 | - | let bf = addressFromStringValue(value(getString( | |
345 | - | let bB = fraction(fraction( | |
346 | - | let bC = valueOrElse(getInteger( | |
347 | - | let bg = addressFromStringValue(value(getString( | |
348 | - | let bD = fraction(fraction( | |
349 | - | let bE = valueOrElse(getInteger( | |
350 | - | let bF = fraction(fraction( | |
351 | - | let bG = ((ba - bz) / | |
352 | - | if ((bG > ( | |
342 | + | let bz = valueOrErrorMessage(getInteger(aL), "Not initialized") | |
343 | + | let bA = valueOrElse(getInteger(aO), bz) | |
344 | + | let bf = addressFromStringValue(value(getString(aM))) | |
345 | + | let bB = fraction(fraction(aB, aC, j), (ba - bA), aG) | |
346 | + | let bC = valueOrElse(getInteger(aP), bz) | |
347 | + | let bg = addressFromStringValue(value(getString(aN))) | |
348 | + | let bD = fraction(fraction(aB, aD, j), (ba - bC), (3 * aG)) | |
349 | + | let bE = valueOrElse(getInteger(aQ), bz) | |
350 | + | let bF = fraction(fraction(aB, aE, j), (ba - bE), (3 * aG)) | |
351 | + | let bG = ((ba - bz) / aH) | |
352 | + | if ((bG > (aI / 2))) | |
353 | 353 | then throw("Please modify contract for next 1.5 years, according to stats") | |
354 | 354 | else { | |
355 | - | let bH = | |
355 | + | let bH = Y(by) | |
356 | 356 | let bI = bH[b] | |
357 | - | let bJ = valueOrElse(getInteger( | |
358 | - | let bK = fraction(bJ, (2 * bI), (bI + (max([100000, bI]) * ( | |
359 | - | let bL = | |
357 | + | let bJ = valueOrElse(getInteger(aU), 0) | |
358 | + | let bK = fraction(bJ, (2 * bI), (bI + (max([100000, bI]) * (aI - bG)))) | |
359 | + | let bL = aR(by) | |
360 | 360 | let bM = valueOrElse(getInteger(bL), bz) | |
361 | - | let bN = fraction(fraction(bK, bH[c], bI), (ba - bM), (3 * | |
362 | - | let bO = | |
363 | - | $Tuple2([ScriptTransfer(bf, bB, | |
361 | + | let bN = fraction(fraction(bK, bH[c], bI), (ba - bM), (3 * aG)) | |
362 | + | let bO = aW(by) | |
363 | + | $Tuple2([ScriptTransfer(bf, bB, P), ScriptTransfer(bg, bD, P), ScriptTransfer(E, bF, P), ScriptTransfer(bn, bN, P), IntegerEntry(bO, (valueOrElse(getInteger(bO), 0) + bN)), IntegerEntry(aV, (valueOrElse(getInteger(aV), 0) + bN)), IntegerEntry(aU, (bJ - bN)), IntegerEntry(aO, ba), IntegerEntry(aP, ba), IntegerEntry(aQ, ba), IntegerEntry(bL, ba)], bj) | |
364 | 364 | } | |
365 | 365 | } | |
366 | 366 | ||
367 | 367 | ||
368 | 368 | ||
369 | 369 | @Callable(bd) | |
370 | - | func onStakeLand ( | |
370 | + | func onStakeLand (aS) = if ((bd.caller != F)) | |
371 | 371 | then throw("Permission denied") | |
372 | - | else $Tuple2([IntegerEntry( | |
372 | + | else $Tuple2([IntegerEntry(aR(aS), lastBlock.timestamp)], lastBlock.timestamp) | |
373 | 373 | ||
374 | 374 | ||
375 | 375 | ||
376 | 376 | @Callable(bd) | |
377 | - | func onUnstakeLand ( | |
377 | + | func onUnstakeLand (aS) = if ((bd.caller != F)) | |
378 | 378 | then throw("Permission denied") | |
379 | - | else $Tuple2([DeleteEntry( | |
379 | + | else $Tuple2([DeleteEntry(aR(aS))], 0) | |
380 | 380 | ||
381 | 381 |
github/deemru/w8io/169f3d6 189.46 ms ◑