tx · AxEfEyEs8YwBVVDzHc6ehgNVkhK9mTwTX7Zx7cLsYXDg 3MpygN8qm376tUAHB6mhC5BxG5NKYortiyX: -0.14000000 Waves 2022.12.05 18:12 [2347216] smart account 3MpygN8qm376tUAHB6mhC5BxG5NKYortiyX > SELF 0.00000000 Waves
{ "type": 13, "id": "AxEfEyEs8YwBVVDzHc6ehgNVkhK9mTwTX7Zx7cLsYXDg", "fee": 14000000, "feeAssetId": null, "timestamp": 1670253140071, "version": 2, "chainId": 84, "sender": "3MpygN8qm376tUAHB6mhC5BxG5NKYortiyX", "senderPublicKey": "BjnLnkAMaJLYAK36vQqSepUNjGeMDHfZGfmdYwGcLbmg", "proofs": [ "3ZtjwQTEQWD9SRgbmtTV753xndgCHtwQsGzuCuZD44246BBDketvJqoShrByTQ4RjkSdkAsGahF9z1CB86vDLYaT", "25ENpETff7LF2Yp8UW2SzBvAtq5QFtQ3Fi7rMMzuK2EvuHU7wJqdpKXQhnr3DJfiVaN5hzxJXHEX8UEKRELVvvR2" ], "script": "base64:BgJJCAISAwoBBBIECgIEARIGCgQBAQQBEgMKAQESBgoEAQgBARIECgIBARIDCgEBEgASABIAEgMKAQESBQoDBAEIEgASBAoCAQESAGsAB3ZlcnNpb24CBTIuMC4wAAhrVmVyc2lvbgIHdmVyc2lvbgAHa0FjdGl2ZQIGYWN0aXZlAAtrQWN0aXZlR2xvYgIUYWN0aXZlX2FsbF9jb250cmFjdHMACWtBc3NldElkQQIKQV9hc3NldF9pZAAJa0Fzc2V0SWRCAgpCX2Fzc2V0X2lkAAlrQmFsYW5jZUECD0FfYXNzZXRfYmFsYW5jZQAJa0JhbGFuY2VCAg9CX2Fzc2V0X2JhbGFuY2UADWtTaGFyZUFzc2V0SWQCDnNoYXJlX2Fzc2V0X2lkABFrU2hhcmVBc3NldFN1cHBseQISc2hhcmVfYXNzZXRfc3VwcGx5AARrRmVlAgpjb21taXNzaW9uAAprSW52YXJpYW50AglpbnZhcmlhbnQABmtDYXVzZQIOc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aDAEE2NhbGxUYWtlSW50b0FjY291bnQDCQAAAggFA2ludgRkQXBwBQR0aGlzCQAAAggFA2ludghmdW5jdGlvbgIZdGFrZUludG9BY2NvdW50RXh0cmFGdW5kcwcEDXNpZ25lZEJ5QWRtaW4DAwMJAPQDAwgFAnR4CWJvZHlCeXRlcwkAkQMCCAUCdHgGcHJvb2ZzAAAFDGFkbWluUHViS2V5MQYJAPQDAwgFAnR4CWJvZHlCeXRlcwkAkQMCCAUCdHgGcHJvb2ZzAAAFDGFkbWluUHViS2V5MgYJAPQDAwgFAnR4CWJvZHlCeXRlcwkAkQMCCAUCdHgGcHJvb2ZzAAAFDGFkbWluUHViS2V5MwYJAPQDAwgFAnR4CWJvZHlCeXRlcwkAkQMCCAUCdHgGcHJvb2ZzAAAFEWFkbWluUHViS2V5SW52b2tlAwMFE2NhbGxUYWtlSW50b0FjY291bnQFDXNpZ25lZEJ5QWRtaW4HBgUTbXVsdGlTaWduZWRCeUFkbWlucwUTbXVsdGlTaWduZWRCeUFkbWlucyVbCH4=", "height": 2347216, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: CPJBNgiqCoi4X64H6kPiZV8k5jRgYMuRPHtNh9CMpnJ4 Next: EKSesAnP68WHkuQ7YVvgEicae27p2jtHiVbgJ3s3rZkg Diff:
Old | New | Differences | |
---|---|---|---|
381 | 381 | ||
382 | 382 | func calculateFeeDiscount (userAddr) = { | |
383 | 383 | let swopAmount = valueOrElse(getInteger(govAddress, (toString(userAddr) + kUserSwopInGov)), 0) | |
384 | - | let gSwopAmount = valueOrElse(getInteger(govAddress, (toString(userAddr) + kUserGSwopInGov)), | |
384 | + | let gSwopAmount = valueOrElse(getInteger(govAddress, (toString(userAddr) + kUserGSwopInGov)), swopAmount) | |
385 | 385 | let discountValues = split(getStringValue(oracle, kDiscountValues), ",") | |
386 | 386 | let discounts = split(getStringValue(oracle, kDiscounts), ",") | |
387 | 387 | if (if ((gSwopAmount >= parseIntValue(discountValues[0]))) | |
411 | 411 | let pmtAssetIdB = i.payments[1].assetId | |
412 | 412 | let ratioShareTokensInA = fraction(scale8, i.payments[0].amount, balanceA) | |
413 | 413 | let ratioShareTokensInB = fraction(scale8, i.payments[1].amount, balanceB) | |
414 | - | let $ | |
415 | - | let pmtStrAssetIdA = $ | |
416 | - | let pmtAssetNameA = $ | |
417 | - | let pmtDecimalsA = $ | |
418 | - | let $ | |
419 | - | let pmtStrAssetIdB = $ | |
420 | - | let pmtAssetNameB = $ | |
421 | - | let pmtDecimalsB = $ | |
422 | - | let $ | |
414 | + | let $t01231312390 = getAssetInfo(pmtAssetIdA) | |
415 | + | let pmtStrAssetIdA = $t01231312390._1 | |
416 | + | let pmtAssetNameA = $t01231312390._2 | |
417 | + | let pmtDecimalsA = $t01231312390._3 | |
418 | + | let $t01239512512 = getAssetInfo(pmtAssetIdB) | |
419 | + | let pmtStrAssetIdB = $t01239512512._1 | |
420 | + | let pmtAssetNameB = $t01239512512._2 | |
421 | + | let pmtDecimalsB = $t01239512512._3 | |
422 | + | let $t01251713021 = if ((ratioShareTokensInB > ratioShareTokensInA)) | |
423 | 423 | then { | |
424 | 424 | let pmt = fraction(balanceB, ratioShareTokensInA, scale8, CEILING) | |
425 | 425 | $Tuple5(i.payments[0].amount, pmt, (i.payments[1].amount - pmt), pmtAssetIdB, ratioShareTokensInA) | |
428 | 428 | let pmt = fraction(balanceA, ratioShareTokensInB, scale8, CEILING) | |
429 | 429 | $Tuple5(pmt, i.payments[1].amount, (i.payments[0].amount - pmt), pmtAssetIdA, ratioShareTokensInB) | |
430 | 430 | } | |
431 | - | let pmtAmountA = $ | |
432 | - | let pmtAmountB = $ | |
433 | - | let change = $ | |
434 | - | let changeAssetId = $ | |
435 | - | let shareTokenRatio = $ | |
431 | + | let pmtAmountA = $t01251713021._1 | |
432 | + | let pmtAmountB = $t01251713021._2 | |
433 | + | let change = $t01251713021._3 | |
434 | + | let changeAssetId = $t01251713021._4 | |
435 | + | let shareTokenRatio = $t01251713021._5 | |
436 | 436 | let shareTokenToPayAmount = fraction(shareTokenRatio, shareAssetSupply, scale8) | |
437 | 437 | if (if ((size(i.payments) != 2)) | |
438 | 438 | then (size(i.payments) != 3) | |
487 | 487 | ||
488 | 488 | ||
489 | 489 | func replenishWithOneTokenCalc (i,virtualSwapTokenPay,virtualSwapTokenGet,stakeFarming,lockType) = { | |
490 | - | let $ | |
491 | - | let pmtAmount = $ | |
492 | - | let pmtAssetId = $ | |
493 | - | let $ | |
494 | - | let pmtStrAssetId = $ | |
495 | - | let pmtAssetName = $ | |
496 | - | let pmtDecimals = $ | |
490 | + | let $t01541115486 = $Tuple2(i.payments[0].amount, i.payments[0].assetId) | |
491 | + | let pmtAmount = $t01541115486._1 | |
492 | + | let pmtAssetId = $t01541115486._2 | |
493 | + | let $t01549115564 = getAssetInfo(pmtAssetId) | |
494 | + | let pmtStrAssetId = $t01549115564._1 | |
495 | + | let pmtAssetName = $t01549115564._2 | |
496 | + | let pmtDecimals = $t01549115564._3 | |
497 | 497 | let pmtMinThreshold = 5000000 | |
498 | 498 | let thresholdValueForMinTolerance = 50000000 | |
499 | 499 | let tolerance = if ((thresholdValueForMinTolerance > pmtAmount)) | |
515 | 515 | else false) | |
516 | 516 | then throwAssets() | |
517 | 517 | else { | |
518 | - | let $ | |
518 | + | let $t01657117213 = if ((pmtAssetId == assetIdA)) | |
519 | 519 | then $Tuple6((pmtAmount - virtualSwapTokenPay), virtualSwapTokenGet, (balanceA + virtualSwapTokenPay), (balanceB - virtualSwapTokenGet), (balanceA + pmtAmount), balanceB) | |
520 | 520 | else $Tuple6(virtualSwapTokenGet, (pmtAmount - virtualSwapTokenPay), (balanceA - virtualSwapTokenGet), (balanceB + virtualSwapTokenPay), balanceA, (balanceB + pmtAmount)) | |
521 | - | let virtualReplenishA = $ | |
522 | - | let virtualReplenishB = $ | |
523 | - | let balanceAfterSwapA = $ | |
524 | - | let balanceAfterSwapB = $ | |
525 | - | let newBalanceA = $ | |
526 | - | let newBalanceB = $ | |
521 | + | let virtualReplenishA = $t01657117213._1 | |
522 | + | let virtualReplenishB = $t01657117213._2 | |
523 | + | let balanceAfterSwapA = $t01657117213._3 | |
524 | + | let balanceAfterSwapB = $t01657117213._4 | |
525 | + | let newBalanceA = $t01657117213._5 | |
526 | + | let newBalanceB = $t01657117213._6 | |
527 | 527 | let invariantNew = invariantCalc(balanceAfterSwapA, balanceAfterSwapB) | |
528 | 528 | let ratioVirtualBalanceToVirtualReplenish = (fraction(scale16, balanceAfterSwapA, balanceAfterSwapB) / fraction(scale8, virtualReplenishA, virtualReplenishB)) | |
529 | 529 | let dAppThresholdAmount = fraction((newBalanceA + newBalanceB), dAppThreshold, (2 * dAppThresholdScale2)) | |
547 | 547 | let shareTokenGovernanceReward = fraction(shareTokenToPayAmount, (feeGovernance / 2), feeScale6) | |
548 | 548 | let governanceRewardTokenA = fraction(shareTokenGovernanceReward, balanceA, shareAssetSupply) | |
549 | 549 | let governanceRewardTokenB = fraction(shareTokenGovernanceReward, balanceB, shareAssetSupply) | |
550 | - | let $ | |
550 | + | let $t01920319498 = if ((pmtStrAssetId == strAssetIdA)) | |
551 | 551 | then $Tuple3((pmtAmount - governanceRewardTokenA), governanceRewardTokenB, strAssetIdB) | |
552 | 552 | else $Tuple3((pmtAmount - governanceRewardTokenB), governanceRewardTokenA, strAssetIdA) | |
553 | - | let stakeAmount = $ | |
554 | - | let unstakeAmount = $ | |
555 | - | let unstakeAsset = $ | |
553 | + | let stakeAmount = $t01920319498._1 | |
554 | + | let unstakeAmount = $t01920319498._2 | |
555 | + | let unstakeAsset = $t01920319498._3 | |
556 | 556 | let stake1 = if (contains(stakingAssets, pmtStrAssetId)) | |
557 | 557 | then invoke(this, "stakeUnstake", [true, stakeAmount, pmtStrAssetId], nil) | |
558 | 558 | else 0 | |
592 | 592 | ||
593 | 593 | ||
594 | 594 | func withdrawCalc (i,unlockAmount) = { | |
595 | - | let $ | |
595 | + | let $t02148521820 = if ((size(i.payments) == 1)) | |
596 | 596 | then if ((i.payments[0].assetId != shareAssetId)) | |
597 | 597 | then throw(("Incorrect asset attached. Expected: " + toBase58String(shareAssetId))) | |
598 | 598 | else $Tuple2(i.payments[0].amount, i.payments[0].assetId) | |
599 | 599 | else $Tuple2(0, shareAssetId) | |
600 | - | let pmtAmount = $ | |
601 | - | let pmtAssetId = $ | |
600 | + | let pmtAmount = $t02148521820._1 | |
601 | + | let pmtAssetId = $t02148521820._2 | |
602 | 602 | if (!(hasEnoughBalance)) | |
603 | 603 | then ([ScriptTransfer(i.caller, pmtAmount, pmtAssetId)] ++ suspendSuspicious()) | |
604 | 604 | else { | |
632 | 632 | ||
633 | 633 | @Callable(i) | |
634 | 634 | func init (firstHarvest) = { | |
635 | - | let $ | |
636 | - | let pmtAmountA = $ | |
637 | - | let pmtAssetIdA = $ | |
638 | - | let $ | |
639 | - | let pmtAmountB = $ | |
640 | - | let pmtAssetIdB = $ | |
641 | - | let $ | |
642 | - | let pmtStrAssetIdA = $ | |
643 | - | let pmtAssetNameA = $ | |
644 | - | let pmtDecimalsA = $ | |
645 | - | let $ | |
646 | - | let pmtStrAssetIdB = $ | |
647 | - | let pmtAssetNameB = $ | |
648 | - | let pmtDecimalsB = $ | |
635 | + | let $t02337223449 = $Tuple2(i.payments[0].amount, i.payments[0].assetId) | |
636 | + | let pmtAmountA = $t02337223449._1 | |
637 | + | let pmtAssetIdA = $t02337223449._2 | |
638 | + | let $t02345423531 = $Tuple2(i.payments[1].amount, i.payments[1].assetId) | |
639 | + | let pmtAmountB = $t02345423531._1 | |
640 | + | let pmtAssetIdB = $t02345423531._2 | |
641 | + | let $t02353623613 = getAssetInfo(pmtAssetIdA) | |
642 | + | let pmtStrAssetIdA = $t02353623613._1 | |
643 | + | let pmtAssetNameA = $t02353623613._2 | |
644 | + | let pmtDecimalsA = $t02353623613._3 | |
645 | + | let $t02361823695 = getAssetInfo(pmtAssetIdB) | |
646 | + | let pmtStrAssetIdB = $t02361823695._1 | |
647 | + | let pmtAssetNameB = $t02361823695._2 | |
648 | + | let pmtDecimalsB = $t02361823695._3 | |
649 | 649 | if (isDefined(getBoolean(this, kActive))) | |
650 | 650 | then throwIsActive() | |
651 | 651 | else if ((pmtAssetIdA == pmtAssetIdB)) | |
698 | 698 | ||
699 | 699 | @Callable(i) | |
700 | 700 | func withdrawOneToken (unlockAmount,withdrawAsset,estimatedAmountToReceive,minAmountToReceive) = valueOrElse(isActive(), { | |
701 | - | let $ | |
701 | + | let $t02706527400 = if ((size(i.payments) == 1)) | |
702 | 702 | then if ((i.payments[0].assetId != shareAssetId)) | |
703 | 703 | then throw(("Incorrect asset attached. Expected: " + toBase58String(shareAssetId))) | |
704 | 704 | else $Tuple2(i.payments[0].amount, i.payments[0].assetId) | |
705 | 705 | else $Tuple2(0, shareAssetId) | |
706 | - | let pmtAmount = $ | |
707 | - | let pmtAssetId = $ | |
706 | + | let pmtAmount = $t02706527400._1 | |
707 | + | let pmtAssetId = $t02706527400._2 | |
708 | 708 | let withdrawAmount = (pmtAmount + unlockAmount) | |
709 | 709 | if (if ((withdrawAsset != strAssetIdA)) | |
710 | 710 | then (withdrawAsset != strAssetIdB) | |
730 | 730 | else calculateSendAmount(estimatedAmountToReceive, minAmountToReceive, amountToPayA, assetIdA, newVirtBalcA, newVirtBalcB, invariantCalc(newVirtBalcA, newVirtBalcB)) | |
731 | 731 | let govReward = fraction(amountExchangedWithFee, fraction(feeGovernance, feeDiscount, feeScale6, CEILING), feeScale6) | |
732 | 732 | let amountExchanged = fraction(amountExchangedWithFee, (feeScale6 - fraction(fee, feeDiscount, feeScale6, CEILING)), feeScale6) | |
733 | - | let $ | |
733 | + | let $t02900329332 = if ((withdrawAsset == strAssetIdA)) | |
734 | 734 | then $Tuple3((amountToPayA + amountExchanged), (((balanceA - amountToPayA) - amountExchanged) - govReward), balanceB) | |
735 | 735 | else $Tuple3((amountToPayB + amountExchanged), balanceA, (((balanceB - amountToPayB) - amountExchanged) - govReward)) | |
736 | - | let amountToPay = $ | |
737 | - | let balanceANew = $ | |
738 | - | let balanceBNew = $ | |
736 | + | let amountToPay = $t02900329332._1 | |
737 | + | let balanceANew = $t02900329332._2 | |
738 | + | let balanceBNew = $t02900329332._3 | |
739 | 739 | let invariantCalculated = invariantCalc(balanceANew, balanceBNew) | |
740 | 740 | let stake1 = if (contains(stakingAssets, withdrawAsset)) | |
741 | 741 | then invoke(this, "stakeUnstake", [false, (amountToPay + govReward), withdrawAsset], nil) | |
752 | 752 | ||
753 | 753 | @Callable(i) | |
754 | 754 | func exchange (estimatedAmountToReceive,minAmountToReceive) = valueOrElse(isActive(), { | |
755 | - | let $ | |
756 | - | let pmtAmount = $ | |
757 | - | let pmtAssetId = $ | |
755 | + | let $t03020530280 = $Tuple2(i.payments[0].amount, i.payments[0].assetId) | |
756 | + | let pmtAmount = $t03020530280._1 | |
757 | + | let pmtAssetId = $t03020530280._2 | |
758 | 758 | if ((0 >= estimatedAmountToReceive)) | |
759 | 759 | then throw(("Estimated amount must be positive. Actual: " + toString(estimatedAmountToReceive))) | |
760 | 760 | else if ((minAmountToReceive > estimatedAmountToReceive)) | |
781 | 781 | let feeDiscount = calculateFeeDiscount(i.originCaller) | |
782 | 782 | let governanceReward = fraction(amount, fraction(feeGovernance, feeDiscount, feeScale6, CEILING), feeScale6) | |
783 | 783 | let amountMinusFee = fraction(amount, (feeScale6 - fraction(fee, feeDiscount, feeScale6, CEILING)), feeScale6) | |
784 | - | let $ | |
784 | + | let $t03176432026 = if ((pmtAssetId == assetIdA)) | |
785 | 785 | then $Tuple2((balanceA + pmtAmount), ((balanceB - amountMinusFee) - governanceReward)) | |
786 | 786 | else $Tuple2(((balanceA - amountMinusFee) - governanceReward), (balanceB + pmtAmount)) | |
787 | - | let newBalanceA = $ | |
788 | - | let newBalanceB = $ | |
787 | + | let newBalanceA = $t03176432026._1 | |
788 | + | let newBalanceB = $t03176432026._2 | |
789 | 789 | let dAppThresholdAmount = fraction((newBalanceA + newBalanceB), dAppThreshold, (2 * dAppThresholdScale2)) | |
790 | 790 | if (if ((dAppThresholdAmount > newBalanceA)) | |
791 | 791 | then true | |
792 | 792 | else (dAppThresholdAmount > newBalanceB)) | |
793 | 793 | then throwThreshold(dAppThresholdAmount, newBalanceA, newBalanceB) | |
794 | 794 | else { | |
795 | - | let $ | |
796 | - | let pmtStrAssetId = $ | |
797 | - | let pmtAssetName = $ | |
798 | - | let pmtDecimals = $ | |
799 | - | let $ | |
800 | - | let sendStrAssetId = $ | |
801 | - | let sendAssetName = $ | |
802 | - | let sendDecimals = $ | |
795 | + | let $t03232532398 = getAssetInfo(pmtAssetId) | |
796 | + | let pmtStrAssetId = $t03232532398._1 | |
797 | + | let pmtAssetName = $t03232532398._2 | |
798 | + | let pmtDecimals = $t03232532398._3 | |
799 | + | let $t03241132488 = getAssetInfo(sendAssetId) | |
800 | + | let sendStrAssetId = $t03241132488._1 | |
801 | + | let sendAssetName = $t03241132488._2 | |
802 | + | let sendDecimals = $t03241132488._3 | |
803 | 803 | let stake1 = if (contains(stakingAssets, pmtStrAssetId)) | |
804 | 804 | then invoke(this, "stakeUnstake", [true, pmtAmount, pmtStrAssetId], nil) | |
805 | 805 | else 0 | |
885 | 885 | func stakeUnstake (stake,amount,assetIdString) = if ((i.caller != this)) | |
886 | 886 | then throw("Only contract itself can invoke this function") | |
887 | 887 | else { | |
888 | - | let $ | |
889 | - | let call = $ | |
890 | - | let addr = $ | |
891 | - | let params = $ | |
892 | - | let payments = $ | |
888 | + | let $t03579035893 = calcStakingParams(stake, amount, fromBase58String(assetIdString)) | |
889 | + | let call = $t03579035893._1 | |
890 | + | let addr = $t03579035893._2 | |
891 | + | let params = $t03579035893._3 | |
892 | + | let payments = $t03579035893._4 | |
893 | 893 | let inv = invoke(addr, call, params, payments) | |
894 | 894 | if ((inv == inv)) | |
895 | 895 | then nil |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let version = "2.0.0" | |
5 | 5 | ||
6 | 6 | let kVersion = "version" | |
7 | 7 | ||
8 | 8 | let kActive = "active" | |
9 | 9 | ||
10 | 10 | let kActiveGlob = "active_all_contracts" | |
11 | 11 | ||
12 | 12 | let kAssetIdA = "A_asset_id" | |
13 | 13 | ||
14 | 14 | let kAssetIdB = "B_asset_id" | |
15 | 15 | ||
16 | 16 | let kBalanceA = "A_asset_balance" | |
17 | 17 | ||
18 | 18 | let kBalanceB = "B_asset_balance" | |
19 | 19 | ||
20 | 20 | let kShareAssetId = "share_asset_id" | |
21 | 21 | ||
22 | 22 | let kShareAssetSupply = "share_asset_supply" | |
23 | 23 | ||
24 | 24 | let kFee = "commission" | |
25 | 25 | ||
26 | 26 | let kInvariant = "invariant" | |
27 | 27 | ||
28 | 28 | let kCause = "shutdown_cause" | |
29 | 29 | ||
30 | 30 | let kUSDNAddress = "staking_usdnnsbt_address" | |
31 | 31 | ||
32 | 32 | let kEURNAddress = "staking_eurn_address" | |
33 | 33 | ||
34 | 34 | let kDiscounts = "discounts" | |
35 | 35 | ||
36 | 36 | let kDiscountValues = "discount_values" | |
37 | 37 | ||
38 | 38 | let kUserSwopInGov = "_SWOP_amount" | |
39 | 39 | ||
40 | 40 | let kUserGSwopInGov = "_GSwop_amount" | |
41 | 41 | ||
42 | 42 | let kFirstHarvest = "first_harvest" | |
43 | 43 | ||
44 | 44 | let kFirstHarvestHeight = "first_harvest_height" | |
45 | 45 | ||
46 | 46 | let kShareLimit = "share_limit_on_first_harvest" | |
47 | 47 | ||
48 | 48 | let kBasePeriod = "base_period" | |
49 | 49 | ||
50 | 50 | let kPeriodLength = "period_length" | |
51 | 51 | ||
52 | 52 | let kStartHeight = "start_height" | |
53 | 53 | ||
54 | 54 | let kAdminPubKey1 = "admin_pub_1" | |
55 | 55 | ||
56 | 56 | let kAdminPubKey2 = "admin_pub_2" | |
57 | 57 | ||
58 | 58 | let kAdminPubKey3 = "admin_pub_3" | |
59 | 59 | ||
60 | 60 | let kAdminInvokePubKey = "admin_invoke_pub" | |
61 | 61 | ||
62 | 62 | let kMoneyBoxAddress = "money_box_address" | |
63 | 63 | ||
64 | 64 | let kGovAddress = "governance_address" | |
65 | 65 | ||
66 | 66 | let kFarmingAddress = "farming_address" | |
67 | 67 | ||
68 | 68 | let kVotingAddress = "voting_address" | |
69 | 69 | ||
70 | 70 | let kUSDNAssetId = "usdn_asset_id" | |
71 | 71 | ||
72 | 72 | let kStakingAssets = "staking_assets" | |
73 | 73 | ||
74 | 74 | let oracle = Address(base58'3MvVBtsXroQpy1tsPw21TU2ET9A8WfmrNjz') | |
75 | 75 | ||
76 | 76 | func getBase58FromOracle (key) = match getString(oracle, key) { | |
77 | 77 | case string: String => | |
78 | 78 | fromBase58String(string) | |
79 | 79 | case nothing => | |
80 | 80 | throw((key + "is empty")) | |
81 | 81 | } | |
82 | 82 | ||
83 | 83 | ||
84 | 84 | let adminPubKey1 = getBase58FromOracle(kAdminPubKey1) | |
85 | 85 | ||
86 | 86 | let adminPubKey2 = getBase58FromOracle(kAdminPubKey2) | |
87 | 87 | ||
88 | 88 | let adminPubKey3 = getBase58FromOracle(kAdminPubKey3) | |
89 | 89 | ||
90 | 90 | let adminPubKeyInvoke = getBase58FromOracle(kAdminInvokePubKey) | |
91 | 91 | ||
92 | 92 | let moneyBoxAddress = Address(getBase58FromOracle(kMoneyBoxAddress)) | |
93 | 93 | ||
94 | 94 | let govAddress = Address(getBase58FromOracle(kGovAddress)) | |
95 | 95 | ||
96 | 96 | let stakingUSDNAddress = Address(getBase58FromOracle(kUSDNAddress)) | |
97 | 97 | ||
98 | 98 | let votingAddress = Address(getBase58FromOracle(kVotingAddress)) | |
99 | 99 | ||
100 | 100 | let farmingAddress = Address(getBase58FromOracle(kFarmingAddress)) | |
101 | 101 | ||
102 | 102 | let USDN = getBase58FromOracle(kUSDNAssetId) | |
103 | 103 | ||
104 | 104 | let stakingAssets = getStringValue(oracle, kStakingAssets) | |
105 | 105 | ||
106 | 106 | let basePeriod = valueOrErrorMessage(getInteger(votingAddress, kBasePeriod), "Empty kBasePeriod") | |
107 | 107 | ||
108 | 108 | let startHeight = valueOrErrorMessage(getInteger(votingAddress, kStartHeight), "Empty kStartHeight") | |
109 | 109 | ||
110 | 110 | let periodLength = valueOrErrorMessage(getInteger(votingAddress, kPeriodLength), "Empty kPeriodLength") | |
111 | 111 | ||
112 | 112 | let firstHarvestEndPeriod = ((basePeriod + ((height - startHeight) / periodLength)) + 3) | |
113 | 113 | ||
114 | 114 | let active = getBooleanValue(this, kActive) | |
115 | 115 | ||
116 | 116 | let activeGlob = valueOrElse(getBoolean(oracle, kActiveGlob), true) | |
117 | 117 | ||
118 | 118 | let strAssetIdA = getStringValue(this, kAssetIdA) | |
119 | 119 | ||
120 | 120 | let strAssetIdB = getStringValue(this, kAssetIdB) | |
121 | 121 | ||
122 | 122 | let assetIdA = if ((strAssetIdA == "WAVES")) | |
123 | 123 | then unit | |
124 | 124 | else fromBase58String(strAssetIdA) | |
125 | 125 | ||
126 | 126 | let assetIdB = if ((strAssetIdB == "WAVES")) | |
127 | 127 | then unit | |
128 | 128 | else fromBase58String(strAssetIdB) | |
129 | 129 | ||
130 | 130 | let assetNameA = match assetIdA { | |
131 | 131 | case id: ByteVector => | |
132 | 132 | value(assetInfo(id)).name | |
133 | 133 | case waves: Unit => | |
134 | 134 | "WAVES" | |
135 | 135 | case _ => | |
136 | 136 | throw("Match error") | |
137 | 137 | } | |
138 | 138 | ||
139 | 139 | let assetNameB = match assetIdB { | |
140 | 140 | case id: ByteVector => | |
141 | 141 | value(assetInfo(id)).name | |
142 | 142 | case waves: Unit => | |
143 | 143 | "WAVES" | |
144 | 144 | case _ => | |
145 | 145 | throw("Match error") | |
146 | 146 | } | |
147 | 147 | ||
148 | 148 | let balanceA = getIntegerValue(this, kBalanceA) | |
149 | 149 | ||
150 | 150 | let balanceB = getIntegerValue(this, kBalanceB) | |
151 | 151 | ||
152 | 152 | let shareAssetId = fromBase58String(getStringValue(this, kShareAssetId)) | |
153 | 153 | ||
154 | 154 | let shareAssetSupply = getIntegerValue(this, kShareAssetSupply) | |
155 | 155 | ||
156 | 156 | let invariant = getIntegerValue(this, kInvariant) | |
157 | 157 | ||
158 | 158 | let fee = getIntegerValue(this, kFee) | |
159 | 159 | ||
160 | 160 | let feeGovernance = fraction(fee, 40, 100) | |
161 | 161 | ||
162 | 162 | let feeScale6 = 1000000 | |
163 | 163 | ||
164 | 164 | let scale3 = 1000 | |
165 | 165 | ||
166 | 166 | let scale8 = 100000000 | |
167 | 167 | ||
168 | 168 | let scale16 = 10000000000000000 | |
169 | 169 | ||
170 | 170 | let digits8 = 8 | |
171 | 171 | ||
172 | 172 | let dAppThreshold = 50 | |
173 | 173 | ||
174 | 174 | let dAppThresholdScale2 = 100 | |
175 | 175 | ||
176 | 176 | let exchangeRatioLimitMin = 90000000 | |
177 | 177 | ||
178 | 178 | let exchangeRatioLimitMax = 110000000 | |
179 | 179 | ||
180 | 180 | let alpha = 50 | |
181 | 181 | ||
182 | 182 | let alphaDigits = 2 | |
183 | 183 | ||
184 | 184 | let beta = 4600000000000000 | |
185 | 185 | ||
186 | 186 | func accountBalance (assetId) = match assetId { | |
187 | 187 | case id: ByteVector => | |
188 | 188 | assetBalance(this, id) | |
189 | 189 | case waves: Unit => | |
190 | 190 | wavesBalance(this).available | |
191 | 191 | case _ => | |
192 | 192 | throw("Match error") | |
193 | 193 | } | |
194 | 194 | ||
195 | 195 | ||
196 | 196 | func stakedAmount (assetId) = { | |
197 | 197 | let stakedAmountCalculated = match assetId { | |
198 | 198 | case aId: ByteVector => | |
199 | 199 | if ((aId == USDN)) | |
200 | 200 | then getInteger(stakingUSDNAddress, ((("rpd_balance_" + toBase58String(aId)) + "_") + toString(this))) | |
201 | 201 | else 0 | |
202 | 202 | case _: Unit => | |
203 | 203 | 0 | |
204 | 204 | case _ => | |
205 | 205 | throw("Match error") | |
206 | 206 | } | |
207 | 207 | match stakedAmountCalculated { | |
208 | 208 | case i: Int => | |
209 | 209 | i | |
210 | 210 | case _ => | |
211 | 211 | 0 | |
212 | 212 | } | |
213 | 213 | } | |
214 | 214 | ||
215 | 215 | ||
216 | 216 | let stakedAmountA = stakedAmount(assetIdA) | |
217 | 217 | ||
218 | 218 | let stakedAmountB = stakedAmount(assetIdB) | |
219 | 219 | ||
220 | 220 | let availableBalanceA = (balanceA - stakedAmountA) | |
221 | 221 | ||
222 | 222 | let availableBalanceB = (balanceB - stakedAmountB) | |
223 | 223 | ||
224 | 224 | let accountBalanceWithStakedA = (accountBalance(assetIdA) + stakedAmountA) | |
225 | 225 | ||
226 | 226 | let accountBalanceWithStakedB = (accountBalance(assetIdB) + stakedAmountB) | |
227 | 227 | ||
228 | 228 | let hasEnoughBalance = if ((accountBalanceWithStakedA >= balanceA)) | |
229 | 229 | then (accountBalanceWithStakedB >= balanceB) | |
230 | 230 | else false | |
231 | 231 | ||
232 | 232 | func skewness (x,y) = ((fraction(scale16, x, y) + fraction(scale16, y, x)) / 2) | |
233 | 233 | ||
234 | 234 | ||
235 | 235 | func invariantCalc (x,y) = { | |
236 | 236 | let sk = skewness(x, y) | |
237 | 237 | (fraction((x + y), scale16, pow(sk, digits8, alpha, alphaDigits, digits8, CEILING)) + (2 * fraction(toInt(pow(fraction(toBigInt(x), toBigInt(y), toBigInt(scale8)), 0, toBigInt(5), 1, (digits8 / 2), DOWN)), pow((sk - beta), digits8, alpha, alphaDigits, digits8, DOWN), scale8))) | |
238 | 238 | } | |
239 | 239 | ||
240 | 240 | ||
241 | 241 | func calculateSendAmount (amountToSendEstimated,minTokenReceiveAmount,tokenReceiveAmount,tokenId,balcA,balcB,invCur) = { | |
242 | 242 | let worstAllowedNewInvariantRatio = (scale16 - ((scale16 * 1) / 10000000)) | |
243 | 243 | let deltaBetweenMaxAndMinSendValue = (amountToSendEstimated - minTokenReceiveAmount) | |
244 | 244 | let x = (balcA + tokenReceiveAmount) | |
245 | 245 | let y = (balcB + tokenReceiveAmount) | |
246 | 246 | func getStepAmount (acc,step) = if ((acc._1 == -1)) | |
247 | 247 | then { | |
248 | 248 | let amountToSend = (amountToSendEstimated - (((step * deltaBetweenMaxAndMinSendValue) / 3) / scale3)) | |
249 | 249 | let stepInvariant = if ((tokenId == assetIdA)) | |
250 | 250 | then invariantCalc(x, (balcB - amountToSend)) | |
251 | 251 | else invariantCalc((balcA - amountToSend), y) | |
252 | 252 | if ((stepInvariant > invCur)) | |
253 | 253 | then $Tuple2(amountToSend, stepInvariant) | |
254 | 254 | else $Tuple2(-1, 0) | |
255 | 255 | } | |
256 | 256 | else acc | |
257 | 257 | ||
258 | 258 | let amountToSendMin = getStepAmount($Tuple2(-1, 0), 3000) | |
259 | 259 | if ((0 > amountToSendMin._1)) | |
260 | 260 | then throw("Price is worse than minReceived") | |
261 | 261 | else { | |
262 | 262 | let invEstimated = if ((tokenId == assetIdA)) | |
263 | 263 | then invariantCalc(x, (balcB - amountToSendEstimated)) | |
264 | 264 | else if ((tokenId == assetIdB)) | |
265 | 265 | then invariantCalc((balcA - amountToSendEstimated), y) | |
266 | 266 | else throw("Wrong asset in payment") | |
267 | 267 | if ((invCur > invEstimated)) | |
268 | 268 | then if ((worstAllowedNewInvariantRatio >= fraction(scale16, invCur, invEstimated))) | |
269 | 269 | then throw("The requested price is too not profitable for user") | |
270 | 270 | else { | |
271 | 271 | let a = { | |
272 | 272 | let $l = [25, 200, 500] | |
273 | 273 | let $s = size($l) | |
274 | 274 | let $acc0 = $Tuple2(-1, 0) | |
275 | 275 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
276 | 276 | then $a | |
277 | 277 | else getStepAmount($a, $l[$i]) | |
278 | 278 | ||
279 | 279 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
280 | 280 | then $a | |
281 | 281 | else throw("List size exceeds 3") | |
282 | 282 | ||
283 | 283 | $f0_2($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3) | |
284 | 284 | } | |
285 | 285 | if ((0 > a._1)) | |
286 | 286 | then amountToSendMin._1 | |
287 | 287 | else a._1 | |
288 | 288 | } | |
289 | 289 | else { | |
290 | 290 | let a = { | |
291 | 291 | let $l = [-500, -200, -25] | |
292 | 292 | let $s = size($l) | |
293 | 293 | let $acc0 = $Tuple2(-1, 0) | |
294 | 294 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
295 | 295 | then $a | |
296 | 296 | else getStepAmount($a, $l[$i]) | |
297 | 297 | ||
298 | 298 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
299 | 299 | then $a | |
300 | 300 | else throw("List size exceeds 3") | |
301 | 301 | ||
302 | 302 | $f0_2($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3) | |
303 | 303 | } | |
304 | 304 | let tupleSendBetter = if ((0 > a._1)) | |
305 | 305 | then $Tuple2(amountToSendEstimated, invEstimated) | |
306 | 306 | else a | |
307 | 307 | if ((worstAllowedNewInvariantRatio >= fraction(scale16, invCur, tupleSendBetter._2))) | |
308 | 308 | then throw("The requested price is too not profitable for user") | |
309 | 309 | else tupleSendBetter._1 | |
310 | 310 | } | |
311 | 311 | } | |
312 | 312 | } | |
313 | 313 | ||
314 | 314 | ||
315 | 315 | func getAssetInfo (assetId) = match assetId { | |
316 | 316 | case id: ByteVector => | |
317 | 317 | let stringId = toBase58String(id) | |
318 | 318 | let info = valueOrErrorMessage(assetInfo(id), (("Asset " + stringId) + " doesn't exist")) | |
319 | 319 | $Tuple3(stringId, info.name, info.decimals) | |
320 | 320 | case waves: Unit => | |
321 | 321 | $Tuple3("WAVES", "WAVES", 8) | |
322 | 322 | case _ => | |
323 | 323 | throw("Match error") | |
324 | 324 | } | |
325 | 325 | ||
326 | 326 | ||
327 | 327 | func suspend (cause) = [BooleanEntry(kActive, false), StringEntry(kCause, cause)] | |
328 | 328 | ||
329 | 329 | ||
330 | 330 | func throwIsActive () = throw("DApp is already active") | |
331 | 331 | ||
332 | 332 | ||
333 | 333 | func isActive () = if (if (active) | |
334 | 334 | then activeGlob | |
335 | 335 | else false) | |
336 | 336 | then unit | |
337 | 337 | else throw("DApp is inactive at this moment") | |
338 | 338 | ||
339 | 339 | ||
340 | 340 | func isAdminCall (i) = if (containsElement([adminPubKey1, adminPubKey2, adminPubKey3], i.callerPublicKey)) | |
341 | 341 | then unit | |
342 | 342 | else throw("Only admin can call this function") | |
343 | 343 | ||
344 | 344 | ||
345 | 345 | func isSelfCall (i) = if ((this == i.caller)) | |
346 | 346 | then unit | |
347 | 347 | else throw("Only contract itself can call this function") | |
348 | 348 | ||
349 | 349 | ||
350 | 350 | func throwAssets () = throw(((("Incorrect assets attached. Expected: " + strAssetIdA) + " and ") + strAssetIdB)) | |
351 | 351 | ||
352 | 352 | ||
353 | 353 | func throwOnePayment () = throw("One attached payment expected") | |
354 | 354 | ||
355 | 355 | ||
356 | 356 | func throwThreshold (threshold,amountA,amountB) = throw(((((((((("New balance in assets of the DApp is less than threshold " + toString(threshold)) + ": ") + toString(amountA)) + " ") + assetNameA) + ", ") + toString(amountB)) + " ") + assetNameB)) | |
357 | 357 | ||
358 | 358 | ||
359 | 359 | func suspendSuspicious () = suspend(((((((((((((((("Suspicious state. Actual balances: " + toString(balanceA)) + " ") + assetNameA) + ", ") + toString(balanceB)) + " ") + assetNameB) + ". State: ") + toString(accountBalance(assetIdA))) + " ") + assetNameA) + ", ") + toString(accountBalance(assetIdB))) + " ") + assetNameB)) | |
360 | 360 | ||
361 | 361 | ||
362 | 362 | func calcStakingFuncAndAddres (stake,assetId) = if (stake) | |
363 | 363 | then $Tuple2("lockNeutrino", stakingUSDNAddress) | |
364 | 364 | else $Tuple2("unlockNeutrino", stakingUSDNAddress) | |
365 | 365 | ||
366 | 366 | ||
367 | 367 | func calcStakingParams (stake,amount,assetId) = if (stake) | |
368 | 368 | then { | |
369 | 369 | let $t01050410570 = calcStakingFuncAndAddres(stake, assetId) | |
370 | 370 | let call = $t01050410570._1 | |
371 | 371 | let stakingAddr = $t01050410570._2 | |
372 | 372 | $Tuple4(call, stakingAddr, nil, [AttachedPayment(assetId, amount)]) | |
373 | 373 | } | |
374 | 374 | else { | |
375 | 375 | let $t01065610722 = calcStakingFuncAndAddres(stake, assetId) | |
376 | 376 | let call = $t01065610722._1 | |
377 | 377 | let stakingAddr = $t01065610722._2 | |
378 | 378 | $Tuple4(call, stakingAddr, [amount, toBase58String(assetId)], nil) | |
379 | 379 | } | |
380 | 380 | ||
381 | 381 | ||
382 | 382 | func calculateFeeDiscount (userAddr) = { | |
383 | 383 | let swopAmount = valueOrElse(getInteger(govAddress, (toString(userAddr) + kUserSwopInGov)), 0) | |
384 | - | let gSwopAmount = valueOrElse(getInteger(govAddress, (toString(userAddr) + kUserGSwopInGov)), | |
384 | + | let gSwopAmount = valueOrElse(getInteger(govAddress, (toString(userAddr) + kUserGSwopInGov)), swopAmount) | |
385 | 385 | let discountValues = split(getStringValue(oracle, kDiscountValues), ",") | |
386 | 386 | let discounts = split(getStringValue(oracle, kDiscounts), ",") | |
387 | 387 | if (if ((gSwopAmount >= parseIntValue(discountValues[0]))) | |
388 | 388 | then (parseIntValue(discountValues[1]) > gSwopAmount) | |
389 | 389 | else false) | |
390 | 390 | then (feeScale6 - parseIntValue(discounts[0])) | |
391 | 391 | else if (if ((gSwopAmount >= parseIntValue(discountValues[1]))) | |
392 | 392 | then (parseIntValue(discountValues[2]) > gSwopAmount) | |
393 | 393 | else false) | |
394 | 394 | then (feeScale6 - parseIntValue(discounts[1])) | |
395 | 395 | else if (if ((gSwopAmount >= parseIntValue(discountValues[2]))) | |
396 | 396 | then (parseIntValue(discountValues[3]) > gSwopAmount) | |
397 | 397 | else false) | |
398 | 398 | then (feeScale6 - parseIntValue(discounts[2])) | |
399 | 399 | else if (if ((gSwopAmount >= parseIntValue(discountValues[3]))) | |
400 | 400 | then (parseIntValue(discountValues[4]) > gSwopAmount) | |
401 | 401 | else false) | |
402 | 402 | then (feeScale6 - parseIntValue(discounts[3])) | |
403 | 403 | else if ((gSwopAmount >= parseIntValue(discountValues[4]))) | |
404 | 404 | then (feeScale6 - parseIntValue(discounts[4])) | |
405 | 405 | else feeScale6 | |
406 | 406 | } | |
407 | 407 | ||
408 | 408 | ||
409 | 409 | func replenishWithTwoTokensCalc (i,stakeFarming,lockType) = { | |
410 | 410 | let pmtAssetIdA = i.payments[0].assetId | |
411 | 411 | let pmtAssetIdB = i.payments[1].assetId | |
412 | 412 | let ratioShareTokensInA = fraction(scale8, i.payments[0].amount, balanceA) | |
413 | 413 | let ratioShareTokensInB = fraction(scale8, i.payments[1].amount, balanceB) | |
414 | - | let $ | |
415 | - | let pmtStrAssetIdA = $ | |
416 | - | let pmtAssetNameA = $ | |
417 | - | let pmtDecimalsA = $ | |
418 | - | let $ | |
419 | - | let pmtStrAssetIdB = $ | |
420 | - | let pmtAssetNameB = $ | |
421 | - | let pmtDecimalsB = $ | |
422 | - | let $ | |
414 | + | let $t01231312390 = getAssetInfo(pmtAssetIdA) | |
415 | + | let pmtStrAssetIdA = $t01231312390._1 | |
416 | + | let pmtAssetNameA = $t01231312390._2 | |
417 | + | let pmtDecimalsA = $t01231312390._3 | |
418 | + | let $t01239512512 = getAssetInfo(pmtAssetIdB) | |
419 | + | let pmtStrAssetIdB = $t01239512512._1 | |
420 | + | let pmtAssetNameB = $t01239512512._2 | |
421 | + | let pmtDecimalsB = $t01239512512._3 | |
422 | + | let $t01251713021 = if ((ratioShareTokensInB > ratioShareTokensInA)) | |
423 | 423 | then { | |
424 | 424 | let pmt = fraction(balanceB, ratioShareTokensInA, scale8, CEILING) | |
425 | 425 | $Tuple5(i.payments[0].amount, pmt, (i.payments[1].amount - pmt), pmtAssetIdB, ratioShareTokensInA) | |
426 | 426 | } | |
427 | 427 | else { | |
428 | 428 | let pmt = fraction(balanceA, ratioShareTokensInB, scale8, CEILING) | |
429 | 429 | $Tuple5(pmt, i.payments[1].amount, (i.payments[0].amount - pmt), pmtAssetIdA, ratioShareTokensInB) | |
430 | 430 | } | |
431 | - | let pmtAmountA = $ | |
432 | - | let pmtAmountB = $ | |
433 | - | let change = $ | |
434 | - | let changeAssetId = $ | |
435 | - | let shareTokenRatio = $ | |
431 | + | let pmtAmountA = $t01251713021._1 | |
432 | + | let pmtAmountB = $t01251713021._2 | |
433 | + | let change = $t01251713021._3 | |
434 | + | let changeAssetId = $t01251713021._4 | |
435 | + | let shareTokenRatio = $t01251713021._5 | |
436 | 436 | let shareTokenToPayAmount = fraction(shareTokenRatio, shareAssetSupply, scale8) | |
437 | 437 | if (if ((size(i.payments) != 2)) | |
438 | 438 | then (size(i.payments) != 3) | |
439 | 439 | else false) | |
440 | 440 | then throw("Two or three payments expected") | |
441 | 441 | else if (if ((pmtAssetIdA != assetIdA)) | |
442 | 442 | then true | |
443 | 443 | else (pmtAssetIdB != assetIdB)) | |
444 | 444 | then throwAssets() | |
445 | 445 | else if ((shareTokenToPayAmount == 0)) | |
446 | 446 | then throw("Too small amount to replenish") | |
447 | 447 | else if ((0 > change)) | |
448 | 448 | then throw("Change < 0") | |
449 | 449 | else if (!(hasEnoughBalance)) | |
450 | 450 | then ([ScriptTransfer(i.caller, pmtAmountA, pmtAssetIdA), ScriptTransfer(i.caller, pmtAmountB, pmtAssetIdB)] ++ suspendSuspicious()) | |
451 | 451 | else { | |
452 | 452 | let stake1 = if (contains(stakingAssets, pmtStrAssetIdA)) | |
453 | 453 | then invoke(this, "stakeUnstake", [true, pmtAmountA, pmtStrAssetIdA], nil) | |
454 | 454 | else 0 | |
455 | 455 | if ((stake1 == stake1)) | |
456 | 456 | then { | |
457 | 457 | let stake2 = if (contains(stakingAssets, pmtStrAssetIdB)) | |
458 | 458 | then invoke(this, "stakeUnstake", [true, pmtAmountB, pmtStrAssetIdB], nil) | |
459 | 459 | else 0 | |
460 | 460 | if ((stake2 == stake2)) | |
461 | 461 | then { | |
462 | 462 | let scriptActions = [IntegerEntry(kBalanceA, (balanceA + pmtAmountA)), IntegerEntry(kBalanceB, (balanceB + pmtAmountB)), IntegerEntry(kShareAssetSupply, (shareAssetSupply + shareTokenToPayAmount)), IntegerEntry(kInvariant, invariantCalc((balanceA + pmtAmountA), (balanceB + pmtAmountB))), ScriptTransfer(i.caller, change, changeAssetId)] | |
463 | 463 | if (stakeFarming) | |
464 | 464 | then { | |
465 | 465 | let stPayments = ([AttachedPayment(shareAssetId, shareTokenToPayAmount)] ++ (if ((size(i.payments) == 3)) | |
466 | 466 | then [AttachedPayment(if ((i.payments[2].assetId == base58'')) | |
467 | 467 | then unit | |
468 | 468 | else i.payments[2].assetId, i.payments[2].amount)] | |
469 | 469 | else nil)) | |
470 | 470 | let re = invoke(this, "reissueShare", [shareTokenToPayAmount], nil) | |
471 | 471 | if ((re == re)) | |
472 | 472 | then { | |
473 | 473 | let s = invoke(farmingAddress, "lockShareTokensFromPool", [i.caller.bytes, toString(this), lockType], stPayments) | |
474 | 474 | if ((s == s)) | |
475 | 475 | then scriptActions | |
476 | 476 | else throw("Strict value is not equal to itself.") | |
477 | 477 | } | |
478 | 478 | else throw("Strict value is not equal to itself.") | |
479 | 479 | } | |
480 | 480 | else (scriptActions ++ [Reissue(shareAssetId, shareTokenToPayAmount, true), ScriptTransfer(i.caller, shareTokenToPayAmount, shareAssetId)]) | |
481 | 481 | } | |
482 | 482 | else throw("Strict value is not equal to itself.") | |
483 | 483 | } | |
484 | 484 | else throw("Strict value is not equal to itself.") | |
485 | 485 | } | |
486 | 486 | } | |
487 | 487 | ||
488 | 488 | ||
489 | 489 | func replenishWithOneTokenCalc (i,virtualSwapTokenPay,virtualSwapTokenGet,stakeFarming,lockType) = { | |
490 | - | let $ | |
491 | - | let pmtAmount = $ | |
492 | - | let pmtAssetId = $ | |
493 | - | let $ | |
494 | - | let pmtStrAssetId = $ | |
495 | - | let pmtAssetName = $ | |
496 | - | let pmtDecimals = $ | |
490 | + | let $t01541115486 = $Tuple2(i.payments[0].amount, i.payments[0].assetId) | |
491 | + | let pmtAmount = $t01541115486._1 | |
492 | + | let pmtAssetId = $t01541115486._2 | |
493 | + | let $t01549115564 = getAssetInfo(pmtAssetId) | |
494 | + | let pmtStrAssetId = $t01549115564._1 | |
495 | + | let pmtAssetName = $t01549115564._2 | |
496 | + | let pmtDecimals = $t01549115564._3 | |
497 | 497 | let pmtMinThreshold = 5000000 | |
498 | 498 | let thresholdValueForMinTolerance = 50000000 | |
499 | 499 | let tolerance = if ((thresholdValueForMinTolerance > pmtAmount)) | |
500 | 500 | then 100000 | |
501 | 501 | else 1 | |
502 | 502 | let slippageValueMinForReplenish = (scale8 - ((scale8 * tolerance) / 10000000)) | |
503 | 503 | let slippageValueMaxForReplenish = (scale8 + ((scale8 * tolerance) / 10000000)) | |
504 | 504 | let slippageValueMinForSwap = (scale8 - ((scale8 * 1) / 10000000)) | |
505 | 505 | if ((pmtMinThreshold > pmtAmount)) | |
506 | 506 | then throw((((("Payment amount " + toString(pmtAmount)) + " does not exceed the minimum amount of ") + toString(pmtMinThreshold)) + " tokens")) | |
507 | 507 | else if (if ((size(i.payments) != 1)) | |
508 | 508 | then (size(i.payments) != 2) | |
509 | 509 | else false) | |
510 | 510 | then throw("One or two payments expected") | |
511 | 511 | else if (!(hasEnoughBalance)) | |
512 | 512 | then ([ScriptTransfer(i.caller, pmtAmount, pmtAssetId)] ++ suspendSuspicious()) | |
513 | 513 | else if (if ((pmtAssetId != assetIdA)) | |
514 | 514 | then (pmtAssetId != assetIdB) | |
515 | 515 | else false) | |
516 | 516 | then throwAssets() | |
517 | 517 | else { | |
518 | - | let $ | |
518 | + | let $t01657117213 = if ((pmtAssetId == assetIdA)) | |
519 | 519 | then $Tuple6((pmtAmount - virtualSwapTokenPay), virtualSwapTokenGet, (balanceA + virtualSwapTokenPay), (balanceB - virtualSwapTokenGet), (balanceA + pmtAmount), balanceB) | |
520 | 520 | else $Tuple6(virtualSwapTokenGet, (pmtAmount - virtualSwapTokenPay), (balanceA - virtualSwapTokenGet), (balanceB + virtualSwapTokenPay), balanceA, (balanceB + pmtAmount)) | |
521 | - | let virtualReplenishA = $ | |
522 | - | let virtualReplenishB = $ | |
523 | - | let balanceAfterSwapA = $ | |
524 | - | let balanceAfterSwapB = $ | |
525 | - | let newBalanceA = $ | |
526 | - | let newBalanceB = $ | |
521 | + | let virtualReplenishA = $t01657117213._1 | |
522 | + | let virtualReplenishB = $t01657117213._2 | |
523 | + | let balanceAfterSwapA = $t01657117213._3 | |
524 | + | let balanceAfterSwapB = $t01657117213._4 | |
525 | + | let newBalanceA = $t01657117213._5 | |
526 | + | let newBalanceB = $t01657117213._6 | |
527 | 527 | let invariantNew = invariantCalc(balanceAfterSwapA, balanceAfterSwapB) | |
528 | 528 | let ratioVirtualBalanceToVirtualReplenish = (fraction(scale16, balanceAfterSwapA, balanceAfterSwapB) / fraction(scale8, virtualReplenishA, virtualReplenishB)) | |
529 | 529 | let dAppThresholdAmount = fraction((newBalanceA + newBalanceB), dAppThreshold, (2 * dAppThresholdScale2)) | |
530 | 530 | if (if ((slippageValueMinForSwap >= fraction(scale8, invariant, invariantNew))) | |
531 | 531 | then true | |
532 | 532 | else (invariant > invariantNew)) | |
533 | 533 | then throw("Incorrect virtualSwapTokenPay or virtualSwapTokenGet value") | |
534 | 534 | else if (if ((slippageValueMinForReplenish > ratioVirtualBalanceToVirtualReplenish)) | |
535 | 535 | then true | |
536 | 536 | else (ratioVirtualBalanceToVirtualReplenish > slippageValueMaxForReplenish)) | |
537 | 537 | then throw("Swap with virtualSwapTokenPay and virtualSwapTokenGet is possible, but ratio after virtual swap is incorrect") | |
538 | 538 | else if (if ((dAppThresholdAmount > newBalanceA)) | |
539 | 539 | then true | |
540 | 540 | else (dAppThresholdAmount > newBalanceB)) | |
541 | 541 | then throwThreshold(dAppThresholdAmount, newBalanceA, newBalanceB) | |
542 | 542 | else { | |
543 | 543 | let ratioShareTokensInA = fraction(virtualReplenishA, scale8, balanceAfterSwapA) | |
544 | 544 | let ratioShareTokensInB = fraction(virtualReplenishB, scale8, balanceAfterSwapB) | |
545 | 545 | let shareTokenToPayAmount = fraction(min([ratioShareTokensInA, ratioShareTokensInB]), shareAssetSupply, scale8) | |
546 | 546 | let shareTokenToPayAmountAfterFee = fraction(shareTokenToPayAmount, (feeScale6 - (fee / 2)), feeScale6) | |
547 | 547 | let shareTokenGovernanceReward = fraction(shareTokenToPayAmount, (feeGovernance / 2), feeScale6) | |
548 | 548 | let governanceRewardTokenA = fraction(shareTokenGovernanceReward, balanceA, shareAssetSupply) | |
549 | 549 | let governanceRewardTokenB = fraction(shareTokenGovernanceReward, balanceB, shareAssetSupply) | |
550 | - | let $ | |
550 | + | let $t01920319498 = if ((pmtStrAssetId == strAssetIdA)) | |
551 | 551 | then $Tuple3((pmtAmount - governanceRewardTokenA), governanceRewardTokenB, strAssetIdB) | |
552 | 552 | else $Tuple3((pmtAmount - governanceRewardTokenB), governanceRewardTokenA, strAssetIdA) | |
553 | - | let stakeAmount = $ | |
554 | - | let unstakeAmount = $ | |
555 | - | let unstakeAsset = $ | |
553 | + | let stakeAmount = $t01920319498._1 | |
554 | + | let unstakeAmount = $t01920319498._2 | |
555 | + | let unstakeAsset = $t01920319498._3 | |
556 | 556 | let stake1 = if (contains(stakingAssets, pmtStrAssetId)) | |
557 | 557 | then invoke(this, "stakeUnstake", [true, stakeAmount, pmtStrAssetId], nil) | |
558 | 558 | else 0 | |
559 | 559 | if ((stake1 == stake1)) | |
560 | 560 | then { | |
561 | 561 | let stake2 = if (contains(stakingAssets, unstakeAsset)) | |
562 | 562 | then invoke(this, "stakeUnstake", [false, unstakeAmount, unstakeAsset], nil) | |
563 | 563 | else 0 | |
564 | 564 | if ((stake2 == stake2)) | |
565 | 565 | then { | |
566 | 566 | let scriptActions = [IntegerEntry(kBalanceA, (newBalanceA - governanceRewardTokenA)), IntegerEntry(kBalanceB, (newBalanceB - governanceRewardTokenB)), IntegerEntry(kShareAssetSupply, (shareAssetSupply + shareTokenToPayAmountAfterFee)), IntegerEntry(kInvariant, invariantCalc((newBalanceA - governanceRewardTokenA), (newBalanceB - governanceRewardTokenB))), ScriptTransfer(moneyBoxAddress, governanceRewardTokenA, assetIdA), ScriptTransfer(moneyBoxAddress, governanceRewardTokenB, assetIdB)] | |
567 | 567 | if (stakeFarming) | |
568 | 568 | then { | |
569 | 569 | let stPayments = ([AttachedPayment(shareAssetId, shareTokenToPayAmountAfterFee)] ++ (if ((size(i.payments) == 2)) | |
570 | 570 | then [AttachedPayment(if ((i.payments[1].assetId == base58'')) | |
571 | 571 | then unit | |
572 | 572 | else i.payments[1].assetId, i.payments[1].amount)] | |
573 | 573 | else nil)) | |
574 | 574 | let re = invoke(this, "reissueShare", [shareTokenToPayAmountAfterFee], nil) | |
575 | 575 | if ((re == re)) | |
576 | 576 | then { | |
577 | 577 | let s = invoke(farmingAddress, "lockShareTokensFromPool", [i.caller.bytes, toString(this), lockType], stPayments) | |
578 | 578 | if ((s == s)) | |
579 | 579 | then scriptActions | |
580 | 580 | else throw("Strict value is not equal to itself.") | |
581 | 581 | } | |
582 | 582 | else throw("Strict value is not equal to itself.") | |
583 | 583 | } | |
584 | 584 | else (scriptActions ++ [Reissue(shareAssetId, shareTokenToPayAmountAfterFee, true), ScriptTransfer(i.caller, shareTokenToPayAmountAfterFee, shareAssetId)]) | |
585 | 585 | } | |
586 | 586 | else throw("Strict value is not equal to itself.") | |
587 | 587 | } | |
588 | 588 | else throw("Strict value is not equal to itself.") | |
589 | 589 | } | |
590 | 590 | } | |
591 | 591 | } | |
592 | 592 | ||
593 | 593 | ||
594 | 594 | func withdrawCalc (i,unlockAmount) = { | |
595 | - | let $ | |
595 | + | let $t02148521820 = if ((size(i.payments) == 1)) | |
596 | 596 | then if ((i.payments[0].assetId != shareAssetId)) | |
597 | 597 | then throw(("Incorrect asset attached. Expected: " + toBase58String(shareAssetId))) | |
598 | 598 | else $Tuple2(i.payments[0].amount, i.payments[0].assetId) | |
599 | 599 | else $Tuple2(0, shareAssetId) | |
600 | - | let pmtAmount = $ | |
601 | - | let pmtAssetId = $ | |
600 | + | let pmtAmount = $t02148521820._1 | |
601 | + | let pmtAssetId = $t02148521820._2 | |
602 | 602 | if (!(hasEnoughBalance)) | |
603 | 603 | then ([ScriptTransfer(i.caller, pmtAmount, pmtAssetId)] ++ suspendSuspicious()) | |
604 | 604 | else { | |
605 | 605 | let unlock = if ((unlockAmount > 0)) | |
606 | 606 | then invoke(farmingAddress, "withdrawShareTokensFromPool", [i.caller.bytes, toString(this), unlockAmount], nil) | |
607 | 607 | else 0 | |
608 | 608 | if ((unlock == unlock)) | |
609 | 609 | then { | |
610 | 610 | let withdrawAmount = (pmtAmount + unlockAmount) | |
611 | 611 | let amountToPayA = fraction(withdrawAmount, balanceA, shareAssetSupply) | |
612 | 612 | let amountToPayB = fraction(withdrawAmount, balanceB, shareAssetSupply) | |
613 | 613 | let invariantCalculated = invariantCalc((balanceA - amountToPayA), (balanceB - amountToPayB)) | |
614 | 614 | let stake1 = if (contains(stakingAssets, strAssetIdA)) | |
615 | 615 | then invoke(this, "stakeUnstake", [false, amountToPayA, strAssetIdA], nil) | |
616 | 616 | else 0 | |
617 | 617 | if ((stake1 == stake1)) | |
618 | 618 | then { | |
619 | 619 | let stake2 = if (contains(stakingAssets, strAssetIdB)) | |
620 | 620 | then invoke(this, "stakeUnstake", [false, amountToPayB, strAssetIdB], nil) | |
621 | 621 | else 0 | |
622 | 622 | if ((stake2 == stake2)) | |
623 | 623 | then [IntegerEntry(kBalanceA, (balanceA - amountToPayA)), IntegerEntry(kBalanceB, (balanceB - amountToPayB)), IntegerEntry(kShareAssetSupply, (shareAssetSupply - withdrawAmount)), IntegerEntry(kInvariant, invariantCalculated), Burn(shareAssetId, withdrawAmount), ScriptTransfer(i.caller, amountToPayA, assetIdA), ScriptTransfer(i.caller, amountToPayB, assetIdB)] | |
624 | 624 | else throw("Strict value is not equal to itself.") | |
625 | 625 | } | |
626 | 626 | else throw("Strict value is not equal to itself.") | |
627 | 627 | } | |
628 | 628 | else throw("Strict value is not equal to itself.") | |
629 | 629 | } | |
630 | 630 | } | |
631 | 631 | ||
632 | 632 | ||
633 | 633 | @Callable(i) | |
634 | 634 | func init (firstHarvest) = { | |
635 | - | let $ | |
636 | - | let pmtAmountA = $ | |
637 | - | let pmtAssetIdA = $ | |
638 | - | let $ | |
639 | - | let pmtAmountB = $ | |
640 | - | let pmtAssetIdB = $ | |
641 | - | let $ | |
642 | - | let pmtStrAssetIdA = $ | |
643 | - | let pmtAssetNameA = $ | |
644 | - | let pmtDecimalsA = $ | |
645 | - | let $ | |
646 | - | let pmtStrAssetIdB = $ | |
647 | - | let pmtAssetNameB = $ | |
648 | - | let pmtDecimalsB = $ | |
635 | + | let $t02337223449 = $Tuple2(i.payments[0].amount, i.payments[0].assetId) | |
636 | + | let pmtAmountA = $t02337223449._1 | |
637 | + | let pmtAssetIdA = $t02337223449._2 | |
638 | + | let $t02345423531 = $Tuple2(i.payments[1].amount, i.payments[1].assetId) | |
639 | + | let pmtAmountB = $t02345423531._1 | |
640 | + | let pmtAssetIdB = $t02345423531._2 | |
641 | + | let $t02353623613 = getAssetInfo(pmtAssetIdA) | |
642 | + | let pmtStrAssetIdA = $t02353623613._1 | |
643 | + | let pmtAssetNameA = $t02353623613._2 | |
644 | + | let pmtDecimalsA = $t02353623613._3 | |
645 | + | let $t02361823695 = getAssetInfo(pmtAssetIdB) | |
646 | + | let pmtStrAssetIdB = $t02361823695._1 | |
647 | + | let pmtAssetNameB = $t02361823695._2 | |
648 | + | let pmtDecimalsB = $t02361823695._3 | |
649 | 649 | if (isDefined(getBoolean(this, kActive))) | |
650 | 650 | then throwIsActive() | |
651 | 651 | else if ((pmtAssetIdA == pmtAssetIdB)) | |
652 | 652 | then throw("Assets must be different") | |
653 | 653 | else { | |
654 | 654 | let shareName = ((("s" + take(pmtAssetNameA, 7)) + "_") + take(pmtAssetNameB, 7)) | |
655 | 655 | let shareDescription = ((((("ShareToken of SwopFi protocol for " + pmtAssetNameA) + " and ") + pmtAssetNameB) + " at address ") + toString(this)) | |
656 | 656 | let shareDecimals = ((pmtDecimalsA + pmtDecimalsB) / 2) | |
657 | 657 | let shareInitialSupply = fraction(pow(pmtAmountA, pmtDecimalsA, 5, 1, pmtDecimalsA, DOWN), pow(pmtAmountB, pmtDecimalsB, 5, 1, pmtDecimalsB, DOWN), pow(10, 0, shareDecimals, 0, 0, DOWN)) | |
658 | 658 | let shareIssue = Issue(shareName, shareDescription, shareInitialSupply, shareDecimals, true) | |
659 | 659 | let shareIssueId = calculateAssetId(shareIssue) | |
660 | 660 | let invariantCalculated = invariantCalc(pmtAmountA, pmtAmountB) | |
661 | 661 | let stake1 = if (contains(stakingAssets, pmtStrAssetIdA)) | |
662 | 662 | then invoke(this, "stakeUnstake", [true, pmtAmountA, pmtStrAssetIdA], nil) | |
663 | 663 | else 0 | |
664 | 664 | if ((stake1 == stake1)) | |
665 | 665 | then { | |
666 | 666 | let stake2 = if (contains(stakingAssets, pmtStrAssetIdB)) | |
667 | 667 | then invoke(this, "stakeUnstake", [true, pmtAmountB, pmtStrAssetIdB], nil) | |
668 | 668 | else 0 | |
669 | 669 | if ((stake2 == stake2)) | |
670 | 670 | then { | |
671 | 671 | let baseEntry = [StringEntry(kVersion, version), BooleanEntry(kActive, true), StringEntry(kAssetIdA, pmtStrAssetIdA), StringEntry(kAssetIdB, pmtStrAssetIdB), IntegerEntry(kBalanceA, pmtAmountA), IntegerEntry(kBalanceB, pmtAmountB), IntegerEntry(kInvariant, invariantCalculated), IntegerEntry(kFee, getIntegerValue(oracle, "base_fee_flat")), shareIssue, StringEntry(kShareAssetId, toBase58String(shareIssueId)), IntegerEntry(kShareAssetSupply, shareInitialSupply), ScriptTransfer(i.caller, shareInitialSupply, shareIssueId)] | |
672 | 672 | if (firstHarvest) | |
673 | 673 | then (baseEntry ++ [BooleanEntry(kFirstHarvest, firstHarvest), IntegerEntry(kFirstHarvestHeight, (startHeight + (firstHarvestEndPeriod * periodLength)))]) | |
674 | 674 | else baseEntry | |
675 | 675 | } | |
676 | 676 | else throw("Strict value is not equal to itself.") | |
677 | 677 | } | |
678 | 678 | else throw("Strict value is not equal to itself.") | |
679 | 679 | } | |
680 | 680 | } | |
681 | 681 | ||
682 | 682 | ||
683 | 683 | ||
684 | 684 | @Callable(i) | |
685 | 685 | func replenishWithTwoTokensV2 (stakeFarming,lockType) = valueOrElse(isActive(), replenishWithTwoTokensCalc(i, stakeFarming, lockType)) | |
686 | 686 | ||
687 | 687 | ||
688 | 688 | ||
689 | 689 | @Callable(i) | |
690 | 690 | func replenishWithOneTokenV2 (virtualSwapTokenPay,virtualSwapTokenGet,stakeFarming,lockType) = valueOrElse(isActive(), replenishWithOneTokenCalc(i, virtualSwapTokenPay, virtualSwapTokenGet, stakeFarming, lockType)) | |
691 | 691 | ||
692 | 692 | ||
693 | 693 | ||
694 | 694 | @Callable(i) | |
695 | 695 | func withdrawV2 (unlockAmount) = valueOrElse(isActive(), withdrawCalc(i, unlockAmount)) | |
696 | 696 | ||
697 | 697 | ||
698 | 698 | ||
699 | 699 | @Callable(i) | |
700 | 700 | func withdrawOneToken (unlockAmount,withdrawAsset,estimatedAmountToReceive,minAmountToReceive) = valueOrElse(isActive(), { | |
701 | - | let $ | |
701 | + | let $t02706527400 = if ((size(i.payments) == 1)) | |
702 | 702 | then if ((i.payments[0].assetId != shareAssetId)) | |
703 | 703 | then throw(("Incorrect asset attached. Expected: " + toBase58String(shareAssetId))) | |
704 | 704 | else $Tuple2(i.payments[0].amount, i.payments[0].assetId) | |
705 | 705 | else $Tuple2(0, shareAssetId) | |
706 | - | let pmtAmount = $ | |
707 | - | let pmtAssetId = $ | |
706 | + | let pmtAmount = $t02706527400._1 | |
707 | + | let pmtAssetId = $t02706527400._2 | |
708 | 708 | let withdrawAmount = (pmtAmount + unlockAmount) | |
709 | 709 | if (if ((withdrawAsset != strAssetIdA)) | |
710 | 710 | then (withdrawAsset != strAssetIdB) | |
711 | 711 | else false) | |
712 | 712 | then throw("Incorrect withdraw asset") | |
713 | 713 | else if ((0 >= withdrawAmount)) | |
714 | 714 | then throw("withdraw amount must be grater than 0") | |
715 | 715 | else if (!(hasEnoughBalance)) | |
716 | 716 | then ([ScriptTransfer(i.caller, pmtAmount, pmtAssetId)] ++ suspendSuspicious()) | |
717 | 717 | else { | |
718 | 718 | let unlock = if ((unlockAmount > 0)) | |
719 | 719 | then invoke(farmingAddress, "withdrawShareTokensFromPool", [i.caller.bytes, toString(this), unlockAmount], nil) | |
720 | 720 | else 0 | |
721 | 721 | if ((unlock == unlock)) | |
722 | 722 | then { | |
723 | 723 | let amountToPayA = fraction(withdrawAmount, balanceA, shareAssetSupply) | |
724 | 724 | let amountToPayB = fraction(withdrawAmount, balanceB, shareAssetSupply) | |
725 | 725 | let newVirtBalcA = (balanceA - amountToPayA) | |
726 | 726 | let newVirtBalcB = (balanceB - amountToPayB) | |
727 | 727 | let feeDiscount = calculateFeeDiscount(i.originCaller) | |
728 | 728 | let amountExchangedWithFee = if ((withdrawAsset == strAssetIdA)) | |
729 | 729 | then calculateSendAmount(estimatedAmountToReceive, minAmountToReceive, amountToPayB, assetIdB, newVirtBalcA, newVirtBalcB, invariantCalc(newVirtBalcA, newVirtBalcB)) | |
730 | 730 | else calculateSendAmount(estimatedAmountToReceive, minAmountToReceive, amountToPayA, assetIdA, newVirtBalcA, newVirtBalcB, invariantCalc(newVirtBalcA, newVirtBalcB)) | |
731 | 731 | let govReward = fraction(amountExchangedWithFee, fraction(feeGovernance, feeDiscount, feeScale6, CEILING), feeScale6) | |
732 | 732 | let amountExchanged = fraction(amountExchangedWithFee, (feeScale6 - fraction(fee, feeDiscount, feeScale6, CEILING)), feeScale6) | |
733 | - | let $ | |
733 | + | let $t02900329332 = if ((withdrawAsset == strAssetIdA)) | |
734 | 734 | then $Tuple3((amountToPayA + amountExchanged), (((balanceA - amountToPayA) - amountExchanged) - govReward), balanceB) | |
735 | 735 | else $Tuple3((amountToPayB + amountExchanged), balanceA, (((balanceB - amountToPayB) - amountExchanged) - govReward)) | |
736 | - | let amountToPay = $ | |
737 | - | let balanceANew = $ | |
738 | - | let balanceBNew = $ | |
736 | + | let amountToPay = $t02900329332._1 | |
737 | + | let balanceANew = $t02900329332._2 | |
738 | + | let balanceBNew = $t02900329332._3 | |
739 | 739 | let invariantCalculated = invariantCalc(balanceANew, balanceBNew) | |
740 | 740 | let stake1 = if (contains(stakingAssets, withdrawAsset)) | |
741 | 741 | then invoke(this, "stakeUnstake", [false, (amountToPay + govReward), withdrawAsset], nil) | |
742 | 742 | else 0 | |
743 | 743 | if ((stake1 == stake1)) | |
744 | 744 | then [IntegerEntry(kBalanceA, balanceANew), IntegerEntry(kBalanceB, balanceBNew), IntegerEntry(kShareAssetSupply, (shareAssetSupply - withdrawAmount)), IntegerEntry(kInvariant, invariantCalculated), Burn(shareAssetId, withdrawAmount), ScriptTransfer(i.caller, amountToPay, fromBase58String(withdrawAsset)), ScriptTransfer(moneyBoxAddress, govReward, fromBase58String(withdrawAsset))] | |
745 | 745 | else throw("Strict value is not equal to itself.") | |
746 | 746 | } | |
747 | 747 | else throw("Strict value is not equal to itself.") | |
748 | 748 | } | |
749 | 749 | }) | |
750 | 750 | ||
751 | 751 | ||
752 | 752 | ||
753 | 753 | @Callable(i) | |
754 | 754 | func exchange (estimatedAmountToReceive,minAmountToReceive) = valueOrElse(isActive(), { | |
755 | - | let $ | |
756 | - | let pmtAmount = $ | |
757 | - | let pmtAssetId = $ | |
755 | + | let $t03020530280 = $Tuple2(i.payments[0].amount, i.payments[0].assetId) | |
756 | + | let pmtAmount = $t03020530280._1 | |
757 | + | let pmtAssetId = $t03020530280._2 | |
758 | 758 | if ((0 >= estimatedAmountToReceive)) | |
759 | 759 | then throw(("Estimated amount must be positive. Actual: " + toString(estimatedAmountToReceive))) | |
760 | 760 | else if ((minAmountToReceive > estimatedAmountToReceive)) | |
761 | 761 | then throw("Minimal amount can't be greater than estimated.") | |
762 | 762 | else if ((size(i.payments) != 1)) | |
763 | 763 | then throwOnePayment() | |
764 | 764 | else if (!(hasEnoughBalance)) | |
765 | 765 | then ([ScriptTransfer(i.caller, pmtAmount, pmtAssetId)] ++ suspendSuspicious()) | |
766 | 766 | else if (if ((pmtAssetId != assetIdA)) | |
767 | 767 | then (pmtAssetId != assetIdB) | |
768 | 768 | else false) | |
769 | 769 | then throwAssets() | |
770 | 770 | else if ((10000000 > pmtAmount)) | |
771 | 771 | then throw("Only swap of 10.000000 or more tokens is allowed") | |
772 | 772 | else if (if ((exchangeRatioLimitMin > fraction(scale8, minAmountToReceive, pmtAmount))) | |
773 | 773 | then true | |
774 | 774 | else (fraction(scale8, estimatedAmountToReceive, pmtAmount) > exchangeRatioLimitMax)) | |
775 | 775 | then throw("Incorrect args and pmt ratio") | |
776 | 776 | else { | |
777 | 777 | let sendAssetId = if ((pmtAssetId == assetIdA)) | |
778 | 778 | then assetIdB | |
779 | 779 | else assetIdA | |
780 | 780 | let amount = calculateSendAmount(estimatedAmountToReceive, minAmountToReceive, pmtAmount, pmtAssetId, balanceA, balanceB, invariant) | |
781 | 781 | let feeDiscount = calculateFeeDiscount(i.originCaller) | |
782 | 782 | let governanceReward = fraction(amount, fraction(feeGovernance, feeDiscount, feeScale6, CEILING), feeScale6) | |
783 | 783 | let amountMinusFee = fraction(amount, (feeScale6 - fraction(fee, feeDiscount, feeScale6, CEILING)), feeScale6) | |
784 | - | let $ | |
784 | + | let $t03176432026 = if ((pmtAssetId == assetIdA)) | |
785 | 785 | then $Tuple2((balanceA + pmtAmount), ((balanceB - amountMinusFee) - governanceReward)) | |
786 | 786 | else $Tuple2(((balanceA - amountMinusFee) - governanceReward), (balanceB + pmtAmount)) | |
787 | - | let newBalanceA = $ | |
788 | - | let newBalanceB = $ | |
787 | + | let newBalanceA = $t03176432026._1 | |
788 | + | let newBalanceB = $t03176432026._2 | |
789 | 789 | let dAppThresholdAmount = fraction((newBalanceA + newBalanceB), dAppThreshold, (2 * dAppThresholdScale2)) | |
790 | 790 | if (if ((dAppThresholdAmount > newBalanceA)) | |
791 | 791 | then true | |
792 | 792 | else (dAppThresholdAmount > newBalanceB)) | |
793 | 793 | then throwThreshold(dAppThresholdAmount, newBalanceA, newBalanceB) | |
794 | 794 | else { | |
795 | - | let $ | |
796 | - | let pmtStrAssetId = $ | |
797 | - | let pmtAssetName = $ | |
798 | - | let pmtDecimals = $ | |
799 | - | let $ | |
800 | - | let sendStrAssetId = $ | |
801 | - | let sendAssetName = $ | |
802 | - | let sendDecimals = $ | |
795 | + | let $t03232532398 = getAssetInfo(pmtAssetId) | |
796 | + | let pmtStrAssetId = $t03232532398._1 | |
797 | + | let pmtAssetName = $t03232532398._2 | |
798 | + | let pmtDecimals = $t03232532398._3 | |
799 | + | let $t03241132488 = getAssetInfo(sendAssetId) | |
800 | + | let sendStrAssetId = $t03241132488._1 | |
801 | + | let sendAssetName = $t03241132488._2 | |
802 | + | let sendDecimals = $t03241132488._3 | |
803 | 803 | let stake1 = if (contains(stakingAssets, pmtStrAssetId)) | |
804 | 804 | then invoke(this, "stakeUnstake", [true, pmtAmount, pmtStrAssetId], nil) | |
805 | 805 | else 0 | |
806 | 806 | if ((stake1 == stake1)) | |
807 | 807 | then { | |
808 | 808 | let stake2 = if (contains(stakingAssets, sendStrAssetId)) | |
809 | 809 | then invoke(this, "stakeUnstake", [false, (amountMinusFee + governanceReward), sendStrAssetId], nil) | |
810 | 810 | else 0 | |
811 | 811 | if ((stake2 == stake2)) | |
812 | 812 | then $Tuple2([IntegerEntry(kBalanceA, newBalanceA), IntegerEntry(kBalanceB, newBalanceB), IntegerEntry(kInvariant, invariantCalc(newBalanceA, newBalanceB)), ScriptTransfer(i.caller, amountMinusFee, sendAssetId), ScriptTransfer(moneyBoxAddress, governanceReward, sendAssetId)], [amountMinusFee, sendAssetId]) | |
813 | 813 | else throw("Strict value is not equal to itself.") | |
814 | 814 | } | |
815 | 815 | else throw("Strict value is not equal to itself.") | |
816 | 816 | } | |
817 | 817 | } | |
818 | 818 | }) | |
819 | 819 | ||
820 | 820 | ||
821 | 821 | ||
822 | 822 | @Callable(msg) | |
823 | 823 | func reissueShare (amount) = valueOrElse(isSelfCall(msg), [Reissue(shareAssetId, amount, true)]) | |
824 | 824 | ||
825 | 825 | ||
826 | 826 | ||
827 | 827 | @Callable(i) | |
828 | 828 | func shutdown () = valueOrElse(isAdminCall(i), if (!(active)) | |
829 | 829 | then throw(("DApp is already suspended. Cause: " + valueOrElse(getString(this, kCause), "the cause wasn't specified"))) | |
830 | 830 | else suspend("Paused by admin")) | |
831 | 831 | ||
832 | 832 | ||
833 | 833 | ||
834 | 834 | @Callable(i) | |
835 | 835 | func activate () = valueOrElse(isAdminCall(i), if (active) | |
836 | 836 | then throwIsActive() | |
837 | 837 | else [BooleanEntry(kActive, true), DeleteEntry(kCause)]) | |
838 | 838 | ||
839 | 839 | ||
840 | 840 | ||
841 | 841 | @Callable(i) | |
842 | 842 | func takeIntoAccountExtraFunds () = valueOrElse(isActive(), { | |
843 | 843 | let amountEnrollA = (accountBalanceWithStakedA - balanceA) | |
844 | 844 | let amountEnrollB = (accountBalanceWithStakedB - balanceB) | |
845 | 845 | let invariantNew = invariantCalc((balanceA + amountEnrollA), (balanceB + amountEnrollB)) | |
846 | 846 | if ((i.caller != moneyBoxAddress)) | |
847 | 847 | then throw("Only the money box can call this function") | |
848 | 848 | else if (if ((0 > amountEnrollA)) | |
849 | 849 | then true | |
850 | 850 | else (0 > amountEnrollB)) | |
851 | 851 | then suspend("Enroll amount negative") | |
852 | 852 | else if (if ((amountEnrollA == 0)) | |
853 | 853 | then (amountEnrollB == 0) | |
854 | 854 | else false) | |
855 | 855 | then throw("No money to take") | |
856 | 856 | else { | |
857 | 857 | let stake1 = if (if (contains(stakingAssets, strAssetIdA)) | |
858 | 858 | then (amountEnrollA > 0) | |
859 | 859 | else false) | |
860 | 860 | then invoke(this, "stakeUnstake", [true, amountEnrollA, strAssetIdA], nil) | |
861 | 861 | else 0 | |
862 | 862 | if ((stake1 == stake1)) | |
863 | 863 | then { | |
864 | 864 | let stake2 = if (if (contains(stakingAssets, strAssetIdB)) | |
865 | 865 | then (amountEnrollB > 0) | |
866 | 866 | else false) | |
867 | 867 | then invoke(this, "stakeUnstake", [true, amountEnrollB, strAssetIdB], nil) | |
868 | 868 | else 0 | |
869 | 869 | if ((stake2 == stake2)) | |
870 | 870 | then [IntegerEntry(kInvariant, invariantNew), IntegerEntry(kBalanceA, (balanceA + amountEnrollA)), IntegerEntry(kBalanceB, (balanceB + amountEnrollB))] | |
871 | 871 | else throw("Strict value is not equal to itself.") | |
872 | 872 | } | |
873 | 873 | else throw("Strict value is not equal to itself.") | |
874 | 874 | } | |
875 | 875 | }) | |
876 | 876 | ||
877 | 877 | ||
878 | 878 | ||
879 | 879 | @Callable(i) | |
880 | 880 | func keepLimitForFirstHarvest (shareLimit) = valueOrElse(isActive(), valueOrElse(isAdminCall(i), [IntegerEntry(kShareLimit, shareLimit)])) | |
881 | 881 | ||
882 | 882 | ||
883 | 883 | ||
884 | 884 | @Callable(i) | |
885 | 885 | func stakeUnstake (stake,amount,assetIdString) = if ((i.caller != this)) | |
886 | 886 | then throw("Only contract itself can invoke this function") | |
887 | 887 | else { | |
888 | - | let $ | |
889 | - | let call = $ | |
890 | - | let addr = $ | |
891 | - | let params = $ | |
892 | - | let payments = $ | |
888 | + | let $t03579035893 = calcStakingParams(stake, amount, fromBase58String(assetIdString)) | |
889 | + | let call = $t03579035893._1 | |
890 | + | let addr = $t03579035893._2 | |
891 | + | let params = $t03579035893._3 | |
892 | + | let payments = $t03579035893._4 | |
893 | 893 | let inv = invoke(addr, call, params, payments) | |
894 | 894 | if ((inv == inv)) | |
895 | 895 | then nil | |
896 | 896 | else throw("Strict value is not equal to itself.") | |
897 | 897 | } | |
898 | 898 | ||
899 | 899 | ||
900 | 900 | ||
901 | 901 | @Callable(i) | |
902 | 902 | func replenishWithTwoTokens () = valueOrElse(isActive(), replenishWithTwoTokensCalc(i, false, 0)) | |
903 | 903 | ||
904 | 904 | ||
905 | 905 | ||
906 | 906 | @Callable(i) | |
907 | 907 | func replenishWithOneToken (virtualSwapTokenPay,virtualSwapTokenGet) = valueOrElse(isActive(), replenishWithOneTokenCalc(i, virtualSwapTokenPay, virtualSwapTokenGet, false, 0)) | |
908 | 908 | ||
909 | 909 | ||
910 | 910 | ||
911 | 911 | @Callable(i) | |
912 | 912 | func withdraw () = valueOrElse(isActive(), withdrawCalc(i, 0)) | |
913 | 913 | ||
914 | 914 | ||
915 | 915 | @Verifier(tx) | |
916 | 916 | func verify () = { | |
917 | 917 | let multiSignedByAdmins = { | |
918 | 918 | let adminPubKey1Signed = if (sigVerify(tx.bodyBytes, tx.proofs[0], adminPubKey1)) | |
919 | 919 | then 1 | |
920 | 920 | else 0 | |
921 | 921 | let adminPubKey2Signed = if (sigVerify(tx.bodyBytes, tx.proofs[1], adminPubKey2)) | |
922 | 922 | then 1 | |
923 | 923 | else 0 | |
924 | 924 | let adminPubKey3Signed = if (sigVerify(tx.bodyBytes, tx.proofs[2], adminPubKey3)) | |
925 | 925 | then 1 | |
926 | 926 | else 0 | |
927 | 927 | (((adminPubKey1Signed + adminPubKey2Signed) + adminPubKey3Signed) >= 2) | |
928 | 928 | } | |
929 | 929 | match tx { | |
930 | 930 | case inv: InvokeScriptTransaction => | |
931 | 931 | let callTakeIntoAccount = if ((inv.dApp == this)) | |
932 | 932 | then (inv.function == "takeIntoAccountExtraFunds") | |
933 | 933 | else false | |
934 | 934 | let signedByAdmin = if (if (if (sigVerify(tx.bodyBytes, tx.proofs[0], adminPubKey1)) | |
935 | 935 | then true | |
936 | 936 | else sigVerify(tx.bodyBytes, tx.proofs[0], adminPubKey2)) | |
937 | 937 | then true | |
938 | 938 | else sigVerify(tx.bodyBytes, tx.proofs[0], adminPubKey3)) | |
939 | 939 | then true | |
940 | 940 | else sigVerify(tx.bodyBytes, tx.proofs[0], adminPubKeyInvoke) | |
941 | 941 | if (if (callTakeIntoAccount) | |
942 | 942 | then signedByAdmin | |
943 | 943 | else false) | |
944 | 944 | then true | |
945 | 945 | else multiSignedByAdmins | |
946 | 946 | case _ => | |
947 | 947 | multiSignedByAdmins | |
948 | 948 | } | |
949 | 949 | } | |
950 | 950 |
github/deemru/w8io/026f985 180.88 ms ◑