tx · 5DC9irA7VoBt7GYocYGE9q6omzp6KrEAKDU6yYu2wYr5

3MvRWw2FPEimFCTGtK7qY9uAJbM7XJ4ZfJS:  -0.22000000 Waves

2023.04.18 11:34 [2539758] smart account 3MvRWw2FPEimFCTGtK7qY9uAJbM7XJ4ZfJS > SELF 0.00000000 Waves

{ "type": 13, "id": "5DC9irA7VoBt7GYocYGE9q6omzp6KrEAKDU6yYu2wYr5", "fee": 22000000, "feeAssetId": null, "timestamp": 1681806900228, "version": 2, "chainId": 84, "sender": "3MvRWw2FPEimFCTGtK7qY9uAJbM7XJ4ZfJS", "senderPublicKey": "HP8sssVq1866F7CaPQJwgFrt6fsqhQjKwM84cL1wjD2a", "proofs": [ "3ajNq8B9zjJtmjv8yf2xtDa5epcQQe5kneYYNm1aDQbYLTRHDcm6LST3F8UpsHgSirLtccnoGxEDbmJgTCuoqqCc" ], "script": "base64:BgJVCAISBQoDCAEIEgUKAwgBCBIDCgEIEgQKAggBEgMKAQgSDgoMCAgIAQQRGBgRAQEYEgoKCAgICAEECAEYEg4KDAgICAEEGBgYGBgBGBIHCgUICAEBAUEAB1NGX1BPT0wCAlNGAAdXWF9QT09MAgJXWAAHQ0FQX0ZFRQIDY2FwAAhMT0FOX0ZFRQIEbG9hbgALTk9fTE9BTl9GRUUCBm5vTG9hbgAGU0NBTEU4AIDC1y8AB1NDQUxFMTAAgMivoCUACkZFRV9TQ0FMRTYAwIQ9ABRrU0ZQb29sQUFzc2V0QmFsYW5jZQIPQV9hc3NldF9iYWxhbmNlABRrU0ZQb29sQkFzc2V0QmFsYW5jZQIPQl9hc3NldF9iYWxhbmNlAA9rU0ZQb29sQUFzc2V0SWQCCkFfYXNzZXRfaWQAD2tTRlBvb2xCQXNzZXRJZAIKQl9hc3NldF9pZAAOa1NGUG9vbFNoYXJlSWQCDnNoYXJlX2Fzc2V0X2lkAAprU0ZQb29sRmVlAgpjb21taXNzaW9uAA1rVXNlclBvc2l0aW9uAg5fdXNlcl9wb3NpdGlv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ZUVudHJ5AWkBC2luaXROZXdQb29sBQR0eXBlCHBvb2xBZGRyC2luRmVlTm9Mb2FuCWluRmVlTG9hbgZjYXBGZWUDAwkBAiE9AgUEdHlwZQUHU0ZfUE9PTAkBAiE9AgUEdHlwZQUHV1hfUE9PTAcJAAIBAgpXcm9uZyB0eXBlCQDMCAIJAQxJbnRlZ2VyRW50cnkCCQCsAgIFCHBvb2xBZGRyBRVrQXhseUluRmVlV2l0aG91dExvYW4FC2luRmVlTm9Mb2FuCQDMCAIJAQxJbnRlZ2VyRW50cnkCCQCsAgIFCHBvb2xBZGRyBRJrQXhseUluRmVlV2l0aExvYW4FCWluRmVlTG9hbgkAzAgCCQEMSW50ZWdlckVudHJ5AgkArAICBQhwb29sQWRkcgULa0F4bHlDYXBGZWUFBmNhcEZlZQkAzAgCCQEMSW50ZWdlckVudHJ5AgkArAICBQhwb29sQWRkcgUNa1Bvb2xJbnRlcmVzdAAACQDMCAIJAQtTdHJpbmdFbnRyeQIJAKwCAgUFa1Bvb2wFCHBvb2xBZGRyBQR0eXBlBQNuaWwBAnR4AQZ2ZXJpZnkACQD0AwMIBQJ0eAlib2R5Qnl0ZXMJAJEDAggFAnR4BnByb29mcwAACAUCdHgPc2VuZGVyUHVibGljS2V53calSA==", "height": 2539758, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 3gvvR1SPMCwsiHAjAJHRRptgZCShuyjJ2gpgZaVf71Y5 Next: 5icAixP2HAxx5V1Tf9LnFxQXzcPkWYG2bP9q6nB6GPG2 Diff:
OldNewDifferences
487487
488488
489489 @Callable(i)
490-func replenishREADONLY (pool,pmtA,pmtB,leverage,borrowAssetId) = if (if ((100 > leverage))
490+func replenishREADONLY (pool,leverage,borrowAssetId) = if (if ((100 > leverage))
491491 then true
492492 else (leverage > 300))
493493 then throw("Leverage can't be <100 and >300")
494494 else {
495495 let type = valueOrErrorMessage(getString(this, (kPool + pool)), "Pool is not inited")
496- let $t01644916538 = getPoolData(Address(fromBase58String(pool)), type)
497- let AId = $t01644916538._1
498- let BId = $t01644916538._2
499- let balA = $t01644916538._3
500- let balB = $t01644916538._4
501- let shareId = $t01644916538._5
502- let $t01654417222 = if ((leverage > 100))
496+ let $t01642716516 = getPoolData(Address(fromBase58String(pool)), type)
497+ let AId = $t01642716516._1
498+ let BId = $t01642716516._2
499+ let balA = $t01642716516._3
500+ let balB = $t01642716516._4
501+ let shareId = $t01642716516._5
502+ let $t01651917156 = if ((size(i.payments) == 2))
503+ then if ((assetIdToStr(i.payments[0].assetId) != AId))
504+ then throw("Wrong payment asset A")
505+ else if ((assetIdToStr(i.payments[1].assetId) != BId))
506+ then throw("Wrong payment asset B")
507+ else $Tuple4(i.payments[0].amount, AId, i.payments[1].amount, BId)
508+ else if ((size(i.payments) == 1))
509+ then if ((assetIdToStr(i.payments[0].assetId) == AId))
510+ then $Tuple4(i.payments[0].amount, AId, 0, BId)
511+ else if ((assetIdToStr(i.payments[0].assetId) == BId))
512+ then $Tuple4(0, AId, i.payments[0].amount, BId)
513+ else throw("Wrong payment")
514+ else throw("One or two payments expected")
515+ let pmtA = $t01651917156._1
516+ let pmtAssetA = $t01651917156._2
517+ let pmtB = $t01651917156._3
518+ let pmtAssetB = $t01651917156._4
519+ let $t01715917867 = if ((leverage > 100))
503520 then {
504- let dPriceA = ( let @ = invoke(priceOracleAddr, "getTWAP60", [AId, false], nil)
521+ let dPriceA = ( let @ = invoke(priceOracleAddr, "getTWAP60", [pmtAssetA, false], nil)
505522 if ($isInstanceOf(@, "(Int, Int)"))
506523 then @
507524 else throw(($getType(@) + " couldn't be cast to (Int, Int)")))._1
508- let dPriceB = ( let @ = invoke(priceOracleAddr, "getTWAP60", [BId, false], nil)
525+ let dPriceB = ( let @ = invoke(priceOracleAddr, "getTWAP60", [pmtAssetB, false], nil)
509526 if ($isInstanceOf(@, "(Int, Int)"))
510527 then @
511528 else throw(($getType(@) + " couldn't be cast to (Int, Int)")))._1
512- let paydInDollar = (fraction(dPriceA, pmtA, pow(10, 0, getAssetDecimals(AId), 0, 0, DOWN)) + fraction(dPriceB, pmtB, pow(10, 0, getAssetDecimals(BId), 0, 0, DOWN)))
529+ let paydInDollar = (fraction(dPriceA, pmtA, pow(10, 0, getAssetDecimals(pmtAssetA), 0, 0, DOWN)) + fraction(dPriceB, pmtB, pow(10, 0, getAssetDecimals(pmtAssetB), 0, 0, DOWN)))
513530 let borrowAmount = fraction(paydInDollar, (leverage - 100), 100)
514- if ((borrowAssetId == AId))
531+ if ((borrowAssetId == pmtAssetA))
515532 then $Tuple3((pmtA + borrowAmount), pmtB, LOAN_FEE)
516533 else $Tuple3(pmtA, (pmtB + borrowAmount), LOAN_FEE)
517534 }
518535 else $Tuple3(pmtA, pmtB, NO_LOAN_FEE)
519- let paymentA = $t01654417222._1
520- let paymentB = $t01654417222._2
521- let feeType = $t01654417222._3
522- let $t01722517595 = if ((type == SF_POOL))
523- then replenishSwopFi(pool, feeType, paymentA, AId, paymentB, BId, balA, balB, shareId)
524- else replenishWX(pool, feeType, pmtA, AId, pmtB, BId, shareId)
525- let userStaked = $t01722517595._1
526- let axlyFee = $t01722517595._2
536+ let paymentA = $t01715917867._1
537+ let paymentB = $t01715917867._2
538+ let feeType = $t01715917867._3
539+ let $t01787018264 = if ((type == SF_POOL))
540+ then replenishSwopFi(pool, feeType, paymentA, pmtAssetA, paymentB, pmtAssetB, balA, balB, shareId)
541+ else replenishWX(pool, feeType, pmtA, pmtAssetA, pmtB, pmtAssetB, shareId)
542+ let userStaked = $t01787018264._1
543+ let axlyFee = $t01787018264._2
527544 $Tuple2(nil, userStaked)
528545 }
529546
536553 then throw("Leverage can't be <100 and >300")
537554 else {
538555 let type = valueOrErrorMessage(getString(this, (kPool + pool)), "Pool is not inited")
539- let $t01792318012 = getPoolData(Address(fromBase58String(pool)), type)
540- let AId = $t01792318012._1
541- let BId = $t01792318012._2
542- let balA = $t01792318012._3
543- let balB = $t01792318012._4
544- let shareId = $t01792318012._5
545- let $t01801518652 = if ((size(i.payments) == 2))
556+ let $t01858918678 = getPoolData(Address(fromBase58String(pool)), type)
557+ let AId = $t01858918678._1
558+ let BId = $t01858918678._2
559+ let balA = $t01858918678._3
560+ let balB = $t01858918678._4
561+ let shareId = $t01858918678._5
562+ let $t01868119318 = if ((size(i.payments) == 2))
546563 then if ((assetIdToStr(i.payments[0].assetId) != AId))
547564 then throw("Wrong payment asset A")
548565 else if ((assetIdToStr(i.payments[1].assetId) != BId))
555572 then $Tuple4(0, AId, i.payments[0].amount, BId)
556573 else throw("Wrong payment")
557574 else throw("One or two payments expected")
558- let pmtA = $t01801518652._1
559- let pmtAssetA = $t01801518652._2
560- let pmtB = $t01801518652._3
561- let pmtAssetB = $t01801518652._4
575+ let pmtA = $t01868119318._1
576+ let pmtAssetA = $t01868119318._2
577+ let pmtB = $t01868119318._3
578+ let pmtAssetB = $t01868119318._4
562579 let newPosNum = getNewUserPositionNumber(pool, toString(i.caller))
563580 if ((leverage > 100))
564581 then {
590607 else throw("Strict value is not equal to itself.")
591608 }
592609 else {
593- let $t01999320384 = if ((type == SF_POOL))
610+ let $t02065921050 = if ((type == SF_POOL))
594611 then replenishSwopFi(pool, NO_LOAN_FEE, pmtA, pmtAssetA, pmtB, pmtAssetB, balA, balB, shareId)
595612 else replenishWX(pool, NO_LOAN_FEE, pmtA, pmtAssetA, pmtB, pmtAssetB, shareId)
596- let userStaked = $t01999320384._1
597- let axlyFee = $t01999320384._2
613+ let userStaked = $t02065921050._1
614+ let axlyFee = $t02065921050._2
598615 replenishEntries(pool, toString(i.caller), userStaked, axlyFee, newPosNum, shareId, type)
599616 }
600617 }
621638 let user = request[1]
622639 let shareId = request[9]
623640 let posNum = parseIntValue(request[12])
624- let $t02134221857 = if ((request[0] == SF_POOL))
641+ let $t02200822523 = if ((request[0] == SF_POOL))
625642 then replenishSwopFi(pool, LOAN_FEE, pmtA, request[4], pmtB, request[6], parseIntValue(request[7]), parseIntValue(request[8]), shareId)
626643 else if ((request[0] == WX_POOL))
627644 then replenishWX(pool, LOAN_FEE, pmtA, request[4], pmtB, request[6], shareId)
628645 else throw("Wrong request type")
629- let userStaked = $t02134221857._1
630- let axlyFee = $t02134221857._2
646+ let userStaked = $t02200822523._1
647+ let axlyFee = $t02200822523._2
631648 let borrowEntries = [IntegerEntry((((((request[2] + "_") + request[1]) + "_") + request[12]) + kUserBorrowAmount), i.payments[0].amount), StringEntry((((((request[2] + "_") + request[1]) + "_") + request[12]) + kUserBorrowAssetId), request[10])]
632649 let entries = replenishEntries(pool, user, userStaked, axlyFee, posNum, shareId, request[0])
633650 $Tuple2(((entries ++ borrowEntries) :+ DeleteEntry((requestId + kRequestId))), userStaked)
649666 let userAddr = Address(fromBase58String(user))
650667 let borrowAmount = getIntegerValue(this, (((((pool + "_") + user) + "_") + toString(posId)) + kUserBorrowAmount))
651668 let borrowAsset = getStringValue(this, (((((pool + "_") + user) + "_") + toString(posId)) + kUserBorrowAssetId))
652- let $t02320323303 = getPoolData(Address(fromBase58String(pool)), pType)
653- let assetIdA = $t02320323303._1
654- let assetIdB = $t02320323303._2
655- let balA = $t02320323303._3
656- let balB = $t02320323303._4
657- let shareId = $t02320323303._5
669+ let $t02386923969 = getPoolData(Address(fromBase58String(pool)), pType)
670+ let assetIdA = $t02386923969._1
671+ let assetIdB = $t02386923969._2
672+ let balA = $t02386923969._3
673+ let balB = $t02386923969._4
674+ let shareId = $t02386923969._5
658675 let cBalABefore = accountBalance(assetIdFromStr(assetIdA))
659676 if ((cBalABefore == cBalABefore))
660677 then {
670687 then {
671688 let cBalAAfter = accountBalance(assetIdFromStr(assetIdA))
672689 let cBalBAfter = accountBalance(assetIdFromStr(assetIdB))
673- let $t02381523904 = $Tuple2((cBalAAfter - cBalABefore), (cBalBAfter - cBalBBefore))
674- let tokensAmountA = $t02381523904._1
675- let tokensAmountB = $t02381523904._2
676- let $t02390724902 = if ((borrowAmount > 0))
690+ let $t02448124570 = $Tuple2((cBalAAfter - cBalABefore), (cBalBAfter - cBalBBefore))
691+ let tokensAmountA = $t02448124570._1
692+ let tokensAmountB = $t02448124570._2
693+ let $t02457325568 = if ((borrowAmount > 0))
677694 then {
678695 let debt = {
679696 let @ = invoke(getLendSrvAddr(), "getAssetDebt", [false, ((((pool + "_") + user) + "_") + toString(posId)), borrowAsset], nil)
707724 else throw("Strict value is not equal to itself.")
708725 }
709726 else $Tuple2(tokensAmountA, tokensAmountB)
710- let toUserAmountA = $t02390724902._1
711- let toUserAmountB = $t02390724902._2
727+ let toUserAmountA = $t02457325568._1
728+ let toUserAmountB = $t02457325568._2
712729 [DeleteEntry((((((pool + "_") + user) + "_") + toString(posId)) + kUserPosition)), DeleteEntry((((((pool + "_") + user) + "_") + toString(posId)) + kUserPositionInterest)), IntegerEntry((pool + kPoolTotal), (poolTotalShare - userCanWithdraw)), ScriptTransfer(userAddr, tokensAmountA, assetIdFromStr(assetIdA)), ScriptTransfer(userAddr, tokensAmountB, assetIdFromStr(assetIdB))]
713730 }
714731 else throw("Strict value is not equal to itself.")
730747
731748 @Callable(i)
732749 func capitalizeExKeeper (pool,type,tokenToId,amountToExchange,claim,amountsIn,addresses,assetsToReceive,estReceived,slippageTolerance,minReceived,options) = {
733- let $t02601126205 = if (claim)
750+ let $t02667726871 = if (claim)
734751 then claimFarmed(type, pool)
735752 else {
736753 let claimedAsset = if ((type == SF_POOL))
738755 else WXID
739756 $Tuple2(amountToExchange, claimedAsset)
740757 }
741- let claimedAmount = $t02601126205._1
742- let claimedAsset = $t02601126205._2
758+ let claimedAmount = $t02667726871._1
759+ let claimedAsset = $t02667726871._2
743760 let exchangedAmount = exchangeKeeper(tokenToId, amountToExchange, claimedAsset, amountsIn, addresses, assetsToReceive, estReceived, slippageTolerance, minReceived, options)
744761 let change = (claimedAmount - amountToExchange)
745762 let changeEntry = if ((change > 0))
752769
753770 @Callable(i)
754771 func capitalizeExPazzle (pool,type,tokenToId,amountToExchange,claim,routesStr,minToReceive,options) = {
755- let $t02686127055 = if (claim)
772+ let $t02752727721 = if (claim)
756773 then claimFarmed(type, pool)
757774 else {
758775 let claimedAsset = if ((type == SF_POOL))
760777 else WXID
761778 $Tuple2(amountToExchange, claimedAsset)
762779 }
763- let claimedAmount = $t02686127055._1
764- let claimedAsset = $t02686127055._2
780+ let claimedAmount = $t02752727721._1
781+ let claimedAsset = $t02752727721._2
765782 let exchangedAmount = exchangePazzle(tokenToId, amountToExchange, claimedAsset, routesStr, minToReceive, options)
766783 let change = (claimedAmount - amountToExchange)
767784 let changeEntry = if ((change > 0))
774791
775792 @Callable(i)
776793 func capitalizeExSwopFi (pool,type,tokenToId,amountToExchange,claim,exchangers,exchangersType,args1,args2,routingAssetsKeys,minAmountToReceive,options) = {
777- let $t02777827972 = if (claim)
794+ let $t02844428638 = if (claim)
778795 then claimFarmed(type, pool)
779796 else {
780797 let claimedAsset = if ((type == SF_POOL))
782799 else WXID
783800 $Tuple2(amountToExchange, claimedAsset)
784801 }
785- let claimedAmount = $t02777827972._1
786- let claimedAsset = $t02777827972._2
802+ let claimedAmount = $t02844428638._1
803+ let claimedAsset = $t02844428638._2
787804 let exchangedAmount = exchangeSwopFi(tokenToId, amountToExchange, claimedAsset, exchangers, exchangersType, args1, args2, routingAssetsKeys, minAmountToReceive, options)
788805 let change = (claimedAmount - amountToExchange)
789806 let changeEntry = if ((change > 0))
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 6 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let SF_POOL = "SF"
55
66 let WX_POOL = "WX"
77
88 let CAP_FEE = "cap"
99
1010 let LOAN_FEE = "loan"
1111
1212 let NO_LOAN_FEE = "noLoan"
1313
1414 let SCALE8 = 100000000
1515
1616 let SCALE10 = 10000000000
1717
1818 let FEE_SCALE6 = 1000000
1919
2020 let kSFPoolAAssetBalance = "A_asset_balance"
2121
2222 let kSFPoolBAssetBalance = "B_asset_balance"
2323
2424 let kSFPoolAAssetId = "A_asset_id"
2525
2626 let kSFPoolBAssetId = "B_asset_id"
2727
2828 let kSFPoolShareId = "share_asset_id"
2929
3030 let kSFPoolFee = "commission"
3131
3232 let kUserPosition = "_user_position"
3333
3434 let kUserBorrowAmount = "_user_position_borrow_amount"
3535
3636 let kUserBorrowAssetId = "_user_position_borrow_asset_id"
3737
3838 let kUserPositionNum = "_user_position_number"
3939
4040 let kUserPositionInterest = "_user_position_interest"
4141
4242 let kPoolTotal = "_pool_total"
4343
4444 let kPoolInterest = "_pool_interest"
4545
4646 let kAxlyInFeeWithoutLoan = "_axly_fee_without_loan"
4747
4848 let kAxlyInFeeWithLoan = "_axly_fee_with_loan"
4949
5050 let kAxlyCapFee = "_axly_fee_cap"
5151
5252 let kRequestId = "_request_id"
5353
5454 let kRequestIter = "requests_iter"
5555
5656 let kPool = "pool_"
5757
5858 let kPoolCapChange = "_pool_cap_change"
5959
6060 let kMoneyBox = "axly_money_box"
6161
6262 let kSFFarmingAddr = "swopfi_farming_addr"
6363
6464 let kLendService = "lend_service_addr"
6565
6666 let kPriceOracle = "price_oracle"
6767
6868 let kExContract = "exchange_contract"
6969
7070 let kWxSwapContract = "wx_swap_contract"
7171
7272 let moneyBox = Address(fromBase58String(valueOrErrorMessage(getString(this, kMoneyBox), "No axly moneyBox address")))
7373
7474 let exContract = Address(fromBase58String(valueOrErrorMessage(getString(this, kExContract), "No exchange contract address")))
7575
7676 let priceOracleAddr = Address(fromBase58String(valueOrErrorMessage(getString(this, kPriceOracle), "No price oracle address")))
7777
7878 let wxSwapContract = Address(fromBase58String(valueOrErrorMessage(getString(this, kWxSwapContract), "No wx swap address")))
7979
8080 let SWOPID = base58'4W19ndijcc2CsQa9HGW2dfXKTVXhnneWWttxXrtjPmEp'
8181
8282 let WXID = base58'EMAMLxDnv3xiz8RXg8Btj33jcEw3wLczL3JKYYmuubpc'
8383
8484 func isSelfCall (i) = if ((i.caller == this))
8585 then unit
8686 else throw("Only contract itself can call this function")
8787
8888
8989 func accountBalance (assetId) = match assetId {
9090 case id: ByteVector =>
9191 assetBalance(this, id)
9292 case waves: Unit =>
9393 wavesBalance(this).available
9494 case _ =>
9595 throw("Match error")
9696 }
9797
9898
9999 func getSFPoolData (poolAddr) = $Tuple5(valueOrErrorMessage(getString(poolAddr, kSFPoolAAssetId), "Can't get pool A asset id"), valueOrErrorMessage(getString(poolAddr, kSFPoolBAssetId), "Can't get pool B asset id"), valueOrErrorMessage(getInteger(poolAddr, kSFPoolAAssetBalance), "Can't get pool A asset balance"), valueOrErrorMessage(getInteger(poolAddr, kSFPoolBAssetBalance), "Can't get pool B asset balance"), valueOrErrorMessage(getString(poolAddr, kSFPoolShareId), "Can't get share asset id"))
100100
101101
102102 func getWXPoolData (poolAddr) = {
103103 let cfg = {
104104 let @ = invoke(poolAddr, "getPoolConfigWrapperREADONLY", nil, nil)
105105 if ($isInstanceOf(@, "List[Any]"))
106106 then @
107107 else throw(($getType(@) + " couldn't be cast to List[Any]"))
108108 }
109109 if ((cfg == cfg))
110110 then $Tuple5(valueOrErrorMessage({
111111 let @ = cfg[4]
112112 if ($isInstanceOf(@, "String"))
113113 then @
114114 else unit
115115 }, "Can't get pool A asset id"), valueOrErrorMessage({
116116 let @ = cfg[5]
117117 if ($isInstanceOf(@, "String"))
118118 then @
119119 else unit
120120 }, "Can't get pool B asset id"), 0, 0, valueOrErrorMessage({
121121 let @ = cfg[3]
122122 if ($isInstanceOf(@, "String"))
123123 then @
124124 else unit
125125 }, "Can't get pool LP asset id"))
126126 else throw("Strict value is not equal to itself.")
127127 }
128128
129129
130130 func getPoolData (poolAddr,type) = if ((type == SF_POOL))
131131 then getSFPoolData(poolAddr)
132132 else if ((type == WX_POOL))
133133 then getWXPoolData(poolAddr)
134134 else throw("Wrong pool type")
135135
136136
137137 func getPoolTotalShare (pool) = valueOrElse(getInteger(this, (pool + kPoolTotal)), 0)
138138
139139
140140 func getNewUserPositionNumber (pool,user) = (valueOrElse(getInteger(this, (((pool + "_") + user) + kUserPositionNum)), 0) + 1)
141141
142142
143143 func getAxlyFee (pool,feeType) = if ((feeType == "cap"))
144144 then getIntegerValue(this, (pool + kAxlyCapFee))
145145 else if ((feeType == "loan"))
146146 then getIntegerValue(this, (pool + kAxlyInFeeWithLoan))
147147 else if ((feeType == "noLoan"))
148148 then getIntegerValue(this, (pool + kAxlyInFeeWithoutLoan))
149149 else throw("Wrong fee type")
150150
151151
152152 func getSFFarmingAddr () = Address(fromBase58String(valueOrErrorMessage(getString(this, kSFFarmingAddr), "Can't get swopfi farming addr")))
153153
154154
155155 func getWXFarmingAddr (poolAddr) = {
156156 let fContract = Address(fromBase58String(valueOrErrorMessage(getString(poolAddr, "%s__factoryContract"), "Can't get WX factory contract addr")))
157157 let factroyCfg = split(valueOrErrorMessage(getString(fContract, "%s__factoryConfig"), "Can't get WX factory cfg"), "__")
158158 Address(fromBase58String(factroyCfg[1]))
159159 }
160160
161161
162162 func getLendSrvAddr () = Address(fromBase58String(valueOrErrorMessage(getString(this, kLendService), "Can't get lend service addr")))
163163
164164
165165 func assetIdToStr (assetId) = match assetId {
166166 case id: ByteVector =>
167167 toBase58String(id)
168168 case waves: Unit =>
169169 "WAVES"
170170 case _ =>
171171 throw("Match error")
172172 }
173173
174174
175175 func assetIdFromStr (assetId) = if ((assetId == "WAVES"))
176176 then unit
177177 else fromBase58String(assetId)
178178
179179
180180 func getAssetDecimals (assetId) = if ((assetId == "WAVES"))
181181 then 8
182182 else match assetInfo(fromBase58String(assetId)) {
183183 case asset: Asset =>
184184 asset.decimals
185185 case _ =>
186186 throw("Can't find asset")
187187 }
188188
189189
190190 func replenishSwopFi (pool,feeType,pmtA,pmtAssetA,pmtB,pmtAssetB,balA,balB,shareId) = {
191191 let shareBalanceBefore = accountBalance(fromBase58String(shareId))
192192 if ((shareBalanceBefore == shareBalanceBefore))
193193 then {
194194 let poolAddr = Address(fromBase58String(pool))
195195 let ratioA = fraction(SCALE8, pmtA, balA)
196196 let ratioB = fraction(SCALE8, pmtB, balB)
197197 let $t063976689 = if ((ratioB > ratioA))
198198 then {
199199 let pmt = fraction(balB, ratioA, SCALE8, CEILING)
200200 $Tuple4(pmtA, pmt, (pmtB - pmt), pmtAssetB)
201201 }
202202 else {
203203 let pmt = fraction(balA, ratioB, SCALE8, CEILING)
204204 $Tuple4(pmt, pmtB, (pmtA - pmt), pmtAssetA)
205205 }
206206 let pmtAmountA = $t063976689._1
207207 let pmtAmountB = $t063976689._2
208208 let change = $t063976689._3
209209 let changeAssetId = $t063976689._4
210210 let inv1 = if (if ((pmtAmountA > 0))
211211 then (pmtAmountB > 0)
212212 else false)
213213 then {
214214 let payments = [AttachedPayment(assetIdFromStr(pmtAssetA), pmtAmountA), AttachedPayment(assetIdFromStr(pmtAssetB), pmtAmountB)]
215215 invoke(poolAddr, "callFunction", ["replenishWithTwoTokens", ["false", "0"]], payments)
216216 }
217217 else 0
218218 if ((inv1 == inv1))
219219 then {
220220 let inv2 = if ((change > 0))
221221 then {
222222 let payments = [AttachedPayment(assetIdFromStr(changeAssetId), change)]
223223 let vars = ["0", "false", "0"]
224224 invoke(poolAddr, "callFunction", ["replenishWithOneToken", vars], payments)
225225 }
226226 else 0
227227 if ((inv2 == inv2))
228228 then {
229229 let shareBalanceAfter = accountBalance(fromBase58String(shareId))
230230 let totalStaked = (shareBalanceAfter - shareBalanceBefore)
231231 let axlyFeeAmount = fraction(totalStaked, getAxlyFee(pool, feeType), FEE_SCALE6)
232232 let userShareForStake = (totalStaked - axlyFeeAmount)
233233 if ((0 >= userShareForStake))
234234 then throw("amount of staked sharetokens must be > 0")
235235 else {
236236 let inv3 = invoke(getSFFarmingAddr(), "lockShareTokens", [pool, 0], [AttachedPayment(fromBase58String(shareId), userShareForStake)])
237237 if ((inv3 == inv3))
238238 then $Tuple2(userShareForStake, axlyFeeAmount)
239239 else throw("Strict value is not equal to itself.")
240240 }
241241 }
242242 else throw("Strict value is not equal to itself.")
243243 }
244244 else throw("Strict value is not equal to itself.")
245245 }
246246 else throw("Strict value is not equal to itself.")
247247 }
248248
249249
250250 func replenishWX (pool,feeType,pmtA,pmtAssetA,pmtB,pmtAssetB,shareId) = {
251251 let poolAddr = Address(fromBase58String(pool))
252252 let $t081408989 = if (if ((pmtA > 0))
253253 then (pmtB > 0)
254254 else false)
255255 then {
256256 let evalPutInA = split({
257257 let @ = invoke(poolAddr, "evaluatePutByAmountAssetREADONLY", [pmtA], nil)
258258 if ($isInstanceOf(@, "String"))
259259 then @
260260 else throw(($getType(@) + " couldn't be cast to String"))
261261 }, "__")
262262 if ((evalPutInA == evalPutInA))
263263 then {
264264 let evalPutInB = split({
265265 let @ = invoke(poolAddr, "evaluatePutByPriceAssetREADONLY", [pmtB], nil)
266266 if ($isInstanceOf(@, "String"))
267267 then @
268268 else throw(($getType(@) + " couldn't be cast to String"))
269269 }, "__")
270270 if ((evalPutInB == evalPutInB))
271271 then {
272272 let lpInA = parseIntValue(evalPutInA[1])
273273 let lpInB = parseIntValue(evalPutInB[1])
274274 if ((lpInB > lpInA))
275275 then {
276276 let pmtInB = parseIntValue(evalPutInA[8])
277277 $Tuple4(pmtA, pmtInB, (pmtB - pmtInB), pmtAssetB)
278278 }
279279 else {
280280 let pmtInA = parseIntValue(evalPutInB[7])
281281 $Tuple4(pmtInA, pmtB, (pmtA - pmtInA), pmtAssetA)
282282 }
283283 }
284284 else throw("Strict value is not equal to itself.")
285285 }
286286 else throw("Strict value is not equal to itself.")
287287 }
288288 else if ((pmtA > 0))
289289 then $Tuple4(pmtA, pmtB, pmtA, pmtAssetA)
290290 else if ((pmtB > 0))
291291 then $Tuple4(pmtA, pmtB, pmtB, pmtAssetB)
292292 else throw("pmts must be > 0")
293293 let pmtAmountA = $t081408989._1
294294 let pmtAmountB = $t081408989._2
295295 let change = $t081408989._3
296296 let changeAssetId = $t081408989._4
297297 let shareBalanceBefore = accountBalance(fromBase58String(shareId))
298298 if ((shareBalanceBefore == shareBalanceBefore))
299299 then {
300300 let inv1 = if (if ((pmtAmountA > 0))
301301 then (pmtAmountB > 0)
302302 else false)
303303 then {
304304 let payments = [AttachedPayment(assetIdFromStr(pmtAssetA), pmtAmountA), AttachedPayment(assetIdFromStr(pmtAssetB), pmtAmountB)]
305305 invoke(poolAddr, "put", [1000000, false], payments)
306306 }
307307 else 0
308308 if ((inv1 == inv1))
309309 then {
310310 let inv2 = if ((change > 0))
311311 then {
312312 let payments = [AttachedPayment(assetIdFromStr(changeAssetId), change)]
313313 invoke(poolAddr, "putOneTkn", [0, false], payments)
314314 }
315315 else 0
316316 if ((inv2 == inv2))
317317 then {
318318 let shareBalanceAfter = accountBalance(fromBase58String(shareId))
319319 let totalStaked = (shareBalanceAfter - shareBalanceBefore)
320320 let axlyFeeAmount = fraction(totalStaked, getAxlyFee(pool, feeType), FEE_SCALE6)
321321 let userShareForStake = (totalStaked - axlyFeeAmount)
322322 if ((0 >= userShareForStake))
323323 then throw("amount of staked sharetokens must be > 0")
324324 else {
325325 let inv3 = invoke(getWXFarmingAddr(poolAddr), "stake", nil, [AttachedPayment(fromBase58String(shareId), userShareForStake)])
326326 if ((inv3 == inv3))
327327 then $Tuple2(userShareForStake, axlyFeeAmount)
328328 else throw("Strict value is not equal to itself.")
329329 }
330330 }
331331 else throw("Strict value is not equal to itself.")
332332 }
333333 else throw("Strict value is not equal to itself.")
334334 }
335335 else throw("Strict value is not equal to itself.")
336336 }
337337
338338
339339 func replenishEntries (pool,user,stakedAmount,axlyFeeAmount,posNum,shareId,type) = {
340340 let totalAmount = getPoolTotalShare(pool)
341341 let curPoolInterest = getIntegerValue(this, (pool + kPoolInterest))
342342 [IntegerEntry((pool + kPoolTotal), (totalAmount + stakedAmount)), IntegerEntry((((((pool + "_") + user) + "_") + toString(posNum)) + kUserPosition), stakedAmount), IntegerEntry((((((pool + "_") + user) + "_") + toString(posNum)) + kUserPositionInterest), curPoolInterest), IntegerEntry((((pool + "_") + user) + kUserPositionNum), posNum), ScriptTransfer(moneyBox, axlyFeeAmount, fromBase58String(shareId))]
343343 }
344344
345345
346346 func claimFarmed (type,pool) = if ((type == SF_POOL))
347347 then {
348348 let balBefore = accountBalance(SWOPID)
349349 if ((balBefore == balBefore))
350350 then {
351351 let inv = invoke(getSFFarmingAddr(), "claim", [pool], nil)
352352 if ((inv == inv))
353353 then {
354354 let balAfter = accountBalance(SWOPID)
355355 $Tuple2((balAfter - balBefore), SWOPID)
356356 }
357357 else throw("Strict value is not equal to itself.")
358358 }
359359 else throw("Strict value is not equal to itself.")
360360 }
361361 else if ((type == WX_POOL))
362362 then {
363363 let balBefore = accountBalance(WXID)
364364 if ((balBefore == balBefore))
365365 then {
366366 let inv = invoke(getWXFarmingAddr(Address(fromBase58String(pool))), "claimWX", [pool], nil)
367367 if ((inv == inv))
368368 then {
369369 let balAfter = accountBalance(WXID)
370370 $Tuple2((balAfter - balBefore), WXID)
371371 }
372372 else throw("Strict value is not equal to itself.")
373373 }
374374 else throw("Strict value is not equal to itself.")
375375 }
376376 else throw("Wrong pool type")
377377
378378
379379 func exchangeKeeper (toToken,pmtAmount,pmtAsset,amountsIn,addresses,assetsToReceive,estReceived,slippageTolerance,minReceived,options) = {
380380 let tokenBalanceBefore = accountBalance(assetIdFromStr(toToken))
381381 if ((tokenBalanceBefore == tokenBalanceBefore))
382382 then {
383383 let inv = invoke(exContract, "swap", [amountsIn, addresses, assetsToReceive, estReceived, slippageTolerance, minReceived, options], [AttachedPayment(pmtAsset, pmtAmount)])
384384 if ((inv == inv))
385385 then (accountBalance(assetIdFromStr(toToken)) - tokenBalanceBefore)
386386 else throw("Strict value is not equal to itself.")
387387 }
388388 else throw("Strict value is not equal to itself.")
389389 }
390390
391391
392392 func exchangePazzle (toToken,pmtAmount,pmtAsset,routesStr,minToReceive,options) = {
393393 let tokenBalanceBefore = accountBalance(assetIdFromStr(toToken))
394394 if ((tokenBalanceBefore == tokenBalanceBefore))
395395 then {
396396 let inv = invoke(exContract, "puzzleSwap", [routesStr, minToReceive, options], [AttachedPayment(pmtAsset, pmtAmount)])
397397 if ((inv == inv))
398398 then (accountBalance(assetIdFromStr(toToken)) - tokenBalanceBefore)
399399 else throw("Strict value is not equal to itself.")
400400 }
401401 else throw("Strict value is not equal to itself.")
402402 }
403403
404404
405405 func exchangeSwopFi (toToken,pmtAmount,pmtAsset,exchangers,exchangersType,args1,args2,routingAssetsKeys,minAmountToReceive,options) = {
406406 let tokenBalanceBefore = accountBalance(assetIdFromStr(toToken))
407407 if ((tokenBalanceBefore == tokenBalanceBefore))
408408 then {
409409 let inv = invoke(exContract, "swopfiSwap", [exchangers, exchangersType, args1, args2, routingAssetsKeys, minAmountToReceive, options], [AttachedPayment(pmtAsset, pmtAmount)])
410410 if ((inv == inv))
411411 then (accountBalance(assetIdFromStr(toToken)) - tokenBalanceBefore)
412412 else throw("Strict value is not equal to itself.")
413413 }
414414 else throw("Strict value is not equal to itself.")
415415 }
416416
417417
418418 func capitalize (pool,type,tokenId,tokenAmount) = {
419419 let poolAddr = Address(fromBase58String(pool))
420420 let $t01319013268 = getPoolData(poolAddr, type)
421421 let AId = $t01319013268._1
422422 let BId = $t01319013268._2
423423 let balA = $t01319013268._3
424424 let balB = $t01319013268._4
425425 let shareId = $t01319013268._5
426426 let $t01327113351 = if ((tokenId == AId))
427427 then $Tuple2(tokenAmount, 0)
428428 else $Tuple2(0, tokenAmount)
429429 let pmtA = $t01327113351._1
430430 let pmtB = $t01327113351._2
431431 let $t01335413715 = if ((type == SF_POOL))
432432 then replenishSwopFi(pool, CAP_FEE, pmtA, AId, pmtB, BId, balA, balB, shareId)
433433 else replenishWX(pool, CAP_FEE, pmtA, AId, pmtB, BId, shareId)
434434 let stakedAmount = $t01335413715._1
435435 let axlyFee = $t01335413715._2
436436 let curPoolInterest = valueOrElse(getInteger(this, (pool + kPoolInterest)), 0)
437437 let totalShareAmount = getPoolTotalShare(pool)
438438 let newInterest = (curPoolInterest + fraction(stakedAmount, SCALE10, totalShareAmount))
439439 [IntegerEntry((pool + kPoolInterest), newInterest), ScriptTransfer(moneyBox, axlyFee, fromBase58String(shareId))]
440440 }
441441
442442
443443 func exchangeDirectlySF (pool,assetIdA,assetIdB,balA,balB,amountTokenToGet,assetTokenToGet) = {
444444 let poolAddr = Address(fromBase58String(pool))
445445 let feeScale6 = 1000000
446446 let fee = getIntegerValue(poolAddr, kSFPoolFee)
447447 let amntGetNoFee = fraction(amountTokenToGet, feeScale6, (feeScale6 - fee))
448448 let $t01440814696 = if ((assetTokenToGet == assetIdA))
449449 then {
450450 let amountToPay = fraction(balA, amntGetNoFee, (balB - amntGetNoFee))
451451 $Tuple2(amountToPay, assetIdB)
452452 }
453453 else {
454454 let amountToPay = fraction(balB, amntGetNoFee, (balA - amntGetNoFee))
455455 $Tuple2(amountToPay, assetIdA)
456456 }
457457 let amountToPay = $t01440814696._1
458458 let assetToPay = $t01440814696._2
459459 invoke(poolAddr, "callFunction", ["exchange", "1"], [AttachedPayment(assetIdFromStr(assetToPay), amountToPay)])
460460 }
461461
462462
463463 func exchangeDirectlyWX (pool,assetIdA,assetIdB,balA,balB,amountTokenToGet,assetTokenToGet) = {
464464 let poolAddr = Address(fromBase58String(pool))
465465 let prFee = getIntegerValue(wxSwapContract, "%s__protocolFee")
466466 let pFee = getIntegerValue(wxSwapContract, "%s__poolFee")
467467 let feeScale = toBigInt(100000000)
468468 let $t01517315481 = if ((assetTokenToGet == assetIdA))
469469 then {
470470 let amountToPay = fraction(balA, amountTokenToGet, (balB - amountTokenToGet))
471471 $Tuple2(amountToPay, assetIdB)
472472 }
473473 else {
474474 let amountToPay = fraction(balB, amountTokenToGet, (balA - amountTokenToGet))
475475 $Tuple2(amountToPay, assetIdA)
476476 }
477477 let amountToPay = $t01517315481._1
478478 let assetToPay = $t01517315481._2
479479 let amountToPayWithFee = toInt(fraction(toBigInt(amountToPay), feeScale, (feeScale - toBigInt((prFee + pFee)))))
480480 invoke(wxSwapContract, "swap", [1, assetTokenToGet, toString(this)], [AttachedPayment(assetIdFromStr(assetToPay), amountToPayWithFee)])
481481 }
482482
483483
484484 func exchangeDirectly (type,pool,assetIdA,assetIdB,balA,balB,amountTokenToGet,assetTokenToGet) = if ((type == SF_POOL))
485485 then exchangeDirectlySF(pool, assetIdA, assetIdB, balA, balB, amountTokenToGet, assetTokenToGet)
486486 else exchangeDirectlyWX(pool, assetIdA, assetIdB, balA, balB, amountTokenToGet, assetTokenToGet)
487487
488488
489489 @Callable(i)
490-func replenishREADONLY (pool,pmtA,pmtB,leverage,borrowAssetId) = if (if ((100 > leverage))
490+func replenishREADONLY (pool,leverage,borrowAssetId) = if (if ((100 > leverage))
491491 then true
492492 else (leverage > 300))
493493 then throw("Leverage can't be <100 and >300")
494494 else {
495495 let type = valueOrErrorMessage(getString(this, (kPool + pool)), "Pool is not inited")
496- let $t01644916538 = getPoolData(Address(fromBase58String(pool)), type)
497- let AId = $t01644916538._1
498- let BId = $t01644916538._2
499- let balA = $t01644916538._3
500- let balB = $t01644916538._4
501- let shareId = $t01644916538._5
502- let $t01654417222 = if ((leverage > 100))
496+ let $t01642716516 = getPoolData(Address(fromBase58String(pool)), type)
497+ let AId = $t01642716516._1
498+ let BId = $t01642716516._2
499+ let balA = $t01642716516._3
500+ let balB = $t01642716516._4
501+ let shareId = $t01642716516._5
502+ let $t01651917156 = if ((size(i.payments) == 2))
503+ then if ((assetIdToStr(i.payments[0].assetId) != AId))
504+ then throw("Wrong payment asset A")
505+ else if ((assetIdToStr(i.payments[1].assetId) != BId))
506+ then throw("Wrong payment asset B")
507+ else $Tuple4(i.payments[0].amount, AId, i.payments[1].amount, BId)
508+ else if ((size(i.payments) == 1))
509+ then if ((assetIdToStr(i.payments[0].assetId) == AId))
510+ then $Tuple4(i.payments[0].amount, AId, 0, BId)
511+ else if ((assetIdToStr(i.payments[0].assetId) == BId))
512+ then $Tuple4(0, AId, i.payments[0].amount, BId)
513+ else throw("Wrong payment")
514+ else throw("One or two payments expected")
515+ let pmtA = $t01651917156._1
516+ let pmtAssetA = $t01651917156._2
517+ let pmtB = $t01651917156._3
518+ let pmtAssetB = $t01651917156._4
519+ let $t01715917867 = if ((leverage > 100))
503520 then {
504- let dPriceA = ( let @ = invoke(priceOracleAddr, "getTWAP60", [AId, false], nil)
521+ let dPriceA = ( let @ = invoke(priceOracleAddr, "getTWAP60", [pmtAssetA, false], nil)
505522 if ($isInstanceOf(@, "(Int, Int)"))
506523 then @
507524 else throw(($getType(@) + " couldn't be cast to (Int, Int)")))._1
508- let dPriceB = ( let @ = invoke(priceOracleAddr, "getTWAP60", [BId, false], nil)
525+ let dPriceB = ( let @ = invoke(priceOracleAddr, "getTWAP60", [pmtAssetB, false], nil)
509526 if ($isInstanceOf(@, "(Int, Int)"))
510527 then @
511528 else throw(($getType(@) + " couldn't be cast to (Int, Int)")))._1
512- let paydInDollar = (fraction(dPriceA, pmtA, pow(10, 0, getAssetDecimals(AId), 0, 0, DOWN)) + fraction(dPriceB, pmtB, pow(10, 0, getAssetDecimals(BId), 0, 0, DOWN)))
529+ let paydInDollar = (fraction(dPriceA, pmtA, pow(10, 0, getAssetDecimals(pmtAssetA), 0, 0, DOWN)) + fraction(dPriceB, pmtB, pow(10, 0, getAssetDecimals(pmtAssetB), 0, 0, DOWN)))
513530 let borrowAmount = fraction(paydInDollar, (leverage - 100), 100)
514- if ((borrowAssetId == AId))
531+ if ((borrowAssetId == pmtAssetA))
515532 then $Tuple3((pmtA + borrowAmount), pmtB, LOAN_FEE)
516533 else $Tuple3(pmtA, (pmtB + borrowAmount), LOAN_FEE)
517534 }
518535 else $Tuple3(pmtA, pmtB, NO_LOAN_FEE)
519- let paymentA = $t01654417222._1
520- let paymentB = $t01654417222._2
521- let feeType = $t01654417222._3
522- let $t01722517595 = if ((type == SF_POOL))
523- then replenishSwopFi(pool, feeType, paymentA, AId, paymentB, BId, balA, balB, shareId)
524- else replenishWX(pool, feeType, pmtA, AId, pmtB, BId, shareId)
525- let userStaked = $t01722517595._1
526- let axlyFee = $t01722517595._2
536+ let paymentA = $t01715917867._1
537+ let paymentB = $t01715917867._2
538+ let feeType = $t01715917867._3
539+ let $t01787018264 = if ((type == SF_POOL))
540+ then replenishSwopFi(pool, feeType, paymentA, pmtAssetA, paymentB, pmtAssetB, balA, balB, shareId)
541+ else replenishWX(pool, feeType, pmtA, pmtAssetA, pmtB, pmtAssetB, shareId)
542+ let userStaked = $t01787018264._1
543+ let axlyFee = $t01787018264._2
527544 $Tuple2(nil, userStaked)
528545 }
529546
530547
531548
532549 @Callable(i)
533550 func replenish (pool,leverage,borrowAssetId) = if (if ((100 > leverage))
534551 then true
535552 else (leverage > 300))
536553 then throw("Leverage can't be <100 and >300")
537554 else {
538555 let type = valueOrErrorMessage(getString(this, (kPool + pool)), "Pool is not inited")
539- let $t01792318012 = getPoolData(Address(fromBase58String(pool)), type)
540- let AId = $t01792318012._1
541- let BId = $t01792318012._2
542- let balA = $t01792318012._3
543- let balB = $t01792318012._4
544- let shareId = $t01792318012._5
545- let $t01801518652 = if ((size(i.payments) == 2))
556+ let $t01858918678 = getPoolData(Address(fromBase58String(pool)), type)
557+ let AId = $t01858918678._1
558+ let BId = $t01858918678._2
559+ let balA = $t01858918678._3
560+ let balB = $t01858918678._4
561+ let shareId = $t01858918678._5
562+ let $t01868119318 = if ((size(i.payments) == 2))
546563 then if ((assetIdToStr(i.payments[0].assetId) != AId))
547564 then throw("Wrong payment asset A")
548565 else if ((assetIdToStr(i.payments[1].assetId) != BId))
549566 then throw("Wrong payment asset B")
550567 else $Tuple4(i.payments[0].amount, AId, i.payments[1].amount, BId)
551568 else if ((size(i.payments) == 1))
552569 then if ((assetIdToStr(i.payments[0].assetId) == AId))
553570 then $Tuple4(i.payments[0].amount, AId, 0, BId)
554571 else if ((assetIdToStr(i.payments[0].assetId) == BId))
555572 then $Tuple4(0, AId, i.payments[0].amount, BId)
556573 else throw("Wrong payment")
557574 else throw("One or two payments expected")
558- let pmtA = $t01801518652._1
559- let pmtAssetA = $t01801518652._2
560- let pmtB = $t01801518652._3
561- let pmtAssetB = $t01801518652._4
575+ let pmtA = $t01868119318._1
576+ let pmtAssetA = $t01868119318._2
577+ let pmtB = $t01868119318._3
578+ let pmtAssetB = $t01868119318._4
562579 let newPosNum = getNewUserPositionNumber(pool, toString(i.caller))
563580 if ((leverage > 100))
564581 then {
565582 let dPriceA = ( let @ = invoke(priceOracleAddr, "getTWAP60", [pmtAssetA, false], nil)
566583 if ($isInstanceOf(@, "(Int, Int)"))
567584 then @
568585 else throw(($getType(@) + " couldn't be cast to (Int, Int)")))._1
569586 let dPriceB = ( let @ = invoke(priceOracleAddr, "getTWAP60", [pmtAssetB, false], nil)
570587 if ($isInstanceOf(@, "(Int, Int)"))
571588 then @
572589 else throw(($getType(@) + " couldn't be cast to (Int, Int)")))._1
573590 let paydInDollar = (fraction(dPriceA, pmtA, pow(10, 0, getAssetDecimals(pmtAssetA), 0, 0, DOWN)) + fraction(dPriceB, pmtB, pow(10, 0, getAssetDecimals(pmtAssetB), 0, 0, DOWN)))
574591 let borrowAmount = fraction(paydInDollar, (leverage - 100), 100)
575592 let request = makeString([type, toString(i.caller), pool, toString(pmtA), pmtAssetA, toString(pmtB), pmtAssetB, toString(balA), toString(balB), shareId, borrowAssetId, toString(borrowAmount), toString(newPosNum)], ",")
576593 let newRequestId = {
577594 let @ = invoke(this, "createNewRequest", [request], nil)
578595 if ($isInstanceOf(@, "Int"))
579596 then @
580597 else throw(($getType(@) + " couldn't be cast to Int"))
581598 }
582599 if ((newRequestId == newRequestId))
583600 then {
584601 let args = [((toString(i.caller) + "_") + toString(newPosNum)), shareId, borrowAssetId, borrowAmount, toString(this), "replenishFromLand", toString(valueOrErrorMessage(newRequestId, "Can't create new request"))]
585602 let inv = reentrantInvoke(getLendSrvAddr(), "flashPosition", args, nil)
586603 if ((inv == inv))
587604 then nil
588605 else throw("Strict value is not equal to itself.")
589606 }
590607 else throw("Strict value is not equal to itself.")
591608 }
592609 else {
593- let $t01999320384 = if ((type == SF_POOL))
610+ let $t02065921050 = if ((type == SF_POOL))
594611 then replenishSwopFi(pool, NO_LOAN_FEE, pmtA, pmtAssetA, pmtB, pmtAssetB, balA, balB, shareId)
595612 else replenishWX(pool, NO_LOAN_FEE, pmtA, pmtAssetA, pmtB, pmtAssetB, shareId)
596- let userStaked = $t01999320384._1
597- let axlyFee = $t01999320384._2
613+ let userStaked = $t02065921050._1
614+ let axlyFee = $t02065921050._2
598615 replenishEntries(pool, toString(i.caller), userStaked, axlyFee, newPosNum, shareId, type)
599616 }
600617 }
601618
602619
603620
604621 @Callable(i)
605622 func replenishFromLand (requestId) = {
606623 let request = split(valueOrErrorMessage(getString(this, (requestId + kRequestId)), ("No request with id " + requestId)), ",")
607624 if ((size(i.payments) != 1))
608625 then throw("Wrong payment size")
609626 else if (if ((assetIdToStr(i.payments[0].assetId) != request[10]))
610627 then true
611628 else (i.payments[0].amount != parseIntValue(request[11])))
612629 then throw("Wrong payment")
613630 else {
614631 let pmtA = if ((request[4] == assetIdToStr(i.payments[0].assetId)))
615632 then (parseIntValue(request[3]) + i.payments[0].amount)
616633 else parseIntValue(request[3])
617634 let pmtB = if ((request[6] == assetIdToStr(i.payments[0].assetId)))
618635 then (parseIntValue(request[5]) + i.payments[0].amount)
619636 else parseIntValue(request[3])
620637 let pool = request[2]
621638 let user = request[1]
622639 let shareId = request[9]
623640 let posNum = parseIntValue(request[12])
624- let $t02134221857 = if ((request[0] == SF_POOL))
641+ let $t02200822523 = if ((request[0] == SF_POOL))
625642 then replenishSwopFi(pool, LOAN_FEE, pmtA, request[4], pmtB, request[6], parseIntValue(request[7]), parseIntValue(request[8]), shareId)
626643 else if ((request[0] == WX_POOL))
627644 then replenishWX(pool, LOAN_FEE, pmtA, request[4], pmtB, request[6], shareId)
628645 else throw("Wrong request type")
629- let userStaked = $t02134221857._1
630- let axlyFee = $t02134221857._2
646+ let userStaked = $t02200822523._1
647+ let axlyFee = $t02200822523._2
631648 let borrowEntries = [IntegerEntry((((((request[2] + "_") + request[1]) + "_") + request[12]) + kUserBorrowAmount), i.payments[0].amount), StringEntry((((((request[2] + "_") + request[1]) + "_") + request[12]) + kUserBorrowAssetId), request[10])]
632649 let entries = replenishEntries(pool, user, userStaked, axlyFee, posNum, shareId, request[0])
633650 $Tuple2(((entries ++ borrowEntries) :+ DeleteEntry((requestId + kRequestId))), userStaked)
634651 }
635652 }
636653
637654
638655
639656 @Callable(i)
640657 func withdraw (pool,posId) = {
641658 let user = toString(i.caller)
642659 let pType = valueOrErrorMessage(getString(this, (kPool + pool)), "Unknown pool")
643660 let pAmount = valueOrErrorMessage(getInteger(this, (((((pool + "_") + user) + "_") + toString(posId)) + kUserPosition)), "Unknown position")
644661 let userInterest = getIntegerValue(this, (((((pool + "_") + user) + "_") + toString(posId)) + kUserPositionInterest))
645662 let poolInterst = getIntegerValue(this, (pool + kPoolInterest))
646663 let poolTotalShare = getPoolTotalShare(pool)
647664 let userCanWithdraw = (pAmount + fraction(pAmount, (poolInterst - userInterest), SCALE10))
648665 let poolAddr = Address(fromBase58String(pool))
649666 let userAddr = Address(fromBase58String(user))
650667 let borrowAmount = getIntegerValue(this, (((((pool + "_") + user) + "_") + toString(posId)) + kUserBorrowAmount))
651668 let borrowAsset = getStringValue(this, (((((pool + "_") + user) + "_") + toString(posId)) + kUserBorrowAssetId))
652- let $t02320323303 = getPoolData(Address(fromBase58String(pool)), pType)
653- let assetIdA = $t02320323303._1
654- let assetIdB = $t02320323303._2
655- let balA = $t02320323303._3
656- let balB = $t02320323303._4
657- let shareId = $t02320323303._5
669+ let $t02386923969 = getPoolData(Address(fromBase58String(pool)), pType)
670+ let assetIdA = $t02386923969._1
671+ let assetIdB = $t02386923969._2
672+ let balA = $t02386923969._3
673+ let balB = $t02386923969._4
674+ let shareId = $t02386923969._5
658675 let cBalABefore = accountBalance(assetIdFromStr(assetIdA))
659676 if ((cBalABefore == cBalABefore))
660677 then {
661678 let cBalBBefore = accountBalance(assetIdFromStr(assetIdB))
662679 if ((cBalBBefore == cBalBBefore))
663680 then {
664681 let inv = if ((pType == SF_POOL))
665682 then invoke(poolAddr, "callFunction", ["withdraw", [toString(userCanWithdraw)]], nil)
666683 else if ((pType == WX_POOL))
667684 then invoke(poolAddr, "unstakeAndGet", [userCanWithdraw], nil)
668685 else throw("Wrong position type")
669686 if ((inv == inv))
670687 then {
671688 let cBalAAfter = accountBalance(assetIdFromStr(assetIdA))
672689 let cBalBAfter = accountBalance(assetIdFromStr(assetIdB))
673- let $t02381523904 = $Tuple2((cBalAAfter - cBalABefore), (cBalBAfter - cBalBBefore))
674- let tokensAmountA = $t02381523904._1
675- let tokensAmountB = $t02381523904._2
676- let $t02390724902 = if ((borrowAmount > 0))
690+ let $t02448124570 = $Tuple2((cBalAAfter - cBalABefore), (cBalBAfter - cBalBBefore))
691+ let tokensAmountA = $t02448124570._1
692+ let tokensAmountB = $t02448124570._2
693+ let $t02457325568 = if ((borrowAmount > 0))
677694 then {
678695 let debt = {
679696 let @ = invoke(getLendSrvAddr(), "getAssetDebt", [false, ((((pool + "_") + user) + "_") + toString(posId)), borrowAsset], nil)
680697 if ($isInstanceOf(@, "Int"))
681698 then @
682699 else throw(($getType(@) + " couldn't be cast to Int"))
683700 }
684701 let amountToGetEx = if (if ((borrowAsset == assetIdA))
685702 then (debt > tokensAmountA)
686703 else false)
687704 then (debt - tokensAmountA)
688705 else if (if ((borrowAsset == assetIdB))
689706 then (debt > tokensAmountB)
690707 else false)
691708 then (debt - tokensAmountB)
692709 else 0
693710 let exInv = if ((amountToGetEx > 0))
694711 then exchangeDirectly(pType, pool, assetIdA, assetIdB, balA, balB, amountToGetEx, borrowAsset)
695712 else 0
696713 if ((exInv == exInv))
697714 then {
698715 let closeDbtInv = invoke(getLendSrvAddr(), "repayFor", [((user + "_") + toString(posId))], [AttachedPayment(assetIdFromStr(borrowAsset), debt)])
699716 if ((closeDbtInv == closeDbtInv))
700717 then {
701718 let cBalAAfterRepay = accountBalance(assetIdFromStr(assetIdA))
702719 let cBalBAfterRepay = accountBalance(assetIdFromStr(assetIdB))
703720 $Tuple2((cBalAAfterRepay - cBalABefore), (cBalBAfterRepay - cBalBBefore))
704721 }
705722 else throw("Strict value is not equal to itself.")
706723 }
707724 else throw("Strict value is not equal to itself.")
708725 }
709726 else $Tuple2(tokensAmountA, tokensAmountB)
710- let toUserAmountA = $t02390724902._1
711- let toUserAmountB = $t02390724902._2
727+ let toUserAmountA = $t02457325568._1
728+ let toUserAmountB = $t02457325568._2
712729 [DeleteEntry((((((pool + "_") + user) + "_") + toString(posId)) + kUserPosition)), DeleteEntry((((((pool + "_") + user) + "_") + toString(posId)) + kUserPositionInterest)), IntegerEntry((pool + kPoolTotal), (poolTotalShare - userCanWithdraw)), ScriptTransfer(userAddr, tokensAmountA, assetIdFromStr(assetIdA)), ScriptTransfer(userAddr, tokensAmountB, assetIdFromStr(assetIdB))]
713730 }
714731 else throw("Strict value is not equal to itself.")
715732 }
716733 else throw("Strict value is not equal to itself.")
717734 }
718735 else throw("Strict value is not equal to itself.")
719736 }
720737
721738
722739
723740 @Callable(i)
724741 func createNewRequest (params) = valueOrElse(isSelfCall(i), {
725742 let newRequestId = (valueOrElse(getInteger(this, kRequestIter), 0) + 1)
726743 $Tuple2([StringEntry((toString(newRequestId) + kRequestId), params), IntegerEntry(kRequestIter, newRequestId)], newRequestId)
727744 })
728745
729746
730747
731748 @Callable(i)
732749 func capitalizeExKeeper (pool,type,tokenToId,amountToExchange,claim,amountsIn,addresses,assetsToReceive,estReceived,slippageTolerance,minReceived,options) = {
733- let $t02601126205 = if (claim)
750+ let $t02667726871 = if (claim)
734751 then claimFarmed(type, pool)
735752 else {
736753 let claimedAsset = if ((type == SF_POOL))
737754 then SWOPID
738755 else WXID
739756 $Tuple2(amountToExchange, claimedAsset)
740757 }
741- let claimedAmount = $t02601126205._1
742- let claimedAsset = $t02601126205._2
758+ let claimedAmount = $t02667726871._1
759+ let claimedAsset = $t02667726871._2
743760 let exchangedAmount = exchangeKeeper(tokenToId, amountToExchange, claimedAsset, amountsIn, addresses, assetsToReceive, estReceived, slippageTolerance, minReceived, options)
744761 let change = (claimedAmount - amountToExchange)
745762 let changeEntry = if ((change > 0))
746763 then [IntegerEntry((pool + kPoolCapChange), (change + valueOrElse(getInteger(this, (pool + kPoolCapChange)), 0)))]
747764 else nil
748765 (capitalize(pool, type, tokenToId, exchangedAmount) ++ changeEntry)
749766 }
750767
751768
752769
753770 @Callable(i)
754771 func capitalizeExPazzle (pool,type,tokenToId,amountToExchange,claim,routesStr,minToReceive,options) = {
755- let $t02686127055 = if (claim)
772+ let $t02752727721 = if (claim)
756773 then claimFarmed(type, pool)
757774 else {
758775 let claimedAsset = if ((type == SF_POOL))
759776 then SWOPID
760777 else WXID
761778 $Tuple2(amountToExchange, claimedAsset)
762779 }
763- let claimedAmount = $t02686127055._1
764- let claimedAsset = $t02686127055._2
780+ let claimedAmount = $t02752727721._1
781+ let claimedAsset = $t02752727721._2
765782 let exchangedAmount = exchangePazzle(tokenToId, amountToExchange, claimedAsset, routesStr, minToReceive, options)
766783 let change = (claimedAmount - amountToExchange)
767784 let changeEntry = if ((change > 0))
768785 then [IntegerEntry((pool + kPoolCapChange), (change + valueOrElse(getInteger(this, (pool + kPoolCapChange)), 0)))]
769786 else nil
770787 (capitalize(pool, type, tokenToId, exchangedAmount) ++ changeEntry)
771788 }
772789
773790
774791
775792 @Callable(i)
776793 func capitalizeExSwopFi (pool,type,tokenToId,amountToExchange,claim,exchangers,exchangersType,args1,args2,routingAssetsKeys,minAmountToReceive,options) = {
777- let $t02777827972 = if (claim)
794+ let $t02844428638 = if (claim)
778795 then claimFarmed(type, pool)
779796 else {
780797 let claimedAsset = if ((type == SF_POOL))
781798 then SWOPID
782799 else WXID
783800 $Tuple2(amountToExchange, claimedAsset)
784801 }
785- let claimedAmount = $t02777827972._1
786- let claimedAsset = $t02777827972._2
802+ let claimedAmount = $t02844428638._1
803+ let claimedAsset = $t02844428638._2
787804 let exchangedAmount = exchangeSwopFi(tokenToId, amountToExchange, claimedAsset, exchangers, exchangersType, args1, args2, routingAssetsKeys, minAmountToReceive, options)
788805 let change = (claimedAmount - amountToExchange)
789806 let changeEntry = if ((change > 0))
790807 then [IntegerEntry((pool + kPoolCapChange), (change + valueOrElse(getInteger(this, (pool + kPoolCapChange)), 0)))]
791808 else nil
792809 (capitalize(pool, type, tokenToId, exchangedAmount) ++ changeEntry)
793810 }
794811
795812
796813
797814 @Callable(i)
798815 func initNewPool (type,poolAddr,inFeeNoLoan,inFeeLoan,capFee) = if (if ((type != SF_POOL))
799816 then (type != WX_POOL)
800817 else false)
801818 then throw("Wrong type")
802819 else [IntegerEntry((poolAddr + kAxlyInFeeWithoutLoan), inFeeNoLoan), IntegerEntry((poolAddr + kAxlyInFeeWithLoan), inFeeLoan), IntegerEntry((poolAddr + kAxlyCapFee), capFee), IntegerEntry((poolAddr + kPoolInterest), 0), StringEntry((kPool + poolAddr), type)]
803820
804821
805822 @Verifier(tx)
806823 func verify () = sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey)
807824

github/deemru/w8io/026f985 
109.48 ms