tx · GG7U6RU6imnkPjoM189Aw2SLTGFWupFoyuXhvc19ZGVQ

3N5yarEiTQccnnuerogYT3BxM5Zc5bRgDZy:  -0.04000000 Waves

2022.08.01 05:54 [2164864] smart account 3N5yarEiTQccnnuerogYT3BxM5Zc5bRgDZy > SELF 0.00000000 Waves

{ "type": 13, "id": "GG7U6RU6imnkPjoM189Aw2SLTGFWupFoyuXhvc19ZGVQ", "fee": 4000000, "feeAssetId": null, "timestamp": 1659322512387, "version": 1, "sender": "3N5yarEiTQccnnuerogYT3BxM5Zc5bRgDZy", "senderPublicKey": "FK9j3YFWVChXKESTn33fMZz1JseCNMMqHhfB7smxJo4e", "proofs": [ "5fQY2fFpmUxed3u991mzGKLdgKdMWPJkuCUqT25AZftEyevC1HEtY9dsRGh8Dwd8wE5M1NzY2TjNvFgVtfvmXJGq" ], "script": "base64:BgIiCAISBQoDAQgIEgASABIDCgEBEgASABIDCgEIEgMKAQgSAEkACXNlcGFyYXRvcgICX18AA1NFUAICX18ABU1VTFQ2AMCEPQAFTVVMVDgAgMLXLwAGTVVMVFg2CQC2AgEFBU1VTFQ2AAZNVUxUWDgJALYCAQUFTVVMVDgAB01VTFRYMTgJALYCAQCAgJC7utat8A0ACldBVkVTSURTVFICBVdBVkVTAAdXQVZFU0lECQDZBAEFCldBVkVTSURTVFIAGUlkeENvbnRyb2xDZmdOZXV0cmlub0RhcHAAAQAYSWR4Q29udHJvbENmZ0F1Y3Rpb25EYXBwAAIAFElkeENvbnRyb2xDZmdScGREYXBwAAMAFUlkeENvbnRyb2xDZmdNYXRoRGFwcAAEABxJZHhDb250cm9sQ2ZnTGlxdWlkYXRpb25EYXBwAAUAFUlkeENvbnRyb2xDZmdSZXN0RGFwcAAGAB1JZHhDb250cm9sQ2ZnTm9kZVJlZ2lzdHJ5RGFwcAAHABxJZHhDb250cm9sQ2ZnTnNidFN0YWtpbmdEYXBwAAgAGUlkeENvbnRyb2xDZmdNZWRpYXRvckRhcHAACQAcSWR4Q29udHJvb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0kJAJQKAgUDbmlsCQDMCAIFCm1pbkxvY2tBbXQJAMwIAgUSZ25zYnRGcm9tU3VyZkNvZWZmCQDMCAIFIHN1cmZWb3RpbmdQb3dlclJlc3RyaWN0aXZlUGVyaW9kCQDMCAIFG2JyVG9TdGFydFN1cmZUcmFuc2Zvcm1hdGlvbgUDbmlsAPTtzSA=", "chainId": 84, "height": 2164864, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: HbEZi9QHRCcY3dFJLQYyZ1jyA1xbFjnLkgFuo7rZsgn5 Next: 5QhYwBHtJGPxSwDsWDEUxY7GsRg4Uhbqu794nCFRqNUA Diff:
OldNewDifferences
596596 }
597597
598598
599+
600+@Callable(i)
601+func configSYSREADONLY () = {
602+ let minLockAmt = getIntegerValue(keyMinLockAmount())
603+ let gnsbtFromSurfCoeff = (60 * MULT6)
604+ let surfVotingPowerRestrictivePeriod = (1440 * 14)
605+ let brToStartSurfTransformation = 1200000
606+ $Tuple2(nil, [minLockAmt, gnsbtFromSurfCoeff, surfVotingPowerRestrictivePeriod, brToStartSurfTransformation])
607+ }
608+
609+
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 6 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let separator = "__"
55
66 let SEP = "__"
77
88 let MULT6 = 1000000
99
1010 let MULT8 = 100000000
1111
1212 let MULTX6 = toBigInt(MULT6)
1313
1414 let MULTX8 = toBigInt(MULT8)
1515
1616 let MULTX18 = toBigInt(1000000000000000000)
1717
1818 let WAVESIDSTR = "WAVES"
1919
2020 let WAVESID = fromBase58String(WAVESIDSTR)
2121
2222 let IdxControlCfgNeutrinoDapp = 1
2323
2424 let IdxControlCfgAuctionDapp = 2
2525
2626 let IdxControlCfgRpdDapp = 3
2727
2828 let IdxControlCfgMathDapp = 4
2929
3030 let IdxControlCfgLiquidationDapp = 5
3131
3232 let IdxControlCfgRestDapp = 6
3333
3434 let IdxControlCfgNodeRegistryDapp = 7
3535
3636 let IdxControlCfgNsbtStakingDapp = 8
3737
3838 let IdxControlCfgMediatorDapp = 9
3939
4040 let IdxControlCfgSurfStakingDapp = 10
4141
4242 let IdxControlCfgGnsbtControllerDapp = 11
4343
4444 func getStringOrFail (address,key) = valueOrErrorMessage(getString(address, key), (((("mandatory " + toString(address)) + ".") + key) + " is not defined"))
4545
4646
4747 func keyControlAddress () = "%s%s__config__controlAddress"
4848
4949
5050 func keyControlCfg () = "%s__controlConfig"
5151
5252
5353 func readControlCfgOrFail (control) = split(getStringOrFail(control, keyControlCfg()), SEP)
5454
5555
5656 func getContractAddressOrFail (controlCfg,idx) = valueOrErrorMessage(addressFromString(controlCfg[idx]), ("Control cfg doesn't contain address at index " + toString(idx)))
5757
5858
5959 let controlContract = addressFromStringValue(valueOrElse(getString(this, keyControlAddress()), "3N4NS7d4Jo9a6F14LiFUKKYVdUkkf2eP4Zx"))
6060
6161 let controlCfg = readControlCfgOrFail(controlContract)
6262
6363 let mathContract = getContractAddressOrFail(controlCfg, IdxControlCfgMathDapp)
6464
6565 let neutrinoContract = getContractAddressOrFail(controlCfg, IdxControlCfgNeutrinoDapp)
6666
6767 let auctionContract = getContractAddressOrFail(controlCfg, IdxControlCfgAuctionDapp)
6868
6969 func keyBondAsset () = "bond_asset_id"
7070
7171
7272 func keyAuctionContractAddress () = "auction_contract"
7373
7474
7575 func keyMinLockAmount () = "%s__minLockAmount"
7676
7777
7878 func keyStakedAssetId () = "%s__stakedAssetId"
7979
8080
8181 func keyLockParamUserAmount (userAddress) = makeString(["%s%s%s", "paramByUser", toString(userAddress), "amount"], separator)
8282
8383
8484 func keyLockParamStartBlock (userAddress) = makeString(["%s%s%s", "paramByUser", toString(userAddress), "start"], separator)
8585
8686
8787 func keyHistoryRecord (type,userAddress,txId) = makeString(["%s%s%s%s", "history", type, toString(userAddress), toBase58String(txId)], separator)
8888
8989
9090 func keyLockParamTotalAmount () = makeString(["%s%s", "stats", "activeTotalLocked"], separator)
9191
9292
9393 func keyStatsLocksCount () = makeString(["%s%s", "stats", "locksCount"], separator)
9494
9595
9696 func keyStatsUsersCount () = makeString(["%s%s", "stats", "activeUsersCount"], separator)
9797
9898
9999 func keyNextPeriod () = "%s__nextPeriod"
100100
101101
102102 func keySupportedRewardAssets () = "supportedRewardAssets"
103103
104104
105105 func keyDepositNumLast () = makeString(["%s%s%s", "dep", "lastNum"], separator)
106106
107107
108108 func keyUserRewardFromDepositNum (userAddress) = makeString(["%s%s%s", "userRwdFromDepNum", userAddress], separator)
109109
110110
111111 func keyRewardPerNsbtSumAt (depositNum,tkn) = makeString(["%s%d", "rwdPerNsbtSumByDepNum", toString(depositNum), tkn], separator)
112112
113113
114114 func keyReward (userAddress,tkn) = makeString(["%s%s%s", "rwd", userAddress, tkn], separator)
115115
116116
117117 func keyClaimed (userAddress,tkn) = makeString(["%s%s%s", "clm", userAddress, tkn], separator)
118118
119119
120120 func keyNotDistributedReward (tkn) = makeString(["%s%s", "notDistributed", tkn], separator)
121121
122122
123123 func toX18 (origVal,origMult) = fraction(toBigInt(origVal), MULTX18, origMult)
124124
125125
126126 func getIntOrZero (key) = valueOrElse(getInteger(this, key), 0)
127127
128128
129129 func getIntOrElse (key,defaultVal) = valueOrElse(getInteger(this, key), defaultVal)
130130
131131
132132 func getIntOrFail (key) = valueOrErrorMessage(getInteger(this, key), (("Mandatory this." + key) + " is not defined"))
133133
134134
135135 func getStrOrElse (key,defaultVal) = valueOrElse(getString(this, key), defaultVal)
136136
137137
138138 func toAddressOrFail (addressStr) = valueOrErrorMessage(addressFromString(addressStr), ("couldn't parse passed addressStr=" + addressStr))
139139
140140
141141 func toAssetVect (assetStr) = if ((assetStr == WAVESIDSTR))
142142 then unit
143143 else fromBase58String(assetStr)
144144
145145
146146 func asInt (val) = match val {
147147 case valInt: Int =>
148148 valInt
149149 case _ =>
150150 throw("fail to cast into Int")
151151 }
152152
153153
154154 func formatHistoryRecord (oldAmount,oldStart,newAmount,newStart) = makeString(["%d%d%d%d%d%d", toString(lastBlock.height), toString(lastBlock.timestamp), toString(oldAmount), toString(oldStart), toString(newAmount), toString(newStart)], separator)
155155
156156
157157 func formatClaimHistoryRecord (user,claimedRewards) = makeString(["%s%d%d%s", user, toString(lastBlock.height), toString(lastBlock.timestamp), claimedRewards], separator)
158158
159159
160160 func HistoryRecordEntry (type,userAddress,txId,oldAmount,oldStart,newAmount,newStart) = StringEntry(keyHistoryRecord(type, userAddress, txId), formatHistoryRecord(oldAmount, oldStart, newAmount, newStart))
161161
162162
163163 func ClaimHistoryEntry (userAddress,txId,claimedRewards) = StringEntry(keyHistoryRecord("claim", userAddress, txId), formatClaimHistoryRecord(toString(userAddress), claimedRewards))
164164
165165
166166 func StatsResult (totalLockedInc,lockCountInc,usersCountInc) = {
167167 let locksCount = getIntOrZero(keyStatsLocksCount())
168168 let usersCount = getIntOrZero(keyStatsUsersCount())
169169 let totalAmount = getIntOrZero(keyLockParamTotalAmount())
170170 let totalAmountNew = (totalAmount + totalLockedInc)
171171 $Tuple3([IntegerEntry(keyStatsLocksCount(), (locksCount + lockCountInc)), IntegerEntry(keyStatsUsersCount(), (usersCount + usersCountInc)), IntegerEntry(keyLockParamTotalAmount(), totalAmountNew)], totalAmount, totalAmountNew)
172172 }
173173
174174
175175 func LockParamsEntry (userAddress,amount,start) = [IntegerEntry(keyLockParamUserAmount(userAddress), amount), IntegerEntry(keyLockParamStartBlock(userAddress), start)]
176176
177177
178178 func getParamsOrFail () = $Tuple2(fromBase58String(getStringOrFail(this, keyStakedAssetId())), getIntOrFail(keyMinLockAmount()))
179179
180180
181181 func isActiveUser (userAddress) = (getIntOrElse(keyLockParamUserAmount(userAddress), 0) > 0)
182182
183183
184184 func getUserParamsOrUnit (userAddress) = if (isActiveUser(userAddress))
185185 then $Tuple3(false, getIntOrFail(keyLockParamUserAmount(userAddress)), getIntOrFail(keyLockParamStartBlock(userAddress)))
186186 else unit
187187
188188
189189 func getUserParamsOrFail (userAddress) = valueOrErrorMessage(getUserParamsOrUnit(userAddress), (("User " + toString(userAddress)) + " is not defined"))
190190
191191
192192 let supportedAssetsStr = getStrOrElse(keySupportedRewardAssets(), "")
193193
194194 let supportedAssetsList = split(supportedAssetsStr, "_")
195195
196196 func calcReward (userAddress,assetId,stakedAmountX,depositNumUser,depositNumLast) = {
197197 let rewardPerNsbtSumLastKEY = keyRewardPerNsbtSumAt(depositNumLast, assetId)
198198 let sumLastX18 = parseBigIntValue(getStrOrElse(keyRewardPerNsbtSumAt(depositNumLast, assetId), "0"))
199199 let sumUserX18 = parseBigIntValue(getStrOrElse(keyRewardPerNsbtSumAt(depositNumUser, assetId), "0"))
200200 let rewardDynamicPart = toInt(fraction((sumLastX18 - sumUserX18), stakedAmountX, MULTX18))
201201 let rewardCachedPartKEY = keyReward(userAddress, assetId)
202202 let rewardCachedPart = getIntOrElse(rewardCachedPartKEY, 0)
203203 $Tuple4((rewardCachedPart + rewardDynamicPart), rewardCachedPart, rewardDynamicPart, rewardCachedPartKEY)
204204 }
205205
206206
207207 func RewardEntries (isNewUser,userAddress,stakedAmount) = {
208208 let stakedAmountX = toBigInt(stakedAmount)
209209 let userRewardFromDepositNumKEY = keyUserRewardFromDepositNum(userAddress)
210210 let depositNumUser = getIntOrElse(userRewardFromDepositNumKEY, -1)
211211 let depositNumLast = getIntOrElse(keyDepositNumLast(), -1)
212212 func forEachAssetCacheUserReward (accum,asset) = {
213213 let $t084368571 = calcReward(userAddress, asset, stakedAmountX, depositNumUser, depositNumLast)
214214 let rewardTotal = $t084368571._1
215215 let cached = $t084368571._2
216216 let dynamic = $t084368571._3
217217 let rewardCachedPartKEY = $t084368571._4
218218 (accum :+ IntegerEntry(rewardCachedPartKEY, rewardTotal))
219219 }
220220
221221 if (if ((depositNumLast == -1))
222222 then (depositNumUser == -1)
223223 else false)
224224 then nil
225225 else if (if ((depositNumLast == -1))
226226 then (depositNumUser > -1)
227227 else false)
228228 then throw("invalid depositNumLast and depositNumUser state")
229229 else if (if ((depositNumLast > -1))
230230 then (depositNumUser == -1)
231231 else false)
232232 then if (isNewUser)
233233 then [IntegerEntry(userRewardFromDepositNumKEY, depositNumLast)]
234234 else ({
235235 let $l = supportedAssetsList
236236 let $s = size($l)
237237 let $acc0 = nil
238238 func $f0_1 ($a,$i) = if (($i >= $s))
239239 then $a
240240 else forEachAssetCacheUserReward($a, $l[$i])
241241
242242 func $f0_2 ($a,$i) = if (($i >= $s))
243243 then $a
244244 else throw("List size exceeds 10")
245245
246246 $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10)
247247 } :+ IntegerEntry(userRewardFromDepositNumKEY, depositNumLast))
248248 else if (if ((depositNumLast > -1))
249249 then (depositNumUser > -1)
250250 else false)
251251 then if (isNewUser)
252252 then [IntegerEntry(userRewardFromDepositNumKEY, depositNumLast)]
253253 else ({
254254 let $l = supportedAssetsList
255255 let $s = size($l)
256256 let $acc0 = nil
257257 func $f0_1 ($a,$i) = if (($i >= $s))
258258 then $a
259259 else forEachAssetCacheUserReward($a, $l[$i])
260260
261261 func $f0_2 ($a,$i) = if (($i >= $s))
262262 then $a
263263 else throw("List size exceeds 10")
264264
265265 $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10)
266266 } :+ IntegerEntry(userRewardFromDepositNumKEY, depositNumLast))
267267 else throw(((("uncovered condition: depositNumLast=" + toString(depositNumLast)) + " depositNumUser=") + toString(depositNumUser)))
268268 }
269269
270270
271271 func IncrementNotDistributedRewardEntry (tkn,amountInc) = {
272272 let notDistributedRewardKEY = keyNotDistributedReward(tkn)
273273 let notDistributedReward = getIntOrElse(notDistributedRewardKEY, 0)
274274 [IntegerEntry(notDistributedRewardKEY, (notDistributedReward + amountInc))]
275275 }
276276
277277
278278 func surfToGnsbt (surfAmt) = (surfAmt / 60)
279279
280280
281281 let ContolContractKey = "control_contract"
282282
283283 @Callable(i)
284284 func constructor (minLockAmount,supportedRewardAssets,stakedAssetId) = if ((i.caller != this))
285285 then throw("Permission denied")
286286 else [IntegerEntry(keyMinLockAmount(), minLockAmount), StringEntry(keySupportedRewardAssets(), supportedRewardAssets), StringEntry(keyStakedAssetId(), stakedAssetId)]
287287
288288
289289
290290 @Callable(i)
291291 func stake () = {
292292 let $t01212012174 = getParamsOrFail()
293293 let stakedAssetId = $t01212012174._1
294294 let minLockAmount = $t01212012174._2
295295 if ((size(i.payments) != 1))
296296 then throw("Invalid payments size")
297297 else {
298298 let payment = i.payments[0]
299299 let amount = payment.amount
300300 let invalidAssetMessage = (("Invalid asset. " + toBase58String(stakedAssetId)) + " is expected")
301301 let assetId = valueOrErrorMessage(payment.assetId, invalidAssetMessage)
302302 if ((assetId != stakedAssetId))
303303 then throw(invalidAssetMessage)
304304 else {
305305 let userAddress = i.caller
306306 let userAddressStr = toString(userAddress)
307307 let gnsbtAmtUser = 0
308308 let gnsbtAmtTotal = 0
309309 let $t01267212781 = valueOrElse(getUserParamsOrUnit(userAddress), $Tuple3(true, 0, -1))
310310 let isNewUser = $t01267212781._1
311311 let stakedAmount = $t01267212781._2
312312 let lockStartHeight = $t01267212781._3
313313 let stakedAmountNew = if (isNewUser)
314314 then amount
315315 else (amount + stakedAmount)
316316 let mergedStartHeight = if (isNewUser)
317317 then height
318318 else (height + (1440 * 14))
319319 if ((minLockAmount > stakedAmountNew))
320320 then throw(("Min lock amount is " + toString(minLockAmount)))
321321 else {
322322 let $t01308413186 = StatsResult(amount, 1, if (isNewUser)
323323 then 1
324324 else 0)
325325 let statsEntries = $t01308413186._1
326326 let totalStaked = $t01308413186._2
327327 let totalStakedNew = $t01308413186._3
328328 ((([HistoryRecordEntry("stake", userAddress, i.transactionId, stakedAmount, lockStartHeight, stakedAmountNew, mergedStartHeight)] ++ RewardEntries(isNewUser, userAddressStr, stakedAmount)) ++ LockParamsEntry(userAddress, stakedAmountNew, mergedStartHeight)) ++ statsEntries)
329329 }
330330 }
331331 }
332332 }
333333
334334
335335
336336 @Callable(i)
337337 func stakeByOriginCaller () = {
338338 let $t01352213576 = getParamsOrFail()
339339 let stakedAssetId = $t01352213576._1
340340 let minLockAmount = $t01352213576._2
341341 if ((size(i.payments) != 1))
342342 then throw("Invalid payments size")
343343 else {
344344 let payment = i.payments[0]
345345 let amount = payment.amount
346346 let invalidAssetMessage = (("Invalid asset. " + toBase58String(stakedAssetId)) + " is expected")
347347 let assetId = valueOrErrorMessage(payment.assetId, invalidAssetMessage)
348348 if ((assetId != stakedAssetId))
349349 then throw(invalidAssetMessage)
350350 else {
351351 let userAddress = i.originCaller
352352 let userAddressStr = toString(userAddress)
353353 let gnsbtAmtUser = 0
354354 let gnsbtAmtTotal = 0
355355 let $t01408014189 = valueOrElse(getUserParamsOrUnit(userAddress), $Tuple3(true, 0, -1))
356356 let isNewUser = $t01408014189._1
357357 let stakedAmount = $t01408014189._2
358358 let lockStartHeight = $t01408014189._3
359359 let stakedAmountNew = if (isNewUser)
360360 then amount
361361 else (amount + stakedAmount)
362362 let mergedStartHeight = if (isNewUser)
363363 then height
364364 else (height + (1440 * 14))
365365 if ((minLockAmount > stakedAmountNew))
366366 then throw(("Min lock amount is " + toString(minLockAmount)))
367367 else {
368368 let $t01449214594 = StatsResult(amount, 1, if (isNewUser)
369369 then 1
370370 else 0)
371371 let statsEntries = $t01449214594._1
372372 let totalStaked = $t01449214594._2
373373 let totalStakedNew = $t01449214594._3
374374 ((([HistoryRecordEntry("stake", userAddress, i.transactionId, stakedAmount, lockStartHeight, stakedAmountNew, mergedStartHeight)] ++ RewardEntries(isNewUser, userAddressStr, stakedAmount)) ++ LockParamsEntry(userAddress, stakedAmountNew, mergedStartHeight)) ++ statsEntries)
375375 }
376376 }
377377 }
378378 }
379379
380380
381381
382382 @Callable(i)
383383 func unstake (amount) = if ((size(i.payments) != 0))
384384 then throw("unstake doesn't require any payment")
385385 else {
386386 let userAddress = i.caller
387387 let userAddressStr = toString(userAddress)
388388 let $t01509015144 = getParamsOrFail()
389389 let stakedAssetId = $t01509015144._1
390390 let minLockAmount = $t01509015144._2
391391 let $t01514715221 = getUserParamsOrFail(userAddress)
392392 let isNewUser = $t01514715221._1
393393 let lockAmount = $t01514715221._2
394394 let lockStart = $t01514715221._3
395395 if ((0 >= lockAmount))
396396 then throw("Nothing to unstake")
397397 else if ((amount > lockAmount))
398398 then throw(((("Requested " + toString(amount)) + ", but staked only ") + toString(lockAmount)))
399399 else {
400400 let $t01541115565 = StatsResult(-(amount), if ((amount == lockAmount))
401401 then -1
402402 else 0, if ((amount == lockAmount))
403403 then -1
404404 else 0)
405405 let statsEntries = $t01541115565._1
406406 let totalStaked = $t01541115565._2
407407 let totalStakedNew = $t01541115565._3
408408 ((([ScriptTransfer(userAddress, amount, stakedAssetId), HistoryRecordEntry("unstake", userAddress, i.transactionId, lockAmount, lockStart, (lockAmount - amount), lockStart)] ++ RewardEntries(false, userAddressStr, lockAmount)) ++ LockParamsEntry(userAddress, (lockAmount - amount), lockStart)) ++ statsEntries)
409409 }
410410 }
411411
412412
413413
414414 @Callable(i)
415415 func deposit () = if ((size(i.payments) != 1))
416416 then throw("exact 1 payment is allowed only")
417417 else {
418418 let pmt = i.payments[0]
419419 let amount = pmt.amount
420420 let pmtAssetId = valueOrElse(pmt.assetId, WAVESID)
421421 let pmtAssetIdStr = toBase58String(pmtAssetId)
422422 let pmtMultX = if ((pmtAssetId == WAVESID))
423423 then MULTX8
424424 else MULTX6
425425 let amountX = toBigInt(amount)
426426 let totalStaked = getIntOrElse(keyLockParamTotalAmount(), 0)
427427 let totalStakedX = toBigInt(totalStaked)
428428 if ((0 > totalStaked))
429429 then throw("TODO: case is not supported")
430430 else if ((totalStaked == 0))
431431 then IncrementNotDistributedRewardEntry(pmtAssetIdStr, amount)
432432 else {
433433 let rewardPerNsbtX18 = fraction(amountX, MULTX18, totalStakedX)
434434 let depositNumLastKEY = keyDepositNumLast()
435435 let depositNumLast = getIntOrElse(depositNumLastKEY, -1)
436436 let depositNumNew = (depositNumLast + 1)
437437 if (!(contains(supportedAssetsStr, pmtAssetIdStr)))
438438 then throw(((supportedAssetsStr + " doesn't contain ") + pmtAssetIdStr))
439439 else {
440440 func refreshRewardPerNsbtSUM (accum,nextAsset) = {
441441 let rewardPerNsbtSumNewKEY = keyRewardPerNsbtSumAt(depositNumNew, nextAsset)
442442 let sumLastStr = getStrOrElse(keyRewardPerNsbtSumAt(depositNumLast, nextAsset), "0")
443443 (accum :+ (if ((nextAsset == pmtAssetIdStr))
444444 then StringEntry(rewardPerNsbtSumNewKEY, toString((parseBigIntValue(sumLastStr) + rewardPerNsbtX18)))
445445 else StringEntry(rewardPerNsbtSumNewKEY, sumLastStr)))
446446 }
447447
448448 ({
449449 let $l = supportedAssetsList
450450 let $s = size($l)
451451 let $acc0 = nil
452452 func $f0_1 ($a,$i) = if (($i >= $s))
453453 then $a
454454 else refreshRewardPerNsbtSUM($a, $l[$i])
455455
456456 func $f0_2 ($a,$i) = if (($i >= $s))
457457 then $a
458458 else throw("List size exceeds 10")
459459
460460 $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10)
461461 } :+ IntegerEntry(depositNumLastKEY, depositNumNew))
462462 }
463463 }
464464 }
465465
466466
467467
468468 @Callable(i)
469469 func claimRewards () = {
470470 let userAddress = i.caller
471471 let userAddressStr = toString(userAddress)
472472 if ((size(i.payments) > 0))
473473 then throw("payments are not accepted")
474474 else {
475475 let $t01772917834 = valueOrElse(getUserParamsOrUnit(userAddress), $Tuple3(true, 0, 0))
476476 let isNewUser = $t01772917834._1
477477 let stakedAmount = $t01772917834._2
478478 let stakingStart = $t01772917834._3
479479 let stakedAmountX = toBigInt(stakedAmount)
480480 let userRewardFromDepositNumKEY = keyUserRewardFromDepositNum(userAddressStr)
481481 let depositNumUser = getIntOrElse(userRewardFromDepositNumKEY, -1)
482482 let depositNumLast = getIntOrElse(keyDepositNumLast(), -1)
483483 func forEachAssetCalcUnclaimedReward (accum,asset) = {
484484 let $t01820518343 = calcReward(userAddressStr, asset, stakedAmountX, depositNumUser, depositNumLast)
485485 let rewardTotal = $t01820518343._1
486486 let cached = $t01820518343._2
487487 let dynamic = $t01820518343._3
488488 let rewardCachedPartKEY = $t01820518343._4
489489 let claimedKEY = keyClaimed(userAddressStr, asset)
490490 let $t01840318440 = accum
491491 let data = $t01840318440._1
492492 let claimedAmtByAsset = $t01840318440._2
493493 let newPart = makeString([asset, toString(rewardTotal)], ":")
494494 let claimedAmtByAssetNew = makeString([claimedAmtByAsset, newPart], "_")
495495 if ((0 >= rewardTotal))
496496 then $Tuple2(data, claimedAmtByAssetNew)
497497 else $Tuple2((((data :+ ScriptTransfer(userAddress, rewardTotal, toAssetVect(asset))) :+ IntegerEntry(claimedKEY, (valueOrElse(getInteger(claimedKEY), 0) + rewardTotal))) :+ IntegerEntry(rewardCachedPartKEY, 0)), claimedAmtByAssetNew)
498498 }
499499
500500 let $t01890019014 = {
501501 let $l = supportedAssetsList
502502 let $s = size($l)
503503 let $acc0 = $Tuple2(nil, "")
504504 func $f0_1 ($a,$i) = if (($i >= $s))
505505 then $a
506506 else forEachAssetCalcUnclaimedReward($a, $l[$i])
507507
508508 func $f0_2 ($a,$i) = if (($i >= $s))
509509 then $a
510510 else throw("List size exceeds 10")
511511
512512 $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10)
513513 }
514514 let transfers = $t01890019014._1
515515 let claimedAmtByAssetResult = $t01890019014._2
516516 if ((0 >= size(transfers)))
517517 then throw("nothing to claim")
518518 else ((transfers :+ IntegerEntry(userRewardFromDepositNumKEY, depositNumLast)) :+ ClaimHistoryEntry(userAddress, i.transactionId, drop(claimedAmtByAssetResult, 1)))
519519 }
520520 }
521521
522522
523523
524524 @Callable(i)
525525 func unclaimedRewardsREADONLY (userAddressStr) = {
526526 func forEachAssetZeroReward (accum,asset) = ((accum + makeString([asset, "0", "0"], ":")) + "_")
527527
528528 let unclaimedRewardStr = if ((userAddressStr == ""))
529529 then {
530530 let $l = supportedAssetsList
531531 let $s = size($l)
532532 let $acc0 = ""
533533 func $f0_1 ($a,$i) = if (($i >= $s))
534534 then $a
535535 else forEachAssetZeroReward($a, $l[$i])
536536
537537 func $f0_2 ($a,$i) = if (($i >= $s))
538538 then $a
539539 else throw("List size exceeds 10")
540540
541541 $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10)
542542 }
543543 else {
544544 let userAddress = addressFromStringValue(userAddressStr)
545545 let $t01967319778 = valueOrElse(getUserParamsOrUnit(userAddress), $Tuple3(true, 0, 0))
546546 let isNewUser = $t01967319778._1
547547 let stakedAmount = $t01967319778._2
548548 let stakingStart = $t01967319778._3
549549 let stakedAmountX = toBigInt(stakedAmount)
550550 let userRewardFromDepositNumKEY = keyUserRewardFromDepositNum(userAddressStr)
551551 let depositNumUser = getIntOrElse(userRewardFromDepositNumKEY, -1)
552552 let depositNumLast = getIntOrElse(keyDepositNumLast(), -1)
553553 func forEachAssetCalcUnclaimedReward (accum,asset) = {
554554 let $t02012420262 = calcReward(userAddressStr, asset, stakedAmountX, depositNumUser, depositNumLast)
555555 let rewardTotal = $t02012420262._1
556556 let cached = $t02012420262._2
557557 let dynamic = $t02012420262._3
558558 let rewardCachedPartKEY = $t02012420262._4
559559 let claimed = valueOrElse(getInteger(keyClaimed(userAddressStr, asset)), 0)
560560 ((accum + makeString([asset, toString(rewardTotal), toString(claimed)], ":")) + "_")
561561 }
562562
563563 let $l = supportedAssetsList
564564 let $s = size($l)
565565 let $acc0 = ""
566566 func $f0_1 ($a,$i) = if (($i >= $s))
567567 then $a
568568 else forEachAssetCalcUnclaimedReward($a, $l[$i])
569569
570570 func $f0_2 ($a,$i) = if (($i >= $s))
571571 then $a
572572 else throw("List size exceeds 10")
573573
574574 $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10)
575575 }
576576 $Tuple2(nil, dropRight(unclaimedRewardStr, 1))
577577 }
578578
579579
580580
581581 @Callable(i)
582582 func surfStakingSYSREADONLY (userAddressStrOrEmpty) = {
583583 let surfTotal = getIntOrElse(keyLockParamTotalAmount(), 0)
584584 let gnsbtFromSurfTotal = surfToGnsbt(surfTotal)
585585 if ((userAddressStrOrEmpty == ""))
586586 then $Tuple2(nil, [0, surfTotal, 0, gnsbtFromSurfTotal, 0])
587587 else {
588588 let userAddress = toAddressOrFail(userAddressStrOrEmpty)
589589 let $t02095421055 = valueOrElse(getUserParamsOrUnit(userAddress), $Tuple3(true, 0, 0))
590590 let isNewUser = $t02095421055._1
591591 let surfUser = $t02095421055._2
592592 let stakingStart = $t02095421055._3
593593 let gnsbtFromSurfUser = surfToGnsbt(surfUser)
594594 $Tuple2(nil, [surfUser, surfTotal, gnsbtFromSurfUser, gnsbtFromSurfTotal, stakingStart])
595595 }
596596 }
597597
598598
599+
600+@Callable(i)
601+func configSYSREADONLY () = {
602+ let minLockAmt = getIntegerValue(keyMinLockAmount())
603+ let gnsbtFromSurfCoeff = (60 * MULT6)
604+ let surfVotingPowerRestrictivePeriod = (1440 * 14)
605+ let brToStartSurfTransformation = 1200000
606+ $Tuple2(nil, [minLockAmt, gnsbtFromSurfCoeff, surfVotingPowerRestrictivePeriod, brToStartSurfTransformation])
607+ }
608+
609+

github/deemru/w8io/169f3d6 
97.99 ms