tx · E5AveZhi12RNfidhzu9NkbAu8WsJrf4inH8HYKNb4ioS 3MvRWw2FPEimFCTGtK7qY9uAJbM7XJ4ZfJS: -0.04300000 Waves 2023.06.24 10:47 [2636406] smart account 3MvRWw2FPEimFCTGtK7qY9uAJbM7XJ4ZfJS > SELF 0.00000000 Waves
{ "type": 13, "id": "E5AveZhi12RNfidhzu9NkbAu8WsJrf4inH8HYKNb4ioS", "fee": 4300000, "feeAssetId": null, "timestamp": 1687592844036, "version": 2, "chainId": 84, "sender": "3MvRWw2FPEimFCTGtK7qY9uAJbM7XJ4ZfJS", "senderPublicKey": "HP8sssVq1866F7CaPQJwgFrt6fsqhQjKwM84cL1wjD2a", "proofs": [ "27f5B8X9126AqvpHeZz9qCvyjssMfdfMLe99z7rW2C2vHChD7C61m5kc4wLyCRQL9tJRyWLSgvv3T1nkxbJxtLi7" ], "script": "base64:BgKKAQgCEgcKBQgBCAEBEgMKAQgSBAoCCAgSBQoDCBgYEgUKAwgBCBIECgIIARIGCgQBCAgBEgUKAwEICBIDCgEIEgMKAQgSBQoDCAgBEgYKBAgBCAgSDgoMCAgIAQQRGBgRAQEYEgoKCAgICAEECAEYEg4KDAgICAEEGBgYGBgBGBIKCggICAEBAQEBAWYAB1NGX1BPT0wCAlNGAAdXWF9QT09MAgJXWAAPQ0FQX0ZFRV9OT19MT0FOAgljYXBOb0xvYW4ADENBUF9GRUVfTE9BTgIHY2FwTG9hbgAUU1RPUExPU1NfRkVFX05PX0xPQU4CDnN0b3BMb3NzTm9Mb2FuAA1TVE9QTE9TU19MT0FOAgxzdG9wTG9zc0xvYW4ACExPQU5fRkVFAgRsb2FuAAtOT19MT0FOX0ZFRQIGbm9Mb2FuAAZOT19GRUUCBW5vRmVlAAZTQ0FMRTgAgMLXLwAHU0NBTEUxMACAyK+gJQAHU0NBTEUxNgkAtgIBAICAhP6m3uERAApGRUVfU0NBTEU2AMCEPQAUa1NGUG9vbEFBc3NldEJhbGFuY2UCD0FfYXNzZXRfYmF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UCdHgJYm9keUJ5dGVzCQCRAwIIBQJ0eAZwcm9vZnMAAAgFAnR4D3NlbmRlclB1YmxpY0tleejkqPk=", "height": 2636406, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 4Fk7bYx6xdHRcB3w32CBpszvhVbawza5M9qHPY7eyDc9 Next: 6D9wtUz83iSGDkhLU1GPC6C5RkFHETkmvyZZe5eXczrr Diff:
Old | New | Differences | |
---|---|---|---|
465 | 465 | let bO = bN._1 | |
466 | 466 | let bP = bN._2 | |
467 | 467 | let bQ = bN._3 | |
468 | - | let | |
469 | - | if (( | |
468 | + | let bR = invoke(bO, bP, bQ, nil) | |
469 | + | if ((bR == bR)) | |
470 | 470 | then bL | |
471 | 471 | else throw("Strict value is not equal to itself.") | |
472 | 472 | } | |
473 | 473 | ||
474 | 474 | ||
475 | - | func | |
475 | + | func bS (aD,bT,bU,ax,ay,bV,bW) = { | |
476 | 476 | let aq = Address(fromBase58String(aD)) | |
477 | - | let | |
478 | - | let | |
479 | - | let | |
480 | - | let | |
477 | + | let bX = 1000000 | |
478 | + | let bY = getIntegerValue(aq, t) | |
479 | + | let bZ = fraction(bV, bX, (bX - bY)) | |
480 | + | let ca = if ((bW == bT)) | |
481 | 481 | then { | |
482 | - | let | |
483 | - | $Tuple2( | |
482 | + | let cb = fraction(ax, bZ, (ay - bZ)) | |
483 | + | $Tuple2(cb, bU) | |
484 | 484 | } | |
485 | 485 | else { | |
486 | - | let | |
487 | - | $Tuple2( | |
486 | + | let cb = fraction(ay, bZ, (ax - bZ)) | |
487 | + | $Tuple2(cb, bT) | |
488 | 488 | } | |
489 | - | let | |
490 | - | let | |
491 | - | $Tuple2( | |
489 | + | let cb = ca._1 | |
490 | + | let cc = ca._2 | |
491 | + | $Tuple2(cc, cb) | |
492 | 492 | } | |
493 | 493 | ||
494 | 494 | ||
495 | - | func | |
496 | - | let | |
497 | - | let | |
498 | - | let | |
499 | - | let | |
495 | + | func cd (aD,bT,bU,ax,ay,bV,bW) = { | |
496 | + | let ce = getIntegerValue(ab, "%s__protocolFee") | |
497 | + | let cf = getIntegerValue(ab, "%s__poolFee") | |
498 | + | let cg = toBigInt(100000000) | |
499 | + | let ch = if ((bW == bT)) | |
500 | 500 | then { | |
501 | - | let | |
502 | - | $Tuple2( | |
501 | + | let cb = fraction(ax, bV, (ay - bV)) | |
502 | + | $Tuple2(cb, bU) | |
503 | 503 | } | |
504 | 504 | else { | |
505 | - | let | |
506 | - | $Tuple2( | |
505 | + | let cb = fraction(ay, bV, (ax - bV)) | |
506 | + | $Tuple2(cb, bT) | |
507 | 507 | } | |
508 | - | let | |
509 | - | let | |
510 | - | let | |
511 | - | $Tuple2( | |
508 | + | let cb = ch._1 | |
509 | + | let cc = ch._2 | |
510 | + | let ci = toInt(fraction(toBigInt(cb), cg, (cg - toBigInt((ce + cf))))) | |
511 | + | $Tuple2(cc, ci) | |
512 | 512 | } | |
513 | 513 | ||
514 | 514 | ||
515 | - | func | |
515 | + | func cj (aA,aD,bT,bU,ax,ay,bV,bW) = if ((aA == a)) | |
516 | 516 | then { | |
517 | - | let | |
518 | - | let | |
519 | - | let | |
520 | - | invoke(addressFromStringValue(aD), "callFunction", ["exchange", ["1"]], [AttachedPayment(aO( | |
517 | + | let ck = bS(aD, bT, bU, ax, ay, bV, bW) | |
518 | + | let cc = ck._1 | |
519 | + | let cb = ck._2 | |
520 | + | invoke(addressFromStringValue(aD), "callFunction", ["exchange", ["1"]], [AttachedPayment(aO(cc), cb)]) | |
521 | 521 | } | |
522 | 522 | else { | |
523 | - | let | |
524 | - | let | |
525 | - | let | |
526 | - | invoke(ab, "swap", [1, | |
523 | + | let cl = cd(aD, bT, bU, ax, ay, bV, bW) | |
524 | + | let cc = cl._1 | |
525 | + | let cb = cl._2 | |
526 | + | invoke(ab, "swap", [1, bW, toString(this)], [AttachedPayment(aO(cc), cb)]) | |
527 | 527 | } | |
528 | 528 | ||
529 | 529 | ||
530 | - | func | |
530 | + | func cm (bf,aD,bx,au,by,av,ax,ay) = { | |
531 | 531 | let aq = addressFromStringValue(aD) | |
532 | 532 | if ((bf == a)) | |
533 | 533 | then { | |
534 | - | let | |
534 | + | let bR = { | |
535 | 535 | let at = invoke(aq, "callFunction", ["calcLPReplenishDiffPropREADONLY", [toString(bx), toString(by), "0"]], nil) | |
536 | 536 | if ($isInstanceOf(at, "List[Any]")) | |
537 | 537 | then at | |
538 | 538 | else throw(($getType(at) + " couldn't be cast to List[Any]")) | |
539 | 539 | } | |
540 | - | if (( | |
540 | + | if ((bR == bR)) | |
541 | 541 | then $Tuple2({ | |
542 | - | let at = | |
542 | + | let at = bR[0] | |
543 | 543 | if ($isInstanceOf(at, "Int")) | |
544 | 544 | then at | |
545 | 545 | else throw(($getType(at) + " couldn't be cast to Int")) | |
546 | 546 | }, { | |
547 | - | let at = | |
547 | + | let at = bR[1] | |
548 | 548 | if ($isInstanceOf(at, "Int")) | |
549 | 549 | then at | |
550 | 550 | else throw(($getType(at) + " couldn't be cast to Int")) | |
553 | 553 | } | |
554 | 554 | else if ((bf == b)) | |
555 | 555 | then { | |
556 | - | let | |
556 | + | let cn = if (if ((bx > 0)) | |
557 | 557 | then (by > 0) | |
558 | 558 | else false) | |
559 | 559 | then { | |
560 | - | let | |
561 | - | let | |
562 | - | let | |
563 | - | let | |
564 | - | let | |
565 | - | let | |
566 | - | $Tuple3( | |
560 | + | let co = bw(bf, aq, bx, au, by, av, ax, ay) | |
561 | + | let cp = co._1 | |
562 | + | let cq = co._2 | |
563 | + | let cr = co._3 | |
564 | + | let cs = co._4 | |
565 | + | let ct = co._5 | |
566 | + | $Tuple3(cr, cs, ct) | |
567 | 567 | } | |
568 | 568 | else if ((bx > 0)) | |
569 | 569 | then $Tuple3(bx, au, 0) | |
570 | 570 | else $Tuple3(by, av, 0) | |
571 | - | let | |
572 | - | let | |
573 | - | let | |
574 | - | let | |
571 | + | let cr = cn._1 | |
572 | + | let cs = cn._2 | |
573 | + | let cu = cn._3 | |
574 | + | let cv = if ((cr > 0)) | |
575 | 575 | then { | |
576 | - | let | |
577 | - | let at = invoke(aq, "putOneTknREADONLY", [ | |
576 | + | let bR = { | |
577 | + | let at = invoke(aq, "putOneTknREADONLY", [cs, cr], nil) | |
578 | 578 | if ($isInstanceOf(at, "(Int, Int, Int)")) | |
579 | 579 | then at | |
580 | 580 | else throw(($getType(at) + " couldn't be cast to (Int, Int, Int)")) | |
581 | 581 | } | |
582 | - | if (( | |
583 | - | then $Tuple2( | |
582 | + | if ((bR == bR)) | |
583 | + | then $Tuple2(bR._1, bR._3) | |
584 | 584 | else throw("Strict value is not equal to itself.") | |
585 | 585 | } | |
586 | 586 | else $Tuple2(0, 0) | |
587 | - | let | |
588 | - | let | |
589 | - | $Tuple2(( | |
587 | + | let cw = cv._1 | |
588 | + | let cx = cv._2 | |
589 | + | $Tuple2((cu + cw), cx) | |
590 | 590 | } | |
591 | 591 | else throw("Wrong pool type") | |
592 | 592 | } | |
593 | 593 | ||
594 | 594 | ||
595 | - | func | |
595 | + | func cy (bf,aD,ct,aw,au,av,ax,ay,cz,cA) = { | |
596 | 596 | let aq = addressFromStringValue(aD) | |
597 | - | let | |
597 | + | let cB = if ((bf == a)) | |
598 | 598 | then { | |
599 | - | let | |
600 | - | let at = invoke(aq, "callFunction", ["withdrawREADONLY", [toString( | |
599 | + | let bR = { | |
600 | + | let at = invoke(aq, "callFunction", ["withdrawREADONLY", [toString(ct), toString(ax), toString(ay)]], nil) | |
601 | 601 | if ($isInstanceOf(at, "List[Any]")) | |
602 | 602 | then at | |
603 | 603 | else throw(($getType(at) + " couldn't be cast to List[Any]")) | |
604 | 604 | } | |
605 | - | if (( | |
605 | + | if ((bR == bR)) | |
606 | 606 | then $Tuple2({ | |
607 | - | let at = | |
607 | + | let at = bR[0] | |
608 | 608 | if ($isInstanceOf(at, "Int")) | |
609 | 609 | then at | |
610 | 610 | else throw(($getType(at) + " couldn't be cast to Int")) | |
611 | 611 | }, { | |
612 | - | let at = | |
612 | + | let at = bR[1] | |
613 | 613 | if ($isInstanceOf(at, "Int")) | |
614 | 614 | then at | |
615 | 615 | else throw(($getType(at) + " couldn't be cast to Int")) | |
618 | 618 | } | |
619 | 619 | else if ((bf == b)) | |
620 | 620 | then { | |
621 | - | let | |
622 | - | let at = invoke(aq, "evaluateGetREADONLY", [aw, | |
621 | + | let cC = split({ | |
622 | + | let at = invoke(aq, "evaluateGetREADONLY", [aw, ct], nil) | |
623 | 623 | if ($isInstanceOf(at, "String")) | |
624 | 624 | then at | |
625 | 625 | else throw(($getType(at) + " couldn't be cast to String")) | |
626 | 626 | }, "__") | |
627 | - | if (( | |
628 | - | then $Tuple2(parseIntValue( | |
627 | + | if ((cC == cC)) | |
628 | + | then $Tuple2(parseIntValue(cC[1]), parseIntValue(cC[2])) | |
629 | 629 | else throw("Strict value is not equal to itself.") | |
630 | 630 | } | |
631 | 631 | else throw("Wrong pool type") | |
632 | - | let | |
633 | - | let | |
634 | - | if (( | |
632 | + | let cD = cB._1 | |
633 | + | let cE = cB._2 | |
634 | + | if ((cz > 0)) | |
635 | 635 | then { | |
636 | - | let | |
637 | - | then ( | |
636 | + | let cF = if (if ((cA == au)) | |
637 | + | then (cz > cD) | |
638 | 638 | else false) | |
639 | - | then ( | |
640 | - | else if (if (( | |
641 | - | then ( | |
639 | + | then (cz - cD) | |
640 | + | else if (if ((cA == av)) | |
641 | + | then (cz > cE) | |
642 | 642 | else false) | |
643 | - | then ( | |
643 | + | then (cz - cE) | |
644 | 644 | else 0 | |
645 | - | let | |
645 | + | let cG = if ((cF > 0)) | |
646 | 646 | then if ((bf == a)) | |
647 | - | then | |
648 | - | else | |
647 | + | then bS(aD, au, av, ax, ay, cF, cA) | |
648 | + | else cd(aD, au, av, ax, ay, cF, cA) | |
649 | 649 | else $Tuple2("", 0) | |
650 | - | let | |
651 | - | let | |
652 | - | if (( | |
653 | - | then $Tuple2((( | |
654 | - | else $Tuple2(( | |
650 | + | let cc = cG._1 | |
651 | + | let cb = cG._2 | |
652 | + | if ((cA == au)) | |
653 | + | then $Tuple2(((cD + cF) - cz), (cE - cb)) | |
654 | + | else $Tuple2((cD - cb), ((cE + cF) - cz)) | |
655 | 655 | } | |
656 | - | else $Tuple2( | |
656 | + | else $Tuple2(cD, cE) | |
657 | 657 | } | |
658 | 658 | ||
659 | 659 | ||
660 | - | func | |
660 | + | func cH (aA,aD) = if ((aA == a)) | |
661 | 661 | then { | |
662 | - | let | |
663 | - | if (( | |
662 | + | let cI = ak(ac) | |
663 | + | if ((cI == cI)) | |
664 | 664 | then { | |
665 | - | let | |
666 | - | if (( | |
665 | + | let bR = invoke(aJ(), "claim", [aD], nil) | |
666 | + | if ((bR == bR)) | |
667 | 667 | then { | |
668 | - | let | |
669 | - | $Tuple2(( | |
668 | + | let cJ = ak(ac) | |
669 | + | $Tuple2((cJ - cI), ac) | |
670 | 670 | } | |
671 | 671 | else throw("Strict value is not equal to itself.") | |
672 | 672 | } | |
674 | 674 | } | |
675 | 675 | else if ((aA == b)) | |
676 | 676 | then { | |
677 | - | let | |
678 | - | if (( | |
677 | + | let cI = ak(ad) | |
678 | + | if ((cI == cI)) | |
679 | 679 | then { | |
680 | - | let | |
681 | - | if (( | |
680 | + | let bR = invoke(aK(Address(fromBase58String(aD))), "claimWX", [aD], nil) | |
681 | + | if ((bR == bR)) | |
682 | 682 | then { | |
683 | - | let | |
684 | - | $Tuple2(( | |
683 | + | let cJ = ak(ad) | |
684 | + | $Tuple2((cJ - cI), ad) | |
685 | 685 | } | |
686 | 686 | else throw("Strict value is not equal to itself.") | |
687 | 687 | } | |
690 | 690 | else throw("Wrong pool type") | |
691 | 691 | ||
692 | 692 | ||
693 | - | func | |
694 | - | let | |
695 | - | if (( | |
693 | + | func cK (bf,aD,aI,bx,au,by,av,ax,ay,cL) = { | |
694 | + | let cM = ak(fromBase58String(cL)) | |
695 | + | if ((cM == cM)) | |
696 | 696 | then { | |
697 | 697 | let aq = addressFromStringValue(aD) | |
698 | - | let | |
698 | + | let cN = if (if ((bx > 0)) | |
699 | 699 | then (by > 0) | |
700 | 700 | else false) | |
701 | 701 | then { | |
702 | - | let | |
703 | - | let | |
704 | - | let | |
705 | - | let | |
706 | - | let | |
707 | - | let | |
708 | - | if (( | |
709 | - | then $Tuple2( | |
702 | + | let cO = bw(bf, aq, bx, au, by, av, ax, ay) | |
703 | + | let cp = cO._1 | |
704 | + | let cq = cO._2 | |
705 | + | let cr = cO._3 | |
706 | + | let cs = cO._4 | |
707 | + | let bR = bG(aq, bf, cp, au, cq, av) | |
708 | + | if ((bR == bR)) | |
709 | + | then $Tuple2(cr, cs) | |
710 | 710 | else throw("Strict value is not equal to itself.") | |
711 | 711 | } | |
712 | 712 | else if ((bx > 0)) | |
714 | 714 | else if ((by > 0)) | |
715 | 715 | then $Tuple2(by, av) | |
716 | 716 | else throw("pmts must be > 0") | |
717 | - | let | |
718 | - | let | |
719 | - | let | |
720 | - | then bI(aq, bf, | |
717 | + | let cr = cN._1 | |
718 | + | let cs = cN._2 | |
719 | + | let bR = if ((cr > 0)) | |
720 | + | then bI(aq, bf, cr, cs) | |
721 | 721 | else nil | |
722 | - | if (( | |
722 | + | if ((bR == bR)) | |
723 | 723 | then { | |
724 | - | let | |
725 | - | let | |
726 | - | let | |
727 | - | let | |
728 | - | if ((0 >= | |
724 | + | let cP = ak(fromBase58String(cL)) | |
725 | + | let cQ = (cP - cM) | |
726 | + | let cR = fraction(cQ, aH(aD, aI), m) | |
727 | + | let cS = (cQ - cR) | |
728 | + | if ((0 >= cS)) | |
729 | 729 | then throw("amount of staked sharetokens must be > 0") | |
730 | 730 | else { | |
731 | - | let | |
732 | - | if (( | |
733 | - | then $Tuple2( | |
731 | + | let cT = bK(aD, bf, cL, cS) | |
732 | + | if ((cT == cT)) | |
733 | + | then $Tuple2(cS, cR) | |
734 | 734 | else throw("Strict value is not equal to itself.") | |
735 | 735 | } | |
736 | 736 | } | |
740 | 740 | } | |
741 | 741 | ||
742 | 742 | ||
743 | - | func | |
744 | - | let | |
745 | - | let | |
746 | - | let | |
747 | - | then $Tuple2(getIntegerValue(this, (aD + C)), ( | |
748 | - | else $Tuple2(getIntegerValue(this, (aD + D)), | |
749 | - | let | |
750 | - | let | |
751 | - | [IntegerEntry((aD + A), ( | |
743 | + | func cU (aD,aG,cV,cR,cW,aw,aA,cX) = { | |
744 | + | let cY = aC(aD) | |
745 | + | let cZ = aE(aD) | |
746 | + | let da = if (cX) | |
747 | + | then $Tuple2(getIntegerValue(this, (aD + C)), (cZ + cV)) | |
748 | + | else $Tuple2(getIntegerValue(this, (aD + D)), cZ) | |
749 | + | let db = da._1 | |
750 | + | let dc = da._2 | |
751 | + | [IntegerEntry((aD + A), (cY + cV)), IntegerEntry((aD + B), dc), IntegerEntry((((((aD + "_") + aG) + "_") + toString(cW)) + u), cV), IntegerEntry((((((aD + "_") + aG) + "_") + toString(cW)) + z), db), StringEntry((((aG + "_") + toString(cW)) + v), aD), IntegerEntry((aG + y), cW), ScriptTransfer(Y, cR, fromBase58String(aw))] | |
752 | 752 | } | |
753 | 753 | ||
754 | 754 | ||
755 | - | func | |
756 | - | let | |
757 | - | if (( | |
755 | + | func dd (de,df,dg,dh,di,dj,dk,dl,dm,dn) = { | |
756 | + | let do = ak(aO(de)) | |
757 | + | if ((do == do)) | |
758 | 758 | then { | |
759 | - | let | |
760 | - | if (( | |
761 | - | then (ak(aO( | |
759 | + | let bR = invoke(Z, "swap", [dh, di, dj, dk, dl, dm, dn], [AttachedPayment(dg, df)]) | |
760 | + | if ((bR == bR)) | |
761 | + | then (ak(aO(de)) - do) | |
762 | 762 | else throw("Strict value is not equal to itself.") | |
763 | 763 | } | |
764 | 764 | else throw("Strict value is not equal to itself.") | |
765 | 765 | } | |
766 | 766 | ||
767 | 767 | ||
768 | - | func | |
769 | - | let | |
770 | - | if (( | |
768 | + | func dp (de,df,dg,dq,dr,dn) = { | |
769 | + | let do = ak(aO(de)) | |
770 | + | if ((do == do)) | |
771 | 771 | then { | |
772 | - | let | |
773 | - | if (( | |
774 | - | then (ak(aO( | |
772 | + | let bR = invoke(Z, "puzzleSwap", [dq, dr, dn], [AttachedPayment(dg, df)]) | |
773 | + | if ((bR == bR)) | |
774 | + | then (ak(aO(de)) - do) | |
775 | 775 | else throw("Strict value is not equal to itself.") | |
776 | 776 | } | |
777 | 777 | else throw("Strict value is not equal to itself.") | |
778 | 778 | } | |
779 | 779 | ||
780 | 780 | ||
781 | - | func | |
782 | - | let | |
783 | - | if (( | |
781 | + | func ds (de,df,dg,dt,du,dv,dw,dx,dy,dn) = { | |
782 | + | let do = ak(aO(de)) | |
783 | + | if ((do == do)) | |
784 | 784 | then { | |
785 | - | let | |
786 | - | if (( | |
787 | - | then (ak(aO( | |
785 | + | let bR = invoke(Z, "swopfiSwap", [dt, du, dv, dw, dx, dy, dn], [AttachedPayment(dg, df)]) | |
786 | + | if ((bR == bR)) | |
787 | + | then (ak(aO(de)) - do) | |
788 | 788 | else throw("Strict value is not equal to itself.") | |
789 | 789 | } | |
790 | 790 | else throw("Strict value is not equal to itself.") | |
791 | 791 | } | |
792 | 792 | ||
793 | 793 | ||
794 | - | func | |
794 | + | func dz (aD,bf,dA,dB) = { | |
795 | 795 | let aq = Address(fromBase58String(aD)) | |
796 | - | let | |
797 | - | let | |
798 | - | let | |
799 | - | let ax = | |
800 | - | let ay = | |
801 | - | let aw = | |
802 | - | if (if (( | |
803 | - | then ( | |
796 | + | let dC = az(aq, bf) | |
797 | + | let dD = dC._1 | |
798 | + | let dE = dC._2 | |
799 | + | let ax = dC._3 | |
800 | + | let ay = dC._4 | |
801 | + | let aw = dC._5 | |
802 | + | if (if ((dA != dD)) | |
803 | + | then (dA != dE) | |
804 | 804 | else false) | |
805 | 805 | then throw("Wrong asset") | |
806 | 806 | else { | |
807 | - | let | |
808 | - | then $Tuple2( | |
809 | - | else $Tuple2(0, | |
810 | - | let bx = | |
811 | - | let by = | |
812 | - | let | |
813 | - | let | |
814 | - | let | |
815 | - | let | |
816 | - | let | |
817 | - | let | |
818 | - | let | |
819 | - | let | |
820 | - | let | |
821 | - | let | |
822 | - | let | |
823 | - | then ( | |
807 | + | let dF = if ((dA == dD)) | |
808 | + | then $Tuple2(dB, 0) | |
809 | + | else $Tuple2(0, dB) | |
810 | + | let bx = dF._1 | |
811 | + | let by = dF._2 | |
812 | + | let dG = cK(bf, aD, i, bx, dD, by, dE, ax, ay, aw) | |
813 | + | let cV = dG._1 | |
814 | + | let dH = dG._2 | |
815 | + | let dI = valueOrElse(getInteger(this, (aD + C)), 0) | |
816 | + | let dJ = valueOrElse(getInteger(this, (aD + D)), 0) | |
817 | + | let dK = aC(aD) | |
818 | + | let dL = aE(aD) | |
819 | + | let dM = fraction(dL, j, dK) | |
820 | + | let dN = fraction(cV, dM, j) | |
821 | + | let dO = (cV - dN) | |
822 | + | let dP = if ((dL > 0)) | |
823 | + | then (dI + fraction(dN, k, dL)) | |
824 | 824 | else 0 | |
825 | - | let | |
826 | - | then ( | |
825 | + | let dQ = if (((dK - dL) > 0)) | |
826 | + | then (dJ + fraction(dO, k, (dK - dL))) | |
827 | 827 | else 0 | |
828 | - | let | |
829 | - | let | |
830 | - | let | |
831 | - | if (( | |
832 | - | then ([IntegerEntry((aD + C), | |
828 | + | let dR = fraction(dN, aH(aD, d), m) | |
829 | + | let dS = fraction(dO, aH(aD, c), m) | |
830 | + | let dT = bM(aD, bf, aw, (dR + dS)) | |
831 | + | if ((dT == dT)) | |
832 | + | then ([IntegerEntry((aD + C), dP), IntegerEntry((aD + D), dQ), IntegerEntry((aD + A), ((dK + cV) - dT)), IntegerEntry((aD + B), ((dL + dN) - dR)), ScriptTransfer(Y, (dR + dS), fromBase58String(aw))] ++ bs(dD, dE, aw)) | |
833 | 833 | else throw("Strict value is not equal to itself.") | |
834 | 834 | } | |
835 | 835 | } | |
836 | 836 | ||
837 | 837 | ||
838 | - | func | |
838 | + | func dU (aD,dV,dW,dX) = { | |
839 | 839 | let aq = Address(fromBase58String(aD)) | |
840 | 840 | let bf = valueOrErrorMessage(getString(this, (M + aD)), "Unknown pool") | |
841 | - | let | |
842 | - | let | |
843 | - | let | |
844 | - | let ax = | |
845 | - | let ay = | |
846 | - | let aw = | |
847 | - | let | |
848 | - | if (( | |
841 | + | let dY = az(aq, bf) | |
842 | + | let bT = dY._1 | |
843 | + | let bU = dY._2 | |
844 | + | let ax = dY._3 | |
845 | + | let ay = dY._4 | |
846 | + | let aw = dY._5 | |
847 | + | let dZ = ak(aO(bT)) | |
848 | + | if ((dZ == dZ)) | |
849 | 849 | then { | |
850 | - | let | |
851 | - | if (( | |
850 | + | let ea = ak(aO(bU)) | |
851 | + | if ((ea == ea)) | |
852 | 852 | then { | |
853 | - | let | |
854 | - | then invoke(aq, "callFunction", ["withdraw", [toString( | |
853 | + | let bR = if ((bf == a)) | |
854 | + | then invoke(aq, "callFunction", ["withdraw", [toString(dV)]], nil) | |
855 | 855 | else { | |
856 | - | let | |
857 | - | if (( | |
858 | - | then invoke(aq, "get", nil, [AttachedPayment(aO(aw), | |
856 | + | let bR = bM(aD, bf, aw, dV) | |
857 | + | if ((bR == bR)) | |
858 | + | then invoke(aq, "get", nil, [AttachedPayment(aO(aw), dV)]) | |
859 | 859 | else throw("Strict value is not equal to itself.") | |
860 | 860 | } | |
861 | - | if (( | |
861 | + | if ((bR == bR)) | |
862 | 862 | then { | |
863 | - | let ea = ak(aO(bS)) | |
864 | 863 | let eb = ak(aO(bT)) | |
865 | - | let ec = $Tuple2((ea - dY), (eb - dZ)) | |
866 | - | let ed = ec._1 | |
867 | - | let ee = ec._2 | |
868 | - | let ef = if ((dV > 0)) | |
864 | + | let ec = ak(aO(bU)) | |
865 | + | let ed = $Tuple2((eb - dZ), (ec - ea)) | |
866 | + | let ee = ed._1 | |
867 | + | let ef = ed._2 | |
868 | + | let eg = if ((dW > 0)) | |
869 | 869 | then { | |
870 | - | let | |
871 | - | then ( | |
870 | + | let cF = if (if ((dX == bT)) | |
871 | + | then (dW > ee) | |
872 | 872 | else false) | |
873 | - | then ( | |
874 | - | else if (if (( | |
875 | - | then ( | |
873 | + | then (dW - ee) | |
874 | + | else if (if ((dX == bU)) | |
875 | + | then (dW > ef) | |
876 | 876 | else false) | |
877 | - | then ( | |
877 | + | then (dW - ef) | |
878 | 878 | else 0 | |
879 | - | let | |
880 | - | then | |
879 | + | let eh = if ((cF > 0)) | |
880 | + | then cj(bf, aD, bT, bU, ax, ay, cF, dX) | |
881 | 881 | else 0 | |
882 | - | if (( | |
882 | + | if ((eh == eh)) | |
883 | 883 | then { | |
884 | - | let eh = ak(aO(bS)) | |
885 | 884 | let ei = ak(aO(bT)) | |
886 | - | $Tuple2((eh - dY), (ei - dZ)) | |
885 | + | let ej = ak(aO(bU)) | |
886 | + | $Tuple2((ei - dZ), (ej - ea)) | |
887 | 887 | } | |
888 | 888 | else throw("Strict value is not equal to itself.") | |
889 | 889 | } | |
890 | - | else $Tuple2( | |
891 | - | let | |
892 | - | let | |
893 | - | $Tuple7( | |
890 | + | else $Tuple2(ee, ef) | |
891 | + | let ek = eg._1 | |
892 | + | let el = eg._2 | |
893 | + | $Tuple7(ek, bT, el, bU, eb, ec, aw) | |
894 | 894 | } | |
895 | 895 | else throw("Strict value is not equal to itself.") | |
896 | 896 | } | |
900 | 900 | } | |
901 | 901 | ||
902 | 902 | ||
903 | - | func | |
904 | - | let | |
905 | - | let | |
906 | - | let | |
903 | + | func em (aG,aD,en,eo) = { | |
904 | + | let ep = valueOrErrorMessage(getInteger(this, (((((aD + "_") + aG) + "_") + en) + u)), "Unknown position") | |
905 | + | let eq = getIntegerValue(this, (((((aD + "_") + aG) + "_") + en) + z)) | |
906 | + | let er = if (eo) | |
907 | 907 | then getIntegerValue(this, (aD + C)) | |
908 | 908 | else getIntegerValue(this, (aD + D)) | |
909 | - | ( | |
909 | + | (ep + fraction(ep, (er - eq), k)) | |
910 | 910 | } | |
911 | 911 | ||
912 | 912 | ||
913 | - | func | |
914 | - | let | |
915 | - | let | |
916 | - | let | |
917 | - | let | |
918 | - | let | |
919 | - | let | |
920 | - | let | |
921 | - | let | |
913 | + | func es (aG,aD,en,et) = { | |
914 | + | let ep = valueOrErrorMessage(getInteger(this, (((((aD + "_") + aG) + "_") + en) + u)), "Unknown position") | |
915 | + | let eq = getIntegerValue(this, (((((aD + "_") + aG) + "_") + en) + z)) | |
916 | + | let cz = valueOrElse(getInteger(this, (((((aD + "_") + aG) + "_") + en) + w)), 0) | |
917 | + | let dV = em(aG, aD, en, (cz > 0)) | |
918 | + | let eu = aC(aD) | |
919 | + | let ev = Address(fromBase58String(aG)) | |
920 | + | let dX = valueOrElse(getString(this, (((((aD + "_") + aG) + "_") + en) + x)), "") | |
921 | + | let dW = if ((cz > 0)) | |
922 | 922 | then { | |
923 | - | let at = invoke(ae(), "getAssetDebt", [false, ((aG + "_") + | |
923 | + | let at = invoke(ae(), "getAssetDebt", [false, ((aG + "_") + en), dX], nil) | |
924 | 924 | if ($isInstanceOf(at, "Int")) | |
925 | 925 | then at | |
926 | 926 | else throw(($getType(at) + " couldn't be cast to Int")) | |
927 | 927 | } | |
928 | 928 | else 0 | |
929 | - | let | |
930 | - | if (( | |
929 | + | let ew = dU(aD, dV, dW, dX) | |
930 | + | if ((ew == ew)) | |
931 | 931 | then { | |
932 | - | let aw = | |
933 | - | let | |
934 | - | let | |
935 | - | let | |
936 | - | let | |
937 | - | let | |
938 | - | let | |
939 | - | let | |
940 | - | then invoke(ae(), "repayFor", [((aG + "_") + | |
932 | + | let aw = ew._7 | |
933 | + | let ec = ew._6 | |
934 | + | let eb = ew._5 | |
935 | + | let bU = ew._4 | |
936 | + | let el = ew._3 | |
937 | + | let bT = ew._2 | |
938 | + | let ek = ew._1 | |
939 | + | let ex = if ((dW > 0)) | |
940 | + | then invoke(ae(), "repayFor", [((aG + "_") + en)], [AttachedPayment(aO(dX), dW)]) | |
941 | 941 | else 0 | |
942 | - | if (( | |
943 | - | then ([DeleteEntry((((((aD + "_") + aG) + "_") + | |
942 | + | if ((ex == ex)) | |
943 | + | then ([DeleteEntry((((((aD + "_") + aG) + "_") + en) + u)), DeleteEntry((((((aD + "_") + aG) + "_") + en) + z)), IntegerEntry((aD + A), (eu - dV)), ScriptTransfer(ev, ek, aO(bT)), ScriptTransfer(ev, el, aO(bU))] ++ bs(bT, bU, aw)) | |
944 | 944 | else throw("Strict value is not equal to itself.") | |
945 | 945 | } | |
946 | 946 | else throw("Strict value is not equal to itself.") | |
947 | 947 | } | |
948 | 948 | ||
949 | 949 | ||
950 | - | func | |
951 | - | let | |
952 | - | let aG = | |
953 | - | let aD = | |
954 | - | let bx = parseIntValue( | |
955 | - | let | |
956 | - | let by = parseIntValue( | |
957 | - | let | |
958 | - | let ax = parseIntValue( | |
959 | - | let ay = parseIntValue( | |
960 | - | let aw = | |
961 | - | let | |
962 | - | let | |
963 | - | $Tuple11(aG, aD, bx, | |
950 | + | func ey (ez) = { | |
951 | + | let eA = split(valueOrErrorMessage(getString(this, (ez + K)), ("No request with id " + ez)), ",") | |
952 | + | let aG = eA[0] | |
953 | + | let aD = eA[1] | |
954 | + | let bx = parseIntValue(eA[2]) | |
955 | + | let dD = eA[3] | |
956 | + | let by = parseIntValue(eA[4]) | |
957 | + | let dE = eA[5] | |
958 | + | let ax = parseIntValue(eA[6]) | |
959 | + | let ay = parseIntValue(eA[7]) | |
960 | + | let aw = eA[8] | |
961 | + | let eB = eA[9] | |
962 | + | let eC = parseIntValue(eA[10]) | |
963 | + | $Tuple11(aG, aD, bx, dD, by, dE, ax, ay, aw, eB, eC) | |
964 | 964 | } | |
965 | 965 | ||
966 | 966 | ||
967 | - | func | |
967 | + | func eD (bx,by,au,av,eE,eF) = { | |
968 | 968 | let bj = ( let at = invoke(aa, "getTWAP60", [au, false], nil) | |
969 | 969 | if ($isInstanceOf(at, "(Int, Int)")) | |
970 | 970 | then at | |
973 | 973 | if ($isInstanceOf(at, "(Int, Int)")) | |
974 | 974 | then at | |
975 | 975 | else throw(($getType(at) + " couldn't be cast to (Int, Int)")))._2 | |
976 | - | let | |
977 | - | let | |
978 | - | let | |
979 | - | let | |
980 | - | then $Tuple2(bj, | |
981 | - | else $Tuple2(bk, | |
982 | - | let | |
983 | - | let | |
984 | - | fraction(fraction( | |
976 | + | let eG = pow(10, 0, aP(au), 0, 0, DOWN) | |
977 | + | let eH = pow(10, 0, aP(av), 0, 0, DOWN) | |
978 | + | let eI = (fraction(bj, bx, eG) + fraction(bk, by, eH)) | |
979 | + | let eJ = if ((eF == au)) | |
980 | + | then $Tuple2(bj, eG) | |
981 | + | else $Tuple2(bk, eH) | |
982 | + | let eK = eJ._1 | |
983 | + | let eL = eJ._2 | |
984 | + | fraction(fraction(eI, (eE - 100), 100), eL, eK) | |
985 | 985 | } | |
986 | 986 | ||
987 | 987 | ||
988 | 988 | @Callable(ah) | |
989 | - | func calcPriceImpactEVALONLY (aD, | |
989 | + | func calcPriceImpactEVALONLY (aD,eE,eF,bx,by) = if (if ((100 > eE)) | |
990 | 990 | then true | |
991 | - | else ( | |
991 | + | else (eE > 300)) | |
992 | 992 | then throw("Leverage can't be <100 and >300") | |
993 | 993 | else { | |
994 | 994 | let bf = valueOrErrorMessage(getString(this, (M + aD)), "Pool is not inited") | |
995 | - | let | |
996 | - | let | |
997 | - | let | |
998 | - | let ax = | |
999 | - | let ay = | |
1000 | - | let aw = | |
1001 | - | let | |
1002 | - | then | |
995 | + | let eM = az(Address(fromBase58String(aD)), bf) | |
996 | + | let dD = eM._1 | |
997 | + | let dE = eM._2 | |
998 | + | let ax = eM._3 | |
999 | + | let ay = eM._4 | |
1000 | + | let aw = eM._5 | |
1001 | + | let cz = if ((eE > 100)) | |
1002 | + | then eD(bx, by, dD, dE, eE, eF) | |
1003 | 1003 | else 0 | |
1004 | - | let | |
1005 | - | then $Tuple2((bx + | |
1006 | - | else $Tuple2(bx, (by + | |
1007 | - | let | |
1008 | - | let | |
1009 | - | let | |
1010 | - | let | |
1011 | - | let | |
1012 | - | let | |
1013 | - | then ( | |
1014 | - | else | |
1015 | - | $Tuple2(nil, [ | |
1004 | + | let eN = if ((eF == dD)) | |
1005 | + | then $Tuple2((bx + cz), by) | |
1006 | + | else $Tuple2(bx, (by + cz)) | |
1007 | + | let eO = eN._1 | |
1008 | + | let eP = eN._2 | |
1009 | + | let eQ = cm(bf, aD, eO, dD, eP, dE, ax, ay) | |
1010 | + | let ct = eQ._1 | |
1011 | + | let cx = eQ._2 | |
1012 | + | let eR = if ((0 > cx)) | |
1013 | + | then (cx * -1) | |
1014 | + | else cx | |
1015 | + | $Tuple2(nil, [eR]) | |
1016 | 1016 | } | |
1017 | 1017 | ||
1018 | 1018 | ||
1019 | 1019 | ||
1020 | 1020 | @Callable(ah) | |
1021 | 1021 | func getShareAssetPriceREADONLY (aw) = { | |
1022 | - | let | |
1023 | - | $Tuple2(nil, | |
1022 | + | let eS = be(aw) | |
1023 | + | $Tuple2(nil, eS) | |
1024 | 1024 | } | |
1025 | 1025 | ||
1026 | 1026 | ||
1027 | 1027 | ||
1028 | 1028 | @Callable(ah) | |
1029 | - | func getUserPositionShareAmountREADONLY (aG, | |
1030 | - | let aD = valueOrErrorMessage(getString(this, (((aG + "_") + | |
1031 | - | let | |
1032 | - | let | |
1033 | - | $Tuple2(nil, | |
1029 | + | func getUserPositionShareAmountREADONLY (aG,cW) = { | |
1030 | + | let aD = valueOrErrorMessage(getString(this, (((aG + "_") + cW) + v)), "Unknown position") | |
1031 | + | let cz = getIntegerValue(this, (((((aD + "_") + aG) + "_") + cW) + w)) | |
1032 | + | let dV = em(aG, aD, cW, (cz > 0)) | |
1033 | + | $Tuple2(nil, dV) | |
1034 | 1034 | } | |
1035 | 1035 | ||
1036 | 1036 | ||
1037 | 1037 | ||
1038 | 1038 | @Callable(ah) | |
1039 | - | func getUserPositionInDollarsREADONLY (aG, | |
1040 | - | func | |
1041 | - | let | |
1042 | - | let | |
1043 | - | let | |
1044 | - | let | |
1039 | + | func getUserPositionInDollarsREADONLY (aG,eT,cW) = { | |
1040 | + | func eU (aV,aD) = { | |
1041 | + | let eV = aV | |
1042 | + | let eW = eV._1 | |
1043 | + | let eX = eV._2 | |
1044 | + | let eY = eV._3 | |
1045 | 1045 | let bf = valueOrErrorMessage(getString(this, (M + aD)), "Pool is not inited") | |
1046 | - | let | |
1047 | - | let | |
1048 | - | let | |
1049 | - | let ax = | |
1050 | - | let ay = | |
1051 | - | let aw = | |
1052 | - | let | |
1053 | - | let | |
1054 | - | let | |
1055 | - | let | |
1056 | - | let | |
1057 | - | if (( | |
1058 | - | then $Tuple3(( | |
1046 | + | let eZ = az(Address(fromBase58String(aD)), bf) | |
1047 | + | let dD = eZ._1 | |
1048 | + | let dE = eZ._2 | |
1049 | + | let ax = eZ._3 | |
1050 | + | let ay = eZ._4 | |
1051 | + | let aw = eZ._5 | |
1052 | + | let cz = valueOrElse(getInteger(this, (((((aD + "_") + aG) + "_") + cW[eY]) + w)), 0) | |
1053 | + | let dV = em(aG, aD, cW[eY], (cz > 0)) | |
1054 | + | let eS = be(aw) | |
1055 | + | let fa = pow(10, 0, aP(aw), 0, 0, DOWN) | |
1056 | + | let fb = fraction(dV, eS, fa) | |
1057 | + | if ((cz == 0)) | |
1058 | + | then $Tuple3((eW :+ fb), (eX :+ 0), (eY + 1)) | |
1059 | 1059 | else { | |
1060 | - | let | |
1061 | - | let | |
1062 | - | let at = invoke(ae(), "getAssetDebt", [false, ((aG + "_") + | |
1060 | + | let dX = getStringValue(this, (((((aD + "_") + aG) + "_") + cW[eY]) + x)) | |
1061 | + | let dW = { | |
1062 | + | let at = invoke(ae(), "getAssetDebt", [false, ((aG + "_") + cW[eY]), dX], nil) | |
1063 | 1063 | if ($isInstanceOf(at, "Int")) | |
1064 | 1064 | then at | |
1065 | 1065 | else throw(($getType(at) + " couldn't be cast to Int")) | |
1066 | 1066 | } | |
1067 | - | let | |
1067 | + | let fc = ( let at = invoke(aa, "getTWAP60", [dX, false], nil) | |
1068 | 1068 | if ($isInstanceOf(at, "(Int, Int)")) | |
1069 | 1069 | then at | |
1070 | 1070 | else throw(($getType(at) + " couldn't be cast to (Int, Int)")))._1 | |
1071 | - | let | |
1072 | - | let | |
1073 | - | $Tuple3(( | |
1071 | + | let fd = pow(10, 0, aP(dX), 0, 0, DOWN) | |
1072 | + | let fe = fraction(dW, fc, fd) | |
1073 | + | $Tuple3((eW :+ fb), (eX :+ fe), (eY + 1)) | |
1074 | 1074 | } | |
1075 | 1075 | } | |
1076 | 1076 | ||
1077 | - | let | |
1078 | - | let aX = | |
1077 | + | let ff = { | |
1078 | + | let aX = eT | |
1079 | 1079 | let aY = size(aX) | |
1080 | 1080 | let aZ = $Tuple3(nil, nil, 0) | |
1081 | 1081 | func ba (bb,bc) = if ((bc >= aY)) | |
1082 | 1082 | then bb | |
1083 | - | else | |
1083 | + | else eU(bb, aX[bc]) | |
1084 | 1084 | ||
1085 | 1085 | func bd (bb,bc) = if ((bc >= aY)) | |
1086 | 1086 | then bb | |
1088 | 1088 | ||
1089 | 1089 | bd(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(aZ, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20) | |
1090 | 1090 | } | |
1091 | - | let | |
1092 | - | let | |
1093 | - | $Tuple2(nil, $Tuple2( | |
1091 | + | let fg = ff._1 | |
1092 | + | let dW = ff._2 | |
1093 | + | $Tuple2(nil, $Tuple2(fg, dW)) | |
1094 | 1094 | } | |
1095 | 1095 | ||
1096 | 1096 | ||
1097 | 1097 | ||
1098 | 1098 | @Callable(ah) | |
1099 | - | func replenish (aD, | |
1099 | + | func replenish (aD,eE,eF) = if (if ((100 > eE)) | |
1100 | 1100 | then true | |
1101 | - | else ( | |
1101 | + | else (eE > 300)) | |
1102 | 1102 | then throw("Leverage can't be <100 and >300") | |
1103 | 1103 | else { | |
1104 | 1104 | let bf = valueOrErrorMessage(getString(this, (M + aD)), "Pool is not inited") | |
1105 | - | let | |
1106 | - | let | |
1107 | - | let | |
1108 | - | let ax = | |
1109 | - | let ay = | |
1110 | - | let aw = | |
1111 | - | let | |
1112 | - | then if ((aN(ah.payments[0].assetId) != | |
1105 | + | let fh = az(Address(fromBase58String(aD)), bf) | |
1106 | + | let dD = fh._1 | |
1107 | + | let dE = fh._2 | |
1108 | + | let ax = fh._3 | |
1109 | + | let ay = fh._4 | |
1110 | + | let aw = fh._5 | |
1111 | + | let fi = if ((size(ah.payments) == 2)) | |
1112 | + | then if ((aN(ah.payments[0].assetId) != dD)) | |
1113 | 1113 | then throw("Wrong payment asset A") | |
1114 | - | else if ((aN(ah.payments[1].assetId) != | |
1114 | + | else if ((aN(ah.payments[1].assetId) != dE)) | |
1115 | 1115 | then throw("Wrong payment asset B") | |
1116 | - | else $Tuple4(ah.payments[0].amount, | |
1116 | + | else $Tuple4(ah.payments[0].amount, dD, ah.payments[1].amount, dE) | |
1117 | 1117 | else if ((size(ah.payments) == 1)) | |
1118 | - | then if ((aN(ah.payments[0].assetId) == | |
1119 | - | then $Tuple4(ah.payments[0].amount, | |
1120 | - | else if ((aN(ah.payments[0].assetId) == | |
1121 | - | then $Tuple4(0, | |
1118 | + | then if ((aN(ah.payments[0].assetId) == dD)) | |
1119 | + | then $Tuple4(ah.payments[0].amount, dD, 0, dE) | |
1120 | + | else if ((aN(ah.payments[0].assetId) == dE)) | |
1121 | + | then $Tuple4(0, dD, ah.payments[0].amount, dE) | |
1122 | 1122 | else throw("Wrong payment") | |
1123 | 1123 | else throw("One or two payments expected") | |
1124 | - | let bx = | |
1125 | - | let | |
1126 | - | let by = | |
1127 | - | let | |
1128 | - | let | |
1129 | - | if (( | |
1124 | + | let bx = fi._1 | |
1125 | + | let fj = fi._2 | |
1126 | + | let by = fi._3 | |
1127 | + | let fk = fi._4 | |
1128 | + | let fl = aF(toString(ah.caller)) | |
1129 | + | if ((eE > 100)) | |
1130 | 1130 | then { | |
1131 | - | let | |
1132 | - | let | |
1133 | - | let | |
1134 | - | let at = invoke(this, "createNewRequest", [ | |
1131 | + | let cz = eD(bx, by, fj, fk, eE, eF) | |
1132 | + | let eA = makeString([toString(ah.caller), aD, toString(bx), fj, toString(by), fk, toString(ax), toString(ay), aw, eF, toString(cz)], ",") | |
1133 | + | let fm = { | |
1134 | + | let at = invoke(this, "createNewRequest", [eA], nil) | |
1135 | 1135 | if ($isInstanceOf(at, "Int")) | |
1136 | 1136 | then at | |
1137 | 1137 | else throw(($getType(at) + " couldn't be cast to Int")) | |
1138 | 1138 | } | |
1139 | - | if (( | |
1139 | + | if ((fm == fm)) | |
1140 | 1140 | then { | |
1141 | - | let | |
1142 | - | let | |
1143 | - | if (( | |
1141 | + | let fn = [((toString(ah.caller) + "_") + toString(fl)), aw, eF, cz, toString(this), "replenishFromLand", toString(valueOrErrorMessage(fm, "Can't create new request"))] | |
1142 | + | let bR = reentrantInvoke(ae(), "flashPosition", fn, nil) | |
1143 | + | if ((bR == bR)) | |
1144 | 1144 | then nil | |
1145 | 1145 | else throw("Strict value is not equal to itself.") | |
1146 | 1146 | } | |
1147 | 1147 | else throw("Strict value is not equal to itself.") | |
1148 | 1148 | } | |
1149 | 1149 | else { | |
1150 | - | let | |
1151 | - | let | |
1152 | - | let | |
1153 | - | ( | |
1150 | + | let fo = cK(bf, aD, h, bx, dD, by, dE, ax, ay, aw) | |
1151 | + | let fp = fo._1 | |
1152 | + | let dT = fo._2 | |
1153 | + | (cU(aD, toString(ah.caller), fp, dT, fl, aw, bf, false) ++ bs(dD, dE, aw)) | |
1154 | 1154 | } | |
1155 | 1155 | } | |
1156 | 1156 | ||
1157 | 1157 | ||
1158 | 1158 | ||
1159 | 1159 | @Callable(ah) | |
1160 | - | func withdraw (aD, | |
1160 | + | func withdraw (aD,en) = es(toString(ah.caller), aD, toString(en), false) | |
1161 | 1161 | ||
1162 | 1162 | ||
1163 | 1163 | ||
1164 | 1164 | @Callable(ah) | |
1165 | - | func createUpdateStopLoss ( | |
1166 | - | let | |
1165 | + | func createUpdateStopLoss (en,fq,al,fr) = { | |
1166 | + | let fs = ( let at = invoke(aa, "getTWAP60", [al, false], nil) | |
1167 | 1167 | if ($isInstanceOf(at, "(Int, Int)")) | |
1168 | 1168 | then at | |
1169 | 1169 | else throw(($getType(at) + " couldn't be cast to (Int, Int)")))._1 | |
1170 | - | if (!(isDefined(getInteger(this, ((((( | |
1170 | + | if (!(isDefined(getInteger(this, (((((fq + "_") + toString(ah.caller)) + "_") + toString(en)) + u))))) | |
1171 | 1171 | then throw("There are no user position") | |
1172 | - | else if ((0 >= | |
1172 | + | else if ((0 >= fr)) | |
1173 | 1173 | then throw("Price must be greater than 0") | |
1174 | - | else if (( | |
1174 | + | else if ((fr > fs)) | |
1175 | 1175 | then throw("Price must be less than current token price") | |
1176 | - | else [IntegerEntry((((((((toString(ah.caller) + "_") + toString( | |
1176 | + | else [IntegerEntry((((((((toString(ah.caller) + "_") + toString(en)) + "_") + fq) + "_") + al) + Q), fr)] | |
1177 | 1177 | } | |
1178 | 1178 | ||
1179 | 1179 | ||
1180 | 1180 | ||
1181 | 1181 | @Callable(ah) | |
1182 | - | func deleteStopLoss ( | |
1182 | + | func deleteStopLoss (en,fq,al) = if (!(isDefined(getInteger(this, (((((((toString(ah.caller) + "_") + toString(en)) + "_") + fq) + "_") + al) + Q))))) | |
1183 | 1183 | then throw("No entry") | |
1184 | - | else [DeleteEntry((((((((toString(ah.caller) + "_") + toString( | |
1184 | + | else [DeleteEntry((((((((toString(ah.caller) + "_") + toString(en)) + "_") + fq) + "_") + al) + Q))] | |
1185 | 1185 | ||
1186 | 1186 | ||
1187 | 1187 | ||
1188 | 1188 | @Callable(ah) | |
1189 | 1189 | func createNewRequest (bQ) = valueOrElse(ai(ah), { | |
1190 | - | let | |
1191 | - | $Tuple2([StringEntry((toString( | |
1190 | + | let fm = (valueOrElse(getInteger(this, L), 0) + 1) | |
1191 | + | $Tuple2([StringEntry((toString(fm) + K), bQ), IntegerEntry(L, fm)], fm) | |
1192 | 1192 | }) | |
1193 | 1193 | ||
1194 | 1194 | ||
1195 | 1195 | ||
1196 | 1196 | @Callable(ah) | |
1197 | - | func replenishFromLand ( | |
1198 | - | let | |
1199 | - | let aG = | |
1200 | - | let aD = | |
1201 | - | let bx = | |
1202 | - | let | |
1203 | - | let by = | |
1204 | - | let | |
1205 | - | let ax = | |
1206 | - | let ay = | |
1207 | - | let aw = | |
1208 | - | let | |
1209 | - | let | |
1197 | + | func replenishFromLand (ez) = valueOrElse(aj(ah), { | |
1198 | + | let ft = ey(ez) | |
1199 | + | let aG = ft._1 | |
1200 | + | let aD = ft._2 | |
1201 | + | let bx = ft._3 | |
1202 | + | let dD = ft._4 | |
1203 | + | let by = ft._5 | |
1204 | + | let dE = ft._6 | |
1205 | + | let ax = ft._7 | |
1206 | + | let ay = ft._8 | |
1207 | + | let aw = ft._9 | |
1208 | + | let eB = ft._10 | |
1209 | + | let eC = ft._11 | |
1210 | 1210 | if ((size(ah.payments) != 1)) | |
1211 | 1211 | then throw("Wrong payment size") | |
1212 | - | else if (if ((aN(ah.payments[0].assetId) != | |
1212 | + | else if (if ((aN(ah.payments[0].assetId) != eB)) | |
1213 | 1213 | then true | |
1214 | - | else (ah.payments[0].amount != | |
1214 | + | else (ah.payments[0].amount != eC)) | |
1215 | 1215 | then throw("Wrong payment") | |
1216 | 1216 | else { | |
1217 | - | let | |
1217 | + | let fu = if ((dD == eB)) | |
1218 | 1218 | then $Tuple2((bx + ah.payments[0].amount), by) | |
1219 | 1219 | else $Tuple2(bx, (by + ah.payments[0].amount)) | |
1220 | - | let | |
1221 | - | let | |
1220 | + | let fv = fu._1 | |
1221 | + | let fw = fu._2 | |
1222 | 1222 | let bf = valueOrErrorMessage(getString(this, (M + aD)), "Unknown pool") | |
1223 | - | let | |
1224 | - | let | |
1225 | - | let | |
1226 | - | let | |
1227 | - | let | |
1228 | - | let | |
1229 | - | $Tuple2(((( | |
1223 | + | let fx = cK(bf, aD, g, fv, dD, fw, dE, ax, ay, aw) | |
1224 | + | let fp = fx._1 | |
1225 | + | let dT = fx._2 | |
1226 | + | let cW = aF(aG) | |
1227 | + | let fy = [IntegerEntry((((((aD + "_") + aG) + "_") + toString(cW)) + w), eC), StringEntry((((((aD + "_") + aG) + "_") + toString(cW)) + x), eB)] | |
1228 | + | let fz = cU(aD, aG, fp, dT, cW, aw, bf, true) | |
1229 | + | $Tuple2((((fz ++ bs(dD, dE, aw)) ++ fy) :+ DeleteEntry((ez + K))), fp) | |
1230 | 1230 | } | |
1231 | 1231 | }) | |
1232 | 1232 | ||
1233 | 1233 | ||
1234 | 1234 | ||
1235 | 1235 | @Callable(ah) | |
1236 | - | func liquidate (aG, | |
1237 | - | let aD = valueOrErrorMessage(getString(this, (((aG + "_") + | |
1236 | + | func liquidate (aG,en,fA) = valueOrElse(aj(ah), { | |
1237 | + | let aD = valueOrErrorMessage(getString(this, (((aG + "_") + en) + v)), "no position") | |
1238 | 1238 | let bf = valueOrErrorMessage(getString(this, (M + aD)), "Pool is not inited") | |
1239 | - | let | |
1240 | - | let | |
1241 | - | let | |
1242 | - | let ax = | |
1243 | - | let ay = | |
1244 | - | let aw = | |
1245 | - | let bL = bM(aD, bf, aw, | |
1246 | - | let | |
1247 | - | let | |
1248 | - | let | |
1249 | - | if (( | |
1239 | + | let fB = az(Address(fromBase58String(aD)), bf) | |
1240 | + | let dD = fB._1 | |
1241 | + | let dE = fB._2 | |
1242 | + | let ax = fB._3 | |
1243 | + | let ay = fB._4 | |
1244 | + | let aw = fB._5 | |
1245 | + | let bL = bM(aD, bf, aw, fA) | |
1246 | + | let cz = getIntegerValue(this, (((((aD + "_") + aG) + "_") + en) + w)) | |
1247 | + | let dX = getStringValue(this, (((((aD + "_") + aG) + "_") + en) + x)) | |
1248 | + | let dV = em(aG, aD, en, (cz > 0)) | |
1249 | + | if ((cz == 0)) | |
1250 | 1250 | then throw("You can't liquidate position without borrow") | |
1251 | - | else [IntegerEntry((((((aD + "_") + aG) + "_") + | |
1251 | + | else [IntegerEntry((((((aD + "_") + aG) + "_") + en) + z), getIntegerValue(this, (aD + C))), IntegerEntry((aD + B), (aE(aD) - fA)), IntegerEntry((aD + A), (aC(aD) - fA)), IntegerEntry((((((aD + "_") + aG) + "_") + en) + u), (dV - fA)), ScriptTransfer(ah.caller, bL, fromBase58String(aw))] | |
1252 | 1252 | }) | |
1253 | 1253 | ||
1254 | 1254 | ||
1255 | 1255 | ||
1256 | 1256 | @Callable(ah) | |
1257 | - | func stopLoss (aG, | |
1258 | - | let | |
1257 | + | func stopLoss (aG,en,aD,al) = valueOrElse(ag(ah), { | |
1258 | + | let fs = ( let at = invoke(aa, "getTWAP60", [al, false], nil) | |
1259 | 1259 | if ($isInstanceOf(at, "(Int, Int)")) | |
1260 | 1260 | then at | |
1261 | 1261 | else throw(($getType(at) + " couldn't be cast to (Int, Int)")))._1 | |
1262 | - | if (!(isDefined(getInteger(this, (((((((aG + "_") + toString( | |
1262 | + | if (!(isDefined(getInteger(this, (((((((aG + "_") + toString(en)) + "_") + aD) + "_") + al) + Q))))) | |
1263 | 1263 | then throw("No entry") | |
1264 | - | else ( | |
1264 | + | else (es(toString(ah.caller), aD, toString(en), true) :+ DeleteEntry((((((((aG + "_") + toString(en)) + "_") + aD) + "_") + al) + Q))) | |
1265 | 1265 | }) | |
1266 | 1266 | ||
1267 | 1267 | ||
1268 | 1268 | ||
1269 | 1269 | @Callable(ah) | |
1270 | - | func capitalizeExKeeper (aD,aA, | |
1271 | - | let | |
1272 | - | then | |
1270 | + | func capitalizeExKeeper (aD,aA,fC,fD,fE,dh,di,dj,dk,dl,dm,dn) = valueOrElse(ag(ah), { | |
1271 | + | let fF = if (fE) | |
1272 | + | then cH(aA, aD) | |
1273 | 1273 | else { | |
1274 | - | let | |
1274 | + | let fG = if ((aA == a)) | |
1275 | 1275 | then ac | |
1276 | 1276 | else ad | |
1277 | - | $Tuple2( | |
1277 | + | $Tuple2(fD, fG) | |
1278 | 1278 | } | |
1279 | - | let | |
1280 | - | let | |
1281 | - | let | |
1282 | - | let | |
1283 | - | let | |
1284 | - | then [IntegerEntry((aD + O), ( | |
1279 | + | let fH = fF._1 | |
1280 | + | let fG = fF._2 | |
1281 | + | let fI = dd(fC, fD, fG, dh, di, dj, dk, dl, dm, dn) | |
1282 | + | let cr = (fH - fD) | |
1283 | + | let fJ = if ((cr > 0)) | |
1284 | + | then [IntegerEntry((aD + O), (cr + valueOrElse(getInteger(this, (aD + O)), 0)))] | |
1285 | 1285 | else nil | |
1286 | - | ( | |
1286 | + | (dz(aD, aA, fC, fI) ++ fJ) | |
1287 | 1287 | }) | |
1288 | 1288 | ||
1289 | 1289 | ||
1290 | 1290 | ||
1291 | 1291 | @Callable(ah) | |
1292 | - | func capitalizeExPuzzle (aD,aA, | |
1293 | - | let | |
1294 | - | then | |
1292 | + | func capitalizeExPuzzle (aD,aA,fC,fD,fE,dq,dr,dn) = valueOrElse(ag(ah), { | |
1293 | + | let fK = if (fE) | |
1294 | + | then cH(aA, aD) | |
1295 | 1295 | else { | |
1296 | - | let | |
1296 | + | let fG = if ((aA == a)) | |
1297 | 1297 | then ac | |
1298 | 1298 | else ad | |
1299 | - | $Tuple2( | |
1299 | + | $Tuple2(fD, fG) | |
1300 | 1300 | } | |
1301 | - | let | |
1302 | - | let | |
1303 | - | let | |
1304 | - | let | |
1305 | - | let | |
1306 | - | then [IntegerEntry((aD + O), ( | |
1301 | + | let fH = fK._1 | |
1302 | + | let fG = fK._2 | |
1303 | + | let fI = dp(fC, fD, fG, dq, dr, dn) | |
1304 | + | let cr = (fH - fD) | |
1305 | + | let fJ = if ((cr > 0)) | |
1306 | + | then [IntegerEntry((aD + O), (cr + valueOrElse(getInteger(this, (aD + O)), 0)))] | |
1307 | 1307 | else nil | |
1308 | - | ( | |
1308 | + | (dz(aD, aA, fC, fI) ++ fJ) | |
1309 | 1309 | }) | |
1310 | 1310 | ||
1311 | 1311 | ||
1312 | 1312 | ||
1313 | 1313 | @Callable(ah) | |
1314 | - | func capitalizeExSwopFi (aD,aA, | |
1315 | - | let | |
1316 | - | then | |
1314 | + | func capitalizeExSwopFi (aD,aA,fC,fD,fE,dt,du,dv,dw,dx,dy,dn) = valueOrElse(ag(ah), { | |
1315 | + | let fL = if (fE) | |
1316 | + | then cH(aA, aD) | |
1317 | 1317 | else { | |
1318 | - | let | |
1318 | + | let fG = if ((aA == a)) | |
1319 | 1319 | then ac | |
1320 | 1320 | else ad | |
1321 | - | $Tuple2( | |
1321 | + | $Tuple2(fD, fG) | |
1322 | 1322 | } | |
1323 | - | let | |
1324 | - | let | |
1325 | - | let | |
1326 | - | let | |
1327 | - | let | |
1328 | - | then [IntegerEntry((aD + O), ( | |
1323 | + | let fH = fL._1 | |
1324 | + | let fG = fL._2 | |
1325 | + | let fI = ds(fC, fD, fG, dt, du, dv, dw, dx, dy, dn) | |
1326 | + | let cr = (fH - fD) | |
1327 | + | let fJ = if ((cr > 0)) | |
1328 | + | then [IntegerEntry((aD + O), (cr + valueOrElse(getInteger(this, (aD + O)), 0)))] | |
1329 | 1329 | else nil | |
1330 | - | ( | |
1330 | + | (dz(aD, aA, fC, fI) ++ fJ) | |
1331 | 1331 | }) | |
1332 | 1332 | ||
1333 | 1333 | ||
1334 | 1334 | ||
1335 | 1335 | @Callable(ah) | |
1336 | - | func initNewPool (aA,aq | |
1336 | + | func initNewPool (aA,aq,fM,fN,fO,fP,fQ,fR) = valueOrElse(ag(ah), if (if ((aA != a)) | |
1337 | 1337 | then (aA != b) | |
1338 | 1338 | else false) | |
1339 | 1339 | then throw("Wrong type") | |
1340 | 1340 | else { | |
1341 | - | let | |
1342 | - | let au = | |
1343 | - | let av = | |
1344 | - | let | |
1345 | - | let | |
1346 | - | let aw = | |
1347 | - | [IntegerEntry((aq + E), | |
1341 | + | let fS = az(Address(fromBase58String(aq)), aA) | |
1342 | + | let au = fS._1 | |
1343 | + | let av = fS._2 | |
1344 | + | let fT = fS._3 | |
1345 | + | let fU = fS._4 | |
1346 | + | let aw = fS._5 | |
1347 | + | [IntegerEntry((aq + E), fM), IntegerEntry((aq + F), fN), IntegerEntry((aq + G), fO), IntegerEntry((aq + H), fP), IntegerEntry((aq + I), fQ), IntegerEntry((aq + J), fR), IntegerEntry((aq + C), 0), IntegerEntry((aq + D), 0), StringEntry((M + aq), aA), StringEntry((aw + N), aq)] | |
1348 | 1348 | }) | |
1349 | 1349 | ||
1350 | 1350 | ||
1351 | - | @Verifier( | |
1352 | - | func | |
1351 | + | @Verifier(fV) | |
1352 | + | func fW () = sigVerify(fV.bodyBytes, fV.proofs[0], fV.senderPublicKey) | |
1353 | 1353 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let a = "SF" | |
5 | 5 | ||
6 | 6 | let b = "WX" | |
7 | 7 | ||
8 | 8 | let c = "capNoLoan" | |
9 | 9 | ||
10 | 10 | let d = "capLoan" | |
11 | 11 | ||
12 | 12 | let e = "stopLossNoLoan" | |
13 | 13 | ||
14 | 14 | let f = "stopLossLoan" | |
15 | 15 | ||
16 | 16 | let g = "loan" | |
17 | 17 | ||
18 | 18 | let h = "noLoan" | |
19 | 19 | ||
20 | 20 | let i = "noFee" | |
21 | 21 | ||
22 | 22 | let j = 100000000 | |
23 | 23 | ||
24 | 24 | let k = 10000000000 | |
25 | 25 | ||
26 | 26 | let l = toBigInt(10000000000000000) | |
27 | 27 | ||
28 | 28 | let m = 1000000 | |
29 | 29 | ||
30 | 30 | let n = "A_asset_balance" | |
31 | 31 | ||
32 | 32 | let o = "B_asset_balance" | |
33 | 33 | ||
34 | 34 | let p = "A_asset_id" | |
35 | 35 | ||
36 | 36 | let q = "B_asset_id" | |
37 | 37 | ||
38 | 38 | let r = "share_asset_id" | |
39 | 39 | ||
40 | 40 | let s = "share_asset_supply" | |
41 | 41 | ||
42 | 42 | let t = "commission" | |
43 | 43 | ||
44 | 44 | let u = "_user_position" | |
45 | 45 | ||
46 | 46 | let v = "_user_position_pool" | |
47 | 47 | ||
48 | 48 | let w = "_user_position_borrow_amount" | |
49 | 49 | ||
50 | 50 | let x = "_user_position_borrow_asset_id" | |
51 | 51 | ||
52 | 52 | let y = "_user_position_number" | |
53 | 53 | ||
54 | 54 | let z = "_user_position_interest" | |
55 | 55 | ||
56 | 56 | let A = "_pool_total" | |
57 | 57 | ||
58 | 58 | let B = "_pool_total_loan" | |
59 | 59 | ||
60 | 60 | let C = "_pool_interest_loan" | |
61 | 61 | ||
62 | 62 | let D = "_pool_interest_no_loan" | |
63 | 63 | ||
64 | 64 | let E = "_axly_fee_without_loan" | |
65 | 65 | ||
66 | 66 | let F = "_axly_fee_with_loan" | |
67 | 67 | ||
68 | 68 | let G = "_axly_fee_cap_with_loan" | |
69 | 69 | ||
70 | 70 | let H = "_axly_fee_cap_no_loan" | |
71 | 71 | ||
72 | 72 | let I = "_axly_fee_stoploss_with_loan" | |
73 | 73 | ||
74 | 74 | let J = "_axly_fee_stoploss_no_loan" | |
75 | 75 | ||
76 | 76 | let K = "_request_id" | |
77 | 77 | ||
78 | 78 | let L = "requests_iter" | |
79 | 79 | ||
80 | 80 | let M = "pool_" | |
81 | 81 | ||
82 | 82 | let N = "_pool_share_id" | |
83 | 83 | ||
84 | 84 | let O = "_pool_cap_change" | |
85 | 85 | ||
86 | 86 | let P = "last_price" | |
87 | 87 | ||
88 | 88 | let Q = "_stop_loss" | |
89 | 89 | ||
90 | 90 | let R = "axly_money_box" | |
91 | 91 | ||
92 | 92 | let S = "swopfi_farming_addr" | |
93 | 93 | ||
94 | 94 | let T = "lend_service_addr" | |
95 | 95 | ||
96 | 96 | let U = "admin_call_pub_key" | |
97 | 97 | ||
98 | 98 | let V = "price_oracle" | |
99 | 99 | ||
100 | 100 | let W = "exchange_contract" | |
101 | 101 | ||
102 | 102 | let X = "wx_swap_contract" | |
103 | 103 | ||
104 | 104 | let Y = Address(fromBase58String(valueOrErrorMessage(getString(this, R), "No axly moneyBox address"))) | |
105 | 105 | ||
106 | 106 | let Z = Address(fromBase58String(valueOrErrorMessage(getString(this, W), "No exchange contract address"))) | |
107 | 107 | ||
108 | 108 | let aa = Address(fromBase58String(valueOrErrorMessage(getString(this, V), "No price oracle address"))) | |
109 | 109 | ||
110 | 110 | let ab = Address(fromBase58String(valueOrErrorMessage(getString(this, X), "No wx swap address"))) | |
111 | 111 | ||
112 | 112 | let ac = base58'4W19ndijcc2CsQa9HGW2dfXKTVXhnneWWttxXrtjPmEp' | |
113 | 113 | ||
114 | 114 | let ad = base58'EMAMLxDnv3xiz8RXg8Btj33jcEw3wLczL3JKYYmuubpc' | |
115 | 115 | ||
116 | 116 | func ae () = Address(fromBase58String(valueOrErrorMessage(getString(this, T), "Can't get lend service addr"))) | |
117 | 117 | ||
118 | 118 | ||
119 | 119 | func af () = addressFromPublicKey(fromBase58String(valueOrErrorMessage(getString(this, U), "Can't get admin addr"))) | |
120 | 120 | ||
121 | 121 | ||
122 | 122 | func ag (ah) = if ((ah.caller == af())) | |
123 | 123 | then unit | |
124 | 124 | else throw("Only admin can call this function") | |
125 | 125 | ||
126 | 126 | ||
127 | 127 | func ai (ah) = if ((ah.caller == this)) | |
128 | 128 | then unit | |
129 | 129 | else throw("Only contract itself can call this function") | |
130 | 130 | ||
131 | 131 | ||
132 | 132 | func aj (ah) = if ((ah.caller == ae())) | |
133 | 133 | then unit | |
134 | 134 | else throw("Only land contract can call this function") | |
135 | 135 | ||
136 | 136 | ||
137 | 137 | func ak (al) = { | |
138 | 138 | let am = al | |
139 | 139 | if ($isInstanceOf(am, "ByteVector")) | |
140 | 140 | then { | |
141 | 141 | let an = am | |
142 | 142 | assetBalance(this, an) | |
143 | 143 | } | |
144 | 144 | else if ($isInstanceOf(am, "Unit")) | |
145 | 145 | then { | |
146 | 146 | let ao = am | |
147 | 147 | wavesBalance(this).available | |
148 | 148 | } | |
149 | 149 | else throw("Match error") | |
150 | 150 | } | |
151 | 151 | ||
152 | 152 | ||
153 | 153 | func ap (aq) = $Tuple5(valueOrErrorMessage(getString(aq, p), "Can't get pool A asset id"), valueOrErrorMessage(getString(aq, q), "Can't get pool B asset id"), valueOrErrorMessage(getInteger(aq, n), "Can't get pool A asset balance"), valueOrErrorMessage(getInteger(aq, o), "Can't get pool B asset balance"), valueOrErrorMessage(getString(aq, r), "Can't get share asset id")) | |
154 | 154 | ||
155 | 155 | ||
156 | 156 | func ar (aq) = { | |
157 | 157 | let as = { | |
158 | 158 | let at = invoke(aq, "getPoolConfigWrapperREADONLY", nil, nil) | |
159 | 159 | if ($isInstanceOf(at, "List[Any]")) | |
160 | 160 | then at | |
161 | 161 | else throw(($getType(at) + " couldn't be cast to List[Any]")) | |
162 | 162 | } | |
163 | 163 | if ((as == as)) | |
164 | 164 | then { | |
165 | 165 | let au = valueOrErrorMessage({ | |
166 | 166 | let at = as[4] | |
167 | 167 | if ($isInstanceOf(at, "String")) | |
168 | 168 | then at | |
169 | 169 | else unit | |
170 | 170 | }, "Can't get pool A asset id") | |
171 | 171 | let av = valueOrErrorMessage({ | |
172 | 172 | let at = as[5] | |
173 | 173 | if ($isInstanceOf(at, "String")) | |
174 | 174 | then at | |
175 | 175 | else unit | |
176 | 176 | }, "Can't get pool B asset id") | |
177 | 177 | let aw = valueOrErrorMessage({ | |
178 | 178 | let at = as[3] | |
179 | 179 | if ($isInstanceOf(at, "String")) | |
180 | 180 | then at | |
181 | 181 | else unit | |
182 | 182 | }, "Can't get pool LP asset id") | |
183 | 183 | let ax = { | |
184 | 184 | let at = invoke(aq, "getAccBalanceWrapperREADONLY", [au], nil) | |
185 | 185 | if ($isInstanceOf(at, "Int")) | |
186 | 186 | then at | |
187 | 187 | else throw(($getType(at) + " couldn't be cast to Int")) | |
188 | 188 | } | |
189 | 189 | if ((ax == ax)) | |
190 | 190 | then { | |
191 | 191 | let ay = { | |
192 | 192 | let at = invoke(aq, "getAccBalanceWrapperREADONLY", [av], nil) | |
193 | 193 | if ($isInstanceOf(at, "Int")) | |
194 | 194 | then at | |
195 | 195 | else throw(($getType(at) + " couldn't be cast to Int")) | |
196 | 196 | } | |
197 | 197 | if ((ay == ay)) | |
198 | 198 | then $Tuple5(au, av, ax, ay, aw) | |
199 | 199 | else throw("Strict value is not equal to itself.") | |
200 | 200 | } | |
201 | 201 | else throw("Strict value is not equal to itself.") | |
202 | 202 | } | |
203 | 203 | else throw("Strict value is not equal to itself.") | |
204 | 204 | } | |
205 | 205 | ||
206 | 206 | ||
207 | 207 | func az (aq,aA) = if ((aA == a)) | |
208 | 208 | then ap(aq) | |
209 | 209 | else if ((aA == b)) | |
210 | 210 | then ar(aq) | |
211 | 211 | else throw("Wrong pool type") | |
212 | 212 | ||
213 | 213 | ||
214 | 214 | func aB (aq,aA,aw) = if ((aA == a)) | |
215 | 215 | then valueOrErrorMessage(getInteger(aq, s), "Can't get share asset supply") | |
216 | 216 | else if ((aA == b)) | |
217 | 217 | then valueOrErrorMessage(assetInfo(fromBase58String(aw)), "Wrong ShareId").quantity | |
218 | 218 | else throw("Wrong pool type") | |
219 | 219 | ||
220 | 220 | ||
221 | 221 | func aC (aD) = valueOrElse(getInteger(this, (aD + A)), 0) | |
222 | 222 | ||
223 | 223 | ||
224 | 224 | func aE (aD) = valueOrElse(getInteger(this, (aD + B)), 0) | |
225 | 225 | ||
226 | 226 | ||
227 | 227 | func aF (aG) = (valueOrElse(getInteger(this, (aG + y)), 0) + 1) | |
228 | 228 | ||
229 | 229 | ||
230 | 230 | func aH (aD,aI) = if ((aI == d)) | |
231 | 231 | then getIntegerValue(this, (aD + H)) | |
232 | 232 | else if ((aI == c)) | |
233 | 233 | then getIntegerValue(this, (aD + G)) | |
234 | 234 | else if ((aI == g)) | |
235 | 235 | then getIntegerValue(this, (aD + F)) | |
236 | 236 | else if ((aI == h)) | |
237 | 237 | then getIntegerValue(this, (aD + E)) | |
238 | 238 | else if ((aI == i)) | |
239 | 239 | then 0 | |
240 | 240 | else throw("Wrong fee type") | |
241 | 241 | ||
242 | 242 | ||
243 | 243 | func aJ () = Address(fromBase58String(valueOrErrorMessage(getString(this, S), "Can't get swopfi farming addr"))) | |
244 | 244 | ||
245 | 245 | ||
246 | 246 | func aK (aq) = { | |
247 | 247 | let aL = Address(fromBase58String(valueOrErrorMessage(getString(aq, "%s__factoryContract"), "Can't get WX factory contract addr"))) | |
248 | 248 | let aM = split(valueOrErrorMessage(getString(aL, "%s__factoryConfig"), "Can't get WX factory cfg"), "__") | |
249 | 249 | Address(fromBase58String(aM[1])) | |
250 | 250 | } | |
251 | 251 | ||
252 | 252 | ||
253 | 253 | func aN (al) = { | |
254 | 254 | let am = al | |
255 | 255 | if ($isInstanceOf(am, "ByteVector")) | |
256 | 256 | then { | |
257 | 257 | let an = am | |
258 | 258 | toBase58String(an) | |
259 | 259 | } | |
260 | 260 | else if ($isInstanceOf(am, "Unit")) | |
261 | 261 | then { | |
262 | 262 | let ao = am | |
263 | 263 | "WAVES" | |
264 | 264 | } | |
265 | 265 | else throw("Match error") | |
266 | 266 | } | |
267 | 267 | ||
268 | 268 | ||
269 | 269 | func aO (al) = if ((al == "WAVES")) | |
270 | 270 | then unit | |
271 | 271 | else fromBase58String(al) | |
272 | 272 | ||
273 | 273 | ||
274 | 274 | func aP (al) = if ((al == "WAVES")) | |
275 | 275 | then 8 | |
276 | 276 | else { | |
277 | 277 | let am = assetInfo(fromBase58String(al)) | |
278 | 278 | if ($isInstanceOf(am, "Asset")) | |
279 | 279 | then { | |
280 | 280 | let aQ = am | |
281 | 281 | aQ.decimals | |
282 | 282 | } | |
283 | 283 | else throw("Can't find asset") | |
284 | 284 | } | |
285 | 285 | ||
286 | 286 | ||
287 | 287 | func aR (al) = pow(10, 0, aP(al), 0, 0, DOWN) | |
288 | 288 | ||
289 | 289 | ||
290 | 290 | func aS (aT) = { | |
291 | 291 | func aU (aV,al) = { | |
292 | 292 | let aW = ( let at = invoke(aa, "getTWAP60", [al, false], nil) | |
293 | 293 | if ($isInstanceOf(at, "(Int, Int)")) | |
294 | 294 | then at | |
295 | 295 | else throw(($getType(at) + " couldn't be cast to (Int, Int)")))._2 | |
296 | 296 | (aV :+ aW) | |
297 | 297 | } | |
298 | 298 | ||
299 | 299 | let aX = aT | |
300 | 300 | let aY = size(aX) | |
301 | 301 | let aZ = nil | |
302 | 302 | func ba (bb,bc) = if ((bc >= aY)) | |
303 | 303 | then bb | |
304 | 304 | else aU(bb, aX[bc]) | |
305 | 305 | ||
306 | 306 | func bd (bb,bc) = if ((bc >= aY)) | |
307 | 307 | then bb | |
308 | 308 | else throw("List size exceeds 50") | |
309 | 309 | ||
310 | 310 | bd(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(aZ, 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) | |
311 | 311 | } | |
312 | 312 | ||
313 | 313 | ||
314 | 314 | func be (aw) = { | |
315 | 315 | let aD = valueOrErrorMessage(getString(this, (aw + N)), "Can't find pool addr by share id") | |
316 | 316 | let aq = Address(fromBase58String(aD)) | |
317 | 317 | let bf = valueOrErrorMessage(getString(this, (M + aD)), "Pool is not inited") | |
318 | 318 | let bg = az(aq, bf) | |
319 | 319 | let au = bg._1 | |
320 | 320 | let av = bg._2 | |
321 | 321 | let bh = bg._3 | |
322 | 322 | let bi = bg._4 | |
323 | 323 | let bj = ( let at = invoke(aa, "getTWAP60", [au, false], nil) | |
324 | 324 | if ($isInstanceOf(at, "(Int, Int)")) | |
325 | 325 | then at | |
326 | 326 | else throw(($getType(at) + " couldn't be cast to (Int, Int)")))._2 | |
327 | 327 | let bk = ( let at = invoke(aa, "getTWAP60", [av, false], nil) | |
328 | 328 | if ($isInstanceOf(at, "(Int, Int)")) | |
329 | 329 | then at | |
330 | 330 | else throw(($getType(at) + " couldn't be cast to (Int, Int)")))._2 | |
331 | 331 | let bl = aB(aq, bf, aw) | |
332 | 332 | let bm = pow(10, 0, aP(au), 0, 0, DOWN) | |
333 | 333 | let bn = pow(10, 0, aP(av), 0, 0, DOWN) | |
334 | 334 | let bo = pow(10, 0, aP(aw), 0, 0, DOWN) | |
335 | 335 | let bp = (fraction(bh, bj, bm) + fraction(bi, bk, bn)) | |
336 | 336 | fraction(bp, bo, bl) | |
337 | 337 | } | |
338 | 338 | ||
339 | 339 | ||
340 | 340 | func bq (br) = { | |
341 | 341 | func aU (aV,aw) = (aV :+ be(aw)) | |
342 | 342 | ||
343 | 343 | let aX = br | |
344 | 344 | let aY = size(aX) | |
345 | 345 | let aZ = nil | |
346 | 346 | func ba (bb,bc) = if ((bc >= aY)) | |
347 | 347 | then bb | |
348 | 348 | else aU(bb, aX[bc]) | |
349 | 349 | ||
350 | 350 | func bd (bb,bc) = if ((bc >= aY)) | |
351 | 351 | then bb | |
352 | 352 | else throw("List size exceeds 20") | |
353 | 353 | ||
354 | 354 | bd(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(aZ, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20) | |
355 | 355 | } | |
356 | 356 | ||
357 | 357 | ||
358 | 358 | func bs (au,av,aw) = { | |
359 | 359 | let bt = aS([au, av]) | |
360 | 360 | let bu = be(aw) | |
361 | 361 | let bv = [toString(bt[0]), toString(bt[1]), toString(bu)] | |
362 | 362 | [StringEntry(P, makeString(bv, ","))] | |
363 | 363 | } | |
364 | 364 | ||
365 | 365 | ||
366 | 366 | func bw (bf,aq,bx,au,by,av,ax,ay) = if ((bf == a)) | |
367 | 367 | then { | |
368 | 368 | let bz = { | |
369 | 369 | let at = invoke(aq, "callFunction", ["calcLPReplenishTwoTokensREADONLY", [toString(bx), toString(by)]], nil) | |
370 | 370 | if ($isInstanceOf(at, "List[Any]")) | |
371 | 371 | then at | |
372 | 372 | else throw(($getType(at) + " couldn't be cast to List[Any]")) | |
373 | 373 | } | |
374 | 374 | if ((bz == bz)) | |
375 | 375 | then $Tuple5({ | |
376 | 376 | let at = bz[3] | |
377 | 377 | if ($isInstanceOf(at, "Int")) | |
378 | 378 | then at | |
379 | 379 | else throw(($getType(at) + " couldn't be cast to Int")) | |
380 | 380 | }, { | |
381 | 381 | let at = bz[4] | |
382 | 382 | if ($isInstanceOf(at, "Int")) | |
383 | 383 | then at | |
384 | 384 | else throw(($getType(at) + " couldn't be cast to Int")) | |
385 | 385 | }, { | |
386 | 386 | let at = bz[1] | |
387 | 387 | if ($isInstanceOf(at, "Int")) | |
388 | 388 | then at | |
389 | 389 | else throw(($getType(at) + " couldn't be cast to Int")) | |
390 | 390 | }, aN({ | |
391 | 391 | let at = bz[2] | |
392 | 392 | if ($isInstanceOf(at, "ByteVector|Unit")) | |
393 | 393 | then at | |
394 | 394 | else throw(($getType(at) + " couldn't be cast to ByteVector|Unit")) | |
395 | 395 | }), { | |
396 | 396 | let at = bz[0] | |
397 | 397 | if ($isInstanceOf(at, "Int")) | |
398 | 398 | then at | |
399 | 399 | else throw(($getType(at) + " couldn't be cast to Int")) | |
400 | 400 | }) | |
401 | 401 | else throw("Strict value is not equal to itself.") | |
402 | 402 | } | |
403 | 403 | else { | |
404 | 404 | let bA = $Tuple2(split({ | |
405 | 405 | let at = invoke(aq, "evaluatePutByAmountAssetREADONLY", [bx], nil) | |
406 | 406 | if ($isInstanceOf(at, "String")) | |
407 | 407 | then at | |
408 | 408 | else throw(($getType(at) + " couldn't be cast to String")) | |
409 | 409 | }, "__"), split({ | |
410 | 410 | let at = invoke(aq, "evaluatePutByPriceAssetREADONLY", [by], nil) | |
411 | 411 | if ($isInstanceOf(at, "String")) | |
412 | 412 | then at | |
413 | 413 | else throw(($getType(at) + " couldn't be cast to String")) | |
414 | 414 | }, "__")) | |
415 | 415 | if ((bA == bA)) | |
416 | 416 | then { | |
417 | 417 | let bB = bA._2 | |
418 | 418 | let bC = bA._1 | |
419 | 419 | let bD = parseIntValue(bC[1]) | |
420 | 420 | let bE = parseIntValue(bB[1]) | |
421 | 421 | if ((bE > bD)) | |
422 | 422 | then { | |
423 | 423 | let bF = parseIntValue(bC[8]) | |
424 | 424 | $Tuple5(bx, bF, (by - bF), av, bE) | |
425 | 425 | } | |
426 | 426 | else { | |
427 | 427 | let bF = parseIntValue(bC[8]) | |
428 | 428 | $Tuple5(bF, by, (bx - bF), au, bD) | |
429 | 429 | } | |
430 | 430 | } | |
431 | 431 | else throw("Strict value is not equal to itself.") | |
432 | 432 | } | |
433 | 433 | ||
434 | 434 | ||
435 | 435 | func bG (aq,bf,bx,au,by,av) = { | |
436 | 436 | let bH = [AttachedPayment(aO(au), bx), AttachedPayment(aO(av), by)] | |
437 | 437 | if ((bf == a)) | |
438 | 438 | then invoke(aq, "callFunction", ["replenishWithTwoTokens", ["false", "0"]], bH) | |
439 | 439 | else invoke(aq, "put", [1000000, false], bH) | |
440 | 440 | } | |
441 | 441 | ||
442 | 442 | ||
443 | 443 | func bI (aq,bf,bF,bJ) = { | |
444 | 444 | let bH = [AttachedPayment(aO(bJ), bF)] | |
445 | 445 | if ((bf == a)) | |
446 | 446 | then invoke(aq, "callFunction", ["replenishWithOneToken", ["0", "false", "0"]], bH) | |
447 | 447 | else invoke(aq, "putOneTkn", [0, false], bH) | |
448 | 448 | } | |
449 | 449 | ||
450 | 450 | ||
451 | 451 | func bK (aD,bf,aw,bL) = { | |
452 | 452 | let bH = [AttachedPayment(fromBase58String(aw), bL)] | |
453 | 453 | if ((bf == a)) | |
454 | 454 | then invoke(aJ(), "lockShareTokens", [aD, 0], bH) | |
455 | 455 | else invoke(aK(addressFromStringValue(aD)), "stake", nil, bH) | |
456 | 456 | } | |
457 | 457 | ||
458 | 458 | ||
459 | 459 | func bM (aD,bf,aw,bL) = { | |
460 | 460 | let bN = if ((bf == a)) | |
461 | 461 | then $Tuple3(aJ(), "withdrawShareTokens", [aD, bL]) | |
462 | 462 | else if ((bf == b)) | |
463 | 463 | then $Tuple3(aK(Address(fromBase58String(aD))), "unstake", [aw, bL]) | |
464 | 464 | else throw("Wrong pool type") | |
465 | 465 | let bO = bN._1 | |
466 | 466 | let bP = bN._2 | |
467 | 467 | let bQ = bN._3 | |
468 | - | let | |
469 | - | if (( | |
468 | + | let bR = invoke(bO, bP, bQ, nil) | |
469 | + | if ((bR == bR)) | |
470 | 470 | then bL | |
471 | 471 | else throw("Strict value is not equal to itself.") | |
472 | 472 | } | |
473 | 473 | ||
474 | 474 | ||
475 | - | func | |
475 | + | func bS (aD,bT,bU,ax,ay,bV,bW) = { | |
476 | 476 | let aq = Address(fromBase58String(aD)) | |
477 | - | let | |
478 | - | let | |
479 | - | let | |
480 | - | let | |
477 | + | let bX = 1000000 | |
478 | + | let bY = getIntegerValue(aq, t) | |
479 | + | let bZ = fraction(bV, bX, (bX - bY)) | |
480 | + | let ca = if ((bW == bT)) | |
481 | 481 | then { | |
482 | - | let | |
483 | - | $Tuple2( | |
482 | + | let cb = fraction(ax, bZ, (ay - bZ)) | |
483 | + | $Tuple2(cb, bU) | |
484 | 484 | } | |
485 | 485 | else { | |
486 | - | let | |
487 | - | $Tuple2( | |
486 | + | let cb = fraction(ay, bZ, (ax - bZ)) | |
487 | + | $Tuple2(cb, bT) | |
488 | 488 | } | |
489 | - | let | |
490 | - | let | |
491 | - | $Tuple2( | |
489 | + | let cb = ca._1 | |
490 | + | let cc = ca._2 | |
491 | + | $Tuple2(cc, cb) | |
492 | 492 | } | |
493 | 493 | ||
494 | 494 | ||
495 | - | func | |
496 | - | let | |
497 | - | let | |
498 | - | let | |
499 | - | let | |
495 | + | func cd (aD,bT,bU,ax,ay,bV,bW) = { | |
496 | + | let ce = getIntegerValue(ab, "%s__protocolFee") | |
497 | + | let cf = getIntegerValue(ab, "%s__poolFee") | |
498 | + | let cg = toBigInt(100000000) | |
499 | + | let ch = if ((bW == bT)) | |
500 | 500 | then { | |
501 | - | let | |
502 | - | $Tuple2( | |
501 | + | let cb = fraction(ax, bV, (ay - bV)) | |
502 | + | $Tuple2(cb, bU) | |
503 | 503 | } | |
504 | 504 | else { | |
505 | - | let | |
506 | - | $Tuple2( | |
505 | + | let cb = fraction(ay, bV, (ax - bV)) | |
506 | + | $Tuple2(cb, bT) | |
507 | 507 | } | |
508 | - | let | |
509 | - | let | |
510 | - | let | |
511 | - | $Tuple2( | |
508 | + | let cb = ch._1 | |
509 | + | let cc = ch._2 | |
510 | + | let ci = toInt(fraction(toBigInt(cb), cg, (cg - toBigInt((ce + cf))))) | |
511 | + | $Tuple2(cc, ci) | |
512 | 512 | } | |
513 | 513 | ||
514 | 514 | ||
515 | - | func | |
515 | + | func cj (aA,aD,bT,bU,ax,ay,bV,bW) = if ((aA == a)) | |
516 | 516 | then { | |
517 | - | let | |
518 | - | let | |
519 | - | let | |
520 | - | invoke(addressFromStringValue(aD), "callFunction", ["exchange", ["1"]], [AttachedPayment(aO( | |
517 | + | let ck = bS(aD, bT, bU, ax, ay, bV, bW) | |
518 | + | let cc = ck._1 | |
519 | + | let cb = ck._2 | |
520 | + | invoke(addressFromStringValue(aD), "callFunction", ["exchange", ["1"]], [AttachedPayment(aO(cc), cb)]) | |
521 | 521 | } | |
522 | 522 | else { | |
523 | - | let | |
524 | - | let | |
525 | - | let | |
526 | - | invoke(ab, "swap", [1, | |
523 | + | let cl = cd(aD, bT, bU, ax, ay, bV, bW) | |
524 | + | let cc = cl._1 | |
525 | + | let cb = cl._2 | |
526 | + | invoke(ab, "swap", [1, bW, toString(this)], [AttachedPayment(aO(cc), cb)]) | |
527 | 527 | } | |
528 | 528 | ||
529 | 529 | ||
530 | - | func | |
530 | + | func cm (bf,aD,bx,au,by,av,ax,ay) = { | |
531 | 531 | let aq = addressFromStringValue(aD) | |
532 | 532 | if ((bf == a)) | |
533 | 533 | then { | |
534 | - | let | |
534 | + | let bR = { | |
535 | 535 | let at = invoke(aq, "callFunction", ["calcLPReplenishDiffPropREADONLY", [toString(bx), toString(by), "0"]], nil) | |
536 | 536 | if ($isInstanceOf(at, "List[Any]")) | |
537 | 537 | then at | |
538 | 538 | else throw(($getType(at) + " couldn't be cast to List[Any]")) | |
539 | 539 | } | |
540 | - | if (( | |
540 | + | if ((bR == bR)) | |
541 | 541 | then $Tuple2({ | |
542 | - | let at = | |
542 | + | let at = bR[0] | |
543 | 543 | if ($isInstanceOf(at, "Int")) | |
544 | 544 | then at | |
545 | 545 | else throw(($getType(at) + " couldn't be cast to Int")) | |
546 | 546 | }, { | |
547 | - | let at = | |
547 | + | let at = bR[1] | |
548 | 548 | if ($isInstanceOf(at, "Int")) | |
549 | 549 | then at | |
550 | 550 | else throw(($getType(at) + " couldn't be cast to Int")) | |
551 | 551 | }) | |
552 | 552 | else throw("Strict value is not equal to itself.") | |
553 | 553 | } | |
554 | 554 | else if ((bf == b)) | |
555 | 555 | then { | |
556 | - | let | |
556 | + | let cn = if (if ((bx > 0)) | |
557 | 557 | then (by > 0) | |
558 | 558 | else false) | |
559 | 559 | then { | |
560 | - | let | |
561 | - | let | |
562 | - | let | |
563 | - | let | |
564 | - | let | |
565 | - | let | |
566 | - | $Tuple3( | |
560 | + | let co = bw(bf, aq, bx, au, by, av, ax, ay) | |
561 | + | let cp = co._1 | |
562 | + | let cq = co._2 | |
563 | + | let cr = co._3 | |
564 | + | let cs = co._4 | |
565 | + | let ct = co._5 | |
566 | + | $Tuple3(cr, cs, ct) | |
567 | 567 | } | |
568 | 568 | else if ((bx > 0)) | |
569 | 569 | then $Tuple3(bx, au, 0) | |
570 | 570 | else $Tuple3(by, av, 0) | |
571 | - | let | |
572 | - | let | |
573 | - | let | |
574 | - | let | |
571 | + | let cr = cn._1 | |
572 | + | let cs = cn._2 | |
573 | + | let cu = cn._3 | |
574 | + | let cv = if ((cr > 0)) | |
575 | 575 | then { | |
576 | - | let | |
577 | - | let at = invoke(aq, "putOneTknREADONLY", [ | |
576 | + | let bR = { | |
577 | + | let at = invoke(aq, "putOneTknREADONLY", [cs, cr], nil) | |
578 | 578 | if ($isInstanceOf(at, "(Int, Int, Int)")) | |
579 | 579 | then at | |
580 | 580 | else throw(($getType(at) + " couldn't be cast to (Int, Int, Int)")) | |
581 | 581 | } | |
582 | - | if (( | |
583 | - | then $Tuple2( | |
582 | + | if ((bR == bR)) | |
583 | + | then $Tuple2(bR._1, bR._3) | |
584 | 584 | else throw("Strict value is not equal to itself.") | |
585 | 585 | } | |
586 | 586 | else $Tuple2(0, 0) | |
587 | - | let | |
588 | - | let | |
589 | - | $Tuple2(( | |
587 | + | let cw = cv._1 | |
588 | + | let cx = cv._2 | |
589 | + | $Tuple2((cu + cw), cx) | |
590 | 590 | } | |
591 | 591 | else throw("Wrong pool type") | |
592 | 592 | } | |
593 | 593 | ||
594 | 594 | ||
595 | - | func | |
595 | + | func cy (bf,aD,ct,aw,au,av,ax,ay,cz,cA) = { | |
596 | 596 | let aq = addressFromStringValue(aD) | |
597 | - | let | |
597 | + | let cB = if ((bf == a)) | |
598 | 598 | then { | |
599 | - | let | |
600 | - | let at = invoke(aq, "callFunction", ["withdrawREADONLY", [toString( | |
599 | + | let bR = { | |
600 | + | let at = invoke(aq, "callFunction", ["withdrawREADONLY", [toString(ct), toString(ax), toString(ay)]], nil) | |
601 | 601 | if ($isInstanceOf(at, "List[Any]")) | |
602 | 602 | then at | |
603 | 603 | else throw(($getType(at) + " couldn't be cast to List[Any]")) | |
604 | 604 | } | |
605 | - | if (( | |
605 | + | if ((bR == bR)) | |
606 | 606 | then $Tuple2({ | |
607 | - | let at = | |
607 | + | let at = bR[0] | |
608 | 608 | if ($isInstanceOf(at, "Int")) | |
609 | 609 | then at | |
610 | 610 | else throw(($getType(at) + " couldn't be cast to Int")) | |
611 | 611 | }, { | |
612 | - | let at = | |
612 | + | let at = bR[1] | |
613 | 613 | if ($isInstanceOf(at, "Int")) | |
614 | 614 | then at | |
615 | 615 | else throw(($getType(at) + " couldn't be cast to Int")) | |
616 | 616 | }) | |
617 | 617 | else throw("Strict value is not equal to itself.") | |
618 | 618 | } | |
619 | 619 | else if ((bf == b)) | |
620 | 620 | then { | |
621 | - | let | |
622 | - | let at = invoke(aq, "evaluateGetREADONLY", [aw, | |
621 | + | let cC = split({ | |
622 | + | let at = invoke(aq, "evaluateGetREADONLY", [aw, ct], nil) | |
623 | 623 | if ($isInstanceOf(at, "String")) | |
624 | 624 | then at | |
625 | 625 | else throw(($getType(at) + " couldn't be cast to String")) | |
626 | 626 | }, "__") | |
627 | - | if (( | |
628 | - | then $Tuple2(parseIntValue( | |
627 | + | if ((cC == cC)) | |
628 | + | then $Tuple2(parseIntValue(cC[1]), parseIntValue(cC[2])) | |
629 | 629 | else throw("Strict value is not equal to itself.") | |
630 | 630 | } | |
631 | 631 | else throw("Wrong pool type") | |
632 | - | let | |
633 | - | let | |
634 | - | if (( | |
632 | + | let cD = cB._1 | |
633 | + | let cE = cB._2 | |
634 | + | if ((cz > 0)) | |
635 | 635 | then { | |
636 | - | let | |
637 | - | then ( | |
636 | + | let cF = if (if ((cA == au)) | |
637 | + | then (cz > cD) | |
638 | 638 | else false) | |
639 | - | then ( | |
640 | - | else if (if (( | |
641 | - | then ( | |
639 | + | then (cz - cD) | |
640 | + | else if (if ((cA == av)) | |
641 | + | then (cz > cE) | |
642 | 642 | else false) | |
643 | - | then ( | |
643 | + | then (cz - cE) | |
644 | 644 | else 0 | |
645 | - | let | |
645 | + | let cG = if ((cF > 0)) | |
646 | 646 | then if ((bf == a)) | |
647 | - | then | |
648 | - | else | |
647 | + | then bS(aD, au, av, ax, ay, cF, cA) | |
648 | + | else cd(aD, au, av, ax, ay, cF, cA) | |
649 | 649 | else $Tuple2("", 0) | |
650 | - | let | |
651 | - | let | |
652 | - | if (( | |
653 | - | then $Tuple2((( | |
654 | - | else $Tuple2(( | |
650 | + | let cc = cG._1 | |
651 | + | let cb = cG._2 | |
652 | + | if ((cA == au)) | |
653 | + | then $Tuple2(((cD + cF) - cz), (cE - cb)) | |
654 | + | else $Tuple2((cD - cb), ((cE + cF) - cz)) | |
655 | 655 | } | |
656 | - | else $Tuple2( | |
656 | + | else $Tuple2(cD, cE) | |
657 | 657 | } | |
658 | 658 | ||
659 | 659 | ||
660 | - | func | |
660 | + | func cH (aA,aD) = if ((aA == a)) | |
661 | 661 | then { | |
662 | - | let | |
663 | - | if (( | |
662 | + | let cI = ak(ac) | |
663 | + | if ((cI == cI)) | |
664 | 664 | then { | |
665 | - | let | |
666 | - | if (( | |
665 | + | let bR = invoke(aJ(), "claim", [aD], nil) | |
666 | + | if ((bR == bR)) | |
667 | 667 | then { | |
668 | - | let | |
669 | - | $Tuple2(( | |
668 | + | let cJ = ak(ac) | |
669 | + | $Tuple2((cJ - cI), ac) | |
670 | 670 | } | |
671 | 671 | else throw("Strict value is not equal to itself.") | |
672 | 672 | } | |
673 | 673 | else throw("Strict value is not equal to itself.") | |
674 | 674 | } | |
675 | 675 | else if ((aA == b)) | |
676 | 676 | then { | |
677 | - | let | |
678 | - | if (( | |
677 | + | let cI = ak(ad) | |
678 | + | if ((cI == cI)) | |
679 | 679 | then { | |
680 | - | let | |
681 | - | if (( | |
680 | + | let bR = invoke(aK(Address(fromBase58String(aD))), "claimWX", [aD], nil) | |
681 | + | if ((bR == bR)) | |
682 | 682 | then { | |
683 | - | let | |
684 | - | $Tuple2(( | |
683 | + | let cJ = ak(ad) | |
684 | + | $Tuple2((cJ - cI), ad) | |
685 | 685 | } | |
686 | 686 | else throw("Strict value is not equal to itself.") | |
687 | 687 | } | |
688 | 688 | else throw("Strict value is not equal to itself.") | |
689 | 689 | } | |
690 | 690 | else throw("Wrong pool type") | |
691 | 691 | ||
692 | 692 | ||
693 | - | func | |
694 | - | let | |
695 | - | if (( | |
693 | + | func cK (bf,aD,aI,bx,au,by,av,ax,ay,cL) = { | |
694 | + | let cM = ak(fromBase58String(cL)) | |
695 | + | if ((cM == cM)) | |
696 | 696 | then { | |
697 | 697 | let aq = addressFromStringValue(aD) | |
698 | - | let | |
698 | + | let cN = if (if ((bx > 0)) | |
699 | 699 | then (by > 0) | |
700 | 700 | else false) | |
701 | 701 | then { | |
702 | - | let | |
703 | - | let | |
704 | - | let | |
705 | - | let | |
706 | - | let | |
707 | - | let | |
708 | - | if (( | |
709 | - | then $Tuple2( | |
702 | + | let cO = bw(bf, aq, bx, au, by, av, ax, ay) | |
703 | + | let cp = cO._1 | |
704 | + | let cq = cO._2 | |
705 | + | let cr = cO._3 | |
706 | + | let cs = cO._4 | |
707 | + | let bR = bG(aq, bf, cp, au, cq, av) | |
708 | + | if ((bR == bR)) | |
709 | + | then $Tuple2(cr, cs) | |
710 | 710 | else throw("Strict value is not equal to itself.") | |
711 | 711 | } | |
712 | 712 | else if ((bx > 0)) | |
713 | 713 | then $Tuple2(bx, au) | |
714 | 714 | else if ((by > 0)) | |
715 | 715 | then $Tuple2(by, av) | |
716 | 716 | else throw("pmts must be > 0") | |
717 | - | let | |
718 | - | let | |
719 | - | let | |
720 | - | then bI(aq, bf, | |
717 | + | let cr = cN._1 | |
718 | + | let cs = cN._2 | |
719 | + | let bR = if ((cr > 0)) | |
720 | + | then bI(aq, bf, cr, cs) | |
721 | 721 | else nil | |
722 | - | if (( | |
722 | + | if ((bR == bR)) | |
723 | 723 | then { | |
724 | - | let | |
725 | - | let | |
726 | - | let | |
727 | - | let | |
728 | - | if ((0 >= | |
724 | + | let cP = ak(fromBase58String(cL)) | |
725 | + | let cQ = (cP - cM) | |
726 | + | let cR = fraction(cQ, aH(aD, aI), m) | |
727 | + | let cS = (cQ - cR) | |
728 | + | if ((0 >= cS)) | |
729 | 729 | then throw("amount of staked sharetokens must be > 0") | |
730 | 730 | else { | |
731 | - | let | |
732 | - | if (( | |
733 | - | then $Tuple2( | |
731 | + | let cT = bK(aD, bf, cL, cS) | |
732 | + | if ((cT == cT)) | |
733 | + | then $Tuple2(cS, cR) | |
734 | 734 | else throw("Strict value is not equal to itself.") | |
735 | 735 | } | |
736 | 736 | } | |
737 | 737 | else throw("Strict value is not equal to itself.") | |
738 | 738 | } | |
739 | 739 | else throw("Strict value is not equal to itself.") | |
740 | 740 | } | |
741 | 741 | ||
742 | 742 | ||
743 | - | func | |
744 | - | let | |
745 | - | let | |
746 | - | let | |
747 | - | then $Tuple2(getIntegerValue(this, (aD + C)), ( | |
748 | - | else $Tuple2(getIntegerValue(this, (aD + D)), | |
749 | - | let | |
750 | - | let | |
751 | - | [IntegerEntry((aD + A), ( | |
743 | + | func cU (aD,aG,cV,cR,cW,aw,aA,cX) = { | |
744 | + | let cY = aC(aD) | |
745 | + | let cZ = aE(aD) | |
746 | + | let da = if (cX) | |
747 | + | then $Tuple2(getIntegerValue(this, (aD + C)), (cZ + cV)) | |
748 | + | else $Tuple2(getIntegerValue(this, (aD + D)), cZ) | |
749 | + | let db = da._1 | |
750 | + | let dc = da._2 | |
751 | + | [IntegerEntry((aD + A), (cY + cV)), IntegerEntry((aD + B), dc), IntegerEntry((((((aD + "_") + aG) + "_") + toString(cW)) + u), cV), IntegerEntry((((((aD + "_") + aG) + "_") + toString(cW)) + z), db), StringEntry((((aG + "_") + toString(cW)) + v), aD), IntegerEntry((aG + y), cW), ScriptTransfer(Y, cR, fromBase58String(aw))] | |
752 | 752 | } | |
753 | 753 | ||
754 | 754 | ||
755 | - | func | |
756 | - | let | |
757 | - | if (( | |
755 | + | func dd (de,df,dg,dh,di,dj,dk,dl,dm,dn) = { | |
756 | + | let do = ak(aO(de)) | |
757 | + | if ((do == do)) | |
758 | 758 | then { | |
759 | - | let | |
760 | - | if (( | |
761 | - | then (ak(aO( | |
759 | + | let bR = invoke(Z, "swap", [dh, di, dj, dk, dl, dm, dn], [AttachedPayment(dg, df)]) | |
760 | + | if ((bR == bR)) | |
761 | + | then (ak(aO(de)) - do) | |
762 | 762 | else throw("Strict value is not equal to itself.") | |
763 | 763 | } | |
764 | 764 | else throw("Strict value is not equal to itself.") | |
765 | 765 | } | |
766 | 766 | ||
767 | 767 | ||
768 | - | func | |
769 | - | let | |
770 | - | if (( | |
768 | + | func dp (de,df,dg,dq,dr,dn) = { | |
769 | + | let do = ak(aO(de)) | |
770 | + | if ((do == do)) | |
771 | 771 | then { | |
772 | - | let | |
773 | - | if (( | |
774 | - | then (ak(aO( | |
772 | + | let bR = invoke(Z, "puzzleSwap", [dq, dr, dn], [AttachedPayment(dg, df)]) | |
773 | + | if ((bR == bR)) | |
774 | + | then (ak(aO(de)) - do) | |
775 | 775 | else throw("Strict value is not equal to itself.") | |
776 | 776 | } | |
777 | 777 | else throw("Strict value is not equal to itself.") | |
778 | 778 | } | |
779 | 779 | ||
780 | 780 | ||
781 | - | func | |
782 | - | let | |
783 | - | if (( | |
781 | + | func ds (de,df,dg,dt,du,dv,dw,dx,dy,dn) = { | |
782 | + | let do = ak(aO(de)) | |
783 | + | if ((do == do)) | |
784 | 784 | then { | |
785 | - | let | |
786 | - | if (( | |
787 | - | then (ak(aO( | |
785 | + | let bR = invoke(Z, "swopfiSwap", [dt, du, dv, dw, dx, dy, dn], [AttachedPayment(dg, df)]) | |
786 | + | if ((bR == bR)) | |
787 | + | then (ak(aO(de)) - do) | |
788 | 788 | else throw("Strict value is not equal to itself.") | |
789 | 789 | } | |
790 | 790 | else throw("Strict value is not equal to itself.") | |
791 | 791 | } | |
792 | 792 | ||
793 | 793 | ||
794 | - | func | |
794 | + | func dz (aD,bf,dA,dB) = { | |
795 | 795 | let aq = Address(fromBase58String(aD)) | |
796 | - | let | |
797 | - | let | |
798 | - | let | |
799 | - | let ax = | |
800 | - | let ay = | |
801 | - | let aw = | |
802 | - | if (if (( | |
803 | - | then ( | |
796 | + | let dC = az(aq, bf) | |
797 | + | let dD = dC._1 | |
798 | + | let dE = dC._2 | |
799 | + | let ax = dC._3 | |
800 | + | let ay = dC._4 | |
801 | + | let aw = dC._5 | |
802 | + | if (if ((dA != dD)) | |
803 | + | then (dA != dE) | |
804 | 804 | else false) | |
805 | 805 | then throw("Wrong asset") | |
806 | 806 | else { | |
807 | - | let | |
808 | - | then $Tuple2( | |
809 | - | else $Tuple2(0, | |
810 | - | let bx = | |
811 | - | let by = | |
812 | - | let | |
813 | - | let | |
814 | - | let | |
815 | - | let | |
816 | - | let | |
817 | - | let | |
818 | - | let | |
819 | - | let | |
820 | - | let | |
821 | - | let | |
822 | - | let | |
823 | - | then ( | |
807 | + | let dF = if ((dA == dD)) | |
808 | + | then $Tuple2(dB, 0) | |
809 | + | else $Tuple2(0, dB) | |
810 | + | let bx = dF._1 | |
811 | + | let by = dF._2 | |
812 | + | let dG = cK(bf, aD, i, bx, dD, by, dE, ax, ay, aw) | |
813 | + | let cV = dG._1 | |
814 | + | let dH = dG._2 | |
815 | + | let dI = valueOrElse(getInteger(this, (aD + C)), 0) | |
816 | + | let dJ = valueOrElse(getInteger(this, (aD + D)), 0) | |
817 | + | let dK = aC(aD) | |
818 | + | let dL = aE(aD) | |
819 | + | let dM = fraction(dL, j, dK) | |
820 | + | let dN = fraction(cV, dM, j) | |
821 | + | let dO = (cV - dN) | |
822 | + | let dP = if ((dL > 0)) | |
823 | + | then (dI + fraction(dN, k, dL)) | |
824 | 824 | else 0 | |
825 | - | let | |
826 | - | then ( | |
825 | + | let dQ = if (((dK - dL) > 0)) | |
826 | + | then (dJ + fraction(dO, k, (dK - dL))) | |
827 | 827 | else 0 | |
828 | - | let | |
829 | - | let | |
830 | - | let | |
831 | - | if (( | |
832 | - | then ([IntegerEntry((aD + C), | |
828 | + | let dR = fraction(dN, aH(aD, d), m) | |
829 | + | let dS = fraction(dO, aH(aD, c), m) | |
830 | + | let dT = bM(aD, bf, aw, (dR + dS)) | |
831 | + | if ((dT == dT)) | |
832 | + | then ([IntegerEntry((aD + C), dP), IntegerEntry((aD + D), dQ), IntegerEntry((aD + A), ((dK + cV) - dT)), IntegerEntry((aD + B), ((dL + dN) - dR)), ScriptTransfer(Y, (dR + dS), fromBase58String(aw))] ++ bs(dD, dE, aw)) | |
833 | 833 | else throw("Strict value is not equal to itself.") | |
834 | 834 | } | |
835 | 835 | } | |
836 | 836 | ||
837 | 837 | ||
838 | - | func | |
838 | + | func dU (aD,dV,dW,dX) = { | |
839 | 839 | let aq = Address(fromBase58String(aD)) | |
840 | 840 | let bf = valueOrErrorMessage(getString(this, (M + aD)), "Unknown pool") | |
841 | - | let | |
842 | - | let | |
843 | - | let | |
844 | - | let ax = | |
845 | - | let ay = | |
846 | - | let aw = | |
847 | - | let | |
848 | - | if (( | |
841 | + | let dY = az(aq, bf) | |
842 | + | let bT = dY._1 | |
843 | + | let bU = dY._2 | |
844 | + | let ax = dY._3 | |
845 | + | let ay = dY._4 | |
846 | + | let aw = dY._5 | |
847 | + | let dZ = ak(aO(bT)) | |
848 | + | if ((dZ == dZ)) | |
849 | 849 | then { | |
850 | - | let | |
851 | - | if (( | |
850 | + | let ea = ak(aO(bU)) | |
851 | + | if ((ea == ea)) | |
852 | 852 | then { | |
853 | - | let | |
854 | - | then invoke(aq, "callFunction", ["withdraw", [toString( | |
853 | + | let bR = if ((bf == a)) | |
854 | + | then invoke(aq, "callFunction", ["withdraw", [toString(dV)]], nil) | |
855 | 855 | else { | |
856 | - | let | |
857 | - | if (( | |
858 | - | then invoke(aq, "get", nil, [AttachedPayment(aO(aw), | |
856 | + | let bR = bM(aD, bf, aw, dV) | |
857 | + | if ((bR == bR)) | |
858 | + | then invoke(aq, "get", nil, [AttachedPayment(aO(aw), dV)]) | |
859 | 859 | else throw("Strict value is not equal to itself.") | |
860 | 860 | } | |
861 | - | if (( | |
861 | + | if ((bR == bR)) | |
862 | 862 | then { | |
863 | - | let ea = ak(aO(bS)) | |
864 | 863 | let eb = ak(aO(bT)) | |
865 | - | let ec = $Tuple2((ea - dY), (eb - dZ)) | |
866 | - | let ed = ec._1 | |
867 | - | let ee = ec._2 | |
868 | - | let ef = if ((dV > 0)) | |
864 | + | let ec = ak(aO(bU)) | |
865 | + | let ed = $Tuple2((eb - dZ), (ec - ea)) | |
866 | + | let ee = ed._1 | |
867 | + | let ef = ed._2 | |
868 | + | let eg = if ((dW > 0)) | |
869 | 869 | then { | |
870 | - | let | |
871 | - | then ( | |
870 | + | let cF = if (if ((dX == bT)) | |
871 | + | then (dW > ee) | |
872 | 872 | else false) | |
873 | - | then ( | |
874 | - | else if (if (( | |
875 | - | then ( | |
873 | + | then (dW - ee) | |
874 | + | else if (if ((dX == bU)) | |
875 | + | then (dW > ef) | |
876 | 876 | else false) | |
877 | - | then ( | |
877 | + | then (dW - ef) | |
878 | 878 | else 0 | |
879 | - | let | |
880 | - | then | |
879 | + | let eh = if ((cF > 0)) | |
880 | + | then cj(bf, aD, bT, bU, ax, ay, cF, dX) | |
881 | 881 | else 0 | |
882 | - | if (( | |
882 | + | if ((eh == eh)) | |
883 | 883 | then { | |
884 | - | let eh = ak(aO(bS)) | |
885 | 884 | let ei = ak(aO(bT)) | |
886 | - | $Tuple2((eh - dY), (ei - dZ)) | |
885 | + | let ej = ak(aO(bU)) | |
886 | + | $Tuple2((ei - dZ), (ej - ea)) | |
887 | 887 | } | |
888 | 888 | else throw("Strict value is not equal to itself.") | |
889 | 889 | } | |
890 | - | else $Tuple2( | |
891 | - | let | |
892 | - | let | |
893 | - | $Tuple7( | |
890 | + | else $Tuple2(ee, ef) | |
891 | + | let ek = eg._1 | |
892 | + | let el = eg._2 | |
893 | + | $Tuple7(ek, bT, el, bU, eb, ec, aw) | |
894 | 894 | } | |
895 | 895 | else throw("Strict value is not equal to itself.") | |
896 | 896 | } | |
897 | 897 | else throw("Strict value is not equal to itself.") | |
898 | 898 | } | |
899 | 899 | else throw("Strict value is not equal to itself.") | |
900 | 900 | } | |
901 | 901 | ||
902 | 902 | ||
903 | - | func | |
904 | - | let | |
905 | - | let | |
906 | - | let | |
903 | + | func em (aG,aD,en,eo) = { | |
904 | + | let ep = valueOrErrorMessage(getInteger(this, (((((aD + "_") + aG) + "_") + en) + u)), "Unknown position") | |
905 | + | let eq = getIntegerValue(this, (((((aD + "_") + aG) + "_") + en) + z)) | |
906 | + | let er = if (eo) | |
907 | 907 | then getIntegerValue(this, (aD + C)) | |
908 | 908 | else getIntegerValue(this, (aD + D)) | |
909 | - | ( | |
909 | + | (ep + fraction(ep, (er - eq), k)) | |
910 | 910 | } | |
911 | 911 | ||
912 | 912 | ||
913 | - | func | |
914 | - | let | |
915 | - | let | |
916 | - | let | |
917 | - | let | |
918 | - | let | |
919 | - | let | |
920 | - | let | |
921 | - | let | |
913 | + | func es (aG,aD,en,et) = { | |
914 | + | let ep = valueOrErrorMessage(getInteger(this, (((((aD + "_") + aG) + "_") + en) + u)), "Unknown position") | |
915 | + | let eq = getIntegerValue(this, (((((aD + "_") + aG) + "_") + en) + z)) | |
916 | + | let cz = valueOrElse(getInteger(this, (((((aD + "_") + aG) + "_") + en) + w)), 0) | |
917 | + | let dV = em(aG, aD, en, (cz > 0)) | |
918 | + | let eu = aC(aD) | |
919 | + | let ev = Address(fromBase58String(aG)) | |
920 | + | let dX = valueOrElse(getString(this, (((((aD + "_") + aG) + "_") + en) + x)), "") | |
921 | + | let dW = if ((cz > 0)) | |
922 | 922 | then { | |
923 | - | let at = invoke(ae(), "getAssetDebt", [false, ((aG + "_") + | |
923 | + | let at = invoke(ae(), "getAssetDebt", [false, ((aG + "_") + en), dX], nil) | |
924 | 924 | if ($isInstanceOf(at, "Int")) | |
925 | 925 | then at | |
926 | 926 | else throw(($getType(at) + " couldn't be cast to Int")) | |
927 | 927 | } | |
928 | 928 | else 0 | |
929 | - | let | |
930 | - | if (( | |
929 | + | let ew = dU(aD, dV, dW, dX) | |
930 | + | if ((ew == ew)) | |
931 | 931 | then { | |
932 | - | let aw = | |
933 | - | let | |
934 | - | let | |
935 | - | let | |
936 | - | let | |
937 | - | let | |
938 | - | let | |
939 | - | let | |
940 | - | then invoke(ae(), "repayFor", [((aG + "_") + | |
932 | + | let aw = ew._7 | |
933 | + | let ec = ew._6 | |
934 | + | let eb = ew._5 | |
935 | + | let bU = ew._4 | |
936 | + | let el = ew._3 | |
937 | + | let bT = ew._2 | |
938 | + | let ek = ew._1 | |
939 | + | let ex = if ((dW > 0)) | |
940 | + | then invoke(ae(), "repayFor", [((aG + "_") + en)], [AttachedPayment(aO(dX), dW)]) | |
941 | 941 | else 0 | |
942 | - | if (( | |
943 | - | then ([DeleteEntry((((((aD + "_") + aG) + "_") + | |
942 | + | if ((ex == ex)) | |
943 | + | then ([DeleteEntry((((((aD + "_") + aG) + "_") + en) + u)), DeleteEntry((((((aD + "_") + aG) + "_") + en) + z)), IntegerEntry((aD + A), (eu - dV)), ScriptTransfer(ev, ek, aO(bT)), ScriptTransfer(ev, el, aO(bU))] ++ bs(bT, bU, aw)) | |
944 | 944 | else throw("Strict value is not equal to itself.") | |
945 | 945 | } | |
946 | 946 | else throw("Strict value is not equal to itself.") | |
947 | 947 | } | |
948 | 948 | ||
949 | 949 | ||
950 | - | func | |
951 | - | let | |
952 | - | let aG = | |
953 | - | let aD = | |
954 | - | let bx = parseIntValue( | |
955 | - | let | |
956 | - | let by = parseIntValue( | |
957 | - | let | |
958 | - | let ax = parseIntValue( | |
959 | - | let ay = parseIntValue( | |
960 | - | let aw = | |
961 | - | let | |
962 | - | let | |
963 | - | $Tuple11(aG, aD, bx, | |
950 | + | func ey (ez) = { | |
951 | + | let eA = split(valueOrErrorMessage(getString(this, (ez + K)), ("No request with id " + ez)), ",") | |
952 | + | let aG = eA[0] | |
953 | + | let aD = eA[1] | |
954 | + | let bx = parseIntValue(eA[2]) | |
955 | + | let dD = eA[3] | |
956 | + | let by = parseIntValue(eA[4]) | |
957 | + | let dE = eA[5] | |
958 | + | let ax = parseIntValue(eA[6]) | |
959 | + | let ay = parseIntValue(eA[7]) | |
960 | + | let aw = eA[8] | |
961 | + | let eB = eA[9] | |
962 | + | let eC = parseIntValue(eA[10]) | |
963 | + | $Tuple11(aG, aD, bx, dD, by, dE, ax, ay, aw, eB, eC) | |
964 | 964 | } | |
965 | 965 | ||
966 | 966 | ||
967 | - | func | |
967 | + | func eD (bx,by,au,av,eE,eF) = { | |
968 | 968 | let bj = ( let at = invoke(aa, "getTWAP60", [au, false], nil) | |
969 | 969 | if ($isInstanceOf(at, "(Int, Int)")) | |
970 | 970 | then at | |
971 | 971 | else throw(($getType(at) + " couldn't be cast to (Int, Int)")))._2 | |
972 | 972 | let bk = ( let at = invoke(aa, "getTWAP60", [av, false], nil) | |
973 | 973 | if ($isInstanceOf(at, "(Int, Int)")) | |
974 | 974 | then at | |
975 | 975 | else throw(($getType(at) + " couldn't be cast to (Int, Int)")))._2 | |
976 | - | let | |
977 | - | let | |
978 | - | let | |
979 | - | let | |
980 | - | then $Tuple2(bj, | |
981 | - | else $Tuple2(bk, | |
982 | - | let | |
983 | - | let | |
984 | - | fraction(fraction( | |
976 | + | let eG = pow(10, 0, aP(au), 0, 0, DOWN) | |
977 | + | let eH = pow(10, 0, aP(av), 0, 0, DOWN) | |
978 | + | let eI = (fraction(bj, bx, eG) + fraction(bk, by, eH)) | |
979 | + | let eJ = if ((eF == au)) | |
980 | + | then $Tuple2(bj, eG) | |
981 | + | else $Tuple2(bk, eH) | |
982 | + | let eK = eJ._1 | |
983 | + | let eL = eJ._2 | |
984 | + | fraction(fraction(eI, (eE - 100), 100), eL, eK) | |
985 | 985 | } | |
986 | 986 | ||
987 | 987 | ||
988 | 988 | @Callable(ah) | |
989 | - | func calcPriceImpactEVALONLY (aD, | |
989 | + | func calcPriceImpactEVALONLY (aD,eE,eF,bx,by) = if (if ((100 > eE)) | |
990 | 990 | then true | |
991 | - | else ( | |
991 | + | else (eE > 300)) | |
992 | 992 | then throw("Leverage can't be <100 and >300") | |
993 | 993 | else { | |
994 | 994 | let bf = valueOrErrorMessage(getString(this, (M + aD)), "Pool is not inited") | |
995 | - | let | |
996 | - | let | |
997 | - | let | |
998 | - | let ax = | |
999 | - | let ay = | |
1000 | - | let aw = | |
1001 | - | let | |
1002 | - | then | |
995 | + | let eM = az(Address(fromBase58String(aD)), bf) | |
996 | + | let dD = eM._1 | |
997 | + | let dE = eM._2 | |
998 | + | let ax = eM._3 | |
999 | + | let ay = eM._4 | |
1000 | + | let aw = eM._5 | |
1001 | + | let cz = if ((eE > 100)) | |
1002 | + | then eD(bx, by, dD, dE, eE, eF) | |
1003 | 1003 | else 0 | |
1004 | - | let | |
1005 | - | then $Tuple2((bx + | |
1006 | - | else $Tuple2(bx, (by + | |
1007 | - | let | |
1008 | - | let | |
1009 | - | let | |
1010 | - | let | |
1011 | - | let | |
1012 | - | let | |
1013 | - | then ( | |
1014 | - | else | |
1015 | - | $Tuple2(nil, [ | |
1004 | + | let eN = if ((eF == dD)) | |
1005 | + | then $Tuple2((bx + cz), by) | |
1006 | + | else $Tuple2(bx, (by + cz)) | |
1007 | + | let eO = eN._1 | |
1008 | + | let eP = eN._2 | |
1009 | + | let eQ = cm(bf, aD, eO, dD, eP, dE, ax, ay) | |
1010 | + | let ct = eQ._1 | |
1011 | + | let cx = eQ._2 | |
1012 | + | let eR = if ((0 > cx)) | |
1013 | + | then (cx * -1) | |
1014 | + | else cx | |
1015 | + | $Tuple2(nil, [eR]) | |
1016 | 1016 | } | |
1017 | 1017 | ||
1018 | 1018 | ||
1019 | 1019 | ||
1020 | 1020 | @Callable(ah) | |
1021 | 1021 | func getShareAssetPriceREADONLY (aw) = { | |
1022 | - | let | |
1023 | - | $Tuple2(nil, | |
1022 | + | let eS = be(aw) | |
1023 | + | $Tuple2(nil, eS) | |
1024 | 1024 | } | |
1025 | 1025 | ||
1026 | 1026 | ||
1027 | 1027 | ||
1028 | 1028 | @Callable(ah) | |
1029 | - | func getUserPositionShareAmountREADONLY (aG, | |
1030 | - | let aD = valueOrErrorMessage(getString(this, (((aG + "_") + | |
1031 | - | let | |
1032 | - | let | |
1033 | - | $Tuple2(nil, | |
1029 | + | func getUserPositionShareAmountREADONLY (aG,cW) = { | |
1030 | + | let aD = valueOrErrorMessage(getString(this, (((aG + "_") + cW) + v)), "Unknown position") | |
1031 | + | let cz = getIntegerValue(this, (((((aD + "_") + aG) + "_") + cW) + w)) | |
1032 | + | let dV = em(aG, aD, cW, (cz > 0)) | |
1033 | + | $Tuple2(nil, dV) | |
1034 | 1034 | } | |
1035 | 1035 | ||
1036 | 1036 | ||
1037 | 1037 | ||
1038 | 1038 | @Callable(ah) | |
1039 | - | func getUserPositionInDollarsREADONLY (aG, | |
1040 | - | func | |
1041 | - | let | |
1042 | - | let | |
1043 | - | let | |
1044 | - | let | |
1039 | + | func getUserPositionInDollarsREADONLY (aG,eT,cW) = { | |
1040 | + | func eU (aV,aD) = { | |
1041 | + | let eV = aV | |
1042 | + | let eW = eV._1 | |
1043 | + | let eX = eV._2 | |
1044 | + | let eY = eV._3 | |
1045 | 1045 | let bf = valueOrErrorMessage(getString(this, (M + aD)), "Pool is not inited") | |
1046 | - | let | |
1047 | - | let | |
1048 | - | let | |
1049 | - | let ax = | |
1050 | - | let ay = | |
1051 | - | let aw = | |
1052 | - | let | |
1053 | - | let | |
1054 | - | let | |
1055 | - | let | |
1056 | - | let | |
1057 | - | if (( | |
1058 | - | then $Tuple3(( | |
1046 | + | let eZ = az(Address(fromBase58String(aD)), bf) | |
1047 | + | let dD = eZ._1 | |
1048 | + | let dE = eZ._2 | |
1049 | + | let ax = eZ._3 | |
1050 | + | let ay = eZ._4 | |
1051 | + | let aw = eZ._5 | |
1052 | + | let cz = valueOrElse(getInteger(this, (((((aD + "_") + aG) + "_") + cW[eY]) + w)), 0) | |
1053 | + | let dV = em(aG, aD, cW[eY], (cz > 0)) | |
1054 | + | let eS = be(aw) | |
1055 | + | let fa = pow(10, 0, aP(aw), 0, 0, DOWN) | |
1056 | + | let fb = fraction(dV, eS, fa) | |
1057 | + | if ((cz == 0)) | |
1058 | + | then $Tuple3((eW :+ fb), (eX :+ 0), (eY + 1)) | |
1059 | 1059 | else { | |
1060 | - | let | |
1061 | - | let | |
1062 | - | let at = invoke(ae(), "getAssetDebt", [false, ((aG + "_") + | |
1060 | + | let dX = getStringValue(this, (((((aD + "_") + aG) + "_") + cW[eY]) + x)) | |
1061 | + | let dW = { | |
1062 | + | let at = invoke(ae(), "getAssetDebt", [false, ((aG + "_") + cW[eY]), dX], nil) | |
1063 | 1063 | if ($isInstanceOf(at, "Int")) | |
1064 | 1064 | then at | |
1065 | 1065 | else throw(($getType(at) + " couldn't be cast to Int")) | |
1066 | 1066 | } | |
1067 | - | let | |
1067 | + | let fc = ( let at = invoke(aa, "getTWAP60", [dX, false], nil) | |
1068 | 1068 | if ($isInstanceOf(at, "(Int, Int)")) | |
1069 | 1069 | then at | |
1070 | 1070 | else throw(($getType(at) + " couldn't be cast to (Int, Int)")))._1 | |
1071 | - | let | |
1072 | - | let | |
1073 | - | $Tuple3(( | |
1071 | + | let fd = pow(10, 0, aP(dX), 0, 0, DOWN) | |
1072 | + | let fe = fraction(dW, fc, fd) | |
1073 | + | $Tuple3((eW :+ fb), (eX :+ fe), (eY + 1)) | |
1074 | 1074 | } | |
1075 | 1075 | } | |
1076 | 1076 | ||
1077 | - | let | |
1078 | - | let aX = | |
1077 | + | let ff = { | |
1078 | + | let aX = eT | |
1079 | 1079 | let aY = size(aX) | |
1080 | 1080 | let aZ = $Tuple3(nil, nil, 0) | |
1081 | 1081 | func ba (bb,bc) = if ((bc >= aY)) | |
1082 | 1082 | then bb | |
1083 | - | else | |
1083 | + | else eU(bb, aX[bc]) | |
1084 | 1084 | ||
1085 | 1085 | func bd (bb,bc) = if ((bc >= aY)) | |
1086 | 1086 | then bb | |
1087 | 1087 | else throw("List size exceeds 20") | |
1088 | 1088 | ||
1089 | 1089 | bd(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(ba(aZ, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20) | |
1090 | 1090 | } | |
1091 | - | let | |
1092 | - | let | |
1093 | - | $Tuple2(nil, $Tuple2( | |
1091 | + | let fg = ff._1 | |
1092 | + | let dW = ff._2 | |
1093 | + | $Tuple2(nil, $Tuple2(fg, dW)) | |
1094 | 1094 | } | |
1095 | 1095 | ||
1096 | 1096 | ||
1097 | 1097 | ||
1098 | 1098 | @Callable(ah) | |
1099 | - | func replenish (aD, | |
1099 | + | func replenish (aD,eE,eF) = if (if ((100 > eE)) | |
1100 | 1100 | then true | |
1101 | - | else ( | |
1101 | + | else (eE > 300)) | |
1102 | 1102 | then throw("Leverage can't be <100 and >300") | |
1103 | 1103 | else { | |
1104 | 1104 | let bf = valueOrErrorMessage(getString(this, (M + aD)), "Pool is not inited") | |
1105 | - | let | |
1106 | - | let | |
1107 | - | let | |
1108 | - | let ax = | |
1109 | - | let ay = | |
1110 | - | let aw = | |
1111 | - | let | |
1112 | - | then if ((aN(ah.payments[0].assetId) != | |
1105 | + | let fh = az(Address(fromBase58String(aD)), bf) | |
1106 | + | let dD = fh._1 | |
1107 | + | let dE = fh._2 | |
1108 | + | let ax = fh._3 | |
1109 | + | let ay = fh._4 | |
1110 | + | let aw = fh._5 | |
1111 | + | let fi = if ((size(ah.payments) == 2)) | |
1112 | + | then if ((aN(ah.payments[0].assetId) != dD)) | |
1113 | 1113 | then throw("Wrong payment asset A") | |
1114 | - | else if ((aN(ah.payments[1].assetId) != | |
1114 | + | else if ((aN(ah.payments[1].assetId) != dE)) | |
1115 | 1115 | then throw("Wrong payment asset B") | |
1116 | - | else $Tuple4(ah.payments[0].amount, | |
1116 | + | else $Tuple4(ah.payments[0].amount, dD, ah.payments[1].amount, dE) | |
1117 | 1117 | else if ((size(ah.payments) == 1)) | |
1118 | - | then if ((aN(ah.payments[0].assetId) == | |
1119 | - | then $Tuple4(ah.payments[0].amount, | |
1120 | - | else if ((aN(ah.payments[0].assetId) == | |
1121 | - | then $Tuple4(0, | |
1118 | + | then if ((aN(ah.payments[0].assetId) == dD)) | |
1119 | + | then $Tuple4(ah.payments[0].amount, dD, 0, dE) | |
1120 | + | else if ((aN(ah.payments[0].assetId) == dE)) | |
1121 | + | then $Tuple4(0, dD, ah.payments[0].amount, dE) | |
1122 | 1122 | else throw("Wrong payment") | |
1123 | 1123 | else throw("One or two payments expected") | |
1124 | - | let bx = | |
1125 | - | let | |
1126 | - | let by = | |
1127 | - | let | |
1128 | - | let | |
1129 | - | if (( | |
1124 | + | let bx = fi._1 | |
1125 | + | let fj = fi._2 | |
1126 | + | let by = fi._3 | |
1127 | + | let fk = fi._4 | |
1128 | + | let fl = aF(toString(ah.caller)) | |
1129 | + | if ((eE > 100)) | |
1130 | 1130 | then { | |
1131 | - | let | |
1132 | - | let | |
1133 | - | let | |
1134 | - | let at = invoke(this, "createNewRequest", [ | |
1131 | + | let cz = eD(bx, by, fj, fk, eE, eF) | |
1132 | + | let eA = makeString([toString(ah.caller), aD, toString(bx), fj, toString(by), fk, toString(ax), toString(ay), aw, eF, toString(cz)], ",") | |
1133 | + | let fm = { | |
1134 | + | let at = invoke(this, "createNewRequest", [eA], nil) | |
1135 | 1135 | if ($isInstanceOf(at, "Int")) | |
1136 | 1136 | then at | |
1137 | 1137 | else throw(($getType(at) + " couldn't be cast to Int")) | |
1138 | 1138 | } | |
1139 | - | if (( | |
1139 | + | if ((fm == fm)) | |
1140 | 1140 | then { | |
1141 | - | let | |
1142 | - | let | |
1143 | - | if (( | |
1141 | + | let fn = [((toString(ah.caller) + "_") + toString(fl)), aw, eF, cz, toString(this), "replenishFromLand", toString(valueOrErrorMessage(fm, "Can't create new request"))] | |
1142 | + | let bR = reentrantInvoke(ae(), "flashPosition", fn, nil) | |
1143 | + | if ((bR == bR)) | |
1144 | 1144 | then nil | |
1145 | 1145 | else throw("Strict value is not equal to itself.") | |
1146 | 1146 | } | |
1147 | 1147 | else throw("Strict value is not equal to itself.") | |
1148 | 1148 | } | |
1149 | 1149 | else { | |
1150 | - | let | |
1151 | - | let | |
1152 | - | let | |
1153 | - | ( | |
1150 | + | let fo = cK(bf, aD, h, bx, dD, by, dE, ax, ay, aw) | |
1151 | + | let fp = fo._1 | |
1152 | + | let dT = fo._2 | |
1153 | + | (cU(aD, toString(ah.caller), fp, dT, fl, aw, bf, false) ++ bs(dD, dE, aw)) | |
1154 | 1154 | } | |
1155 | 1155 | } | |
1156 | 1156 | ||
1157 | 1157 | ||
1158 | 1158 | ||
1159 | 1159 | @Callable(ah) | |
1160 | - | func withdraw (aD, | |
1160 | + | func withdraw (aD,en) = es(toString(ah.caller), aD, toString(en), false) | |
1161 | 1161 | ||
1162 | 1162 | ||
1163 | 1163 | ||
1164 | 1164 | @Callable(ah) | |
1165 | - | func createUpdateStopLoss ( | |
1166 | - | let | |
1165 | + | func createUpdateStopLoss (en,fq,al,fr) = { | |
1166 | + | let fs = ( let at = invoke(aa, "getTWAP60", [al, false], nil) | |
1167 | 1167 | if ($isInstanceOf(at, "(Int, Int)")) | |
1168 | 1168 | then at | |
1169 | 1169 | else throw(($getType(at) + " couldn't be cast to (Int, Int)")))._1 | |
1170 | - | if (!(isDefined(getInteger(this, ((((( | |
1170 | + | if (!(isDefined(getInteger(this, (((((fq + "_") + toString(ah.caller)) + "_") + toString(en)) + u))))) | |
1171 | 1171 | then throw("There are no user position") | |
1172 | - | else if ((0 >= | |
1172 | + | else if ((0 >= fr)) | |
1173 | 1173 | then throw("Price must be greater than 0") | |
1174 | - | else if (( | |
1174 | + | else if ((fr > fs)) | |
1175 | 1175 | then throw("Price must be less than current token price") | |
1176 | - | else [IntegerEntry((((((((toString(ah.caller) + "_") + toString( | |
1176 | + | else [IntegerEntry((((((((toString(ah.caller) + "_") + toString(en)) + "_") + fq) + "_") + al) + Q), fr)] | |
1177 | 1177 | } | |
1178 | 1178 | ||
1179 | 1179 | ||
1180 | 1180 | ||
1181 | 1181 | @Callable(ah) | |
1182 | - | func deleteStopLoss ( | |
1182 | + | func deleteStopLoss (en,fq,al) = if (!(isDefined(getInteger(this, (((((((toString(ah.caller) + "_") + toString(en)) + "_") + fq) + "_") + al) + Q))))) | |
1183 | 1183 | then throw("No entry") | |
1184 | - | else [DeleteEntry((((((((toString(ah.caller) + "_") + toString( | |
1184 | + | else [DeleteEntry((((((((toString(ah.caller) + "_") + toString(en)) + "_") + fq) + "_") + al) + Q))] | |
1185 | 1185 | ||
1186 | 1186 | ||
1187 | 1187 | ||
1188 | 1188 | @Callable(ah) | |
1189 | 1189 | func createNewRequest (bQ) = valueOrElse(ai(ah), { | |
1190 | - | let | |
1191 | - | $Tuple2([StringEntry((toString( | |
1190 | + | let fm = (valueOrElse(getInteger(this, L), 0) + 1) | |
1191 | + | $Tuple2([StringEntry((toString(fm) + K), bQ), IntegerEntry(L, fm)], fm) | |
1192 | 1192 | }) | |
1193 | 1193 | ||
1194 | 1194 | ||
1195 | 1195 | ||
1196 | 1196 | @Callable(ah) | |
1197 | - | func replenishFromLand ( | |
1198 | - | let | |
1199 | - | let aG = | |
1200 | - | let aD = | |
1201 | - | let bx = | |
1202 | - | let | |
1203 | - | let by = | |
1204 | - | let | |
1205 | - | let ax = | |
1206 | - | let ay = | |
1207 | - | let aw = | |
1208 | - | let | |
1209 | - | let | |
1197 | + | func replenishFromLand (ez) = valueOrElse(aj(ah), { | |
1198 | + | let ft = ey(ez) | |
1199 | + | let aG = ft._1 | |
1200 | + | let aD = ft._2 | |
1201 | + | let bx = ft._3 | |
1202 | + | let dD = ft._4 | |
1203 | + | let by = ft._5 | |
1204 | + | let dE = ft._6 | |
1205 | + | let ax = ft._7 | |
1206 | + | let ay = ft._8 | |
1207 | + | let aw = ft._9 | |
1208 | + | let eB = ft._10 | |
1209 | + | let eC = ft._11 | |
1210 | 1210 | if ((size(ah.payments) != 1)) | |
1211 | 1211 | then throw("Wrong payment size") | |
1212 | - | else if (if ((aN(ah.payments[0].assetId) != | |
1212 | + | else if (if ((aN(ah.payments[0].assetId) != eB)) | |
1213 | 1213 | then true | |
1214 | - | else (ah.payments[0].amount != | |
1214 | + | else (ah.payments[0].amount != eC)) | |
1215 | 1215 | then throw("Wrong payment") | |
1216 | 1216 | else { | |
1217 | - | let | |
1217 | + | let fu = if ((dD == eB)) | |
1218 | 1218 | then $Tuple2((bx + ah.payments[0].amount), by) | |
1219 | 1219 | else $Tuple2(bx, (by + ah.payments[0].amount)) | |
1220 | - | let | |
1221 | - | let | |
1220 | + | let fv = fu._1 | |
1221 | + | let fw = fu._2 | |
1222 | 1222 | let bf = valueOrErrorMessage(getString(this, (M + aD)), "Unknown pool") | |
1223 | - | let | |
1224 | - | let | |
1225 | - | let | |
1226 | - | let | |
1227 | - | let | |
1228 | - | let | |
1229 | - | $Tuple2(((( | |
1223 | + | let fx = cK(bf, aD, g, fv, dD, fw, dE, ax, ay, aw) | |
1224 | + | let fp = fx._1 | |
1225 | + | let dT = fx._2 | |
1226 | + | let cW = aF(aG) | |
1227 | + | let fy = [IntegerEntry((((((aD + "_") + aG) + "_") + toString(cW)) + w), eC), StringEntry((((((aD + "_") + aG) + "_") + toString(cW)) + x), eB)] | |
1228 | + | let fz = cU(aD, aG, fp, dT, cW, aw, bf, true) | |
1229 | + | $Tuple2((((fz ++ bs(dD, dE, aw)) ++ fy) :+ DeleteEntry((ez + K))), fp) | |
1230 | 1230 | } | |
1231 | 1231 | }) | |
1232 | 1232 | ||
1233 | 1233 | ||
1234 | 1234 | ||
1235 | 1235 | @Callable(ah) | |
1236 | - | func liquidate (aG, | |
1237 | - | let aD = valueOrErrorMessage(getString(this, (((aG + "_") + | |
1236 | + | func liquidate (aG,en,fA) = valueOrElse(aj(ah), { | |
1237 | + | let aD = valueOrErrorMessage(getString(this, (((aG + "_") + en) + v)), "no position") | |
1238 | 1238 | let bf = valueOrErrorMessage(getString(this, (M + aD)), "Pool is not inited") | |
1239 | - | let | |
1240 | - | let | |
1241 | - | let | |
1242 | - | let ax = | |
1243 | - | let ay = | |
1244 | - | let aw = | |
1245 | - | let bL = bM(aD, bf, aw, | |
1246 | - | let | |
1247 | - | let | |
1248 | - | let | |
1249 | - | if (( | |
1239 | + | let fB = az(Address(fromBase58String(aD)), bf) | |
1240 | + | let dD = fB._1 | |
1241 | + | let dE = fB._2 | |
1242 | + | let ax = fB._3 | |
1243 | + | let ay = fB._4 | |
1244 | + | let aw = fB._5 | |
1245 | + | let bL = bM(aD, bf, aw, fA) | |
1246 | + | let cz = getIntegerValue(this, (((((aD + "_") + aG) + "_") + en) + w)) | |
1247 | + | let dX = getStringValue(this, (((((aD + "_") + aG) + "_") + en) + x)) | |
1248 | + | let dV = em(aG, aD, en, (cz > 0)) | |
1249 | + | if ((cz == 0)) | |
1250 | 1250 | then throw("You can't liquidate position without borrow") | |
1251 | - | else [IntegerEntry((((((aD + "_") + aG) + "_") + | |
1251 | + | else [IntegerEntry((((((aD + "_") + aG) + "_") + en) + z), getIntegerValue(this, (aD + C))), IntegerEntry((aD + B), (aE(aD) - fA)), IntegerEntry((aD + A), (aC(aD) - fA)), IntegerEntry((((((aD + "_") + aG) + "_") + en) + u), (dV - fA)), ScriptTransfer(ah.caller, bL, fromBase58String(aw))] | |
1252 | 1252 | }) | |
1253 | 1253 | ||
1254 | 1254 | ||
1255 | 1255 | ||
1256 | 1256 | @Callable(ah) | |
1257 | - | func stopLoss (aG, | |
1258 | - | let | |
1257 | + | func stopLoss (aG,en,aD,al) = valueOrElse(ag(ah), { | |
1258 | + | let fs = ( let at = invoke(aa, "getTWAP60", [al, false], nil) | |
1259 | 1259 | if ($isInstanceOf(at, "(Int, Int)")) | |
1260 | 1260 | then at | |
1261 | 1261 | else throw(($getType(at) + " couldn't be cast to (Int, Int)")))._1 | |
1262 | - | if (!(isDefined(getInteger(this, (((((((aG + "_") + toString( | |
1262 | + | if (!(isDefined(getInteger(this, (((((((aG + "_") + toString(en)) + "_") + aD) + "_") + al) + Q))))) | |
1263 | 1263 | then throw("No entry") | |
1264 | - | else ( | |
1264 | + | else (es(toString(ah.caller), aD, toString(en), true) :+ DeleteEntry((((((((aG + "_") + toString(en)) + "_") + aD) + "_") + al) + Q))) | |
1265 | 1265 | }) | |
1266 | 1266 | ||
1267 | 1267 | ||
1268 | 1268 | ||
1269 | 1269 | @Callable(ah) | |
1270 | - | func capitalizeExKeeper (aD,aA, | |
1271 | - | let | |
1272 | - | then | |
1270 | + | func capitalizeExKeeper (aD,aA,fC,fD,fE,dh,di,dj,dk,dl,dm,dn) = valueOrElse(ag(ah), { | |
1271 | + | let fF = if (fE) | |
1272 | + | then cH(aA, aD) | |
1273 | 1273 | else { | |
1274 | - | let | |
1274 | + | let fG = if ((aA == a)) | |
1275 | 1275 | then ac | |
1276 | 1276 | else ad | |
1277 | - | $Tuple2( | |
1277 | + | $Tuple2(fD, fG) | |
1278 | 1278 | } | |
1279 | - | let | |
1280 | - | let | |
1281 | - | let | |
1282 | - | let | |
1283 | - | let | |
1284 | - | then [IntegerEntry((aD + O), ( | |
1279 | + | let fH = fF._1 | |
1280 | + | let fG = fF._2 | |
1281 | + | let fI = dd(fC, fD, fG, dh, di, dj, dk, dl, dm, dn) | |
1282 | + | let cr = (fH - fD) | |
1283 | + | let fJ = if ((cr > 0)) | |
1284 | + | then [IntegerEntry((aD + O), (cr + valueOrElse(getInteger(this, (aD + O)), 0)))] | |
1285 | 1285 | else nil | |
1286 | - | ( | |
1286 | + | (dz(aD, aA, fC, fI) ++ fJ) | |
1287 | 1287 | }) | |
1288 | 1288 | ||
1289 | 1289 | ||
1290 | 1290 | ||
1291 | 1291 | @Callable(ah) | |
1292 | - | func capitalizeExPuzzle (aD,aA, | |
1293 | - | let | |
1294 | - | then | |
1292 | + | func capitalizeExPuzzle (aD,aA,fC,fD,fE,dq,dr,dn) = valueOrElse(ag(ah), { | |
1293 | + | let fK = if (fE) | |
1294 | + | then cH(aA, aD) | |
1295 | 1295 | else { | |
1296 | - | let | |
1296 | + | let fG = if ((aA == a)) | |
1297 | 1297 | then ac | |
1298 | 1298 | else ad | |
1299 | - | $Tuple2( | |
1299 | + | $Tuple2(fD, fG) | |
1300 | 1300 | } | |
1301 | - | let | |
1302 | - | let | |
1303 | - | let | |
1304 | - | let | |
1305 | - | let | |
1306 | - | then [IntegerEntry((aD + O), ( | |
1301 | + | let fH = fK._1 | |
1302 | + | let fG = fK._2 | |
1303 | + | let fI = dp(fC, fD, fG, dq, dr, dn) | |
1304 | + | let cr = (fH - fD) | |
1305 | + | let fJ = if ((cr > 0)) | |
1306 | + | then [IntegerEntry((aD + O), (cr + valueOrElse(getInteger(this, (aD + O)), 0)))] | |
1307 | 1307 | else nil | |
1308 | - | ( | |
1308 | + | (dz(aD, aA, fC, fI) ++ fJ) | |
1309 | 1309 | }) | |
1310 | 1310 | ||
1311 | 1311 | ||
1312 | 1312 | ||
1313 | 1313 | @Callable(ah) | |
1314 | - | func capitalizeExSwopFi (aD,aA, | |
1315 | - | let | |
1316 | - | then | |
1314 | + | func capitalizeExSwopFi (aD,aA,fC,fD,fE,dt,du,dv,dw,dx,dy,dn) = valueOrElse(ag(ah), { | |
1315 | + | let fL = if (fE) | |
1316 | + | then cH(aA, aD) | |
1317 | 1317 | else { | |
1318 | - | let | |
1318 | + | let fG = if ((aA == a)) | |
1319 | 1319 | then ac | |
1320 | 1320 | else ad | |
1321 | - | $Tuple2( | |
1321 | + | $Tuple2(fD, fG) | |
1322 | 1322 | } | |
1323 | - | let | |
1324 | - | let | |
1325 | - | let | |
1326 | - | let | |
1327 | - | let | |
1328 | - | then [IntegerEntry((aD + O), ( | |
1323 | + | let fH = fL._1 | |
1324 | + | let fG = fL._2 | |
1325 | + | let fI = ds(fC, fD, fG, dt, du, dv, dw, dx, dy, dn) | |
1326 | + | let cr = (fH - fD) | |
1327 | + | let fJ = if ((cr > 0)) | |
1328 | + | then [IntegerEntry((aD + O), (cr + valueOrElse(getInteger(this, (aD + O)), 0)))] | |
1329 | 1329 | else nil | |
1330 | - | ( | |
1330 | + | (dz(aD, aA, fC, fI) ++ fJ) | |
1331 | 1331 | }) | |
1332 | 1332 | ||
1333 | 1333 | ||
1334 | 1334 | ||
1335 | 1335 | @Callable(ah) | |
1336 | - | func initNewPool (aA,aq | |
1336 | + | func initNewPool (aA,aq,fM,fN,fO,fP,fQ,fR) = valueOrElse(ag(ah), if (if ((aA != a)) | |
1337 | 1337 | then (aA != b) | |
1338 | 1338 | else false) | |
1339 | 1339 | then throw("Wrong type") | |
1340 | 1340 | else { | |
1341 | - | let | |
1342 | - | let au = | |
1343 | - | let av = | |
1344 | - | let | |
1345 | - | let | |
1346 | - | let aw = | |
1347 | - | [IntegerEntry((aq + E), | |
1341 | + | let fS = az(Address(fromBase58String(aq)), aA) | |
1342 | + | let au = fS._1 | |
1343 | + | let av = fS._2 | |
1344 | + | let fT = fS._3 | |
1345 | + | let fU = fS._4 | |
1346 | + | let aw = fS._5 | |
1347 | + | [IntegerEntry((aq + E), fM), IntegerEntry((aq + F), fN), IntegerEntry((aq + G), fO), IntegerEntry((aq + H), fP), IntegerEntry((aq + I), fQ), IntegerEntry((aq + J), fR), IntegerEntry((aq + C), 0), IntegerEntry((aq + D), 0), StringEntry((M + aq), aA), StringEntry((aw + N), aq)] | |
1348 | 1348 | }) | |
1349 | 1349 | ||
1350 | 1350 | ||
1351 | - | @Verifier( | |
1352 | - | func | |
1351 | + | @Verifier(fV) | |
1352 | + | func fW () = sigVerify(fV.bodyBytes, fV.proofs[0], fV.senderPublicKey) | |
1353 | 1353 |
github/deemru/w8io/026f985 354.55 ms ◑