tx · 249zk6hPajqGoYiQbEsDaQaUu7P3iqTLugUMD9CeqYqb

3MwK6nw9HMwuKbXxu6J1rfecvePPd3JyAje:  -0.02700000 Waves

2022.11.30 15:11 [2339818] smart account 3MwK6nw9HMwuKbXxu6J1rfecvePPd3JyAje > SELF 0.00000000 Waves

{ "type": 13, "id": "249zk6hPajqGoYiQbEsDaQaUu7P3iqTLugUMD9CeqYqb", "fee": 2700000, "feeAssetId": null, "timestamp": 1669810269349, "version": 1, "sender": "3MwK6nw9HMwuKbXxu6J1rfecvePPd3JyAje", "senderPublicKey": "8JB75GXEKqxmpXc6KVtT9UNqJ3BBSUZDodYD4DU7CUUB", "proofs": [ "cZ8uqtRENNQQ7KncRm4dE6GDgKyKzbkQdm8sFtK917gCWrYnGxBWTz1ZQdrteACv8agjhxJW71oj71cUtzBDAQf" ], "script": "base64:AAIFAAAAAAAAD10IAhIJCgcBAQEBAQgBEgASBAoCCAgSBAoCCAgSBAoCCAgSAwoBCBIAIg9nZXRTdHJpbmdPckZhaWwiA2tleSIDU0VQIghCVUZTQ0FMRSIGc2NhbGU4Igh0aHJvd0VyciIDbXNnIh1jb252ZXJ0UHJpY2VBc3NldEludG9JZG9Bc3NldCIQcHJpY2VBc3NldEFtb3VudCIOcHJpY2VBc3NldE1VTFQiBXByaWNlIglwcmljZU1VTFQiDGlkb0Fzc2V0TVVMVCIPYlByaWNlQXNzZXRNVUxUIg1iSWRvQXNzZXRNVUxUIg5iUHJpY2VBc3NldEJVRiIPYkFtb3VudEFzc2V0QlVGIg5JZHhDZmdJZG9TdGFydCIRSWR4Q2ZnSWRvRHVyYXRpb24iEElkeENmZ0NsYWltU3RhcnQiE0lkeENmZ0NsYWltRHVyYXRpb24iC0lkeENmZ1ByaWNlIg9JZHhDZmdQcmljZU11bHQiEElkeENmZ0lkb0Fzc2V0SWQiEklkeENmZ0lkb0Fzc2V0TXVsdCISSWR4Q2ZnUHJpY2VBc3NldElkIhRJZHhDZmdQcmljZUFzc2V0TXVsd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Z2VyAwkAAAAAAAACBQAAAAJjWAUAAAACY1gEAAAAAmNZAwkAAAAAAAACCAUAAAACY2oAAAAPY2FsbGVyUHVibGljS2V5CQEAAAAFdmFsdWUAAAABBQAAAAJjVwYJAAACAAAAAQIAAAAbWW91IGFyZSBub3QgcGVuZGluZyBtYW5hZ2VyAwkAAAAAAAACBQAAAAJjWQUAAAACY1kJAARMAAAAAgkBAAAAC1N0cmluZ0VudHJ5AAAAAgkBAAAAAmFCAAAAAAkAAlgAAAABCQEAAAAFdmFsdWUAAAABBQAAAAJjVwkABEwAAAACCQEAAAALRGVsZXRlRW50cnkAAAABCQEAAAACYUMAAAAABQAAAANuaWwJAAACAAAAAQIAAAAkU3RyaWN0IHZhbHVlIGlzIG5vdCBlcXVhbCB0byBpdHNlbGYuCQAAAgAAAAECAAAAJFN0cmljdCB2YWx1ZSBpcyBub3QgZXF1YWwgdG8gaXRzZWxmLgAAAAEAAAACY1oBAAAAAmRhAAAAAAQAAAACZGIEAAAAAmNmCQEAAAACY2UAAAAAAwkAAAEAAAACBQAAAAJjZgIAAAAKQnl0ZVZlY3RvcgQAAAACY2wFAAAAAmNmBQAAAAJjbAMJAAABAAAAAgUAAAACY2YCAAAABFVuaXQIBQAAAAJjWgAAAA9zZW5kZXJQdWJsaWNLZXkJAAACAAAAAQIAAAALTWF0Y2ggZXJyb3IJAAH0AAAAAwgFAAAAAmNaAAAACWJvZHlCeXRlcwkAAZEAAAACCAUAAAACY1oAAAAGcHJvb2ZzAAAAAAAAAAAABQAAAAJkYigvVHc=", "chainId": 84, "height": 2339818, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 6oMJyRJo7UsamLpt6rpiKxJnr69ecHkmka2zy44q453x Next: 6SWYDCccc9xoSNsEnhk9VzCL77LcF3M4mxoxRMFrmyxw Diff:
OldNewDifferences
166166 let priceAssetBalancePriceAssetDecimals = fraction(priceAssetBalance, scale8, pow(10, 0, priceAssetDecimals, 0, 0, DOWN))
167167 let newClaimedPriceAssetAmount = ((claimedPriceAssetAmount + incrementDiff[IdxDiffClaimedPriceAmountIncrement]) - priceAssetBalance)
168168 let newClaimedIdoAssetAmount = ((claimedIdoAssetAmount + incrementDiff[IdxDiffClaimedIdoAssetAmountIncrement]) + priceAssetBalancePriceAssetDecimals)
169- if ((0 > newRemainingAmount))
170- then throwErr(makeString(["invalid math", toString(remainingAmount), toString(incrementDiff[IdxDiffRemainingPriceAmountIncrement]), toString(newRemainingAmount), toString(incrementDiff[IdxDiffTotalIncrement])], " "))
169+ let entries = if ((0 > newRemainingAmount))
170+ then {
171+ let newLogicRemainingAmount = (newTotalAmount - newClaimedPriceAssetAmount)
172+ StringEntry(key, formatInvestor(newTotalAmount, newLogicRemainingAmount, newClaimedPriceAssetAmount, newClaimedIdoAssetAmount, newLastClaimedHeight))
173+ }
171174 else StringEntry(key, formatInvestor(newTotalAmount, newRemainingAmount, newClaimedPriceAssetAmount, newClaimedIdoAssetAmount, newLastClaimedHeight))
175+ entries
172176 }
173177
174178
229233 let periodLength = value(getInteger(keyPeriodLength()))
230234 let currentPeriod = valueOrElse(getInteger(keyCurrentPeriod()), 0)
231235 let zeroPeriodEndHeighIsDefined = isDefined(getInteger(keyPeriodEndHeight(0)))
232- let $t01248214352 = if ((currentPeriod > 0))
236+ let $t01259414464 = if ((currentPeriod > 0))
233237 then {
234238 let lastPeriodStartHeight = value(getInteger(keyPeriodStartHeight(currentPeriod)))
235239 let lastPeriodEndHeight = value(getInteger(keyPeriodEndHeight(currentPeriod)))
236- let $t01274213447 = if ((height > lastPeriodEndHeight))
240+ let $t01285413559 = if ((height > lastPeriodEndHeight))
237241 then {
238242 let updatedCurrentPeriod = (currentPeriod + 1)
239243 let periodStart = if ((height > (lastPeriodEndHeight + periodLength)))
248252 $Tuple3(updatedCurrentPeriod, periodStart, periodEnd)
249253 }
250254 else $Tuple3(currentPeriod, lastPeriodStartHeight, lastPeriodEndHeight)
251- let updatedCurrentPeriod = $t01274213447._1
252- let periodStart = $t01274213447._2
253- let periodEnd = $t01274213447._3
255+ let updatedCurrentPeriod = $t01285413559._1
256+ let periodStart = $t01285413559._2
257+ let periodEnd = $t01285413559._3
254258 $Tuple3(updatedCurrentPeriod, periodStart, periodEnd)
255259 }
256260 else if (zeroPeriodEndHeighIsDefined)
257261 then {
258262 let zeroPeriodStartHeight = value(getInteger(keyPeriodStartHeight(0)))
259263 let zeroPeriodEndHeight = value(getInteger(keyPeriodEndHeight(0)))
260- let $t01370214084 = if ((height > zeroPeriodEndHeight))
264+ let $t01381414196 = if ((height > zeroPeriodEndHeight))
261265 then {
262266 let updatedCurrentPeriod = (currentPeriod + 1)
263267 let periodStart = (zeroPeriodEndHeight + 1)
265269 $Tuple3(updatedCurrentPeriod, periodStart, periodEnd)
266270 }
267271 else $Tuple3(currentPeriod, zeroPeriodStartHeight, zeroPeriodEndHeight)
268- let updatedCurrentPeriod = $t01370214084._1
269- let periodStart = $t01370214084._2
270- let periodEnd = $t01370214084._3
272+ let updatedCurrentPeriod = $t01381414196._1
273+ let periodStart = $t01381414196._2
274+ let periodEnd = $t01381414196._3
271275 $Tuple3(updatedCurrentPeriod, periodStart, periodEnd)
272276 }
273277 else $Tuple3(currentPeriod, valueOrElse(getInteger(keyPeriodStartHeight(currentPeriod)), height), valueOrElse(getInteger(keyPeriodEndHeight(currentPeriod)), ((height + periodLength) - 1)))
274- let updatedCurrentPeriod = $t01248214352._1
275- let periodStart = $t01248214352._2
276- let periodEnd = $t01248214352._3
278+ let updatedCurrentPeriod = $t01259414464._1
279+ let periodStart = $t01259414464._2
280+ let periodEnd = $t01259414464._3
277281 let periodTotalAvailableToClaim = valueOrElse(getInteger(keyPeriodTotalAvailableToClaim(priceAssetId58, updatedCurrentPeriod)), totalPeriodPriceAssetAllowance)
278282 let periodUserAvailableToClaim = valueOrElse(getInteger(keyPeriodUserAvailableToClaim(priceAssetId58, updatedCurrentPeriod, userAddress58)), userPeriodPriceAssetAllowance)
279283 let priceAssetBalance = valueOrElse(getInteger(keyPriceAssetBalance(userAddress58)), 0)
280284 let periodMinAvailableToClaim = min([(outAmount + priceAssetBalance), periodTotalAvailableToClaim, periodUserAvailableToClaim])
281285 let usdtPriceAssetAllowableRatio = value(getInteger(keyUsdtPriceAssetAllowableRatio()))
282286 let putOneTknV2PriceAssetAmount = scale8
283- let $t01510715360 = {
287+ let $t01521915472 = {
284288 let @ = invoke(addressFromStringValue(value(getString(keyUsdtPriceAssetStablePool()))), "putOneTknV2WithoutTakeFeeREADONLY", [putOneTknV2PriceAssetAmount, priceAssetId58], nil)
285289 if ($isInstanceOf(@, "(Int, Int, Int)"))
286290 then @
287291 else throw("Couldn't cast Any to (Int, Int, Int)")
288292 }
289- if (($t01510715360 == $t01510715360))
293+ if (($t01521915472 == $t01521915472))
290294 then {
291- let bonus = $t01510715360._3
292- let feeAmount = $t01510715360._2
293- let lpAmount = $t01510715360._1
295+ let bonus = $t01521915472._3
296+ let feeAmount = $t01521915472._2
297+ let lpAmount = $t01521915472._1
294298 let usdtAssetId = value(getString(keyUsdtAssetId()))
295- let $t01542215640 = {
299+ let $t01553415752 = {
296300 let @ = invoke(addressFromStringValue(value(getString(keyUsdtPriceAssetStablePool()))), "getOneTknV2READONLY", [usdtAssetId, lpAmount], nil)
297301 if ($isInstanceOf(@, "(Int, Int)"))
298302 then @
299303 else throw("Couldn't cast Any to (Int, Int)")
300304 }
301- if (($t01542215640 == $t01542215640))
305+ if (($t01553415752 == $t01553415752))
302306 then {
303- let getOneTknV2FeeAmount = $t01542215640._2
304- let usdtAmount = $t01542215640._1
307+ let getOneTknV2FeeAmount = $t01553415752._2
308+ let usdtAmount = $t01553415752._1
305309 let currentUsdtPriceAssetRatio = fraction(putOneTknV2PriceAssetAmount, scale8, usdtAmount)
306310 let endPeriodBlocksLeft = (periodEnd - height)
307311 $Tuple10(periodMinAvailableToClaim, periodTotalAvailableToClaim, periodUserAvailableToClaim, totalUserAvailableToClaim, usdtPriceAssetAllowableRatio, currentUsdtPriceAssetRatio, endPeriodBlocksLeft, updatedCurrentPeriod, periodStart, periodEnd)
445449 let priceAssetDecimals = value(assetInfo(fromBase58String(priceAssetId58))).decimals
446450 let entries = if ((claimedAssetId58 == priceAssetId58))
447451 then {
448- let $t02154921993 = internalClaimV2(priceAssetId58, userAddress58, outAmount, totalsDiff[IdxDiffClaimedPriceAmountIncrement])
449- let periodMinAvailableToClaim = $t02154921993._1
450- let periodTotalAvailableToClaim = $t02154921993._2
451- let periodUserAvailableToClaim = $t02154921993._3
452- let totalUserAvailableToClaim = $t02154921993._4
453- let usdtPriceAssetAllowableRatio = $t02154921993._5
454- let currentUsdtPriceAssetRatio = $t02154921993._6
455- let endPeriodBlocksLeft = $t02154921993._7
456- let updatedCurrentPeriod = $t02154921993._8
457- let periodStart = $t02154921993._9
458- let periodEnd = $t02154921993._10
452+ let $t02166122105 = internalClaimV2(priceAssetId58, userAddress58, outAmount, totalsDiff[IdxDiffClaimedPriceAmountIncrement])
453+ let periodMinAvailableToClaim = $t02166122105._1
454+ let periodTotalAvailableToClaim = $t02166122105._2
455+ let periodUserAvailableToClaim = $t02166122105._3
456+ let totalUserAvailableToClaim = $t02166122105._4
457+ let usdtPriceAssetAllowableRatio = $t02166122105._5
458+ let currentUsdtPriceAssetRatio = $t02166122105._6
459+ let endPeriodBlocksLeft = $t02166122105._7
460+ let updatedCurrentPeriod = $t02166122105._8
461+ let periodStart = $t02166122105._9
462+ let periodEnd = $t02166122105._10
459463 let checks = [if ((periodUserAvailableToClaim > 0))
460464 then true
461465 else throwErr("unavailable to claim because user period allowance reached"), if ((periodTotalAvailableToClaim > 0))
521525 let priceAssetBalance = valueOrElse(getInteger(keyPriceAssetBalance(userAddress58)), 0)
522526 let priceAssetBalanceIdoDecimals = (priceAssetBalance * 100)
523527 let availableIdoAmountToClaimWithPriceAssetBalance = (availableIdoAmountToClaim + priceAssetBalanceIdoDecimals)
524- let $t02828628698 = internalClaimV2(priceAssetId58, userAddress58, outAmount, totalsDiff[IdxDiffClaimedPriceAmountIncrement])
525- let periodMinAvailableToClaim = $t02828628698._1
526- let periodTotalAvailableToClaim = $t02828628698._2
527- let periodUserAvailableToClaim = $t02828628698._3
528- let totalUserAvailableToClaim = $t02828628698._4
529- let usdtPriceAssetAllowableRatio = $t02828628698._5
530- let currentUsdtPriceAssetRatio = $t02828628698._6
531- let endPeriodBlocksLeft = $t02828628698._7
532- let updatedCurrentPeriod = $t02828628698._8
533- let periodStart = $t02828628698._9
534- let periodEnd = $t02828628698._10
528+ let $t02839828810 = internalClaimV2(priceAssetId58, userAddress58, outAmount, totalsDiff[IdxDiffClaimedPriceAmountIncrement])
529+ let periodMinAvailableToClaim = $t02839828810._1
530+ let periodTotalAvailableToClaim = $t02839828810._2
531+ let periodUserAvailableToClaim = $t02839828810._3
532+ let totalUserAvailableToClaim = $t02839828810._4
533+ let usdtPriceAssetAllowableRatio = $t02839828810._5
534+ let currentUsdtPriceAssetRatio = $t02839828810._6
535+ let endPeriodBlocksLeft = $t02839828810._7
536+ let updatedCurrentPeriod = $t02839828810._8
537+ let periodStart = $t02839828810._9
538+ let periodEnd = $t02839828810._10
535539 let currentPeriodEndHeight = valueOrElse(getInteger(keyPeriodEndHeight(updatedCurrentPeriod)), 0)
536540 let userTotalPriceAssetClaimed = (parseIntValue(readInvestorArrayOrFail(userAddress58)[IdxInvClaimedPriceAssetAmount]) - priceAssetBalance)
537541 let resultString = if ((height > currentPeriodEndHeight))
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 func getStringOrFail (key) = valueOrErrorMessage(getString(key), (("mandatory this." + key) + " is not defined"))
55
66
77 let SEP = "__"
88
99 let BUFSCALE = toBigInt(1000000000000000000)
1010
1111 let scale8 = 100000000
1212
1313 func throwErr (msg) = throw(makeString(["ido.ride:", msg], " "))
1414
1515
1616 func convertPriceAssetIntoIdoAsset (priceAssetAmount,priceAssetMULT,price,priceMULT,idoAssetMULT) = {
1717 let bPriceAssetMULT = toBigInt(priceAssetMULT)
1818 let bIdoAssetMULT = toBigInt(idoAssetMULT)
1919 let bPriceAssetBUF = fraction(toBigInt(priceAssetAmount), BUFSCALE, bPriceAssetMULT)
2020 let bAmountAssetBUF = fraction(bPriceAssetBUF, toBigInt(priceMULT), toBigInt(price))
2121 toInt(fraction(bAmountAssetBUF, toBigInt(idoAssetMULT), BUFSCALE))
2222 }
2323
2424
2525 let IdxCfgIdoStart = 1
2626
2727 let IdxCfgIdoDuration = 2
2828
2929 let IdxCfgClaimStart = 3
3030
3131 let IdxCfgClaimDuration = 4
3232
3333 let IdxCfgPrice = 5
3434
3535 let IdxCfgPriceMult = 6
3636
3737 let IdxCfgIdoAssetId = 7
3838
3939 let IdxCfgIdoAssetMult = 8
4040
4141 let IdxCfgPriceAssetId = 9
4242
4343 let IdxCfgPriceAssetMult = 10
4444
4545 let IdxCfgMinInvestAmount = 11
4646
4747 func fromatConfigS (idoStart,idoDuration,claimStart,claimDuration,price,priceMult,idoAssetId58,idoAssetMult,priceAssetId58,priceAssetMult,minInvestAmount,totalIdoAssetToSell) = makeString(["%d%d%d%d%d%d%s%d%s%d%d%d", idoStart, idoDuration, claimStart, claimDuration, price, priceMult, idoAssetId58, idoAssetMult, priceAssetId58, priceAssetMult, minInvestAmount, totalIdoAssetToSell], SEP)
4848
4949
5050 func fromatConfig (idoStart,idoDuration,claimStart,claimDuration,price,priceMult,idoAssetId58,idoAssetMult,priceAssetId58,priceAssetMult,minInvestAmount,totalIdoAssetToSell) = fromatConfigS(toString(idoStart), toString(idoDuration), toString(claimStart), toString(claimDuration), toString(price), toString(priceMult), idoAssetId58, toString(idoAssetMult), priceAssetId58, toString(priceAssetMult), toString(minInvestAmount), toString(totalIdoAssetToSell))
5151
5252
5353 let IdxInvTotalAmount = 1
5454
5555 let IdxInvRemainingAmount = 2
5656
5757 let IdxInvClaimedPriceAssetAmount = 3
5858
5959 let IdxInvClaimedIdoAssetAmount = 4
6060
6161 let IdxInvLastClaimedHeight = 5
6262
6363 func formatInvestorS (totalAmount,remainingAmount,claimedPriceAssetAmount,claimedIdoAssetAmount,lastClaimedHeight) = makeString(["%d%d%d%d%d", totalAmount, remainingAmount, claimedPriceAssetAmount, claimedIdoAssetAmount, lastClaimedHeight], SEP)
6464
6565
6666 func formatInvestor (totalAmount,remainingAmount,claimedPriceAssetAmount,claimedIdoAssetAmount,lastClaimedHeight) = formatInvestorS(toString(totalAmount), toString(remainingAmount), toString(claimedPriceAssetAmount), toString(claimedIdoAssetAmount), toString(lastClaimedHeight))
6767
6868
6969 func formatHistoryRecord (priceAssetAmount,idoAssetAmount) = makeString(["%d%d%d%d", toString(height), toString(lastBlock.timestamp), toString(priceAssetAmount), toString(idoAssetAmount)], SEP)
7070
7171
7272 func keyConfig () = "%s__config"
7373
7474
7575 func keyInvestor (userAddress) = ("%s__" + userAddress)
7676
7777
7878 func keyTotals () = "%s__totals"
7979
8080
8181 func keyOperationHistoryRecord (type,userAddress,txId58) = makeString(["%s%s%s%s__history", type, userAddress, txId58], SEP)
8282
8383
8484 func keyUSDNClaimDisabled () = "%s__usdnClaimDisabled"
8585
8686
8787 func keyUSDNClaimEndHeight () = "%s__usdnClaimEndHeight"
8888
8989
9090 func keyPeriodLength () = makeString(["%s", "periodLength"], SEP)
9191
9292
9393 func keyCurrentPeriod () = makeString(["%s", "currentPeriod"], SEP)
9494
9595
9696 func keyPeriodStartHeight (periodNum) = makeString(["%s%s", "periodStartHeight", toString(periodNum)], SEP)
9797
9898
9999 func keyPeriodEndHeight (periodNum) = makeString(["%s%s", "periodEndHeight", toString(periodNum)], SEP)
100100
101101
102102 func keyUsdtPriceAssetAllowableRatio () = makeString(["%s", "usdtPriceAssetAllowableRatio"], SEP)
103103
104104
105105 func keyTotalPeriodAllowance (assetId) = makeString(["%s%s", "totalPeriodAllowance", assetId], SEP)
106106
107107
108108 func keyUserPeriodAllowance (assetId) = makeString(["%s%s", "userPeriodAllowance", assetId], SEP)
109109
110110
111111 func keyPeriodTotalAvailableToClaim (assetId,periodNum) = makeString(["%s%s%s", "periodTotalAvailableToClaim", assetId, toString(periodNum)], SEP)
112112
113113
114114 func keyPeriodUserAvailableToClaim (assetId,periodNum,userAddress) = makeString(["%s%s%s%s", "periodUserAvailableToClaim", assetId, toString(periodNum), userAddress], SEP)
115115
116116
117117 func keyUsdtPriceAssetStablePool () = makeString(["%s", "usdtPriceAssetStablePool"], SEP)
118118
119119
120120 func keyUsdtAssetId () = makeString(["%s", "usdtAssetId"], SEP)
121121
122122
123123 func keyPriceAssetBalance (address) = makeString(["%s%s", "priceAssetBalance", address], SEP)
124124
125125
126126 func keyManagerPublicKey () = "%s__managerPublicKey"
127127
128128
129129 func keyPendingManagerPublicKey () = "%s__pendingManagerPublicKey"
130130
131131
132132 func readConfigArray () = split(getStringOrFail(keyConfig()), SEP)
133133
134134
135135 func readTotalsArrayOrDefaultByCustomKey (customKey) = split(valueOrElse(getString(customKey), formatInvestorS("0", "0", "0", "0", "0")), SEP)
136136
137137
138138 func readTotalsArrayOrDefault () = readTotalsArrayOrDefaultByCustomKey(keyTotals())
139139
140140
141141 func readInvestorArrayOrDefault (userAddress) = readTotalsArrayOrDefaultByCustomKey(keyInvestor(userAddress))
142142
143143
144144 func readInvestorArrayOrFail (userAddress) = split(getStringOrFail(keyInvestor(userAddress)), SEP)
145145
146146
147147 let IdxDiffTotalIncrement = 0
148148
149149 let IdxDiffRemainingPriceAmountIncrement = 1
150150
151151 let IdxDiffClaimedPriceAmountIncrement = 2
152152
153153 let IdxDiffClaimedIdoAssetAmountIncrement = 3
154154
155155 func TotalsEntry (key,origArray,incrementDiff,newLastClaimedHeight,priceAssetBalance) = {
156156 let totalAmount = parseIntValue(origArray[IdxInvTotalAmount])
157157 let remainingAmount = parseIntValue(origArray[IdxInvRemainingAmount])
158158 let claimedPriceAssetAmount = parseIntValue(origArray[IdxInvClaimedPriceAssetAmount])
159159 let claimedIdoAssetAmount = parseIntValue(origArray[IdxInvClaimedIdoAssetAmount])
160160 let lastClaimedHeight = parseIntValue(origArray[IdxInvLastClaimedHeight])
161161 let newTotalAmount = (totalAmount + incrementDiff[IdxDiffTotalIncrement])
162162 let newRemainingAmount = (remainingAmount + incrementDiff[IdxDiffRemainingPriceAmountIncrement])
163163 let cfgArray = readConfigArray()
164164 let priceAssetId58 = cfgArray[IdxCfgPriceAssetId]
165165 let priceAssetDecimals = value(assetInfo(fromBase58String(priceAssetId58))).decimals
166166 let priceAssetBalancePriceAssetDecimals = fraction(priceAssetBalance, scale8, pow(10, 0, priceAssetDecimals, 0, 0, DOWN))
167167 let newClaimedPriceAssetAmount = ((claimedPriceAssetAmount + incrementDiff[IdxDiffClaimedPriceAmountIncrement]) - priceAssetBalance)
168168 let newClaimedIdoAssetAmount = ((claimedIdoAssetAmount + incrementDiff[IdxDiffClaimedIdoAssetAmountIncrement]) + priceAssetBalancePriceAssetDecimals)
169- if ((0 > newRemainingAmount))
170- then throwErr(makeString(["invalid math", toString(remainingAmount), toString(incrementDiff[IdxDiffRemainingPriceAmountIncrement]), toString(newRemainingAmount), toString(incrementDiff[IdxDiffTotalIncrement])], " "))
169+ let entries = if ((0 > newRemainingAmount))
170+ then {
171+ let newLogicRemainingAmount = (newTotalAmount - newClaimedPriceAssetAmount)
172+ StringEntry(key, formatInvestor(newTotalAmount, newLogicRemainingAmount, newClaimedPriceAssetAmount, newClaimedIdoAssetAmount, newLastClaimedHeight))
173+ }
171174 else StringEntry(key, formatInvestor(newTotalAmount, newRemainingAmount, newClaimedPriceAssetAmount, newClaimedIdoAssetAmount, newLastClaimedHeight))
175+ entries
172176 }
173177
174178
175179 func InvestOperationHistoryEntry (userAddress,priceAssetAmount,idoAssetAmount,txId) = StringEntry(keyOperationHistoryRecord("invest", userAddress, toBase58String(txId)), formatHistoryRecord(priceAssetAmount, idoAssetAmount))
176180
177181
178182 func ClaimOperationHistoryEntry (userAddress,priceAssetAmount,idoAssetAmount,txId) = StringEntry(keyOperationHistoryRecord("claim", userAddress, toBase58String(txId)), formatHistoryRecord(priceAssetAmount, idoAssetAmount))
179183
180184
181185 func internalClaim (claimedAssetId58,userAddress,txId) = {
182186 let cfgArray = readConfigArray()
183187 let claimStart = parseIntValue(cfgArray[IdxCfgClaimStart])
184188 let claimDuration = parseIntValue(cfgArray[IdxCfgClaimDuration])
185189 let claimEnd = (claimStart + claimDuration)
186190 let price = parseIntValue(cfgArray[IdxCfgPrice])
187191 let priceMult = parseIntValue(cfgArray[IdxCfgPriceMult])
188192 let idoAssetId58 = cfgArray[IdxCfgIdoAssetId]
189193 let idoAssetId = fromBase58String(idoAssetId58)
190194 let idoAssetMult = parseIntValue(cfgArray[IdxCfgIdoAssetMult])
191195 let priceAssetId58 = cfgArray[IdxCfgPriceAssetId]
192196 let priceAssetId = fromBase58String(priceAssetId58)
193197 let priceAssetMult = parseIntValue(cfgArray[IdxCfgPriceAssetMult])
194198 let userAddress58 = toString(userAddress)
195199 let origInvestArray = readInvestorArrayOrFail(userAddress58)
196200 let investTotalAmount = parseIntValue(origInvestArray[IdxInvTotalAmount])
197201 let investLastClaimedHeightTMP = parseIntValue(origInvestArray[IdxInvLastClaimedHeight])
198202 let investLastClaimedHeight = if ((claimStart >= investLastClaimedHeightTMP))
199203 then claimStart
200204 else investLastClaimedHeightTMP
201205 let newClaimPeriodHeight = if ((height > claimEnd))
202206 then claimEnd
203207 else if ((claimStart > height))
204208 then claimStart
205209 else height
206210 let claimingBlocks = (newClaimPeriodHeight - investLastClaimedHeight)
207211 let claimingPriceAssetAmount = fraction(investTotalAmount, claimingBlocks, claimDuration)
208212 let claimingIdoAssetAmount = convertPriceAssetIntoIdoAsset(claimingPriceAssetAmount, priceAssetMult, price, priceMult, idoAssetMult)
209213 let isUSDN = (claimedAssetId58 == priceAssetId58)
210214 let isUSDNClaimDisabled = valueOrElse(getBoolean(keyUSDNClaimDisabled()), false)
211215 let checks = [if (!(if (isUSDN)
212216 then isUSDNClaimDisabled
213217 else false))
214218 then true
215219 else throw("USDN claim is disabled")]
216220 if ((checks == checks))
217221 then if ((claimedAssetId58 == priceAssetId58))
218222 then $Tuple6([0, -(claimingPriceAssetAmount), claimingPriceAssetAmount, 0], claimingPriceAssetAmount, priceAssetId, origInvestArray, newClaimPeriodHeight, [claimingPriceAssetAmount, claimingIdoAssetAmount])
219223 else if ((claimedAssetId58 == idoAssetId58))
220224 then $Tuple6([0, -(claimingPriceAssetAmount), 0, claimingIdoAssetAmount], claimingIdoAssetAmount, idoAssetId, origInvestArray, newClaimPeriodHeight, [claimingPriceAssetAmount, claimingIdoAssetAmount])
221225 else throw(("unsupported assetId: " + claimedAssetId58))
222226 else throw("Strict value is not equal to itself.")
223227 }
224228
225229
226230 func internalClaimV2 (priceAssetId58,userAddress58,outAmount,totalUserAvailableToClaim) = {
227231 let totalPeriodPriceAssetAllowance = value(getInteger(keyTotalPeriodAllowance(priceAssetId58)))
228232 let userPeriodPriceAssetAllowance = value(getInteger(keyUserPeriodAllowance(priceAssetId58)))
229233 let periodLength = value(getInteger(keyPeriodLength()))
230234 let currentPeriod = valueOrElse(getInteger(keyCurrentPeriod()), 0)
231235 let zeroPeriodEndHeighIsDefined = isDefined(getInteger(keyPeriodEndHeight(0)))
232- let $t01248214352 = if ((currentPeriod > 0))
236+ let $t01259414464 = if ((currentPeriod > 0))
233237 then {
234238 let lastPeriodStartHeight = value(getInteger(keyPeriodStartHeight(currentPeriod)))
235239 let lastPeriodEndHeight = value(getInteger(keyPeriodEndHeight(currentPeriod)))
236- let $t01274213447 = if ((height > lastPeriodEndHeight))
240+ let $t01285413559 = if ((height > lastPeriodEndHeight))
237241 then {
238242 let updatedCurrentPeriod = (currentPeriod + 1)
239243 let periodStart = if ((height > (lastPeriodEndHeight + periodLength)))
240244 then {
241245 let blocksToLastPeriodStart = ((height - lastPeriodEndHeight) % periodLength)
242246 if ((blocksToLastPeriodStart == 0))
243247 then ((height - periodLength) + 1)
244248 else (height - blocksToLastPeriodStart)
245249 }
246250 else (lastPeriodEndHeight + 1)
247251 let periodEnd = ((periodStart + periodLength) - 1)
248252 $Tuple3(updatedCurrentPeriod, periodStart, periodEnd)
249253 }
250254 else $Tuple3(currentPeriod, lastPeriodStartHeight, lastPeriodEndHeight)
251- let updatedCurrentPeriod = $t01274213447._1
252- let periodStart = $t01274213447._2
253- let periodEnd = $t01274213447._3
255+ let updatedCurrentPeriod = $t01285413559._1
256+ let periodStart = $t01285413559._2
257+ let periodEnd = $t01285413559._3
254258 $Tuple3(updatedCurrentPeriod, periodStart, periodEnd)
255259 }
256260 else if (zeroPeriodEndHeighIsDefined)
257261 then {
258262 let zeroPeriodStartHeight = value(getInteger(keyPeriodStartHeight(0)))
259263 let zeroPeriodEndHeight = value(getInteger(keyPeriodEndHeight(0)))
260- let $t01370214084 = if ((height > zeroPeriodEndHeight))
264+ let $t01381414196 = if ((height > zeroPeriodEndHeight))
261265 then {
262266 let updatedCurrentPeriod = (currentPeriod + 1)
263267 let periodStart = (zeroPeriodEndHeight + 1)
264268 let periodEnd = ((periodStart + periodLength) - 1)
265269 $Tuple3(updatedCurrentPeriod, periodStart, periodEnd)
266270 }
267271 else $Tuple3(currentPeriod, zeroPeriodStartHeight, zeroPeriodEndHeight)
268- let updatedCurrentPeriod = $t01370214084._1
269- let periodStart = $t01370214084._2
270- let periodEnd = $t01370214084._3
272+ let updatedCurrentPeriod = $t01381414196._1
273+ let periodStart = $t01381414196._2
274+ let periodEnd = $t01381414196._3
271275 $Tuple3(updatedCurrentPeriod, periodStart, periodEnd)
272276 }
273277 else $Tuple3(currentPeriod, valueOrElse(getInteger(keyPeriodStartHeight(currentPeriod)), height), valueOrElse(getInteger(keyPeriodEndHeight(currentPeriod)), ((height + periodLength) - 1)))
274- let updatedCurrentPeriod = $t01248214352._1
275- let periodStart = $t01248214352._2
276- let periodEnd = $t01248214352._3
278+ let updatedCurrentPeriod = $t01259414464._1
279+ let periodStart = $t01259414464._2
280+ let periodEnd = $t01259414464._3
277281 let periodTotalAvailableToClaim = valueOrElse(getInteger(keyPeriodTotalAvailableToClaim(priceAssetId58, updatedCurrentPeriod)), totalPeriodPriceAssetAllowance)
278282 let periodUserAvailableToClaim = valueOrElse(getInteger(keyPeriodUserAvailableToClaim(priceAssetId58, updatedCurrentPeriod, userAddress58)), userPeriodPriceAssetAllowance)
279283 let priceAssetBalance = valueOrElse(getInteger(keyPriceAssetBalance(userAddress58)), 0)
280284 let periodMinAvailableToClaim = min([(outAmount + priceAssetBalance), periodTotalAvailableToClaim, periodUserAvailableToClaim])
281285 let usdtPriceAssetAllowableRatio = value(getInteger(keyUsdtPriceAssetAllowableRatio()))
282286 let putOneTknV2PriceAssetAmount = scale8
283- let $t01510715360 = {
287+ let $t01521915472 = {
284288 let @ = invoke(addressFromStringValue(value(getString(keyUsdtPriceAssetStablePool()))), "putOneTknV2WithoutTakeFeeREADONLY", [putOneTknV2PriceAssetAmount, priceAssetId58], nil)
285289 if ($isInstanceOf(@, "(Int, Int, Int)"))
286290 then @
287291 else throw("Couldn't cast Any to (Int, Int, Int)")
288292 }
289- if (($t01510715360 == $t01510715360))
293+ if (($t01521915472 == $t01521915472))
290294 then {
291- let bonus = $t01510715360._3
292- let feeAmount = $t01510715360._2
293- let lpAmount = $t01510715360._1
295+ let bonus = $t01521915472._3
296+ let feeAmount = $t01521915472._2
297+ let lpAmount = $t01521915472._1
294298 let usdtAssetId = value(getString(keyUsdtAssetId()))
295- let $t01542215640 = {
299+ let $t01553415752 = {
296300 let @ = invoke(addressFromStringValue(value(getString(keyUsdtPriceAssetStablePool()))), "getOneTknV2READONLY", [usdtAssetId, lpAmount], nil)
297301 if ($isInstanceOf(@, "(Int, Int)"))
298302 then @
299303 else throw("Couldn't cast Any to (Int, Int)")
300304 }
301- if (($t01542215640 == $t01542215640))
305+ if (($t01553415752 == $t01553415752))
302306 then {
303- let getOneTknV2FeeAmount = $t01542215640._2
304- let usdtAmount = $t01542215640._1
307+ let getOneTknV2FeeAmount = $t01553415752._2
308+ let usdtAmount = $t01553415752._1
305309 let currentUsdtPriceAssetRatio = fraction(putOneTknV2PriceAssetAmount, scale8, usdtAmount)
306310 let endPeriodBlocksLeft = (periodEnd - height)
307311 $Tuple10(periodMinAvailableToClaim, periodTotalAvailableToClaim, periodUserAvailableToClaim, totalUserAvailableToClaim, usdtPriceAssetAllowableRatio, currentUsdtPriceAssetRatio, endPeriodBlocksLeft, updatedCurrentPeriod, periodStart, periodEnd)
308312 }
309313 else throw("Strict value is not equal to itself.")
310314 }
311315 else throw("Strict value is not equal to itself.")
312316 }
313317
314318
315319 func managerPublicKeyOrUnit () = match getString(keyManagerPublicKey()) {
316320 case s: String =>
317321 fromBase58String(s)
318322 case _: Unit =>
319323 unit
320324 case _ =>
321325 throw("Match error")
322326 }
323327
324328
325329 func pendingManagerPublicKeyOrUnit () = match getString(keyPendingManagerPublicKey()) {
326330 case s: String =>
327331 fromBase58String(s)
328332 case _: Unit =>
329333 unit
330334 case _ =>
331335 throw("Match error")
332336 }
333337
334338
335339 func mustManager (i) = {
336340 let pd = throw("Permission denied")
337341 match managerPublicKeyOrUnit() {
338342 case pk: ByteVector =>
339343 if ((i.callerPublicKey == pk))
340344 then true
341345 else pd
342346 case _: Unit =>
343347 if ((i.caller == this))
344348 then true
345349 else pd
346350 case _ =>
347351 throw("Match error")
348352 }
349353 }
350354
351355
352356 @Callable(i)
353357 func constructor (idoStart,idoDuration,claimStart,claimDuration,price,priceAssetId58,minInvestAmount) = {
354358 let priceMult = ((100 * 1000) * 1000)
355359 let idoEnd = (idoStart + idoDuration)
356360 if (isDefined(getString(keyConfig())))
357361 then throw("already initialized")
358362 else if (("3PMEHLx1j6zerarZTYfsGqDeeZqQoMpxq5S" != toString(i.caller)))
359363 then throw("not authorized")
360364 else if ((size(i.payments) != 1))
361365 then throw("exactly 1 payment must be attached")
362366 else if ((idoEnd >= claimStart))
363367 then throw("claimStart must be greater than idoEnd")
364368 else {
365369 let pmt = value(i.payments[0])
366370 let idoAssetId = value(pmt.assetId)
367371 let idoAssetInfo = valueOrErrorMessage(assetInfo(idoAssetId), "fail to load ido asset info")
368372 let idoAssetId58 = toBase58String(idoAssetId)
369373 let idoAssetMult = pow(10, 0, idoAssetInfo.decimals, 0, 0, DOWN)
370374 let priceAssetId = fromBase58String(priceAssetId58)
371375 let priceAssetInfo = valueOrErrorMessage(assetInfo(priceAssetId), "fail to load price asset info")
372376 let priceAssetMult = pow(10, 0, priceAssetInfo.decimals, 0, 0, DOWN)
373377 let origTotalsArray = readTotalsArrayOrDefault()
374378 let totalsDiff = [0, 0, 0, 0]
375379 [StringEntry(keyConfig(), fromatConfig(idoStart, idoDuration, claimStart, claimDuration, price, priceMult, idoAssetId58, idoAssetMult, priceAssetId58, priceAssetMult, minInvestAmount, pmt.amount)), TotalsEntry(keyTotals(), origTotalsArray, totalsDiff, claimStart, 0)]
376380 }
377381 }
378382
379383
380384
381385 @Callable(i)
382386 func invest () = {
383387 let cfgArray = readConfigArray()
384388 let idoStart = parseIntValue(cfgArray[IdxCfgIdoStart])
385389 let idoDuration = parseIntValue(cfgArray[IdxCfgIdoDuration])
386390 let idoEnd = (idoStart + idoDuration)
387391 let claimStart = parseIntValue(cfgArray[IdxCfgClaimStart])
388392 let claimDuration = parseIntValue(cfgArray[IdxCfgClaimDuration])
389393 let price = parseIntValue(cfgArray[IdxCfgPrice])
390394 let priceMult = parseIntValue(cfgArray[IdxCfgPriceMult])
391395 let idoAssetId58 = cfgArray[IdxCfgIdoAssetId]
392396 let idoAssetId = fromBase58String(idoAssetId58)
393397 let idoAssetMult = parseIntValue(cfgArray[IdxCfgIdoAssetMult])
394398 let priceAssetId58 = cfgArray[IdxCfgPriceAssetId]
395399 let priceAssetId = fromBase58String(priceAssetId58)
396400 let priceAssetMult = parseIntValue(cfgArray[IdxCfgPriceAssetMult])
397401 let minIvestAmount = parseIntValue(cfgArray[IdxCfgMinInvestAmount])
398402 let userAddress = toString(i.caller)
399403 if ((idoStart > height))
400404 then throw("ido has not been started yet")
401405 else if ((height > idoEnd))
402406 then throw("ido has been already ended")
403407 else if ((size(i.payments) != 1))
404408 then throw("exactly 1 payment is expected")
405409 else {
406410 let pmt = value(i.payments[0])
407411 let pmtAssetId = value(pmt.assetId)
408412 let pmtAmount = pmt.amount
409413 if ((pmtAssetId != priceAssetId))
410414 then throw((("invalid payment asset id: " + toBase58String(pmtAssetId)) + " is expected"))
411415 else {
412416 let origInvestorArray = readInvestorArrayOrDefault(userAddress)
413417 let origTotalsArray = readTotalsArrayOrDefault()
414418 let newPriceTotalAmount = (parseIntValue(origTotalsArray[IdxInvTotalAmount]) + pmtAmount)
415419 let requiredIdoAssetAmount = (newPriceTotalAmount * 100)
416420 if ((requiredIdoAssetAmount > assetBalance(this, idoAssetId)))
417421 then throw("IDO asset has been - sold consider to use smaller payment")
418422 else {
419423 let totalsDiff = [pmtAmount, pmtAmount, 0, 0]
420424 [TotalsEntry(keyInvestor(userAddress), origInvestorArray, totalsDiff, claimStart, 0), TotalsEntry(keyTotals(), origTotalsArray, totalsDiff, claimStart, 0), InvestOperationHistoryEntry(userAddress, pmtAmount, 0, i.transactionId)]
421425 }
422426 }
423427 }
424428 }
425429
426430
427431
428432 @Callable(i)
429433 func claim (claimedAssetId58,userAddress58) = {
430434 let callerAddress58 = toString(i.caller)
431435 if ((userAddress58 != callerAddress58))
432436 then throw("not authorized")
433437 else {
434438 let cfgArray = readConfigArray()
435439 let priceAssetId58 = cfgArray[IdxCfgPriceAssetId]
436440 let claimResultTuple = internalClaim(claimedAssetId58, i.caller, i.transactionId)
437441 let totalsDiff = claimResultTuple._1
438442 let outAmount = claimResultTuple._2
439443 let outAssetId = claimResultTuple._3
440444 let origInvestArray = claimResultTuple._4
441445 let newClaimPeriodHeight = claimResultTuple._5
442446 let claimedPriceAmountFromDiff = totalsDiff[IdxDiffClaimedPriceAmountIncrement]
443447 let claimedIdoAssetAmountFromDiff = totalsDiff[IdxDiffClaimedIdoAssetAmountIncrement]
444448 let priceAssetBalance = valueOrElse(getInteger(keyPriceAssetBalance(userAddress58)), 0)
445449 let priceAssetDecimals = value(assetInfo(fromBase58String(priceAssetId58))).decimals
446450 let entries = if ((claimedAssetId58 == priceAssetId58))
447451 then {
448- let $t02154921993 = internalClaimV2(priceAssetId58, userAddress58, outAmount, totalsDiff[IdxDiffClaimedPriceAmountIncrement])
449- let periodMinAvailableToClaim = $t02154921993._1
450- let periodTotalAvailableToClaim = $t02154921993._2
451- let periodUserAvailableToClaim = $t02154921993._3
452- let totalUserAvailableToClaim = $t02154921993._4
453- let usdtPriceAssetAllowableRatio = $t02154921993._5
454- let currentUsdtPriceAssetRatio = $t02154921993._6
455- let endPeriodBlocksLeft = $t02154921993._7
456- let updatedCurrentPeriod = $t02154921993._8
457- let periodStart = $t02154921993._9
458- let periodEnd = $t02154921993._10
452+ let $t02166122105 = internalClaimV2(priceAssetId58, userAddress58, outAmount, totalsDiff[IdxDiffClaimedPriceAmountIncrement])
453+ let periodMinAvailableToClaim = $t02166122105._1
454+ let periodTotalAvailableToClaim = $t02166122105._2
455+ let periodUserAvailableToClaim = $t02166122105._3
456+ let totalUserAvailableToClaim = $t02166122105._4
457+ let usdtPriceAssetAllowableRatio = $t02166122105._5
458+ let currentUsdtPriceAssetRatio = $t02166122105._6
459+ let endPeriodBlocksLeft = $t02166122105._7
460+ let updatedCurrentPeriod = $t02166122105._8
461+ let periodStart = $t02166122105._9
462+ let periodEnd = $t02166122105._10
459463 let checks = [if ((periodUserAvailableToClaim > 0))
460464 then true
461465 else throwErr("unavailable to claim because user period allowance reached"), if ((periodTotalAvailableToClaim > 0))
462466 then true
463467 else throwErr("unavailable to claim because total period allowance reached"), if ((periodMinAvailableToClaim > 0))
464468 then true
465469 else throwErr("nothing to claim"), if ((usdtPriceAssetAllowableRatio > currentUsdtPriceAssetRatio))
466470 then true
467471 else throwErr("unavailable to claim because usdn price lower than usdtPriceAssetAllowableRatio")]
468472 if ((checks == checks))
469473 then {
470474 let updatedPeriodTotalAvailableToClaim = (periodTotalAvailableToClaim - periodMinAvailableToClaim)
471475 let updatedPeriodUserAvailableToClaim = (periodUserAvailableToClaim - periodMinAvailableToClaim)
472476 let entries = if ((priceAssetBalance >= periodMinAvailableToClaim))
473477 then [ScriptTransfer(i.caller, periodMinAvailableToClaim, outAssetId), IntegerEntry(keyPriceAssetBalance(userAddress58), (priceAssetBalance - periodMinAvailableToClaim))]
474478 else {
475479 let updatedPriceAssetBalance = ((priceAssetBalance + outAmount) - periodMinAvailableToClaim)
476480 [ScriptTransfer(i.caller, periodMinAvailableToClaim, outAssetId), TotalsEntry(keyInvestor(userAddress58), origInvestArray, totalsDiff, newClaimPeriodHeight, 0), TotalsEntry(keyTotals(), readTotalsArrayOrDefault(), totalsDiff, newClaimPeriodHeight, 0), IntegerEntry(keyPriceAssetBalance(userAddress58), updatedPriceAssetBalance)]
477481 }
478482 $Tuple2(([IntegerEntry(keyCurrentPeriod(), updatedCurrentPeriod), IntegerEntry(keyPeriodStartHeight(updatedCurrentPeriod), periodStart), IntegerEntry(keyPeriodEndHeight(updatedCurrentPeriod), periodEnd), IntegerEntry(keyPeriodTotalAvailableToClaim(priceAssetId58, updatedCurrentPeriod), updatedPeriodTotalAvailableToClaim), IntegerEntry(keyPeriodUserAvailableToClaim(priceAssetId58, updatedCurrentPeriod, userAddress58), updatedPeriodUserAvailableToClaim), ClaimOperationHistoryEntry(userAddress58, periodMinAvailableToClaim, claimedIdoAssetAmountFromDiff, i.transactionId)] ++ entries), unit)
479483 }
480484 else throw("Strict value is not equal to itself.")
481485 }
482486 else {
483487 let priceAssetBalanceIdoDecimals = fraction(priceAssetBalance, scale8, pow(10, 0, priceAssetDecimals, 0, 0, DOWN))
484488 $Tuple2([ScriptTransfer(i.caller, (outAmount + priceAssetBalanceIdoDecimals), outAssetId), IntegerEntry(keyPriceAssetBalance(userAddress58), 0), TotalsEntry(keyInvestor(userAddress58), origInvestArray, totalsDiff, newClaimPeriodHeight, priceAssetBalance), TotalsEntry(keyTotals(), readTotalsArrayOrDefault(), totalsDiff, newClaimPeriodHeight, priceAssetBalance), ClaimOperationHistoryEntry(userAddress58, claimedPriceAmountFromDiff, (claimedIdoAssetAmountFromDiff + priceAssetBalanceIdoDecimals), i.transactionId)], unit)
485489 }
486490 entries
487491 }
488492 }
489493
490494
491495
492496 @Callable(i)
493497 func claimREADONLY (claimedAssetId58,userAddress58) = {
494498 let claimResultTuple = internalClaim(claimedAssetId58, addressFromStringValue(userAddress58), fromBase58String(""))
495499 let totalsDiff = claimResultTuple._1
496500 let outAmount = claimResultTuple._2
497501 let outAssetId = claimResultTuple._3
498502 let origInvestArray = claimResultTuple._4
499503 let newClaimPeriodHeight = claimResultTuple._5
500504 let availableToClaimArray = claimResultTuple._6
501505 let availablePriceAmountToClaim = availableToClaimArray[0]
502506 let availableIdoAmountToClaim = availableToClaimArray[1]
503507 $Tuple2(nil, makeString(["%s%d%d", userAddress58, toString(availablePriceAmountToClaim), toString(availableIdoAmountToClaim)], SEP))
504508 }
505509
506510
507511
508512 @Callable(i)
509513 func claimV2READONLY (claimedAssetId58,userAddress58) = {
510514 let claimResultTuple = internalClaim(claimedAssetId58, addressFromStringValue(userAddress58), fromBase58String(""))
511515 let totalsDiff = claimResultTuple._1
512516 let outAmount = claimResultTuple._2
513517 let outAssetId = claimResultTuple._3
514518 let origInvestArray = claimResultTuple._4
515519 let newClaimPeriodHeight = claimResultTuple._5
516520 let availableToClaimArray = claimResultTuple._6
517521 let availablePriceAmountToClaim = availableToClaimArray[0]
518522 let availableIdoAmountToClaim = availableToClaimArray[1]
519523 let cfgArray = readConfigArray()
520524 let priceAssetId58 = cfgArray[IdxCfgPriceAssetId]
521525 let priceAssetBalance = valueOrElse(getInteger(keyPriceAssetBalance(userAddress58)), 0)
522526 let priceAssetBalanceIdoDecimals = (priceAssetBalance * 100)
523527 let availableIdoAmountToClaimWithPriceAssetBalance = (availableIdoAmountToClaim + priceAssetBalanceIdoDecimals)
524- let $t02828628698 = internalClaimV2(priceAssetId58, userAddress58, outAmount, totalsDiff[IdxDiffClaimedPriceAmountIncrement])
525- let periodMinAvailableToClaim = $t02828628698._1
526- let periodTotalAvailableToClaim = $t02828628698._2
527- let periodUserAvailableToClaim = $t02828628698._3
528- let totalUserAvailableToClaim = $t02828628698._4
529- let usdtPriceAssetAllowableRatio = $t02828628698._5
530- let currentUsdtPriceAssetRatio = $t02828628698._6
531- let endPeriodBlocksLeft = $t02828628698._7
532- let updatedCurrentPeriod = $t02828628698._8
533- let periodStart = $t02828628698._9
534- let periodEnd = $t02828628698._10
528+ let $t02839828810 = internalClaimV2(priceAssetId58, userAddress58, outAmount, totalsDiff[IdxDiffClaimedPriceAmountIncrement])
529+ let periodMinAvailableToClaim = $t02839828810._1
530+ let periodTotalAvailableToClaim = $t02839828810._2
531+ let periodUserAvailableToClaim = $t02839828810._3
532+ let totalUserAvailableToClaim = $t02839828810._4
533+ let usdtPriceAssetAllowableRatio = $t02839828810._5
534+ let currentUsdtPriceAssetRatio = $t02839828810._6
535+ let endPeriodBlocksLeft = $t02839828810._7
536+ let updatedCurrentPeriod = $t02839828810._8
537+ let periodStart = $t02839828810._9
538+ let periodEnd = $t02839828810._10
535539 let currentPeriodEndHeight = valueOrElse(getInteger(keyPeriodEndHeight(updatedCurrentPeriod)), 0)
536540 let userTotalPriceAssetClaimed = (parseIntValue(readInvestorArrayOrFail(userAddress58)[IdxInvClaimedPriceAssetAmount]) - priceAssetBalance)
537541 let resultString = if ((height > currentPeriodEndHeight))
538542 then {
539543 let periodLenght = value(getInteger(keyPeriodLength()))
540544 let userPeriodAllowance = value(getInteger(keyUserPeriodAllowance(priceAssetId58)))
541545 let totalPeriodAllowance = value(getInteger(keyTotalPeriodAllowance(priceAssetId58)))
542546 makeString(["%d%d%d%d%d%d", toString(availableIdoAmountToClaimWithPriceAssetBalance), toString(userPeriodAllowance), toString(totalPeriodAllowance), toString(usdtPriceAssetAllowableRatio), toString(currentUsdtPriceAssetRatio), toString(periodLenght), toString(userTotalPriceAssetClaimed)], SEP)
543547 }
544548 else makeString(["%d%d%d%d%d%d", toString(availableIdoAmountToClaimWithPriceAssetBalance), toString(periodMinAvailableToClaim), toString(periodTotalAvailableToClaim), toString(usdtPriceAssetAllowableRatio), toString(currentUsdtPriceAssetRatio), toString(endPeriodBlocksLeft), toString(userTotalPriceAssetClaimed)], SEP)
545549 $Tuple2(nil, resultString)
546550 }
547551
548552
549553
550554 @Callable(i)
551555 func setManager (pendingManagerPublicKey) = {
552556 let checkCaller = mustManager(i)
553557 if ((checkCaller == checkCaller))
554558 then {
555559 let checkManagerPublicKey = fromBase58String(pendingManagerPublicKey)
556560 if ((checkManagerPublicKey == checkManagerPublicKey))
557561 then [StringEntry(keyPendingManagerPublicKey(), pendingManagerPublicKey)]
558562 else throw("Strict value is not equal to itself.")
559563 }
560564 else throw("Strict value is not equal to itself.")
561565 }
562566
563567
564568
565569 @Callable(i)
566570 func confirmManager () = {
567571 let pm = pendingManagerPublicKeyOrUnit()
568572 let hasPM = if (isDefined(pm))
569573 then true
570574 else throw("No pending manager")
571575 if ((hasPM == hasPM))
572576 then {
573577 let checkPM = if ((i.callerPublicKey == value(pm)))
574578 then true
575579 else throw("You are not pending manager")
576580 if ((checkPM == checkPM))
577581 then [StringEntry(keyManagerPublicKey(), toBase58String(value(pm))), DeleteEntry(keyPendingManagerPublicKey())]
578582 else throw("Strict value is not equal to itself.")
579583 }
580584 else throw("Strict value is not equal to itself.")
581585 }
582586
583587
584588 @Verifier(tx)
585589 func verify () = {
586590 let targetPublicKey = match managerPublicKeyOrUnit() {
587591 case pk: ByteVector =>
588592 pk
589593 case _: Unit =>
590594 tx.senderPublicKey
591595 case _ =>
592596 throw("Match error")
593597 }
594598 sigVerify(tx.bodyBytes, tx.proofs[0], targetPublicKey)
595599 }
596600

github/deemru/w8io/026f985 
98.53 ms