tx · FdcXQtzzNoBqmxPg8mBtXCZHkY9d8w75behsiHRWhWwn

3N4ig26JgHMJuLfZ1cdm2Rvy7oWg7pMnxjy:  -0.02800000 Waves

2022.10.14 09:11 [2271649] smart account 3N4ig26JgHMJuLfZ1cdm2Rvy7oWg7pMnxjy > SELF 0.00000000 Waves

{ "type": 13, "id": "FdcXQtzzNoBqmxPg8mBtXCZHkY9d8w75behsiHRWhWwn", "fee": 2800000, "feeAssetId": null, "timestamp": 1665727861460, "version": 1, "sender": "3N4ig26JgHMJuLfZ1cdm2Rvy7oWg7pMnxjy", "senderPublicKey": "1Q1fBqTqxTRfxwxvQhDYXVLbyoJeM9hnAHUUhKLbQ3K", "proofs": [ "4Cm9CRPgXCabJRz8BjLmoz9vnxBkQjkeAaRJhpehDC7NW9pvm5Yj1f5F1am81munmQ5cgriGdRtpAsDeDMsh7Dxw" ], "script": "base64:BgKOJwgCEgMKAQgSABIECgIBBBIDCgEBEgQKAgEEEgQKAgEIEgUKAwgBARIECgIIARIAEgQKAgEBEgMKAQESBAoCCAgSABIDCgEIEgUKAwEBARIECgIBARIECgIIARIECgIICBILCgkIAQECAQIIBAQSBgoECAgBCBIAEgMKAQESAwoBARIECgIIASIKbFBkZWNpbWFscyIGc2NhbGU4IgxzY2FsZThCaWdJbnQiB3NjYWxlMTgiCnplcm9CaWdJbnQiBGJpZzAiBGJpZzEiBGJpZzIiC3dhdmVzU3RyaW5nIgNTRVAiClBvb2xBY3RpdmUiD1Bvb2xQdXREaXNhYmxlZCITUG9vbE1hdGNoZXJEaXNhYmxlZCIMUG9vbFNodXRkb3duIg5pZHhQb29sQWRkcmVzcyINaWR4UG9vbFN0YXR1cyIQaWR4UG9vbExQQXNzZXRJZCINaWR4QW10QXNzZXRJZCIPaWR4UHJpY2VBc3NldElkIg5pZHhBbXRBc3NldERjbSIQaWR4UHJpY2VBc3NldERjbSIOaWR4SUFtdEFzc2V0SWQiEGlkeElQcmljZUFzc2V0SWQiDWlkeExQQXNzZXREY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ddLm7Kh2bUw1pxviok8pCB56JFBxBQr8rzS7kCMLb Diff:
OldNewDifferences
175175
176176 func parsePoolConfig (poolConfig) = $Tuple7(addressFromStringValue(poolConfig[idxPoolAddress]), parseIntValue(poolConfig[idxPoolStatus]), fromBase58String(poolConfig[idxPoolLPAssetId]), parseAssetId(poolConfig[idxAmtAssetId]), parseAssetId(poolConfig[idxPriceAssetId]), parseIntValue(poolConfig[idxAmtAssetDcm]), parseIntValue(poolConfig[idxPriceAssetDcm]))
177177
178+
179+let poolConfigParsed = parsePoolConfig(getPoolConfig())
180+
181+let $t074847650 = poolConfigParsed
182+
183+let cfgPoolAddress = $t074847650._1
184+
185+let cfgPoolStatus = $t074847650._2
186+
187+let cfgLpAssetId = $t074847650._3
188+
189+let cfgAmountAssetId = $t074847650._4
190+
191+let cfgPriceAssetId = $t074847650._5
192+
193+let cfgAmountAssetDecimals = $t074847650._6
194+
195+let cfgPriceAssetDecimals = $t074847650._7
178196
179197 func getFactoryConfig () = split(getStringOrFail(factoryContract, keyFactoryConfig()), SEP)
180198
444462
445463 func calcPutOneToken (paymentAmountRaw,paymentAssetId,userAddress,txId) = {
446464 let isEval = (txId == unit)
447- let $t02194222120 = parsePoolConfig(getPoolConfig())
448- let poolAddress = $t02194222120._1
449- let poolStatus = $t02194222120._2
450- let lpAssetId = $t02194222120._3
451- let amountAssetId = $t02194222120._4
452- let priceAssetId = $t02194222120._5
453- let amountAssetDecimals = $t02194222120._6
454- let priceAssetDecimals = $t02194222120._7
465+ let $t02216722345 = parsePoolConfig(getPoolConfig())
466+ let poolAddress = $t02216722345._1
467+ let poolStatus = $t02216722345._2
468+ let lpAssetId = $t02216722345._3
469+ let amountAssetId = $t02216722345._4
470+ let priceAssetId = $t02216722345._5
471+ let amountAssetDecimals = $t02216722345._6
472+ let priceAssetDecimals = $t02216722345._7
455473 let amountBalanceRaw = getAccBalance(assetIdToString(amountAssetId))
456474 let priceBalanceRaw = getAccBalance(assetIdToString(priceAssetId))
457475 let paymentInAmountAsset = if ((paymentAssetId == amountAssetId))
459477 else if ((paymentAssetId == priceAssetId))
460478 then false
461479 else throwErr("invalid asset")
462- let $t02245022743 = if (isEval)
480+ let $t02267522968 = if (isEval)
463481 then $Tuple2(amountBalanceRaw, priceBalanceRaw)
464482 else if (paymentInAmountAsset)
465483 then $Tuple2((amountBalanceRaw - paymentAmountRaw), priceBalanceRaw)
466484 else $Tuple2(amountBalanceRaw, (priceBalanceRaw - paymentAmountRaw))
467- let amountBalanceOld = $t02245022743._1
468- let priceBalanceOld = $t02245022743._2
469- let $t02274722896 = if (paymentInAmountAsset)
485+ let amountBalanceOld = $t02267522968._1
486+ let priceBalanceOld = $t02267522968._2
487+ let $t02297223121 = if (paymentInAmountAsset)
470488 then $Tuple2(paymentAmountRaw, 0)
471489 else $Tuple2(0, paymentAmountRaw)
472- let amountAssetAmountRaw = $t02274722896._1
473- let priceAssetAmountRaw = $t02274722896._2
490+ let amountAssetAmountRaw = $t02297223121._1
491+ let priceAssetAmountRaw = $t02297223121._2
474492 let amountAssetAmount = takeFee(amountAssetAmountRaw)._1
475493 let priceAssetAmount = takeFee(priceAssetAmountRaw)._1
476- let $t02301823077 = takeFee(paymentAmountRaw)
477- let paymentAmount = $t02301823077._1
478- let feeAmount = $t02301823077._2
494+ let $t02324323302 = takeFee(paymentAmountRaw)
495+ let paymentAmount = $t02324323302._1
496+ let feeAmount = $t02324323302._2
479497 let amountBalanceNew = (amountBalanceOld + amountAssetAmount)
480498 let priceBalanceNew = (priceBalanceOld + priceAssetAmount)
481499 let curPrice = fromX18(calcPriceBigInt(toX18(priceBalanceNew, priceAssetDecimals), toX18(amountBalanceNew, amountAssetDecimals)), scale8)
507525
508526 func calcGetOneToken (outAssetId,paymentAmount,paymentAssetId,userAddress,txId) = {
509527 let isEval = (txId == unit)
510- let $t02502725188 = parsePoolConfig(getPoolConfig())
511- let poolAddress = $t02502725188._1
512- let poolStatus = $t02502725188._2
513- let lpAssetId = $t02502725188._3
514- let amountAssetId = $t02502725188._4
515- let priceAssetId = $t02502725188._5
516- let amDecimals = $t02502725188._6
517- let prDecimals = $t02502725188._7
528+ let $t02525225413 = parsePoolConfig(getPoolConfig())
529+ let poolAddress = $t02525225413._1
530+ let poolStatus = $t02525225413._2
531+ let lpAssetId = $t02525225413._3
532+ let amountAssetId = $t02525225413._4
533+ let priceAssetId = $t02525225413._5
534+ let amDecimals = $t02525225413._6
535+ let prDecimals = $t02525225413._7
518536 let checks = [if ((paymentAssetId == lpAssetId))
519537 then true
520538 else throw("invalid lp asset")]
537555 let supplyBigInt = toBigInt(valueOrErrorMessage(assetInfo(lpAssetId), (("asset " + toBase58String(lpAssetId)) + " doesn't exist")).quantity)
538556 let redeemedBigInt = toBigInt(paymentAmount)
539557 let amountRaw = toInt(((balanceBigInt * (scale8BigInt - pow((scale8BigInt - ((redeemedBigInt * scale8BigInt) / supplyBigInt)), 8, big2, 0, 8, DOWN))) / scale8BigInt))
540- let $t02625526305 = takeFee(amountRaw)
541- let totalAmount = $t02625526305._1
542- let feeAmount = $t02625526305._2
543- let $t02630926535 = if (outInAmountAsset)
558+ let $t02648026530 = takeFee(amountRaw)
559+ let totalAmount = $t02648026530._1
560+ let feeAmount = $t02648026530._2
561+ let $t02653426760 = if (outInAmountAsset)
544562 then $Tuple4(totalAmount, 0, (amBalanceOld - amountRaw), prBalanceOld)
545563 else $Tuple4(0, totalAmount, amBalanceOld, (prBalanceOld - amountRaw))
546- let outAmAmount = $t02630926535._1
547- let outPrAmount = $t02630926535._2
548- let amBalanceNew = $t02630926535._3
549- let prBalanceNew = $t02630926535._4
564+ let outAmAmount = $t02653426760._1
565+ let outPrAmount = $t02653426760._2
566+ let amBalanceNew = $t02653426760._3
567+ let prBalanceNew = $t02653426760._4
550568 let curPrX18 = calcPriceBigInt(toX18(prBalanceNew, prDecimals), toX18(amBalanceNew, amDecimals))
551569 let curPrice = fromX18(curPrX18, scale8)
552570 let commonState = if (isEval)
699717
700718 @Callable(i)
701719 func putOneTkn (minOutAmount,autoStake) = {
702- let $t03042630604 = parsePoolConfig(getPoolConfig())
703- let poolAddress = $t03042630604._1
704- let poolStatus = $t03042630604._2
705- let lpAssetId = $t03042630604._3
706- let amountAssetId = $t03042630604._4
707- let priceAssetId = $t03042630604._5
708- let amountAssetDecimals = $t03042630604._6
709- let priceAssetDecimals = $t03042630604._7
710720 let isPutDisabled = if (if (isGlobalShutdown())
711721 then true
712- else (poolStatus == PoolPutDisabled))
722+ else (cfgPoolStatus == PoolPutDisabled))
713723 then true
714- else (poolStatus == PoolShutdown)
724+ else (cfgPoolStatus == PoolShutdown)
715725 let checks = [if (!(isPutDisabled))
716726 then true
717727 else throwErr("put operation is blocked by admin"), if ((size(i.payments) == 1))
722732 let payment = i.payments[0]
723733 let paymentAssetId = payment.assetId
724734 let paymentAmountRaw = payment.amount
725- let paymentAmount = paymentAmountRaw
726735 let userAddress = i.caller
727736 let txId = i.transactionId
728- let $t03109131218 = calcPutOneToken(paymentAmountRaw, paymentAssetId, userAddress, txId)
729- let emitAmountEstimated = $t03109131218._1
730- let commonState = $t03109131218._2
731- let feeAmount = $t03109131218._3
732- let bonus = $t03109131218._4
737+ let $t03110131228 = calcPutOneToken(paymentAmountRaw, paymentAssetId, userAddress, txId)
738+ let emitAmountEstimated = $t03110131228._1
739+ let commonState = $t03110131228._2
740+ let feeAmount = $t03110131228._3
741+ let bonus = $t03110131228._4
733742 let emitAmount = if (if ((minOutAmount > 0))
734743 then (minOutAmount > emitAmountEstimated)
735744 else false)
740749 then {
741750 let lpTransfer = if (autoStake)
742751 then {
743- let stakeInv = invoke(stakingContract, "stake", nil, [AttachedPayment(lpAssetId, emitAmount)])
752+ let stakeInv = invoke(stakingContract, "stake", nil, [AttachedPayment(cfgLpAssetId, emitAmount)])
744753 if ((stakeInv == stakeInv))
745754 then nil
746755 else throw("Strict value is not equal to itself.")
747756 }
748- else [ScriptTransfer(i.caller, emitAmount, lpAssetId)]
757+ else [ScriptTransfer(i.caller, emitAmount, cfgLpAssetId)]
749758 let sendFee = if ((feeAmount > 0))
750759 then [ScriptTransfer(feeCollectorAddress, feeAmount, paymentAssetId)]
751760 else nil
759768
760769
761770 @Callable(i)
771+func putOneTknREADONLY (paymentAmountRaw,paymentAssetId) = {
772+ let $t03195432089 = calcPutOneToken(paymentAmountRaw, parseAssetId(paymentAssetId), unit, unit)
773+ let emitAmountEstimated = $t03195432089._1
774+ let commonState = $t03195432089._2
775+ let feeAmount = $t03195432089._3
776+ let bonus = $t03195432089._4
777+ $Tuple2(nil, $Tuple3(emitAmountEstimated, feeAmount, bonus))
778+ }
779+
780+
781+
782+@Callable(i)
762783 func getOneTkn (outAssetId,minOutAmount,unstakeAmount) = {
763- let $t03194232120 = parsePoolConfig(getPoolConfig())
764- let poolAddress = $t03194232120._1
765- let poolStatus = $t03194232120._2
766- let lpAssetId = $t03194232120._3
767- let amountAssetId = $t03194232120._4
768- let priceAssetId = $t03194232120._5
769- let amountAssetDecimals = $t03194232120._6
770- let priceAssetDecimals = $t03194232120._7
771784 let isGetDisabled = if (isGlobalShutdown())
772785 then true
773- else (poolStatus == PoolShutdown)
786+ else (cfgPoolStatus == PoolShutdown)
774787 let checks = [if (!(isGetDisabled))
775788 then true
776789 else throwErr("get operation is blocked by admin"), if ((size(i.payments) == 1))
783796 let paymentAmount = payment.amount
784797 let userAddress = i.caller
785798 let txId = i.transactionId
786- let $t03253132678 = calcGetOneToken(parseAssetId(outAssetId), paymentAmount, paymentAssetId, userAddress, txId)
787- let amountEstimated = $t03253132678._1
788- let commonState = $t03253132678._2
789- let feeAmount = $t03253132678._3
790- let bonus = $t03253132678._4
799+ let $t03264532792 = calcGetOneToken(parseAssetId(outAssetId), paymentAmount, paymentAssetId, userAddress, txId)
800+ let amountEstimated = $t03264532792._1
801+ let commonState = $t03264532792._2
802+ let feeAmount = $t03264532792._3
803+ let bonus = $t03264532792._4
791804 let amount = if (if ((minOutAmount > 0))
792805 then (minOutAmount > amountEstimated)
793806 else false)
802815 else throw("Strict value is not equal to itself.")
803816 }
804817 else throw("Strict value is not equal to itself.")
818+ }
819+
820+
821+
822+@Callable(i)
823+func getOneTknREADONLY (outAssetId,paymentAmount) = {
824+ let $t03330333441 = calcGetOneToken(parseAssetId(outAssetId), paymentAmount, cfgLpAssetId, unit, unit)
825+ let amountEstimated = $t03330333441._1
826+ let commonState = $t03330333441._2
827+ let feeAmount = $t03330333441._3
828+ let bonus = $t03330333441._4
829+ $Tuple2(nil, $Tuple3(amountEstimated, feeAmount, bonus))
805830 }
806831
807832
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 6 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let lPdecimals = 8
55
66 let scale8 = 100000000
77
88 let scale8BigInt = toBigInt(100000000)
99
1010 let scale18 = toBigInt(1000000000000000000)
1111
1212 let zeroBigInt = toBigInt(0)
1313
1414 let big0 = toBigInt(0)
1515
1616 let big1 = toBigInt(1)
1717
1818 let big2 = toBigInt(2)
1919
2020 let wavesString = "WAVES"
2121
2222 let SEP = "__"
2323
2424 let PoolActive = 1
2525
2626 let PoolPutDisabled = 2
2727
2828 let PoolMatcherDisabled = 3
2929
3030 let PoolShutdown = 4
3131
3232 let idxPoolAddress = 1
3333
3434 let idxPoolStatus = 2
3535
3636 let idxPoolLPAssetId = 3
3737
3838 let idxAmtAssetId = 4
3939
4040 let idxPriceAssetId = 5
4141
4242 let idxAmtAssetDcm = 6
4343
4444 let idxPriceAssetDcm = 7
4545
4646 let idxIAmtAssetId = 8
4747
4848 let idxIPriceAssetId = 9
4949
5050 let idxLPAssetDcm = 10
5151
5252 let idxPoolAmtAssetAmt = 1
5353
5454 let idxPoolPriceAssetAmt = 2
5555
5656 let idxPoolLPAssetAmt = 3
5757
5858 let idxFactoryStakingContract = 1
5959
6060 let idxFactorySlippageContract = 7
6161
6262 func toX18 (origVal,origScaleMult) = fraction(toBigInt(origVal), scale18, toBigInt(origScaleMult))
6363
6464
6565 func fromX18 (val,resultScaleMult) = toInt(fraction(val, toBigInt(resultScaleMult), scale18))
6666
6767
6868 func toScale (amt,resScale,curScale) = fraction(amt, resScale, curScale)
6969
7070
7171 func abs (val) = if ((zeroBigInt > val))
7272 then -(val)
7373 else val
7474
7575
7676 func fc () = "%s__factoryContract"
7777
7878
7979 func mpk () = "%s__managerPublicKey"
8080
8181
8282 func pmpk () = "%s__pendingManagerPublicKey"
8383
8484
8585 func pl () = "%s%s__price__last"
8686
8787
8888 func ph (h,timestamp) = makeString(["%s%s%d%d__price__history", toString(h), toString(timestamp)], SEP)
8989
9090
9191 func pau (userAddress,txId) = ((("%s%s%s__P__" + userAddress) + "__") + txId)
9292
9393
9494 func gau (userAddress,txId) = ((("%s%s%s__G__" + userAddress) + "__") + txId)
9595
9696
9797 func aa () = "%s__amountAsset"
9898
9999
100100 func pa () = "%s__priceAsset"
101101
102102
103103 let keyFee = "%s__fee"
104104
105105 let feeDefault = fraction(5, scale8, 10000)
106106
107107 let fee = valueOrElse(getInteger(this, keyFee), feeDefault)
108108
109109 func keyFactoryConfig () = "%s__factoryConfig"
110110
111111
112112 func keyMatcherPub () = "%s%s__matcher__publicKey"
113113
114114
115115 func keyMappingPoolContractAddressToPoolAssets (poolContractAddress) = (("%s%s%s__" + poolContractAddress) + "__mappings__poolContract2LpAsset")
116116
117117
118118 func keyPoolConfig (iAmtAsset,iPriceAsset) = (((("%d%d%s__" + iAmtAsset) + "__") + iPriceAsset) + "__config")
119119
120120
121121 func keyMappingsBaseAsset2internalId (baseAssetStr) = ("%s%s%s__mappings__baseAsset2internalId__" + baseAssetStr)
122122
123123
124124 func keyAllPoolsShutdown () = "%s__shutdown"
125125
126126
127127 func keyPoolWeight (contractAddress) = ("%s%s__poolWeight__" + contractAddress)
128128
129129
130130 func keyAllowedLpScriptHash () = "%s__allowedLpScriptHash"
131131
132132
133133 let keyFeeCollectorAddress = "%s__feeCollectorAddress"
134134
135135 func throwOrderError (orderValid,senderValid,matcherValid) = throw(((((("order validation failed: orderValid=" + toString(orderValid)) + " senderValid=") + toString(senderValid)) + " matcherValid=") + toString(matcherValid)))
136136
137137
138138 func getStringOrFail (address,key) = valueOrErrorMessage(getString(address, key), makeString(["mandatory ", toString(address), ".", key, " is not defined"], ""))
139139
140140
141141 func getIntOrFail (address,key) = valueOrErrorMessage(getInteger(address, key), makeString(["mandatory ", toString(address), ".", key, " is not defined"], ""))
142142
143143
144144 func throwErr (msg) = throw(makeString(["lp.ride:", msg], " "))
145145
146146
147147 let factoryContract = addressFromStringValue(getStringOrFail(this, fc()))
148148
149149 let feeCollectorAddress = addressFromStringValue(getStringOrFail(factoryContract, keyFeeCollectorAddress))
150150
151151 func isGlobalShutdown () = valueOrElse(getBoolean(factoryContract, keyAllPoolsShutdown()), false)
152152
153153
154154 func getMatcherPubOrFail () = fromBase58String(getStringOrFail(factoryContract, keyMatcherPub()))
155155
156156
157157 func getPoolConfig () = {
158158 let amtAsset = getStringOrFail(this, aa())
159159 let priceAsset = getStringOrFail(this, pa())
160160 let iPriceAsset = getIntOrFail(factoryContract, keyMappingsBaseAsset2internalId(priceAsset))
161161 let iAmtAsset = getIntOrFail(factoryContract, keyMappingsBaseAsset2internalId(amtAsset))
162162 split(getStringOrFail(factoryContract, keyPoolConfig(toString(iAmtAsset), toString(iPriceAsset))), SEP)
163163 }
164164
165165
166166 func parseAssetId (input) = if ((input == wavesString))
167167 then unit
168168 else fromBase58String(input)
169169
170170
171171 func assetIdToString (input) = if ((input == unit))
172172 then wavesString
173173 else toBase58String(value(input))
174174
175175
176176 func parsePoolConfig (poolConfig) = $Tuple7(addressFromStringValue(poolConfig[idxPoolAddress]), parseIntValue(poolConfig[idxPoolStatus]), fromBase58String(poolConfig[idxPoolLPAssetId]), parseAssetId(poolConfig[idxAmtAssetId]), parseAssetId(poolConfig[idxPriceAssetId]), parseIntValue(poolConfig[idxAmtAssetDcm]), parseIntValue(poolConfig[idxPriceAssetDcm]))
177177
178+
179+let poolConfigParsed = parsePoolConfig(getPoolConfig())
180+
181+let $t074847650 = poolConfigParsed
182+
183+let cfgPoolAddress = $t074847650._1
184+
185+let cfgPoolStatus = $t074847650._2
186+
187+let cfgLpAssetId = $t074847650._3
188+
189+let cfgAmountAssetId = $t074847650._4
190+
191+let cfgPriceAssetId = $t074847650._5
192+
193+let cfgAmountAssetDecimals = $t074847650._6
194+
195+let cfgPriceAssetDecimals = $t074847650._7
178196
179197 func getFactoryConfig () = split(getStringOrFail(factoryContract, keyFactoryConfig()), SEP)
180198
181199
182200 let stakingContract = valueOrErrorMessage(addressFromString(getFactoryConfig()[idxFactoryStakingContract]), "incorrect staking address")
183201
184202 let slippageContract = valueOrErrorMessage(addressFromString(getFactoryConfig()[idxFactorySlippageContract]), "incorrect staking address")
185203
186204 func dataPutActionInfo (inAmtAssetAmt,inPriceAssetAmt,outLpAmt,price,slippageTolerancePassedByUser,slippageToleranceReal,txHeight,txTimestamp,slipageAmtAssetAmt,slipagePriceAssetAmt) = makeString(["%d%d%d%d%d%d%d%d%d%d", toString(inAmtAssetAmt), toString(inPriceAssetAmt), toString(outLpAmt), toString(price), toString(slippageTolerancePassedByUser), toString(slippageToleranceReal), toString(txHeight), toString(txTimestamp), toString(slipageAmtAssetAmt), toString(slipagePriceAssetAmt)], SEP)
187205
188206
189207 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)
190208
191209
192210 func getAccBalance (assetId) = if ((assetId == "WAVES"))
193211 then wavesBalance(this).available
194212 else assetBalance(this, fromBase58String(assetId))
195213
196214
197215 func calcPriceBigInt (prAmtX18,amAmtX18) = fraction(prAmtX18, scale18, amAmtX18)
198216
199217
200218 func privateCalcPrice (amAssetDcm,prAssetDcm,amAmt,prAmt) = {
201219 let amtAssetAmtX18 = toX18(amAmt, amAssetDcm)
202220 let priceAssetAmtX18 = toX18(prAmt, prAssetDcm)
203221 calcPriceBigInt(priceAssetAmtX18, amtAssetAmtX18)
204222 }
205223
206224
207225 func calcPrices (amAmt,prAmt,lpAmt) = {
208226 let cfg = getPoolConfig()
209227 let amtAssetDcm = parseIntValue(cfg[idxAmtAssetDcm])
210228 let priceAssetDcm = parseIntValue(cfg[idxPriceAssetDcm])
211229 let priceX18 = privateCalcPrice(amtAssetDcm, priceAssetDcm, amAmt, prAmt)
212230 let amAmtX18 = toX18(amAmt, amtAssetDcm)
213231 let prAmtX18 = toX18(prAmt, priceAssetDcm)
214232 let lpAmtX18 = toX18(lpAmt, scale8)
215233 let lpPriceInAmAssetX18 = calcPriceBigInt(amAmtX18, lpAmtX18)
216234 let lpPriceInPrAssetX18 = calcPriceBigInt(prAmtX18, lpAmtX18)
217235 [priceX18, lpPriceInAmAssetX18, lpPriceInPrAssetX18]
218236 }
219237
220238
221239 func calculatePrices (amAmt,prAmt,lpAmt) = {
222240 let prices = calcPrices(amAmt, prAmt, lpAmt)
223241 [fromX18(prices[0], scale8), fromX18(prices[1], scale8), fromX18(prices[2], scale8)]
224242 }
225243
226244
227245 func estimateGetOperation (txId58,pmtAssetId,pmtLpAmt,userAddress) = {
228246 let cfg = getPoolConfig()
229247 let lpAssetId = cfg[idxPoolLPAssetId]
230248 let amAssetId = cfg[idxAmtAssetId]
231249 let prAssetId = cfg[idxPriceAssetId]
232250 let amAssetDcm = parseIntValue(cfg[idxAmtAssetDcm])
233251 let prAssetDcm = parseIntValue(cfg[idxPriceAssetDcm])
234252 let poolStatus = cfg[idxPoolStatus]
235253 let lpEmission = valueOrErrorMessage(assetInfo(fromBase58String(lpAssetId)), (("Asset " + lpAssetId) + " doesn't exist")).quantity
236254 if ((lpAssetId != pmtAssetId))
237255 then throw("Invalid asset passed.")
238256 else {
239257 let amBalance = getAccBalance(amAssetId)
240258 let amBalanceX18 = toX18(amBalance, amAssetDcm)
241259 let prBalance = getAccBalance(prAssetId)
242260 let prBalanceX18 = toX18(prBalance, prAssetDcm)
243261 let curPriceX18 = calcPriceBigInt(prBalanceX18, amBalanceX18)
244262 let curPrice = fromX18(curPriceX18, scale8)
245263 let pmtLpAmtX18 = toX18(pmtLpAmt, scale8)
246264 let lpEmissionX18 = toX18(lpEmission, scale8)
247265 let outAmAmtX18 = fraction(amBalanceX18, pmtLpAmtX18, lpEmissionX18)
248266 let outPrAmtX18 = fraction(prBalanceX18, pmtLpAmtX18, lpEmissionX18)
249267 let outAmAmt = fromX18(outAmAmtX18, amAssetDcm)
250268 let outPrAmt = fromX18(outPrAmtX18, prAssetDcm)
251269 let state = if ((txId58 == ""))
252270 then nil
253271 else [ScriptTransfer(userAddress, outAmAmt, if ((amAssetId == "WAVES"))
254272 then unit
255273 else fromBase58String(amAssetId)), ScriptTransfer(userAddress, outPrAmt, if ((prAssetId == "WAVES"))
256274 then unit
257275 else fromBase58String(prAssetId)), StringEntry(gau(toString(userAddress), txId58), dataGetActionInfo(outAmAmt, outPrAmt, pmtLpAmt, curPrice, height, lastBlock.timestamp)), IntegerEntry(pl(), curPrice), IntegerEntry(ph(height, lastBlock.timestamp), curPrice)]
258276 $Tuple10(outAmAmt, outPrAmt, amAssetId, prAssetId, amBalance, prBalance, lpEmission, curPriceX18, poolStatus, state)
259277 }
260278 }
261279
262280
263281 func estimatePutOperation (txId58,slippageTolerance,inAmAssetAmt,inAmAssetId,inPrAssetAmt,inPrAssetId,userAddress,isEvaluate,emitLp) = {
264282 let cfg = getPoolConfig()
265283 let lpAssetId = fromBase58String(cfg[idxPoolLPAssetId])
266284 let amAssetIdStr = cfg[idxAmtAssetId]
267285 let prAssetIdStr = cfg[idxPriceAssetId]
268286 let iAmtAssetId = cfg[idxIAmtAssetId]
269287 let iPriceAssetId = cfg[idxIPriceAssetId]
270288 let amtAssetDcm = parseIntValue(cfg[idxAmtAssetDcm])
271289 let priceAssetDcm = parseIntValue(cfg[idxPriceAssetDcm])
272290 let poolStatus = cfg[idxPoolStatus]
273291 let lpEmission = valueOrErrorMessage(assetInfo(lpAssetId), (("Asset " + toBase58String(lpAssetId)) + " doesn't exist")).quantity
274292 let inAmAssetIdStr = toBase58String(valueOrElse(inAmAssetId, fromBase58String("WAVES")))
275293 let inPrAssetIdStr = toBase58String(valueOrElse(inPrAssetId, fromBase58String("WAVES")))
276294 if (if ((amAssetIdStr != inAmAssetIdStr))
277295 then true
278296 else (prAssetIdStr != inPrAssetIdStr))
279297 then throw("Invalid amt or price asset passed.")
280298 else {
281299 let amBalance = if (isEvaluate)
282300 then getAccBalance(amAssetIdStr)
283301 else (getAccBalance(amAssetIdStr) - inAmAssetAmt)
284302 let prBalance = if (isEvaluate)
285303 then getAccBalance(prAssetIdStr)
286304 else (getAccBalance(prAssetIdStr) - inPrAssetAmt)
287305 let inAmAssetAmtX18 = toX18(inAmAssetAmt, amtAssetDcm)
288306 let inPrAssetAmtX18 = toX18(inPrAssetAmt, priceAssetDcm)
289307 let userPriceX18 = calcPriceBigInt(inPrAssetAmtX18, inAmAssetAmtX18)
290308 let amBalanceX18 = toX18(amBalance, amtAssetDcm)
291309 let prBalanceX18 = toX18(prBalance, priceAssetDcm)
292310 let res = if ((lpEmission == 0))
293311 then {
294312 let curPriceX18 = zeroBigInt
295313 let slippageX18 = zeroBigInt
296314 let lpAmtX18 = pow((inAmAssetAmtX18 * inPrAssetAmtX18), 0, toBigInt(5), 1, 0, DOWN)
297315 $Tuple5(fromX18(lpAmtX18, scale8), fromX18(inAmAssetAmtX18, amtAssetDcm), fromX18(inPrAssetAmtX18, priceAssetDcm), calcPriceBigInt((prBalanceX18 + inPrAssetAmtX18), (amBalanceX18 + inAmAssetAmtX18)), slippageX18)
298316 }
299317 else {
300318 let curPriceX18 = calcPriceBigInt(prBalanceX18, amBalanceX18)
301319 let slippageX18 = fraction(abs((curPriceX18 - userPriceX18)), scale18, curPriceX18)
302320 let slippageToleranceX18 = toX18(slippageTolerance, scale8)
303321 if (if ((curPriceX18 != zeroBigInt))
304322 then (slippageX18 > slippageToleranceX18)
305323 else false)
306324 then throw(((("Price slippage " + toString(slippageX18)) + " exceeded the passed limit of ") + toString(slippageToleranceX18)))
307325 else {
308326 let lpEmissionX18 = toX18(lpEmission, scale8)
309327 let prViaAmX18 = fraction(inAmAssetAmtX18, curPriceX18, scale18)
310328 let amViaPrX18 = fraction(inPrAssetAmtX18, scale18, curPriceX18)
311329 let expectedAmts = if ((prViaAmX18 > inPrAssetAmtX18))
312330 then $Tuple2(amViaPrX18, inPrAssetAmtX18)
313331 else $Tuple2(inAmAssetAmtX18, prViaAmX18)
314332 let expAmtAssetAmtX18 = expectedAmts._1
315333 let expPriceAssetAmtX18 = expectedAmts._2
316334 let lpAmtX18 = fraction(lpEmissionX18, expPriceAssetAmtX18, prBalanceX18)
317335 $Tuple5(fromX18(lpAmtX18, scale8), fromX18(expAmtAssetAmtX18, amtAssetDcm), fromX18(expPriceAssetAmtX18, priceAssetDcm), curPriceX18, slippageX18)
318336 }
319337 }
320338 let calcLpAmt = res._1
321339 let calcAmAssetPmt = res._2
322340 let calcPrAssetPmt = res._3
323341 let curPrice = fromX18(res._4, scale8)
324342 let slippageCalc = fromX18(res._5, scale8)
325343 if ((0 >= calcLpAmt))
326344 then throw("Invalid calculations. LP calculated is less than zero.")
327345 else {
328346 let emitLpAmt = if (!(emitLp))
329347 then 0
330348 else calcLpAmt
331349 let amDiff = (inAmAssetAmt - calcAmAssetPmt)
332350 let prDiff = (inPrAssetAmt - calcPrAssetPmt)
333351 let commonState = [IntegerEntry(pl(), curPrice), IntegerEntry(ph(height, lastBlock.timestamp), curPrice), StringEntry(pau(userAddress, txId58), dataPutActionInfo(calcAmAssetPmt, calcPrAssetPmt, emitLpAmt, curPrice, slippageTolerance, slippageCalc, height, lastBlock.timestamp, amDiff, prDiff))]
334352 $Tuple13(calcLpAmt, emitLpAmt, curPrice, amBalance, prBalance, lpEmission, lpAssetId, poolStatus, commonState, amDiff, prDiff, inAmAssetId, inPrAssetId)
335353 }
336354 }
337355 }
338356
339357
340358 func validateMatcherOrderAllowed (order) = {
341359 let cfg = getPoolConfig()
342360 let amtAssetId = cfg[idxAmtAssetId]
343361 let priceAssetId = cfg[idxPriceAssetId]
344362 let poolStatus = parseIntValue(cfg[idxPoolStatus])
345363 let amtAssetDcm = parseIntValue(cfg[idxAmtAssetDcm])
346364 let priceAssetDcm = parseIntValue(cfg[idxPriceAssetDcm])
347365 let accAmtAssetBalance = getAccBalance(amtAssetId)
348366 let accPriceAssetBalance = getAccBalance(priceAssetId)
349367 let curPriceX18 = if ((order.orderType == Buy))
350368 then privateCalcPrice(amtAssetDcm, priceAssetDcm, (accAmtAssetBalance + order.amount), accPriceAssetBalance)
351369 else privateCalcPrice(amtAssetDcm, priceAssetDcm, (accAmtAssetBalance - order.amount), accPriceAssetBalance)
352370 let curPrice = fromX18(curPriceX18, scale8)
353371 if (if (if (isGlobalShutdown())
354372 then true
355373 else (poolStatus == PoolMatcherDisabled))
356374 then true
357375 else (poolStatus == PoolShutdown))
358376 then throw("Exchange operations disabled")
359377 else {
360378 let orderAmtAsset = order.assetPair.amountAsset
361379 let orderAmtAssetStr = if ((orderAmtAsset == unit))
362380 then "WAVES"
363381 else toBase58String(value(orderAmtAsset))
364382 let orderPriceAsset = order.assetPair.priceAsset
365383 let orderPriceAssetStr = if ((orderPriceAsset == unit))
366384 then "WAVES"
367385 else toBase58String(value(orderPriceAsset))
368386 if (if ((orderAmtAssetStr != amtAssetId))
369387 then true
370388 else (orderPriceAssetStr != priceAssetId))
371389 then throw("Wrong order assets.")
372390 else {
373391 let orderPrice = order.price
374392 let priceDcm = fraction(scale8, priceAssetDcm, amtAssetDcm)
375393 let castedOrderPrice = toScale(orderPrice, scale8, priceDcm)
376394 let isOrderPriceValid = if ((order.orderType == Buy))
377395 then (curPrice >= castedOrderPrice)
378396 else (castedOrderPrice >= curPrice)
379397 true
380398 }
381399 }
382400 }
383401
384402
385403 func commonGet (i) = if ((size(i.payments) != 1))
386404 then throw("exactly 1 payment is expected")
387405 else {
388406 let pmt = value(i.payments[0])
389407 let pmtAssetId = value(pmt.assetId)
390408 let pmtAmt = pmt.amount
391409 let res = estimateGetOperation(toBase58String(i.transactionId), toBase58String(pmtAssetId), pmtAmt, i.caller)
392410 let outAmAmt = res._1
393411 let outPrAmt = res._2
394412 let poolStatus = parseIntValue(res._9)
395413 let state = res._10
396414 if (if (isGlobalShutdown())
397415 then true
398416 else (poolStatus == PoolShutdown))
399417 then throw(("Get operation is blocked by admin. Status = " + toString(poolStatus)))
400418 else $Tuple5(outAmAmt, outPrAmt, pmtAmt, pmtAssetId, state)
401419 }
402420
403421
404422 func commonPut (i,slippageTolerance,emitLp) = if ((size(i.payments) != 2))
405423 then throw("exactly 2 payments are expected")
406424 else {
407425 let amAssetPmt = value(i.payments[0])
408426 let prAssetPmt = value(i.payments[1])
409427 let estPut = estimatePutOperation(toBase58String(i.transactionId), slippageTolerance, amAssetPmt.amount, amAssetPmt.assetId, prAssetPmt.amount, prAssetPmt.assetId, toString(i.caller), false, emitLp)
410428 let poolStatus = parseIntValue(estPut._8)
411429 if (if (if (isGlobalShutdown())
412430 then true
413431 else (poolStatus == PoolPutDisabled))
414432 then true
415433 else (poolStatus == PoolShutdown))
416434 then throw(("Put operation is blocked by admin. Status = " + toString(poolStatus)))
417435 else estPut
418436 }
419437
420438
421439 func emit (amount) = {
422440 let emitInv = invoke(factoryContract, "emit", [amount], nil)
423441 if ((emitInv == emitInv))
424442 then {
425443 let emitInvLegacy = match emitInv {
426444 case legacyFactoryContract: Address =>
427445 invoke(legacyFactoryContract, "emit", [amount], nil)
428446 case _ =>
429447 unit
430448 }
431449 if ((emitInvLegacy == emitInvLegacy))
432450 then amount
433451 else throw("Strict value is not equal to itself.")
434452 }
435453 else throw("Strict value is not equal to itself.")
436454 }
437455
438456
439457 func takeFee (amount) = {
440458 let feeAmount = fraction(amount, fee, scale8)
441459 $Tuple2((amount - feeAmount), feeAmount)
442460 }
443461
444462
445463 func calcPutOneToken (paymentAmountRaw,paymentAssetId,userAddress,txId) = {
446464 let isEval = (txId == unit)
447- let $t02194222120 = parsePoolConfig(getPoolConfig())
448- let poolAddress = $t02194222120._1
449- let poolStatus = $t02194222120._2
450- let lpAssetId = $t02194222120._3
451- let amountAssetId = $t02194222120._4
452- let priceAssetId = $t02194222120._5
453- let amountAssetDecimals = $t02194222120._6
454- let priceAssetDecimals = $t02194222120._7
465+ let $t02216722345 = parsePoolConfig(getPoolConfig())
466+ let poolAddress = $t02216722345._1
467+ let poolStatus = $t02216722345._2
468+ let lpAssetId = $t02216722345._3
469+ let amountAssetId = $t02216722345._4
470+ let priceAssetId = $t02216722345._5
471+ let amountAssetDecimals = $t02216722345._6
472+ let priceAssetDecimals = $t02216722345._7
455473 let amountBalanceRaw = getAccBalance(assetIdToString(amountAssetId))
456474 let priceBalanceRaw = getAccBalance(assetIdToString(priceAssetId))
457475 let paymentInAmountAsset = if ((paymentAssetId == amountAssetId))
458476 then true
459477 else if ((paymentAssetId == priceAssetId))
460478 then false
461479 else throwErr("invalid asset")
462- let $t02245022743 = if (isEval)
480+ let $t02267522968 = if (isEval)
463481 then $Tuple2(amountBalanceRaw, priceBalanceRaw)
464482 else if (paymentInAmountAsset)
465483 then $Tuple2((amountBalanceRaw - paymentAmountRaw), priceBalanceRaw)
466484 else $Tuple2(amountBalanceRaw, (priceBalanceRaw - paymentAmountRaw))
467- let amountBalanceOld = $t02245022743._1
468- let priceBalanceOld = $t02245022743._2
469- let $t02274722896 = if (paymentInAmountAsset)
485+ let amountBalanceOld = $t02267522968._1
486+ let priceBalanceOld = $t02267522968._2
487+ let $t02297223121 = if (paymentInAmountAsset)
470488 then $Tuple2(paymentAmountRaw, 0)
471489 else $Tuple2(0, paymentAmountRaw)
472- let amountAssetAmountRaw = $t02274722896._1
473- let priceAssetAmountRaw = $t02274722896._2
490+ let amountAssetAmountRaw = $t02297223121._1
491+ let priceAssetAmountRaw = $t02297223121._2
474492 let amountAssetAmount = takeFee(amountAssetAmountRaw)._1
475493 let priceAssetAmount = takeFee(priceAssetAmountRaw)._1
476- let $t02301823077 = takeFee(paymentAmountRaw)
477- let paymentAmount = $t02301823077._1
478- let feeAmount = $t02301823077._2
494+ let $t02324323302 = takeFee(paymentAmountRaw)
495+ let paymentAmount = $t02324323302._1
496+ let feeAmount = $t02324323302._2
479497 let amountBalanceNew = (amountBalanceOld + amountAssetAmount)
480498 let priceBalanceNew = (priceBalanceOld + priceAssetAmount)
481499 let curPrice = fromX18(calcPriceBigInt(toX18(priceBalanceNew, priceAssetDecimals), toX18(amountBalanceNew, amountAssetDecimals)), scale8)
482500 let paymentBalance = if (paymentInAmountAsset)
483501 then amountBalanceOld
484502 else priceBalanceOld
485503 let paymentBalanceBigInt = toBigInt(paymentBalance)
486504 let supplyBigInt = toBigInt(valueOrErrorMessage(assetInfo(lpAssetId), (("asset " + toBase58String(lpAssetId)) + " doesn't exist")).quantity)
487505 let chechSupply = if ((supplyBigInt > big0))
488506 then true
489507 else throw("initial deposit requires all coins")
490508 if ((chechSupply == chechSupply))
491509 then {
492510 let depositBigInt = toBigInt(paymentAmount)
493511 let issueAmount = toInt(((supplyBigInt * (sqrtBigInt((scale8BigInt + ((depositBigInt * scale8BigInt) / paymentBalanceBigInt)), 8, 8, DOWN) - scale8BigInt)) / scale8BigInt))
494512 let commonState = if (isEval)
495513 then nil
496514 else [IntegerEntry(pl(), curPrice), IntegerEntry(ph(height, lastBlock.timestamp), curPrice), StringEntry(pau(toString(value(userAddress)), toBase58String(value(txId))), dataPutActionInfo(amountAssetAmountRaw, priceAssetAmountRaw, issueAmount, curPrice, 0, 0, height, lastBlock.timestamp, 0, 0))]
497515 let poolProportion = fraction(priceBalanceOld, scale8, amountBalanceOld)
498516 let amountAssetPart = fraction(paymentAmountRaw, scale8, (poolProportion + scale8))
499517 let priceAssetPart = (paymentAmountRaw - amountAssetPart)
500518 let lpAmtBoth = fraction(supplyBigInt, toBigInt(priceAssetPart), toBigInt(priceBalanceOld))
501519 let bonus = toInt(fraction((toBigInt(issueAmount) - lpAmtBoth), scale8BigInt, lpAmtBoth))
502520 $Tuple4(issueAmount, commonState, feeAmount, bonus)
503521 }
504522 else throw("Strict value is not equal to itself.")
505523 }
506524
507525
508526 func calcGetOneToken (outAssetId,paymentAmount,paymentAssetId,userAddress,txId) = {
509527 let isEval = (txId == unit)
510- let $t02502725188 = parsePoolConfig(getPoolConfig())
511- let poolAddress = $t02502725188._1
512- let poolStatus = $t02502725188._2
513- let lpAssetId = $t02502725188._3
514- let amountAssetId = $t02502725188._4
515- let priceAssetId = $t02502725188._5
516- let amDecimals = $t02502725188._6
517- let prDecimals = $t02502725188._7
528+ let $t02525225413 = parsePoolConfig(getPoolConfig())
529+ let poolAddress = $t02525225413._1
530+ let poolStatus = $t02525225413._2
531+ let lpAssetId = $t02525225413._3
532+ let amountAssetId = $t02525225413._4
533+ let priceAssetId = $t02525225413._5
534+ let amDecimals = $t02525225413._6
535+ let prDecimals = $t02525225413._7
518536 let checks = [if ((paymentAssetId == lpAssetId))
519537 then true
520538 else throw("invalid lp asset")]
521539 if ((checks == checks))
522540 then {
523541 let outInAmountAsset = if ((outAssetId == amountAssetId))
524542 then true
525543 else if ((outAssetId == priceAssetId))
526544 then false
527545 else throwErr("invalid asset")
528546 let balanceBigInt = if (outInAmountAsset)
529547 then toBigInt(getAccBalance(assetIdToString(amountAssetId)))
530548 else toBigInt(getAccBalance(assetIdToString(priceAssetId)))
531549 let amBalanceOld = getAccBalance(assetIdToString(amountAssetId))
532550 let prBalanceOld = getAccBalance(assetIdToString(priceAssetId))
533551 let outBalance = if (outInAmountAsset)
534552 then amBalanceOld
535553 else prBalanceOld
536554 let outBalanceBigInt = toBigInt(outBalance)
537555 let supplyBigInt = toBigInt(valueOrErrorMessage(assetInfo(lpAssetId), (("asset " + toBase58String(lpAssetId)) + " doesn't exist")).quantity)
538556 let redeemedBigInt = toBigInt(paymentAmount)
539557 let amountRaw = toInt(((balanceBigInt * (scale8BigInt - pow((scale8BigInt - ((redeemedBigInt * scale8BigInt) / supplyBigInt)), 8, big2, 0, 8, DOWN))) / scale8BigInt))
540- let $t02625526305 = takeFee(amountRaw)
541- let totalAmount = $t02625526305._1
542- let feeAmount = $t02625526305._2
543- let $t02630926535 = if (outInAmountAsset)
558+ let $t02648026530 = takeFee(amountRaw)
559+ let totalAmount = $t02648026530._1
560+ let feeAmount = $t02648026530._2
561+ let $t02653426760 = if (outInAmountAsset)
544562 then $Tuple4(totalAmount, 0, (amBalanceOld - amountRaw), prBalanceOld)
545563 else $Tuple4(0, totalAmount, amBalanceOld, (prBalanceOld - amountRaw))
546- let outAmAmount = $t02630926535._1
547- let outPrAmount = $t02630926535._2
548- let amBalanceNew = $t02630926535._3
549- let prBalanceNew = $t02630926535._4
564+ let outAmAmount = $t02653426760._1
565+ let outPrAmount = $t02653426760._2
566+ let amBalanceNew = $t02653426760._3
567+ let prBalanceNew = $t02653426760._4
550568 let curPrX18 = calcPriceBigInt(toX18(prBalanceNew, prDecimals), toX18(amBalanceNew, amDecimals))
551569 let curPrice = fromX18(curPrX18, scale8)
552570 let commonState = if (isEval)
553571 then nil
554572 else [StringEntry(gau(toString(value(userAddress)), toBase58String(value(txId))), dataGetActionInfo(outAmAmount, outPrAmount, paymentAmount, curPrice, height, lastBlock.timestamp)), IntegerEntry(pl(), curPrice), IntegerEntry(ph(height, lastBlock.timestamp), curPrice)]
555573 let r = estimateGetOperation("", assetIdToString(lpAssetId), paymentAmount, this)
556574 let sumOfGetAssets = (r._1 + r._2)
557575 let bonus = fraction((totalAmount - sumOfGetAssets), scale8, sumOfGetAssets)
558576 $Tuple4(totalAmount, commonState, feeAmount, bonus)
559577 }
560578 else throw("Strict value is not equal to itself.")
561579 }
562580
563581
564582 func managerPublicKeyOrUnit () = match getString(mpk()) {
565583 case s: String =>
566584 fromBase58String(s)
567585 case _: Unit =>
568586 unit
569587 case _ =>
570588 throw("Match error")
571589 }
572590
573591
574592 func pendingManagerPublicKeyOrUnit () = match getString(pmpk()) {
575593 case s: String =>
576594 fromBase58String(s)
577595 case _: Unit =>
578596 unit
579597 case _ =>
580598 throw("Match error")
581599 }
582600
583601
584602 func mustManager (i) = {
585603 let pd = throw("Permission denied")
586604 match managerPublicKeyOrUnit() {
587605 case pk: ByteVector =>
588606 if ((i.callerPublicKey == pk))
589607 then true
590608 else pd
591609 case _: Unit =>
592610 if ((i.caller == this))
593611 then true
594612 else pd
595613 case _ =>
596614 throw("Match error")
597615 }
598616 }
599617
600618
601619 @Callable(i)
602620 func setManager (pendingManagerPublicKey) = {
603621 let checkCaller = mustManager(i)
604622 if ((checkCaller == checkCaller))
605623 then {
606624 let checkManagerPublicKey = fromBase58String(pendingManagerPublicKey)
607625 if ((checkManagerPublicKey == checkManagerPublicKey))
608626 then [StringEntry(pmpk(), pendingManagerPublicKey)]
609627 else throw("Strict value is not equal to itself.")
610628 }
611629 else throw("Strict value is not equal to itself.")
612630 }
613631
614632
615633
616634 @Callable(i)
617635 func confirmManager () = {
618636 let pm = pendingManagerPublicKeyOrUnit()
619637 let hasPM = if (isDefined(pm))
620638 then true
621639 else throw("No pending manager")
622640 if ((hasPM == hasPM))
623641 then {
624642 let checkPM = if ((i.callerPublicKey == value(pm)))
625643 then true
626644 else throw("You are not pending manager")
627645 if ((checkPM == checkPM))
628646 then [StringEntry(mpk(), toBase58String(value(pm))), DeleteEntry(pmpk())]
629647 else throw("Strict value is not equal to itself.")
630648 }
631649 else throw("Strict value is not equal to itself.")
632650 }
633651
634652
635653
636654 @Callable(i)
637655 func put (slippageTolerance,shouldAutoStake) = if ((0 > slippageTolerance))
638656 then throw("Invalid slippageTolerance passed")
639657 else {
640658 let estPut = commonPut(i, slippageTolerance, true)
641659 let emitLpAmt = estPut._2
642660 let lpAssetId = estPut._7
643661 let state = estPut._9
644662 let amDiff = estPut._10
645663 let prDiff = estPut._11
646664 let amId = estPut._12
647665 let prId = estPut._13
648666 let emitInv = invoke(factoryContract, "emit", [emitLpAmt], nil)
649667 if ((emitInv == emitInv))
650668 then {
651669 let emitInvLegacy = match emitInv {
652670 case legacyFactoryContract: Address =>
653671 invoke(legacyFactoryContract, "emit", [emitLpAmt], nil)
654672 case _ =>
655673 unit
656674 }
657675 if ((emitInvLegacy == emitInvLegacy))
658676 then {
659677 let slippageAInv = if ((amDiff > 0))
660678 then invoke(slippageContract, "put", nil, [AttachedPayment(amId, amDiff)])
661679 else nil
662680 if ((slippageAInv == slippageAInv))
663681 then {
664682 let slippagePInv = if ((prDiff > 0))
665683 then invoke(slippageContract, "put", nil, [AttachedPayment(prId, prDiff)])
666684 else nil
667685 if ((slippagePInv == slippagePInv))
668686 then {
669687 let lpTransfer = if (shouldAutoStake)
670688 then {
671689 let slpStakeInv = invoke(stakingContract, "stake", nil, [AttachedPayment(lpAssetId, emitLpAmt)])
672690 if ((slpStakeInv == slpStakeInv))
673691 then nil
674692 else throw("Strict value is not equal to itself.")
675693 }
676694 else [ScriptTransfer(i.caller, emitLpAmt, lpAssetId)]
677695 (state ++ lpTransfer)
678696 }
679697 else throw("Strict value is not equal to itself.")
680698 }
681699 else throw("Strict value is not equal to itself.")
682700 }
683701 else throw("Strict value is not equal to itself.")
684702 }
685703 else throw("Strict value is not equal to itself.")
686704 }
687705
688706
689707
690708 @Callable(i)
691709 func putForFree (maxSlippage) = if ((0 > maxSlippage))
692710 then throw("Invalid value passed")
693711 else {
694712 let estPut = commonPut(i, maxSlippage, false)
695713 estPut._9
696714 }
697715
698716
699717
700718 @Callable(i)
701719 func putOneTkn (minOutAmount,autoStake) = {
702- let $t03042630604 = parsePoolConfig(getPoolConfig())
703- let poolAddress = $t03042630604._1
704- let poolStatus = $t03042630604._2
705- let lpAssetId = $t03042630604._3
706- let amountAssetId = $t03042630604._4
707- let priceAssetId = $t03042630604._5
708- let amountAssetDecimals = $t03042630604._6
709- let priceAssetDecimals = $t03042630604._7
710720 let isPutDisabled = if (if (isGlobalShutdown())
711721 then true
712- else (poolStatus == PoolPutDisabled))
722+ else (cfgPoolStatus == PoolPutDisabled))
713723 then true
714- else (poolStatus == PoolShutdown)
724+ else (cfgPoolStatus == PoolShutdown)
715725 let checks = [if (!(isPutDisabled))
716726 then true
717727 else throwErr("put operation is blocked by admin"), if ((size(i.payments) == 1))
718728 then true
719729 else throwErr("exactly 1 payment are expected")]
720730 if ((checks == checks))
721731 then {
722732 let payment = i.payments[0]
723733 let paymentAssetId = payment.assetId
724734 let paymentAmountRaw = payment.amount
725- let paymentAmount = paymentAmountRaw
726735 let userAddress = i.caller
727736 let txId = i.transactionId
728- let $t03109131218 = calcPutOneToken(paymentAmountRaw, paymentAssetId, userAddress, txId)
729- let emitAmountEstimated = $t03109131218._1
730- let commonState = $t03109131218._2
731- let feeAmount = $t03109131218._3
732- let bonus = $t03109131218._4
737+ let $t03110131228 = calcPutOneToken(paymentAmountRaw, paymentAssetId, userAddress, txId)
738+ let emitAmountEstimated = $t03110131228._1
739+ let commonState = $t03110131228._2
740+ let feeAmount = $t03110131228._3
741+ let bonus = $t03110131228._4
733742 let emitAmount = if (if ((minOutAmount > 0))
734743 then (minOutAmount > emitAmountEstimated)
735744 else false)
736745 then throw(makeString(["amount to receive is less than ", toString(minOutAmount)], ""))
737746 else emitAmountEstimated
738747 let emitInv = emit(emitAmount)
739748 if ((emitInv == emitInv))
740749 then {
741750 let lpTransfer = if (autoStake)
742751 then {
743- let stakeInv = invoke(stakingContract, "stake", nil, [AttachedPayment(lpAssetId, emitAmount)])
752+ let stakeInv = invoke(stakingContract, "stake", nil, [AttachedPayment(cfgLpAssetId, emitAmount)])
744753 if ((stakeInv == stakeInv))
745754 then nil
746755 else throw("Strict value is not equal to itself.")
747756 }
748- else [ScriptTransfer(i.caller, emitAmount, lpAssetId)]
757+ else [ScriptTransfer(i.caller, emitAmount, cfgLpAssetId)]
749758 let sendFee = if ((feeAmount > 0))
750759 then [ScriptTransfer(feeCollectorAddress, feeAmount, paymentAssetId)]
751760 else nil
752761 $Tuple2(((commonState ++ lpTransfer) ++ sendFee), emitAmount)
753762 }
754763 else throw("Strict value is not equal to itself.")
755764 }
756765 else throw("Strict value is not equal to itself.")
757766 }
758767
759768
760769
761770 @Callable(i)
771+func putOneTknREADONLY (paymentAmountRaw,paymentAssetId) = {
772+ let $t03195432089 = calcPutOneToken(paymentAmountRaw, parseAssetId(paymentAssetId), unit, unit)
773+ let emitAmountEstimated = $t03195432089._1
774+ let commonState = $t03195432089._2
775+ let feeAmount = $t03195432089._3
776+ let bonus = $t03195432089._4
777+ $Tuple2(nil, $Tuple3(emitAmountEstimated, feeAmount, bonus))
778+ }
779+
780+
781+
782+@Callable(i)
762783 func getOneTkn (outAssetId,minOutAmount,unstakeAmount) = {
763- let $t03194232120 = parsePoolConfig(getPoolConfig())
764- let poolAddress = $t03194232120._1
765- let poolStatus = $t03194232120._2
766- let lpAssetId = $t03194232120._3
767- let amountAssetId = $t03194232120._4
768- let priceAssetId = $t03194232120._5
769- let amountAssetDecimals = $t03194232120._6
770- let priceAssetDecimals = $t03194232120._7
771784 let isGetDisabled = if (isGlobalShutdown())
772785 then true
773- else (poolStatus == PoolShutdown)
786+ else (cfgPoolStatus == PoolShutdown)
774787 let checks = [if (!(isGetDisabled))
775788 then true
776789 else throwErr("get operation is blocked by admin"), if ((size(i.payments) == 1))
777790 then true
778791 else throwErr("exactly 1 payment are expected")]
779792 if ((checks == checks))
780793 then {
781794 let payment = i.payments[0]
782795 let paymentAssetId = payment.assetId
783796 let paymentAmount = payment.amount
784797 let userAddress = i.caller
785798 let txId = i.transactionId
786- let $t03253132678 = calcGetOneToken(parseAssetId(outAssetId), paymentAmount, paymentAssetId, userAddress, txId)
787- let amountEstimated = $t03253132678._1
788- let commonState = $t03253132678._2
789- let feeAmount = $t03253132678._3
790- let bonus = $t03253132678._4
799+ let $t03264532792 = calcGetOneToken(parseAssetId(outAssetId), paymentAmount, paymentAssetId, userAddress, txId)
800+ let amountEstimated = $t03264532792._1
801+ let commonState = $t03264532792._2
802+ let feeAmount = $t03264532792._3
803+ let bonus = $t03264532792._4
791804 let amount = if (if ((minOutAmount > 0))
792805 then (minOutAmount > amountEstimated)
793806 else false)
794807 then throw(makeString(["amount to receive is less than ", toString(minOutAmount)], ""))
795808 else amountEstimated
796809 let burnInv = invoke(factoryContract, "burn", [paymentAmount], [AttachedPayment(paymentAssetId, paymentAmount)])
797810 if ((burnInv == burnInv))
798811 then {
799812 let assetTransfer = [ScriptTransfer(userAddress, amount, parseAssetId(outAssetId))]
800813 $Tuple2(assetTransfer, amount)
801814 }
802815 else throw("Strict value is not equal to itself.")
803816 }
804817 else throw("Strict value is not equal to itself.")
818+ }
819+
820+
821+
822+@Callable(i)
823+func getOneTknREADONLY (outAssetId,paymentAmount) = {
824+ let $t03330333441 = calcGetOneToken(parseAssetId(outAssetId), paymentAmount, cfgLpAssetId, unit, unit)
825+ let amountEstimated = $t03330333441._1
826+ let commonState = $t03330333441._2
827+ let feeAmount = $t03330333441._3
828+ let bonus = $t03330333441._4
829+ $Tuple2(nil, $Tuple3(amountEstimated, feeAmount, bonus))
805830 }
806831
807832
808833
809834 @Callable(i)
810835 func get () = {
811836 let res = commonGet(i)
812837 let outAmtAmt = res._1
813838 let outPrAmt = res._2
814839 let pmtAmt = res._3
815840 let pmtAssetId = res._4
816841 let state = res._5
817842 let burnLPAssetOnFactory = invoke(factoryContract, "burn", [pmtAmt], [AttachedPayment(pmtAssetId, pmtAmt)])
818843 if ((burnLPAssetOnFactory == burnLPAssetOnFactory))
819844 then state
820845 else throw("Strict value is not equal to itself.")
821846 }
822847
823848
824849
825850 @Callable(i)
826851 func getNoLess (noLessThenAmtAsset,noLessThenPriceAsset) = {
827852 let res = commonGet(i)
828853 let outAmAmt = res._1
829854 let outPrAmt = res._2
830855 let pmtAmt = res._3
831856 let pmtAssetId = res._4
832857 let state = res._5
833858 if ((noLessThenAmtAsset > outAmAmt))
834859 then throw(((("noLessThenAmtAsset failed: " + toString(outAmAmt)) + " < ") + toString(noLessThenAmtAsset)))
835860 else if ((noLessThenPriceAsset > outPrAmt))
836861 then throw(((("noLessThenPriceAsset failed: " + toString(outPrAmt)) + " < ") + toString(noLessThenPriceAsset)))
837862 else {
838863 let burnLPAssetOnFactory = invoke(factoryContract, "burn", [pmtAmt], [AttachedPayment(pmtAssetId, pmtAmt)])
839864 if ((burnLPAssetOnFactory == burnLPAssetOnFactory))
840865 then state
841866 else throw("Strict value is not equal to itself.")
842867 }
843868 }
844869
845870
846871
847872 @Callable(i)
848873 func unstakeAndGet (amount) = {
849874 let checkPayments = if ((size(i.payments) != 0))
850875 then throw("No payments are expected")
851876 else true
852877 if ((checkPayments == checkPayments))
853878 then {
854879 let cfg = getPoolConfig()
855880 let lpAssetId = fromBase58String(cfg[idxPoolLPAssetId])
856881 let unstakeInv = invoke(stakingContract, "unstake", [toBase58String(lpAssetId), amount], nil)
857882 if ((unstakeInv == unstakeInv))
858883 then {
859884 let res = estimateGetOperation(toBase58String(i.transactionId), toBase58String(lpAssetId), amount, i.caller)
860885 let poolStatus = parseIntValue(res._9)
861886 let state = res._10
862887 let checkPoolStatus = if (if (isGlobalShutdown())
863888 then true
864889 else (poolStatus == PoolShutdown))
865890 then throw(("Get operation is blocked by admin. Status = " + toString(poolStatus)))
866891 else true
867892 if ((checkPoolStatus == checkPoolStatus))
868893 then {
869894 let burnLPAssetOnFactory = invoke(factoryContract, "burn", [amount], [AttachedPayment(lpAssetId, amount)])
870895 if ((burnLPAssetOnFactory == burnLPAssetOnFactory))
871896 then state
872897 else throw("Strict value is not equal to itself.")
873898 }
874899 else throw("Strict value is not equal to itself.")
875900 }
876901 else throw("Strict value is not equal to itself.")
877902 }
878903 else throw("Strict value is not equal to itself.")
879904 }
880905
881906
882907
883908 @Callable(i)
884909 func activate (amtAssetStr,priceAssetStr) = if ((toString(i.caller) != toString(factoryContract)))
885910 then throw("permissions denied")
886911 else $Tuple2([StringEntry(aa(), amtAssetStr), StringEntry(pa(), priceAssetStr)], "success")
887912
888913
889914
890915 @Callable(i)
891916 func getPoolConfigWrapperREADONLY () = $Tuple2(nil, getPoolConfig())
892917
893918
894919
895920 @Callable(i)
896921 func getAccBalanceWrapperREADONLY (assetId) = $Tuple2(nil, getAccBalance(assetId))
897922
898923
899924
900925 @Callable(i)
901926 func calcPricesWrapperREADONLY (amAmt,prAmt,lpAmt) = {
902927 let prices = calcPrices(amAmt, prAmt, lpAmt)
903928 $Tuple2(nil, [toString(prices[0]), toString(prices[1]), toString(prices[2])])
904929 }
905930
906931
907932
908933 @Callable(i)
909934 func toX18WrapperREADONLY (origVal,origScaleMult) = $Tuple2(nil, toString(toX18(origVal, origScaleMult)))
910935
911936
912937
913938 @Callable(i)
914939 func fromX18WrapperREADONLY (val,resultScaleMult) = $Tuple2(nil, fromX18(parseBigIntValue(val), resultScaleMult))
915940
916941
917942
918943 @Callable(i)
919944 func calcPriceBigIntWrapperREADONLY (prAmtX18,amAmtX18) = $Tuple2(nil, toString(calcPriceBigInt(parseBigIntValue(prAmtX18), parseBigIntValue(amAmtX18))))
920945
921946
922947
923948 @Callable(i)
924949 func estimatePutOperationWrapperREADONLY (txId58,slippageTolerance,inAmAssetAmt,inAmAssetId,inPrAssetAmt,inPrAssetId,userAddress,isEvaluate,emitLp) = $Tuple2(nil, estimatePutOperation(txId58, slippageTolerance, inAmAssetAmt, inAmAssetId, inPrAssetAmt, inPrAssetId, userAddress, isEvaluate, emitLp))
925950
926951
927952
928953 @Callable(i)
929954 func estimateGetOperationWrapperREADONLY (txId58,pmtAssetId,pmtLpAmt,userAddress) = {
930955 let res = estimateGetOperation(txId58, pmtAssetId, pmtLpAmt, addressFromStringValue(userAddress))
931956 $Tuple2(nil, $Tuple10(res._1, res._2, res._3, res._4, res._5, res._6, res._7, toString(res._8), res._9, res._10))
932957 }
933958
934959
935960
936961 @Callable(i)
937962 func statsREADONLY () = {
938963 let cfg = getPoolConfig()
939964 let lpAssetId = fromBase58String(cfg[idxPoolLPAssetId])
940965 let amtAssetId = cfg[idxAmtAssetId]
941966 let priceAssetId = cfg[idxPriceAssetId]
942967 let iAmtAssetId = cfg[idxIAmtAssetId]
943968 let iPriceAssetId = cfg[idxIPriceAssetId]
944969 let amtAssetDcm = parseIntValue(cfg[idxAmtAssetDcm])
945970 let priceAssetDcm = parseIntValue(cfg[idxPriceAssetDcm])
946971 let poolLPBalance = valueOrErrorMessage(assetInfo(lpAssetId), (("Asset " + toBase58String(lpAssetId)) + " doesn't exist")).quantity
947972 let accAmtAssetBalance = getAccBalance(amtAssetId)
948973 let accPriceAssetBalance = getAccBalance(priceAssetId)
949974 let pricesList = if ((poolLPBalance == 0))
950975 then [zeroBigInt, zeroBigInt, zeroBigInt]
951976 else calcPrices(accAmtAssetBalance, accPriceAssetBalance, poolLPBalance)
952977 let curPrice = 0
953978 let lpAmtAssetShare = fromX18(pricesList[1], scale8)
954979 let lpPriceAssetShare = fromX18(pricesList[2], scale8)
955980 let poolWeight = value(getInteger(factoryContract, keyPoolWeight(toString(this))))
956981 $Tuple2(nil, makeString(["%d%d%d%d%d%d%d", toString(accAmtAssetBalance), toString(accPriceAssetBalance), toString(poolLPBalance), toString(curPrice), toString(lpAmtAssetShare), toString(lpPriceAssetShare), toString(poolWeight)], SEP))
957982 }
958983
959984
960985
961986 @Callable(i)
962987 func evaluatePutByAmountAssetREADONLY (inAmAssetAmt) = {
963988 let cfg = getPoolConfig()
964989 let lpAssetId = fromBase58String(cfg[idxPoolLPAssetId])
965990 let amAssetIdStr = cfg[idxAmtAssetId]
966991 let amAssetId = fromBase58String(amAssetIdStr)
967992 let prAssetIdStr = cfg[idxPriceAssetId]
968993 let prAssetId = fromBase58String(prAssetIdStr)
969994 let amtAssetDcm = parseIntValue(cfg[idxAmtAssetDcm])
970995 let priceAssetDcm = parseIntValue(cfg[idxPriceAssetDcm])
971996 let poolStatus = cfg[idxPoolStatus]
972997 let poolLPBalance = valueOrErrorMessage(assetInfo(lpAssetId), (("Asset " + toBase58String(lpAssetId)) + " doesn't exist")).quantity
973998 let accAmtAssetBalance = getAccBalance(amAssetIdStr)
974999 let accPriceAssetBalance = getAccBalance(prAssetIdStr)
9751000 let amtAssetAmtX18 = toX18(accAmtAssetBalance, amtAssetDcm)
9761001 let priceAssetAmtX18 = toX18(accPriceAssetBalance, priceAssetDcm)
9771002 let curPriceX18 = if ((poolLPBalance == 0))
9781003 then zeroBigInt
9791004 else calcPriceBigInt(priceAssetAmtX18, amtAssetAmtX18)
9801005 let inAmAssetAmtX18 = toX18(inAmAssetAmt, amtAssetDcm)
9811006 let inPrAssetAmtX18 = fraction(inAmAssetAmtX18, curPriceX18, scale18)
9821007 let inPrAssetAmt = fromX18(inPrAssetAmtX18, priceAssetDcm)
9831008 let estPut = estimatePutOperation("", 500000, inAmAssetAmt, amAssetId, inPrAssetAmt, prAssetId, "", true, false)
9841009 let calcLpAmt = estPut._1
9851010 let curPriceCalc = estPut._3
9861011 let amBalance = estPut._4
9871012 let prBalance = estPut._5
9881013 let lpEmission = estPut._6
9891014 $Tuple2(nil, makeString(["%d%d%d%d%d%d%d%d", toString(calcLpAmt), toString(fromX18(curPriceX18, scale8)), toString(amBalance), toString(prBalance), toString(lpEmission), poolStatus, toString(inAmAssetAmt), toString(inPrAssetAmt)], SEP))
9901015 }
9911016
9921017
9931018
9941019 @Callable(i)
9951020 func evaluatePutByPriceAssetREADONLY (inPrAssetAmt) = {
9961021 let cfg = getPoolConfig()
9971022 let lpAssetId = fromBase58String(cfg[idxPoolLPAssetId])
9981023 let amAssetIdStr = cfg[idxAmtAssetId]
9991024 let amAssetId = fromBase58String(amAssetIdStr)
10001025 let prAssetIdStr = cfg[idxPriceAssetId]
10011026 let prAssetId = fromBase58String(prAssetIdStr)
10021027 let amtAssetDcm = parseIntValue(cfg[idxAmtAssetDcm])
10031028 let priceAssetDcm = parseIntValue(cfg[idxPriceAssetDcm])
10041029 let poolStatus = cfg[idxPoolStatus]
10051030 let poolLPBalance = valueOrErrorMessage(assetInfo(lpAssetId), (("Asset " + toBase58String(lpAssetId)) + " doesn't exist")).quantity
10061031 let amBalanceRaw = getAccBalance(amAssetIdStr)
10071032 let prBalanceRaw = getAccBalance(prAssetIdStr)
10081033 let amBalanceRawX18 = toX18(amBalanceRaw, amtAssetDcm)
10091034 let prBalanceRawX18 = toX18(prBalanceRaw, priceAssetDcm)
10101035 let curPriceX18 = if ((poolLPBalance == 0))
10111036 then zeroBigInt
10121037 else calcPriceBigInt(prBalanceRawX18, amBalanceRawX18)
10131038 let inPrAssetAmtX18 = toX18(inPrAssetAmt, priceAssetDcm)
10141039 let inAmAssetAmtX18 = fraction(inPrAssetAmtX18, scale18, curPriceX18)
10151040 let inAmAssetAmt = fromX18(inAmAssetAmtX18, amtAssetDcm)
10161041 let estPut = estimatePutOperation("", 500000, inAmAssetAmt, amAssetId, inPrAssetAmt, prAssetId, "", true, false)
10171042 let calcLpAmt = estPut._1
10181043 let curPriceCalc = estPut._3
10191044 let amBalance = estPut._4
10201045 let prBalance = estPut._5
10211046 let lpEmission = estPut._6
10221047 $Tuple2(nil, makeString(["%d%d%d%d%d%d%d%d", toString(calcLpAmt), toString(fromX18(curPriceX18, scale8)), toString(amBalance), toString(prBalance), toString(lpEmission), poolStatus, toString(inAmAssetAmt), toString(inPrAssetAmt)], SEP))
10231048 }
10241049
10251050
10261051
10271052 @Callable(i)
10281053 func evaluateGetREADONLY (paymentLpAssetId,paymentLpAmt) = {
10291054 let res = estimateGetOperation("", paymentLpAssetId, paymentLpAmt, this)
10301055 let outAmAmt = res._1
10311056 let outPrAmt = res._2
10321057 let amBalance = res._5
10331058 let prBalance = res._6
10341059 let lpEmission = res._7
10351060 let curPrice = res._8
10361061 let poolStatus = parseIntValue(res._9)
10371062 $Tuple2(nil, makeString(["%d%d%d%d%d%d%d", toString(outAmAmt), toString(outPrAmt), toString(amBalance), toString(prBalance), toString(lpEmission), toString(curPrice), toString(poolStatus)], SEP))
10381063 }
10391064
10401065
10411066 @Verifier(tx)
10421067 func verify () = {
10431068 let targetPublicKey = match managerPublicKeyOrUnit() {
10441069 case pk: ByteVector =>
10451070 pk
10461071 case _: Unit =>
10471072 tx.senderPublicKey
10481073 case _ =>
10491074 throw("Match error")
10501075 }
10511076 match tx {
10521077 case order: Order =>
10531078 let matcherPub = getMatcherPubOrFail()
10541079 let orderValid = validateMatcherOrderAllowed(order)
10551080 let senderValid = sigVerify(order.bodyBytes, order.proofs[0], order.senderPublicKey)
10561081 let matcherValid = sigVerify(order.bodyBytes, order.proofs[1], matcherPub)
10571082 if (if (if (orderValid)
10581083 then senderValid
10591084 else false)
10601085 then matcherValid
10611086 else false)
10621087 then true
10631088 else throwOrderError(orderValid, senderValid, matcherValid)
10641089 case s: SetScriptTransaction =>
10651090 let newHash = blake2b256(value(s.script))
10661091 let allowedHash = fromBase64String(value(getString(factoryContract, keyAllowedLpScriptHash())))
10671092 let currentHash = scriptHash(this)
10681093 if (if ((allowedHash == newHash))
10691094 then (currentHash != newHash)
10701095 else false)
10711096 then true
10721097 else sigVerify(tx.bodyBytes, tx.proofs[0], targetPublicKey)
10731098 case _ =>
10741099 sigVerify(tx.bodyBytes, tx.proofs[0], targetPublicKey)
10751100 }
10761101 }
10771102

github/deemru/w8io/026f985 
117.80 ms