tx · EP4sVG81wmGjP6gprVZ2nmnyzZCC1NNbTTtNGNe3JmrE 3Mq63YubY7UKJEobhDuXfsnXaPDJZT1fDhx: -0.01400000 Waves 2021.12.29 19:15 [1855734] smart account 3Mq63YubY7UKJEobhDuXfsnXaPDJZT1fDhx > SELF 0.00000000 Waves
{ "type": 13, "id": "EP4sVG81wmGjP6gprVZ2nmnyzZCC1NNbTTtNGNe3JmrE", "fee": 1400000, "feeAssetId": null, "timestamp": 1640794555561, "version": 2, "chainId": 84, "sender": "3Mq63YubY7UKJEobhDuXfsnXaPDJZT1fDhx", "senderPublicKey": "HXfVyeXgXUtHD3uSP6yjsk6JQcTwmU9qQTvhXzFpPw2T", "proofs": [ "2UeJQp8EeecgmA2VSv9MvUbWMa5HwNvUBvj6iNsw7sV62vffQ1Sus24C3jNmG7NNRFSyhrGeQCKR1L4DRZraGmQT", "5L9QXHsTJQzD76ngxG6YdPnEakKfN9ppqha1vVZS2WN49DzLfgj4RMXVG9DCyCGTDwqhvXjBjmTqwBtVpngdcPh8" ], "script": "base64:AAIFAAAAAAAADsAIAhIDCgEEEgcKBQEBCAgEEgMKAQESAwoBARIAEgMKAQESABIAEgMKAQESBQoDBAEIEgAaFAoBQRIPa2V5QWRtaW5QdWJLZXkyGhQKAUISD2tleUFkbWluUHViS2V5MxoLCgFDEgZvcmFjbGUaEAoBRBILZ2V0QWRtaW5QdWIaEAoBRRILa2V5QWRtaW5QdWIaDAoBRhIHJG1hdGNoMBoLCgFHEgZzdHJpbmcaDAoBSBIHbm90aGluZxoRCgFJEgxhZG1pblB1YktleTEaEQoBShIMYWRtaW5QdWJLZXkyGhEKAUsSDGFkbWluUHViS2V5MxoZCgFMEhRhZG1pblB1YktleVN0YXJ0U3RvcBoXCgFNEhJhZG1pblB1YktleVN0YWtpbmcaEgoBThINd2FsbGV0QWRkcmVzcxoSCgFPEg12b3RpbmdBZGRyZXNzGgkKAVASBFVTRE4aCQoBURIETlNCVBoJCgFSEgRFVVJOGhIKAVM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Z2UHCQAAAAAAAAIFAAAAAmFlBQAAAAFQBwYDAwkAAAAAAAACBQAAAAJhZgUAAAABUAkAAAAAAAACCQABkAAAAAEIBQAAAAJjdAAAAAhwYXltZW50cwAAAAAAAAAAAQcJAAAAAAAAAggJAAGRAAAAAggFAAAAAmN0AAAACHBheW1lbnRzAAAAAAAAAAAAAAAAB2Fzc2V0SWQFAAAAAVAHBAAAAAJjRQMDAwkAAAAAAAACCAUAAAACY3QAAAAEZEFwcAUAAAABVwkAAAAAAAACCAUAAAACY3QAAAAIZnVuY3Rpb24CAAAACGV4Y2hhbmdlBwkAAAAAAAACBQAAAAJhZQUAAAABUQcGAwMJAAAAAAAAAgUAAAACYWYFAAAAAVEJAAAAAAAAAgkAAZAAAAABCAUAAAACY3QAAAAIcGF5bWVudHMAAAAAAAAAAAEHCQAAAAAAAAIICQABkQAAAAIIBQAAAAJjdAAAAAhwYXltZW50cwAAAAAAAAAAAAAAAAdhc3NldElkBQAAAAFQBwQAAAACY0YDAwMJAAH0AAAAAwgFAAAAAmN3AAAACWJvZHlCeXRlcwkAAZEAAAACCAUAAAACY3cAAAAGcHJvb2ZzAAAAAAAAAAAABQAAAAFJBgkAAfQAAAADCAUAAAACY3cAAAAJYm9keUJ5dGVzCQABkQAAAAIIBQAAAAJjdwAAAAZwcm9vZnMAAAAAAAAAAAAFAAAAAUoGCQAB9AAAAAMIBQAAAAJjdwAAAAlib2R5Qnl0ZXMJAAGRAAAAAggFAAAAAmN3AAAABnByb29mcwAAAAAAAAAAAAUAAAABSwYJAAH0AAAAAwgFAAAAAmN3AAAACWJvZHlCeXRlcwkAAZEAAAACCAUAAAACY3cAAAAGcHJvb2ZzAAAAAAAAAAAABQAAAAFNAwMDAwUAAAACY0MGBQAAAAJjRAYFAAAAAmNFBQAAAAJjRgcGBQAAAAJjeQUAAAACY3krZvYu", "height": 1855734, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 269JkUQbjcwiHcSmcSz2fWZsuNFA9VVsioiztQz6ryo5 Next: 8rYiFi2o9kjEz3Z3JKP8AvKttrKcfT4sRexurNmsGQfs Diff:
Old | New | Differences | |
---|---|---|---|
225 | 225 | ||
226 | 226 | let aC = getIntegerValue(this, i) | |
227 | 227 | ||
228 | - | let aD = ( | |
228 | + | let aD = (at(ae) + az) | |
229 | 229 | ||
230 | - | let aE = ( | |
230 | + | let aE = (at(af) + aA) | |
231 | 231 | ||
232 | - | let aF = (at(ae) + az) | |
233 | - | ||
234 | - | let aG = (at(af) + aA) | |
235 | - | ||
236 | - | let aH = if ((aF >= ak)) | |
237 | - | then (aG >= al) | |
232 | + | let aF = if ((aD >= ak)) | |
233 | + | then (aE >= al) | |
238 | 234 | else false | |
239 | 235 | ||
240 | - | func | |
236 | + | func aG (au) = { | |
241 | 237 | let F = au | |
242 | 238 | if ($isInstanceOf(F, "ByteVector")) | |
243 | 239 | then { | |
244 | 240 | let ah = F | |
245 | - | let | |
246 | - | let | |
247 | - | $Tuple3( | |
241 | + | let aH = toBase58String(ah) | |
242 | + | let aI = valueOrErrorMessage(assetInfo(ah), (("Asset " + aH) + " doesn't exist")) | |
243 | + | $Tuple3(aH, aI.name, aI.decimals) | |
248 | 244 | } | |
249 | 245 | else if ($isInstanceOf(F, "Unit")) | |
250 | 246 | then { | |
255 | 251 | } | |
256 | 252 | ||
257 | 253 | ||
258 | - | func | |
254 | + | func aJ (aK) = if ((aK == "WAVES")) | |
259 | 255 | then $Tuple3("WAVES", "WAVES", 8) | |
260 | 256 | else { | |
261 | - | let | |
262 | - | let ah = fromBase58String( | |
263 | - | let | |
264 | - | $Tuple3( | |
257 | + | let aH = aK | |
258 | + | let ah = fromBase58String(aK) | |
259 | + | let aI = valueOrErrorMessage(assetInfo(ah), (("Asset " + aH) + " doesn't exist")) | |
260 | + | $Tuple3(aH, aI.name, aI.decimals) | |
265 | 261 | } | |
266 | 262 | ||
267 | 263 | ||
268 | - | func | |
264 | + | func aL (aM) = [BooleanEntry(c, false), StringEntry(n, aM)] | |
269 | 265 | ||
270 | 266 | ||
271 | - | func | |
267 | + | func aN (aO,au) = if (aO) | |
272 | 268 | then if ((au == P)) | |
273 | 269 | then $Tuple2("lockNeutrino", T) | |
274 | 270 | else if ((au == Q)) | |
281 | 277 | else $Tuple2("stopStaking", U) | |
282 | 278 | ||
283 | 279 | ||
284 | - | func | |
280 | + | func aP (aO,aQ,au) = if (aO) | |
285 | 281 | then { | |
286 | - | let | |
287 | - | let | |
288 | - | let | |
289 | - | $Tuple4( | |
282 | + | let aR = aN(aO, au) | |
283 | + | let aS = aR._1 | |
284 | + | let aT = aR._2 | |
285 | + | $Tuple4(aS, aT, nil, [AttachedPayment(au, aQ)]) | |
290 | 286 | } | |
291 | 287 | else { | |
292 | - | let | |
293 | - | let | |
294 | - | let | |
295 | - | $Tuple4( | |
288 | + | let aU = aN(aO, au) | |
289 | + | let aS = aU._1 | |
290 | + | let aT = aU._2 | |
291 | + | $Tuple4(aS, aT, [aQ, toBase58String(au)], nil) | |
296 | 292 | } | |
297 | 293 | ||
298 | 294 | ||
299 | - | func aX (aS,aY,aZ) = throw((((((((("Insufficient DApp balance to pay " + toString(aS)) + " ") + aZ) + " due to staking. Available: ") + toString(aY)) + " ") + aZ) + ". Please contact support in Telegram: https://t.me/swopfisupport")) | |
300 | - | ||
301 | - | ||
302 | - | func ba (bb,bc) = throw((((((((((((((((("Insufficient DApp balance to pay " + toString(bb)) + " ") + ag) + " and ") + toString(bc)) + " ") + aj) + " due to staking. Available: ") + toString(aD)) + " ") + ag) + " and ") + toString(aE)) + " ") + aj) + ". Please contact support in Telegram: https://t.me/swopfisupport")) | |
303 | - | ||
304 | - | ||
305 | - | func bd () = aN(((((((((((((((("Suspicious state. Actual balances: " + toString(aF)) + " ") + ag) + ", ") + toString(aG)) + " ") + aj) + ". State: ") + toString(ak)) + " ") + ag) + ", ") + toString(al)) + " ") + aj)) | |
295 | + | func aV () = aL(((((((((((((((("Suspicious state. Actual balances: " + toString(aD)) + " ") + ag) + ", ") + toString(aE)) + " ") + aj) + ". State: ") + toString(ak)) + " ") + ag) + ", ") + toString(al)) + " ") + aj)) | |
306 | 296 | ||
307 | 297 | ||
308 | 298 | @Callable(ay) | |
309 | - | func init ( | |
310 | - | let | |
311 | - | let | |
312 | - | let | |
313 | - | let | |
314 | - | let | |
315 | - | let | |
316 | - | let | |
317 | - | let | |
318 | - | let | |
319 | - | let | |
320 | - | let | |
321 | - | let | |
322 | - | let | |
323 | - | let | |
299 | + | func init (aW) = { | |
300 | + | let aX = $Tuple2(ay.payments[0].amount, ay.payments[0].assetId) | |
301 | + | let aY = aX._1 | |
302 | + | let aZ = aX._2 | |
303 | + | let ba = $Tuple2(ay.payments[1].amount, ay.payments[1].assetId) | |
304 | + | let bb = ba._1 | |
305 | + | let bc = ba._2 | |
306 | + | let bd = aG(aZ) | |
307 | + | let be = bd._1 | |
308 | + | let bf = bd._2 | |
309 | + | let bg = bd._3 | |
310 | + | let bh = aG(bc) | |
311 | + | let bi = bh._1 | |
312 | + | let bj = bh._2 | |
313 | + | let bk = bh._3 | |
324 | 314 | if (!(containsElement([I, J, K, M], ay.callerPublicKey))) | |
325 | 315 | then throw("Only admin can call this function") | |
326 | 316 | else if (isDefined(getBoolean(this, c))) | |
327 | 317 | then throw("DApp is already active") | |
328 | - | else if (( | |
318 | + | else if ((aZ == bc)) | |
329 | 319 | then throw("Assets must be different") | |
330 | 320 | else { | |
331 | - | let | |
332 | - | let | |
333 | - | let | |
334 | - | let | |
335 | - | let | |
336 | - | let | |
337 | - | let | |
338 | - | let | |
339 | - | let | |
340 | - | let | |
341 | - | then invoke(this, "stakeUnstake", [true, | |
321 | + | let bl = ((("s" + take(bf, 7)) + "_") + take(bj, 7)) | |
322 | + | let bm = ((((("ShareToken of SwopFi protocol for " + bf) + " and ") + bj) + " at address ") + toString(this)) | |
323 | + | let bn = ((bg + bk) / 2) | |
324 | + | let bo = pow(aY, bg, 5, 1, bg, DOWN) | |
325 | + | let bp = pow(bb, bk, 5, 1, bk, DOWN) | |
326 | + | let bq = pow(10, 0, bn, 0, 0, DOWN) | |
327 | + | let br = fraction(bo, bp, bq) | |
328 | + | let bs = Issue(bl, bm, br, bn, true) | |
329 | + | let bt = calculateAssetId(bs) | |
330 | + | let bu = if (containsElement(S, be)) | |
331 | + | then invoke(this, "stakeUnstake", [true, aY, be], nil) | |
342 | 332 | else 0 | |
343 | - | if (( | |
333 | + | if ((bu == bu)) | |
344 | 334 | then { | |
345 | - | let | |
346 | - | then invoke(this, "stakeUnstake", [true, | |
335 | + | let bv = if (containsElement(S, bi)) | |
336 | + | then invoke(this, "stakeUnstake", [true, bb, bi], nil) | |
347 | 337 | else 0 | |
348 | - | if (( | |
338 | + | if ((bv == bv)) | |
349 | 339 | then { | |
350 | - | let | |
351 | - | if ( | |
352 | - | then ( | |
353 | - | else | |
340 | + | let bw = [StringEntry(b, a), BooleanEntry(c, true), StringEntry(d, be), StringEntry(e, bi), IntegerEntry(f, aY), IntegerEntry(g, bb), IntegerEntry(l, ao), IntegerEntry(m, ap), bs, StringEntry(j, toBase58String(bt)), IntegerEntry(k, br), ScriptTransfer(ay.caller, br, bt)] | |
341 | + | if (aW) | |
342 | + | then (bw ++ [BooleanEntry(o, aW), IntegerEntry(p, (Y + (aa * Z)))]) | |
343 | + | else bw | |
354 | 344 | } | |
355 | 345 | else throw("Strict value is not equal to itself.") | |
356 | 346 | } | |
361 | 351 | ||
362 | 352 | ||
363 | 353 | @Callable(ay) | |
364 | - | func initWithInitRatio ( | |
365 | - | let | |
366 | - | let | |
367 | - | let | |
368 | - | let | |
369 | - | let | |
370 | - | let | |
371 | - | let | |
372 | - | let | |
354 | + | func initWithInitRatio (bx,by,ac,ad,aW) = { | |
355 | + | let bz = aJ(ac) | |
356 | + | let be = bz._1 | |
357 | + | let bf = bz._2 | |
358 | + | let bg = bz._3 | |
359 | + | let bA = aJ(ad) | |
360 | + | let bi = bA._1 | |
361 | + | let bj = bA._2 | |
362 | + | let bk = bA._3 | |
373 | 363 | if (!(containsElement([I, J, K, M], ay.callerPublicKey))) | |
374 | 364 | then throw("Only admin can call this function") | |
375 | 365 | else if (isDefined(getBoolean(this, c))) | |
377 | 367 | else if ((ac == ad)) | |
378 | 368 | then throw("Assets must be different") | |
379 | 369 | else { | |
380 | - | let | |
381 | - | let | |
382 | - | let | |
383 | - | let | |
384 | - | let | |
385 | - | let | |
386 | - | let | |
387 | - | if ( | |
388 | - | then ( | |
389 | - | else | |
370 | + | let bl = ((("s" + take(bf, 7)) + "_") + take(bj, 7)) | |
371 | + | let bm = ((((("ShareToken of SwopFi protocol for " + bf) + " and ") + bj) + " at address ") + toString(this)) | |
372 | + | let bn = ((bg + bk) / 2) | |
373 | + | let br = 0 | |
374 | + | let bs = Issue(bl, bm, br, bn, true) | |
375 | + | let bt = calculateAssetId(bs) | |
376 | + | let bw = [StringEntry(b, a), BooleanEntry(c, true), StringEntry(d, be), StringEntry(e, bi), IntegerEntry(h, bx), IntegerEntry(i, by), IntegerEntry(f, 0), IntegerEntry(g, 0), IntegerEntry(l, ao), IntegerEntry(m, ap), bs, StringEntry(j, toBase58String(bt)), IntegerEntry(k, br)] | |
377 | + | if (aW) | |
378 | + | then (bw ++ [BooleanEntry(o, aW), IntegerEntry(p, (Y + (aa * Z)))]) | |
379 | + | else bw | |
390 | 380 | } | |
391 | 381 | } | |
392 | 382 | ||
393 | 383 | ||
394 | 384 | ||
395 | 385 | @Callable(ay) | |
396 | - | func keepLimitForFirstHarvest ( | |
386 | + | func keepLimitForFirstHarvest (bB) = if (!(ab)) | |
397 | 387 | then throw("DApp is inactive at this moment") | |
398 | 388 | else if (!(containsElement([I, J, K, M], ay.callerPublicKey))) | |
399 | 389 | then throw("Only admin can call this function") | |
400 | - | else [IntegerEntry(q, | |
390 | + | else [IntegerEntry(q, bB)] | |
401 | 391 | ||
402 | 392 | ||
403 | 393 | ||
404 | 394 | @Callable(ay) | |
405 | - | func replenishWithTwoTokens ( | |
406 | - | let | |
407 | - | let | |
408 | - | let | |
409 | - | let | |
410 | - | let | |
411 | - | let | |
412 | - | let | |
413 | - | let | |
414 | - | let | |
415 | - | let | |
416 | - | let | |
417 | - | let | |
395 | + | func replenishWithTwoTokens (bC) = { | |
396 | + | let aZ = ay.payments[0].assetId | |
397 | + | let bc = ay.payments[1].assetId | |
398 | + | let aY = ay.payments[0].amount | |
399 | + | let bb = ay.payments[1].amount | |
400 | + | let bD = aG(aZ) | |
401 | + | let be = bD._1 | |
402 | + | let bf = bD._2 | |
403 | + | let bg = bD._3 | |
404 | + | let bE = aG(bc) | |
405 | + | let bi = bE._1 | |
406 | + | let bj = bE._2 | |
407 | + | let bk = bE._3 | |
418 | 408 | if (if ((ak == 0)) | |
419 | 409 | then (al == 0) | |
420 | 410 | else false) | |
421 | 411 | then { | |
422 | - | let | |
423 | - | if (( | |
412 | + | let bF = fraction(fraction(aB, ar, aY), aq, fraction(aC, ar, bb)) | |
413 | + | if ((aZ == bc)) | |
424 | 414 | then throw("Assets must be different") | |
425 | 415 | else { | |
426 | - | let | |
427 | - | let | |
416 | + | let bn = ((bg + bk) / 2) | |
417 | + | let br = fraction(pow(aY, bg, 5, 1, bg, DOWN), pow(bb, bk, 5, 1, bk, DOWN), pow(10, 0, bn, 0, 0, DOWN)) | |
428 | 418 | if (!(ab)) | |
429 | 419 | then throw("DApp is inactive at this moment") | |
430 | - | else if (if ((0 > | |
420 | + | else if (if ((0 > bC)) | |
431 | 421 | then true | |
432 | - | else ( | |
433 | - | then throw(((("Slippage tolerance must be between 0 and " + toString(as)) + " inclusively. Actual: ") + toString( | |
422 | + | else (bC > as)) | |
423 | + | then throw(((("Slippage tolerance must be between 0 and " + toString(as)) + " inclusively. Actual: ") + toString(bC))) | |
434 | 424 | else if ((size(ay.payments) != 2)) | |
435 | 425 | then throw("Two attached assets expected") | |
436 | - | else if (if ((((aq * (as - | |
426 | + | else if (if ((((aq * (as - bC)) / as) > bF)) | |
437 | 427 | then true | |
438 | - | else ( | |
428 | + | else (bF > ((aq * (as + bC)) / as))) | |
439 | 429 | then throw("Incorrect assets amount: amounts must have the contract ratio") | |
440 | - | else if (if (( | |
430 | + | else if (if ((aZ != ae)) | |
441 | 431 | then true | |
442 | - | else ( | |
432 | + | else (bc != af)) | |
443 | 433 | then throw(((("Incorrect assets attached. Expected: " + ac) + " and ") + ad)) | |
444 | - | else if (( | |
434 | + | else if ((br == 0)) | |
445 | 435 | then throw("Too small amount to replenish") | |
446 | - | else if (!( | |
447 | - | then ([ScriptTransfer(ay.caller, | |
436 | + | else if (!(aF)) | |
437 | + | then ([ScriptTransfer(ay.caller, aY, aZ), ScriptTransfer(ay.caller, bb, bc)] ++ aV()) | |
448 | 438 | else { | |
449 | - | let | |
450 | - | then invoke(this, "stakeUnstake", [true, | |
439 | + | let bu = if (containsElement(S, be)) | |
440 | + | then invoke(this, "stakeUnstake", [true, aY, be], nil) | |
451 | 441 | else 0 | |
452 | - | if (( | |
442 | + | if ((bu == bu)) | |
453 | 443 | then { | |
454 | - | let | |
455 | - | then invoke(this, "stakeUnstake", [true, | |
444 | + | let bv = if (containsElement(S, bi)) | |
445 | + | then invoke(this, "stakeUnstake", [true, bb, bi], nil) | |
456 | 446 | else 0 | |
457 | - | if (( | |
458 | - | then [Reissue(am, | |
447 | + | if ((bv == bv)) | |
448 | + | then [Reissue(am, br, true), IntegerEntry(f, aY), IntegerEntry(g, bb), IntegerEntry(k, br), ScriptTransfer(ay.caller, br, am)] | |
459 | 449 | else throw("Strict value is not equal to itself.") | |
460 | 450 | } | |
461 | 451 | else throw("Strict value is not equal to itself.") | |
463 | 453 | } | |
464 | 454 | } | |
465 | 455 | else { | |
466 | - | let | |
467 | - | let | |
468 | - | let | |
469 | - | let | |
456 | + | let bF = fraction(fraction(ak, ar, aY), aq, fraction(al, ar, bb)) | |
457 | + | let bG = fraction(aY, ar, ak) | |
458 | + | let bH = fraction(bb, ar, al) | |
459 | + | let bI = fraction(min([bG, bH]), an, ar) | |
470 | 460 | if (!(ab)) | |
471 | 461 | then throw("DApp is inactive at this moment") | |
472 | - | else if (if ((0 > | |
462 | + | else if (if ((0 > bC)) | |
473 | 463 | then true | |
474 | - | else ( | |
475 | - | then throw(((("Slippage tolerance must be between 0 and " + toString(as)) + " inclusively. Actual: ") + toString( | |
464 | + | else (bC > as)) | |
465 | + | then throw(((("Slippage tolerance must be between 0 and " + toString(as)) + " inclusively. Actual: ") + toString(bC))) | |
476 | 466 | else if ((size(ay.payments) != 2)) | |
477 | 467 | then throw("Two attached assets expected") | |
478 | - | else if (if (( | |
468 | + | else if (if ((aZ != ae)) | |
479 | 469 | then true | |
480 | - | else ( | |
470 | + | else (bc != af)) | |
481 | 471 | then throw(((("Incorrect assets attached. Expected: " + ac) + " and ") + ad)) | |
482 | - | else if (if ((((aq * (as - | |
472 | + | else if (if ((((aq * (as - bC)) / as) > bF)) | |
483 | 473 | then true | |
484 | - | else ( | |
474 | + | else (bF > ((aq * (as + bC)) / as))) | |
485 | 475 | then throw("Incorrect assets amount: amounts must have the contract ratio") | |
486 | - | else if (( | |
476 | + | else if ((bI == 0)) | |
487 | 477 | then throw("Too small amount to replenish") | |
488 | - | else if (!( | |
489 | - | then ([ScriptTransfer(ay.caller, | |
478 | + | else if (!(aF)) | |
479 | + | then ([ScriptTransfer(ay.caller, aY, aZ), ScriptTransfer(ay.caller, bb, bc)] ++ aV()) | |
490 | 480 | else { | |
491 | - | let | |
492 | - | then invoke(this, "stakeUnstake", [true, | |
481 | + | let bu = if (containsElement(S, be)) | |
482 | + | then invoke(this, "stakeUnstake", [true, aY, be], nil) | |
493 | 483 | else 0 | |
494 | - | if (( | |
484 | + | if ((bu == bu)) | |
495 | 485 | then { | |
496 | - | let | |
497 | - | then invoke(this, "stakeUnstake", [true, | |
486 | + | let bv = if (containsElement(S, bi)) | |
487 | + | then invoke(this, "stakeUnstake", [true, bb, bi], nil) | |
498 | 488 | else 0 | |
499 | - | if (( | |
500 | - | then [IntegerEntry(f, (ak + | |
489 | + | if ((bv == bv)) | |
490 | + | then [IntegerEntry(f, (ak + aY)), IntegerEntry(g, (al + bb)), IntegerEntry(k, (an + bI)), Reissue(am, bI, true), ScriptTransfer(ay.caller, bI, am)] | |
501 | 491 | else throw("Strict value is not equal to itself.") | |
502 | 492 | } | |
503 | 493 | else throw("Strict value is not equal to itself.") | |
509 | 499 | ||
510 | 500 | @Callable(ay) | |
511 | 501 | func withdraw () = { | |
512 | - | let | |
513 | - | let | |
514 | - | let | |
515 | - | let | |
516 | - | let | |
502 | + | let bJ = $Tuple2(ay.payments[0].amount, ay.payments[0].assetId) | |
503 | + | let bK = bJ._1 | |
504 | + | let bL = bJ._2 | |
505 | + | let bM = fraction(bK, ak, an) | |
506 | + | let bN = fraction(bK, al, an) | |
517 | 507 | if (!(ab)) | |
518 | 508 | then throw("DApp is inactive at this moment") | |
519 | 509 | else if ((size(ay.payments) != 1)) | |
520 | 510 | then throw("One attached payment expected") | |
521 | - | else if (( | |
511 | + | else if ((bL != am)) | |
522 | 512 | then throw(("Incorrect asset attached. Expected: " + toBase58String(am))) | |
523 | - | else if (!(aH)) | |
524 | - | then ([ScriptTransfer(ay.caller, bS, bT)] ++ bd()) | |
525 | - | else if (if ((bU > aD)) | |
526 | - | then true | |
527 | - | else (bV > aE)) | |
528 | - | then ba(bU, bV) | |
529 | - | else { | |
530 | - | let bC = if (containsElement(S, ac)) | |
531 | - | then invoke(this, "stakeUnstake", [false, bU, ac], nil) | |
532 | - | else 0 | |
533 | - | if ((bC == bC)) | |
534 | - | then { | |
535 | - | let bD = if (containsElement(S, ad)) | |
536 | - | then invoke(this, "stakeUnstake", [false, bV, ad], nil) | |
537 | - | else 0 | |
538 | - | if ((bD == bD)) | |
539 | - | then [IntegerEntry(f, (ak - bU)), IntegerEntry(g, (al - bV)), IntegerEntry(k, (an - bS)), Burn(am, bS), ScriptTransfer(ay.caller, bU, ae), ScriptTransfer(ay.caller, bV, af)] | |
540 | - | else throw("Strict value is not equal to itself.") | |
541 | - | } | |
542 | - | else throw("Strict value is not equal to itself.") | |
543 | - | } | |
513 | + | else if (!(aF)) | |
514 | + | then ([ScriptTransfer(ay.caller, bK, bL)] ++ aV()) | |
515 | + | else { | |
516 | + | let bu = if (containsElement(S, ac)) | |
517 | + | then invoke(this, "stakeUnstake", [false, bM, ac], nil) | |
518 | + | else 0 | |
519 | + | if ((bu == bu)) | |
520 | + | then { | |
521 | + | let bv = if (containsElement(S, ad)) | |
522 | + | then invoke(this, "stakeUnstake", [false, bN, ad], nil) | |
523 | + | else 0 | |
524 | + | if ((bv == bv)) | |
525 | + | then [IntegerEntry(f, (ak - bM)), IntegerEntry(g, (al - bN)), IntegerEntry(k, (an - bK)), Burn(am, bK), ScriptTransfer(ay.caller, bM, ae), ScriptTransfer(ay.caller, bN, af)] | |
526 | + | else throw("Strict value is not equal to itself.") | |
527 | + | } | |
528 | + | else throw("Strict value is not equal to itself.") | |
529 | + | } | |
544 | 530 | } | |
545 | 531 | ||
546 | 532 | ||
547 | 533 | ||
548 | 534 | @Callable(ay) | |
549 | - | func exchange ( | |
550 | - | let | |
551 | - | let | |
552 | - | let | |
553 | - | func | |
554 | - | let | |
555 | - | let | |
556 | - | let | |
557 | - | if (( | |
558 | - | then throw(((("Calculated amount to receive " + toString( | |
559 | - | else $Tuple3( | |
535 | + | func exchange (bO) = { | |
536 | + | let bP = $Tuple2(ay.payments[0].amount, ay.payments[0].assetId) | |
537 | + | let bK = bP._1 | |
538 | + | let bL = bP._2 | |
539 | + | func bQ (bR,bS) = { | |
540 | + | let bT = fraction(bS, bK, (bK + bR)) | |
541 | + | let bU = fraction(bT, (ap - ao), ap) | |
542 | + | let bV = fraction(bT, commissionGovernance, ap) | |
543 | + | if ((bO > bU)) | |
544 | + | then throw(((("Calculated amount to receive " + toString(bU)) + " is less than specified minimum ") + toString(bO))) | |
545 | + | else $Tuple3(bT, bU, bV) | |
560 | 546 | } | |
561 | 547 | ||
562 | 548 | if (!(ab)) | |
565 | 551 | then true | |
566 | 552 | else (al == 0)) | |
567 | 553 | then throw("Can't exchange with zero balance") | |
568 | - | else if ((0 >= | |
569 | - | then throw(("Minimal amount to receive must be positive. Actual: " + toString( | |
554 | + | else if ((0 >= bO)) | |
555 | + | then throw(("Minimal amount to receive must be positive. Actual: " + toString(bO))) | |
570 | 556 | else if ((size(ay.payments) != 1)) | |
571 | 557 | then throw("One attached payment expected") | |
572 | - | else if (!( | |
573 | - | then ([ScriptTransfer(ay.caller, | |
574 | - | else if (( | |
558 | + | else if (!(aF)) | |
559 | + | then ([ScriptTransfer(ay.caller, bK, bL)] ++ aV()) | |
560 | + | else if ((bL == ae)) | |
575 | 561 | then { | |
576 | - | let | |
577 | - | let | |
578 | - | let | |
579 | - | let | |
580 | - | let | |
581 | - | let | |
582 | - | let | |
583 | - | let | |
584 | - | then invoke(this, "stakeUnstake", [true, | |
562 | + | let bW = af | |
563 | + | let bX = bQ(ak, al) | |
564 | + | let bT = bX._1 | |
565 | + | let bU = bX._2 | |
566 | + | let bV = bX._3 | |
567 | + | let bY = (ak + bK) | |
568 | + | let bZ = ((al - bU) - bV) | |
569 | + | let bu = if (containsElement(S, ac)) | |
570 | + | then invoke(this, "stakeUnstake", [true, bK, ac], nil) | |
585 | 571 | else 0 | |
586 | - | if (( | |
572 | + | if ((bu == bu)) | |
587 | 573 | then { | |
588 | - | let | |
589 | - | then invoke(this, "stakeUnstake", [false, ( | |
574 | + | let bv = if (containsElement(S, ad)) | |
575 | + | then invoke(this, "stakeUnstake", [false, (bU + bV), ad], nil) | |
590 | 576 | else 0 | |
591 | - | if (( | |
592 | - | then [IntegerEntry(f, | |
577 | + | if ((bv == bv)) | |
578 | + | then [IntegerEntry(f, bY), IntegerEntry(g, bZ), ScriptTransfer(ay.caller, bU, bW), ScriptTransfer(N, bV, bW)] | |
593 | 579 | else throw("Strict value is not equal to itself.") | |
594 | 580 | } | |
595 | 581 | else throw("Strict value is not equal to itself.") | |
596 | 582 | } | |
597 | - | else if (( | |
583 | + | else if ((bL == af)) | |
598 | 584 | then { | |
599 | - | let | |
600 | - | let | |
601 | - | let | |
602 | - | let | |
603 | - | let | |
604 | - | let | |
605 | - | let | |
606 | - | if ( | |
607 | - | then | |
608 | - | else | |
609 | - | | |
610 | - | | |
611 | - | let | |
612 | - | then invoke(this, "stakeUnstake", [ | |
585 | + | let bW = ae | |
586 | + | let ca = bQ(al, ak) | |
587 | + | let bT = ca._1 | |
588 | + | let bU = ca._2 | |
589 | + | let bV = ca._3 | |
590 | + | let bY = ((ak - bU) - bV) | |
591 | + | let bZ = (al + bK) | |
592 | + | let bu = if (containsElement(S, ac)) | |
593 | + | then invoke(this, "stakeUnstake", [false, (bU + bV), ac], nil) | |
594 | + | else 0 | |
595 | + | if ((bu == bu)) | |
596 | + | then { | |
597 | + | let bv = if (containsElement(S, ad)) | |
598 | + | then invoke(this, "stakeUnstake", [true, bK, ad], nil) | |
613 | 599 | else 0 | |
614 | - | if ((bC == bC)) | |
615 | - | then { | |
616 | - | let bD = if (containsElement(S, ad)) | |
617 | - | then invoke(this, "stakeUnstake", [true, bS, ad], nil) | |
618 | - | else 0 | |
619 | - | if ((bD == bD)) | |
620 | - | then [IntegerEntry(f, cg), IntegerEntry(g, ch), ScriptTransfer(ay.caller, cc, ce), ScriptTransfer(N, cd, ce)] | |
621 | - | else throw("Strict value is not equal to itself.") | |
622 | - | } | |
600 | + | if ((bv == bv)) | |
601 | + | then [IntegerEntry(f, bY), IntegerEntry(g, bZ), ScriptTransfer(ay.caller, bU, bW), ScriptTransfer(N, bV, bW)] | |
623 | 602 | else throw("Strict value is not equal to itself.") | |
624 | 603 | } | |
604 | + | else throw("Strict value is not equal to itself.") | |
625 | 605 | } | |
626 | 606 | else throw(((("Incorrect asset attached. Expected: " + ac) + " or ") + ad)) | |
627 | 607 | } | |
633 | 613 | then throw(("DApp is already suspended. Cause: " + valueOrElse(getString(this, n), "the cause wasn't specified"))) | |
634 | 614 | else if (!(containsElement([I, J, K, L], ay.callerPublicKey))) | |
635 | 615 | then throw("Only admin can call this function") | |
636 | - | else | |
616 | + | else aL("Paused by admin") | |
637 | 617 | ||
638 | 618 | ||
639 | 619 | ||
647 | 627 | ||
648 | 628 | ||
649 | 629 | @Callable(ay) | |
650 | - | func takeIntoAccountExtraFunds ( | |
651 | - | let | |
652 | - | let | |
653 | - | let | |
654 | - | then | |
630 | + | func takeIntoAccountExtraFunds (cb) = { | |
631 | + | let cc = (aD - ak) | |
632 | + | let cd = (aE - al) | |
633 | + | let ce = (cc - (if ((ae == unit)) | |
634 | + | then cb | |
655 | 635 | else 0)) | |
656 | - | let | |
657 | - | then | |
636 | + | let cf = (cd - (if ((af == unit)) | |
637 | + | then cb | |
658 | 638 | else 0)) | |
659 | 639 | if (!(ab)) | |
660 | 640 | then throw("DApp is inactive at this moment") | |
661 | 641 | else if ((ay.caller != this)) | |
662 | 642 | then throw("Only the DApp itself can call this function") | |
663 | - | else if ((0 > | |
664 | - | then throw(("Argument 'amountLeave' cannot be negative. Actual: " + toString( | |
665 | - | else if (if ((0 > | |
643 | + | else if ((0 > cb)) | |
644 | + | then throw(("Argument 'amountLeave' cannot be negative. Actual: " + toString(cb))) | |
645 | + | else if (if ((0 > cc)) | |
666 | 646 | then true | |
667 | - | else (0 > | |
668 | - | then | |
669 | - | else if (if ((0 > | |
647 | + | else (0 > cd)) | |
648 | + | then aL("Enroll amount negative") | |
649 | + | else if (if ((0 > ce)) | |
670 | 650 | then true | |
671 | - | else (0 > | |
651 | + | else (0 > cf)) | |
672 | 652 | then throw("Too large amountLeave") | |
673 | 653 | else { | |
674 | - | let | |
675 | - | then ( | |
654 | + | let bu = if (if (containsElement(S, ac)) | |
655 | + | then (ce > 0) | |
676 | 656 | else false) | |
677 | - | then invoke(this, "stakeUnstake", [true, | |
657 | + | then invoke(this, "stakeUnstake", [true, ce, ac], nil) | |
678 | 658 | else 0 | |
679 | - | if (( | |
659 | + | if ((bu == bu)) | |
680 | 660 | then { | |
681 | - | let | |
682 | - | then ( | |
661 | + | let bv = if (if (containsElement(S, ad)) | |
662 | + | then (cf > 0) | |
683 | 663 | else false) | |
684 | - | then invoke(this, "stakeUnstake", [true, | |
664 | + | then invoke(this, "stakeUnstake", [true, cf, ad], nil) | |
685 | 665 | else 0 | |
686 | - | if (( | |
687 | - | then [IntegerEntry(f, (ak + | |
666 | + | if ((bv == bv)) | |
667 | + | then [IntegerEntry(f, (ak + ce)), IntegerEntry(g, (al + cf)), IntegerEntry(("last_income_" + ac), ce), IntegerEntry(("last_income_" + ad), cf)] | |
688 | 668 | else throw("Strict value is not equal to itself.") | |
689 | 669 | } | |
690 | 670 | else throw("Strict value is not equal to itself.") | |
694 | 674 | ||
695 | 675 | ||
696 | 676 | @Callable(ay) | |
697 | - | func stakeUnstake (aQ, | |
677 | + | func stakeUnstake (aO,aQ,cg) = if ((ay.caller != this)) | |
698 | 678 | then throw("Only contract itself can invoke this function") | |
699 | - | else if (( | |
679 | + | else if ((cg == "WAVES")) | |
700 | 680 | then { | |
701 | - | let | |
702 | - | let | |
703 | - | let | |
704 | - | let | |
705 | - | then ( | |
706 | - | else ( | |
707 | - | let | |
708 | - | let | |
709 | - | let | |
710 | - | let F = | |
681 | + | let ch = addressFromStringValue(valueOrErrorMessage(getString(C, w), "No leasing pool in oracle")) | |
682 | + | let ci = getBinary(this, y) | |
683 | + | let cj = valueOrElse(getInteger(this, x), 0) | |
684 | + | let ck = if (aO) | |
685 | + | then (cj + aQ) | |
686 | + | else (cj - aQ) | |
687 | + | let cl = Lease(ch, ck) | |
688 | + | let cm = calculateLeaseId(cl) | |
689 | + | let cn = [cl, BinaryEntry(y, cm), IntegerEntry(x, ck)] | |
690 | + | let F = ci | |
711 | 691 | if ($isInstanceOf(F, "ByteVector")) | |
712 | 692 | then { | |
713 | - | let | |
714 | - | ([LeaseCancel( | |
693 | + | let co = F | |
694 | + | ([LeaseCancel(co)] ++ cn) | |
715 | 695 | } | |
716 | - | else | |
696 | + | else cn | |
717 | 697 | } | |
718 | 698 | else { | |
719 | - | let | |
720 | - | let | |
721 | - | let | |
722 | - | let | |
723 | - | let | |
724 | - | let | |
725 | - | if (( | |
699 | + | let cp = aP(aO, aQ, fromBase58String(cg)) | |
700 | + | let aS = cp._1 | |
701 | + | let cq = cp._2 | |
702 | + | let cr = cp._3 | |
703 | + | let cs = cp._4 | |
704 | + | let ct = invoke(cq, aS, cr, cs) | |
705 | + | if ((ct == ct)) | |
726 | 706 | then nil | |
727 | 707 | else throw("Strict value is not equal to itself.") | |
728 | 708 | } | |
735 | 715 | else if (!(containsElement([I, J, K, L], ay.callerPublicKey))) | |
736 | 716 | then throw("Only admin can call this function") | |
737 | 717 | else { | |
738 | - | let | |
718 | + | let bu = if (containsElement(S, ac)) | |
739 | 719 | then { | |
740 | - | let | |
741 | - | if (( | |
742 | - | then invoke(this, "stakeUnstake", [true, | |
720 | + | let cu = (ak - az) | |
721 | + | if ((cu > 0)) | |
722 | + | then invoke(this, "stakeUnstake", [true, cu, ac], nil) | |
743 | 723 | else 0 | |
744 | 724 | } | |
745 | 725 | else 0 | |
746 | - | if (( | |
726 | + | if ((bu == bu)) | |
747 | 727 | then { | |
748 | - | let | |
728 | + | let bv = if (containsElement(S, ad)) | |
749 | 729 | then { | |
750 | - | let | |
751 | - | if (( | |
752 | - | then invoke(this, "stakeUnstake", [true, | |
730 | + | let cv = (al - aA) | |
731 | + | if ((cv > 0)) | |
732 | + | then invoke(this, "stakeUnstake", [true, cv, ad], nil) | |
753 | 733 | else 0 | |
754 | 734 | } | |
755 | 735 | else 0 | |
756 | - | if (( | |
736 | + | if ((bv == bv)) | |
757 | 737 | then nil | |
758 | 738 | else throw("Strict value is not equal to itself.") | |
759 | 739 | } | |
761 | 741 | } | |
762 | 742 | ||
763 | 743 | ||
764 | - | @Verifier( | |
765 | - | func | |
766 | - | let | |
767 | - | let | |
744 | + | @Verifier(cw) | |
745 | + | func cx () = { | |
746 | + | let cy = { | |
747 | + | let cz = if (sigVerify(cw.bodyBytes, cw.proofs[0], I)) | |
768 | 748 | then 1 | |
769 | 749 | else 0 | |
770 | - | let | |
750 | + | let cA = if (sigVerify(cw.bodyBytes, cw.proofs[1], J)) | |
771 | 751 | then 1 | |
772 | 752 | else 0 | |
773 | - | let | |
753 | + | let cB = if (sigVerify(cw.bodyBytes, cw.proofs[2], K)) | |
774 | 754 | then 1 | |
775 | 755 | else 0 | |
776 | - | ((( | |
756 | + | (((cz + cA) + cB) >= 2) | |
777 | 757 | } | |
778 | - | let F = | |
758 | + | let F = cw | |
779 | 759 | if ($isInstanceOf(F, "InvokeScriptTransaction")) | |
780 | 760 | then { | |
781 | - | let | |
782 | - | let | |
783 | - | then ( | |
761 | + | let ct = F | |
762 | + | let cC = if ((ct.dApp == this)) | |
763 | + | then (ct.function == "takeIntoAccountExtraFunds") | |
784 | 764 | else false | |
785 | - | let | |
786 | - | then ( | |
765 | + | let cD = if (if (if ((ct.dApp == V)) | |
766 | + | then (ct.function == "exchange") | |
787 | 767 | else false) | |
788 | 768 | then (ae == P) | |
789 | 769 | else false) | |
790 | 770 | then true | |
791 | 771 | else if (if ((af == P)) | |
792 | - | then (size( | |
772 | + | then (size(ct.payments) == 1) | |
793 | 773 | else false) | |
794 | - | then ( | |
774 | + | then (ct.payments[0].assetId == P) | |
795 | 775 | else false | |
796 | - | let | |
797 | - | then ( | |
776 | + | let cE = if (if (if ((ct.dApp == W)) | |
777 | + | then (ct.function == "exchange") | |
798 | 778 | else false) | |
799 | 779 | then (ae == Q) | |
800 | 780 | else false) | |
801 | 781 | then true | |
802 | 782 | else if (if ((af == Q)) | |
803 | - | then (size( | |
783 | + | then (size(ct.payments) == 1) | |
804 | 784 | else false) | |
805 | - | then ( | |
785 | + | then (ct.payments[0].assetId == P) | |
806 | 786 | else false | |
807 | - | let | |
787 | + | let cF = if (if (if (sigVerify(cw.bodyBytes, cw.proofs[0], I)) | |
808 | 788 | then true | |
809 | - | else sigVerify( | |
789 | + | else sigVerify(cw.bodyBytes, cw.proofs[0], J)) | |
810 | 790 | then true | |
811 | - | else sigVerify( | |
791 | + | else sigVerify(cw.bodyBytes, cw.proofs[0], K)) | |
812 | 792 | then true | |
813 | - | else sigVerify( | |
814 | - | if (if (if (if ( | |
793 | + | else sigVerify(cw.bodyBytes, cw.proofs[0], M) | |
794 | + | if (if (if (if (cC) | |
815 | 795 | then true | |
816 | - | else | |
796 | + | else cD) | |
817 | 797 | then true | |
818 | - | else | |
819 | - | then | |
798 | + | else cE) | |
799 | + | then cF | |
820 | 800 | else false) | |
821 | 801 | then true | |
822 | - | else | |
802 | + | else cy | |
823 | 803 | } | |
824 | - | else | |
804 | + | else cy | |
825 | 805 | } | |
826 | 806 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 5 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let a = "1.0.0" | |
5 | 5 | ||
6 | 6 | let b = "version" | |
7 | 7 | ||
8 | 8 | let c = "active" | |
9 | 9 | ||
10 | 10 | let d = "A_asset_id" | |
11 | 11 | ||
12 | 12 | let e = "B_asset_id" | |
13 | 13 | ||
14 | 14 | let f = "A_asset_balance" | |
15 | 15 | ||
16 | 16 | let g = "B_asset_balance" | |
17 | 17 | ||
18 | 18 | let h = "A_asset_init" | |
19 | 19 | ||
20 | 20 | let i = "B_asset_init" | |
21 | 21 | ||
22 | 22 | let j = "share_asset_id" | |
23 | 23 | ||
24 | 24 | let k = "share_asset_supply" | |
25 | 25 | ||
26 | 26 | let l = "commission" | |
27 | 27 | ||
28 | 28 | let m = "commission_scale_delimiter" | |
29 | 29 | ||
30 | 30 | let n = "shutdown_cause" | |
31 | 31 | ||
32 | 32 | let o = "first_harvest" | |
33 | 33 | ||
34 | 34 | let p = "first_harvest_height" | |
35 | 35 | ||
36 | 36 | let q = "share_limit_on_first_harvest" | |
37 | 37 | ||
38 | 38 | let r = "base_period" | |
39 | 39 | ||
40 | 40 | let s = "period_length" | |
41 | 41 | ||
42 | 42 | let t = "start_height" | |
43 | 43 | ||
44 | 44 | let u = "staking_usdnnsbt_address" | |
45 | 45 | ||
46 | 46 | let v = "staking_eurn_address" | |
47 | 47 | ||
48 | 48 | let w = "leasing_address" | |
49 | 49 | ||
50 | 50 | let x = "leasing_amount" | |
51 | 51 | ||
52 | 52 | let y = "leasing_id" | |
53 | 53 | ||
54 | 54 | let z = "admin_pub_1" | |
55 | 55 | ||
56 | 56 | let A = "admin_pub_2" | |
57 | 57 | ||
58 | 58 | let B = "admin_pub_3" | |
59 | 59 | ||
60 | 60 | let C = Address(base58'3NBBWfzZtZtszaXbitTKnrB2xXwv26Bn7H9') | |
61 | 61 | ||
62 | 62 | func D (E) = { | |
63 | 63 | let F = getString(C, E) | |
64 | 64 | if ($isInstanceOf(F, "String")) | |
65 | 65 | then { | |
66 | 66 | let G = F | |
67 | 67 | fromBase58String(G) | |
68 | 68 | } | |
69 | 69 | else { | |
70 | 70 | let H = F | |
71 | 71 | throw("Admin public key is empty") | |
72 | 72 | } | |
73 | 73 | } | |
74 | 74 | ||
75 | 75 | ||
76 | 76 | let I = D(z) | |
77 | 77 | ||
78 | 78 | let J = D(A) | |
79 | 79 | ||
80 | 80 | let K = D(B) | |
81 | 81 | ||
82 | 82 | let L = base58'Kn7NpzaG12dLZgcHf2ipUftU6hbJygmrhFqQYE4B7ZK' | |
83 | 83 | ||
84 | 84 | let M = base58'Kn7NpzaG12dLZgcHf2ipUftU6hbJygmrhFqQYE4B7ZK' | |
85 | 85 | ||
86 | 86 | let N = Address(base58'3NAGTtZz6WpupSN89NZD5rMZwwziZEg4Kx4') | |
87 | 87 | ||
88 | 88 | let O = Address(base58'3MrJgdL1GniipErHy44YF9idzLaUL2iX5DQ') | |
89 | 89 | ||
90 | 90 | let P = base58'8UrfDVd5GreeUwm7uPk7eYz1eMv376kzR52C6sANPkwS' | |
91 | 91 | ||
92 | 92 | let Q = base58'36mg8NZTaFRDygiVwb8uBnLR51hetJruUCZcxhaVcHj9' | |
93 | 93 | ||
94 | 94 | let R = base58'ECBCkHS68DckpBrzLeoRgYbFg7sCVqR176mPqbXsj9pA' | |
95 | 95 | ||
96 | 96 | let S = ["WAVES", toBase58String(P), toBase58String(Q), toBase58String(R)] | |
97 | 97 | ||
98 | 98 | let T = Address(fromBase58String(valueOrErrorMessage(getString(C, u), "no usdn staking address"))) | |
99 | 99 | ||
100 | 100 | let U = Address(fromBase58String(valueOrErrorMessage(getString(C, v), "no usdn staking address"))) | |
101 | 101 | ||
102 | 102 | let V = Address(base58'3N8PGkzXhbtTvEwEQTtE2xiTJmsDEQ9XfoZ') | |
103 | 103 | ||
104 | 104 | let W = Address(base58'3MqW1t2cxdYy2emEMk3YtZkRwQPhHaTfWRe') | |
105 | 105 | ||
106 | 106 | let X = valueOrErrorMessage(getInteger(O, r), "Empty kBasePeriod") | |
107 | 107 | ||
108 | 108 | let Y = valueOrErrorMessage(getInteger(O, t), "Empty kStartHeight") | |
109 | 109 | ||
110 | 110 | let Z = valueOrErrorMessage(getInteger(O, s), "Empty kPeriodLength") | |
111 | 111 | ||
112 | 112 | let aa = ((X + ((height - Y) / Z)) + 3) | |
113 | 113 | ||
114 | 114 | let ab = getBooleanValue(this, c) | |
115 | 115 | ||
116 | 116 | let ac = getStringValue(this, d) | |
117 | 117 | ||
118 | 118 | let ad = getStringValue(this, e) | |
119 | 119 | ||
120 | 120 | let ae = if ((ac == "WAVES")) | |
121 | 121 | then unit | |
122 | 122 | else fromBase58String(ac) | |
123 | 123 | ||
124 | 124 | let af = if ((ad == "WAVES")) | |
125 | 125 | then unit | |
126 | 126 | else fromBase58String(ad) | |
127 | 127 | ||
128 | 128 | let ag = { | |
129 | 129 | let F = ae | |
130 | 130 | if ($isInstanceOf(F, "ByteVector")) | |
131 | 131 | then { | |
132 | 132 | let ah = F | |
133 | 133 | value(assetInfo(ah)).name | |
134 | 134 | } | |
135 | 135 | else if ($isInstanceOf(F, "Unit")) | |
136 | 136 | then { | |
137 | 137 | let ai = F | |
138 | 138 | "WAVES" | |
139 | 139 | } | |
140 | 140 | else throw("Match error") | |
141 | 141 | } | |
142 | 142 | ||
143 | 143 | let aj = { | |
144 | 144 | let F = af | |
145 | 145 | if ($isInstanceOf(F, "ByteVector")) | |
146 | 146 | then { | |
147 | 147 | let ah = F | |
148 | 148 | value(assetInfo(ah)).name | |
149 | 149 | } | |
150 | 150 | else if ($isInstanceOf(F, "Unit")) | |
151 | 151 | then { | |
152 | 152 | let ai = F | |
153 | 153 | "WAVES" | |
154 | 154 | } | |
155 | 155 | else throw("Match error") | |
156 | 156 | } | |
157 | 157 | ||
158 | 158 | let ak = getIntegerValue(this, f) | |
159 | 159 | ||
160 | 160 | let al = getIntegerValue(this, g) | |
161 | 161 | ||
162 | 162 | let am = fromBase58String(getStringValue(this, j)) | |
163 | 163 | ||
164 | 164 | let an = getIntegerValue(this, k) | |
165 | 165 | ||
166 | 166 | let ao = 3000 | |
167 | 167 | ||
168 | 168 | let ap = 1000000 | |
169 | 169 | ||
170 | 170 | let aq = 1000 | |
171 | 171 | ||
172 | 172 | let ar = 100000000 | |
173 | 173 | ||
174 | 174 | let as = 1000 | |
175 | 175 | ||
176 | 176 | func at (au) = { | |
177 | 177 | let F = au | |
178 | 178 | if ($isInstanceOf(F, "ByteVector")) | |
179 | 179 | then { | |
180 | 180 | let ah = F | |
181 | 181 | assetBalance(this, ah) | |
182 | 182 | } | |
183 | 183 | else if ($isInstanceOf(F, "Unit")) | |
184 | 184 | then { | |
185 | 185 | let ai = F | |
186 | 186 | wavesBalance(this).available | |
187 | 187 | } | |
188 | 188 | else throw("Match error") | |
189 | 189 | } | |
190 | 190 | ||
191 | 191 | ||
192 | 192 | func av (au) = { | |
193 | 193 | let aw = { | |
194 | 194 | let F = au | |
195 | 195 | if ($isInstanceOf(F, "ByteVector")) | |
196 | 196 | then { | |
197 | 197 | let ax = F | |
198 | 198 | if (if ((ax == P)) | |
199 | 199 | then true | |
200 | 200 | else (ax == Q)) | |
201 | 201 | then getInteger(T, ((("rpd_balance_" + toBase58String(ax)) + "_") + toString(this))) | |
202 | 202 | else if ((ax == R)) | |
203 | 203 | then getInteger(U, ((("%s%s%s__stakingBalance__" + toBase58String(ax)) + "__") + toString(this))) | |
204 | 204 | else 0 | |
205 | 205 | } | |
206 | 206 | else if ($isInstanceOf(F, "Unit")) | |
207 | 207 | then valueOrElse(getInteger(this, x), 0) | |
208 | 208 | else throw("Match error") | |
209 | 209 | } | |
210 | 210 | let F = aw | |
211 | 211 | if ($isInstanceOf(F, "Int")) | |
212 | 212 | then { | |
213 | 213 | let ay = F | |
214 | 214 | ay | |
215 | 215 | } | |
216 | 216 | else 0 | |
217 | 217 | } | |
218 | 218 | ||
219 | 219 | ||
220 | 220 | let az = av(ae) | |
221 | 221 | ||
222 | 222 | let aA = av(af) | |
223 | 223 | ||
224 | 224 | let aB = getIntegerValue(this, h) | |
225 | 225 | ||
226 | 226 | let aC = getIntegerValue(this, i) | |
227 | 227 | ||
228 | - | let aD = ( | |
228 | + | let aD = (at(ae) + az) | |
229 | 229 | ||
230 | - | let aE = ( | |
230 | + | let aE = (at(af) + aA) | |
231 | 231 | ||
232 | - | let aF = (at(ae) + az) | |
233 | - | ||
234 | - | let aG = (at(af) + aA) | |
235 | - | ||
236 | - | let aH = if ((aF >= ak)) | |
237 | - | then (aG >= al) | |
232 | + | let aF = if ((aD >= ak)) | |
233 | + | then (aE >= al) | |
238 | 234 | else false | |
239 | 235 | ||
240 | - | func | |
236 | + | func aG (au) = { | |
241 | 237 | let F = au | |
242 | 238 | if ($isInstanceOf(F, "ByteVector")) | |
243 | 239 | then { | |
244 | 240 | let ah = F | |
245 | - | let | |
246 | - | let | |
247 | - | $Tuple3( | |
241 | + | let aH = toBase58String(ah) | |
242 | + | let aI = valueOrErrorMessage(assetInfo(ah), (("Asset " + aH) + " doesn't exist")) | |
243 | + | $Tuple3(aH, aI.name, aI.decimals) | |
248 | 244 | } | |
249 | 245 | else if ($isInstanceOf(F, "Unit")) | |
250 | 246 | then { | |
251 | 247 | let ai = F | |
252 | 248 | $Tuple3("WAVES", "WAVES", 8) | |
253 | 249 | } | |
254 | 250 | else throw("Match error") | |
255 | 251 | } | |
256 | 252 | ||
257 | 253 | ||
258 | - | func | |
254 | + | func aJ (aK) = if ((aK == "WAVES")) | |
259 | 255 | then $Tuple3("WAVES", "WAVES", 8) | |
260 | 256 | else { | |
261 | - | let | |
262 | - | let ah = fromBase58String( | |
263 | - | let | |
264 | - | $Tuple3( | |
257 | + | let aH = aK | |
258 | + | let ah = fromBase58String(aK) | |
259 | + | let aI = valueOrErrorMessage(assetInfo(ah), (("Asset " + aH) + " doesn't exist")) | |
260 | + | $Tuple3(aH, aI.name, aI.decimals) | |
265 | 261 | } | |
266 | 262 | ||
267 | 263 | ||
268 | - | func | |
264 | + | func aL (aM) = [BooleanEntry(c, false), StringEntry(n, aM)] | |
269 | 265 | ||
270 | 266 | ||
271 | - | func | |
267 | + | func aN (aO,au) = if (aO) | |
272 | 268 | then if ((au == P)) | |
273 | 269 | then $Tuple2("lockNeutrino", T) | |
274 | 270 | else if ((au == Q)) | |
275 | 271 | then $Tuple2("lockNsbt", T) | |
276 | 272 | else $Tuple2("startStaking", U) | |
277 | 273 | else if ((au == P)) | |
278 | 274 | then $Tuple2("unlockNeutrino", T) | |
279 | 275 | else if ((au == Q)) | |
280 | 276 | then $Tuple2("unlockNsbt", T) | |
281 | 277 | else $Tuple2("stopStaking", U) | |
282 | 278 | ||
283 | 279 | ||
284 | - | func | |
280 | + | func aP (aO,aQ,au) = if (aO) | |
285 | 281 | then { | |
286 | - | let | |
287 | - | let | |
288 | - | let | |
289 | - | $Tuple4( | |
282 | + | let aR = aN(aO, au) | |
283 | + | let aS = aR._1 | |
284 | + | let aT = aR._2 | |
285 | + | $Tuple4(aS, aT, nil, [AttachedPayment(au, aQ)]) | |
290 | 286 | } | |
291 | 287 | else { | |
292 | - | let | |
293 | - | let | |
294 | - | let | |
295 | - | $Tuple4( | |
288 | + | let aU = aN(aO, au) | |
289 | + | let aS = aU._1 | |
290 | + | let aT = aU._2 | |
291 | + | $Tuple4(aS, aT, [aQ, toBase58String(au)], nil) | |
296 | 292 | } | |
297 | 293 | ||
298 | 294 | ||
299 | - | func aX (aS,aY,aZ) = throw((((((((("Insufficient DApp balance to pay " + toString(aS)) + " ") + aZ) + " due to staking. Available: ") + toString(aY)) + " ") + aZ) + ". Please contact support in Telegram: https://t.me/swopfisupport")) | |
300 | - | ||
301 | - | ||
302 | - | func ba (bb,bc) = throw((((((((((((((((("Insufficient DApp balance to pay " + toString(bb)) + " ") + ag) + " and ") + toString(bc)) + " ") + aj) + " due to staking. Available: ") + toString(aD)) + " ") + ag) + " and ") + toString(aE)) + " ") + aj) + ". Please contact support in Telegram: https://t.me/swopfisupport")) | |
303 | - | ||
304 | - | ||
305 | - | func bd () = aN(((((((((((((((("Suspicious state. Actual balances: " + toString(aF)) + " ") + ag) + ", ") + toString(aG)) + " ") + aj) + ". State: ") + toString(ak)) + " ") + ag) + ", ") + toString(al)) + " ") + aj)) | |
295 | + | func aV () = aL(((((((((((((((("Suspicious state. Actual balances: " + toString(aD)) + " ") + ag) + ", ") + toString(aE)) + " ") + aj) + ". State: ") + toString(ak)) + " ") + ag) + ", ") + toString(al)) + " ") + aj)) | |
306 | 296 | ||
307 | 297 | ||
308 | 298 | @Callable(ay) | |
309 | - | func init ( | |
310 | - | let | |
311 | - | let | |
312 | - | let | |
313 | - | let | |
314 | - | let | |
315 | - | let | |
316 | - | let | |
317 | - | let | |
318 | - | let | |
319 | - | let | |
320 | - | let | |
321 | - | let | |
322 | - | let | |
323 | - | let | |
299 | + | func init (aW) = { | |
300 | + | let aX = $Tuple2(ay.payments[0].amount, ay.payments[0].assetId) | |
301 | + | let aY = aX._1 | |
302 | + | let aZ = aX._2 | |
303 | + | let ba = $Tuple2(ay.payments[1].amount, ay.payments[1].assetId) | |
304 | + | let bb = ba._1 | |
305 | + | let bc = ba._2 | |
306 | + | let bd = aG(aZ) | |
307 | + | let be = bd._1 | |
308 | + | let bf = bd._2 | |
309 | + | let bg = bd._3 | |
310 | + | let bh = aG(bc) | |
311 | + | let bi = bh._1 | |
312 | + | let bj = bh._2 | |
313 | + | let bk = bh._3 | |
324 | 314 | if (!(containsElement([I, J, K, M], ay.callerPublicKey))) | |
325 | 315 | then throw("Only admin can call this function") | |
326 | 316 | else if (isDefined(getBoolean(this, c))) | |
327 | 317 | then throw("DApp is already active") | |
328 | - | else if (( | |
318 | + | else if ((aZ == bc)) | |
329 | 319 | then throw("Assets must be different") | |
330 | 320 | else { | |
331 | - | let | |
332 | - | let | |
333 | - | let | |
334 | - | let | |
335 | - | let | |
336 | - | let | |
337 | - | let | |
338 | - | let | |
339 | - | let | |
340 | - | let | |
341 | - | then invoke(this, "stakeUnstake", [true, | |
321 | + | let bl = ((("s" + take(bf, 7)) + "_") + take(bj, 7)) | |
322 | + | let bm = ((((("ShareToken of SwopFi protocol for " + bf) + " and ") + bj) + " at address ") + toString(this)) | |
323 | + | let bn = ((bg + bk) / 2) | |
324 | + | let bo = pow(aY, bg, 5, 1, bg, DOWN) | |
325 | + | let bp = pow(bb, bk, 5, 1, bk, DOWN) | |
326 | + | let bq = pow(10, 0, bn, 0, 0, DOWN) | |
327 | + | let br = fraction(bo, bp, bq) | |
328 | + | let bs = Issue(bl, bm, br, bn, true) | |
329 | + | let bt = calculateAssetId(bs) | |
330 | + | let bu = if (containsElement(S, be)) | |
331 | + | then invoke(this, "stakeUnstake", [true, aY, be], nil) | |
342 | 332 | else 0 | |
343 | - | if (( | |
333 | + | if ((bu == bu)) | |
344 | 334 | then { | |
345 | - | let | |
346 | - | then invoke(this, "stakeUnstake", [true, | |
335 | + | let bv = if (containsElement(S, bi)) | |
336 | + | then invoke(this, "stakeUnstake", [true, bb, bi], nil) | |
347 | 337 | else 0 | |
348 | - | if (( | |
338 | + | if ((bv == bv)) | |
349 | 339 | then { | |
350 | - | let | |
351 | - | if ( | |
352 | - | then ( | |
353 | - | else | |
340 | + | let bw = [StringEntry(b, a), BooleanEntry(c, true), StringEntry(d, be), StringEntry(e, bi), IntegerEntry(f, aY), IntegerEntry(g, bb), IntegerEntry(l, ao), IntegerEntry(m, ap), bs, StringEntry(j, toBase58String(bt)), IntegerEntry(k, br), ScriptTransfer(ay.caller, br, bt)] | |
341 | + | if (aW) | |
342 | + | then (bw ++ [BooleanEntry(o, aW), IntegerEntry(p, (Y + (aa * Z)))]) | |
343 | + | else bw | |
354 | 344 | } | |
355 | 345 | else throw("Strict value is not equal to itself.") | |
356 | 346 | } | |
357 | 347 | else throw("Strict value is not equal to itself.") | |
358 | 348 | } | |
359 | 349 | } | |
360 | 350 | ||
361 | 351 | ||
362 | 352 | ||
363 | 353 | @Callable(ay) | |
364 | - | func initWithInitRatio ( | |
365 | - | let | |
366 | - | let | |
367 | - | let | |
368 | - | let | |
369 | - | let | |
370 | - | let | |
371 | - | let | |
372 | - | let | |
354 | + | func initWithInitRatio (bx,by,ac,ad,aW) = { | |
355 | + | let bz = aJ(ac) | |
356 | + | let be = bz._1 | |
357 | + | let bf = bz._2 | |
358 | + | let bg = bz._3 | |
359 | + | let bA = aJ(ad) | |
360 | + | let bi = bA._1 | |
361 | + | let bj = bA._2 | |
362 | + | let bk = bA._3 | |
373 | 363 | if (!(containsElement([I, J, K, M], ay.callerPublicKey))) | |
374 | 364 | then throw("Only admin can call this function") | |
375 | 365 | else if (isDefined(getBoolean(this, c))) | |
376 | 366 | then throw("DApp is already active") | |
377 | 367 | else if ((ac == ad)) | |
378 | 368 | then throw("Assets must be different") | |
379 | 369 | else { | |
380 | - | let | |
381 | - | let | |
382 | - | let | |
383 | - | let | |
384 | - | let | |
385 | - | let | |
386 | - | let | |
387 | - | if ( | |
388 | - | then ( | |
389 | - | else | |
370 | + | let bl = ((("s" + take(bf, 7)) + "_") + take(bj, 7)) | |
371 | + | let bm = ((((("ShareToken of SwopFi protocol for " + bf) + " and ") + bj) + " at address ") + toString(this)) | |
372 | + | let bn = ((bg + bk) / 2) | |
373 | + | let br = 0 | |
374 | + | let bs = Issue(bl, bm, br, bn, true) | |
375 | + | let bt = calculateAssetId(bs) | |
376 | + | let bw = [StringEntry(b, a), BooleanEntry(c, true), StringEntry(d, be), StringEntry(e, bi), IntegerEntry(h, bx), IntegerEntry(i, by), IntegerEntry(f, 0), IntegerEntry(g, 0), IntegerEntry(l, ao), IntegerEntry(m, ap), bs, StringEntry(j, toBase58String(bt)), IntegerEntry(k, br)] | |
377 | + | if (aW) | |
378 | + | then (bw ++ [BooleanEntry(o, aW), IntegerEntry(p, (Y + (aa * Z)))]) | |
379 | + | else bw | |
390 | 380 | } | |
391 | 381 | } | |
392 | 382 | ||
393 | 383 | ||
394 | 384 | ||
395 | 385 | @Callable(ay) | |
396 | - | func keepLimitForFirstHarvest ( | |
386 | + | func keepLimitForFirstHarvest (bB) = if (!(ab)) | |
397 | 387 | then throw("DApp is inactive at this moment") | |
398 | 388 | else if (!(containsElement([I, J, K, M], ay.callerPublicKey))) | |
399 | 389 | then throw("Only admin can call this function") | |
400 | - | else [IntegerEntry(q, | |
390 | + | else [IntegerEntry(q, bB)] | |
401 | 391 | ||
402 | 392 | ||
403 | 393 | ||
404 | 394 | @Callable(ay) | |
405 | - | func replenishWithTwoTokens ( | |
406 | - | let | |
407 | - | let | |
408 | - | let | |
409 | - | let | |
410 | - | let | |
411 | - | let | |
412 | - | let | |
413 | - | let | |
414 | - | let | |
415 | - | let | |
416 | - | let | |
417 | - | let | |
395 | + | func replenishWithTwoTokens (bC) = { | |
396 | + | let aZ = ay.payments[0].assetId | |
397 | + | let bc = ay.payments[1].assetId | |
398 | + | let aY = ay.payments[0].amount | |
399 | + | let bb = ay.payments[1].amount | |
400 | + | let bD = aG(aZ) | |
401 | + | let be = bD._1 | |
402 | + | let bf = bD._2 | |
403 | + | let bg = bD._3 | |
404 | + | let bE = aG(bc) | |
405 | + | let bi = bE._1 | |
406 | + | let bj = bE._2 | |
407 | + | let bk = bE._3 | |
418 | 408 | if (if ((ak == 0)) | |
419 | 409 | then (al == 0) | |
420 | 410 | else false) | |
421 | 411 | then { | |
422 | - | let | |
423 | - | if (( | |
412 | + | let bF = fraction(fraction(aB, ar, aY), aq, fraction(aC, ar, bb)) | |
413 | + | if ((aZ == bc)) | |
424 | 414 | then throw("Assets must be different") | |
425 | 415 | else { | |
426 | - | let | |
427 | - | let | |
416 | + | let bn = ((bg + bk) / 2) | |
417 | + | let br = fraction(pow(aY, bg, 5, 1, bg, DOWN), pow(bb, bk, 5, 1, bk, DOWN), pow(10, 0, bn, 0, 0, DOWN)) | |
428 | 418 | if (!(ab)) | |
429 | 419 | then throw("DApp is inactive at this moment") | |
430 | - | else if (if ((0 > | |
420 | + | else if (if ((0 > bC)) | |
431 | 421 | then true | |
432 | - | else ( | |
433 | - | then throw(((("Slippage tolerance must be between 0 and " + toString(as)) + " inclusively. Actual: ") + toString( | |
422 | + | else (bC > as)) | |
423 | + | then throw(((("Slippage tolerance must be between 0 and " + toString(as)) + " inclusively. Actual: ") + toString(bC))) | |
434 | 424 | else if ((size(ay.payments) != 2)) | |
435 | 425 | then throw("Two attached assets expected") | |
436 | - | else if (if ((((aq * (as - | |
426 | + | else if (if ((((aq * (as - bC)) / as) > bF)) | |
437 | 427 | then true | |
438 | - | else ( | |
428 | + | else (bF > ((aq * (as + bC)) / as))) | |
439 | 429 | then throw("Incorrect assets amount: amounts must have the contract ratio") | |
440 | - | else if (if (( | |
430 | + | else if (if ((aZ != ae)) | |
441 | 431 | then true | |
442 | - | else ( | |
432 | + | else (bc != af)) | |
443 | 433 | then throw(((("Incorrect assets attached. Expected: " + ac) + " and ") + ad)) | |
444 | - | else if (( | |
434 | + | else if ((br == 0)) | |
445 | 435 | then throw("Too small amount to replenish") | |
446 | - | else if (!( | |
447 | - | then ([ScriptTransfer(ay.caller, | |
436 | + | else if (!(aF)) | |
437 | + | then ([ScriptTransfer(ay.caller, aY, aZ), ScriptTransfer(ay.caller, bb, bc)] ++ aV()) | |
448 | 438 | else { | |
449 | - | let | |
450 | - | then invoke(this, "stakeUnstake", [true, | |
439 | + | let bu = if (containsElement(S, be)) | |
440 | + | then invoke(this, "stakeUnstake", [true, aY, be], nil) | |
451 | 441 | else 0 | |
452 | - | if (( | |
442 | + | if ((bu == bu)) | |
453 | 443 | then { | |
454 | - | let | |
455 | - | then invoke(this, "stakeUnstake", [true, | |
444 | + | let bv = if (containsElement(S, bi)) | |
445 | + | then invoke(this, "stakeUnstake", [true, bb, bi], nil) | |
456 | 446 | else 0 | |
457 | - | if (( | |
458 | - | then [Reissue(am, | |
447 | + | if ((bv == bv)) | |
448 | + | then [Reissue(am, br, true), IntegerEntry(f, aY), IntegerEntry(g, bb), IntegerEntry(k, br), ScriptTransfer(ay.caller, br, am)] | |
459 | 449 | else throw("Strict value is not equal to itself.") | |
460 | 450 | } | |
461 | 451 | else throw("Strict value is not equal to itself.") | |
462 | 452 | } | |
463 | 453 | } | |
464 | 454 | } | |
465 | 455 | else { | |
466 | - | let | |
467 | - | let | |
468 | - | let | |
469 | - | let | |
456 | + | let bF = fraction(fraction(ak, ar, aY), aq, fraction(al, ar, bb)) | |
457 | + | let bG = fraction(aY, ar, ak) | |
458 | + | let bH = fraction(bb, ar, al) | |
459 | + | let bI = fraction(min([bG, bH]), an, ar) | |
470 | 460 | if (!(ab)) | |
471 | 461 | then throw("DApp is inactive at this moment") | |
472 | - | else if (if ((0 > | |
462 | + | else if (if ((0 > bC)) | |
473 | 463 | then true | |
474 | - | else ( | |
475 | - | then throw(((("Slippage tolerance must be between 0 and " + toString(as)) + " inclusively. Actual: ") + toString( | |
464 | + | else (bC > as)) | |
465 | + | then throw(((("Slippage tolerance must be between 0 and " + toString(as)) + " inclusively. Actual: ") + toString(bC))) | |
476 | 466 | else if ((size(ay.payments) != 2)) | |
477 | 467 | then throw("Two attached assets expected") | |
478 | - | else if (if (( | |
468 | + | else if (if ((aZ != ae)) | |
479 | 469 | then true | |
480 | - | else ( | |
470 | + | else (bc != af)) | |
481 | 471 | then throw(((("Incorrect assets attached. Expected: " + ac) + " and ") + ad)) | |
482 | - | else if (if ((((aq * (as - | |
472 | + | else if (if ((((aq * (as - bC)) / as) > bF)) | |
483 | 473 | then true | |
484 | - | else ( | |
474 | + | else (bF > ((aq * (as + bC)) / as))) | |
485 | 475 | then throw("Incorrect assets amount: amounts must have the contract ratio") | |
486 | - | else if (( | |
476 | + | else if ((bI == 0)) | |
487 | 477 | then throw("Too small amount to replenish") | |
488 | - | else if (!( | |
489 | - | then ([ScriptTransfer(ay.caller, | |
478 | + | else if (!(aF)) | |
479 | + | then ([ScriptTransfer(ay.caller, aY, aZ), ScriptTransfer(ay.caller, bb, bc)] ++ aV()) | |
490 | 480 | else { | |
491 | - | let | |
492 | - | then invoke(this, "stakeUnstake", [true, | |
481 | + | let bu = if (containsElement(S, be)) | |
482 | + | then invoke(this, "stakeUnstake", [true, aY, be], nil) | |
493 | 483 | else 0 | |
494 | - | if (( | |
484 | + | if ((bu == bu)) | |
495 | 485 | then { | |
496 | - | let | |
497 | - | then invoke(this, "stakeUnstake", [true, | |
486 | + | let bv = if (containsElement(S, bi)) | |
487 | + | then invoke(this, "stakeUnstake", [true, bb, bi], nil) | |
498 | 488 | else 0 | |
499 | - | if (( | |
500 | - | then [IntegerEntry(f, (ak + | |
489 | + | if ((bv == bv)) | |
490 | + | then [IntegerEntry(f, (ak + aY)), IntegerEntry(g, (al + bb)), IntegerEntry(k, (an + bI)), Reissue(am, bI, true), ScriptTransfer(ay.caller, bI, am)] | |
501 | 491 | else throw("Strict value is not equal to itself.") | |
502 | 492 | } | |
503 | 493 | else throw("Strict value is not equal to itself.") | |
504 | 494 | } | |
505 | 495 | } | |
506 | 496 | } | |
507 | 497 | ||
508 | 498 | ||
509 | 499 | ||
510 | 500 | @Callable(ay) | |
511 | 501 | func withdraw () = { | |
512 | - | let | |
513 | - | let | |
514 | - | let | |
515 | - | let | |
516 | - | let | |
502 | + | let bJ = $Tuple2(ay.payments[0].amount, ay.payments[0].assetId) | |
503 | + | let bK = bJ._1 | |
504 | + | let bL = bJ._2 | |
505 | + | let bM = fraction(bK, ak, an) | |
506 | + | let bN = fraction(bK, al, an) | |
517 | 507 | if (!(ab)) | |
518 | 508 | then throw("DApp is inactive at this moment") | |
519 | 509 | else if ((size(ay.payments) != 1)) | |
520 | 510 | then throw("One attached payment expected") | |
521 | - | else if (( | |
511 | + | else if ((bL != am)) | |
522 | 512 | then throw(("Incorrect asset attached. Expected: " + toBase58String(am))) | |
523 | - | else if (!(aH)) | |
524 | - | then ([ScriptTransfer(ay.caller, bS, bT)] ++ bd()) | |
525 | - | else if (if ((bU > aD)) | |
526 | - | then true | |
527 | - | else (bV > aE)) | |
528 | - | then ba(bU, bV) | |
529 | - | else { | |
530 | - | let bC = if (containsElement(S, ac)) | |
531 | - | then invoke(this, "stakeUnstake", [false, bU, ac], nil) | |
532 | - | else 0 | |
533 | - | if ((bC == bC)) | |
534 | - | then { | |
535 | - | let bD = if (containsElement(S, ad)) | |
536 | - | then invoke(this, "stakeUnstake", [false, bV, ad], nil) | |
537 | - | else 0 | |
538 | - | if ((bD == bD)) | |
539 | - | then [IntegerEntry(f, (ak - bU)), IntegerEntry(g, (al - bV)), IntegerEntry(k, (an - bS)), Burn(am, bS), ScriptTransfer(ay.caller, bU, ae), ScriptTransfer(ay.caller, bV, af)] | |
540 | - | else throw("Strict value is not equal to itself.") | |
541 | - | } | |
542 | - | else throw("Strict value is not equal to itself.") | |
543 | - | } | |
513 | + | else if (!(aF)) | |
514 | + | then ([ScriptTransfer(ay.caller, bK, bL)] ++ aV()) | |
515 | + | else { | |
516 | + | let bu = if (containsElement(S, ac)) | |
517 | + | then invoke(this, "stakeUnstake", [false, bM, ac], nil) | |
518 | + | else 0 | |
519 | + | if ((bu == bu)) | |
520 | + | then { | |
521 | + | let bv = if (containsElement(S, ad)) | |
522 | + | then invoke(this, "stakeUnstake", [false, bN, ad], nil) | |
523 | + | else 0 | |
524 | + | if ((bv == bv)) | |
525 | + | then [IntegerEntry(f, (ak - bM)), IntegerEntry(g, (al - bN)), IntegerEntry(k, (an - bK)), Burn(am, bK), ScriptTransfer(ay.caller, bM, ae), ScriptTransfer(ay.caller, bN, af)] | |
526 | + | else throw("Strict value is not equal to itself.") | |
527 | + | } | |
528 | + | else throw("Strict value is not equal to itself.") | |
529 | + | } | |
544 | 530 | } | |
545 | 531 | ||
546 | 532 | ||
547 | 533 | ||
548 | 534 | @Callable(ay) | |
549 | - | func exchange ( | |
550 | - | let | |
551 | - | let | |
552 | - | let | |
553 | - | func | |
554 | - | let | |
555 | - | let | |
556 | - | let | |
557 | - | if (( | |
558 | - | then throw(((("Calculated amount to receive " + toString( | |
559 | - | else $Tuple3( | |
535 | + | func exchange (bO) = { | |
536 | + | let bP = $Tuple2(ay.payments[0].amount, ay.payments[0].assetId) | |
537 | + | let bK = bP._1 | |
538 | + | let bL = bP._2 | |
539 | + | func bQ (bR,bS) = { | |
540 | + | let bT = fraction(bS, bK, (bK + bR)) | |
541 | + | let bU = fraction(bT, (ap - ao), ap) | |
542 | + | let bV = fraction(bT, commissionGovernance, ap) | |
543 | + | if ((bO > bU)) | |
544 | + | then throw(((("Calculated amount to receive " + toString(bU)) + " is less than specified minimum ") + toString(bO))) | |
545 | + | else $Tuple3(bT, bU, bV) | |
560 | 546 | } | |
561 | 547 | ||
562 | 548 | if (!(ab)) | |
563 | 549 | then throw("DApp is inactive at this moment") | |
564 | 550 | else if (if ((ak == 0)) | |
565 | 551 | then true | |
566 | 552 | else (al == 0)) | |
567 | 553 | then throw("Can't exchange with zero balance") | |
568 | - | else if ((0 >= | |
569 | - | then throw(("Minimal amount to receive must be positive. Actual: " + toString( | |
554 | + | else if ((0 >= bO)) | |
555 | + | then throw(("Minimal amount to receive must be positive. Actual: " + toString(bO))) | |
570 | 556 | else if ((size(ay.payments) != 1)) | |
571 | 557 | then throw("One attached payment expected") | |
572 | - | else if (!( | |
573 | - | then ([ScriptTransfer(ay.caller, | |
574 | - | else if (( | |
558 | + | else if (!(aF)) | |
559 | + | then ([ScriptTransfer(ay.caller, bK, bL)] ++ aV()) | |
560 | + | else if ((bL == ae)) | |
575 | 561 | then { | |
576 | - | let | |
577 | - | let | |
578 | - | let | |
579 | - | let | |
580 | - | let | |
581 | - | let | |
582 | - | let | |
583 | - | let | |
584 | - | then invoke(this, "stakeUnstake", [true, | |
562 | + | let bW = af | |
563 | + | let bX = bQ(ak, al) | |
564 | + | let bT = bX._1 | |
565 | + | let bU = bX._2 | |
566 | + | let bV = bX._3 | |
567 | + | let bY = (ak + bK) | |
568 | + | let bZ = ((al - bU) - bV) | |
569 | + | let bu = if (containsElement(S, ac)) | |
570 | + | then invoke(this, "stakeUnstake", [true, bK, ac], nil) | |
585 | 571 | else 0 | |
586 | - | if (( | |
572 | + | if ((bu == bu)) | |
587 | 573 | then { | |
588 | - | let | |
589 | - | then invoke(this, "stakeUnstake", [false, ( | |
574 | + | let bv = if (containsElement(S, ad)) | |
575 | + | then invoke(this, "stakeUnstake", [false, (bU + bV), ad], nil) | |
590 | 576 | else 0 | |
591 | - | if (( | |
592 | - | then [IntegerEntry(f, | |
577 | + | if ((bv == bv)) | |
578 | + | then [IntegerEntry(f, bY), IntegerEntry(g, bZ), ScriptTransfer(ay.caller, bU, bW), ScriptTransfer(N, bV, bW)] | |
593 | 579 | else throw("Strict value is not equal to itself.") | |
594 | 580 | } | |
595 | 581 | else throw("Strict value is not equal to itself.") | |
596 | 582 | } | |
597 | - | else if (( | |
583 | + | else if ((bL == af)) | |
598 | 584 | then { | |
599 | - | let | |
600 | - | let | |
601 | - | let | |
602 | - | let | |
603 | - | let | |
604 | - | let | |
605 | - | let | |
606 | - | if ( | |
607 | - | then | |
608 | - | else | |
609 | - | | |
610 | - | | |
611 | - | let | |
612 | - | then invoke(this, "stakeUnstake", [ | |
585 | + | let bW = ae | |
586 | + | let ca = bQ(al, ak) | |
587 | + | let bT = ca._1 | |
588 | + | let bU = ca._2 | |
589 | + | let bV = ca._3 | |
590 | + | let bY = ((ak - bU) - bV) | |
591 | + | let bZ = (al + bK) | |
592 | + | let bu = if (containsElement(S, ac)) | |
593 | + | then invoke(this, "stakeUnstake", [false, (bU + bV), ac], nil) | |
594 | + | else 0 | |
595 | + | if ((bu == bu)) | |
596 | + | then { | |
597 | + | let bv = if (containsElement(S, ad)) | |
598 | + | then invoke(this, "stakeUnstake", [true, bK, ad], nil) | |
613 | 599 | else 0 | |
614 | - | if ((bC == bC)) | |
615 | - | then { | |
616 | - | let bD = if (containsElement(S, ad)) | |
617 | - | then invoke(this, "stakeUnstake", [true, bS, ad], nil) | |
618 | - | else 0 | |
619 | - | if ((bD == bD)) | |
620 | - | then [IntegerEntry(f, cg), IntegerEntry(g, ch), ScriptTransfer(ay.caller, cc, ce), ScriptTransfer(N, cd, ce)] | |
621 | - | else throw("Strict value is not equal to itself.") | |
622 | - | } | |
600 | + | if ((bv == bv)) | |
601 | + | then [IntegerEntry(f, bY), IntegerEntry(g, bZ), ScriptTransfer(ay.caller, bU, bW), ScriptTransfer(N, bV, bW)] | |
623 | 602 | else throw("Strict value is not equal to itself.") | |
624 | 603 | } | |
604 | + | else throw("Strict value is not equal to itself.") | |
625 | 605 | } | |
626 | 606 | else throw(((("Incorrect asset attached. Expected: " + ac) + " or ") + ad)) | |
627 | 607 | } | |
628 | 608 | ||
629 | 609 | ||
630 | 610 | ||
631 | 611 | @Callable(ay) | |
632 | 612 | func shutdown () = if (!(ab)) | |
633 | 613 | then throw(("DApp is already suspended. Cause: " + valueOrElse(getString(this, n), "the cause wasn't specified"))) | |
634 | 614 | else if (!(containsElement([I, J, K, L], ay.callerPublicKey))) | |
635 | 615 | then throw("Only admin can call this function") | |
636 | - | else | |
616 | + | else aL("Paused by admin") | |
637 | 617 | ||
638 | 618 | ||
639 | 619 | ||
640 | 620 | @Callable(ay) | |
641 | 621 | func activate () = if (ab) | |
642 | 622 | then throw("DApp is already active") | |
643 | 623 | else if (!(containsElement([I, J, K, L], ay.callerPublicKey))) | |
644 | 624 | then throw("Only admin can call this function") | |
645 | 625 | else [BooleanEntry(c, true), DeleteEntry(n)] | |
646 | 626 | ||
647 | 627 | ||
648 | 628 | ||
649 | 629 | @Callable(ay) | |
650 | - | func takeIntoAccountExtraFunds ( | |
651 | - | let | |
652 | - | let | |
653 | - | let | |
654 | - | then | |
630 | + | func takeIntoAccountExtraFunds (cb) = { | |
631 | + | let cc = (aD - ak) | |
632 | + | let cd = (aE - al) | |
633 | + | let ce = (cc - (if ((ae == unit)) | |
634 | + | then cb | |
655 | 635 | else 0)) | |
656 | - | let | |
657 | - | then | |
636 | + | let cf = (cd - (if ((af == unit)) | |
637 | + | then cb | |
658 | 638 | else 0)) | |
659 | 639 | if (!(ab)) | |
660 | 640 | then throw("DApp is inactive at this moment") | |
661 | 641 | else if ((ay.caller != this)) | |
662 | 642 | then throw("Only the DApp itself can call this function") | |
663 | - | else if ((0 > | |
664 | - | then throw(("Argument 'amountLeave' cannot be negative. Actual: " + toString( | |
665 | - | else if (if ((0 > | |
643 | + | else if ((0 > cb)) | |
644 | + | then throw(("Argument 'amountLeave' cannot be negative. Actual: " + toString(cb))) | |
645 | + | else if (if ((0 > cc)) | |
666 | 646 | then true | |
667 | - | else (0 > | |
668 | - | then | |
669 | - | else if (if ((0 > | |
647 | + | else (0 > cd)) | |
648 | + | then aL("Enroll amount negative") | |
649 | + | else if (if ((0 > ce)) | |
670 | 650 | then true | |
671 | - | else (0 > | |
651 | + | else (0 > cf)) | |
672 | 652 | then throw("Too large amountLeave") | |
673 | 653 | else { | |
674 | - | let | |
675 | - | then ( | |
654 | + | let bu = if (if (containsElement(S, ac)) | |
655 | + | then (ce > 0) | |
676 | 656 | else false) | |
677 | - | then invoke(this, "stakeUnstake", [true, | |
657 | + | then invoke(this, "stakeUnstake", [true, ce, ac], nil) | |
678 | 658 | else 0 | |
679 | - | if (( | |
659 | + | if ((bu == bu)) | |
680 | 660 | then { | |
681 | - | let | |
682 | - | then ( | |
661 | + | let bv = if (if (containsElement(S, ad)) | |
662 | + | then (cf > 0) | |
683 | 663 | else false) | |
684 | - | then invoke(this, "stakeUnstake", [true, | |
664 | + | then invoke(this, "stakeUnstake", [true, cf, ad], nil) | |
685 | 665 | else 0 | |
686 | - | if (( | |
687 | - | then [IntegerEntry(f, (ak + | |
666 | + | if ((bv == bv)) | |
667 | + | then [IntegerEntry(f, (ak + ce)), IntegerEntry(g, (al + cf)), IntegerEntry(("last_income_" + ac), ce), IntegerEntry(("last_income_" + ad), cf)] | |
688 | 668 | else throw("Strict value is not equal to itself.") | |
689 | 669 | } | |
690 | 670 | else throw("Strict value is not equal to itself.") | |
691 | 671 | } | |
692 | 672 | } | |
693 | 673 | ||
694 | 674 | ||
695 | 675 | ||
696 | 676 | @Callable(ay) | |
697 | - | func stakeUnstake (aQ, | |
677 | + | func stakeUnstake (aO,aQ,cg) = if ((ay.caller != this)) | |
698 | 678 | then throw("Only contract itself can invoke this function") | |
699 | - | else if (( | |
679 | + | else if ((cg == "WAVES")) | |
700 | 680 | then { | |
701 | - | let | |
702 | - | let | |
703 | - | let | |
704 | - | let | |
705 | - | then ( | |
706 | - | else ( | |
707 | - | let | |
708 | - | let | |
709 | - | let | |
710 | - | let F = | |
681 | + | let ch = addressFromStringValue(valueOrErrorMessage(getString(C, w), "No leasing pool in oracle")) | |
682 | + | let ci = getBinary(this, y) | |
683 | + | let cj = valueOrElse(getInteger(this, x), 0) | |
684 | + | let ck = if (aO) | |
685 | + | then (cj + aQ) | |
686 | + | else (cj - aQ) | |
687 | + | let cl = Lease(ch, ck) | |
688 | + | let cm = calculateLeaseId(cl) | |
689 | + | let cn = [cl, BinaryEntry(y, cm), IntegerEntry(x, ck)] | |
690 | + | let F = ci | |
711 | 691 | if ($isInstanceOf(F, "ByteVector")) | |
712 | 692 | then { | |
713 | - | let | |
714 | - | ([LeaseCancel( | |
693 | + | let co = F | |
694 | + | ([LeaseCancel(co)] ++ cn) | |
715 | 695 | } | |
716 | - | else | |
696 | + | else cn | |
717 | 697 | } | |
718 | 698 | else { | |
719 | - | let | |
720 | - | let | |
721 | - | let | |
722 | - | let | |
723 | - | let | |
724 | - | let | |
725 | - | if (( | |
699 | + | let cp = aP(aO, aQ, fromBase58String(cg)) | |
700 | + | let aS = cp._1 | |
701 | + | let cq = cp._2 | |
702 | + | let cr = cp._3 | |
703 | + | let cs = cp._4 | |
704 | + | let ct = invoke(cq, aS, cr, cs) | |
705 | + | if ((ct == ct)) | |
726 | 706 | then nil | |
727 | 707 | else throw("Strict value is not equal to itself.") | |
728 | 708 | } | |
729 | 709 | ||
730 | 710 | ||
731 | 711 | ||
732 | 712 | @Callable(ay) | |
733 | 713 | func stakeAll () = if (!(ab)) | |
734 | 714 | then throw("DApp is inactive at this moment") | |
735 | 715 | else if (!(containsElement([I, J, K, L], ay.callerPublicKey))) | |
736 | 716 | then throw("Only admin can call this function") | |
737 | 717 | else { | |
738 | - | let | |
718 | + | let bu = if (containsElement(S, ac)) | |
739 | 719 | then { | |
740 | - | let | |
741 | - | if (( | |
742 | - | then invoke(this, "stakeUnstake", [true, | |
720 | + | let cu = (ak - az) | |
721 | + | if ((cu > 0)) | |
722 | + | then invoke(this, "stakeUnstake", [true, cu, ac], nil) | |
743 | 723 | else 0 | |
744 | 724 | } | |
745 | 725 | else 0 | |
746 | - | if (( | |
726 | + | if ((bu == bu)) | |
747 | 727 | then { | |
748 | - | let | |
728 | + | let bv = if (containsElement(S, ad)) | |
749 | 729 | then { | |
750 | - | let | |
751 | - | if (( | |
752 | - | then invoke(this, "stakeUnstake", [true, | |
730 | + | let cv = (al - aA) | |
731 | + | if ((cv > 0)) | |
732 | + | then invoke(this, "stakeUnstake", [true, cv, ad], nil) | |
753 | 733 | else 0 | |
754 | 734 | } | |
755 | 735 | else 0 | |
756 | - | if (( | |
736 | + | if ((bv == bv)) | |
757 | 737 | then nil | |
758 | 738 | else throw("Strict value is not equal to itself.") | |
759 | 739 | } | |
760 | 740 | else throw("Strict value is not equal to itself.") | |
761 | 741 | } | |
762 | 742 | ||
763 | 743 | ||
764 | - | @Verifier( | |
765 | - | func | |
766 | - | let | |
767 | - | let | |
744 | + | @Verifier(cw) | |
745 | + | func cx () = { | |
746 | + | let cy = { | |
747 | + | let cz = if (sigVerify(cw.bodyBytes, cw.proofs[0], I)) | |
768 | 748 | then 1 | |
769 | 749 | else 0 | |
770 | - | let | |
750 | + | let cA = if (sigVerify(cw.bodyBytes, cw.proofs[1], J)) | |
771 | 751 | then 1 | |
772 | 752 | else 0 | |
773 | - | let | |
753 | + | let cB = if (sigVerify(cw.bodyBytes, cw.proofs[2], K)) | |
774 | 754 | then 1 | |
775 | 755 | else 0 | |
776 | - | ((( | |
756 | + | (((cz + cA) + cB) >= 2) | |
777 | 757 | } | |
778 | - | let F = | |
758 | + | let F = cw | |
779 | 759 | if ($isInstanceOf(F, "InvokeScriptTransaction")) | |
780 | 760 | then { | |
781 | - | let | |
782 | - | let | |
783 | - | then ( | |
761 | + | let ct = F | |
762 | + | let cC = if ((ct.dApp == this)) | |
763 | + | then (ct.function == "takeIntoAccountExtraFunds") | |
784 | 764 | else false | |
785 | - | let | |
786 | - | then ( | |
765 | + | let cD = if (if (if ((ct.dApp == V)) | |
766 | + | then (ct.function == "exchange") | |
787 | 767 | else false) | |
788 | 768 | then (ae == P) | |
789 | 769 | else false) | |
790 | 770 | then true | |
791 | 771 | else if (if ((af == P)) | |
792 | - | then (size( | |
772 | + | then (size(ct.payments) == 1) | |
793 | 773 | else false) | |
794 | - | then ( | |
774 | + | then (ct.payments[0].assetId == P) | |
795 | 775 | else false | |
796 | - | let | |
797 | - | then ( | |
776 | + | let cE = if (if (if ((ct.dApp == W)) | |
777 | + | then (ct.function == "exchange") | |
798 | 778 | else false) | |
799 | 779 | then (ae == Q) | |
800 | 780 | else false) | |
801 | 781 | then true | |
802 | 782 | else if (if ((af == Q)) | |
803 | - | then (size( | |
783 | + | then (size(ct.payments) == 1) | |
804 | 784 | else false) | |
805 | - | then ( | |
785 | + | then (ct.payments[0].assetId == P) | |
806 | 786 | else false | |
807 | - | let | |
787 | + | let cF = if (if (if (sigVerify(cw.bodyBytes, cw.proofs[0], I)) | |
808 | 788 | then true | |
809 | - | else sigVerify( | |
789 | + | else sigVerify(cw.bodyBytes, cw.proofs[0], J)) | |
810 | 790 | then true | |
811 | - | else sigVerify( | |
791 | + | else sigVerify(cw.bodyBytes, cw.proofs[0], K)) | |
812 | 792 | then true | |
813 | - | else sigVerify( | |
814 | - | if (if (if (if ( | |
793 | + | else sigVerify(cw.bodyBytes, cw.proofs[0], M) | |
794 | + | if (if (if (if (cC) | |
815 | 795 | then true | |
816 | - | else | |
796 | + | else cD) | |
817 | 797 | then true | |
818 | - | else | |
819 | - | then | |
798 | + | else cE) | |
799 | + | then cF | |
820 | 800 | else false) | |
821 | 801 | then true | |
822 | - | else | |
802 | + | else cy | |
823 | 803 | } | |
824 | - | else | |
804 | + | else cy | |
825 | 805 | } | |
826 | 806 |
github/deemru/w8io/026f985 233.52 ms ◑