tx · Au35qn3LW4ZRrqtPmTYt4Kxug4GDGtSvURfGQtthm8bZ

3Myn55vLkduxbX3ZXfiDCZhaQsLxYp1kmCy:  -0.02200000 Waves

2022.10.20 11:14 [2280469] smart account 3Myn55vLkduxbX3ZXfiDCZhaQsLxYp1kmCy > SELF 0.00000000 Waves

{ "type": 13, "id": "Au35qn3LW4ZRrqtPmTYt4Kxug4GDGtSvURfGQtthm8bZ", "fee": 2200000, "feeAssetId": null, "timestamp": 1666253672660, "version": 1, "sender": "3Myn55vLkduxbX3ZXfiDCZhaQsLxYp1kmCy", "senderPublicKey": "9W33iCCNfmFxUbiC6XZcH5x7f6xfwC7Jb3BoExT5q2PV", "proofs": [ "5dfgh1WzQyyvAa6Wk45NCmAmvcPvMUFNLRCKq51afY9yGAfs5fA5popjB3UBCKzsjDG2FDdswEJike6PiSV3KBVR" ], "script": "base64:BgKHJAgCEggKBggIAQEBCBIFCgMBCAISAwoBARIDCgEBEgQKAggIEgQKAggIEgMKAQgSAwoBCBIECgIIARIDCgEIEgAiA1NFUCIGU0NBTEU4IgVNVUxUOCIOUE9PTFdFSUdIVE1VTFQiBHN0cmYiB2FkZHJlc3MiA2tleSIDaW96IgNpb2QiCmRlZmF1bHRWYWwiA2lvZiIDYWJzIgN2YWwiA2FhbCIHJG1hdGNoMCIKdmFsQW55THlzdCICYWkiBnZhbEludCIba2V5UmVmZXJyYWxzQ29udHJhY3RBZGRyZXNzIh5yZWZlcnJhbHNDb250cmFjdEFkZHJlc3NPckZhaWwiFmtleVJlZmVycmFsUHJvZ3JhbU5hbWUiGnJlZmVycmFsUHJvZ3JhbU5hbWVEZWZhdWx0IhNyZWZlcnJhbFByb2dyYW1OYW1lIhFrZXlGYWN0b3J5QWRkcmVzcyIYSWR4RmFjdG9yeUNmZ1N0YWtpbmdEYXBwIhlJZHhGYWN0b3J5Q2ZnQm9vc3RpbmdEYXBwIhRJZHhGYWN0b3J5Q2ZnSWRvRGFwcCIVSWR4RmFjdG9yeUNmZ1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UQPY2FsbGVyUHVibGljS2V5CQEFdmFsdWUBBQJlYwYJAAIBAhtZb3UgYXJlIG5vdCBwZW5kaW5nIG1hbmFnZXIDCQAAAgUCZWUFAmVlCQDMCAIJAQtTdHJpbmdFbnRyeQIJAQJhYwAJANgEAQkBBXZhbHVlAQUCZWMJAMwIAgkBC0RlbGV0ZUVudHJ5AQkBAmFkAAUDbmlsCQACAQIkU3RyaWN0IHZhbHVlIGlzIG5vdCBlcXVhbCB0byBpdHNlbGYuCQACAQIkU3RyaWN0IHZhbHVlIGlzIG5vdCBlcXVhbCB0byBpdHNlbGYuAQJlZgECZWcABAJlaAQBbwkBAmF6AAMJAAECBQFvAgpCeXRlVmVjdG9yBAJhRgUBbwUCYUYDCQABAgUBbwIEVW5pdAgFAmVmD3NlbmRlclB1YmxpY0tleQkAAgECC01hdGNoIGVycm9yCQD0AwMIBQJlZglib2R5Qnl0ZXMJAJEDAggFAmVmBnByb29mcwAABQJlaCqHjQ8=", "chainId": 84, "height": 2280469, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: BuHrw8k6RxiXinH9TgDWJnTKVbvvY2EgyiagQYBqjgUq Next: AvCLJowAAydmYuskxvj2EusRRvrZdzvmLnn2wurXzax8 Full:
OldNewDifferences
11 {-# STDLIB_VERSION 6 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let SEP = "__"
55
66 let SCALE8 = 8
77
88 let MULT8 = 100000000
99
1010 let POOLWEIGHTMULT = MULT8
1111
1212 func strf (address,key) = valueOrErrorMessage(getString(address, key), (("mandatory this." + key) + " is not defined"))
1313
1414
1515 func ioz (address,key) = valueOrElse(getInteger(address, key), 0)
1616
1717
1818 func iod (address,key,defaultVal) = valueOrElse(getInteger(address, key), defaultVal)
1919
2020
2121 func iof (address,key) = valueOrErrorMessage(getInteger(address, key), (("mandatory this." + key) + " is not defined"))
2222
2323
2424 func abs (val) = if ((0 > val))
2525 then -(val)
2626 else val
2727
2828
2929 func aal (val) = match val {
3030 case valAnyLyst: List[Any] =>
3131 valAnyLyst
3232 case _ =>
3333 throw("fail to cast into List[Any]")
3434 }
3535
3636
3737 func ai (val) = match val {
3838 case valInt: Int =>
3939 valInt
4040 case _ =>
4141 throw("fail to cast into Int")
4242 }
4343
4444
4545 func keyReferralsContractAddress () = makeString(["%s%s", "config", "referralsContractAddress"], SEP)
4646
4747
4848 let referralsContractAddressOrFail = addressFromStringValue(strf(this, keyReferralsContractAddress()))
4949
5050 let keyReferralProgramName = makeString(["%s%s", "referral", "programName"], SEP)
5151
5252 let referralProgramNameDefault = "wxlock"
5353
5454 let referralProgramName = valueOrElse(getString(this, keyReferralProgramName), referralProgramNameDefault)
5555
5656 func keyFactoryAddress () = "%s%s__config__factoryAddress"
5757
5858
5959 let IdxFactoryCfgStakingDapp = 1
6060
6161 let IdxFactoryCfgBoostingDapp = 2
6262
6363 let IdxFactoryCfgIdoDapp = 3
6464
6565 let IdxFactoryCfgTeamDapp = 4
6666
6767 let IdxFactoryCfgEmissionDapp = 5
6868
6969 let IdxFactoryCfgRestDapp = 6
7070
7171 let IdxFactoryCfgSlippageDapp = 7
7272
7373 let IdxFactoryCfgDaoDapp = 8
7474
7575 let IdxFactoryCfgMarketingDapp = 9
7676
7777 let IdxFactoryCfgGwxRewardDapp = 10
7878
7979 let IdxFactoryCfgBirdsDapp = 11
8080
8181 func keyFactoryCfg () = "%s__factoryConfig"
8282
8383
8484 func keyFactoryLp2AssetsMapping (lpAssetStr) = makeString(["%s%s%s", lpAssetStr, "mappings__lpAsset2PoolContract"], SEP)
8585
8686
8787 func keyFactoryLpList () = "%s__lpTokensList"
8888
8989
9090 func keyFactoryLpAssetToPoolContractAddress (lpAssetStr) = makeString(["%s%s%s", lpAssetStr, "mappings__lpAsset2PoolContract"], SEP)
9191
9292
9393 func keyFactoryPoolWeight (contractAddress) = makeString(["%s%s", "poolWeight", contractAddress], SEP)
9494
9595
9696 func keyFactoryPoolWeightHistory (poolAddress,num) = ((("%s%s__poolWeight__" + poolAddress) + "__") + toString(num))
9797
9898
9999 func readFactoryAddressOrFail () = addressFromStringValue(strf(this, keyFactoryAddress()))
100100
101101
102102 func readLpList () = split(valueOrElse(getString(readFactoryAddressOrFail(), keyFactoryLpList()), ""), SEP)
103103
104104
105105 func readFactoryCfgOrFail (factory) = split(strf(factory, keyFactoryCfg()), SEP)
106106
107107
108108 func getBoostingAddressOrFail (factoryCfg) = addressFromStringValue(factoryCfg[IdxFactoryCfgBoostingDapp])
109109
110110
111111 func getEmissionAddressOrFail (factoryCfg) = addressFromStringValue(factoryCfg[IdxFactoryCfgEmissionDapp])
112112
113113
114114 func getStakingAddressOrFail (factoryCfg) = addressFromStringValue(factoryCfg[IdxFactoryCfgStakingDapp])
115115
116116
117117 func getGwxRewardAddressOrFail (factoryCfg) = addressFromStringValue(factoryCfg[IdxFactoryCfgGwxRewardDapp])
118118
119119
120120 func keyManagerPublicKey () = "%s__managerPublicKey"
121121
122122
123123 func keyPendingManagerPublicKey () = "%s__pendingManagerPublicKey"
124124
125125
126126 func keyEmissionRatePerBlockCurrent () = "%s%s__ratePerBlock__current"
127127
128128
129129 func keyEmissionRatePerBlockMaxCurrent () = "%s%s__ratePerBlockMax__current"
130130
131131
132132 func keyEmissionStartBlock () = "%s%s__emission__startBlock"
133133
134134
135135 func keyEmissionDurationInBlocks () = "%s%s__emission__duration"
136136
137137
138138 func keyEmissionEndBlock () = "%s%s__emission__endBlock"
139139
140140
141141 func keyNextPeriod () = "%s__nextPeriod"
142142
143143
144144 func keyGwxRewardEmissionStartHeight () = "%s%s__gwxRewardEmissionPart__startHeight"
145145
146146
147147 let IdxCfgAssetId = 1
148148
149149 let IdxCfgMinLockAmount = 2
150150
151151 let IdxCfgMinLockDuration = 3
152152
153153 let IdxCfgMaxLockDuration = 4
154154
155155 let IdxCfgMathContract = 5
156156
157157 func keyConfig () = "%s__config"
158158
159159
160160 func readConfigArrayOrFail () = split(strf(this, keyConfig()), SEP)
161161
162162
163163 let mathContract = addressFromStringValue(readConfigArrayOrFail()[IdxCfgMathContract])
164164
165165 func formatConfigS (assetId,minLockAmount,minLockDuration,maxLockDuration,mathContract) = makeString(["%s%d%d%d", assetId, minLockAmount, minLockDuration, maxLockDuration, mathContract], SEP)
166166
167167
168168 func formatConfig (assetId,minLockAmount,minLockDuration,maxLockDuration,mathContract) = formatConfigS(assetId, toString(minLockAmount), toString(minLockDuration), toString(maxLockDuration), mathContract)
169169
170170
171171 func managerPublicKeyOrUnit () = match getString(keyManagerPublicKey()) {
172172 case s: String =>
173173 fromBase58String(s)
174174 case _: Unit =>
175175 unit
176176 case _ =>
177177 throw("Match error")
178178 }
179179
180180
181181 func pendingManagerPublicKeyOrUnit () = match getString(keyPendingManagerPublicKey()) {
182182 case s: String =>
183183 fromBase58String(s)
184184 case _: Unit =>
185185 unit
186186 case _ =>
187187 throw("Match error")
188188 }
189189
190190
191191 func mustManager (i) = {
192192 let pd = throw("Permission denied")
193193 match managerPublicKeyOrUnit() {
194194 case pk: ByteVector =>
195195 if ((i.callerPublicKey == pk))
196196 then true
197197 else pd
198198 case _: Unit =>
199199 if ((i.caller == this))
200200 then true
201201 else pd
202202 case _ =>
203203 throw("Match error")
204204 }
205205 }
206206
207207
208208 let IdxLockUserNum = 1
209209
210210 let IdxLockAmount = 2
211211
212212 let IdxLockStart = 3
213213
214214 let IdxLockDuration = 4
215215
216216 let IdxLockParamK = 5
217217
218218 let IdxLockParamB = 6
219219
220220 func keyLockParamsRecord (userAddress) = makeString(["%s%s__lock", userAddress], SEP)
221221
222222
223223 func readLockParamsRecordOrFail (userAddress) = split(strf(this, keyLockParamsRecord(userAddress)), SEP)
224224
225225
226226 func formatLockParamsRecordS (userNum,amount,start,duration,paramK,paramB,lastUpdTimestamp,gwxAmount) = makeString(["%d%d%d%d%d%d%d%d", userNum, amount, start, duration, paramK, paramB, lastUpdTimestamp, gwxAmount], SEP)
227227
228228
229229 func formatLockParamsRecord (userNum,amount,start,duration,paramK,paramB,gwxAmount) = formatLockParamsRecordS(userNum, toString(amount), toString(start), toString(duration), toString(paramK), toString(paramB), toString(lastBlock.timestamp), toString(gwxAmount))
230230
231231
232232 func keyNextUserNum () = "%s__nextUserNum"
233233
234234
235235 func keyUser2NumMapping (userAddress) = makeString(["%s%s%s__mapping__user2num", userAddress], SEP)
236236
237237
238238 func keyNum2UserMapping (num) = makeString(["%s%s%s__mapping__num2user", num], SEP)
239239
240240
241241 func keyLockParamUserAmount (userNum) = makeString(["%s%d%s__paramByUserNum", userNum, "amount"], SEP)
242242
243243
244244 func keyLockParamStartBlock (userNum) = makeString(["%s%d%s__paramByUserNum", userNum, "start"], SEP)
245245
246246
247247 func keyLockParamDuration (userNum) = makeString(["%s%d%s__paramByUserNum", userNum, "duration"], SEP)
248248
249249
250250 func keyLockParamK (userNum) = makeString(["%s%d%s__paramByUserNum", userNum, "k"], SEP)
251251
252252
253253 func keyLockParamB (userNum) = makeString(["%s%d%s__paramByUserNum", userNum, "b"], SEP)
254254
255255
256256 func keyLockParamByPeriodK (userNum,period) = makeString(["%s%d%s%d__paramByPeriod", userNum, "k", period], SEP)
257257
258258
259259 func keyLockParamByPeriodB (userNum,period) = makeString(["%s%d%s%d__paramByPeriod", userNum, "b", period], SEP)
260260
261261
262262 func keyLockParamTotalAmount () = "%s%s__stats__activeTotalLocked"
263263
264264
265265 func keyStatsLocksDurationSumInBlocks () = "%s%s__stats__locksDurationSumInBlocks"
266266
267267
268268 func keyStatsLocksCount () = "%s%s__stats__locksCount"
269269
270270
271271 func keyStatsUsersCount () = "%s%s__stats__activeUsersCount"
272272
273273
274274 func keyUserBoostEmissionLastINTEGRAL (userNum) = makeString(["%s%d__userBoostEmissionLastInt", userNum], SEP)
275275
276276
277277 func keyUserLpBoostEmissionLastINTEGRAL (userNum,lpAssetId) = makeString(["%s%d__userBoostEmissionLastInt", userNum, lpAssetId], SEP)
278278
279279
280280 func keyUserMaxBoostINTEGRAL (userNum) = makeString(["%s%d__maxBoostInt", userNum], SEP)
281281
282282
283283 func keyTotalMaxBoostINTEGRAL () = "%s%s__maxBoostInt__total"
284284
285285
286286 func keyUserBoostAvalaibleToClaimTotal (userNum) = makeString(["%s%d__userBoostAvaliableToClaimTotal", userNum], SEP)
287287
288288
289289 func keyUserBoostClaimed (userNum) = makeString(["%s%d__userBoostClaimed", userNum], SEP)
290290
291291
292292 func keyTotalCachedGwx () = "%s%s__gwxCached__total"
293293
294294
295295 let factoryContract = readFactoryAddressOrFail()
296296
297297 let factoryCfg = readFactoryCfgOrFail(factoryContract)
298298
299299 let emissionContract = getEmissionAddressOrFail(factoryCfg)
300300
301301 let stakingContract = getStakingAddressOrFail(factoryCfg)
302302
303303 let gwxRewardContract = getGwxRewardAddressOrFail(factoryCfg)
304304
305305 func HistoryEntry (type,user,amount,lockStart,duration,k,b,i) = {
306306 let historyKEY = makeString(["%s%s%s%s__history", type, user, toBase58String(i.transactionId)], SEP)
307307 let historyDATA = makeString(["%d%d%d%d%d%d%d", toString(lastBlock.height), toString(lastBlock.timestamp), toString(amount), toString(lockStart), toString(duration), toString(k), toString(b)], SEP)
308308 StringEntry(historyKEY, historyDATA)
309309 }
310310
311311
312312 func StatsEntry (totalLockedInc,durationInc,lockCountInc,usersCountInc) = {
313313 let locksDurationSumInBlocksKEY = keyStatsLocksDurationSumInBlocks()
314314 let locksCountKEY = keyStatsLocksCount()
315315 let usersCountKEY = keyStatsUsersCount()
316316 let totalAmountKEY = keyLockParamTotalAmount()
317317 let locksDurationSumInBlocks = ioz(this, locksDurationSumInBlocksKEY)
318318 let locksCount = ioz(this, locksCountKEY)
319319 let usersCount = ioz(this, usersCountKEY)
320320 let totalAmount = ioz(this, totalAmountKEY)
321321 [IntegerEntry(locksDurationSumInBlocksKEY, (locksDurationSumInBlocks + durationInc)), IntegerEntry(locksCountKEY, (locksCount + lockCountInc)), IntegerEntry(usersCountKEY, (usersCount + usersCountInc)), IntegerEntry(totalAmountKEY, (totalAmount + totalLockedInc))]
322322 }
323323
324324
325325 func calcGwxAmount (kRaw,bRaw,h) = {
326326 let SCALE = 1000
327327 (((kRaw * h) + bRaw) / SCALE)
328328 }
329329
330330
331331 func LockParamsEntry (userAddress,userNum,amount,start,duration,k,b,period) = {
332332 let userAmountKEY = keyLockParamUserAmount(userNum)
333333 let startBlockKEY = keyLockParamStartBlock(userNum)
334334 let durationKEY = keyLockParamDuration(userNum)
335335 let kKEY = keyLockParamK(userNum)
336336 let bKEY = keyLockParamB(userNum)
337337 let kByPeriodKEY = keyLockParamByPeriodK(userNum, period)
338338 let bByPeriodKEY = keyLockParamByPeriodB(userNum, period)
339339 let gwxAmount = calcGwxAmount(k, b, height)
340340 [IntegerEntry(userAmountKEY, amount), IntegerEntry(startBlockKEY, start), IntegerEntry(durationKEY, duration), IntegerEntry(kKEY, k), IntegerEntry(bKEY, b), IntegerEntry(kByPeriodKEY, k), IntegerEntry(bByPeriodKEY, b), StringEntry(keyLockParamsRecord(userAddress), formatLockParamsRecord(userNum, amount, start, duration, k, b, gwxAmount))]
341341 }
342342
343343
344344 func extractOptionalPaymentAmountOrFail (i,expectedAssetId) = if ((size(i.payments) > 1))
345345 then throw("only one payment is allowed")
346346 else if ((size(i.payments) == 0))
347347 then 0
348348 else {
349349 let pmt = i.payments[0]
350350 if ((value(pmt.assetId) != expectedAssetId))
351351 then throw("invalid asset id in payment")
352352 else pmt.amount
353353 }
354354
355355
356356 func calcUserGwxAmountAtHeight (userAddress,targetHeight) = {
357357 let EMPTY = "empty"
358358 let user2NumMappingKEY = keyUser2NumMapping(userAddress)
359359 let userNum = valueOrElse(getString(user2NumMappingKEY), EMPTY)
360360 let k = valueOrElse(getInteger(keyLockParamK(userNum)), 0)
361361 let b = valueOrElse(getInteger(keyLockParamB(userNum)), 0)
362362 let gwxAmountCalc = calcGwxAmount(k, b, targetHeight)
363363 let gwxAmount = if ((0 > gwxAmountCalc))
364364 then 0
365365 else gwxAmountCalc
366366 gwxAmount
367367 }
368368
369369
370370 func calcCurrentGwxAmount (userAddress) = calcUserGwxAmountAtHeight(userAddress, height)
371371
372372
373373 func internalClaimWxBoost (lpAssetIdStr,userAddressStr,readOnly) = {
374374 let EMPTY = "EMPTY"
375375 let userRecordOrEmpty = valueOrElse(getString(this, keyLockParamsRecord(userAddressStr)), EMPTY)
376376 if ((userRecordOrEmpty == EMPTY))
377377 then $Tuple3(0, nil, "userRecord::is::empty")
378378 else {
379379 let userRecordArray = split(userRecordOrEmpty, SEP)
380380 let userNumStr = userRecordArray[IdxLockUserNum]
381381 let gwxRewardEmissionStartHeight = valueOrElse(getInteger(gwxRewardContract, keyGwxRewardEmissionStartHeight()), 0)
382382 let EMPTYSTR = "empty"
383383 let $t01397714545 = if ((lpAssetIdStr != EMPTYSTR))
384384 then {
385385 let poolAddressStr = valueOrErrorMessage(getString(factoryContract, keyFactoryLp2AssetsMapping(lpAssetIdStr)), ("unsupported lp asset " + lpAssetIdStr))
386386 let pw1 = getIntegerValue(factoryContract, keyFactoryPoolWeight(poolAddressStr))
387387 let pw0 = valueOrElse(getInteger(factoryContract, keyFactoryPoolWeightHistory(poolAddressStr, 0)), pw1)
388388 $Tuple2(pw0, pw1)
389389 }
390390 else if (readOnly)
391391 then $Tuple2(0, 0)
392392 else throw(("not readonly mode: unsupported lp asset " + lpAssetIdStr))
393393 let poolWeight0 = $t01397714545._1
394394 let poolWeight1 = $t01397714545._2
395395 let wxEmissionPerBlock = iof(emissionContract, keyEmissionRatePerBlockCurrent())
396396 let emissionStart = iof(emissionContract, keyEmissionStartBlock())
397397 let emissionEnd = iof(emissionContract, keyEmissionEndBlock())
398398 let h = if ((height > emissionEnd))
399399 then emissionEnd
400400 else height
401401 let dh = max([(h - emissionStart), 0])
402402 let userLpBoostEmissionLastIntegralKEY = keyUserLpBoostEmissionLastINTEGRAL(userNumStr, lpAssetIdStr)
403403 let userBoostEmissionLastIntegralKEY = keyUserBoostEmissionLastINTEGRAL(userNumStr)
404404 let userBoostEmissionLastIntegral = valueOrElse(getInteger(this, userLpBoostEmissionLastIntegralKEY), ioz(this, userBoostEmissionLastIntegralKEY))
405405 let boostEmissionIntegral = (((wxEmissionPerBlock * dh) * 2) / 3)
406406 let userBoostEmissionIntegral = (boostEmissionIntegral - userBoostEmissionLastIntegral)
407407 let udh = fraction(userBoostEmissionIntegral, 3, (2 * wxEmissionPerBlock))
408408 let uLastH = (h - udh)
409409 let udh0 = max([(gwxRewardEmissionStartHeight - uLastH), 0])
410410 let udh1 = ((h - uLastH) - udh0)
411411 if (if (if ((0 > uLastH))
412412 then true
413413 else (0 > udh1))
414414 then true
415415 else (abs(((udh0 + udh1) - udh)) >= 1))
416416 then throw(((((((("invalid udh calc: udh=" + toString(udh)) + " uLastH=") + toString(uLastH)) + " udh0=") + toString(udh0)) + " udh1=") + toString(udh1)))
417417 else if ((0 > userBoostEmissionIntegral))
418418 then throw("wrong calculations")
419419 else {
420420 let userMaxBoostIntegralKEY = keyUserMaxBoostINTEGRAL(userNumStr)
421421 let totalMaxBoostIntegralKEY = keyTotalMaxBoostINTEGRAL()
422422 let userMaxBoostInt = ioz(this, userMaxBoostIntegralKEY)
423423 let totalMaxBoostInt = ioz(this, totalMaxBoostIntegralKEY)
424424 let totalCachedGwxKEY = keyTotalCachedGwx()
425425 let totalCachedGwx = valueOrElse(getInteger(this, totalCachedGwxKEY), 0)
426426 let userCurrGwx = calcCurrentGwxAmount(userAddressStr)
427427 let userBoostAvalaibleToClaimTotalKEY = keyUserBoostAvalaibleToClaimTotal(userNumStr)
428428 let userBoostAvaliableToClaimTotal = ioz(this, userBoostAvalaibleToClaimTotalKEY)
429429 let userBoostEmissionIntegral0 = if ((udh == 0))
430430 then 0
431431 else fraction(userBoostEmissionIntegral, udh0, udh)
432432 let userBoostEmissionIntegral1 = if ((udh == 0))
433433 then 0
434434 else fraction(userBoostEmissionIntegral, udh1, udh)
435435 let poolUserBoostEmissionIntegral0 = fraction(userBoostEmissionIntegral0, poolWeight0, POOLWEIGHTMULT)
436436 let poolUserBoostEmissionIntegral1 = fraction(userBoostEmissionIntegral1, poolWeight1, POOLWEIGHTMULT)
437437 let userBoostAvaliableToClaimTotalNew0 = if ((totalCachedGwx == 0))
438438 then 0
439439 else fraction(poolUserBoostEmissionIntegral0, userCurrGwx, totalCachedGwx)
440440 let userBoostAvaliableToClaimTotalNew1 = if ((totalCachedGwx == 0))
441441 then 0
442442 else fraction(poolUserBoostEmissionIntegral1, userCurrGwx, totalCachedGwx)
443443 let userBoostAvaliableToClaimTotalNew = (userBoostAvaliableToClaimTotalNew0 + userBoostAvaliableToClaimTotalNew1)
444444 let userBoostClaimedKEY = keyUserBoostClaimed(userNumStr)
445445 let userBoostClaimed = ioz(this, userBoostClaimedKEY)
446446 let userBoostAvailable = (userBoostAvaliableToClaimTotalNew - userBoostClaimed)
447447 let dataState = [IntegerEntry(userLpBoostEmissionLastIntegralKEY, boostEmissionIntegral)]
448448 let debug = makeString([toString(userBoostEmissionLastIntegral), toString(userBoostEmissionIntegral), toString(userBoostClaimed), toString(userBoostAvailable), toString(poolWeight0), toString(poolWeight1), toString(h), toString(udh), toString(uLastH), toString(udh0), toString(udh1), toString(userCurrGwx), toString(totalCachedGwx)], ":")
449449 $Tuple3(userBoostAvaliableToClaimTotalNew, dataState, debug)
450450 }
451451 }
452452 }
453453
454454
455455 func lockActions (i,duration) = {
456456 let cfgArray = readConfigArrayOrFail()
457457 let assetIdStr = cfgArray[IdxCfgAssetId]
458458 let assetId = fromBase58String(assetIdStr)
459459 let minLockAmount = parseIntValue(cfgArray[IdxCfgMinLockAmount])
460460 let minLockDuration = parseIntValue(cfgArray[IdxCfgMinLockDuration])
461461 let maxLockDuration = parseIntValue(cfgArray[IdxCfgMaxLockDuration])
462462 if ((size(i.payments) != 1))
463463 then throw("invalid payment - exact one payment must be attached")
464464 else {
465465 let pmt = i.payments[0]
466466 let pmtAmount = pmt.amount
467467 if ((assetId != value(pmt.assetId)))
468468 then throw((("invalid asset is in payment - " + assetIdStr) + " is expected"))
469469 else {
470470 let nextUserNumKEY = keyNextUserNum()
471471 let userAddressStr = toString(i.caller)
472472 let userIsExisting = isDefined(getString(keyUser2NumMapping(userAddressStr)))
473473 let userNumStr = if (userIsExisting)
474474 then value(getString(keyUser2NumMapping(userAddressStr)))
475475 else toString(iof(this, nextUserNumKEY))
476476 let userNum = parseIntValue(userNumStr)
477477 let lockStart = height
478478 let startBlockKEY = keyLockParamStartBlock(userNumStr)
479479 let durationKEY = keyLockParamDuration(userNumStr)
480480 let userAmountKEY = keyLockParamUserAmount(userNumStr)
481481 if ((minLockAmount > pmtAmount))
482482 then throw(("amount is less then minLockAmount=" + toString(minLockAmount)))
483483 else if ((minLockDuration > duration))
484484 then throw(("passed duration is less then minLockDuration=" + toString(minLockDuration)))
485485 else if ((duration > maxLockDuration))
486486 then throw(("passed duration is greater then maxLockDuration=" + toString(maxLockDuration)))
487487 else if (if (userIsExisting)
488488 then ((iof(this, startBlockKEY) + iof(this, durationKEY)) >= lockStart)
489489 else false)
490490 then throw("there is an active lock - consider to use increaseLock")
491491 else if ((ioz(this, userAmountKEY) > 0))
492492 then throw(("there are locked WXs - consider to use increaseLock " + userAmountKEY))
493493 else {
494494 let coeffX8 = fraction(duration, MULT8, maxLockDuration)
495495 let gWxAmountStart = fraction(pmtAmount, coeffX8, MULT8)
496496 let gWxParamsResultList = aal(invoke(mathContract, "calcGwxParamsREADONLY", [gWxAmountStart, lockStart, duration], nil))
497497 let k = ai(gWxParamsResultList[0])
498498 let b = ai(gWxParamsResultList[1])
499499 let period = toString(ai(gWxParamsResultList[2]))
500500 let wxEmissionPerBlock = iof(emissionContract, keyEmissionRatePerBlockCurrent())
501501 let emissionStart = iof(emissionContract, keyEmissionStartBlock())
502502 let emissionEnd = iof(emissionContract, keyEmissionEndBlock())
503503 let h = if ((height > emissionEnd))
504504 then emissionEnd
505505 else height
506506 let dh = max([(h - emissionStart), 0])
507507 let userBoostEmissionLastIntegralKEY = keyUserBoostEmissionLastINTEGRAL(userNumStr)
508508 let boostEmissionIntegral = (((wxEmissionPerBlock * dh) * 2) / 3)
509509 let userMaxBoostIntegralKEY = keyUserMaxBoostINTEGRAL(userNumStr)
510510 let totalMaxBoostIntegralKEY = keyTotalMaxBoostINTEGRAL()
511511 let userMaxBoostInt = ((gWxAmountStart * duration) / 2)
512512 let totalMaxBoostInt = ioz(this, totalMaxBoostIntegralKEY)
513513 let totalCachedGwxKEY = keyTotalCachedGwx()
514514 let totalCachedGwx = valueOrElse(getInteger(this, totalCachedGwxKEY), 0)
515515 let arr = if (userIsExisting)
516516 then nil
517517 else [IntegerEntry(nextUserNumKEY, (userNum + 1)), StringEntry(keyUser2NumMapping(userAddressStr), userNumStr), StringEntry(keyNum2UserMapping(userNumStr), userAddressStr)]
518518 $Tuple2(((((arr ++ LockParamsEntry(userAddressStr, userNumStr, pmtAmount, lockStart, duration, k, b, period)) ++ StatsEntry(pmtAmount, duration, 1, if (userIsExisting)
519519 then 0
520520 else 1)) :+ HistoryEntry("lock", userAddressStr, pmtAmount, lockStart, duration, k, b, i)) ++ [IntegerEntry(userBoostEmissionLastIntegralKEY, boostEmissionIntegral), IntegerEntry(totalCachedGwxKEY, (totalCachedGwx + gWxAmountStart))]), gWxAmountStart)
521521 }
522522 }
523523 }
524524 }
525525
526526
527527 @Callable(i)
528528 func constructor (factoryAddressStr,lockAssetIdStr,minLockAmount,minDuration,maxDuration,mathContract) = {
529529 let checkCaller = mustManager(i)
530530 if ((checkCaller == checkCaller))
531531 then ([IntegerEntry(keyNextUserNum(), 0), StringEntry(keyConfig(), formatConfig(lockAssetIdStr, minLockAmount, minDuration, maxDuration, mathContract)), StringEntry(keyFactoryAddress(), factoryAddressStr)] ++ StatsEntry(0, 0, 0, 0))
532532 else throw("Strict value is not equal to itself.")
533533 }
534534
535535
536536
537537 @Callable(i)
538538 func lockRef (duration,referrerAddress,signature) = {
539539 let $t02298523050 = lockActions(i, duration)
540540 let lockActionsResult = $t02298523050._1
541541 let gWxAmountStart = $t02298523050._2
542542 let referralAddress = toString(i.caller)
543543 let refInv = if (if ((referrerAddress == ""))
544544 then true
545545 else (signature == base58''))
546546 then unit
547547 else invoke(referralsContractAddressOrFail, "createPair", [referralProgramName, referrerAddress, referralAddress, signature], nil)
548548 if ((refInv == refInv))
549549 then {
550550 let updateRefActivity = invoke(mathContract, "updateReferralActivity", [toString(i.caller), gWxAmountStart], nil)
551551 if ((updateRefActivity == updateRefActivity))
552552 then $Tuple2(lockActionsResult, unit)
553553 else throw("Strict value is not equal to itself.")
554554 }
555555 else throw("Strict value is not equal to itself.")
556556 }
557557
558558
559559
560560 @Callable(i)
561561 func lock (duration) = {
562562 let $t02350823573 = lockActions(i, duration)
563563 let lockActionsResult = $t02350823573._1
564564 let gWxAmountStart = $t02350823573._2
565565 let updateRefActivity = invoke(mathContract, "updateReferralActivity", [toString(i.caller), gWxAmountStart], nil)
566566 if ((updateRefActivity == updateRefActivity))
567567 then $Tuple2(lockActionsResult, unit)
568568 else throw("Strict value is not equal to itself.")
569569 }
570570
571571
572572
573573 @Callable(i)
574574 func increaseLock (deltaDuration) = {
575575 let cfgArray = readConfigArrayOrFail()
576576 let assetIdStr = cfgArray[IdxCfgAssetId]
577577 let assetId = fromBase58String(assetIdStr)
578578 let minLockDuration = parseIntValue(cfgArray[IdxCfgMinLockDuration])
579579 let maxLockDuration = parseIntValue(cfgArray[IdxCfgMaxLockDuration])
580580 let pmtAmount = extractOptionalPaymentAmountOrFail(i, assetId)
581581 let userAddressStr = toString(i.caller)
582582 let userRecordArray = readLockParamsRecordOrFail(userAddressStr)
583583 let userNumStr = userRecordArray[IdxLockUserNum]
584584 let userAmount = parseIntValue(userRecordArray[IdxLockAmount])
585585 let lockStart = parseIntValue(userRecordArray[IdxLockStart])
586586 let lockDuration = parseIntValue(userRecordArray[IdxLockDuration])
587587 let lockEnd = (lockStart + lockDuration)
588588 let remainingDuration = max([(lockEnd - height), 0])
589589 let userAmountNew = (userAmount + pmtAmount)
590590 let lockDurationNew = (remainingDuration + deltaDuration)
591591 if ((0 > deltaDuration))
592592 then throw("duration is less then zero")
593593 else if ((minLockDuration > lockDurationNew))
594594 then throw(("lockDurationNew is less then minLockDuration=" + toString(minLockDuration)))
595595 else if ((lockDurationNew > maxLockDuration))
596596 then throw(("deltaDuration + existedLockDuration is greater then maxLockDuration=" + toString(maxLockDuration)))
597597 else {
598598 let coeffX8 = fraction(lockDurationNew, MULT8, maxLockDuration)
599599 let gWxAmountStart = fraction(userAmountNew, coeffX8, MULT8)
600600 let updateRefActivity = invoke(mathContract, "updateReferralActivity", [toString(i.caller), gWxAmountStart], nil)
601601 if ((updateRefActivity == updateRefActivity))
602602 then {
603603 let lockStartNew = height
604604 let gWxParamsResultList = aal(invoke(mathContract, "calcGwxParamsREADONLY", [gWxAmountStart, lockStartNew, lockDurationNew], nil))
605605 let k = ai(gWxParamsResultList[0])
606606 let b = ai(gWxParamsResultList[1])
607607 let period = toString(ai(gWxParamsResultList[2]))
608608 let wxEmissionPerBlock = iof(emissionContract, keyEmissionRatePerBlockCurrent())
609609 let emissionStart = iof(emissionContract, keyEmissionStartBlock())
610610 let emissionEnd = iof(emissionContract, keyEmissionEndBlock())
611611 let h = if ((height > emissionEnd))
612612 then emissionEnd
613613 else height
614614 let dh = max([(h - emissionStart), 0])
615615 let userBoostEmissionLastIntegralKEY = keyUserBoostEmissionLastINTEGRAL(userNumStr)
616616 let userBoostEmissionLastIntegral = ioz(this, userBoostEmissionLastIntegralKEY)
617617 let boostEmissionIntegral = (((wxEmissionPerBlock * dh) * 2) / 3)
618618 let userBoostEmissionIntegral = (boostEmissionIntegral - userBoostEmissionLastIntegral)
619619 if ((0 > userBoostEmissionIntegral))
620620 then throw("wrong calculations")
621621 else {
622622 let userMaxBoostIntegralKEY = keyUserMaxBoostINTEGRAL(userNumStr)
623623 let totalMaxBoostIntegralKEY = keyTotalMaxBoostINTEGRAL()
624624 let userMaxBoostInt = ioz(this, userMaxBoostIntegralKEY)
625625 let totalMaxBoostInt = ioz(this, totalMaxBoostIntegralKEY)
626626 let currUserGwx = calcCurrentGwxAmount(userAddressStr)
627627 let gwxDiff = (gWxAmountStart - currUserGwx)
628628 if ((0 > gwxDiff))
629629 then throw(("gwxDiff is less then 0: " + toString(gwxDiff)))
630630 else {
631631 let totalCachedGwxKEY = keyTotalCachedGwx()
632632 let totalCachedGwx = valueOrElse(getInteger(this, totalCachedGwxKEY), 0)
633633 let userBoostAvalaibleToClaimTotalKEY = keyUserBoostAvalaibleToClaimTotal(userNumStr)
634634 let userBoostAvaliableToClaimTotal = ioz(this, userBoostAvalaibleToClaimTotalKEY)
635635 let userBoostAvaliableToClaimTotalNew = fraction(userBoostEmissionIntegral, currUserGwx, totalCachedGwx)
636636 let userMaxBoostIntNew = ((gWxAmountStart * lockDurationNew) / 2)
637637 let remainingUserMaxBoostInt = ((currUserGwx * remainingDuration) / 2)
638638 let userMaxBoostIntDiff = (userMaxBoostIntNew - remainingUserMaxBoostInt)
639639 (((LockParamsEntry(userAddressStr, userNumStr, userAmountNew, lockStartNew, lockDurationNew, k, b, period) ++ StatsEntry(pmtAmount, deltaDuration, 0, 0)) :+ HistoryEntry("lock", userAddressStr, pmtAmount, lockStart, lockDurationNew, k, b, i)) ++ [IntegerEntry(totalCachedGwxKEY, (totalCachedGwx + gwxDiff))])
640640 }
641641 }
642642 }
643643 else throw("Strict value is not equal to itself.")
644644 }
645645 }
646646
647647
648648
649649 @Callable(i)
650650 func claimWxBoost (lpAssetIdStr,userAddressStr) = if ((stakingContract != i.caller))
651651 then throw("permissions denied")
652652 else {
653653 let $t02855228654 = internalClaimWxBoost(lpAssetIdStr, userAddressStr, false)
654654 let userBoostAvailable = $t02855228654._1
655655 let dataState = $t02855228654._2
656656 let debug = $t02855228654._3
657657 $Tuple2(dataState, [userBoostAvailable])
658658 }
659659
660660
661661
662662 @Callable(i)
663663 func claimWxBoostREADONLY (lpAssetIdStr,userAddressStr) = {
664664 let $t02878628887 = internalClaimWxBoost(lpAssetIdStr, userAddressStr, true)
665665 let userBoostAvailable = $t02878628887._1
666666 let dataState = $t02878628887._2
667667 let debug = $t02878628887._3
668668 $Tuple2(nil, [userBoostAvailable, debug])
669669 }
670670
671671
672672
673673 @Callable(i)
674674 func unlock (userAddress) = {
675675 let userRecordArray = readLockParamsRecordOrFail(userAddress)
676676 let userNumStr = userRecordArray[IdxLockUserNum]
677677 let userAmount = parseIntValue(userRecordArray[IdxLockAmount])
678678 let lockStart = parseIntValue(userRecordArray[IdxLockStart])
679679 let lockDuration = parseIntValue(userRecordArray[IdxLockDuration])
680680 let lockEnd = (lockStart + lockDuration)
681681 let cfgArray = readConfigArrayOrFail()
682682 let assetId = fromBase58String(cfgArray[IdxCfgAssetId])
683683 if ((lockEnd >= height))
684684 then throw((("wait " + toString(lockEnd)) + " to unlock"))
685685 else if ((0 >= userAmount))
686686 then throw("nothing to unlock")
687687 else {
688688 let period = valueOrElse(getInteger(mathContract, keyNextPeriod()), 0)
689689 (((LockParamsEntry(userAddress, userNumStr, 0, lockStart, lockDuration, 0, 0, toString(period)) ++ StatsEntry(-(userAmount), 0, 0, -1)) :+ HistoryEntry("unlock", userAddress, userAmount, lockStart, lockDuration, 0, 0, i)) :+ ScriptTransfer(addressFromStringValue(userAddress), userAmount, assetId))
690690 }
691691 }
692692
693693
694694
695695 @Callable(i)
696696 func gwxUserInfoREADONLY (userAddress) = {
697697 let gwxAmount = calcCurrentGwxAmount(userAddress)
698698 $Tuple2(nil, [gwxAmount])
699699 }
700700
701701
702702
703703 @Callable(i)
704704 func getUserGwxAmountAtHeightREADONLY (userAddress,targetHeight) = {
705705 let gwxAmount = calcUserGwxAmountAtHeight(userAddress, targetHeight)
706706 $Tuple2(nil, gwxAmount)
707707 }
708708
709709
710710
711711 @Callable(i)
712712 func setManager (pendingManagerPublicKey) = {
713713 let checkCaller = mustManager(i)
714714 if ((checkCaller == checkCaller))
715715 then {
716716 let checkManagerPublicKey = fromBase58String(pendingManagerPublicKey)
717717 if ((checkManagerPublicKey == checkManagerPublicKey))
718718 then [StringEntry(keyPendingManagerPublicKey(), pendingManagerPublicKey)]
719719 else throw("Strict value is not equal to itself.")
720720 }
721721 else throw("Strict value is not equal to itself.")
722722 }
723723
724724
725725
726726 @Callable(i)
727727 func confirmManager () = {
728728 let pm = pendingManagerPublicKeyOrUnit()
729729 let hasPM = if (isDefined(pm))
730730 then true
731731 else throw("No pending manager")
732732 if ((hasPM == hasPM))
733733 then {
734734 let checkPM = if ((i.callerPublicKey == value(pm)))
735735 then true
736736 else throw("You are not pending manager")
737737 if ((checkPM == checkPM))
738738 then [StringEntry(keyManagerPublicKey(), toBase58String(value(pm))), DeleteEntry(keyPendingManagerPublicKey())]
739739 else throw("Strict value is not equal to itself.")
740740 }
741741 else throw("Strict value is not equal to itself.")
742742 }
743743
744744
745745 @Verifier(tx)
746746 func verify () = {
747747 let targetPublicKey = match managerPublicKeyOrUnit() {
748748 case pk: ByteVector =>
749749 pk
750750 case _: Unit =>
751751 tx.senderPublicKey
752752 case _ =>
753753 throw("Match error")
754754 }
755755 sigVerify(tx.bodyBytes, tx.proofs[0], targetPublicKey)
756756 }
757757

github/deemru/w8io/026f985 
60.24 ms