tx · 2creARBiVEjbAjppNgoDYbFebJquHxJpYCYmRYgdmz6U

3Mp5kisFrqESzrXxAMEPk2k69zpeF41czEE:  -0.02200000 Waves

2022.09.12 17:24 [2226003] smart account 3Mp5kisFrqESzrXxAMEPk2k69zpeF41czEE > SELF 0.00000000 Waves

{ "type": 13, "id": "2creARBiVEjbAjppNgoDYbFebJquHxJpYCYmRYgdmz6U", "fee": 2200000, "feeAssetId": null, "timestamp": 1662992754377, "version": 1, "sender": "3Mp5kisFrqESzrXxAMEPk2k69zpeF41czEE", "senderPublicKey": "G349Uq3FTox7dRNLeAfAQeoACvwZ9iEnVSaHcEYn6j8J", "proofs": [ "2y1azdZTUwmZ5YpiRBxPM6ypvauwUxk8heQ9C9Nd8cLpFyhXwHjaTMEuQuTHUYBxNmMXsqj1kw1eFzrybs8xUMdF" ], "script": "base64:BgJJCAISBAoCCAESABIDCgEBEgASABIAEgMKAQgSAwoBCBIDCgEIEgUKAwEBARIFCgMBAQESABIDCgEIEgcKBQgICAgIEgMKAQgSAE4AA1NFUAICX18ABVNDQUxFAOgHAAVNVUxUOACAwtcvAAp6ZXJvQmlnSW50CQC2AgEAAAAUcHJvY2Vzc2luZ1N0YWdlVG90YWwAAAAVcHJvY2Vzc2luZ1N0YWdlU2hhcmVzAAEBDmdldE51bWJlckJ5S2V5AQNrZXkJAQt2YWx1ZU9yRWxzZQIJAJoIAgUEdGhpcwUDa2V5AAABD2dldE51bWJlck9yRmFpbAEDa2V5CQETdmFsdWVPckVycm9yTWVzc2FnZQIJAJoIAgUEdGhpcwUDa2V5CQCsAgIJAKwCAgIPbWFuZGF0b3J5IHRoaXMuBQNrZXkCDyBpcyBub3QgZGVmaW5lZAEOZ2V0U3RyaW5nQnlLZXkBA2tleQkBC3ZhbHVlT3JFbHNlAgkAnQgCBQR0aGlzBQNrZXkCAAEPZ2V0U3RyaW5nT3JGYWlsAQNrZXkJARN2YWx1ZU9yRXJyb3JNZXNzYWdlAgkAnQgCBQR0aGlzBQNrZ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QEJaXNEZWZpbmVkAQUCcG0GCQACAQISTm8gcGVuZGluZyBtYW5hZ2VyAwkAAAIFBWhhc1BNBQVoYXNQTQQHY2hlY2tQTQMJAAACCAUBaQ9jYWxsZXJQdWJsaWNLZXkJAQV2YWx1ZQEFAnBtBgkAAgECG1lvdSBhcmUgbm90IHBlbmRpbmcgbWFuYWdlcgMJAAACBQdjaGVja1BNBQdjaGVja1BNCQDMCAIJAQtTdHJpbmdFbnRyeQIJARNrZXlNYW5hZ2VyUHVibGljS2V5AAkA2AQBCQEFdmFsdWUBBQJwbQkAzAgCCQELRGVsZXRlRW50cnkBCQEaa2V5UGVuZGluZ01hbmFnZXJQdWJsaWNLZXkABQNuaWwJAAIBAiRTdHJpY3QgdmFsdWUgaXMgbm90IGVxdWFsIHRvIGl0c2VsZi4JAAIBAiRTdHJpY3QgdmFsdWUgaXMgbm90IGVxdWFsIHRvIGl0c2VsZi4BAnR4AQZ2ZXJpZnkABA90YXJnZXRQdWJsaWNLZXkEByRtYXRjaDAJARZtYW5hZ2VyUHVibGljS2V5T3JVbml0AAMJAAECBQckbWF0Y2gwAgpCeXRlVmVjdG9yBAJwawUHJG1hdGNoMAUCcGsDCQABAgUHJG1hdGNoMAIEVW5pdAgFAnR4D3NlbmRlclB1YmxpY0tleQkAAgECC01hdGNoIGVycm9yCQD0AwMIBQJ0eAlib2R5Qnl0ZXMJAJEDAggFAnR4BnByb29mcwAABQ90YXJnZXRQdWJsaWNLZXlH0ouQ", "chainId": 84, "height": 2226003, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 5qBic48WjbNPwehhwqfTLYVsakhHMb9N549pfwFsLPBV Next: PhHQMyKgKXoaJUzJKmoUNsDZeEVEMgp3LHNFeLX32jD Diff:
OldNewDifferences
2525 func getStringOrFail (key) = valueOrErrorMessage(getString(this, key), (("mandatory this." + key) + " is not defined"))
2626
2727
28-func abs (val) = if ((0 > val))
29- then -(val)
30- else val
31-
32-
33-func absBigInt (val) = if ((zeroBigInt > val))
28+func abs (val) = if ((zeroBigInt > val))
3429 then -(val)
3530 else val
3631
330325 then $Tuple2(nil, false)
331326 else if ((processingStage == processingStageTotal))
332327 then {
333- let $t01208412200 = calcUserWeight(boostingContractOrFail(), heightForPeriod, currentPeriod, currentUser)
334- let userWeight = $t01208412200._1
335- let userActions = $t01208412200._2
328+ let $t01202512141 = calcUserWeight(boostingContractOrFail(), heightForPeriod, currentPeriod, currentUser)
329+ let userWeight = $t01202512141._1
330+ let userActions = $t01202512141._2
336331 let totalWeightNew = (totalWeight + userWeight)
337332 let processingActions = if (((usersCount - 1) > currentUser))
338333 then [IntegerEntry(keyNextProcessedUser(), (currentUser + 1))]
438433 func claimReward () = {
439434 let cfgArray = readConfigArrayOrFail()
440435 let address = toString(i.caller)
441- let $t01754217592 = commonClaimReward(address)
442- let amount = $t01754217592._1
443- let actions = $t01754217592._2
436+ let $t01748317533 = commonClaimReward(address)
437+ let amount = $t01748317533._1
438+ let actions = $t01748317533._2
444439 let checkAmount = if ((amount > 0))
445440 then true
446441 else throw("Nothing to claim")
463458
464459 @Callable(i)
465460 func claimRewardREADONLY (address) = {
466- let $t01816518215 = commonClaimReward(address)
467- let amount = $t01816518215._1
468- let actions = $t01816518215._2
461+ let $t01810618156 = commonClaimReward(address)
462+ let amount = $t01810618156._1
463+ let actions = $t01810618156._2
469464 let referralUnclaimed = valueOrElse(getInteger(referralsContractAddressOrFail, keyUnclaimedReferral(referralProgramName, address)), 0)
470465 let totalAmount = (amount + referralUnclaimed)
471466 $Tuple2(nil, totalAmount)
532527 let ann = (amp * nCoins)
533528 let arr = [1, 2, 3, 4, 5, 6, 7]
534529 func calc (acc,cur) = {
535- let $t02083821027 = acc
536- let d = $t02083821027._1
537- let dPrev = $t02083821027._2
530+ let $t02077920968 = acc
531+ let d = $t02077920968._1
532+ let dPrev = $t02077920968._2
538533 let dp = (((d * d) * d) / (((x1 * x2) * nCoins) * nCoins))
539534 let dNext = (((((ann * s) / aPrecision) + (dp * nCoins)) * d) / ((((ann - aPrecision) * d) / aPrecision) + ((nCoins + toBigInt(1)) * dp)))
540535 $Tuple2(dNext, d)
541536 }
542537
543- let $t02124021290 = {
538+ let $t02118121231 = {
544539 let $l = arr
545540 let $s = size($l)
546541 let $acc0 = $Tuple2(s, unit)
554549
555550 $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7)
556551 }
557- let dNext = $t02124021290._1
558- let dPrev = $t02124021290._2
559- let dDiff = absBigInt((dNext - value(dPrev)))
552+ let dNext = $t02118121231._1
553+ let dPrev = $t02118121231._2
554+ let dDiff = abs((dNext - value(dPrev)))
560555 if ((targetPrecision >= dDiff))
561556 then $Tuple2(nil, toString(dNext))
562557 else throw(("D calculation error, dDiff = " + toString(dDiff)))
563558 }
564- }
565-
566-
567-
568-@Callable(i)
569-func calcPutXOnly (paymentAmountBigIntStr,amountAssetBalanceBigIntStr,priceAssetBalanceBigIntStr,dBigIntStr,amplificatorBigIntStr,amplificatorPrecisionBigIntStr,targetXPrecisionBigIntStr,targetDPrecisionBigIntStr) = {
570- let nCoins = toBigInt(2)
571- let aPrecision = parseBigIntValue(amplificatorPrecisionBigIntStr)
572- let targetPrecision = parseBigIntValue(targetXPrecisionBigIntStr)
573- let X = parseBigIntValue(amountAssetBalanceBigIntStr)
574- let Y = parseBigIntValue(priceAssetBalanceBigIntStr)
575- let d = if ((dBigIntStr == ""))
576- then parseBigIntValue({
577- let @ = invoke(this, "calcD", [amountAssetBalanceBigIntStr, priceAssetBalanceBigIntStr, amplificatorBigIntStr, amplificatorPrecisionBigIntStr, targetDPrecisionBigIntStr], nil)
578- if ($isInstanceOf(@, "String"))
579- then @
580- else throw(($getType(invoke(this, "calcD", [amountAssetBalanceBigIntStr, priceAssetBalanceBigIntStr, amplificatorBigIntStr, amplificatorPrecisionBigIntStr, targetDPrecisionBigIntStr], nil)) + " couldn't be cast to String"))
581- })
582- else parseBigIntValue(dBigIntStr)
583- let amp = (parseBigIntValue(amplificatorBigIntStr) * aPrecision)
584- let S = parseBigIntValue(paymentAmountBigIntStr)
585- let ann = (amp * nCoins)
586- let arr = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
587- func calc (acc,cur) = {
588- let $t02289122911 = acc
589- let x = $t02289122911._1
590- let xPrev = $t02289122911._2
591- let newX = ((X + S) - x)
592- let newY = (Y - ((x * Y) / X))
593- let dp = (((d * d) * d) / (((newX * newY) * nCoins) * nCoins))
594- let xNext = (x + ((((((-(d) * ann) / aPrecision) + d) + ((ann * (newX + newY)) / aPrecision)) - dp) / ((((-(ann) * (toBigInt(-1) - (Y / X))) / aPrecision) + (dp / newX)) + ((Y * dp) / (X * newY)))))
595- $Tuple2(xNext, x)
596- }
597-
598- let $t02321423274 = {
599- let $l = arr
600- let $s = size($l)
601- let $acc0 = $Tuple2(zeroBigInt, unit)
602- func $f0_1 ($a,$i) = if (($i >= $s))
603- then $a
604- else calc($a, $l[$i])
605-
606- func $f0_2 ($a,$i) = if (($i >= $s))
607- then $a
608- else throw("List size exceeds 10")
609-
610- $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)
611- }
612- let xNext = $t02321423274._1
613- let xPrev = $t02321423274._2
614- let xDiff = absBigInt((xNext - value(xPrev)))
615- if ((targetPrecision >= xDiff))
616- then $Tuple2(nil, $Tuple2(toInt(xNext), toInt(fraction(xNext, Y, X))))
617- else throw(((((("X calculation error, xDiff = " + toString(xDiff)) + ", xNext = ") + toString(xNext)) + ", xPrev = ") + toString(value(xPrev))))
618559 }
619560
620561
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 6 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let SEP = "__"
55
66 let SCALE = 1000
77
88 let MULT8 = 100000000
99
1010 let zeroBigInt = toBigInt(0)
1111
1212 let processingStageTotal = 0
1313
1414 let processingStageShares = 1
1515
1616 func getNumberByKey (key) = valueOrElse(getInteger(this, key), 0)
1717
1818
1919 func getNumberOrFail (key) = valueOrErrorMessage(getInteger(this, key), (("mandatory this." + key) + " is not defined"))
2020
2121
2222 func getStringByKey (key) = valueOrElse(getString(this, key), "")
2323
2424
2525 func getStringOrFail (key) = valueOrErrorMessage(getString(this, key), (("mandatory this." + key) + " is not defined"))
2626
2727
28-func abs (val) = if ((0 > val))
29- then -(val)
30- else val
31-
32-
33-func absBigInt (val) = if ((zeroBigInt > val))
28+func abs (val) = if ((zeroBigInt > val))
3429 then -(val)
3530 else val
3631
3732
3833 let keyMaxDepth = "%s__maxDepth"
3934
4035 let maxDepthDefault = 30
4136
4237 let maxDepth = valueOrElse(getInteger(this, keyMaxDepth), maxDepthDefault)
4338
4439 func keyFactoryAddress () = "%s%s__config__factoryAddress"
4540
4641
4742 let factoryAddressStr = getStringOrFail(keyFactoryAddress())
4843
4944 let factoryContract = addressFromStringValue(factoryAddressStr)
5045
5146 func keyEmissionAddress () = "%s%s__config__emissionAddress"
5247
5348
5449 func keyNumToUserMapping (num) = makeString(["%s%s%s", "mapping", "num2user", toString(num)], SEP)
5550
5651
5752 let keyReferralProgramName = makeString(["%s%s", "referral", "programName"], SEP)
5853
5954 let referralProgramNameDefault = "wxlock"
6055
6156 let referralProgramName = valueOrElse(getString(this, keyReferralProgramName), referralProgramNameDefault)
6257
6358 let keyReferralMinGWxAmount = makeString(["%s%s", "referral", "minGWxAmount"], SEP)
6459
6560 let referralMinGWxAmountDefault = (500 * MULT8)
6661
6762 let referralMinGWxAmount = valueOrElse(getInteger(this, keyReferralMinGWxAmount), referralMinGWxAmountDefault)
6863
6964 let keyReferrerRewardPermille = makeString(["%s%s", "referral", "referrerRewardPermille"], SEP)
7065
7166 let referrerRewardPermilleDefault = 50
7267
7368 let referrerRewardPermille = valueOrElse(getInteger(this, keyReferrerRewardPermille), referrerRewardPermilleDefault)
7469
7570 let keyReferralRewardPermille = makeString(["%s%s", "referral", "referralRewardPermille"], SEP)
7671
7772 let referralRewardPermilleDefault = 50
7873
7974 let referralRewardPermille = valueOrElse(getInteger(this, keyReferralRewardPermille), referralRewardPermilleDefault)
8075
8176 func keyReferrer (referralAddress) = makeString(["%s%s%s", "referrer", referralProgramName, referralAddress], SEP)
8277
8378
8479 func keyUnclaimedReferral (programName,claimerAddress) = makeString(["%s%s%s%s", "unclaimedReferral", programName, claimerAddress], SEP)
8580
8681
8782 let emissionAddressStr = getStringOrFail(keyEmissionAddress())
8883
8984 let emissionContract = addressFromStringValue(emissionAddressStr)
9085
9186 let IdxCfgAssetId = 1
9287
9388 let IdxCfgPacemakerAddress = 2
9489
9590 let IdxCfgBoostingContract = 3
9691
9792 let IdxCfgMaxDepth = 4
9893
9994 func keyConfig () = "%s__config"
10095
10196
10297 func readConfigArrayOrFail () = split(getStringOrFail(keyConfig()), SEP)
10398
10499
105100 func formatConfig (wxAssetIdStr,matcherPacemakerAddressStr,boostingContractAddressStr,maxDepth) = makeString(["%s%s%s%d", wxAssetIdStr, matcherPacemakerAddressStr, boostingContractAddressStr, toString(maxDepth)], SEP)
106101
107102
108103 func boostingContractOrFail () = {
109104 let cfgArray = readConfigArrayOrFail()
110105 valueOrErrorMessage(addressFromString(cfgArray[IdxCfgBoostingContract]), "boosting contract address is not defined")
111106 }
112107
113108
114109 func keyGwxRewardEmissionStartHeight () = "%s%s__gwxRewardEmissionPart__startHeight"
115110
116111
117112 func keyUsersCount () = "%s__nextUserNum"
118113
119114
120115 func keyRatePerBlockCurrent () = "%s%s__ratePerBlock__current"
121116
122117
123118 func keyPoolWeightVirtual () = "%s%s__poolWeight__GWXvirtualPOOL"
124119
125120
126121 func keyNextProcessedUser () = "%s__nextProcessedUser"
127122
128123
129124 func keyLatestPeriod () = "%s__latestPeriod"
130125
131126
132127 func keyNextPeriod () = "%s__nextPeriod"
133128
134129
135130 func keyProcessingStage () = "%s__processingStage"
136131
137132
138133 func keyNextProcessedPeriod () = "%s__nextProcessedPeriod"
139134
140135
141136 func keyUserUnclaimed (userIndex) = makeString(["%s%d", "userUnclaimed", toString(userIndex)], SEP)
142137
143138
144139 func keyNextUnlaimedPeriodOfUser (userIndex) = makeString(["%s%d__nextClaimedPeriod", toString(userIndex)], SEP)
145140
146141
147142 func keyLastProcessedPeriodOfUser (userIndex) = makeString(["%s%d__lastProcessedPeriod", toString(userIndex)], SEP)
148143
149144
150145 func keyHeightForPeriod (period) = makeString(["%s%d__startHeightForPeriod", toString(period)], SEP)
151146
152147
153148 func keyAuxEmissionRewardForPeriod (period) = makeString(["%s%d__auxEmissionReward", toString(period)], SEP)
154149
155150
156151 func keyTotalAmountForPeriod (period) = makeString(["%s%d__totalAmountForPeriod", toString(period)], SEP)
157152
158153
159154 func keyLastPayoutInfo () = "%s__lastPayoutInfo"
160155
161156
162157 func PeriodPayoutInfo (period,matcherReward,emissionReward) = makeString(["%d%d%d", toString(period), toString(matcherReward), toString(emissionReward)], SEP)
163158
164159
165160 func keyPayoutHistoryInfo (period) = makeString(["%s%s%d__payouts__history", toString(period)], SEP)
166161
167162
168163 func keyTotalWeightForPeriod (period) = makeString(["%s%d__totalWeightForPeriod", toString(period)], SEP)
169164
170165
171166 func keyUserKValueForPeriod (period,userIndex) = makeString(["%s%d%s%d__paramByPeriod", toString(userIndex), "k", toString(period)], SEP)
172167
173168
174169 func keyUserBValueForPeriod (period,userIndex) = makeString(["%s%d%s%d__paramByPeriod", toString(userIndex), "b", toString(period)], SEP)
175170
176171
177172 func keyUserWeightForPeriod (period,userIndex) = makeString(["%s%d%s%d__paramByPeriod", toString(userIndex), "weight", toString(period)], SEP)
178173
179174
180175 func keyReferralsContractAddress () = makeString(["%s%s", "config", "referralsContractAddress"], SEP)
181176
182177
183178 let referralsContractAddressOrFail = addressFromStringValue(getStringOrFail(keyReferralsContractAddress()))
184179
185180 func HistoryEntry (type,user,amount,i) = {
186181 let historyKEY = makeString(["%s%s%s%s__history", type, user, toBase58String(i.transactionId)], SEP)
187182 let historyDATA = makeString(["%d%d%d%d%d%d", toString(lastBlock.height), toString(lastBlock.timestamp), toString(amount)], SEP)
188183 StringEntry(historyKEY, historyDATA)
189184 }
190185
191186
192187 func keyManagerPublicKey () = "%s__managerPublicKey"
193188
194189
195190 func keyPendingManagerPublicKey () = "%s__pendingManagerPublicKey"
196191
197192
198193 func managerPublicKeyOrUnit () = match getString(keyManagerPublicKey()) {
199194 case s: String =>
200195 fromBase58String(s)
201196 case _: Unit =>
202197 unit
203198 case _ =>
204199 throw("Match error")
205200 }
206201
207202
208203 func pendingManagerPublicKeyOrUnit () = match getString(keyPendingManagerPublicKey()) {
209204 case s: String =>
210205 fromBase58String(s)
211206 case _: Unit =>
212207 unit
213208 case _ =>
214209 throw("Match error")
215210 }
216211
217212
218213 func mustManager (i) = {
219214 let pd = throw("Permission denied")
220215 match managerPublicKeyOrUnit() {
221216 case pk: ByteVector =>
222217 if ((i.callerPublicKey == pk))
223218 then true
224219 else pd
225220 case _: Unit =>
226221 if ((i.caller == this))
227222 then true
228223 else pd
229224 case _ =>
230225 throw("Match error")
231226 }
232227 }
233228
234229
235230 func calcUserWeight (boostingContractAddress,heightForPeriod,period,userIndex) = {
236231 let kLast = keyLastProcessedPeriodOfUser(userIndex)
237232 let kKey = keyUserKValueForPeriod(period, userIndex)
238233 let kRaw = getInteger(boostingContractAddress, kKey)
239234 let kUserWeight = keyUserWeightForPeriod(period, userIndex)
240235 if (isDefined(kRaw))
241236 then {
242237 let k = value(kRaw)
243238 let b = value(getInteger(boostingContractAddress, keyUserBValueForPeriod(period, userIndex)))
244239 let w = ((k * heightForPeriod) + b)
245240 if ((w > 0))
246241 then $Tuple2((w / SCALE), [IntegerEntry(kLast, period), IntegerEntry(kUserWeight, w)])
247242 else $Tuple2(0, nil)
248243 }
249244 else {
250245 let p = getInteger(this, kLast)
251246 if (if (isDefined(p))
252247 then (period >= value(p))
253248 else false)
254249 then {
255250 let pv = value(p)
256251 let k = value(getInteger(boostingContractAddress, keyUserKValueForPeriod(pv, userIndex)))
257252 let b = value(getInteger(boostingContractAddress, keyUserBValueForPeriod(pv, userIndex)))
258253 let w = ((k * heightForPeriod) + b)
259254 if ((w > 0))
260255 then $Tuple2((w / SCALE), [IntegerEntry(kUserWeight, w)])
261256 else $Tuple2(0, nil)
262257 }
263258 else $Tuple2(0, nil)
264259 }
265260 }
266261
267262
268263 func calcUserWeightForClaim (boostingContractAddress,heightForPeriod,period,userIndex) = {
269264 let kUserWeight = keyUserWeightForPeriod(period, userIndex)
270265 let userWeightOrUnit = getInteger(kUserWeight)
271266 match userWeightOrUnit {
272267 case _: Unit =>
273268 0
274269 case w: Int =>
275270 (w / SCALE)
276271 case _ =>
277272 throw("Match error")
278273 }
279274 }
280275
281276
282277 func getUserIndexByAddress (boostingContractAddressStr,userAddress) = {
283278 let key = makeString(["%s%s%s", "mapping", "user2num", userAddress], SEP)
284279 parseIntValue(valueOrErrorMessage(getString(Address(fromBase58String(boostingContractAddressStr)), key), ((("User address " + userAddress) + " is not found in boosting contract data, key=") + key)))
285280 }
286281
287282
288283 func nextPeriod () = getNumberByKey(keyNextPeriod())
289284
290285
291286 func commonClaimReward (userAddress) = {
292287 let cfgArray = readConfigArrayOrFail()
293288 let userIdx = getUserIndexByAddress(cfgArray[IdxCfgBoostingContract], userAddress)
294289 let userUnclaimedOption = getInteger(keyUserUnclaimed(userIdx))
295290 match userUnclaimedOption {
296291 case _: Unit =>
297292 $Tuple2(0, nil)
298293 case u: Int =>
299294 $Tuple2(u, [IntegerEntry(keyUserUnclaimed(userIdx), 0)])
300295 case _ =>
301296 throw("Match error")
302297 }
303298 }
304299
305300
306301 @Callable(i)
307302 func updateReferralActivity (userAddress,gWxAmountStart) = {
308303 let referrer = getString(referralsContractAddressOrFail, keyReferrer(userAddress))
309304 let activeReferralInv = if ((referrer == unit))
310305 then unit
311306 else invoke(referralsContractAddressOrFail, "updateReferralActivity", [referralProgramName, userAddress, (gWxAmountStart >= referralMinGWxAmount)], nil)
312307 if ((activeReferralInv == activeReferralInv))
313308 then $Tuple2(nil, unit)
314309 else throw("Strict value is not equal to itself.")
315310 }
316311
317312
318313
319314 @Callable(i)
320315 func finalizeHelper () = {
321316 let processingStage = valueOrElse(getInteger(keyProcessingStage()), processingStageTotal)
322317 let currentPeriod = getNumberByKey(keyNextProcessedPeriod())
323318 let currentUser = getNumberByKey(keyNextProcessedUser())
324319 let latestPeriod = getNumberByKey(keyLatestPeriod())
325320 let usersCount = valueOrElse(getInteger(boostingContractOrFail(), keyUsersCount()), 0)
326321 let totalWeightKey = keyTotalWeightForPeriod(currentPeriod)
327322 let totalWeight = getNumberByKey(keyTotalWeightForPeriod(currentPeriod))
328323 let heightForPeriod = getNumberByKey(keyHeightForPeriod(currentPeriod))
329324 if ((currentPeriod > latestPeriod))
330325 then $Tuple2(nil, false)
331326 else if ((processingStage == processingStageTotal))
332327 then {
333- let $t01208412200 = calcUserWeight(boostingContractOrFail(), heightForPeriod, currentPeriod, currentUser)
334- let userWeight = $t01208412200._1
335- let userActions = $t01208412200._2
328+ let $t01202512141 = calcUserWeight(boostingContractOrFail(), heightForPeriod, currentPeriod, currentUser)
329+ let userWeight = $t01202512141._1
330+ let userActions = $t01202512141._2
336331 let totalWeightNew = (totalWeight + userWeight)
337332 let processingActions = if (((usersCount - 1) > currentUser))
338333 then [IntegerEntry(keyNextProcessedUser(), (currentUser + 1))]
339334 else [IntegerEntry(keyProcessingStage(), processingStageShares), IntegerEntry(keyNextProcessedUser(), 0)]
340335 $Tuple2((([IntegerEntry(totalWeightKey, totalWeightNew)] ++ processingActions) ++ userActions), true)
341336 }
342337 else if ((processingStage == processingStageShares))
343338 then {
344339 let userWeight = calcUserWeightForClaim(boostingContractOrFail(), heightForPeriod, currentPeriod, currentUser)
345340 let userAmountMatcherForPeriod = fraction(getNumberByKey(keyTotalAmountForPeriod(currentPeriod)), userWeight, totalWeight)
346341 let userAmountEmissionForPeriod = fraction(getNumberByKey(keyAuxEmissionRewardForPeriod(currentPeriod)), userWeight, totalWeight)
347342 let userTotalAmount = (userAmountEmissionForPeriod + userAmountMatcherForPeriod)
348343 let userUnclaimedOption = getInteger(keyUserUnclaimed(currentUser))
349344 let userAddress = getStringValue(boostingContractOrFail(), keyNumToUserMapping(currentUser))
350345 let referrer = getString(referralsContractAddressOrFail, keyReferrer(userAddress))
351346 let activeReferralInv = if ((referrer == unit))
352347 then unit
353348 else invoke(referralsContractAddressOrFail, "updateReferralActivity", [referralProgramName, userAddress, (userWeight >= referralMinGWxAmount)], nil)
354349 if ((activeReferralInv == activeReferralInv))
355350 then {
356351 let referralInv = if (if ((referrer == unit))
357352 then true
358353 else (referralMinGWxAmount > userWeight))
359354 then unit
360355 else {
361356 let referrerReward = fraction(userTotalAmount, referrerRewardPermille, SCALE)
362357 let referralReward = fraction(userTotalAmount, referralRewardPermille, SCALE)
363358 invoke(referralsContractAddressOrFail, "incUnclaimed", [referralProgramName, userAddress, referrerReward, referralReward], nil)
364359 }
365360 if ((referralInv == referralInv))
366361 then {
367362 let unclaimedActions = [IntegerEntry(keyUserUnclaimed(currentUser), (valueOrElse(userUnclaimedOption, 0) + userTotalAmount))]
368363 let processingActions = if (((usersCount - 1) > currentUser))
369364 then [IntegerEntry(keyNextProcessedUser(), (currentUser + 1))]
370365 else [IntegerEntry(keyNextProcessedPeriod(), (currentPeriod + 1)), IntegerEntry(keyNextProcessedUser(), 0), DeleteEntry(keyProcessingStage())]
371366 $Tuple2((unclaimedActions ++ processingActions), true)
372367 }
373368 else throw("Strict value is not equal to itself.")
374369 }
375370 else throw("Strict value is not equal to itself.")
376371 }
377372 else throw("invalid processing stage")
378373 }
379374
380375
381376
382377 @Callable(i)
383378 func finalizeWrapper (counter) = {
384379 let result = {
385380 let @ = invoke(this, "finalizeHelper", nil, nil)
386381 if ($isInstanceOf(@, "Boolean"))
387382 then @
388383 else throw(($getType(invoke(this, "finalizeHelper", nil, nil)) + " couldn't be cast to Boolean"))
389384 }
390385 if ((result == result))
391386 then if (!(result))
392387 then if ((counter == maxDepth))
393388 then throw("Nothing to process")
394389 else $Tuple2(nil, unit)
395390 else if ((counter > 0))
396391 then $Tuple2(nil, invoke(this, "finalizeWrapper", [(counter - 1)], nil))
397392 else $Tuple2(nil, unit)
398393 else throw("Strict value is not equal to itself.")
399394 }
400395
401396
402397
403398 @Callable(i)
404399 func processPendingPeriodsAndUsers () = $Tuple2(nil, invoke(this, "finalizeWrapper", [maxDepth], nil))
405400
406401
407402
408403 @Callable(i)
409404 func deposit () = {
410405 let cfgArray = readConfigArrayOrFail()
411406 if ((i.caller != Address(fromBase58String(cfgArray[IdxCfgPacemakerAddress]))))
412407 then throw("Wrong caller address")
413408 else {
414409 let assetId = value(value(i.payments[0]).assetId)
415410 if ((assetId != fromBase58String(cfgArray[IdxCfgAssetId])))
416411 then throw("Wrong payment asset")
417412 else {
418413 let period = nextPeriod()
419414 let deltaH = (height - getNumberOrFail(keyGwxRewardEmissionStartHeight()))
420415 let emissionRate = valueOrErrorMessage(getInteger(emissionContract, keyRatePerBlockCurrent()), (("mandatory emission_contract." + keyRatePerBlockCurrent()) + " is not defined"))
421416 let weight = valueOrErrorMessage(getInteger(factoryContract, keyPoolWeightVirtual()), (("mandatory factory_contract." + keyPoolWeightVirtual()) + " is not defined"))
422417 let auxAmount = fraction((deltaH * weight), emissionRate, MULT8)
423418 let em = invoke(emissionContract, "emit", [auxAmount], nil)
424419 if ((em == em))
425420 then {
426421 let matcherPart = value(i.payments[0]).amount
427422 let payoutInfo = PeriodPayoutInfo(period, matcherPart, auxAmount)
428423 [IntegerEntry(keyLatestPeriod(), period), IntegerEntry(keyHeightForPeriod(period), height), IntegerEntry(keyAuxEmissionRewardForPeriod(period), auxAmount), IntegerEntry(keyGwxRewardEmissionStartHeight(), height), IntegerEntry(keyTotalAmountForPeriod(period), matcherPart), IntegerEntry(keyNextPeriod(), (period + 1)), StringEntry(keyLastPayoutInfo(), payoutInfo), StringEntry(keyPayoutHistoryInfo(period), payoutInfo)]
429424 }
430425 else throw("Strict value is not equal to itself.")
431426 }
432427 }
433428 }
434429
435430
436431
437432 @Callable(i)
438433 func claimReward () = {
439434 let cfgArray = readConfigArrayOrFail()
440435 let address = toString(i.caller)
441- let $t01754217592 = commonClaimReward(address)
442- let amount = $t01754217592._1
443- let actions = $t01754217592._2
436+ let $t01748317533 = commonClaimReward(address)
437+ let amount = $t01748317533._1
438+ let actions = $t01748317533._2
444439 let checkAmount = if ((amount > 0))
445440 then true
446441 else throw("Nothing to claim")
447442 if ((checkAmount == checkAmount))
448443 then {
449444 let amountFromEmission = 0
450445 let claimedReferral = {
451446 let @ = invoke(referralsContractAddressOrFail, "claim", [referralProgramName], nil)
452447 if ($isInstanceOf(@, "Int"))
453448 then @
454449 else throw(($getType(invoke(referralsContractAddressOrFail, "claim", [referralProgramName], nil)) + " couldn't be cast to Int"))
455450 }
456451 let totalAmount = (amount + claimedReferral)
457452 $Tuple2(([ScriptTransfer(i.caller, totalAmount, fromBase58String(cfgArray[IdxCfgAssetId])), HistoryEntry("claim", address, amount, i)] ++ actions), [totalAmount, amountFromEmission])
458453 }
459454 else throw("Strict value is not equal to itself.")
460455 }
461456
462457
463458
464459 @Callable(i)
465460 func claimRewardREADONLY (address) = {
466- let $t01816518215 = commonClaimReward(address)
467- let amount = $t01816518215._1
468- let actions = $t01816518215._2
461+ let $t01810618156 = commonClaimReward(address)
462+ let amount = $t01810618156._1
463+ let actions = $t01810618156._2
469464 let referralUnclaimed = valueOrElse(getInteger(referralsContractAddressOrFail, keyUnclaimedReferral(referralProgramName, address)), 0)
470465 let totalAmount = (amount + referralUnclaimed)
471466 $Tuple2(nil, totalAmount)
472467 }
473468
474469
475470
476471 @Callable(i)
477472 func latestFinalizedPeriodREADONLY (address) = $Tuple2(nil, valueOrElse(getInteger(this, keyLatestPeriod()), -1))
478473
479474
480475
481476 @Callable(i)
482477 func latestFinalizedPeriodInfoREADONLY (address) = $Tuple2(nil, getStringByKey(keyLastPayoutInfo()))
483478
484479
485480
486481 @Callable(i)
487482 func calcGwxParamsREADONLY (gwxAmountStart,lockStartHeight,lockDurationBlocks) = {
488483 let lockEndHeight = (lockStartHeight + lockDurationBlocks)
489484 let scale8ParamK = -(fraction(gwxAmountStart, SCALE, lockDurationBlocks))
490485 let scale8ParamB = (fraction(gwxAmountStart, SCALE, lockDurationBlocks) * lockEndHeight)
491486 $Tuple2(nil, [scale8ParamK, scale8ParamB, nextPeriod()])
492487 }
493488
494489
495490
496491 @Callable(i)
497492 func calcGwxAmountStartREADONLY (wxLockAmount,lockDuration,maxLockDuration) = {
498493 let coeffX8 = fraction(lockDuration, MULT8, maxLockDuration)
499494 let gWxAmountStart = fraction(wxLockAmount, coeffX8, MULT8)
500495 $Tuple2(nil, [gWxAmountStart])
501496 }
502497
503498
504499
505500 @Callable(i)
506501 func onEmissionForGwxStart () = if ((i.caller != factoryContract))
507502 then throw("permissions denied")
508503 else [IntegerEntry(keyGwxRewardEmissionStartHeight(), height)]
509504
510505
511506
512507 @Callable(i)
513508 func latestPeriodEmissionRewardsREADONLY (address) = {
514509 let period = nextPeriod()
515510 $Tuple2(nil, [getNumberByKey(keyAuxEmissionRewardForPeriod(period))])
516511 }
517512
518513
519514
520515 @Callable(i)
521516 func calcD (x1BigIntStr,x2BigIntStr,ampBigIntStr,aPrecisionBigIntStr,targetPrecisionBigIntStr) = {
522517 let nCoins = toBigInt(2)
523518 let aPrecision = parseBigIntValue(aPrecisionBigIntStr)
524519 let targetPrecision = parseBigIntValue(targetPrecisionBigIntStr)
525520 let x1 = parseBigIntValue(x1BigIntStr)
526521 let x2 = parseBigIntValue(x2BigIntStr)
527522 let amp = (parseBigIntValue(ampBigIntStr) * aPrecision)
528523 let s = (x1 + x2)
529524 if ((s == zeroBigInt))
530525 then $Tuple2(nil, toString(zeroBigInt))
531526 else {
532527 let ann = (amp * nCoins)
533528 let arr = [1, 2, 3, 4, 5, 6, 7]
534529 func calc (acc,cur) = {
535- let $t02083821027 = acc
536- let d = $t02083821027._1
537- let dPrev = $t02083821027._2
530+ let $t02077920968 = acc
531+ let d = $t02077920968._1
532+ let dPrev = $t02077920968._2
538533 let dp = (((d * d) * d) / (((x1 * x2) * nCoins) * nCoins))
539534 let dNext = (((((ann * s) / aPrecision) + (dp * nCoins)) * d) / ((((ann - aPrecision) * d) / aPrecision) + ((nCoins + toBigInt(1)) * dp)))
540535 $Tuple2(dNext, d)
541536 }
542537
543- let $t02124021290 = {
538+ let $t02118121231 = {
544539 let $l = arr
545540 let $s = size($l)
546541 let $acc0 = $Tuple2(s, unit)
547542 func $f0_1 ($a,$i) = if (($i >= $s))
548543 then $a
549544 else calc($a, $l[$i])
550545
551546 func $f0_2 ($a,$i) = if (($i >= $s))
552547 then $a
553548 else throw("List size exceeds 7")
554549
555550 $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7)
556551 }
557- let dNext = $t02124021290._1
558- let dPrev = $t02124021290._2
559- let dDiff = absBigInt((dNext - value(dPrev)))
552+ let dNext = $t02118121231._1
553+ let dPrev = $t02118121231._2
554+ let dDiff = abs((dNext - value(dPrev)))
560555 if ((targetPrecision >= dDiff))
561556 then $Tuple2(nil, toString(dNext))
562557 else throw(("D calculation error, dDiff = " + toString(dDiff)))
563558 }
564- }
565-
566-
567-
568-@Callable(i)
569-func calcPutXOnly (paymentAmountBigIntStr,amountAssetBalanceBigIntStr,priceAssetBalanceBigIntStr,dBigIntStr,amplificatorBigIntStr,amplificatorPrecisionBigIntStr,targetXPrecisionBigIntStr,targetDPrecisionBigIntStr) = {
570- let nCoins = toBigInt(2)
571- let aPrecision = parseBigIntValue(amplificatorPrecisionBigIntStr)
572- let targetPrecision = parseBigIntValue(targetXPrecisionBigIntStr)
573- let X = parseBigIntValue(amountAssetBalanceBigIntStr)
574- let Y = parseBigIntValue(priceAssetBalanceBigIntStr)
575- let d = if ((dBigIntStr == ""))
576- then parseBigIntValue({
577- let @ = invoke(this, "calcD", [amountAssetBalanceBigIntStr, priceAssetBalanceBigIntStr, amplificatorBigIntStr, amplificatorPrecisionBigIntStr, targetDPrecisionBigIntStr], nil)
578- if ($isInstanceOf(@, "String"))
579- then @
580- else throw(($getType(invoke(this, "calcD", [amountAssetBalanceBigIntStr, priceAssetBalanceBigIntStr, amplificatorBigIntStr, amplificatorPrecisionBigIntStr, targetDPrecisionBigIntStr], nil)) + " couldn't be cast to String"))
581- })
582- else parseBigIntValue(dBigIntStr)
583- let amp = (parseBigIntValue(amplificatorBigIntStr) * aPrecision)
584- let S = parseBigIntValue(paymentAmountBigIntStr)
585- let ann = (amp * nCoins)
586- let arr = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
587- func calc (acc,cur) = {
588- let $t02289122911 = acc
589- let x = $t02289122911._1
590- let xPrev = $t02289122911._2
591- let newX = ((X + S) - x)
592- let newY = (Y - ((x * Y) / X))
593- let dp = (((d * d) * d) / (((newX * newY) * nCoins) * nCoins))
594- let xNext = (x + ((((((-(d) * ann) / aPrecision) + d) + ((ann * (newX + newY)) / aPrecision)) - dp) / ((((-(ann) * (toBigInt(-1) - (Y / X))) / aPrecision) + (dp / newX)) + ((Y * dp) / (X * newY)))))
595- $Tuple2(xNext, x)
596- }
597-
598- let $t02321423274 = {
599- let $l = arr
600- let $s = size($l)
601- let $acc0 = $Tuple2(zeroBigInt, unit)
602- func $f0_1 ($a,$i) = if (($i >= $s))
603- then $a
604- else calc($a, $l[$i])
605-
606- func $f0_2 ($a,$i) = if (($i >= $s))
607- then $a
608- else throw("List size exceeds 10")
609-
610- $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)
611- }
612- let xNext = $t02321423274._1
613- let xPrev = $t02321423274._2
614- let xDiff = absBigInt((xNext - value(xPrev)))
615- if ((targetPrecision >= xDiff))
616- then $Tuple2(nil, $Tuple2(toInt(xNext), toInt(fraction(xNext, Y, X))))
617- else throw(((((("X calculation error, xDiff = " + toString(xDiff)) + ", xNext = ") + toString(xNext)) + ", xPrev = ") + toString(value(xPrev))))
618559 }
619560
620561
621562
622563 @Callable(i)
623564 func setManager (pendingManagerPublicKey) = {
624565 let checkCaller = mustManager(i)
625566 if ((checkCaller == checkCaller))
626567 then {
627568 let checkManagerPublicKey = fromBase58String(pendingManagerPublicKey)
628569 if ((checkManagerPublicKey == checkManagerPublicKey))
629570 then [StringEntry(keyPendingManagerPublicKey(), pendingManagerPublicKey)]
630571 else throw("Strict value is not equal to itself.")
631572 }
632573 else throw("Strict value is not equal to itself.")
633574 }
634575
635576
636577
637578 @Callable(i)
638579 func confirmManager () = {
639580 let pm = pendingManagerPublicKeyOrUnit()
640581 let hasPM = if (isDefined(pm))
641582 then true
642583 else throw("No pending manager")
643584 if ((hasPM == hasPM))
644585 then {
645586 let checkPM = if ((i.callerPublicKey == value(pm)))
646587 then true
647588 else throw("You are not pending manager")
648589 if ((checkPM == checkPM))
649590 then [StringEntry(keyManagerPublicKey(), toBase58String(value(pm))), DeleteEntry(keyPendingManagerPublicKey())]
650591 else throw("Strict value is not equal to itself.")
651592 }
652593 else throw("Strict value is not equal to itself.")
653594 }
654595
655596
656597 @Verifier(tx)
657598 func verify () = {
658599 let targetPublicKey = match managerPublicKeyOrUnit() {
659600 case pk: ByteVector =>
660601 pk
661602 case _: Unit =>
662603 tx.senderPublicKey
663604 case _ =>
664605 throw("Match error")
665606 }
666607 sigVerify(tx.bodyBytes, tx.proofs[0], targetPublicKey)
667608 }
668609

github/deemru/w8io/026f985 
101.06 ms