tx · DSgqLqm5gyjG4nCW4Yp2o63V5YWufPD2WQuWovGFDYXx

3NAefciWv6f9fWvEXdGgpHfanJFG8HqfjuT:  -0.03700000 Waves

2022.12.26 16:48 [2377322] smart account 3NAefciWv6f9fWvEXdGgpHfanJFG8HqfjuT > SELF 0.00000000 Waves

{ "type": 13, "id": "DSgqLqm5gyjG4nCW4Yp2o63V5YWufPD2WQuWovGFDYXx", "fee": 3700000, "feeAssetId": null, "timestamp": 1672062539027, "version": 1, "sender": "3NAefciWv6f9fWvEXdGgpHfanJFG8HqfjuT", "senderPublicKey": "D1BL65meykxFZTCuq7jq9HSGLLnWvQamQPUNrguW5w39", "proofs": [ "5CzjFDAmTj1ixKLRAEacpCxRRnESEtGXAvdHJahsE3y4D2emcFnavV3i5qtkt7nkEirM6pjLseWKHAivPPpR9L4B" ], "script": "base64:BgKwKQgCEgMKAQgSAwoBCBIAEgQKAgEEEgQKAgEEEgMKAQESABIECgIIARIAEgQKAggBEgQKAggBEgQKAgEBEgMKAQESBQoDAQEBEgUKAwEIARIECgIBCBIECgIBCBIECgIICBIECgIICBIECgIIARIAEgMKAQgSBQoDAQEBEgQKAggBEgQKAgEBEgQKAggIEgsKCQgBAQIBAggEBBIGCgQICAEIEgAiBnNjYWxlOCIMc2NhbGU4QmlnSW50IgdzY2FsZTE4Igp6ZXJvQmlnSW50IgRiaWcwIgRiaWcxIgRiaWcyIgRiaWczIgRiaWc0IgpzbGlwcGFnZTREIgt3YXZlc1N0cmluZyIFQW11bHQiBURjb252IgNTRVAiBUVNUFRZIgpQb29sQWN0aXZlIgpQb29sUHV0RGlzIg5Qb29sTWF0Y2hlckRpcyIMUG9vbFNodXRkb3duIg5pZHhQb29sQWRkcmVzcyIJaWR4UG9vbFN0IglpZHhMUEFzSWQiCWlkeEFtQXNJZCIJaWR4UHJBc0lkIgtpZHhBbXRBc0RjbSINaWR4UHJpY2VBc0RjbSILaWR4SUFtdEFzSWQiDWlkeElQcmljZUFzSWQiD2lkeEZhY3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JpYQcGCQD0AwMIBQJoVAlib2R5Qnl0ZXMJAJEDAggFAmhUBnByb29mcwAABQJoVgkA9AMDCAUCaFQJYm9keUJ5dGVzCQCRAwIIBQJoVAZwcm9vZnMAAAUCaFYfnD02", "chainId": 84, "height": 2377322, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: uuAsZaGnFLpm3yhk5J8wGdViPKEJT4VnsdGvrd9FCoJ Next: 6HLrMu99hjovDsZLTVLYoZjC2G2fSaVg8B564SxNAN5H Diff:
OldNewDifferences
255255 func cpbi (prAmtX18,amAmtX18) = fraction(prAmtX18, scale18, amAmtX18)
256256
257257
258+func cpbir (prAmtX18,amAmtX18,round) = fraction(prAmtX18, scale18, amAmtX18, round)
259+
260+
258261 func vad (A1,A2,slippage) = {
259262 let diff = fraction((A1 - A2), scale8BigInt, A2)
260263 let pass = ((slippage - abs(diff)) > zeroBigInt)
383386 $Tuple5(f1(lpAmtX18, scale8), f1(inAmAssetAmtX18, amtDcm), f1(inPrAssetAmtX18, priceDcm), cpbi((prBalanceX18 + inPrAssetAmtX18), (amBalanceX18 + inAmAssetAmtX18)), slippageX18)
384387 }
385388 else {
386- let curPriceX18 = cpbi(prBalanceX18, amBalanceX18)
389+ let curPriceX18 = cpbir(prBalanceX18, amBalanceX18, CEILING)
387390 let slippageRealX18 = fraction(abs((curPriceX18 - userPriceX18)), scale18, curPriceX18)
388391 let slippageX18 = t1(slippage, scale8)
389392 if (if (if (validateSlippage)
418421 else calcLpAmt
419422 let amDiff = (inAmAmt - calcAmAssetPmt)
420423 let prDiff = (inPrAmt - calcPrAssetPmt)
421- let $t01819418539 = if (if (isOneAsset)
424+ let $t01832718672 = if (if (isOneAsset)
422425 then (pmtId == amIdStr)
423426 else false)
424427 then $Tuple2(pmtAmt, 0)
427430 else false)
428431 then $Tuple2(0, pmtAmt)
429432 else $Tuple2(calcAmAssetPmt, calcPrAssetPmt)
430- let writeAmAmt = $t01819418539._1
431- let writePrAmt = $t01819418539._2
433+ let writeAmAmt = $t01832718672._1
434+ let writePrAmt = $t01832718672._2
432435 let commonState = [IntegerEntry(pl(), curPrice), IntegerEntry(ph(height, lastBlock.timestamp), curPrice), StringEntry(pau(userAddress, txId58), dataPutActionInfo(writeAmAmt, writePrAmt, emitLpAmt, curPrice, slippage, slippageCalc, height, lastBlock.timestamp, amDiff, prDiff))]
433436 $Tuple13(calcLpAmt, emitLpAmt, curPrice, amBalance, prBalance, lpEm, lpId, sts, commonState, amDiff, prDiff, inAmId, inPrId)
434437 }
470473 }
471474
472475 let arr = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14]
473- let $t02046720515 = {
476+ let $t02060020648 = {
474477 let $l = arr
475478 let $s = size($l)
476479 let $acc0 = $Tuple2(s, false)
484487
485488 $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15)
486489 }
487- let d = $t02046720515._1
488- let found = $t02046720515._2
490+ let d = $t02060020648._1
491+ let found = $t02060020648._2
489492 if (found)
490493 then d
491494 else throw(("D calculation error, D = " + toString(d)))
509512 let ann_aPrecision = (ann - aPrecision)
510513 let n1 = (n + big1)
511514 func calc (acc,cur) = {
512- let $t02114421164 = acc
513- let d = $t02114421164._1
514- let found = $t02114421164._2
515+ let $t02127721297 = acc
516+ let d = $t02127721297._1
517+ let found = $t02127721297._2
515518 if ((found != unit))
516519 then acc
517520 else {
525528 }
526529
527530 let arr = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14]
528- let $t02158521632 = {
531+ let $t02171821765 = {
529532 let $l = arr
530533 let $s = size($l)
531534 let $acc0 = $Tuple2(s, unit)
539542
540543 $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15)
541544 }
542- let d = $t02158521632._1
543- let found = $t02158521632._2
545+ let d = $t02171821765._1
546+ let found = $t02171821765._2
544547 if ((found != unit))
545548 then d
546549 else throw(("D calculation error, D = " + toString(d)))
560563 let c = (((((D * D) / (x * n)) * D) * aPrecision) / (ann * n))
561564 let b = ((s + ((D * aPrecision) / ann)) - D)
562565 func calc (acc,cur) = {
563- let $t02213222152 = acc
564- let y = $t02213222152._1
565- let found = $t02213222152._2
566+ let $t02226522285 = acc
567+ let y = $t02226522285._1
568+ let found = $t02226522285._2
566569 if ((found != unit))
567570 then acc
568571 else {
575578 }
576579
577580 let arr = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14]
578- let $t02245922506 = {
581+ let $t02259222639 = {
579582 let $l = arr
580583 let $s = size($l)
581584 let $acc0 = $Tuple2(D, unit)
589592
590593 $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15)
591594 }
592- let y = $t02245922506._1
593- let found = $t02245922506._2
595+ let y = $t02259222639._1
596+ let found = $t02259222639._2
594597 if ((found != unit))
595598 then y
596599 else throw(("Y calculation error, Y = " + toString(y)))
632635 func validateMatcherOrderAllowed (order) = {
633636 let amountAssetAmount = order.amount
634637 let priceAssetAmount = fraction(order.amount, order.price, scale8, FLOOR)
635- let $t02444524657 = if ((order.orderType == Buy))
638+ let $t02457824790 = if ((order.orderType == Buy))
636639 then $Tuple2(amountAssetAmount, -(priceAssetAmount))
637640 else $Tuple2(-(amountAssetAmount), priceAssetAmount)
638- let amountAssetBalanceDelta = $t02444524657._1
639- let priceAssetBalanceDelta = $t02444524657._2
641+ let amountAssetBalanceDelta = $t02457824790._1
642+ let priceAssetBalanceDelta = $t02457824790._2
640643 if (if (if (igs())
641644 then true
642645 else (cfgPoolStatus == PoolMatcherDis))
649652 then throw("Wr assets")
650653 else {
651654 let dLp = parseBigIntValue(getStringValue(this, keyDLp))
652- let $t02498725087 = refreshDLpInternal(amountAssetBalanceDelta, priceAssetBalanceDelta, 0)
653- let unusedActions = $t02498725087._1
654- let dLpNew = $t02498725087._2
655+ let $t02512025220 = refreshDLpInternal(amountAssetBalanceDelta, priceAssetBalanceDelta, 0)
656+ let unusedActions = $t02512025220._1
657+ let dLpNew = $t02512025220._2
655658 let isOrderValid = (dLpNew >= dLp)
656659 isOrderValid
657660 }
704707 then {
705708 let amBalance = getAccBalance(amId)
706709 let prBalance = getAccBalance(prId)
707- let $t02735327815 = if ((txId == ""))
710+ let $t02748627948 = if ((txId == ""))
708711 then $Tuple2(amBalance, prBalance)
709712 else if ((pmtAssetId == amId))
710713 then if ((pmtAmtRaw > amBalance))
715718 then throw("invalid payment amount")
716719 else $Tuple2(amBalance, (prBalance - pmtAmtRaw))
717720 else throw("wrong pmtAssetId")
718- let amBalanceOld = $t02735327815._1
719- let prBalanceOld = $t02735327815._2
720- let $t02782127997 = if ((pmtAssetId == amId))
721+ let amBalanceOld = $t02748627948._1
722+ let prBalanceOld = $t02748627948._2
723+ let $t02795428130 = if ((pmtAssetId == amId))
721724 then $Tuple2(pmtAmtRaw, 0)
722725 else if ((pmtAssetId == prId))
723726 then $Tuple2(0, pmtAmtRaw)
724727 else throw("invalid payment")
725- let amAmountRaw = $t02782127997._1
726- let prAmountRaw = $t02782127997._2
727- let $t02800128240 = if (withTakeFee)
728+ let amAmountRaw = $t02795428130._1
729+ let prAmountRaw = $t02795428130._2
730+ let $t02813428373 = if (withTakeFee)
728731 then $Tuple3(takeFee(amAmountRaw)._1, takeFee(prAmountRaw)._1, takeFee(pmtAmtRaw)._2)
729732 else $Tuple3(amAmountRaw, prAmountRaw, 0)
730- let amAmount = $t02800128240._1
731- let prAmount = $t02800128240._2
732- let feeAmount = $t02800128240._3
733+ let amAmount = $t02813428373._1
734+ let prAmount = $t02813428373._2
735+ let feeAmount = $t02813428373._3
733736 let amBalanceNew = (amBalanceOld + amAmount)
734737 let prBalanceNew = (prBalanceOld + prAmount)
735738 let D0 = getD([toBigInt(amBalanceOld), toBigInt(prBalanceOld)])
777780 else {
778781 let amBalance = getAccBalance(amId)
779782 let prBalance = getAccBalance(prId)
780- let $t03029030401 = {
783+ let $t03042330534 = {
781784 let @ = invoke(this, "getOneTknV2READONLY", [outAssetId, pmtAmt], nil)
782785 if ($isInstanceOf(@, "(Int, Int)"))
783786 then @
784787 else throw(($getType(@) + " couldn't be cast to (Int, Int)"))
785788 }
786- if (($t03029030401 == $t03029030401))
789+ if (($t03042330534 == $t03042330534))
787790 then {
788- let feeAmount = $t03029030401._2
789- let totalGet = $t03029030401._1
791+ let feeAmount = $t03042330534._2
792+ let totalGet = $t03042330534._1
790793 let totalAmount = if (if ((minOutAmount > 0))
791794 then (minOutAmount > totalGet)
792795 else false)
793796 then throwErr(makeString(["amount to receive is less than ", toString(minOutAmount)], ""))
794797 else totalGet
795- let $t03059130898 = if ((outAssetId == amId))
798+ let $t03072431031 = if ((outAssetId == amId))
796799 then $Tuple4(totalAmount, 0, ((amBalance - totalAmount) - feeAmount), prBalance)
797800 else if ((outAssetId == prId))
798801 then $Tuple4(0, totalAmount, amBalance, ((prBalance - totalAmount) - feeAmount))
799802 else throw("invalid out asset id")
800- let outAm = $t03059130898._1
801- let outPr = $t03059130898._2
802- let amBalanceNew = $t03059130898._3
803- let prBalanceNew = $t03059130898._4
803+ let outAm = $t03072431031._1
804+ let outPr = $t03072431031._2
805+ let amBalanceNew = $t03072431031._3
806+ let prBalanceNew = $t03072431031._4
804807 let curPrX18 = cpbi(t1(prBalanceNew, prDecimals), t1(amBalanceNew, amDecimals))
805808 let curPr = f1(curPrX18, scale8)
806809 let outAssetIdOrWaves = if ((outAssetId == "WAVES"))
815818 let burn = invoke(fca, "burn", [pmtAmt], [AttachedPayment(pmtAssetId, pmtAmt)])
816819 if ((burn == burn))
817820 then {
818- let $t03168332033 = {
821+ let $t03181632166 = {
819822 let feeAmountForCalc = if ((this == feeCollectorAddress))
820823 then 0
821824 else feeAmount
826829 then $Tuple2(-((totalGet + feeAmountForCalc)), 0)
827830 else $Tuple2(0, -((totalGet + feeAmountForCalc)))
828831 }
829- let amountAssetBalanceDelta = $t03168332033._1
830- let priceAssetBalanceDelta = $t03168332033._2
831- let $t03203632144 = refreshDLpInternal(amountAssetBalanceDelta, priceAssetBalanceDelta, 0)
832- let refreshDLpActions = $t03203632144._1
833- let updatedDLp = $t03203632144._2
832+ let amountAssetBalanceDelta = $t03181632166._1
833+ let priceAssetBalanceDelta = $t03181632166._2
834+ let $t03216932277 = refreshDLpInternal(amountAssetBalanceDelta, priceAssetBalanceDelta, 0)
835+ let refreshDLpActions = $t03216932277._1
836+ let updatedDLp = $t03216932277._2
834837 let isUpdatedDLpValid = validateUpdatedDLp(currentDLp, updatedDLp)
835838 if ((isUpdatedDLpValid == isUpdatedDLpValid))
836839 then $Tuple2((state ++ refreshDLpActions), totalAmount)
9991002 else throw("Strict value is not equal to itself.")
10001003 }
10011004 else [ScriptTransfer(i.caller, emitLpAmt, lpAssetId)]
1002- let $t03629336435 = refreshDLpInternal(0, 0, 0)
1003- let refreshDLpActions = $t03629336435._1
1004- let updatedDLp = $t03629336435._2
1005+ let $t03642636568 = refreshDLpInternal(0, 0, 0)
1006+ let refreshDLpActions = $t03642636568._1
1007+ let updatedDLp = $t03642636568._2
10051008 let check = if ((updatedDLp >= currentDLp))
10061009 then true
10071010 else throwErr(makeString(["updated DLp lower than current DLp", toString(amountAssetBalance), toString(priceAssetBalance), toString(lpAssetEmission), toString(currentDLp), toString(updatedDLp)], " "))
10741077 else calcCurrentDLp(toBigInt(0), toBigInt(pmtAmt), toBigInt(0))
10751078 if ((currentDLp == currentDLp))
10761079 then {
1077- let $t03813138289 = calcPutOneTkn(pmtAmt, pmtAssetId, toString(userAddress), toBase58String(i.transactionId), true)
1078- if (($t03813138289 == $t03813138289))
1080+ let $t03836938527 = calcPutOneTkn(pmtAmt, pmtAssetId, toString(userAddress), toBase58String(i.transactionId), true)
1081+ if (($t03836938527 == $t03836938527))
10791082 then {
1080- let feeAmount = $t03813138289._3
1081- let state = $t03813138289._2
1082- let estimLP = $t03813138289._1
1083+ let feeAmount = $t03836938527._3
1084+ let state = $t03836938527._2
1085+ let estimLP = $t03836938527._1
10831086 let emitLpAmt = if (if ((minOutAmount > 0))
10841087 then (minOutAmount > estimLP)
10851088 else false)
11071110 let sendFeeToMatcher = if ((feeAmount > 0))
11081111 then [ScriptTransfer(feeCollectorAddress, feeAmount, fromBase58String(pmtAssetId))]
11091112 else nil
1110- let $t03910439453 = if ((this == feeCollectorAddress))
1113+ let $t03934239691 = if ((this == feeCollectorAddress))
11111114 then $Tuple2(0, 0)
11121115 else {
11131116 let paymentInAmountAsset = if ((pmt.assetId == cfgAmountAssetId))
11171120 then $Tuple2(-(feeAmount), 0)
11181121 else $Tuple2(0, -(feeAmount))
11191122 }
1120- let amountAssetBalanceDelta = $t03910439453._1
1121- let priceAssetBalanceDelta = $t03910439453._2
1122- let $t03945639564 = refreshDLpInternal(amountAssetBalanceDelta, priceAssetBalanceDelta, 0)
1123- let refreshDLpActions = $t03945639564._1
1124- let updatedDLp = $t03945639564._2
1123+ let amountAssetBalanceDelta = $t03934239691._1
1124+ let priceAssetBalanceDelta = $t03934239691._2
1125+ let $t03969439802 = refreshDLpInternal(amountAssetBalanceDelta, priceAssetBalanceDelta, 0)
1126+ let refreshDLpActions = $t03969439802._1
1127+ let updatedDLp = $t03969439802._2
11251128 let isUpdatedDLpValid = validateUpdatedDLp(currentDLp, updatedDLp)
11261129 if ((isUpdatedDLpValid == isUpdatedDLpValid))
11271130 then $Tuple2((((state ++ lpTrnsfr) ++ sendFeeToMatcher) ++ refreshDLpActions), emitLpAmt)
11531156 let currentDLp = calcCurrentDLp(amAssetPmt, prAssetPmt, toBigInt(0))
11541157 if ((currentDLp == currentDLp))
11551158 then {
1156- let $t04059440659 = refreshDLpInternal(0, 0, 0)
1157- let refreshDLpActions = $t04059440659._1
1158- let updatedDLp = $t04059440659._2
1159+ let $t04083240897 = refreshDLpInternal(0, 0, 0)
1160+ let refreshDLpActions = $t04083240897._1
1161+ let updatedDLp = $t04083240897._2
11591162 let isUpdatedDLpValid = validateUpdatedDLp(currentDLp, updatedDLp)
11601163 if ((isUpdatedDLpValid == isUpdatedDLpValid))
11611164 then (state ++ refreshDLpActions)
11801183 let b = invoke(fca, "burn", [pmtAmt], [AttachedPayment(pmtAssetId, pmtAmt)])
11811184 if ((b == b))
11821185 then {
1183- let $t04183241914 = refreshDLpInternal(-(outAmtAmt), -(outPrAmt), 0)
1184- let refreshDLpActions = $t04183241914._1
1185- let updatedDLp = $t04183241914._2
1186+ let $t04207042152 = refreshDLpInternal(-(outAmtAmt), -(outPrAmt), 0)
1187+ let refreshDLpActions = $t04207042152._1
1188+ let updatedDLp = $t04207042152._2
11861189 let isUpdatedDLpValid = validateUpdatedDLp(currentDLp, updatedDLp)
11871190 if ((isUpdatedDLpValid == isUpdatedDLpValid))
11881191 then (state ++ refreshDLpActions)
12171220 else throwErr("exactly 1 payment are expected")]
12181221 if ((checks == checks))
12191222 then {
1220- let $t04253242687 = getOneTknV2Internal(outAssetId, minOutAmount, i.payments, i.caller, i.originCaller, i.transactionId)
1221- let state = $t04253242687._1
1222- let totalAmount = $t04253242687._2
1223+ let $t04277042925 = getOneTknV2Internal(outAssetId, minOutAmount, i.payments, i.caller, i.originCaller, i.transactionId)
1224+ let state = $t04277042925._1
1225+ let totalAmount = $t04277042925._2
12231226 $Tuple2(state, totalAmount)
12241227 }
12251228 else throw("Strict value is not equal to itself.")
12361239 if ((checkLastRefreshedBlockHeight == checkLastRefreshedBlockHeight))
12371240 then {
12381241 let dLp = valueOrErrorMessage(parseBigInt(valueOrElse(getString(this, keyDLp), "0")), fmtErr("invalid dLp"))
1239- let $t04321143275 = refreshDLpInternal(0, 0, 0)
1240- let dLpUpdateActions = $t04321143275._1
1241- let updatedDLp = $t04321143275._2
1242+ let $t04344943513 = refreshDLpInternal(0, 0, 0)
1243+ let dLpUpdateActions = $t04344943513._1
1244+ let updatedDLp = $t04344943513._2
12421245 let actions = if ((dLp != updatedDLp))
12431246 then dLpUpdateActions
12441247 else throwErr("nothing to refresh")
12661269 let newY = getYD(xp, index, D1)
12671270 let dy = (xp[index] - newY)
12681271 let totalGetRaw = max([0, toInt((dy - big1))])
1269- let $t04420544254 = takeFee(totalGetRaw)
1270- let totalGet = $t04420544254._1
1271- let feeAmount = $t04420544254._2
1272+ let $t04444344492 = takeFee(totalGetRaw)
1273+ let totalGet = $t04444344492._1
1274+ let feeAmount = $t04444344492._2
12721275 $Tuple2(nil, $Tuple2(totalGet, feeAmount))
12731276 }
12741277
12811284 let lpId = toBase58String(value(cfgLpAssetId))
12821285 let amBalance = getAccBalance(amId)
12831286 let prBalance = getAccBalance(prId)
1284- let $t04462944744 = {
1287+ let $t04486744982 = {
12851288 let @ = invoke(this, "getOneTknV2READONLY", [outAssetId, lpAssetAmount], nil)
12861289 if ($isInstanceOf(@, "(Int, Int)"))
12871290 then @
12881291 else throw(($getType(@) + " couldn't be cast to (Int, Int)"))
12891292 }
1290- let totalGet = $t04462944744._1
1291- let feeAmount = $t04462944744._2
1293+ let totalGet = $t04486744982._1
1294+ let feeAmount = $t04486744982._2
12921295 let r = ego("", lpId, lpAssetAmount, this)
12931296 let outAmAmt = r._1
12941297 let outPrAmt = r._2
13341337 let burnLPAssetOnFactory = invoke(fca, "burn", [pmtAmt], [AttachedPayment(pmtAssetId, pmtAmt)])
13351338 if ((burnLPAssetOnFactory == burnLPAssetOnFactory))
13361339 then {
1337- let $t04628346364 = refreshDLpInternal(-(outAmAmt), -(outPrAmt), 0)
1338- let refreshDLpActions = $t04628346364._1
1339- let updatedDLp = $t04628346364._2
1340+ let $t04652146602 = refreshDLpInternal(-(outAmAmt), -(outPrAmt), 0)
1341+ let refreshDLpActions = $t04652146602._1
1342+ let updatedDLp = $t04652146602._2
13401343 let isUpdatedDLpValid = validateUpdatedDLp(currentDLp, updatedDLp)
13411344 if ((isUpdatedDLpValid == isUpdatedDLpValid))
13421345 then (state ++ refreshDLpActions)
13871390 let burnA = invoke(fca, "burn", [amount], [AttachedPayment(lpAssetId, amount)])
13881391 if ((burnA == burnA))
13891392 then {
1390- let $t04738847469 = refreshDLpInternal(-(outAmAmt), -(outPrAmt), 0)
1391- let refreshDLpActions = $t04738847469._1
1392- let updatedDLp = $t04738847469._2
1393+ let $t04762647707 = refreshDLpInternal(-(outAmAmt), -(outPrAmt), 0)
1394+ let refreshDLpActions = $t04762647707._1
1395+ let updatedDLp = $t04762647707._2
13931396 let isUpdatedDLpValid = validateUpdatedDLp(currentDLp, updatedDLp)
13941397 if ((isUpdatedDLpValid == isUpdatedDLpValid))
13951398 then (state ++ refreshDLpActions)
14361439 let burnLPAssetOnFactory = invoke(fca, "burn", [unstakeAmount], [AttachedPayment(cfgLpAssetId, unstakeAmount)])
14371440 if ((burnLPAssetOnFactory == burnLPAssetOnFactory))
14381441 then {
1439- let $t04871748798 = refreshDLpInternal(-(outAmAmt), -(outPrAmt), 0)
1440- let refreshDLpActions = $t04871748798._1
1441- let updatedDLp = $t04871748798._2
1442+ let $t04895549036 = refreshDLpInternal(-(outAmAmt), -(outPrAmt), 0)
1443+ let refreshDLpActions = $t04895549036._1
1444+ let updatedDLp = $t04895549036._2
14421445 let isUpdatedDLpValid = validateUpdatedDLp(currentDLp, updatedDLp)
14431446 if ((isUpdatedDLpValid == isUpdatedDLpValid))
14441447 then (state ++ refreshDLpActions)
14831486 let unstakeInv = invoke(staking, "unstake", [toBase58String(lpAssetId), unstakeAmount], nil)
14841487 if ((unstakeInv == unstakeInv))
14851488 then {
1486- let $t04969349881 = getOneTknV2Internal(outAssetId, minOutAmount, [AttachedPayment(lpAssetId, unstakeAmount)], i.caller, i.originCaller, i.transactionId)
1487- let state = $t04969349881._1
1488- let totalAmount = $t04969349881._2
1489+ let $t04993150119 = getOneTknV2Internal(outAssetId, minOutAmount, [AttachedPayment(lpAssetId, unstakeAmount)], i.caller, i.originCaller, i.transactionId)
1490+ let state = $t04993150119._1
1491+ let totalAmount = $t04993150119._2
14891492 $Tuple2(state, totalAmount)
14901493 }
14911494 else throw("Strict value is not equal to itself.")
14971500
14981501 @Callable(i)
14991502 func putOneTknV2WithBonusREADONLY (paymentAmountRaw,paymentAssetId) = {
1500- let $t05000950112 = calcPutOneTkn(paymentAmountRaw, paymentAssetId, "", "", true)
1501- let lpAmount = $t05000950112._1
1502- let state = $t05000950112._2
1503- let feeAmount = $t05000950112._3
1504- let bonus = $t05000950112._4
1503+ let $t05024750350 = calcPutOneTkn(paymentAmountRaw, paymentAssetId, "", "", true)
1504+ let lpAmount = $t05024750350._1
1505+ let state = $t05024750350._2
1506+ let feeAmount = $t05024750350._3
1507+ let bonus = $t05024750350._4
15051508 $Tuple2(nil, $Tuple3(lpAmount, feeAmount, bonus))
15061509 }
15071510
15091512
15101513 @Callable(i)
15111514 func putOneTknV2WithoutTakeFeeREADONLY (paymentAmountRaw,paymentAssetId) = {
1512- let $t05026050364 = calcPutOneTkn(paymentAmountRaw, paymentAssetId, "", "", false)
1513- let lpAmount = $t05026050364._1
1514- let state = $t05026050364._2
1515- let feeAmount = $t05026050364._3
1516- let bonus = $t05026050364._4
1515+ let $t05049850602 = calcPutOneTkn(paymentAmountRaw, paymentAssetId, "", "", false)
1516+ let lpAmount = $t05049850602._1
1517+ let state = $t05049850602._2
1518+ let feeAmount = $t05049850602._3
1519+ let bonus = $t05049850602._4
15171520 $Tuple2(nil, $Tuple3(lpAmount, feeAmount, bonus))
15181521 }
15191522
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 6 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let scale8 = 100000000
55
66 let scale8BigInt = toBigInt(100000000)
77
88 let scale18 = toBigInt(1000000000000000000)
99
1010 let zeroBigInt = toBigInt(0)
1111
1212 let big0 = toBigInt(0)
1313
1414 let big1 = toBigInt(1)
1515
1616 let big2 = toBigInt(2)
1717
1818 let big3 = toBigInt(3)
1919
2020 let big4 = toBigInt(4)
2121
2222 let slippage4D = toBigInt((scale8 - ((scale8 * 1) / scale8)))
2323
2424 let wavesString = "WAVES"
2525
2626 let Amult = "100"
2727
2828 let Dconv = "1"
2929
3030 let SEP = "__"
3131
3232 let EMPTY = ""
3333
3434 let PoolActive = 1
3535
3636 let PoolPutDis = 2
3737
3838 let PoolMatcherDis = 3
3939
4040 let PoolShutdown = 4
4141
4242 let idxPoolAddress = 1
4343
4444 let idxPoolSt = 2
4545
4646 let idxLPAsId = 3
4747
4848 let idxAmAsId = 4
4949
5050 let idxPrAsId = 5
5151
5252 let idxAmtAsDcm = 6
5353
5454 let idxPriceAsDcm = 7
5555
5656 let idxIAmtAsId = 8
5757
5858 let idxIPriceAsId = 9
5959
6060 let idxFactStakCntr = 1
6161
6262 let idxFactoryRestCntr = 6
6363
6464 let idxFactSlippCntr = 7
6565
6666 let idxFactGwxRewCntr = 10
6767
6868 let feeDefault = fraction(10, scale8, 10000)
6969
7070 func t1 (origVal,origScaleMult) = fraction(toBigInt(origVal), scale18, toBigInt(origScaleMult))
7171
7272
7373 func f1 (val,resultScaleMult) = toInt(fraction(val, toBigInt(resultScaleMult), scale18))
7474
7575
7676 func fromX18Round (val,resultScaleMult,round) = toInt(fraction(val, toBigInt(resultScaleMult), scale18, round))
7777
7878
7979 func ts (amt,resScale,curScale) = fraction(amt, resScale, curScale)
8080
8181
8282 func abs (val) = if ((zeroBigInt > val))
8383 then -(val)
8484 else val
8585
8686
8787 func absBigInt (val) = if ((zeroBigInt > val))
8888 then -(val)
8989 else val
9090
9191
9292 func fc () = "%s__factoryContract"
9393
9494
9595 func mpk () = "%s__managerPublicKey"
9696
9797
9898 func pmpk () = "%s__pendingManagerPublicKey"
9999
100100
101101 func pl () = "%s%s__price__last"
102102
103103
104104 func ph (h,t) = makeString(["%s%s%d%d__price__history", toString(h), toString(t)], SEP)
105105
106106
107107 func pau (ua,txId) = ((("%s%s%s__P__" + ua) + "__") + txId)
108108
109109
110110 func gau (ua,txId) = ((("%s%s%s__G__" + ua) + "__") + txId)
111111
112112
113113 func aa () = "%s__amountAsset"
114114
115115
116116 func pa () = "%s__priceAsset"
117117
118118
119119 func amp () = "%s__amp"
120120
121121
122122 func ada () = "%s__addonAddr"
123123
124124
125125 let keyFee = "%s__fee"
126126
127127 let fee = valueOrElse(getInteger(this, keyFee), feeDefault)
128128
129129 let keyDLp = makeString(["%s", "dLp"], SEP)
130130
131131 let keyDLpRefreshedHeight = makeString(["%s", "dLpRefreshedHeight"], SEP)
132132
133133 let keyDLpRefreshDelay = makeString(["%s", "refreshDLpDelay"], SEP)
134134
135135 let dLpRefreshDelayDefault = 1
136136
137137 let dLpRefreshDelay = valueOrElse(getInteger(this, keyDLpRefreshDelay), dLpRefreshDelayDefault)
138138
139139 func fcfg () = "%s__factoryConfig"
140140
141141
142142 func mtpk () = "%s%s__matcher__publicKey"
143143
144144
145145 func pc (iAmtAs,iPrAs) = (((("%d%d%s__" + iAmtAs) + "__") + iPrAs) + "__config")
146146
147147
148148 func mba (bAStr) = ("%s%s%s__mappings__baseAsset2internalId__" + bAStr)
149149
150150
151151 func aps () = "%s__shutdown"
152152
153153
154154 func keyAllowedLpStableScriptHash () = "%s__allowedLpStableScriptHash"
155155
156156
157157 func keyFeeCollectorAddress () = "%s__feeCollectorAddress"
158158
159159
160160 func toe (orV,sendrV,matchV) = throw(((((("Failed: ordValid=" + toString(orV)) + " sndrValid=") + toString(sendrV)) + " mtchrValid=") + toString(matchV)))
161161
162162
163163 func strf (addr,key) = valueOrErrorMessage(getString(addr, key), makeString(["mandatory ", toString(addr), ".", key, " not defined"], ""))
164164
165165
166166 func intf (addr,key) = valueOrErrorMessage(getInteger(addr, key), makeString(["mandatory ", toString(addr), ".", key, " not defined"], ""))
167167
168168
169169 func throwErr (msg) = throw(makeString(["lp_stable.ride:", msg], " "))
170170
171171
172172 func fmtErr (msg) = makeString(["lp_stable.ride:", msg], " ")
173173
174174
175175 let fca = addressFromStringValue(strf(this, fc()))
176176
177177 let A = strf(this, amp())
178178
179179 func igs () = valueOrElse(getBoolean(fca, aps()), false)
180180
181181
182182 func mp () = fromBase58String(strf(fca, mtpk()))
183183
184184
185185 let feeCollectorAddress = addressFromStringValue(strf(fca, keyFeeCollectorAddress()))
186186
187187 func gpc () = {
188188 let amtAs = strf(this, aa())
189189 let priceAs = strf(this, pa())
190190 let iPriceAs = intf(fca, mba(priceAs))
191191 let iAmtAs = intf(fca, mba(amtAs))
192192 split(strf(fca, pc(toString(iAmtAs), toString(iPriceAs))), SEP)
193193 }
194194
195195
196196 func parseAssetId (input) = if ((input == wavesString))
197197 then unit
198198 else fromBase58String(input)
199199
200200
201201 func assetIdToString (input) = if ((input == unit))
202202 then wavesString
203203 else toBase58String(value(input))
204204
205205
206206 func parsePoolConfig (poolConfig) = $Tuple9(addressFromStringValue(poolConfig[idxPoolAddress]), parseIntValue(poolConfig[idxPoolSt]), fromBase58String(poolConfig[idxLPAsId]), parseAssetId(poolConfig[idxAmAsId]), parseAssetId(poolConfig[idxPrAsId]), parseIntValue(poolConfig[idxAmtAsDcm]), parseIntValue(poolConfig[idxPriceAsDcm]), fromBase58String(poolConfig[idxIAmtAsId]), fromBase58String(poolConfig[idxIPriceAsId]))
207207
208208
209209 let poolConfigParsed = parsePoolConfig(gpc())
210210
211211 let $t073837612 = poolConfigParsed
212212
213213 let cfgPoolAddress = $t073837612._1
214214
215215 let cfgPoolStatus = $t073837612._2
216216
217217 let cfgLpAssetId = $t073837612._3
218218
219219 let cfgAmountAssetId = $t073837612._4
220220
221221 let cfgPriceAssetId = $t073837612._5
222222
223223 let cfgAmountAssetDecimals = $t073837612._6
224224
225225 let cfgPriceAssetDecimals = $t073837612._7
226226
227227 let cfgInAmountAssedId = $t073837612._8
228228
229229 let cfgInPriceAssetId = $t073837612._9
230230
231231 func gfc () = split(strf(fca, fcfg()), SEP)
232232
233233
234234 let factoryConfig = gfc()
235235
236236 let stakingContract = valueOrErrorMessage(addressFromString(factoryConfig[idxFactStakCntr]), "Invalid staking contract address")
237237
238238 let slipageContract = valueOrErrorMessage(addressFromString(factoryConfig[idxFactSlippCntr]), "Invalid slipage contract address")
239239
240240 let gwxContract = valueOrErrorMessage(addressFromString(factoryConfig[idxFactGwxRewCntr]), "Invalid gwx contract address")
241241
242242 let restContract = valueOrErrorMessage(addressFromString(factoryConfig[idxFactoryRestCntr]), "Invalid gwx contract address")
243243
244244 func dataPutActionInfo (inAmtAssetAmt,inPriceAssetAmt,outLpAmt,price,slipByUser,slippageReal,txHeight,txTimestamp,slipageAmAmt,slipagePrAmt) = makeString(["%d%d%d%d%d%d%d%d%d%d", toString(inAmtAssetAmt), toString(inPriceAssetAmt), toString(outLpAmt), toString(price), toString(slipByUser), toString(slippageReal), toString(txHeight), toString(txTimestamp), toString(slipageAmAmt), toString(slipagePrAmt)], SEP)
245245
246246
247247 func dataGetActionInfo (outAmtAssetAmt,outPriceAssetAmt,inLpAmt,price,txHeight,txTimestamp) = makeString(["%d%d%d%d%d%d", toString(outAmtAssetAmt), toString(outPriceAssetAmt), toString(inLpAmt), toString(price), toString(txHeight), toString(txTimestamp)], SEP)
248248
249249
250250 func getAccBalance (assetId) = if ((assetId == "WAVES"))
251251 then wavesBalance(this).available
252252 else assetBalance(this, fromBase58String(assetId))
253253
254254
255255 func cpbi (prAmtX18,amAmtX18) = fraction(prAmtX18, scale18, amAmtX18)
256256
257257
258+func cpbir (prAmtX18,amAmtX18,round) = fraction(prAmtX18, scale18, amAmtX18, round)
259+
260+
258261 func vad (A1,A2,slippage) = {
259262 let diff = fraction((A1 - A2), scale8BigInt, A2)
260263 let pass = ((slippage - abs(diff)) > zeroBigInt)
261264 if (!(pass))
262265 then throw(("Big slpg: " + toString(diff)))
263266 else $Tuple2(pass, min([A1, A2]))
264267 }
265268
266269
267270 func vd (D1,D0,slpg) = {
268271 let diff = fraction(D0, scale8BigInt, D1)
269272 let fail = (slpg > diff)
270273 if (if (fail)
271274 then true
272275 else (D0 > D1))
273276 then throw(((((((toString(D0) + " ") + toString(D1)) + " ") + toString(diff)) + " ") + toString(slpg)))
274277 else fail
275278 }
276279
277280
278281 func pcp (amAssetDcm,prAssetDcm,amAmt,prAmt) = {
279282 let amtAsAmtX18 = t1(amAmt, amAssetDcm)
280283 let prAsAmtX18 = t1(prAmt, prAssetDcm)
281284 cpbi(prAsAmtX18, amtAsAmtX18)
282285 }
283286
284287
285288 func calcPrices (amAmt,prAmt,lpAmt) = {
286289 let amtAsDcm = cfgAmountAssetDecimals
287290 let prAsDcm = cfgPriceAssetDecimals
288291 let priceX18 = pcp(amtAsDcm, prAsDcm, amAmt, prAmt)
289292 let amAmtX18 = t1(amAmt, amtAsDcm)
290293 let prAmtX18 = t1(prAmt, prAsDcm)
291294 let lpAmtX18 = t1(lpAmt, scale8)
292295 let lpPrInAmAsX18 = cpbi(amAmtX18, lpAmtX18)
293296 let lpPrInPrAsX18 = cpbi(prAmtX18, lpAmtX18)
294297 [priceX18, lpPrInAmAsX18, lpPrInPrAsX18]
295298 }
296299
297300
298301 func calculatePrices (amAmt,prAmt,lpAmt) = {
299302 let p = calcPrices(amAmt, prAmt, lpAmt)
300303 [f1(p[0], scale8), f1(p[1], scale8), f1(p[2], scale8)]
301304 }
302305
303306
304307 func takeFee (amount) = {
305308 let feeAmount = fraction(amount, fee, scale8)
306309 $Tuple2((amount - feeAmount), feeAmount)
307310 }
308311
309312
310313 func ego (txId58,pmtAssetId,pmtLpAmt,userAddress) = {
311314 let lpId = cfgLpAssetId
312315 let amId = toBase58String(value(cfgAmountAssetId))
313316 let prId = toBase58String(value(cfgPriceAssetId))
314317 let amDcm = cfgAmountAssetDecimals
315318 let prDcm = cfgPriceAssetDecimals
316319 let sts = toString(cfgPoolStatus)
317320 let lpEmiss = valueOrErrorMessage(assetInfo(lpId), "Wrong LP id").quantity
318321 if ((toBase58String(lpId) != pmtAssetId))
319322 then throw("Wrong pmt asset")
320323 else {
321324 let amBalance = getAccBalance(amId)
322325 let amBalanceX18 = t1(amBalance, amDcm)
323326 let prBalance = getAccBalance(prId)
324327 let prBalanceX18 = t1(prBalance, prDcm)
325328 let curPriceX18 = cpbi(prBalanceX18, amBalanceX18)
326329 let curPrice = f1(curPriceX18, scale8)
327330 let pmtLpAmtX18 = t1(pmtLpAmt, scale8)
328331 let lpEmissX18 = t1(lpEmiss, scale8)
329332 let outAmAmtX18 = fraction(amBalanceX18, pmtLpAmtX18, lpEmissX18)
330333 let outPrAmtX18 = fraction(prBalanceX18, pmtLpAmtX18, lpEmissX18)
331334 let outAmAmt = fromX18Round(outAmAmtX18, amDcm, FLOOR)
332335 let outPrAmt = fromX18Round(outPrAmtX18, prDcm, FLOOR)
333336 let state = if ((txId58 == ""))
334337 then nil
335338 else [ScriptTransfer(userAddress, outAmAmt, if ((amId == "WAVES"))
336339 then unit
337340 else fromBase58String(amId)), ScriptTransfer(userAddress, outPrAmt, if ((prId == "WAVES"))
338341 then unit
339342 else fromBase58String(prId)), StringEntry(gau(toString(userAddress), txId58), dataGetActionInfo(outAmAmt, outPrAmt, pmtLpAmt, curPrice, height, lastBlock.timestamp)), IntegerEntry(pl(), curPrice), IntegerEntry(ph(height, lastBlock.timestamp), curPrice)]
340343 $Tuple10(outAmAmt, outPrAmt, amId, prId, amBalance, prBalance, lpEmiss, curPriceX18, sts, state)
341344 }
342345 }
343346
344347
345348 func epo (txId58,slippage,inAmAmt,inAmId,inPrAmt,inPrId,userAddress,isEval,emitLp,isOneAsset,validateSlippage,pmtAmt,pmtId) = {
346349 let lpId = cfgLpAssetId
347350 let amIdStr = toBase58String(value(cfgAmountAssetId))
348351 let prIdStr = toBase58String(value(cfgPriceAssetId))
349352 let inAmIdStr = cfgInAmountAssedId
350353 let inPrIdStr = cfgInPriceAssetId
351354 let amtDcm = cfgAmountAssetDecimals
352355 let priceDcm = cfgPriceAssetDecimals
353356 let sts = toString(cfgPoolStatus)
354357 let lpEm = valueOrErrorMessage(assetInfo(lpId), "Wr lp as").quantity
355358 let amBalance = if (isEval)
356359 then getAccBalance(amIdStr)
357360 else if (if (isOneAsset)
358361 then (pmtId == amIdStr)
359362 else false)
360363 then (getAccBalance(amIdStr) - pmtAmt)
361364 else if (isOneAsset)
362365 then getAccBalance(amIdStr)
363366 else (getAccBalance(amIdStr) - inAmAmt)
364367 let prBalance = if (isEval)
365368 then getAccBalance(prIdStr)
366369 else if (if (isOneAsset)
367370 then (pmtId == prIdStr)
368371 else false)
369372 then (getAccBalance(prIdStr) - pmtAmt)
370373 else if (isOneAsset)
371374 then getAccBalance(prIdStr)
372375 else (getAccBalance(prIdStr) - inPrAmt)
373376 let inAmAssetAmtX18 = t1(inAmAmt, amtDcm)
374377 let inPrAssetAmtX18 = t1(inPrAmt, priceDcm)
375378 let userPriceX18 = cpbi(inPrAssetAmtX18, inAmAssetAmtX18)
376379 let amBalanceX18 = t1(amBalance, amtDcm)
377380 let prBalanceX18 = t1(prBalance, priceDcm)
378381 let r = if ((lpEm == 0))
379382 then {
380383 let curPriceX18 = zeroBigInt
381384 let slippageX18 = zeroBigInt
382385 let lpAmtX18 = pow((inAmAssetAmtX18 * inPrAssetAmtX18), 0, toBigInt(5), 1, 0, DOWN)
383386 $Tuple5(f1(lpAmtX18, scale8), f1(inAmAssetAmtX18, amtDcm), f1(inPrAssetAmtX18, priceDcm), cpbi((prBalanceX18 + inPrAssetAmtX18), (amBalanceX18 + inAmAssetAmtX18)), slippageX18)
384387 }
385388 else {
386- let curPriceX18 = cpbi(prBalanceX18, amBalanceX18)
389+ let curPriceX18 = cpbir(prBalanceX18, amBalanceX18, CEILING)
387390 let slippageRealX18 = fraction(abs((curPriceX18 - userPriceX18)), scale18, curPriceX18)
388391 let slippageX18 = t1(slippage, scale8)
389392 if (if (if (validateSlippage)
390393 then (curPriceX18 != zeroBigInt)
391394 else false)
392395 then (slippageRealX18 > slippageX18)
393396 else false)
394397 then throw(((("Price slippage " + toString(slippageRealX18)) + " > ") + toString(slippageX18)))
395398 else {
396399 let lpEmissionX18 = t1(lpEm, scale8)
397400 let prViaAmX18 = fraction(inAmAssetAmtX18, curPriceX18, scale18, CEILING)
398401 let amViaPrX18 = fraction(inPrAssetAmtX18, scale18, curPriceX18, CEILING)
399402 let expectedAmts = if ((prViaAmX18 > inPrAssetAmtX18))
400403 then $Tuple2(amViaPrX18, inPrAssetAmtX18)
401404 else $Tuple2(inAmAssetAmtX18, prViaAmX18)
402405 let expAmtAssetAmtX18 = expectedAmts._1
403406 let expPriceAssetAmtX18 = expectedAmts._2
404407 let lpAmtX18 = fraction(lpEmissionX18, expPriceAssetAmtX18, prBalanceX18)
405408 $Tuple5(fromX18Round(lpAmtX18, scale8, FLOOR), fromX18Round(expAmtAssetAmtX18, amtDcm, CEILING), fromX18Round(expPriceAssetAmtX18, priceDcm, CEILING), curPriceX18, slippageX18)
406409 }
407410 }
408411 let calcLpAmt = r._1
409412 let calcAmAssetPmt = r._2
410413 let calcPrAssetPmt = r._3
411414 let curPrice = f1(r._4, scale8)
412415 let slippageCalc = f1(r._5, scale8)
413416 if ((0 >= calcLpAmt))
414417 then throw("LP <= 0")
415418 else {
416419 let emitLpAmt = if (!(emitLp))
417420 then 0
418421 else calcLpAmt
419422 let amDiff = (inAmAmt - calcAmAssetPmt)
420423 let prDiff = (inPrAmt - calcPrAssetPmt)
421- let $t01819418539 = if (if (isOneAsset)
424+ let $t01832718672 = if (if (isOneAsset)
422425 then (pmtId == amIdStr)
423426 else false)
424427 then $Tuple2(pmtAmt, 0)
425428 else if (if (isOneAsset)
426429 then (pmtId == prIdStr)
427430 else false)
428431 then $Tuple2(0, pmtAmt)
429432 else $Tuple2(calcAmAssetPmt, calcPrAssetPmt)
430- let writeAmAmt = $t01819418539._1
431- let writePrAmt = $t01819418539._2
433+ let writeAmAmt = $t01832718672._1
434+ let writePrAmt = $t01832718672._2
432435 let commonState = [IntegerEntry(pl(), curPrice), IntegerEntry(ph(height, lastBlock.timestamp), curPrice), StringEntry(pau(userAddress, txId58), dataPutActionInfo(writeAmAmt, writePrAmt, emitLpAmt, curPrice, slippage, slippageCalc, height, lastBlock.timestamp, amDiff, prDiff))]
433436 $Tuple13(calcLpAmt, emitLpAmt, curPrice, amBalance, prBalance, lpEm, lpId, sts, commonState, amDiff, prDiff, inAmId, inPrId)
434437 }
435438 }
436439
437440
438441 func getD (xp) = {
439442 let xp0 = xp[0]
440443 let xp1 = xp[1]
441444 let s = (xp0 + xp1)
442445 if ((s == big0))
443446 then big0
444447 else {
445448 let a = parseIntValue(A)
446449 let ann = (a * 2)
447450 let p = fraction(xp0, xp1, big1)
448451 let xp0_xp1_n_n = fraction(p, big4, big1)
449452 let ann_s = fraction(toBigInt(ann), s, big1)
450453 let ann_1 = toBigInt((ann - 1))
451454 func calcDNext (d) = {
452455 let dd = fraction(d, d, big1)
453456 let ddd = fraction(dd, d, big1)
454457 let dp = fraction(ddd, big1, xp0_xp1_n_n)
455458 fraction((ann_s + fraction(dp, big2, big1)), d, (fraction(ann_1, d, big1) + fraction(big3, dp, big1)), CEILING)
456459 }
457460
458461 func calc (acc,i) = if (acc._2)
459462 then acc
460463 else {
461464 let d = acc._1
462465 let dNext = calcDNext(d)
463466 let dDiffRaw = toInt((dNext - value(d)))
464467 let dDiff = if ((0 > dDiffRaw))
465468 then -(dDiffRaw)
466469 else dDiffRaw
467470 if ((1 >= dDiff))
468471 then $Tuple2(dNext, true)
469472 else $Tuple2(dNext, false)
470473 }
471474
472475 let arr = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14]
473- let $t02046720515 = {
476+ let $t02060020648 = {
474477 let $l = arr
475478 let $s = size($l)
476479 let $acc0 = $Tuple2(s, false)
477480 func $f0_1 ($a,$i) = if (($i >= $s))
478481 then $a
479482 else calc($a, $l[$i])
480483
481484 func $f0_2 ($a,$i) = if (($i >= $s))
482485 then $a
483486 else throw("List size exceeds 15")
484487
485488 $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15)
486489 }
487- let d = $t02046720515._1
488- let found = $t02046720515._2
490+ let d = $t02060020648._1
491+ let found = $t02060020648._2
489492 if (found)
490493 then d
491494 else throw(("D calculation error, D = " + toString(d)))
492495 }
493496 }
494497
495498
496499 func getDOld (xp) = {
497500 let n = big2
498501 let xp0 = xp[0]
499502 let xp1 = xp[1]
500503 let aPrecision = parseBigIntValue(Amult)
501504 let a = (parseBigIntValue(A) * aPrecision)
502505 let s = (xp0 + xp1)
503506 if ((s == big0))
504507 then big0
505508 else {
506509 let ann = (a * n)
507510 let xp0_xp1_n_n = (((xp0 * xp1) * n) * n)
508511 let ann_s_aPrecision = ((ann * s) / aPrecision)
509512 let ann_aPrecision = (ann - aPrecision)
510513 let n1 = (n + big1)
511514 func calc (acc,cur) = {
512- let $t02114421164 = acc
513- let d = $t02114421164._1
514- let found = $t02114421164._2
515+ let $t02127721297 = acc
516+ let d = $t02127721297._1
517+ let found = $t02127721297._2
515518 if ((found != unit))
516519 then acc
517520 else {
518521 let dp = (((d * d) * d) / xp0_xp1_n_n)
519522 let dNext = (((ann_s_aPrecision + (dp * n)) * d) / (((ann_aPrecision * d) / aPrecision) + (n1 * dp)))
520523 let dDiff = absBigInt((dNext - value(d)))
521524 if ((big1 >= dDiff))
522525 then $Tuple2(dNext, cur)
523526 else $Tuple2(dNext, unit)
524527 }
525528 }
526529
527530 let arr = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14]
528- let $t02158521632 = {
531+ let $t02171821765 = {
529532 let $l = arr
530533 let $s = size($l)
531534 let $acc0 = $Tuple2(s, unit)
532535 func $f0_1 ($a,$i) = if (($i >= $s))
533536 then $a
534537 else calc($a, $l[$i])
535538
536539 func $f0_2 ($a,$i) = if (($i >= $s))
537540 then $a
538541 else throw("List size exceeds 15")
539542
540543 $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15)
541544 }
542- let d = $t02158521632._1
543- let found = $t02158521632._2
545+ let d = $t02171821765._1
546+ let found = $t02171821765._2
544547 if ((found != unit))
545548 then d
546549 else throw(("D calculation error, D = " + toString(d)))
547550 }
548551 }
549552
550553
551554 func getYD (xp,i,D) = {
552555 let n = big2
553556 let x = xp[if ((i == 0))
554557 then 1
555558 else 0]
556559 let aPrecision = parseBigIntValue(Amult)
557560 let a = (parseBigIntValue(A) * aPrecision)
558561 let s = x
559562 let ann = (a * n)
560563 let c = (((((D * D) / (x * n)) * D) * aPrecision) / (ann * n))
561564 let b = ((s + ((D * aPrecision) / ann)) - D)
562565 func calc (acc,cur) = {
563- let $t02213222152 = acc
564- let y = $t02213222152._1
565- let found = $t02213222152._2
566+ let $t02226522285 = acc
567+ let y = $t02226522285._1
568+ let found = $t02226522285._2
566569 if ((found != unit))
567570 then acc
568571 else {
569572 let yNext = (((y * y) + c) / ((big2 * y) + b))
570573 let yDiff = absBigInt((yNext - value(y)))
571574 if ((big1 >= yDiff))
572575 then $Tuple2(yNext, cur)
573576 else $Tuple2(yNext, unit)
574577 }
575578 }
576579
577580 let arr = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14]
578- let $t02245922506 = {
581+ let $t02259222639 = {
579582 let $l = arr
580583 let $s = size($l)
581584 let $acc0 = $Tuple2(D, unit)
582585 func $f0_1 ($a,$i) = if (($i >= $s))
583586 then $a
584587 else calc($a, $l[$i])
585588
586589 func $f0_2 ($a,$i) = if (($i >= $s))
587590 then $a
588591 else throw("List size exceeds 15")
589592
590593 $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15)
591594 }
592- let y = $t02245922506._1
593- let found = $t02245922506._2
595+ let y = $t02259222639._1
596+ let found = $t02259222639._2
594597 if ((found != unit))
595598 then y
596599 else throw(("Y calculation error, Y = " + toString(y)))
597600 }
598601
599602
600603 func calcDLp (amountBalance,priceBalance,lpEmission) = {
601604 let updatedDLp = fraction(getD([amountBalance, priceBalance]), scale18, lpEmission)
602605 if ((lpEmission == big0))
603606 then big0
604607 else updatedDLp
605608 }
606609
607610
608611 func calcCurrentDLp (amountAssetDelta,priceAssetDelta,lpAssetEmissionDelta) = {
609612 let amountAssetBalance = (toBigInt(getAccBalance(assetIdToString(cfgAmountAssetId))) - amountAssetDelta)
610613 let priceAssetBalance = (toBigInt(getAccBalance(assetIdToString(cfgPriceAssetId))) - priceAssetDelta)
611614 let lpAssetEmission = (toBigInt(value(assetInfo(cfgLpAssetId)).quantity) - lpAssetEmissionDelta)
612615 let currentDLp = calcDLp(amountAssetBalance, priceAssetBalance, lpAssetEmission)
613616 currentDLp
614617 }
615618
616619
617620 func refreshDLpInternal (amountAssetBalanceDelta,priceAssetBalanceDelta,lpAssetEmissionDelta) = {
618621 let amountAssetBalance = (getAccBalance(assetIdToString(cfgAmountAssetId)) + amountAssetBalanceDelta)
619622 let priceAssetBalance = (getAccBalance(assetIdToString(cfgPriceAssetId)) + priceAssetBalanceDelta)
620623 let lpAssetEmission = (value(assetInfo(cfgLpAssetId)).quantity + lpAssetEmissionDelta)
621624 let updatedDLp = calcDLp(toBigInt(amountAssetBalance), toBigInt(priceAssetBalance), toBigInt(lpAssetEmission))
622625 let actions = [IntegerEntry(keyDLpRefreshedHeight, height), StringEntry(keyDLp, toString(updatedDLp))]
623626 $Tuple2(actions, updatedDLp)
624627 }
625628
626629
627630 func validateUpdatedDLp (oldDLp,updatedDLp) = if ((updatedDLp >= oldDLp))
628631 then true
629632 else throwErr("updated DLp lower than current DLp")
630633
631634
632635 func validateMatcherOrderAllowed (order) = {
633636 let amountAssetAmount = order.amount
634637 let priceAssetAmount = fraction(order.amount, order.price, scale8, FLOOR)
635- let $t02444524657 = if ((order.orderType == Buy))
638+ let $t02457824790 = if ((order.orderType == Buy))
636639 then $Tuple2(amountAssetAmount, -(priceAssetAmount))
637640 else $Tuple2(-(amountAssetAmount), priceAssetAmount)
638- let amountAssetBalanceDelta = $t02444524657._1
639- let priceAssetBalanceDelta = $t02444524657._2
641+ let amountAssetBalanceDelta = $t02457824790._1
642+ let priceAssetBalanceDelta = $t02457824790._2
640643 if (if (if (igs())
641644 then true
642645 else (cfgPoolStatus == PoolMatcherDis))
643646 then true
644647 else (cfgPoolStatus == PoolShutdown))
645648 then throw("Admin blocked")
646649 else if (if ((order.assetPair.amountAsset != cfgAmountAssetId))
647650 then true
648651 else (order.assetPair.priceAsset != cfgPriceAssetId))
649652 then throw("Wr assets")
650653 else {
651654 let dLp = parseBigIntValue(getStringValue(this, keyDLp))
652- let $t02498725087 = refreshDLpInternal(amountAssetBalanceDelta, priceAssetBalanceDelta, 0)
653- let unusedActions = $t02498725087._1
654- let dLpNew = $t02498725087._2
655+ let $t02512025220 = refreshDLpInternal(amountAssetBalanceDelta, priceAssetBalanceDelta, 0)
656+ let unusedActions = $t02512025220._1
657+ let dLpNew = $t02512025220._2
655658 let isOrderValid = (dLpNew >= dLp)
656659 isOrderValid
657660 }
658661 }
659662
660663
661664 func cg (i) = if ((size(i.payments) != 1))
662665 then throw("1 pmnt exp")
663666 else {
664667 let pmt = value(i.payments[0])
665668 let pmtAssetId = value(pmt.assetId)
666669 let pmtAmt = pmt.amount
667670 let r = ego(toBase58String(i.transactionId), toBase58String(pmtAssetId), pmtAmt, i.caller)
668671 let outAmAmt = r._1
669672 let outPrAmt = r._2
670673 let sts = parseIntValue(r._9)
671674 let state = r._10
672675 if (if (igs())
673676 then true
674677 else (sts == PoolShutdown))
675678 then throw(("Admin blocked: " + toString(sts)))
676679 else $Tuple5(outAmAmt, outPrAmt, pmtAmt, pmtAssetId, state)
677680 }
678681
679682
680683 func cp (caller,txId,amAsPmt,prAsPmt,slippage,emitLp,isOneAsset,validateSlippage,pmtAmt,pmtId) = {
681684 let r = epo(txId, slippage, value(amAsPmt).amount, value(amAsPmt).assetId, value(prAsPmt).amount, value(prAsPmt).assetId, caller, (txId == ""), emitLp, isOneAsset, validateSlippage, pmtAmt, pmtId)
682685 let sts = parseIntValue(r._8)
683686 if (if (if (igs())
684687 then true
685688 else (sts == PoolPutDis))
686689 then true
687690 else (sts == PoolShutdown))
688691 then throw(("Blocked:" + toString(sts)))
689692 else r
690693 }
691694
692695
693696 func calcPutOneTkn (pmtAmtRaw,pmtAssetId,userAddress,txId,withTakeFee) = {
694697 let amId = toBase58String(value(cfgAmountAssetId))
695698 let prId = toBase58String(value(cfgPriceAssetId))
696699 let lpId = cfgLpAssetId
697700 let amtDcm = cfgAmountAssetDecimals
698701 let priceDcm = cfgPriceAssetDecimals
699702 let lpAssetEmission = toBigInt(valueOrErrorMessage(assetInfo(lpId), "invalid lp asset").quantity)
700703 let chechEmission = if ((lpAssetEmission > big0))
701704 then true
702705 else throw("initial deposit requires all coins")
703706 if ((chechEmission == chechEmission))
704707 then {
705708 let amBalance = getAccBalance(amId)
706709 let prBalance = getAccBalance(prId)
707- let $t02735327815 = if ((txId == ""))
710+ let $t02748627948 = if ((txId == ""))
708711 then $Tuple2(amBalance, prBalance)
709712 else if ((pmtAssetId == amId))
710713 then if ((pmtAmtRaw > amBalance))
711714 then throw("invalid payment amount")
712715 else $Tuple2((amBalance - pmtAmtRaw), prBalance)
713716 else if ((pmtAssetId == prId))
714717 then if ((pmtAmtRaw > prBalance))
715718 then throw("invalid payment amount")
716719 else $Tuple2(amBalance, (prBalance - pmtAmtRaw))
717720 else throw("wrong pmtAssetId")
718- let amBalanceOld = $t02735327815._1
719- let prBalanceOld = $t02735327815._2
720- let $t02782127997 = if ((pmtAssetId == amId))
721+ let amBalanceOld = $t02748627948._1
722+ let prBalanceOld = $t02748627948._2
723+ let $t02795428130 = if ((pmtAssetId == amId))
721724 then $Tuple2(pmtAmtRaw, 0)
722725 else if ((pmtAssetId == prId))
723726 then $Tuple2(0, pmtAmtRaw)
724727 else throw("invalid payment")
725- let amAmountRaw = $t02782127997._1
726- let prAmountRaw = $t02782127997._2
727- let $t02800128240 = if (withTakeFee)
728+ let amAmountRaw = $t02795428130._1
729+ let prAmountRaw = $t02795428130._2
730+ let $t02813428373 = if (withTakeFee)
728731 then $Tuple3(takeFee(amAmountRaw)._1, takeFee(prAmountRaw)._1, takeFee(pmtAmtRaw)._2)
729732 else $Tuple3(amAmountRaw, prAmountRaw, 0)
730- let amAmount = $t02800128240._1
731- let prAmount = $t02800128240._2
732- let feeAmount = $t02800128240._3
733+ let amAmount = $t02813428373._1
734+ let prAmount = $t02813428373._2
735+ let feeAmount = $t02813428373._3
733736 let amBalanceNew = (amBalanceOld + amAmount)
734737 let prBalanceNew = (prBalanceOld + prAmount)
735738 let D0 = getD([toBigInt(amBalanceOld), toBigInt(prBalanceOld)])
736739 let D1 = getD([toBigInt(amBalanceNew), toBigInt(prBalanceNew)])
737740 let checkD = if ((D1 > D0))
738741 then true
739742 else throw()
740743 if ((checkD == checkD))
741744 then {
742745 let lpAmount = fraction(lpAssetEmission, (D1 - D0), D0, FLOOR)
743746 let curPrice = f1(cpbi(t1(prBalanceNew, priceDcm), t1(amBalanceNew, amtDcm)), scale8)
744747 let commonState = [IntegerEntry(pl(), curPrice), IntegerEntry(ph(height, lastBlock.timestamp), curPrice), StringEntry(pau(userAddress, txId), dataPutActionInfo(amAmountRaw, prAmountRaw, toInt(lpAmount), curPrice, 0, 0, height, lastBlock.timestamp, 0, 0))]
745748 let poolProportion = fraction(prBalanceOld, scale8, amBalanceOld)
746749 let amountAssetPart = fraction(pmtAmtRaw, scale8, (poolProportion + scale8))
747750 let priceAssetPart = (pmtAmtRaw - amountAssetPart)
748751 let lpAmtBoth = fraction(lpAssetEmission, toBigInt(priceAssetPart), toBigInt(prBalanceOld))
749752 let bonus = toInt(fraction((lpAmount - lpAmtBoth), scale8BigInt, lpAmtBoth))
750753 $Tuple4(toInt(lpAmount), commonState, feeAmount, bonus)
751754 }
752755 else throw("Strict value is not equal to itself.")
753756 }
754757 else throw("Strict value is not equal to itself.")
755758 }
756759
757760
758761 func getOneTknV2Internal (outAssetId,minOutAmount,payments,caller,originCaller,transactionId) = {
759762 let lpId = toBase58String(value(cfgLpAssetId))
760763 let amId = toBase58String(value(cfgAmountAssetId))
761764 let prId = toBase58String(value(cfgPriceAssetId))
762765 let amDecimals = cfgAmountAssetDecimals
763766 let prDecimals = cfgPriceAssetDecimals
764767 let poolStatus = cfgPoolStatus
765768 let userAddress = if ((caller == restContract))
766769 then originCaller
767770 else caller
768771 let pmt = value(payments[0])
769772 let pmtAssetId = value(pmt.assetId)
770773 let pmtAmt = pmt.amount
771774 let currentDLp = calcCurrentDLp(big0, big0, big0)
772775 if ((currentDLp == currentDLp))
773776 then {
774777 let txId58 = toBase58String(transactionId)
775778 if ((lpId != toBase58String(pmtAssetId)))
776779 then throw("Wrong LP")
777780 else {
778781 let amBalance = getAccBalance(amId)
779782 let prBalance = getAccBalance(prId)
780- let $t03029030401 = {
783+ let $t03042330534 = {
781784 let @ = invoke(this, "getOneTknV2READONLY", [outAssetId, pmtAmt], nil)
782785 if ($isInstanceOf(@, "(Int, Int)"))
783786 then @
784787 else throw(($getType(@) + " couldn't be cast to (Int, Int)"))
785788 }
786- if (($t03029030401 == $t03029030401))
789+ if (($t03042330534 == $t03042330534))
787790 then {
788- let feeAmount = $t03029030401._2
789- let totalGet = $t03029030401._1
791+ let feeAmount = $t03042330534._2
792+ let totalGet = $t03042330534._1
790793 let totalAmount = if (if ((minOutAmount > 0))
791794 then (minOutAmount > totalGet)
792795 else false)
793796 then throwErr(makeString(["amount to receive is less than ", toString(minOutAmount)], ""))
794797 else totalGet
795- let $t03059130898 = if ((outAssetId == amId))
798+ let $t03072431031 = if ((outAssetId == amId))
796799 then $Tuple4(totalAmount, 0, ((amBalance - totalAmount) - feeAmount), prBalance)
797800 else if ((outAssetId == prId))
798801 then $Tuple4(0, totalAmount, amBalance, ((prBalance - totalAmount) - feeAmount))
799802 else throw("invalid out asset id")
800- let outAm = $t03059130898._1
801- let outPr = $t03059130898._2
802- let amBalanceNew = $t03059130898._3
803- let prBalanceNew = $t03059130898._4
803+ let outAm = $t03072431031._1
804+ let outPr = $t03072431031._2
805+ let amBalanceNew = $t03072431031._3
806+ let prBalanceNew = $t03072431031._4
804807 let curPrX18 = cpbi(t1(prBalanceNew, prDecimals), t1(amBalanceNew, amDecimals))
805808 let curPr = f1(curPrX18, scale8)
806809 let outAssetIdOrWaves = if ((outAssetId == "WAVES"))
807810 then unit
808811 else fromBase58String(outAssetId)
809812 let sendFeeToMatcher = if ((feeAmount > 0))
810813 then [ScriptTransfer(feeCollectorAddress, feeAmount, outAssetIdOrWaves)]
811814 else nil
812815 let state = ([ScriptTransfer(userAddress, totalAmount, outAssetIdOrWaves), StringEntry(gau(toString(userAddress), txId58), dataGetActionInfo(outAm, outPr, pmtAmt, curPr, height, lastBlock.timestamp)), IntegerEntry(pl(), curPr), IntegerEntry(ph(height, lastBlock.timestamp), curPr)] ++ sendFeeToMatcher)
813816 if ((state == state))
814817 then {
815818 let burn = invoke(fca, "burn", [pmtAmt], [AttachedPayment(pmtAssetId, pmtAmt)])
816819 if ((burn == burn))
817820 then {
818- let $t03168332033 = {
821+ let $t03181632166 = {
819822 let feeAmountForCalc = if ((this == feeCollectorAddress))
820823 then 0
821824 else feeAmount
822825 let outInAmountAsset = if ((parseAssetId(outAssetId) == cfgAmountAssetId))
823826 then true
824827 else false
825828 if (outInAmountAsset)
826829 then $Tuple2(-((totalGet + feeAmountForCalc)), 0)
827830 else $Tuple2(0, -((totalGet + feeAmountForCalc)))
828831 }
829- let amountAssetBalanceDelta = $t03168332033._1
830- let priceAssetBalanceDelta = $t03168332033._2
831- let $t03203632144 = refreshDLpInternal(amountAssetBalanceDelta, priceAssetBalanceDelta, 0)
832- let refreshDLpActions = $t03203632144._1
833- let updatedDLp = $t03203632144._2
832+ let amountAssetBalanceDelta = $t03181632166._1
833+ let priceAssetBalanceDelta = $t03181632166._2
834+ let $t03216932277 = refreshDLpInternal(amountAssetBalanceDelta, priceAssetBalanceDelta, 0)
835+ let refreshDLpActions = $t03216932277._1
836+ let updatedDLp = $t03216932277._2
834837 let isUpdatedDLpValid = validateUpdatedDLp(currentDLp, updatedDLp)
835838 if ((isUpdatedDLpValid == isUpdatedDLpValid))
836839 then $Tuple2((state ++ refreshDLpActions), totalAmount)
837840 else throw("Strict value is not equal to itself.")
838841 }
839842 else throw("Strict value is not equal to itself.")
840843 }
841844 else throw("Strict value is not equal to itself.")
842845 }
843846 else throw("Strict value is not equal to itself.")
844847 }
845848 }
846849 else throw("Strict value is not equal to itself.")
847850 }
848851
849852
850853 func m () = match getString(mpk()) {
851854 case s: String =>
852855 fromBase58String(s)
853856 case _: Unit =>
854857 unit
855858 case _ =>
856859 throw("Match error")
857860 }
858861
859862
860863 func pm () = match getString(pmpk()) {
861864 case s: String =>
862865 fromBase58String(s)
863866 case _: Unit =>
864867 unit
865868 case _ =>
866869 throw("Match error")
867870 }
868871
869872
870873 let pd = throw("Permission denied")
871874
872875 func isManager (i) = match m() {
873876 case pk: ByteVector =>
874877 (i.callerPublicKey == pk)
875878 case _: Unit =>
876879 (i.caller == this)
877880 case _ =>
878881 throw("Match error")
879882 }
880883
881884
882885 func mm (i) = match m() {
883886 case pk: ByteVector =>
884887 if ((i.callerPublicKey == pk))
885888 then true
886889 else pd
887890 case _: Unit =>
888891 if ((i.caller == this))
889892 then true
890893 else pd
891894 case _ =>
892895 throw("Match error")
893896 }
894897
895898
896899 @Callable(i)
897900 func constructor (fc) = {
898901 let c = mm(i)
899902 if ((c == c))
900903 then [StringEntry(fc(), fc)]
901904 else throw("Strict value is not equal to itself.")
902905 }
903906
904907
905908
906909 @Callable(i)
907910 func setManager (pendingManagerPublicKey) = {
908911 let c = mm(i)
909912 if ((c == c))
910913 then {
911914 let cm = fromBase58String(pendingManagerPublicKey)
912915 if ((cm == cm))
913916 then [StringEntry(pmpk(), pendingManagerPublicKey)]
914917 else throw("Strict value is not equal to itself.")
915918 }
916919 else throw("Strict value is not equal to itself.")
917920 }
918921
919922
920923
921924 @Callable(i)
922925 func confirmManager () = {
923926 let p = pm()
924927 let hpm = if (isDefined(p))
925928 then true
926929 else throw("No pending manager")
927930 if ((hpm == hpm))
928931 then {
929932 let cpm = if ((i.callerPublicKey == value(p)))
930933 then true
931934 else throw("You are not pending manager")
932935 if ((cpm == cpm))
933936 then [StringEntry(mpk(), toBase58String(value(p))), DeleteEntry(pmpk())]
934937 else throw("Strict value is not equal to itself.")
935938 }
936939 else throw("Strict value is not equal to itself.")
937940 }
938941
939942
940943
941944 @Callable(i)
942945 func put (slip,autoStake) = {
943946 let factCfg = gfc()
944947 let stakingCntr = valueOrErrorMessage(addressFromString(factCfg[idxFactStakCntr]), "Wr st addr")
945948 let slipCntr = valueOrErrorMessage(addressFromString(factCfg[idxFactSlippCntr]), "Wr sl addr")
946949 if ((0 > slip))
947950 then throw("Wrong slippage")
948951 else if ((size(i.payments) != 2))
949952 then throw("2 pmnts expd")
950953 else {
951954 let amAssetPmt = toBigInt(value(i.payments[0]).amount)
952955 let prAssetPmt = toBigInt(value(i.payments[1]).amount)
953956 let amountAssetBalance = (toBigInt(getAccBalance(assetIdToString(cfgAmountAssetId))) - amAssetPmt)
954957 if ((amountAssetBalance == amountAssetBalance))
955958 then {
956959 let priceAssetBalance = (toBigInt(getAccBalance(assetIdToString(cfgPriceAssetId))) - prAssetPmt)
957960 if ((priceAssetBalance == priceAssetBalance))
958961 then {
959962 let lpAssetEmission = toBigInt(value(assetInfo(cfgLpAssetId)).quantity)
960963 if ((lpAssetEmission == lpAssetEmission))
961964 then {
962965 let currentDLp = calcCurrentDLp(amAssetPmt, prAssetPmt, toBigInt(0))
963966 if ((currentDLp == currentDLp))
964967 then {
965968 let e = cp(toString(i.caller), toBase58String(i.transactionId), AttachedPayment(value(i.payments[0]).assetId, value(i.payments[0]).amount), i.payments[1], slip, true, false, true, 0, "")
966969 let emitLpAmt = e._2
967970 let lpAssetId = e._7
968971 let state = e._9
969972 let amDiff = e._10
970973 let prDiff = e._11
971974 let amId = e._12
972975 let prId = e._13
973976 let r = invoke(fca, "emit", [emitLpAmt], nil)
974977 if ((r == r))
975978 then {
976979 let el = match r {
977980 case legacy: Address =>
978981 invoke(legacy, "emit", [emitLpAmt], nil)
979982 case _ =>
980983 unit
981984 }
982985 if ((el == el))
983986 then {
984987 let sa = if ((amDiff > 0))
985988 then invoke(slipCntr, "put", nil, [AttachedPayment(amId, amDiff)])
986989 else nil
987990 if ((sa == sa))
988991 then {
989992 let sp = if ((prDiff > 0))
990993 then invoke(slipCntr, "put", nil, [AttachedPayment(prId, prDiff)])
991994 else nil
992995 if ((sp == sp))
993996 then {
994997 let lpTrnsfr = if (autoStake)
995998 then {
996999 let ss = invoke(stakingCntr, "stake", nil, [AttachedPayment(lpAssetId, emitLpAmt)])
9971000 if ((ss == ss))
9981001 then nil
9991002 else throw("Strict value is not equal to itself.")
10001003 }
10011004 else [ScriptTransfer(i.caller, emitLpAmt, lpAssetId)]
1002- let $t03629336435 = refreshDLpInternal(0, 0, 0)
1003- let refreshDLpActions = $t03629336435._1
1004- let updatedDLp = $t03629336435._2
1005+ let $t03642636568 = refreshDLpInternal(0, 0, 0)
1006+ let refreshDLpActions = $t03642636568._1
1007+ let updatedDLp = $t03642636568._2
10051008 let check = if ((updatedDLp >= currentDLp))
10061009 then true
10071010 else throwErr(makeString(["updated DLp lower than current DLp", toString(amountAssetBalance), toString(priceAssetBalance), toString(lpAssetEmission), toString(currentDLp), toString(updatedDLp)], " "))
10081011 if ((check == check))
10091012 then {
10101013 let lpAssetEmissionAfter = value(assetInfo(cfgLpAssetId)).quantity
10111014 if ((lpAssetEmissionAfter == lpAssetEmissionAfter))
10121015 then ((state ++ lpTrnsfr) ++ refreshDLpActions)
10131016 else throw("Strict value is not equal to itself.")
10141017 }
10151018 else throw("Strict value is not equal to itself.")
10161019 }
10171020 else throw("Strict value is not equal to itself.")
10181021 }
10191022 else throw("Strict value is not equal to itself.")
10201023 }
10211024 else throw("Strict value is not equal to itself.")
10221025 }
10231026 else throw("Strict value is not equal to itself.")
10241027 }
10251028 else throw("Strict value is not equal to itself.")
10261029 }
10271030 else throw("Strict value is not equal to itself.")
10281031 }
10291032 else throw("Strict value is not equal to itself.")
10301033 }
10311034 else throw("Strict value is not equal to itself.")
10321035 }
10331036 }
10341037
10351038
10361039
10371040 @Callable(i)
10381041 func putOneTknV2 (minOutAmount,autoStake) = {
10391042 let isPoolOneTokenOperationsDisabled = {
10401043 let @ = invoke(fca, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
10411044 if ($isInstanceOf(@, "Boolean"))
10421045 then @
10431046 else throw(($getType(@) + " couldn't be cast to Boolean"))
10441047 }
10451048 let isPutDisabled = if (if (if (igs())
10461049 then true
10471050 else (cfgPoolStatus == PoolPutDis))
10481051 then true
10491052 else (cfgPoolStatus == PoolShutdown))
10501053 then true
10511054 else isPoolOneTokenOperationsDisabled
10521055 let checks = [if (if (!(isPutDisabled))
10531056 then true
10541057 else isManager(i))
10551058 then true
10561059 else throwErr("put operation is blocked by admin"), if ((size(i.payments) == 1))
10571060 then true
10581061 else throwErr("exactly 1 payment are expected")]
10591062 if ((checks == checks))
10601063 then {
10611064 let amId = toBase58String(value(cfgAmountAssetId))
10621065 let prId = toBase58String(value(cfgPriceAssetId))
10631066 let lpId = cfgLpAssetId
10641067 let amDecimals = cfgAmountAssetDecimals
10651068 let prDecimals = cfgPriceAssetDecimals
10661069 let userAddress = if ((i.caller == this))
10671070 then i.originCaller
10681071 else i.caller
10691072 let pmt = value(i.payments[0])
10701073 let pmtAssetId = toBase58String(value(pmt.assetId))
10711074 let pmtAmt = pmt.amount
10721075 let currentDLp = if ((pmt.assetId == cfgAmountAssetId))
10731076 then calcCurrentDLp(toBigInt(pmtAmt), toBigInt(0), toBigInt(0))
10741077 else calcCurrentDLp(toBigInt(0), toBigInt(pmtAmt), toBigInt(0))
10751078 if ((currentDLp == currentDLp))
10761079 then {
1077- let $t03813138289 = calcPutOneTkn(pmtAmt, pmtAssetId, toString(userAddress), toBase58String(i.transactionId), true)
1078- if (($t03813138289 == $t03813138289))
1080+ let $t03836938527 = calcPutOneTkn(pmtAmt, pmtAssetId, toString(userAddress), toBase58String(i.transactionId), true)
1081+ if (($t03836938527 == $t03836938527))
10791082 then {
1080- let feeAmount = $t03813138289._3
1081- let state = $t03813138289._2
1082- let estimLP = $t03813138289._1
1083+ let feeAmount = $t03836938527._3
1084+ let state = $t03836938527._2
1085+ let estimLP = $t03836938527._1
10831086 let emitLpAmt = if (if ((minOutAmount > 0))
10841087 then (minOutAmount > estimLP)
10851088 else false)
10861089 then throwErr(makeString(["amount to receive is less than ", toString(minOutAmount)], ""))
10871090 else estimLP
10881091 let e = invoke(fca, "emit", [emitLpAmt], nil)
10891092 if ((e == e))
10901093 then {
10911094 let el = match e {
10921095 case legacy: Address =>
10931096 invoke(legacy, "emit", [emitLpAmt], nil)
10941097 case _ =>
10951098 unit
10961099 }
10971100 if ((el == el))
10981101 then {
10991102 let lpTrnsfr = if (autoStake)
11001103 then {
11011104 let ss = invoke(stakingContract, "stake", nil, [AttachedPayment(lpId, emitLpAmt)])
11021105 if ((ss == ss))
11031106 then nil
11041107 else throw("Strict value is not equal to itself.")
11051108 }
11061109 else [ScriptTransfer(i.caller, emitLpAmt, lpId)]
11071110 let sendFeeToMatcher = if ((feeAmount > 0))
11081111 then [ScriptTransfer(feeCollectorAddress, feeAmount, fromBase58String(pmtAssetId))]
11091112 else nil
1110- let $t03910439453 = if ((this == feeCollectorAddress))
1113+ let $t03934239691 = if ((this == feeCollectorAddress))
11111114 then $Tuple2(0, 0)
11121115 else {
11131116 let paymentInAmountAsset = if ((pmt.assetId == cfgAmountAssetId))
11141117 then true
11151118 else false
11161119 if (paymentInAmountAsset)
11171120 then $Tuple2(-(feeAmount), 0)
11181121 else $Tuple2(0, -(feeAmount))
11191122 }
1120- let amountAssetBalanceDelta = $t03910439453._1
1121- let priceAssetBalanceDelta = $t03910439453._2
1122- let $t03945639564 = refreshDLpInternal(amountAssetBalanceDelta, priceAssetBalanceDelta, 0)
1123- let refreshDLpActions = $t03945639564._1
1124- let updatedDLp = $t03945639564._2
1123+ let amountAssetBalanceDelta = $t03934239691._1
1124+ let priceAssetBalanceDelta = $t03934239691._2
1125+ let $t03969439802 = refreshDLpInternal(amountAssetBalanceDelta, priceAssetBalanceDelta, 0)
1126+ let refreshDLpActions = $t03969439802._1
1127+ let updatedDLp = $t03969439802._2
11251128 let isUpdatedDLpValid = validateUpdatedDLp(currentDLp, updatedDLp)
11261129 if ((isUpdatedDLpValid == isUpdatedDLpValid))
11271130 then $Tuple2((((state ++ lpTrnsfr) ++ sendFeeToMatcher) ++ refreshDLpActions), emitLpAmt)
11281131 else throw("Strict value is not equal to itself.")
11291132 }
11301133 else throw("Strict value is not equal to itself.")
11311134 }
11321135 else throw("Strict value is not equal to itself.")
11331136 }
11341137 else throw("Strict value is not equal to itself.")
11351138 }
11361139 else throw("Strict value is not equal to itself.")
11371140 }
11381141 else throw("Strict value is not equal to itself.")
11391142 }
11401143
11411144
11421145
11431146 @Callable(i)
11441147 func putForFree (maxSlpg) = if ((0 > maxSlpg))
11451148 then throw("Wrong slpg")
11461149 else if ((size(i.payments) != 2))
11471150 then throw("2 pmnts expd")
11481151 else {
11491152 let estPut = cp(toString(i.caller), toBase58String(i.transactionId), AttachedPayment(value(i.payments[0]).assetId, value(i.payments[0]).amount), i.payments[1], maxSlpg, false, false, true, 0, "")
11501153 let state = estPut._9
11511154 let amAssetPmt = toBigInt(value(i.payments[0]).amount)
11521155 let prAssetPmt = toBigInt(value(i.payments[1]).amount)
11531156 let currentDLp = calcCurrentDLp(amAssetPmt, prAssetPmt, toBigInt(0))
11541157 if ((currentDLp == currentDLp))
11551158 then {
1156- let $t04059440659 = refreshDLpInternal(0, 0, 0)
1157- let refreshDLpActions = $t04059440659._1
1158- let updatedDLp = $t04059440659._2
1159+ let $t04083240897 = refreshDLpInternal(0, 0, 0)
1160+ let refreshDLpActions = $t04083240897._1
1161+ let updatedDLp = $t04083240897._2
11591162 let isUpdatedDLpValid = validateUpdatedDLp(currentDLp, updatedDLp)
11601163 if ((isUpdatedDLpValid == isUpdatedDLpValid))
11611164 then (state ++ refreshDLpActions)
11621165 else throw("Strict value is not equal to itself.")
11631166 }
11641167 else throw("Strict value is not equal to itself.")
11651168 }
11661169
11671170
11681171
11691172 @Callable(i)
11701173 func get () = {
11711174 let currentDLp = calcCurrentDLp(toBigInt(0), toBigInt(0), toBigInt(0))
11721175 if ((currentDLp == currentDLp))
11731176 then {
11741177 let r = cg(i)
11751178 let outAmtAmt = r._1
11761179 let outPrAmt = r._2
11771180 let pmtAmt = r._3
11781181 let pmtAssetId = r._4
11791182 let state = r._5
11801183 let b = invoke(fca, "burn", [pmtAmt], [AttachedPayment(pmtAssetId, pmtAmt)])
11811184 if ((b == b))
11821185 then {
1183- let $t04183241914 = refreshDLpInternal(-(outAmtAmt), -(outPrAmt), 0)
1184- let refreshDLpActions = $t04183241914._1
1185- let updatedDLp = $t04183241914._2
1186+ let $t04207042152 = refreshDLpInternal(-(outAmtAmt), -(outPrAmt), 0)
1187+ let refreshDLpActions = $t04207042152._1
1188+ let updatedDLp = $t04207042152._2
11861189 let isUpdatedDLpValid = validateUpdatedDLp(currentDLp, updatedDLp)
11871190 if ((isUpdatedDLpValid == isUpdatedDLpValid))
11881191 then (state ++ refreshDLpActions)
11891192 else throw("Strict value is not equal to itself.")
11901193 }
11911194 else throw("Strict value is not equal to itself.")
11921195 }
11931196 else throw("Strict value is not equal to itself.")
11941197 }
11951198
11961199
11971200
11981201 @Callable(i)
11991202 func getOneTknV2 (outAssetId,minOutAmount) = {
12001203 let isPoolOneTokenOperationsDisabled = {
12011204 let @ = invoke(fca, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
12021205 if ($isInstanceOf(@, "Boolean"))
12031206 then @
12041207 else throw(($getType(@) + " couldn't be cast to Boolean"))
12051208 }
12061209 let isGetDisabled = if (if (igs())
12071210 then true
12081211 else (cfgPoolStatus == PoolShutdown))
12091212 then true
12101213 else isPoolOneTokenOperationsDisabled
12111214 let checks = [if (if (!(isGetDisabled))
12121215 then true
12131216 else isManager(i))
12141217 then true
12151218 else throwErr("get operation is blocked by admin"), if ((size(i.payments) == 1))
12161219 then true
12171220 else throwErr("exactly 1 payment are expected")]
12181221 if ((checks == checks))
12191222 then {
1220- let $t04253242687 = getOneTknV2Internal(outAssetId, minOutAmount, i.payments, i.caller, i.originCaller, i.transactionId)
1221- let state = $t04253242687._1
1222- let totalAmount = $t04253242687._2
1223+ let $t04277042925 = getOneTknV2Internal(outAssetId, minOutAmount, i.payments, i.caller, i.originCaller, i.transactionId)
1224+ let state = $t04277042925._1
1225+ let totalAmount = $t04277042925._2
12231226 $Tuple2(state, totalAmount)
12241227 }
12251228 else throw("Strict value is not equal to itself.")
12261229 }
12271230
12281231
12291232
12301233 @Callable(i)
12311234 func refreshDLp () = {
12321235 let lastRefreshedBlockHeight = valueOrElse(getInteger(keyDLpRefreshedHeight), 0)
12331236 let checkLastRefreshedBlockHeight = if (((height - lastRefreshedBlockHeight) >= dLpRefreshDelay))
12341237 then unit
12351238 else throwErr(makeString([toString(dLpRefreshDelay), " blocks have not passed since the previous call"], ""))
12361239 if ((checkLastRefreshedBlockHeight == checkLastRefreshedBlockHeight))
12371240 then {
12381241 let dLp = valueOrErrorMessage(parseBigInt(valueOrElse(getString(this, keyDLp), "0")), fmtErr("invalid dLp"))
1239- let $t04321143275 = refreshDLpInternal(0, 0, 0)
1240- let dLpUpdateActions = $t04321143275._1
1241- let updatedDLp = $t04321143275._2
1242+ let $t04344943513 = refreshDLpInternal(0, 0, 0)
1243+ let dLpUpdateActions = $t04344943513._1
1244+ let updatedDLp = $t04344943513._2
12421245 let actions = if ((dLp != updatedDLp))
12431246 then dLpUpdateActions
12441247 else throwErr("nothing to refresh")
12451248 $Tuple2(actions, toString(updatedDLp))
12461249 }
12471250 else throw("Strict value is not equal to itself.")
12481251 }
12491252
12501253
12511254
12521255 @Callable(i)
12531256 func getOneTknV2READONLY (outAssetId,lpAssetAmount) = {
12541257 let amId = toBase58String(value(cfgAmountAssetId))
12551258 let prId = toBase58String(value(cfgPriceAssetId))
12561259 let lpId = toBase58String(value(cfgLpAssetId))
12571260 let xp = [toBigInt(getAccBalance(amId)), toBigInt(getAccBalance(prId))]
12581261 let lpEmission = toBigInt(valueOrErrorMessage(assetInfo(fromBase58String(lpId)), "invalid lp asset").quantity)
12591262 let D0 = getD(xp)
12601263 let D1 = (D0 - fraction(toBigInt(lpAssetAmount), D0, lpEmission))
12611264 let index = if ((outAssetId == amId))
12621265 then 0
12631266 else if ((outAssetId == prId))
12641267 then 1
12651268 else throw("invalid out asset id")
12661269 let newY = getYD(xp, index, D1)
12671270 let dy = (xp[index] - newY)
12681271 let totalGetRaw = max([0, toInt((dy - big1))])
1269- let $t04420544254 = takeFee(totalGetRaw)
1270- let totalGet = $t04420544254._1
1271- let feeAmount = $t04420544254._2
1272+ let $t04444344492 = takeFee(totalGetRaw)
1273+ let totalGet = $t04444344492._1
1274+ let feeAmount = $t04444344492._2
12721275 $Tuple2(nil, $Tuple2(totalGet, feeAmount))
12731276 }
12741277
12751278
12761279
12771280 @Callable(i)
12781281 func getOneTknV2WithBonusREADONLY (outAssetId,lpAssetAmount) = {
12791282 let amId = toBase58String(value(cfgAmountAssetId))
12801283 let prId = toBase58String(value(cfgPriceAssetId))
12811284 let lpId = toBase58String(value(cfgLpAssetId))
12821285 let amBalance = getAccBalance(amId)
12831286 let prBalance = getAccBalance(prId)
1284- let $t04462944744 = {
1287+ let $t04486744982 = {
12851288 let @ = invoke(this, "getOneTknV2READONLY", [outAssetId, lpAssetAmount], nil)
12861289 if ($isInstanceOf(@, "(Int, Int)"))
12871290 then @
12881291 else throw(($getType(@) + " couldn't be cast to (Int, Int)"))
12891292 }
1290- let totalGet = $t04462944744._1
1291- let feeAmount = $t04462944744._2
1293+ let totalGet = $t04486744982._1
1294+ let feeAmount = $t04486744982._2
12921295 let r = ego("", lpId, lpAssetAmount, this)
12931296 let outAmAmt = r._1
12941297 let outPrAmt = r._2
12951298 let sumOfGetAssets = (outAmAmt + outPrAmt)
12961299 let bonus = if ((sumOfGetAssets == 0))
12971300 then if ((totalGet == 0))
12981301 then 0
12991302 else throw("bonus calculation error")
13001303 else fraction((totalGet - sumOfGetAssets), scale8, sumOfGetAssets)
13011304 $Tuple2(nil, $Tuple3(totalGet, feeAmount, bonus))
13021305 }
13031306
13041307
13051308
13061309 @Callable(i)
13071310 func getNoLess (noLessThenAmtAsset,noLessThenPriceAsset) = {
13081311 let aab = toBigInt(getAccBalance(assetIdToString(cfgAmountAssetId)))
13091312 if ((aab == aab))
13101313 then {
13111314 let pab = toBigInt(getAccBalance(assetIdToString(cfgPriceAssetId)))
13121315 if ((pab == pab))
13131316 then {
13141317 let lae = toBigInt(value(assetInfo(cfgLpAssetId)).quantity)
13151318 if ((lae == lae))
13161319 then {
13171320 let laea = (lae - toBigInt(value(i.payments[0]).amount))
13181321 if ((laea == laea))
13191322 then {
13201323 let r = cg(i)
13211324 let outAmAmt = r._1
13221325 let outPrAmt = r._2
13231326 let pmtAmt = r._3
13241327 let pmtAssetId = r._4
13251328 let state = r._5
13261329 if ((noLessThenAmtAsset > outAmAmt))
13271330 then throw(((("Failed: " + toString(outAmAmt)) + " < ") + toString(noLessThenAmtAsset)))
13281331 else if ((noLessThenPriceAsset > outPrAmt))
13291332 then throw(((("Failed: " + toString(outPrAmt)) + " < ") + toString(noLessThenPriceAsset)))
13301333 else {
13311334 let currentDLp = calcCurrentDLp(toBigInt(0), toBigInt(0), toBigInt(0))
13321335 if ((currentDLp == currentDLp))
13331336 then {
13341337 let burnLPAssetOnFactory = invoke(fca, "burn", [pmtAmt], [AttachedPayment(pmtAssetId, pmtAmt)])
13351338 if ((burnLPAssetOnFactory == burnLPAssetOnFactory))
13361339 then {
1337- let $t04628346364 = refreshDLpInternal(-(outAmAmt), -(outPrAmt), 0)
1338- let refreshDLpActions = $t04628346364._1
1339- let updatedDLp = $t04628346364._2
1340+ let $t04652146602 = refreshDLpInternal(-(outAmAmt), -(outPrAmt), 0)
1341+ let refreshDLpActions = $t04652146602._1
1342+ let updatedDLp = $t04652146602._2
13401343 let isUpdatedDLpValid = validateUpdatedDLp(currentDLp, updatedDLp)
13411344 if ((isUpdatedDLpValid == isUpdatedDLpValid))
13421345 then (state ++ refreshDLpActions)
13431346 else throw("Strict value is not equal to itself.")
13441347 }
13451348 else throw("Strict value is not equal to itself.")
13461349 }
13471350 else throw("Strict value is not equal to itself.")
13481351 }
13491352 }
13501353 else throw("Strict value is not equal to itself.")
13511354 }
13521355 else throw("Strict value is not equal to itself.")
13531356 }
13541357 else throw("Strict value is not equal to itself.")
13551358 }
13561359 else throw("Strict value is not equal to itself.")
13571360 }
13581361
13591362
13601363
13611364 @Callable(i)
13621365 func unstakeAndGet (amount) = {
13631366 let checkPayments = if ((size(i.payments) != 0))
13641367 then throw("No pmnts expd")
13651368 else true
13661369 if ((checkPayments == checkPayments))
13671370 then {
13681371 let factoryCfg = gfc()
13691372 let lpAssetId = cfgLpAssetId
13701373 let staking = valueOrErrorMessage(addressFromString(factoryCfg[idxFactStakCntr]), "Wr st addr")
13711374 let currentDLp = calcCurrentDLp(toBigInt(0), toBigInt(0), toBigInt(0))
13721375 let unstakeInv = invoke(staking, "unstake", [toBase58String(lpAssetId), amount], nil)
13731376 if ((unstakeInv == unstakeInv))
13741377 then {
13751378 let r = ego(toBase58String(i.transactionId), toBase58String(lpAssetId), amount, i.caller)
13761379 let outAmAmt = r._1
13771380 let outPrAmt = r._2
13781381 let sts = parseIntValue(r._9)
13791382 let state = r._10
13801383 let v = if (if (igs())
13811384 then true
13821385 else (sts == PoolShutdown))
13831386 then throw(("Blocked: " + toString(sts)))
13841387 else true
13851388 if ((v == v))
13861389 then {
13871390 let burnA = invoke(fca, "burn", [amount], [AttachedPayment(lpAssetId, amount)])
13881391 if ((burnA == burnA))
13891392 then {
1390- let $t04738847469 = refreshDLpInternal(-(outAmAmt), -(outPrAmt), 0)
1391- let refreshDLpActions = $t04738847469._1
1392- let updatedDLp = $t04738847469._2
1393+ let $t04762647707 = refreshDLpInternal(-(outAmAmt), -(outPrAmt), 0)
1394+ let refreshDLpActions = $t04762647707._1
1395+ let updatedDLp = $t04762647707._2
13931396 let isUpdatedDLpValid = validateUpdatedDLp(currentDLp, updatedDLp)
13941397 if ((isUpdatedDLpValid == isUpdatedDLpValid))
13951398 then (state ++ refreshDLpActions)
13961399 else throw("Strict value is not equal to itself.")
13971400 }
13981401 else throw("Strict value is not equal to itself.")
13991402 }
14001403 else throw("Strict value is not equal to itself.")
14011404 }
14021405 else throw("Strict value is not equal to itself.")
14031406 }
14041407 else throw("Strict value is not equal to itself.")
14051408 }
14061409
14071410
14081411
14091412 @Callable(i)
14101413 func unstakeAndGetNoLess (unstakeAmount,noLessThenAmountAsset,noLessThenPriceAsset) = {
14111414 let isGetDisabled = if (igs())
14121415 then true
14131416 else (cfgPoolStatus == PoolShutdown)
14141417 let checks = [if (!(isGetDisabled))
14151418 then true
14161419 else throw("get operation is blocked by admin"), if ((size(i.payments) == 0))
14171420 then true
14181421 else throw("no payments are expected")]
14191422 if ((checks == checks))
14201423 then {
14211424 let currentDLp = calcCurrentDLp(toBigInt(0), toBigInt(0), toBigInt(0))
14221425 let unstakeInv = invoke(stakingContract, "unstake", [toBase58String(cfgLpAssetId), unstakeAmount], nil)
14231426 if ((unstakeInv == unstakeInv))
14241427 then {
14251428 let res = ego(toBase58String(i.transactionId), toBase58String(cfgLpAssetId), unstakeAmount, i.caller)
14261429 let outAmAmt = res._1
14271430 let outPrAmt = res._2
14281431 let state = res._10
14291432 let checkAmounts = [if ((outAmAmt >= noLessThenAmountAsset))
14301433 then true
14311434 else throw(makeString(["amount asset amount to receive is less than ", toString(noLessThenAmountAsset)], "")), if ((outPrAmt >= noLessThenPriceAsset))
14321435 then true
14331436 else throw(makeString(["price asset amount to receive is less than ", toString(noLessThenPriceAsset)], ""))]
14341437 if ((checkAmounts == checkAmounts))
14351438 then {
14361439 let burnLPAssetOnFactory = invoke(fca, "burn", [unstakeAmount], [AttachedPayment(cfgLpAssetId, unstakeAmount)])
14371440 if ((burnLPAssetOnFactory == burnLPAssetOnFactory))
14381441 then {
1439- let $t04871748798 = refreshDLpInternal(-(outAmAmt), -(outPrAmt), 0)
1440- let refreshDLpActions = $t04871748798._1
1441- let updatedDLp = $t04871748798._2
1442+ let $t04895549036 = refreshDLpInternal(-(outAmAmt), -(outPrAmt), 0)
1443+ let refreshDLpActions = $t04895549036._1
1444+ let updatedDLp = $t04895549036._2
14421445 let isUpdatedDLpValid = validateUpdatedDLp(currentDLp, updatedDLp)
14431446 if ((isUpdatedDLpValid == isUpdatedDLpValid))
14441447 then (state ++ refreshDLpActions)
14451448 else throw("Strict value is not equal to itself.")
14461449 }
14471450 else throw("Strict value is not equal to itself.")
14481451 }
14491452 else throw("Strict value is not equal to itself.")
14501453 }
14511454 else throw("Strict value is not equal to itself.")
14521455 }
14531456 else throw("Strict value is not equal to itself.")
14541457 }
14551458
14561459
14571460
14581461 @Callable(i)
14591462 func unstakeAndGetOneTknV2 (unstakeAmount,outAssetId,minOutAmount) = {
14601463 let isPoolOneTokenOperationsDisabled = {
14611464 let @ = invoke(fca, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
14621465 if ($isInstanceOf(@, "Boolean"))
14631466 then @
14641467 else throw(($getType(@) + " couldn't be cast to Boolean"))
14651468 }
14661469 let isGetDisabled = if (if (igs())
14671470 then true
14681471 else (cfgPoolStatus == PoolShutdown))
14691472 then true
14701473 else isPoolOneTokenOperationsDisabled
14711474 let checks = [if (if (!(isGetDisabled))
14721475 then true
14731476 else isManager(i))
14741477 then true
14751478 else throwErr("get operation is blocked by admin"), if ((size(i.payments) == 0))
14761479 then true
14771480 else throwErr("no payments are expected")]
14781481 if ((checks == checks))
14791482 then {
14801483 let factoryCfg = gfc()
14811484 let lpAssetId = cfgLpAssetId
14821485 let staking = valueOrErrorMessage(addressFromString(factoryCfg[idxFactStakCntr]), "Wr st addr")
14831486 let unstakeInv = invoke(staking, "unstake", [toBase58String(lpAssetId), unstakeAmount], nil)
14841487 if ((unstakeInv == unstakeInv))
14851488 then {
1486- let $t04969349881 = getOneTknV2Internal(outAssetId, minOutAmount, [AttachedPayment(lpAssetId, unstakeAmount)], i.caller, i.originCaller, i.transactionId)
1487- let state = $t04969349881._1
1488- let totalAmount = $t04969349881._2
1489+ let $t04993150119 = getOneTknV2Internal(outAssetId, minOutAmount, [AttachedPayment(lpAssetId, unstakeAmount)], i.caller, i.originCaller, i.transactionId)
1490+ let state = $t04993150119._1
1491+ let totalAmount = $t04993150119._2
14891492 $Tuple2(state, totalAmount)
14901493 }
14911494 else throw("Strict value is not equal to itself.")
14921495 }
14931496 else throw("Strict value is not equal to itself.")
14941497 }
14951498
14961499
14971500
14981501 @Callable(i)
14991502 func putOneTknV2WithBonusREADONLY (paymentAmountRaw,paymentAssetId) = {
1500- let $t05000950112 = calcPutOneTkn(paymentAmountRaw, paymentAssetId, "", "", true)
1501- let lpAmount = $t05000950112._1
1502- let state = $t05000950112._2
1503- let feeAmount = $t05000950112._3
1504- let bonus = $t05000950112._4
1503+ let $t05024750350 = calcPutOneTkn(paymentAmountRaw, paymentAssetId, "", "", true)
1504+ let lpAmount = $t05024750350._1
1505+ let state = $t05024750350._2
1506+ let feeAmount = $t05024750350._3
1507+ let bonus = $t05024750350._4
15051508 $Tuple2(nil, $Tuple3(lpAmount, feeAmount, bonus))
15061509 }
15071510
15081511
15091512
15101513 @Callable(i)
15111514 func putOneTknV2WithoutTakeFeeREADONLY (paymentAmountRaw,paymentAssetId) = {
1512- let $t05026050364 = calcPutOneTkn(paymentAmountRaw, paymentAssetId, "", "", false)
1513- let lpAmount = $t05026050364._1
1514- let state = $t05026050364._2
1515- let feeAmount = $t05026050364._3
1516- let bonus = $t05026050364._4
1515+ let $t05049850602 = calcPutOneTkn(paymentAmountRaw, paymentAssetId, "", "", false)
1516+ let lpAmount = $t05049850602._1
1517+ let state = $t05049850602._2
1518+ let feeAmount = $t05049850602._3
1519+ let bonus = $t05049850602._4
15171520 $Tuple2(nil, $Tuple3(lpAmount, feeAmount, bonus))
15181521 }
15191522
15201523
15211524
15221525 @Callable(i)
15231526 func activate (amtAsStr,prAsStr) = if ((toString(i.caller) != toString(fca)))
15241527 then throw("denied")
15251528 else $Tuple2([StringEntry(aa(), amtAsStr), StringEntry(pa(), prAsStr)], "success")
15261529
15271530
15281531
15291532 @Callable(i)
15301533 func setS (k,v) = if ((toString(i.caller) != strf(this, ada())))
15311534 then pd
15321535 else [StringEntry(k, v)]
15331536
15341537
15351538
15361539 @Callable(i)
15371540 func setI (k,v) = if ((toString(i.caller) != strf(this, ada())))
15381541 then pd
15391542 else [IntegerEntry(k, v)]
15401543
15411544
15421545
15431546 @Callable(i)
15441547 func getPoolConfigWrapperREADONLY () = $Tuple2(nil, gpc())
15451548
15461549
15471550
15481551 @Callable(i)
15491552 func getAccBalanceWrapperREADONLY (assetId) = $Tuple2(nil, getAccBalance(assetId))
15501553
15511554
15521555
15531556 @Callable(i)
15541557 func calcPricesWrapperREADONLY (amAmt,prAmt,lpAmt) = {
15551558 let pr = calcPrices(amAmt, prAmt, lpAmt)
15561559 $Tuple2(nil, [toString(pr[0]), toString(pr[1]), toString(pr[2])])
15571560 }
15581561
15591562
15601563
15611564 @Callable(i)
15621565 func fromX18WrapperREADONLY (val,resScaleMult) = $Tuple2(nil, f1(parseBigIntValue(val), resScaleMult))
15631566
15641567
15651568
15661569 @Callable(i)
15671570 func toX18WrapperREADONLY (origVal,origScaleMult) = $Tuple2(nil, toString(t1(origVal, origScaleMult)))
15681571
15691572
15701573
15711574 @Callable(i)
15721575 func calcPriceBigIntWrapperREADONLY (prAmtX18,amAmtX18) = $Tuple2(nil, toString(cpbi(parseBigIntValue(prAmtX18), parseBigIntValue(amAmtX18))))
15731576
15741577
15751578
15761579 @Callable(i)
15771580 func estimatePutOperationWrapperREADONLY (txId58,slippage,inAmAmt,inAmId,inPrAmt,inPrId,usrAddr,isEval,emitLp) = $Tuple2(nil, epo(txId58, slippage, inAmAmt, inAmId, inPrAmt, inPrId, usrAddr, isEval, emitLp, true, false, 0, ""))
15781581
15791582
15801583
15811584 @Callable(i)
15821585 func estimateGetOperationWrapperREADONLY (txId58,pmtAsId,pmtLpAmt,usrAddr) = {
15831586 let r = ego(txId58, pmtAsId, pmtLpAmt, addressFromStringValue(usrAddr))
15841587 $Tuple2(nil, $Tuple10(r._1, r._2, r._3, r._4, r._5, r._6, r._7, toString(r._8), r._9, r._10))
15851588 }
15861589
15871590
15881591
15891592 @Callable(i)
15901593 func getFeeREADONLY () = $Tuple2(nil, fee)
15911594
15921595
15931596 @Verifier(tx)
15941597 func verify () = {
15951598 let targetPublicKey = match m() {
15961599 case pk: ByteVector =>
15971600 pk
15981601 case _: Unit =>
15991602 tx.senderPublicKey
16001603 case _ =>
16011604 throw("Match error")
16021605 }
16031606 match tx {
16041607 case order: Order =>
16051608 let matcherPub = mp()
16061609 let orderValid = validateMatcherOrderAllowed(order)
16071610 let senderValid = sigVerify(order.bodyBytes, order.proofs[0], order.senderPublicKey)
16081611 let matcherValid = sigVerify(order.bodyBytes, order.proofs[1], matcherPub)
16091612 if (if (if (orderValid)
16101613 then senderValid
16111614 else false)
16121615 then matcherValid
16131616 else false)
16141617 then true
16151618 else toe(orderValid, senderValid, matcherValid)
16161619 case s: SetScriptTransaction =>
16171620 let newHash = blake2b256(value(s.script))
16181621 let allowedHash = fromBase64String(value(getString(fca, keyAllowedLpStableScriptHash())))
16191622 let currentHash = scriptHash(this)
16201623 if (if ((allowedHash == newHash))
16211624 then (currentHash != newHash)
16221625 else false)
16231626 then true
16241627 else sigVerify(tx.bodyBytes, tx.proofs[0], targetPublicKey)
16251628 case _ =>
16261629 sigVerify(tx.bodyBytes, tx.proofs[0], targetPublicKey)
16271630 }
16281631 }
16291632

github/deemru/w8io/169f3d6 
276.52 ms