tx · 7y5XY6KPk569UiDZiQ4XAKAL1s8YBBWxiCFLVWh3Rf8Y 3MsXpzisJAwnzUr7XrEoW1BZo4U6rw4tsYK: -0.14000000 Waves 2022.11.09 17:02 [2309690] smart account 3MsXpzisJAwnzUr7XrEoW1BZo4U6rw4tsYK > SELF 0.00000000 Waves
{ "type": 13, "id": "7y5XY6KPk569UiDZiQ4XAKAL1s8YBBWxiCFLVWh3Rf8Y", "fee": 14000000, "feeAssetId": null, "timestamp": 1668002628498, "version": 2, "chainId": 84, "sender": "3MsXpzisJAwnzUr7XrEoW1BZo4U6rw4tsYK", "senderPublicKey": "FFdBua5rzzMkZebvsvmN7sAdU7XhFK8QNJ3hiwwxAYRA", "proofs": [ "4TCpgCsYjyw2y1qRHqLxdxfXjmBigLxSXxDVork9CqoMcX1Z9YRAfNCcJHwiMgjK7wzZj3mdndxoQNHzLxRQ21HD", "3dHkbSZyVfqMVvi73oo4jFL1GbzQwgYcdj9dNvVCUBxNyfaJKL3o2n4TQw8bfGKXf8g4gv7pWXEA8Dn76B58fkPR" ], "script": "base64:BgJICAISAwoBCBIDCgEIEgMKAQgSBAoCCAESBQoDCAEBEgQKAggIEgQKAggBEgMKAQgSAwoBCBIDCgEYEgMKARgSBAoCCAgSABIAWwAHa0FjdGl2ZQIGYWN0aXZlAAtrQWN0aXZlR2xvYgIUYWN0aXZlX2FsbF9jb250cmFjdHMABmtDYXVzZQIOc2h1dGRvd25fY2F1c2UAGmtSZXdhcmRQb29sRnJhY3Rpb25DdXJyZW50Ah1fY3VycmVudF9wb29sX2ZyYWN0aW9uX3Jld2FyZAAba1Jld2FyZFBvb2xGcmFjdGlvblByZXZpb3VzAh5fcHJldmlvdXNfcG9vbF9mcmFjdGlvbl9yZXdhcmQAE2tIZWlnaHRQb29sRnJhY3Rpb24CGl9wb29sX3Jld2FyZF91cGRhdGVfaGVpZ2h0ABtrVG90YWxSZXdhcmRQZXJCbG9ja0N1cnJlbnQCHnRvdGFsX3Jld2FyZF9wZX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gkAzAgCCQELRGVsZXRlRW50cnkBBQZrQ2F1c2UFA25pbAECdHgBBnZlcmlmeQAEByRtYXRjaDAFAnR4BBJhZG1pblB1YktleTFTaWduZWQDCQD0AwMIBQJ0eAlib2R5Qnl0ZXMJAJEDAggFAnR4BnByb29mcwAABQxhZG1pblB1YktleTEAAQAABBJhZG1pblB1YktleTJTaWduZWQDCQD0AwMIBQJ0eAlib2R5Qnl0ZXMJAJEDAggFAnR4BnByb29mcwABBQxhZG1pblB1YktleTIAAQAABBJhZG1pblB1YktleTNTaWduZWQDCQD0AwMIBQJ0eAlib2R5Qnl0ZXMJAJEDAggFAnR4BnByb29mcwACBQxhZG1pblB1YktleTMAAQAACQBnAgkAZAIJAGQCBRJhZG1pblB1YktleTFTaWduZWQFEmFkbWluUHViS2V5MlNpZ25lZAUSYWRtaW5QdWJLZXkzU2lnbmVkAAJ5yNOr", "height": 2309690, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: FsUpaZ4TduW31oXp5aKKnT2VAkGGvkE3hyZMd5D1Yp56 Next: 6zVi6BTvYbU4WKhNRX3HEQ6tS4RXpFXQts7R7jFgMW1G Diff:
Old | New | Differences | |
---|---|---|---|
137 | 137 | ||
138 | 138 | let periodLength = valueOrErrorMessage(getInteger(votingAddress, kPeriodLength), "Empty kPeriodLength") | |
139 | 139 | ||
140 | - | let currPeriod = (basePeriod + ((height - startHeight) / periodLength)) | |
141 | - | ||
142 | 140 | let active = getBooleanValue(this, kActive) | |
143 | 141 | ||
144 | 142 | let activeGlob = valueOrElse(getBoolean(oracle, kActiveGlob), true) | |
239 | 237 | func calcInterest (pool,lastInterestHeight,rewardUpdateHeight,poolRewardUpdateHeight,farmInterest,boostInterest,poolVoted,boostLpInterest,currentRewardPerBlock,shareTokenLocked,previousRewardPerBlock,scaleValue) = if ((shareTokenLocked == 0)) | |
240 | 238 | then $Tuple3(0, 0, 0) | |
241 | 239 | else { | |
242 | - | let $ | |
240 | + | let $t01035711794 = if (if (if ((rewardUpdateHeight > height)) | |
243 | 241 | then (rewardUpdateHeight == poolRewardUpdateHeight) | |
244 | 242 | else false) | |
245 | 243 | then true | |
273 | 271 | let rwd = (currentRewardPerBlock * (height - rewardUpdateHeight)) | |
274 | 272 | $Tuple4(rwd, fBfrUp, bBfrUp, bLPBfrUp) | |
275 | 273 | } | |
276 | - | let reward = $ | |
277 | - | let farmIntrBefore = $ | |
278 | - | let boostIntrBefore = $ | |
279 | - | let boostLPIntrBefore = $ | |
274 | + | let reward = $t01035711794._1 | |
275 | + | let farmIntrBefore = $t01035711794._2 | |
276 | + | let boostIntrBefore = $t01035711794._3 | |
277 | + | let boostLPIntrBefore = $t01035711794._4 | |
280 | 278 | let newFarmInterest = (farmIntrBefore + fraction(calcFarmRwd(pool, reward), scaleValue, shareTokenLocked)) | |
281 | 279 | let newBoostInterest = (boostIntrBefore + (if ((poolVoted > 0)) | |
282 | 280 | then fraction(calcBoostRwd(pool, reward), scaleValue8, poolVoted) | |
296 | 294 | let uPoolVoted = getUserPoolVoted(pool, user) | |
297 | 295 | let shareToken = getTotalShareToken(pool) | |
298 | 296 | let totalShareVirtual = valueOrElse(getInteger(this, (pool + kShareTokensVirtual)), shareToken) | |
299 | - | let $ | |
300 | - | let lastInterestHeight = $ | |
301 | - | let farmInterest = $ | |
302 | - | let boostInterest = $ | |
303 | - | let boostLPInterest = $ | |
304 | - | let $ | |
305 | - | let currentRewardPerBlock = $ | |
306 | - | let rewardUpdateHeight = $ | |
307 | - | let previousRewardPerBlock = $ | |
308 | - | let poolRewardUpdateHeight = $ | |
297 | + | let $t01276712865 = getLastInterestInfo(pool) | |
298 | + | let lastInterestHeight = $t01276712865._1 | |
299 | + | let farmInterest = $t01276712865._2 | |
300 | + | let boostInterest = $t01276712865._3 | |
301 | + | let boostLPInterest = $t01276712865._4 | |
302 | + | let $t01287012984 = rewardInfo(pool) | |
303 | + | let currentRewardPerBlock = $t01287012984._1 | |
304 | + | let rewardUpdateHeight = $t01287012984._2 | |
305 | + | let previousRewardPerBlock = $t01287012984._3 | |
306 | + | let poolRewardUpdateHeight = $t01287012984._4 | |
309 | 307 | let uFarmInterest = valueOrElse(getInteger(this, (((pool + "_") + user) + kFarmUserLastInterest)), farmInterest) | |
310 | 308 | let uBoostInterest = valueOrElse(getInteger(this, (((pool + "_") + user) + kBoostUserLastInterest)), boostInterest) | |
311 | 309 | let uBoostLPInterest = valueOrElse(getInteger(this, (((pool + "_") + user) + kBoostLPUserLastInterest)), boostLPInterest) | |
312 | 310 | let uShareTokensStaked = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensStaked)), 0) | |
313 | 311 | let uShareTokensVirt = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensVirtual)), uShareTokensStaked) | |
314 | - | let $ | |
315 | - | let newFarmInterest = $ | |
316 | - | let newBoostInterest = $ | |
317 | - | let newBoostLPInterest = $ | |
312 | + | let $t01355213945 = calcInterest(pool, lastInterestHeight, rewardUpdateHeight, poolRewardUpdateHeight, farmInterest, boostInterest, poolVoted, boostLPInterest, currentRewardPerBlock, totalShareVirtual, previousRewardPerBlock, scaleValue) | |
313 | + | let newFarmInterest = $t01355213945._1 | |
314 | + | let newBoostInterest = $t01355213945._2 | |
315 | + | let newBoostLPInterest = $t01355213945._3 | |
318 | 316 | let claimFarming = fraction(uShareTokensVirt, (newFarmInterest - uFarmInterest), scaleValue) | |
319 | 317 | let claimBoostingMax = fraction(uPoolVoted, (newBoostInterest - uBoostInterest), scaleValue8) | |
320 | 318 | let mul = fraction(toBigInt(uShareTokensVirt), toBigInt(uPoolVoted), toBigInt(1)) | |
328 | 326 | ||
329 | 327 | func availableClaimCalcAllByUser (pools,user) = { | |
330 | 328 | func calcAvailable (acc,pool) = { | |
331 | - | let $ | |
332 | - | let newPools = $ | |
333 | - | let amounts = $ | |
334 | - | let $ | |
335 | - | let fi = $ | |
336 | - | let bi = $ | |
337 | - | let blpi = $ | |
338 | - | let claimAmount = $ | |
339 | - | let tt = $ | |
329 | + | let $t01475614785 = acc | |
330 | + | let newPools = $t01475614785._1 | |
331 | + | let amounts = $t01475614785._2 | |
332 | + | let $t01479414853 = claimCalc(pool, user) | |
333 | + | let fi = $t01479414853._1 | |
334 | + | let bi = $t01479414853._2 | |
335 | + | let blpi = $t01479414853._3 | |
336 | + | let claimAmount = $t01479414853._4 | |
337 | + | let tt = $t01479414853._5 | |
340 | 338 | let availableFund = (userAvailableSWOP(pool, user) + claimAmount) | |
341 | - | $Tuple2((newPools :+ | |
339 | + | $Tuple2((newPools :+ pool), (amounts :+ availableFund)) | |
342 | 340 | } | |
343 | 341 | ||
344 | 342 | let $l = pools | |
359 | 357 | func canLockInFirstHarvest (pool,user,userShareTokensStaked,pmtAmount,lockType) = if ((getHeightFirstHarvest(pool) > height)) | |
360 | 358 | then { | |
361 | 359 | let totalVoteAmount = valueOrElse(getInteger(votingAddress, (pool + kHarvestPoolVote)), 0) | |
362 | - | let userVoteAmount = valueOrElse(getInteger(votingAddress, (((user + "_") + pool) + | |
360 | + | let userVoteAmount = valueOrElse(getInteger(votingAddress, (((user + "_") + pool) + kHarvestUserPoolVote)), 0) | |
363 | 361 | let FHShareTokenLimit = getFHShareLimitToken(addressFromStringValue(pool)) | |
364 | 362 | let FHShareTokenUserLimit = (fraction(FHShareTokenLimit, userVoteAmount, totalVoteAmount) - userShareTokensStaked) | |
365 | 363 | if ((lockType > 0)) | |
416 | 414 | then throw("Only Governance can call this function") | |
417 | 415 | else { | |
418 | 416 | let user = toString(addressFromPublicKey(adminInvokePubKey)) | |
419 | - | let $ | |
420 | - | let farmInterest = $ | |
421 | - | let boostInterest = $ | |
422 | - | let boostLPinterest = $ | |
417 | + | let $t01758917663 = claimCalc(pool, user) | |
418 | + | let farmInterest = $t01758917663._1 | |
419 | + | let boostInterest = $t01758917663._2 | |
420 | + | let boostLPinterest = $t01758917663._3 | |
423 | 421 | [IntegerEntry((pool + kFarmLastInterest), farmInterest), IntegerEntry((pool + kBoostLastInterest), boostInterest), IntegerEntry((pool + kBoostLPLastInterest), boostLPinterest), IntegerEntry((pool + kLastInterestHeight), height)] | |
424 | 422 | }) | |
425 | 423 | ||
436 | 434 | let userLockedAmount = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensLocked)), 0) | |
437 | 435 | let userAmountVirtual = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensVirtual)), userStakedAmount) | |
438 | 436 | let totalUserShareTokens = ((userStakedAmount + userLockedAmount) + i.payments[0].amount) | |
439 | - | let $ | |
440 | - | let lockPeriod = $ | |
441 | - | let lockCoef = $ | |
437 | + | let $t01877218824 = getLockParams(lockType) | |
438 | + | let lockPeriod = $t01877218824._1 | |
439 | + | let lockCoef = $t01877218824._2 | |
442 | 440 | let lockWavesFee = getIntegerValue(this, kLockWavesFee) | |
443 | 441 | if ((i.payments[0].assetId != shareAssetId)) | |
444 | 442 | then throw("Wrong sharetoken in payment") | |
450 | 448 | let shareTokensChangeOnFH = canLockInFirstHarvest(pool, user, userStakedAmount, i.payments[0].amount, lockType) | |
451 | 449 | if ((shareTokensChangeOnFH == shareTokensChangeOnFH)) | |
452 | 450 | then { | |
453 | - | let $ | |
451 | + | let $t01925121193 = if ((lockType == 0)) | |
454 | 452 | then { | |
455 | 453 | let userAmountVirtualNew = ((userAmountVirtual + i.payments[0].amount) - shareTokensChangeOnFH) | |
456 | - | $Tuple2([IntegerEntry((((pool + "_") + user) + kUserShareTokensStaked), ((userStakedAmount + i.payments[0].amount) - shareTokensChangeOnFH)), IntegerEntry((pool + kShareTokensVirtual), ((totalShareVirtual + i.payments[0].amount) - shareTokensChangeOnFH)), ScriptTransfer(i.originCaller, shareTokensChangeOnFH, i.payments[0].assetId)], ((totalShare + i.payments[0].amount) - shareTokensChangeOnFH)) | |
454 | + | $Tuple2([IntegerEntry((((pool + "_") + user) + kUserShareTokensStaked), ((userStakedAmount + i.payments[0].amount) - shareTokensChangeOnFH)), IntegerEntry((((pool + "_") + user) + kUserShareTokensVirtual), userAmountVirtualNew), IntegerEntry((pool + kShareTokensVirtual), ((totalShareVirtual + i.payments[0].amount) - shareTokensChangeOnFH)), ScriptTransfer(i.originCaller, shareTokensChangeOnFH, i.payments[0].assetId)], ((totalShare + i.payments[0].amount) - shareTokensChangeOnFH)) | |
457 | 455 | } | |
458 | 456 | else if (if ((userLockedHeigt == 0)) | |
459 | 457 | then if (if ((2 > size(i.payments))) | |
471 | 469 | let userAmountVirtualNew = (fraction(userLockedAmountNew, lockCoef, lockBoostCoefScale) + userStakedAmount) | |
472 | 470 | $Tuple2([IntegerEntry((((pool + "_") + user) + kUserShareTokensLocked), userLockedAmountNew), IntegerEntry((((pool + "_") + user) + kUserShareTokensLockedHeight), userLockedHeigtNew), IntegerEntry((((pool + "_") + user) + kUserShareTokensLockedType), lockType), IntegerEntry((((pool + "_") + user) + kUserShareTokensVirtual), userAmountVirtualNew), IntegerEntry((pool + kShareTokensVirtual), ((totalShareVirtual - userAmountVirtual) + userAmountVirtualNew))], (totalShare + i.payments[0].amount)) | |
473 | 471 | } | |
474 | - | let lockEntries = $ | |
475 | - | let totalShareNew = $ | |
472 | + | let lockEntries = $t01925121193._1 | |
473 | + | let totalShareNew = $t01925121193._2 | |
476 | 474 | if ((accountBalance(shareAssetId) > totalShareNew)) | |
477 | 475 | then throw("Balance of share-token is lower than totalAmount") | |
478 | 476 | else { | |
479 | - | let $ | |
480 | - | let farmInterest = $ | |
481 | - | let boostInterest = $ | |
482 | - | let boostLPinterest = $ | |
483 | - | let claimAmount = $ | |
484 | - | let toTreasure = $ | |
477 | + | let $t02131821417 = claimCalc(pool, user) | |
478 | + | let farmInterest = $t02131821417._1 | |
479 | + | let boostInterest = $t02131821417._2 | |
480 | + | let boostLPinterest = $t02131821417._3 | |
481 | + | let claimAmount = $t02131821417._4 | |
482 | + | let toTreasure = $t02131821417._5 | |
485 | 483 | let availableFundsNew = (userAvailableSWOP(pool, user) + claimAmount) | |
486 | 484 | let uplp = if ((getString(Address(fromBase58String(pool)), "version") == "3.0.0")) | |
487 | 485 | then invoke(lpFarmingAddress, "updateUserInterest", [pool, totalUserShareTokens], nil) | |
508 | 506 | let userLockedAmount = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensLocked)), 0) | |
509 | 507 | let userAmountVirtual = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensVirtual)), userStakedAmount) | |
510 | 508 | let totalUserShareTokens = (userStakedAmount + userLockedAmount) | |
511 | - | let $ | |
512 | - | let lockPeriod = $ | |
513 | - | let lockCoef = $ | |
509 | + | let $t02331923371 = getLockParams(lockType) | |
510 | + | let lockPeriod = $t02331923371._1 | |
511 | + | let lockCoef = $t02331923371._2 | |
514 | 512 | let lockWavesFee = getIntegerValue(this, kLockWavesFee) | |
515 | 513 | if ((getHeightFirstHarvest(pool) > height)) | |
516 | 514 | then throw("You can't lock shareTokens till first harvest end.") | |
541 | 539 | let userStakedAmountNew = (userStakedAmount - lockAmount) | |
542 | 540 | let userLockedHeigtNew = (height + lockPeriod) | |
543 | 541 | let userAmountVirtualNew = (fraction(userLockedAmountNew, lockCoef, lockBoostCoefScale) + userStakedAmount) | |
544 | - | let $ | |
545 | - | let farmInterest = $ | |
546 | - | let boostInterest = $ | |
547 | - | let boostLPinterest = $ | |
548 | - | let claimAmount = $ | |
549 | - | let toTreasure = $ | |
542 | + | let $t02465824757 = claimCalc(pool, user) | |
543 | + | let farmInterest = $t02465824757._1 | |
544 | + | let boostInterest = $t02465824757._2 | |
545 | + | let boostLPinterest = $t02465824757._3 | |
546 | + | let claimAmount = $t02465824757._4 | |
547 | + | let toTreasure = $t02465824757._5 | |
550 | 548 | let availableFundsNew = (userAvailableSWOP(pool, user) + claimAmount) | |
551 | 549 | [IntegerEntry((((pool + "_") + user) + kUserShareTokensStaked), userStakedAmountNew), IntegerEntry((((pool + "_") + user) + kUserShareTokensLocked), userLockedAmountNew), IntegerEntry((((pool + "_") + user) + kUserShareTokensLockedHeight), userLockedHeigtNew), IntegerEntry((((pool + "_") + user) + kUserShareTokensLockedType), lockType), IntegerEntry((((pool + "_") + user) + kUserShareTokensVirtual), userAmountVirtualNew), IntegerEntry((pool + kShareTokensVirtual), ((totalShareVirtual - userAmountVirtual) + userAmountVirtualNew)), IntegerEntry((((pool + "_") + user) + kFarmUserLastInterest), farmInterest), IntegerEntry((((pool + "_") + user) + kBoostUserLastInterest), boostInterest), IntegerEntry((((pool + "_") + user) + kBoostLPUserLastInterest), boostLPinterest), IntegerEntry((pool + kFarmLastInterest), farmInterest), IntegerEntry((pool + kBoostLastInterest), boostInterest), IntegerEntry((pool + kBoostLPLastInterest), boostLPinterest), IntegerEntry((pool + kLastInterestHeight), height), IntegerEntry((((pool + "_") + user) + kAvailableSWOP), availableFundsNew), Reissue(SWOP, toTreasure, true), ScriptTransfer(farmingTreasureAddr, toTreasure, SWOP)] | |
552 | 550 | } | |
566 | 564 | then throw(("You can't unlock sharetokens till " + toString(userLockedHeigt))) | |
567 | 565 | else { | |
568 | 566 | let userStakedAmountNew = (userStakedAmount + userLockedAmount) | |
569 | - | let $ | |
570 | - | let farmInterest = $ | |
571 | - | let boostInterest = $ | |
572 | - | let boostLPinterest = $ | |
573 | - | let claimAmount = $ | |
574 | - | let toTreasure = $ | |
567 | + | let $t02698727086 = claimCalc(pool, user) | |
568 | + | let farmInterest = $t02698727086._1 | |
569 | + | let boostInterest = $t02698727086._2 | |
570 | + | let boostLPinterest = $t02698727086._3 | |
571 | + | let claimAmount = $t02698727086._4 | |
572 | + | let toTreasure = $t02698727086._5 | |
575 | 573 | let availableFundsNew = (userAvailableSWOP(pool, user) + claimAmount) | |
576 | - | [IntegerEntry((((pool + "_") + user) + kFarmUserLastInterest), farmInterest), IntegerEntry((((pool + "_") + user) + kBoostUserLastInterest), boostInterest), IntegerEntry((((pool + "_") + user) + kBoostLPUserLastInterest), boostLPinterest), IntegerEntry((pool + kFarmLastInterest), farmInterest), IntegerEntry((pool + kBoostLastInterest), boostInterest), IntegerEntry((pool + kBoostLPLastInterest), boostLPinterest), IntegerEntry((pool + kLastInterestHeight), height), IntegerEntry((((pool + "_") + user) + kUserShareTokensStaked), userStakedAmountNew), IntegerEntry((((pool + "_") + user) + kUserShareTokensVirtual), userStakedAmountNew), IntegerEntry((pool + kShareTokensVirtual), ((totalShareVirtual - userAmountVirtual) + userStakedAmountNew)), DeleteEntry((((pool + "_") + user) + kUserShareTokensLocked)), DeleteEntry((((pool + "_") + user) + kUserShareTokensLockedHeight)), DeleteEntry((((pool + "_") + user) + kUserShareTokensLockedType)), Reissue(SWOP, toTreasure, true), ScriptTransfer(farmingTreasureAddr, toTreasure, SWOP), ScriptTransfer(i.caller, lockWavesFee, unit)] | |
574 | + | [IntegerEntry((((pool + "_") + user) + kFarmUserLastInterest), farmInterest), IntegerEntry((((pool + "_") + user) + kBoostUserLastInterest), boostInterest), IntegerEntry((((pool + "_") + user) + kBoostLPUserLastInterest), boostLPinterest), IntegerEntry((pool + kFarmLastInterest), farmInterest), IntegerEntry((pool + kBoostLastInterest), boostInterest), IntegerEntry((pool + kBoostLPLastInterest), boostLPinterest), IntegerEntry((pool + kLastInterestHeight), height), IntegerEntry((((pool + "_") + user) + kUserShareTokensStaked), userStakedAmountNew), IntegerEntry((((pool + "_") + user) + kUserShareTokensVirtual), userStakedAmountNew), IntegerEntry((pool + kShareTokensVirtual), ((totalShareVirtual - userAmountVirtual) + userStakedAmountNew)), IntegerEntry((((pool + "_") + user) + kAvailableSWOP), availableFundsNew), DeleteEntry((((pool + "_") + user) + kUserShareTokensLocked)), DeleteEntry((((pool + "_") + user) + kUserShareTokensLockedHeight)), DeleteEntry((((pool + "_") + user) + kUserShareTokensLockedType)), Reissue(SWOP, toTreasure, true), ScriptTransfer(farmingTreasureAddr, toTreasure, SWOP), ScriptTransfer(i.caller, lockWavesFee, unit)] | |
577 | 575 | } | |
578 | 576 | }) | |
579 | 577 | ||
583 | 581 | func withdrawShareTokens (pool,shareTokensWithdrawAmount) = valueOrElse(isActive(), { | |
584 | 582 | let shareTokensId = fromBase58String(getStringValue(value(addressFromString(pool)), "share_asset_id")) | |
585 | 583 | let user = toString(i.originCaller) | |
586 | - | let $ | |
587 | - | let farmInterest = $ | |
588 | - | let boostInterest = $ | |
589 | - | let boostLPinterest = $ | |
590 | - | let claimAmount = $ | |
591 | - | let toTreasure = $ | |
584 | + | let $t02866128760 = claimCalc(pool, user) | |
585 | + | let farmInterest = $t02866128760._1 | |
586 | + | let boostInterest = $t02866128760._2 | |
587 | + | let boostLPinterest = $t02866128760._3 | |
588 | + | let claimAmount = $t02866128760._4 | |
589 | + | let toTreasure = $t02866128760._5 | |
592 | 590 | let userStakedAmount = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensStaked)), 0) | |
593 | 591 | let userLockedAmount = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensLocked)), 0) | |
594 | 592 | let userAmountVirtual = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensVirtual)), userStakedAmount) | |
620 | 618 | let shareTokensId = fromBase58String(getStringValue(value(addressFromString(pool)), "share_asset_id")) | |
621 | 619 | let user = toString(i.originCaller) | |
622 | 620 | let shareTokenLocked = getTotalShareToken(pool) | |
623 | - | let $ | |
624 | - | let farmInterest = $ | |
625 | - | let boostInterest = $ | |
626 | - | let boostLPinterest = $ | |
627 | - | let claimAmount = $ | |
628 | - | let toTreasure = $ | |
621 | + | let $t03142931528 = claimCalc(pool, user) | |
622 | + | let farmInterest = $t03142931528._1 | |
623 | + | let boostInterest = $t03142931528._2 | |
624 | + | let boostLPinterest = $t03142931528._3 | |
625 | + | let claimAmount = $t03142931528._4 | |
626 | + | let toTreasure = $t03142931528._5 | |
629 | 627 | let availableFund = (userAvailableSWOP(pool, user) + claimAmount) | |
630 | 628 | if ((availableFund == 0)) | |
631 | 629 | then throw("You have 0 available SWOP") | |
740 | 738 | func updateUserBoostInterest (pool,user) = valueOrElse(isActive(), if ((i.caller != votingAddress)) | |
741 | 739 | then throw("Only voiting can call this function") | |
742 | 740 | else { | |
743 | - | let $ | |
744 | - | let farmInterest = $ | |
745 | - | let boostInterest = $ | |
746 | - | let boostLPinterest = $ | |
747 | - | let claimAmount = $ | |
748 | - | let toTreasure = $ | |
741 | + | let $t03396634065 = claimCalc(pool, user) | |
742 | + | let farmInterest = $t03396634065._1 | |
743 | + | let boostInterest = $t03396634065._2 | |
744 | + | let boostLPinterest = $t03396634065._3 | |
745 | + | let claimAmount = $t03396634065._4 | |
746 | + | let toTreasure = $t03396634065._5 | |
749 | 747 | let availableFundsNew = (userAvailableSWOP(pool, user) + claimAmount) | |
750 | 748 | [IntegerEntry((((pool + "_") + user) + kFarmUserLastInterest), farmInterest), IntegerEntry((((pool + "_") + user) + kBoostUserLastInterest), boostInterest), IntegerEntry((((pool + "_") + user) + kBoostLPUserLastInterest), boostLPinterest), IntegerEntry((pool + kFarmLastInterest), farmInterest), IntegerEntry((pool + kBoostLastInterest), boostInterest), IntegerEntry((pool + kBoostLPLastInterest), boostLPinterest), IntegerEntry((pool + kLastInterestHeight), height), IntegerEntry((((pool + "_") + user) + kAvailableSWOP), availableFundsNew), Reissue(SWOP, toTreasure, true), ScriptTransfer(farmingTreasureAddr, toTreasure, SWOP)] | |
751 | 749 | }) |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let kActive = "active" | |
5 | 5 | ||
6 | 6 | let kActiveGlob = "active_all_contracts" | |
7 | 7 | ||
8 | 8 | let kCause = "shutdown_cause" | |
9 | 9 | ||
10 | 10 | let kRewardPoolFractionCurrent = "_current_pool_fraction_reward" | |
11 | 11 | ||
12 | 12 | let kRewardPoolFractionPrevious = "_previous_pool_fraction_reward" | |
13 | 13 | ||
14 | 14 | let kHeightPoolFraction = "_pool_reward_update_height" | |
15 | 15 | ||
16 | 16 | let kTotalRewardPerBlockCurrent = "total_reward_per_block_current" | |
17 | 17 | ||
18 | 18 | let kTotalRewardPerBlockPrevious = "total_reward_per_block_previous" | |
19 | 19 | ||
20 | 20 | let kRewardUpdateHeight = "reward_update_height" | |
21 | 21 | ||
22 | 22 | let kUserShareTokensStaked = "_share_tokens_locked" | |
23 | 23 | ||
24 | 24 | let kUserShareTokensLocked = "_share_tokens_blocked" | |
25 | 25 | ||
26 | 26 | let kUserShareTokensLockedType = "_share_tokens_blocked_type" | |
27 | 27 | ||
28 | 28 | let kUserShareTokensLockedHeight = "_share_tokens_blocked_height" | |
29 | 29 | ||
30 | 30 | let kUserShareTokensVirtual = "_share_tokens_virtual" | |
31 | 31 | ||
32 | 32 | let kShareTotalShareTokens = "_total_share_tokens_locked" | |
33 | 33 | ||
34 | 34 | let kShareTokensVirtual = "_total_share_tokens_virtual" | |
35 | 35 | ||
36 | 36 | let kLockParams = "_lock_params" | |
37 | 37 | ||
38 | 38 | let kLockWavesFee = "lock_waves_fee" | |
39 | 39 | ||
40 | 40 | let kPoolBoostCoef = "_boost_coef" | |
41 | 41 | ||
42 | 42 | let kFarmLastInterest = "_last_interest" | |
43 | 43 | ||
44 | 44 | let kFarmUserLastInterest = "_last_interest" | |
45 | 45 | ||
46 | 46 | let kBoostLastInterest = "_last_interest_b" | |
47 | 47 | ||
48 | 48 | let kBoostUserLastInterest = "_last_interest_u_b" | |
49 | 49 | ||
50 | 50 | let kBoostLPLastInterest = "_last_interest_lpb" | |
51 | 51 | ||
52 | 52 | let kBoostLPUserLastInterest = "_last_interest_u_lpb" | |
53 | 53 | ||
54 | 54 | let kLastInterestHeight = "_last_interest_height" | |
55 | 55 | ||
56 | 56 | let kSWOPid = "SWOP_id" | |
57 | 57 | ||
58 | 58 | let kAvailableSWOP = "_available_SWOP" | |
59 | 59 | ||
60 | 60 | let kSwopYearEmission = "swop_year_emission" | |
61 | 61 | ||
62 | 62 | let kHarvestPoolVote = "_harvest_pool_vote_gSWOP" | |
63 | 63 | ||
64 | 64 | let kPoolVote = "_pool_vote_gSWOP" | |
65 | 65 | ||
66 | 66 | let kUserPoolVote = "_user_vote_gSWOP" | |
67 | 67 | ||
68 | 68 | let kHarvestUserPoolVote = "_harvest_user_pool_vote_gSWOP" | |
69 | 69 | ||
70 | 70 | let kBasePeriod = "base_period" | |
71 | 71 | ||
72 | 72 | let kPeriodLength = "period_length" | |
73 | 73 | ||
74 | 74 | let kStartHeight = "start_height" | |
75 | 75 | ||
76 | 76 | let kFirstHarvestHeight = "first_harvest_height" | |
77 | 77 | ||
78 | 78 | let kShareLimitFH = "share_limit_on_first_harvest" | |
79 | 79 | ||
80 | 80 | let kAdminPubKey1 = "admin_pub_1" | |
81 | 81 | ||
82 | 82 | let kAdminPubKey2 = "admin_pub_2" | |
83 | 83 | ||
84 | 84 | let kAdminPubKey3 = "admin_pub_3" | |
85 | 85 | ||
86 | 86 | let kAdminInvokePubKey = "admin_invoke_pub" | |
87 | 87 | ||
88 | 88 | let kMoneyBoxAddress = "money_box_address" | |
89 | 89 | ||
90 | 90 | let kVotingAddress = "voting_address" | |
91 | 91 | ||
92 | 92 | let kGovAddress = "governance_address" | |
93 | 93 | ||
94 | 94 | let kLPFarmingAddress = "lp_farming" | |
95 | 95 | ||
96 | 96 | let kFarmingTreasureAddr = "farming_treasure" | |
97 | 97 | ||
98 | 98 | let oracle = Address(base58'3MvVBtsXroQpy1tsPw21TU2ET9A8WfmrNjz') | |
99 | 99 | ||
100 | 100 | let totalVoteShare = 10000000000 | |
101 | 101 | ||
102 | 102 | let scaleValue8 = 100000000 | |
103 | 103 | ||
104 | 104 | let lockBoostCoefScale = 1000 | |
105 | 105 | ||
106 | 106 | let defPoolBoostCoef = 500 | |
107 | 107 | ||
108 | 108 | func getBase58FromOracle (key) = match getString(oracle, key) { | |
109 | 109 | case string: String => | |
110 | 110 | fromBase58String(string) | |
111 | 111 | case nothing => | |
112 | 112 | throw((key + "is empty")) | |
113 | 113 | } | |
114 | 114 | ||
115 | 115 | ||
116 | 116 | let adminPubKey1 = getBase58FromOracle(kAdminPubKey1) | |
117 | 117 | ||
118 | 118 | let adminPubKey2 = getBase58FromOracle(kAdminPubKey2) | |
119 | 119 | ||
120 | 120 | let adminPubKey3 = getBase58FromOracle(kAdminPubKey3) | |
121 | 121 | ||
122 | 122 | let moneyBoxAddress = Address(getBase58FromOracle(kMoneyBoxAddress)) | |
123 | 123 | ||
124 | 124 | let votingAddress = Address(getBase58FromOracle(kVotingAddress)) | |
125 | 125 | ||
126 | 126 | let govAddress = Address(getBase58FromOracle(kGovAddress)) | |
127 | 127 | ||
128 | 128 | let adminInvokePubKey = getBase58FromOracle(kAdminInvokePubKey) | |
129 | 129 | ||
130 | 130 | let lpFarmingAddress = Address(getBase58FromOracle(kLPFarmingAddress)) | |
131 | 131 | ||
132 | 132 | let farmingTreasureAddr = Address(getBase58FromOracle(kFarmingTreasureAddr)) | |
133 | 133 | ||
134 | 134 | let basePeriod = valueOrErrorMessage(getInteger(votingAddress, kBasePeriod), "Empty kBasePeriod") | |
135 | 135 | ||
136 | 136 | let startHeight = valueOrErrorMessage(getInteger(votingAddress, kStartHeight), "Empty kStartHeight") | |
137 | 137 | ||
138 | 138 | let periodLength = valueOrErrorMessage(getInteger(votingAddress, kPeriodLength), "Empty kPeriodLength") | |
139 | 139 | ||
140 | - | let currPeriod = (basePeriod + ((height - startHeight) / periodLength)) | |
141 | - | ||
142 | 140 | let active = getBooleanValue(this, kActive) | |
143 | 141 | ||
144 | 142 | let activeGlob = valueOrElse(getBoolean(oracle, kActiveGlob), true) | |
145 | 143 | ||
146 | 144 | let SwopYearEmission = getIntegerValue(this, kSwopYearEmission) | |
147 | 145 | ||
148 | 146 | let SWOP = fromBase58String(getStringValue(this, kSWOPid)) | |
149 | 147 | ||
150 | 148 | func getHeightFirstHarvest (pool) = valueOrElse(getInteger(Address(fromBase58String(pool)), kFirstHarvestHeight), 0) | |
151 | 149 | ||
152 | 150 | ||
153 | 151 | func getFHShareLimitToken (pool) = valueOrErrorMessage(getInteger(pool, kShareLimitFH), ("No data on the key: " + kShareLimitFH)) | |
154 | 152 | ||
155 | 153 | ||
156 | 154 | func getTotalShareToken (pool) = valueOrErrorMessage(getInteger(this, (pool + kShareTotalShareTokens)), (("No data on the key: " + pool) + kShareTotalShareTokens)) | |
157 | 155 | ||
158 | 156 | ||
159 | 157 | func getPoolVoted (pool) = valueOrElse(getInteger(votingAddress, (pool + kPoolVote)), 0) | |
160 | 158 | ||
161 | 159 | ||
162 | 160 | func getUserPoolVoted (pool,user) = valueOrElse(getInteger(votingAddress, (((user + "_") + pool) + kUserPoolVote)), 0) | |
163 | 161 | ||
164 | 162 | ||
165 | 163 | func getShareAssetId (pool) = fromBase58String(getStringValue(value(addressFromString(pool)), "share_asset_id")) | |
166 | 164 | ||
167 | 165 | ||
168 | 166 | func accountBalance (assetId) = match assetId { | |
169 | 167 | case id: ByteVector => | |
170 | 168 | assetBalance(this, id) | |
171 | 169 | case waves: Unit => | |
172 | 170 | wavesBalance(this).available | |
173 | 171 | case _ => | |
174 | 172 | throw("Match error") | |
175 | 173 | } | |
176 | 174 | ||
177 | 175 | ||
178 | 176 | func getAssetInfo (assetId) = match assetId { | |
179 | 177 | case id: ByteVector => | |
180 | 178 | let stringId = toBase58String(id) | |
181 | 179 | let info = valueOrErrorMessage(assetInfo(id), (("Asset " + stringId) + " doesn't exist")) | |
182 | 180 | $Tuple3(stringId, info.name, info.decimals) | |
183 | 181 | case waves: Unit => | |
184 | 182 | $Tuple3("WAVES", "WAVES", 8) | |
185 | 183 | case _ => | |
186 | 184 | throw("Match error") | |
187 | 185 | } | |
188 | 186 | ||
189 | 187 | ||
190 | 188 | func calcScaleValue (assetId1,assetId2) = { | |
191 | 189 | let assetId1Decimals = value(assetInfo(assetId1)).decimals | |
192 | 190 | let assetId2Decimals = value(assetInfo(assetId2)).decimals | |
193 | 191 | let scaleDigits = ((assetId2Decimals - assetId1Decimals) + 8) | |
194 | 192 | pow(10, 0, scaleDigits, 0, 0, DOWN) | |
195 | 193 | } | |
196 | 194 | ||
197 | 195 | ||
198 | 196 | func userAvailableSWOP (pool,user) = valueOrElse(getInteger(this, (((pool + "_") + user) + kAvailableSWOP)), 0) | |
199 | 197 | ||
200 | 198 | ||
201 | 199 | func rewardInfo (pool) = { | |
202 | 200 | let totalRewardPerBlockCurrent = valueOrErrorMessage(getInteger(govAddress, kTotalRewardPerBlockCurrent), ((("No data on the key: " + kTotalRewardPerBlockCurrent) + " at address ") + toString(govAddress))) | |
203 | 201 | let totalRewardPerBlockPrevious = valueOrErrorMessage(getInteger(govAddress, kTotalRewardPerBlockPrevious), ((("No data on the key: " + kTotalRewardPerBlockPrevious) + " at address ") + toString(govAddress))) | |
204 | 202 | let rewardPoolFractionCurrent = valueOrErrorMessage(getInteger(govAddress, (pool + kRewardPoolFractionCurrent)), (((("No data on the key: " + pool) + kRewardPoolFractionCurrent) + " at address ") + toString(govAddress))) | |
205 | 203 | let rewardUpdateHeight = valueOrErrorMessage(getInteger(govAddress, kRewardUpdateHeight), ((("No data on the key: " + kRewardUpdateHeight) + " at address ") + toString(govAddress))) | |
206 | 204 | let poolRewardUpdateHeight = valueOrElse(getInteger(govAddress, (pool + kHeightPoolFraction)), rewardUpdateHeight) | |
207 | 205 | let rewardPoolFractionPrevious = valueOrErrorMessage(getInteger(govAddress, (pool + kRewardPoolFractionPrevious)), (((("No data on the key: " + pool) + kRewardPoolFractionPrevious) + " at address ") + toString(govAddress))) | |
208 | 206 | let rewardPoolCurrent = fraction(totalRewardPerBlockCurrent, rewardPoolFractionCurrent, totalVoteShare) | |
209 | 207 | let rewardPoolPrevious = fraction(totalRewardPerBlockCurrent, rewardPoolFractionPrevious, totalVoteShare) | |
210 | 208 | if (if ((rewardPoolCurrent > totalRewardPerBlockCurrent)) | |
211 | 209 | then true | |
212 | 210 | else (rewardPoolPrevious > totalRewardPerBlockPrevious)) | |
213 | 211 | then throw("rewardPoolCurrent > totalRewardPerBlockCurrent or rewardPoolPrevious > totalRewardPerBlockPrevious") | |
214 | 212 | else $Tuple4(rewardPoolCurrent, rewardUpdateHeight, rewardPoolPrevious, poolRewardUpdateHeight) | |
215 | 213 | } | |
216 | 214 | ||
217 | 215 | ||
218 | 216 | func getLastInterestInfo (pool) = { | |
219 | 217 | let farmInterest = valueOrErrorMessage(getInteger(this, (pool + kFarmLastInterest)), (("No data on the key: " + pool) + kFarmLastInterest)) | |
220 | 218 | let boostInterest = valueOrErrorMessage(getInteger(this, (pool + kBoostLastInterest)), (("No data on the key: " + pool) + kBoostLastInterest)) | |
221 | 219 | let boostLPInterest = valueOrErrorMessage(getInteger(this, (pool + kBoostLPLastInterest)), (("No data on the key: " + pool) + kBoostLPLastInterest)) | |
222 | 220 | let lastInterestHeight = valueOrElse(getInteger(this, (pool + kLastInterestHeight)), height) | |
223 | 221 | $Tuple4(lastInterestHeight, farmInterest, boostInterest, boostLPInterest) | |
224 | 222 | } | |
225 | 223 | ||
226 | 224 | ||
227 | 225 | func calcFarmRwd (pool,curTotalReward) = { | |
228 | 226 | let poolBoostCoef = valueOrElse(getInteger(this, (pool + kPoolBoostCoef)), defPoolBoostCoef) | |
229 | 227 | fraction(curTotalReward, lockBoostCoefScale, (poolBoostCoef + lockBoostCoefScale)) | |
230 | 228 | } | |
231 | 229 | ||
232 | 230 | ||
233 | 231 | func calcBoostRwd (pool,curTotalReward) = { | |
234 | 232 | let poolBoostCoef = valueOrElse(getInteger(this, (pool + kPoolBoostCoef)), defPoolBoostCoef) | |
235 | 233 | fraction(curTotalReward, poolBoostCoef, (poolBoostCoef + lockBoostCoefScale)) | |
236 | 234 | } | |
237 | 235 | ||
238 | 236 | ||
239 | 237 | func calcInterest (pool,lastInterestHeight,rewardUpdateHeight,poolRewardUpdateHeight,farmInterest,boostInterest,poolVoted,boostLpInterest,currentRewardPerBlock,shareTokenLocked,previousRewardPerBlock,scaleValue) = if ((shareTokenLocked == 0)) | |
240 | 238 | then $Tuple3(0, 0, 0) | |
241 | 239 | else { | |
242 | - | let $ | |
240 | + | let $t01035711794 = if (if (if ((rewardUpdateHeight > height)) | |
243 | 241 | then (rewardUpdateHeight == poolRewardUpdateHeight) | |
244 | 242 | else false) | |
245 | 243 | then true | |
246 | 244 | else if ((height > rewardUpdateHeight)) | |
247 | 245 | then (rewardUpdateHeight != poolRewardUpdateHeight) | |
248 | 246 | else false) | |
249 | 247 | then { | |
250 | 248 | let r = (previousRewardPerBlock * (height - lastInterestHeight)) | |
251 | 249 | $Tuple4(r, farmInterest, boostInterest, boostLpInterest) | |
252 | 250 | } | |
253 | 251 | else if (if (if ((height > rewardUpdateHeight)) | |
254 | 252 | then (rewardUpdateHeight == poolRewardUpdateHeight) | |
255 | 253 | else false) | |
256 | 254 | then (lastInterestHeight > rewardUpdateHeight) | |
257 | 255 | else false) | |
258 | 256 | then { | |
259 | 257 | let r = (currentRewardPerBlock * (height - lastInterestHeight)) | |
260 | 258 | $Tuple4(r, farmInterest, boostInterest, boostLpInterest) | |
261 | 259 | } | |
262 | 260 | else { | |
263 | 261 | let rwdBfrUpd = (previousRewardPerBlock * (rewardUpdateHeight - lastInterestHeight)) | |
264 | 262 | let fBfrUp = (farmInterest + fraction(calcFarmRwd(pool, rwdBfrUpd), scaleValue, shareTokenLocked)) | |
265 | 263 | let bBfrUp = (boostInterest + (if ((poolVoted > 0)) | |
266 | 264 | then fraction(calcBoostRwd(pool, rwdBfrUpd), scaleValue8, poolVoted) | |
267 | 265 | else 0)) | |
268 | 266 | let bLPBfrUp = (boostLpInterest + (if (if ((poolVoted > 0)) | |
269 | 267 | then (shareTokenLocked > 0) | |
270 | 268 | else false) | |
271 | 269 | then fraction(fraction(calcBoostRwd(pool, rwdBfrUpd), scaleValue8, shareTokenLocked), scaleValue8, poolVoted) | |
272 | 270 | else 0)) | |
273 | 271 | let rwd = (currentRewardPerBlock * (height - rewardUpdateHeight)) | |
274 | 272 | $Tuple4(rwd, fBfrUp, bBfrUp, bLPBfrUp) | |
275 | 273 | } | |
276 | - | let reward = $ | |
277 | - | let farmIntrBefore = $ | |
278 | - | let boostIntrBefore = $ | |
279 | - | let boostLPIntrBefore = $ | |
274 | + | let reward = $t01035711794._1 | |
275 | + | let farmIntrBefore = $t01035711794._2 | |
276 | + | let boostIntrBefore = $t01035711794._3 | |
277 | + | let boostLPIntrBefore = $t01035711794._4 | |
280 | 278 | let newFarmInterest = (farmIntrBefore + fraction(calcFarmRwd(pool, reward), scaleValue, shareTokenLocked)) | |
281 | 279 | let newBoostInterest = (boostIntrBefore + (if ((poolVoted > 0)) | |
282 | 280 | then fraction(calcBoostRwd(pool, reward), scaleValue8, poolVoted) | |
283 | 281 | else 0)) | |
284 | 282 | let newBoostLPInterest = (boostLPIntrBefore + (if (if ((poolVoted > 0)) | |
285 | 283 | then (shareTokenLocked > 0) | |
286 | 284 | else false) | |
287 | 285 | then fraction(fraction(calcBoostRwd(pool, reward), scaleValue8, shareTokenLocked), scaleValue8, poolVoted) | |
288 | 286 | else 0)) | |
289 | 287 | $Tuple3(newFarmInterest, newBoostInterest, newBoostLPInterest) | |
290 | 288 | } | |
291 | 289 | ||
292 | 290 | ||
293 | 291 | func claimCalc (pool,user) = { | |
294 | 292 | let scaleValue = calcScaleValue(SWOP, getShareAssetId(pool)) | |
295 | 293 | let poolVoted = getPoolVoted(pool) | |
296 | 294 | let uPoolVoted = getUserPoolVoted(pool, user) | |
297 | 295 | let shareToken = getTotalShareToken(pool) | |
298 | 296 | let totalShareVirtual = valueOrElse(getInteger(this, (pool + kShareTokensVirtual)), shareToken) | |
299 | - | let $ | |
300 | - | let lastInterestHeight = $ | |
301 | - | let farmInterest = $ | |
302 | - | let boostInterest = $ | |
303 | - | let boostLPInterest = $ | |
304 | - | let $ | |
305 | - | let currentRewardPerBlock = $ | |
306 | - | let rewardUpdateHeight = $ | |
307 | - | let previousRewardPerBlock = $ | |
308 | - | let poolRewardUpdateHeight = $ | |
297 | + | let $t01276712865 = getLastInterestInfo(pool) | |
298 | + | let lastInterestHeight = $t01276712865._1 | |
299 | + | let farmInterest = $t01276712865._2 | |
300 | + | let boostInterest = $t01276712865._3 | |
301 | + | let boostLPInterest = $t01276712865._4 | |
302 | + | let $t01287012984 = rewardInfo(pool) | |
303 | + | let currentRewardPerBlock = $t01287012984._1 | |
304 | + | let rewardUpdateHeight = $t01287012984._2 | |
305 | + | let previousRewardPerBlock = $t01287012984._3 | |
306 | + | let poolRewardUpdateHeight = $t01287012984._4 | |
309 | 307 | let uFarmInterest = valueOrElse(getInteger(this, (((pool + "_") + user) + kFarmUserLastInterest)), farmInterest) | |
310 | 308 | let uBoostInterest = valueOrElse(getInteger(this, (((pool + "_") + user) + kBoostUserLastInterest)), boostInterest) | |
311 | 309 | let uBoostLPInterest = valueOrElse(getInteger(this, (((pool + "_") + user) + kBoostLPUserLastInterest)), boostLPInterest) | |
312 | 310 | let uShareTokensStaked = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensStaked)), 0) | |
313 | 311 | let uShareTokensVirt = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensVirtual)), uShareTokensStaked) | |
314 | - | let $ | |
315 | - | let newFarmInterest = $ | |
316 | - | let newBoostInterest = $ | |
317 | - | let newBoostLPInterest = $ | |
312 | + | let $t01355213945 = calcInterest(pool, lastInterestHeight, rewardUpdateHeight, poolRewardUpdateHeight, farmInterest, boostInterest, poolVoted, boostLPInterest, currentRewardPerBlock, totalShareVirtual, previousRewardPerBlock, scaleValue) | |
313 | + | let newFarmInterest = $t01355213945._1 | |
314 | + | let newBoostInterest = $t01355213945._2 | |
315 | + | let newBoostLPInterest = $t01355213945._3 | |
318 | 316 | let claimFarming = fraction(uShareTokensVirt, (newFarmInterest - uFarmInterest), scaleValue) | |
319 | 317 | let claimBoostingMax = fraction(uPoolVoted, (newBoostInterest - uBoostInterest), scaleValue8) | |
320 | 318 | let mul = fraction(toBigInt(uShareTokensVirt), toBigInt(uPoolVoted), toBigInt(1)) | |
321 | 319 | let claimBoosting = toInt(fraction(fraction(mul, toBigInt((newBoostLPInterest - uBoostLPInterest)), toBigInt(scaleValue8)), toBigInt(1), toBigInt(scaleValue8))) | |
322 | 320 | let toTreasury = (claimBoostingMax - claimBoosting) | |
323 | 321 | if ((0 > toTreasury)) | |
324 | 322 | then throw("toTreasury < 0") | |
325 | 323 | else $Tuple5(newFarmInterest, newBoostInterest, newBoostLPInterest, (claimFarming + claimBoosting), toTreasury) | |
326 | 324 | } | |
327 | 325 | ||
328 | 326 | ||
329 | 327 | func availableClaimCalcAllByUser (pools,user) = { | |
330 | 328 | func calcAvailable (acc,pool) = { | |
331 | - | let $ | |
332 | - | let newPools = $ | |
333 | - | let amounts = $ | |
334 | - | let $ | |
335 | - | let fi = $ | |
336 | - | let bi = $ | |
337 | - | let blpi = $ | |
338 | - | let claimAmount = $ | |
339 | - | let tt = $ | |
329 | + | let $t01475614785 = acc | |
330 | + | let newPools = $t01475614785._1 | |
331 | + | let amounts = $t01475614785._2 | |
332 | + | let $t01479414853 = claimCalc(pool, user) | |
333 | + | let fi = $t01479414853._1 | |
334 | + | let bi = $t01479414853._2 | |
335 | + | let blpi = $t01479414853._3 | |
336 | + | let claimAmount = $t01479414853._4 | |
337 | + | let tt = $t01479414853._5 | |
340 | 338 | let availableFund = (userAvailableSWOP(pool, user) + claimAmount) | |
341 | - | $Tuple2((newPools :+ | |
339 | + | $Tuple2((newPools :+ pool), (amounts :+ availableFund)) | |
342 | 340 | } | |
343 | 341 | ||
344 | 342 | let $l = pools | |
345 | 343 | let $s = size($l) | |
346 | 344 | let $acc0 = $Tuple2(nil, nil) | |
347 | 345 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
348 | 346 | then $a | |
349 | 347 | else calcAvailable($a, $l[$i]) | |
350 | 348 | ||
351 | 349 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
352 | 350 | then $a | |
353 | 351 | else throw("List size exceeds 60") | |
354 | 352 | ||
355 | 353 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($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), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20), 21), 22), 23), 24), 25), 26), 27), 28), 29), 30), 31), 32), 33), 34), 35), 36), 37), 38), 39), 40), 41), 42), 43), 44), 45), 46), 47), 48), 49), 50), 51), 52), 53), 54), 55), 56), 57), 58), 59), 60) | |
356 | 354 | } | |
357 | 355 | ||
358 | 356 | ||
359 | 357 | func canLockInFirstHarvest (pool,user,userShareTokensStaked,pmtAmount,lockType) = if ((getHeightFirstHarvest(pool) > height)) | |
360 | 358 | then { | |
361 | 359 | let totalVoteAmount = valueOrElse(getInteger(votingAddress, (pool + kHarvestPoolVote)), 0) | |
362 | - | let userVoteAmount = valueOrElse(getInteger(votingAddress, (((user + "_") + pool) + | |
360 | + | let userVoteAmount = valueOrElse(getInteger(votingAddress, (((user + "_") + pool) + kHarvestUserPoolVote)), 0) | |
363 | 361 | let FHShareTokenLimit = getFHShareLimitToken(addressFromStringValue(pool)) | |
364 | 362 | let FHShareTokenUserLimit = (fraction(FHShareTokenLimit, userVoteAmount, totalVoteAmount) - userShareTokensStaked) | |
365 | 363 | if ((lockType > 0)) | |
366 | 364 | then throw("You can't lock shareTokens till first harvest end.") | |
367 | 365 | else if ((userVoteAmount == 0)) | |
368 | 366 | then 0 | |
369 | 367 | else if ((pmtAmount >= FHShareTokenUserLimit)) | |
370 | 368 | then (pmtAmount - FHShareTokenUserLimit) | |
371 | 369 | else 0 | |
372 | 370 | } | |
373 | 371 | else 0 | |
374 | 372 | ||
375 | 373 | ||
376 | 374 | func getLockParams (type) = { | |
377 | 375 | let lockParams = split(valueOrErrorMessage(getString(this, (toString(type) + kLockParams)), ("There are no key for lock type" + toString(type))), "_") | |
378 | 376 | $Tuple2(parseIntValue(lockParams[0]), parseIntValue(lockParams[1])) | |
379 | 377 | } | |
380 | 378 | ||
381 | 379 | ||
382 | 380 | func suspend (cause) = [BooleanEntry(kActive, false), StringEntry(kCause, cause)] | |
383 | 381 | ||
384 | 382 | ||
385 | 383 | func isActive () = if (if (active) | |
386 | 384 | then activeGlob | |
387 | 385 | else false) | |
388 | 386 | then unit | |
389 | 387 | else throw("DApp is inactive at this moment") | |
390 | 388 | ||
391 | 389 | ||
392 | 390 | func isAdminCall (i) = if (containsElement([adminPubKey1, adminPubKey2, adminPubKey3], i.callerPublicKey)) | |
393 | 391 | then unit | |
394 | 392 | else throw("Only admin can call this function") | |
395 | 393 | ||
396 | 394 | ||
397 | 395 | @Callable(i) | |
398 | 396 | func init (earlyLP) = if (isDefined(getString(this, kSWOPid))) | |
399 | 397 | then throw("SWOP already initialized") | |
400 | 398 | else { | |
401 | 399 | let initAmount = 100000000000000 | |
402 | 400 | let SWOPissue = Issue("SWOP", "SWOP protocol token", initAmount, 8, true) | |
403 | 401 | let SWOPid = calculateAssetId(SWOPissue) | |
404 | 402 | [BooleanEntry(kActive, true), Issue("SWOP", "SWOP protocol token", initAmount, 8, true), StringEntry(kSWOPid, toBase58String(SWOPid))] | |
405 | 403 | } | |
406 | 404 | ||
407 | 405 | ||
408 | 406 | ||
409 | 407 | @Callable(i) | |
410 | 408 | func initPoolShareFarming (pool) = valueOrElse(isAdminCall(i), [IntegerEntry((pool + kShareTotalShareTokens), 0), IntegerEntry((pool + kFarmLastInterest), 0), IntegerEntry((pool + kBoostLastInterest), 0), IntegerEntry((pool + kBoostLPLastInterest), 0), IntegerEntry((pool + kLastInterestHeight), height)]) | |
411 | 409 | ||
412 | 410 | ||
413 | 411 | ||
414 | 412 | @Callable(i) | |
415 | 413 | func updatePoolInterest (pool) = valueOrElse(isActive(), if ((i.caller != govAddress)) | |
416 | 414 | then throw("Only Governance can call this function") | |
417 | 415 | else { | |
418 | 416 | let user = toString(addressFromPublicKey(adminInvokePubKey)) | |
419 | - | let $ | |
420 | - | let farmInterest = $ | |
421 | - | let boostInterest = $ | |
422 | - | let boostLPinterest = $ | |
417 | + | let $t01758917663 = claimCalc(pool, user) | |
418 | + | let farmInterest = $t01758917663._1 | |
419 | + | let boostInterest = $t01758917663._2 | |
420 | + | let boostLPinterest = $t01758917663._3 | |
423 | 421 | [IntegerEntry((pool + kFarmLastInterest), farmInterest), IntegerEntry((pool + kBoostLastInterest), boostInterest), IntegerEntry((pool + kBoostLPLastInterest), boostLPinterest), IntegerEntry((pool + kLastInterestHeight), height)] | |
424 | 422 | }) | |
425 | 423 | ||
426 | 424 | ||
427 | 425 | ||
428 | 426 | @Callable(i) | |
429 | 427 | func lockShareTokens (pool,lockType) = valueOrElse(isActive(), { | |
430 | 428 | let shareAssetId = getShareAssetId(pool) | |
431 | 429 | let user = toString(i.originCaller) | |
432 | 430 | let totalShare = getTotalShareToken(pool) | |
433 | 431 | let totalShareVirtual = valueOrElse(getInteger(this, (pool + kShareTokensVirtual)), totalShare) | |
434 | 432 | let userStakedAmount = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensStaked)), 0) | |
435 | 433 | let userLockedHeigt = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensLockedHeight)), 0) | |
436 | 434 | let userLockedAmount = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensLocked)), 0) | |
437 | 435 | let userAmountVirtual = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensVirtual)), userStakedAmount) | |
438 | 436 | let totalUserShareTokens = ((userStakedAmount + userLockedAmount) + i.payments[0].amount) | |
439 | - | let $ | |
440 | - | let lockPeriod = $ | |
441 | - | let lockCoef = $ | |
437 | + | let $t01877218824 = getLockParams(lockType) | |
438 | + | let lockPeriod = $t01877218824._1 | |
439 | + | let lockCoef = $t01877218824._2 | |
442 | 440 | let lockWavesFee = getIntegerValue(this, kLockWavesFee) | |
443 | 441 | if ((i.payments[0].assetId != shareAssetId)) | |
444 | 442 | then throw("Wrong sharetoken in payment") | |
445 | 443 | else if ((0 >= i.payments[0].amount)) | |
446 | 444 | then throw("Payment amount must be greater than 0") | |
447 | 445 | else if ((0 > lockType)) | |
448 | 446 | then throw("lockType must be >= 0") | |
449 | 447 | else { | |
450 | 448 | let shareTokensChangeOnFH = canLockInFirstHarvest(pool, user, userStakedAmount, i.payments[0].amount, lockType) | |
451 | 449 | if ((shareTokensChangeOnFH == shareTokensChangeOnFH)) | |
452 | 450 | then { | |
453 | - | let $ | |
451 | + | let $t01925121193 = if ((lockType == 0)) | |
454 | 452 | then { | |
455 | 453 | let userAmountVirtualNew = ((userAmountVirtual + i.payments[0].amount) - shareTokensChangeOnFH) | |
456 | - | $Tuple2([IntegerEntry((((pool + "_") + user) + kUserShareTokensStaked), ((userStakedAmount + i.payments[0].amount) - shareTokensChangeOnFH)), IntegerEntry((pool + kShareTokensVirtual), ((totalShareVirtual + i.payments[0].amount) - shareTokensChangeOnFH)), ScriptTransfer(i.originCaller, shareTokensChangeOnFH, i.payments[0].assetId)], ((totalShare + i.payments[0].amount) - shareTokensChangeOnFH)) | |
454 | + | $Tuple2([IntegerEntry((((pool + "_") + user) + kUserShareTokensStaked), ((userStakedAmount + i.payments[0].amount) - shareTokensChangeOnFH)), IntegerEntry((((pool + "_") + user) + kUserShareTokensVirtual), userAmountVirtualNew), IntegerEntry((pool + kShareTokensVirtual), ((totalShareVirtual + i.payments[0].amount) - shareTokensChangeOnFH)), ScriptTransfer(i.originCaller, shareTokensChangeOnFH, i.payments[0].assetId)], ((totalShare + i.payments[0].amount) - shareTokensChangeOnFH)) | |
457 | 455 | } | |
458 | 456 | else if (if ((userLockedHeigt == 0)) | |
459 | 457 | then if (if ((2 > size(i.payments))) | |
460 | 458 | then true | |
461 | 459 | else (i.payments[1].assetId != unit)) | |
462 | 460 | then true | |
463 | 461 | else (lockWavesFee > i.payments[1].amount) | |
464 | 462 | else false) | |
465 | 463 | then throw((("You need to pay additional waves comission " + toString(lockWavesFee)) + "WAVES")) | |
466 | 464 | else if ((userLockedHeigt > (height + lockPeriod))) | |
467 | 465 | then throw("You cannot lock sharetokens for a period less than what you have already locked") | |
468 | 466 | else { | |
469 | 467 | let userLockedAmountNew = (userLockedAmount + i.payments[0].amount) | |
470 | 468 | let userLockedHeigtNew = (height + lockPeriod) | |
471 | 469 | let userAmountVirtualNew = (fraction(userLockedAmountNew, lockCoef, lockBoostCoefScale) + userStakedAmount) | |
472 | 470 | $Tuple2([IntegerEntry((((pool + "_") + user) + kUserShareTokensLocked), userLockedAmountNew), IntegerEntry((((pool + "_") + user) + kUserShareTokensLockedHeight), userLockedHeigtNew), IntegerEntry((((pool + "_") + user) + kUserShareTokensLockedType), lockType), IntegerEntry((((pool + "_") + user) + kUserShareTokensVirtual), userAmountVirtualNew), IntegerEntry((pool + kShareTokensVirtual), ((totalShareVirtual - userAmountVirtual) + userAmountVirtualNew))], (totalShare + i.payments[0].amount)) | |
473 | 471 | } | |
474 | - | let lockEntries = $ | |
475 | - | let totalShareNew = $ | |
472 | + | let lockEntries = $t01925121193._1 | |
473 | + | let totalShareNew = $t01925121193._2 | |
476 | 474 | if ((accountBalance(shareAssetId) > totalShareNew)) | |
477 | 475 | then throw("Balance of share-token is lower than totalAmount") | |
478 | 476 | else { | |
479 | - | let $ | |
480 | - | let farmInterest = $ | |
481 | - | let boostInterest = $ | |
482 | - | let boostLPinterest = $ | |
483 | - | let claimAmount = $ | |
484 | - | let toTreasure = $ | |
477 | + | let $t02131821417 = claimCalc(pool, user) | |
478 | + | let farmInterest = $t02131821417._1 | |
479 | + | let boostInterest = $t02131821417._2 | |
480 | + | let boostLPinterest = $t02131821417._3 | |
481 | + | let claimAmount = $t02131821417._4 | |
482 | + | let toTreasure = $t02131821417._5 | |
485 | 483 | let availableFundsNew = (userAvailableSWOP(pool, user) + claimAmount) | |
486 | 484 | let uplp = if ((getString(Address(fromBase58String(pool)), "version") == "3.0.0")) | |
487 | 485 | then invoke(lpFarmingAddress, "updateUserInterest", [pool, totalUserShareTokens], nil) | |
488 | 486 | else 0 | |
489 | 487 | if ((uplp == uplp)) | |
490 | 488 | then ([IntegerEntry((((pool + "_") + user) + kFarmUserLastInterest), farmInterest), IntegerEntry((((pool + "_") + user) + kBoostUserLastInterest), boostInterest), IntegerEntry((((pool + "_") + user) + kBoostLPUserLastInterest), boostLPinterest), IntegerEntry((pool + kFarmLastInterest), farmInterest), IntegerEntry((pool + kBoostLastInterest), boostInterest), IntegerEntry((pool + kBoostLPLastInterest), boostLPinterest), IntegerEntry((pool + kLastInterestHeight), height), IntegerEntry((pool + kShareTotalShareTokens), totalShareNew), IntegerEntry((((pool + "_") + user) + kAvailableSWOP), availableFundsNew), Reissue(SWOP, toTreasure, true), ScriptTransfer(farmingTreasureAddr, toTreasure, SWOP)] ++ lockEntries) | |
491 | 489 | else throw("Strict value is not equal to itself.") | |
492 | 490 | } | |
493 | 491 | } | |
494 | 492 | else throw("Strict value is not equal to itself.") | |
495 | 493 | } | |
496 | 494 | }) | |
497 | 495 | ||
498 | 496 | ||
499 | 497 | ||
500 | 498 | @Callable(i) | |
501 | 499 | func lockStakedShareTokens (pool,lockType,lockAmount) = valueOrElse(isActive(), { | |
502 | 500 | let shareAssetId = getShareAssetId(pool) | |
503 | 501 | let user = toString(i.originCaller) | |
504 | 502 | let totalShare = getTotalShareToken(pool) | |
505 | 503 | let totalShareVirtual = valueOrElse(getInteger(this, (pool + kShareTokensVirtual)), totalShare) | |
506 | 504 | let userStakedAmount = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensStaked)), 0) | |
507 | 505 | let userLockedHeigt = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensLockedHeight)), 0) | |
508 | 506 | let userLockedAmount = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensLocked)), 0) | |
509 | 507 | let userAmountVirtual = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensVirtual)), userStakedAmount) | |
510 | 508 | let totalUserShareTokens = (userStakedAmount + userLockedAmount) | |
511 | - | let $ | |
512 | - | let lockPeriod = $ | |
513 | - | let lockCoef = $ | |
509 | + | let $t02331923371 = getLockParams(lockType) | |
510 | + | let lockPeriod = $t02331923371._1 | |
511 | + | let lockCoef = $t02331923371._2 | |
514 | 512 | let lockWavesFee = getIntegerValue(this, kLockWavesFee) | |
515 | 513 | if ((getHeightFirstHarvest(pool) > height)) | |
516 | 514 | then throw("You can't lock shareTokens till first harvest end.") | |
517 | 515 | else if ((0 >= lockType)) | |
518 | 516 | then throw("lockType must be > 0") | |
519 | 517 | else if ((lockAmount > userStakedAmount)) | |
520 | 518 | then throw(("You can't lock more than " + toString(userStakedAmount))) | |
521 | 519 | else if ((accountBalance(shareAssetId) > totalShare)) | |
522 | 520 | then throw("Balance of share-token is lower than totalAmount") | |
523 | 521 | else if (if ((userLockedHeigt == 0)) | |
524 | 522 | then if (if ((1 > size(i.payments))) | |
525 | 523 | then true | |
526 | 524 | else (i.payments[0].assetId != unit)) | |
527 | 525 | then true | |
528 | 526 | else (lockWavesFee > i.payments[0].amount) | |
529 | 527 | else false) | |
530 | 528 | then throw((("You need to pay additional waves comission " + toString(lockWavesFee)) + "WAVES")) | |
531 | 529 | else if (if ((userLockedHeigt == 0)) | |
532 | 530 | then (0 >= lockAmount) | |
533 | 531 | else false) | |
534 | 532 | then throw("lockAmount must be greater than 0") | |
535 | 533 | else if ((0 > lockAmount)) | |
536 | 534 | then throw("lockAmount must be positive") | |
537 | 535 | else if ((userLockedHeigt > (height + lockPeriod))) | |
538 | 536 | then throw("You cannot lock sharetokens for a period less than what you have already locked") | |
539 | 537 | else { | |
540 | 538 | let userLockedAmountNew = (userLockedAmount + lockAmount) | |
541 | 539 | let userStakedAmountNew = (userStakedAmount - lockAmount) | |
542 | 540 | let userLockedHeigtNew = (height + lockPeriod) | |
543 | 541 | let userAmountVirtualNew = (fraction(userLockedAmountNew, lockCoef, lockBoostCoefScale) + userStakedAmount) | |
544 | - | let $ | |
545 | - | let farmInterest = $ | |
546 | - | let boostInterest = $ | |
547 | - | let boostLPinterest = $ | |
548 | - | let claimAmount = $ | |
549 | - | let toTreasure = $ | |
542 | + | let $t02465824757 = claimCalc(pool, user) | |
543 | + | let farmInterest = $t02465824757._1 | |
544 | + | let boostInterest = $t02465824757._2 | |
545 | + | let boostLPinterest = $t02465824757._3 | |
546 | + | let claimAmount = $t02465824757._4 | |
547 | + | let toTreasure = $t02465824757._5 | |
550 | 548 | let availableFundsNew = (userAvailableSWOP(pool, user) + claimAmount) | |
551 | 549 | [IntegerEntry((((pool + "_") + user) + kUserShareTokensStaked), userStakedAmountNew), IntegerEntry((((pool + "_") + user) + kUserShareTokensLocked), userLockedAmountNew), IntegerEntry((((pool + "_") + user) + kUserShareTokensLockedHeight), userLockedHeigtNew), IntegerEntry((((pool + "_") + user) + kUserShareTokensLockedType), lockType), IntegerEntry((((pool + "_") + user) + kUserShareTokensVirtual), userAmountVirtualNew), IntegerEntry((pool + kShareTokensVirtual), ((totalShareVirtual - userAmountVirtual) + userAmountVirtualNew)), IntegerEntry((((pool + "_") + user) + kFarmUserLastInterest), farmInterest), IntegerEntry((((pool + "_") + user) + kBoostUserLastInterest), boostInterest), IntegerEntry((((pool + "_") + user) + kBoostLPUserLastInterest), boostLPinterest), IntegerEntry((pool + kFarmLastInterest), farmInterest), IntegerEntry((pool + kBoostLastInterest), boostInterest), IntegerEntry((pool + kBoostLPLastInterest), boostLPinterest), IntegerEntry((pool + kLastInterestHeight), height), IntegerEntry((((pool + "_") + user) + kAvailableSWOP), availableFundsNew), Reissue(SWOP, toTreasure, true), ScriptTransfer(farmingTreasureAddr, toTreasure, SWOP)] | |
552 | 550 | } | |
553 | 551 | }) | |
554 | 552 | ||
555 | 553 | ||
556 | 554 | ||
557 | 555 | @Callable(i) | |
558 | 556 | func unlockUserLock (pool,user) = valueOrElse(isActive(), { | |
559 | 557 | let lockWavesFee = getIntegerValue(this, kLockWavesFee) | |
560 | 558 | let userLockedHeigt = valueOrErrorMessage(getInteger(this, (((pool + "_") + user) + kUserShareTokensLockedHeight)), (((("There is no pool " + pool) + " or user ") + user) + "with lock")) | |
561 | 559 | let totalShareVirtual = getIntegerValue(this, (pool + kShareTokensVirtual)) | |
562 | 560 | let userStakedAmount = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensStaked)), 0) | |
563 | 561 | let userLockedAmount = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensLocked)), 0) | |
564 | 562 | let userAmountVirtual = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensVirtual)), userStakedAmount) | |
565 | 563 | if ((userLockedHeigt > height)) | |
566 | 564 | then throw(("You can't unlock sharetokens till " + toString(userLockedHeigt))) | |
567 | 565 | else { | |
568 | 566 | let userStakedAmountNew = (userStakedAmount + userLockedAmount) | |
569 | - | let $ | |
570 | - | let farmInterest = $ | |
571 | - | let boostInterest = $ | |
572 | - | let boostLPinterest = $ | |
573 | - | let claimAmount = $ | |
574 | - | let toTreasure = $ | |
567 | + | let $t02698727086 = claimCalc(pool, user) | |
568 | + | let farmInterest = $t02698727086._1 | |
569 | + | let boostInterest = $t02698727086._2 | |
570 | + | let boostLPinterest = $t02698727086._3 | |
571 | + | let claimAmount = $t02698727086._4 | |
572 | + | let toTreasure = $t02698727086._5 | |
575 | 573 | let availableFundsNew = (userAvailableSWOP(pool, user) + claimAmount) | |
576 | - | [IntegerEntry((((pool + "_") + user) + kFarmUserLastInterest), farmInterest), IntegerEntry((((pool + "_") + user) + kBoostUserLastInterest), boostInterest), IntegerEntry((((pool + "_") + user) + kBoostLPUserLastInterest), boostLPinterest), IntegerEntry((pool + kFarmLastInterest), farmInterest), IntegerEntry((pool + kBoostLastInterest), boostInterest), IntegerEntry((pool + kBoostLPLastInterest), boostLPinterest), IntegerEntry((pool + kLastInterestHeight), height), IntegerEntry((((pool + "_") + user) + kUserShareTokensStaked), userStakedAmountNew), IntegerEntry((((pool + "_") + user) + kUserShareTokensVirtual), userStakedAmountNew), IntegerEntry((pool + kShareTokensVirtual), ((totalShareVirtual - userAmountVirtual) + userStakedAmountNew)), DeleteEntry((((pool + "_") + user) + kUserShareTokensLocked)), DeleteEntry((((pool + "_") + user) + kUserShareTokensLockedHeight)), DeleteEntry((((pool + "_") + user) + kUserShareTokensLockedType)), Reissue(SWOP, toTreasure, true), ScriptTransfer(farmingTreasureAddr, toTreasure, SWOP), ScriptTransfer(i.caller, lockWavesFee, unit)] | |
574 | + | [IntegerEntry((((pool + "_") + user) + kFarmUserLastInterest), farmInterest), IntegerEntry((((pool + "_") + user) + kBoostUserLastInterest), boostInterest), IntegerEntry((((pool + "_") + user) + kBoostLPUserLastInterest), boostLPinterest), IntegerEntry((pool + kFarmLastInterest), farmInterest), IntegerEntry((pool + kBoostLastInterest), boostInterest), IntegerEntry((pool + kBoostLPLastInterest), boostLPinterest), IntegerEntry((pool + kLastInterestHeight), height), IntegerEntry((((pool + "_") + user) + kUserShareTokensStaked), userStakedAmountNew), IntegerEntry((((pool + "_") + user) + kUserShareTokensVirtual), userStakedAmountNew), IntegerEntry((pool + kShareTokensVirtual), ((totalShareVirtual - userAmountVirtual) + userStakedAmountNew)), IntegerEntry((((pool + "_") + user) + kAvailableSWOP), availableFundsNew), DeleteEntry((((pool + "_") + user) + kUserShareTokensLocked)), DeleteEntry((((pool + "_") + user) + kUserShareTokensLockedHeight)), DeleteEntry((((pool + "_") + user) + kUserShareTokensLockedType)), Reissue(SWOP, toTreasure, true), ScriptTransfer(farmingTreasureAddr, toTreasure, SWOP), ScriptTransfer(i.caller, lockWavesFee, unit)] | |
577 | 575 | } | |
578 | 576 | }) | |
579 | 577 | ||
580 | 578 | ||
581 | 579 | ||
582 | 580 | @Callable(i) | |
583 | 581 | func withdrawShareTokens (pool,shareTokensWithdrawAmount) = valueOrElse(isActive(), { | |
584 | 582 | let shareTokensId = fromBase58String(getStringValue(value(addressFromString(pool)), "share_asset_id")) | |
585 | 583 | let user = toString(i.originCaller) | |
586 | - | let $ | |
587 | - | let farmInterest = $ | |
588 | - | let boostInterest = $ | |
589 | - | let boostLPinterest = $ | |
590 | - | let claimAmount = $ | |
591 | - | let toTreasure = $ | |
584 | + | let $t02866128760 = claimCalc(pool, user) | |
585 | + | let farmInterest = $t02866128760._1 | |
586 | + | let boostInterest = $t02866128760._2 | |
587 | + | let boostLPinterest = $t02866128760._3 | |
588 | + | let claimAmount = $t02866128760._4 | |
589 | + | let toTreasure = $t02866128760._5 | |
592 | 590 | let userStakedAmount = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensStaked)), 0) | |
593 | 591 | let userLockedAmount = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensLocked)), 0) | |
594 | 592 | let userAmountVirtual = valueOrElse(getInteger(this, (((pool + "_") + user) + kUserShareTokensVirtual)), userStakedAmount) | |
595 | 593 | let userStakedAmountNew = (userStakedAmount - shareTokensWithdrawAmount) | |
596 | 594 | let availableFundsNew = (userAvailableSWOP(pool, user) + claimAmount) | |
597 | 595 | let totalShareAmount = getTotalShareToken(pool) | |
598 | 596 | let totalShareVirtual = valueOrElse(getInteger(this, (pool + kShareTokensVirtual)), totalShareAmount) | |
599 | 597 | let totalShareAmountNew = (totalShareAmount - shareTokensWithdrawAmount) | |
600 | 598 | let totalShareVirtualNew = (totalShareVirtual - shareTokensWithdrawAmount) | |
601 | 599 | let userAmountVirtualNew = (userAmountVirtual - shareTokensWithdrawAmount) | |
602 | 600 | if ((shareTokensWithdrawAmount > userStakedAmount)) | |
603 | 601 | then throw("Withdraw amount more then user locked amount") | |
604 | 602 | else if ((accountBalance(shareTokensId) > totalShareAmount)) | |
605 | 603 | then throw("Balance of share-token is lower than totalAmount") | |
606 | 604 | else { | |
607 | 605 | let uplp = if ((getString(Address(fromBase58String(pool)), "version") == "3.0.0")) | |
608 | 606 | then invoke(lpFarmingAddress, "updateUserInterest", [pool, (userStakedAmount + userLockedAmount)], nil) | |
609 | 607 | else 0 | |
610 | 608 | if ((uplp == uplp)) | |
611 | 609 | then [IntegerEntry((((pool + "_") + user) + kFarmUserLastInterest), farmInterest), IntegerEntry((((pool + "_") + user) + kBoostUserLastInterest), boostInterest), IntegerEntry((((pool + "_") + user) + kBoostLPUserLastInterest), boostLPinterest), IntegerEntry((pool + kFarmLastInterest), farmInterest), IntegerEntry((pool + kBoostLastInterest), boostInterest), IntegerEntry((pool + kBoostLPLastInterest), boostLPinterest), IntegerEntry((pool + kLastInterestHeight), height), IntegerEntry((((pool + "_") + user) + kUserShareTokensStaked), userStakedAmountNew), IntegerEntry((((pool + "_") + user) + kUserShareTokensVirtual), userAmountVirtualNew), IntegerEntry((pool + kShareTotalShareTokens), totalShareAmountNew), IntegerEntry((pool + kShareTokensVirtual), totalShareVirtualNew), IntegerEntry((((pool + "_") + user) + kAvailableSWOP), availableFundsNew), Reissue(SWOP, toTreasure, true), ScriptTransfer(farmingTreasureAddr, toTreasure, SWOP), ScriptTransfer(i.caller, shareTokensWithdrawAmount, shareTokensId)] | |
612 | 610 | else throw("Strict value is not equal to itself.") | |
613 | 611 | } | |
614 | 612 | }) | |
615 | 613 | ||
616 | 614 | ||
617 | 615 | ||
618 | 616 | @Callable(i) | |
619 | 617 | func claim (pool) = valueOrElse(isActive(), { | |
620 | 618 | let shareTokensId = fromBase58String(getStringValue(value(addressFromString(pool)), "share_asset_id")) | |
621 | 619 | let user = toString(i.originCaller) | |
622 | 620 | let shareTokenLocked = getTotalShareToken(pool) | |
623 | - | let $ | |
624 | - | let farmInterest = $ | |
625 | - | let boostInterest = $ | |
626 | - | let boostLPinterest = $ | |
627 | - | let claimAmount = $ | |
628 | - | let toTreasure = $ | |
621 | + | let $t03142931528 = claimCalc(pool, user) | |
622 | + | let farmInterest = $t03142931528._1 | |
623 | + | let boostInterest = $t03142931528._2 | |
624 | + | let boostLPinterest = $t03142931528._3 | |
625 | + | let claimAmount = $t03142931528._4 | |
626 | + | let toTreasure = $t03142931528._5 | |
629 | 627 | let availableFund = (userAvailableSWOP(pool, user) + claimAmount) | |
630 | 628 | if ((availableFund == 0)) | |
631 | 629 | then throw("You have 0 available SWOP") | |
632 | 630 | else if ((accountBalance(shareTokensId) > shareTokenLocked)) | |
633 | 631 | then throw("Balance of share-token is lower than totalAmount") | |
634 | 632 | else { | |
635 | 633 | let uTrans = if ((i.caller != this)) | |
636 | 634 | then [ScriptTransfer(i.caller, availableFund, SWOP)] | |
637 | 635 | else nil | |
638 | 636 | $Tuple2(([IntegerEntry((((pool + "_") + user) + kFarmUserLastInterest), farmInterest), IntegerEntry((((pool + "_") + user) + kBoostUserLastInterest), boostInterest), IntegerEntry((((pool + "_") + user) + kBoostLPUserLastInterest), boostLPinterest), IntegerEntry((pool + kFarmLastInterest), farmInterest), IntegerEntry((pool + kBoostLastInterest), boostInterest), IntegerEntry((pool + kBoostLPLastInterest), boostLPinterest), IntegerEntry((pool + kLastInterestHeight), height), IntegerEntry((((pool + "_") + user) + kAvailableSWOP), 0), Reissue(SWOP, (toTreasure + availableFund), true), ScriptTransfer(farmingTreasureAddr, toTreasure, SWOP)] ++ uTrans), availableFund) | |
639 | 637 | } | |
640 | 638 | }) | |
641 | 639 | ||
642 | 640 | ||
643 | 641 | ||
644 | 642 | @Callable(i) | |
645 | 643 | func claimAndStake (pool) = valueOrElse(isActive(), { | |
646 | 644 | let claimAmount = { | |
647 | 645 | let @ = invoke(this, "claim", [pool], nil) | |
648 | 646 | if ($isInstanceOf(@, "Int")) | |
649 | 647 | then @ | |
650 | 648 | else throw(($getType(@) + " couldn't be cast to Int")) | |
651 | 649 | } | |
652 | 650 | if ((claimAmount == claimAmount)) | |
653 | 651 | then { | |
654 | 652 | let stakeToGov = invoke(govAddress, "lockSWOPFromFarming", nil, [AttachedPayment(SWOP, claimAmount)]) | |
655 | 653 | if ((stakeToGov == stakeToGov)) | |
656 | 654 | then nil | |
657 | 655 | else throw("Strict value is not equal to itself.") | |
658 | 656 | } | |
659 | 657 | else throw("Strict value is not equal to itself.") | |
660 | 658 | }) | |
661 | 659 | ||
662 | 660 | ||
663 | 661 | ||
664 | 662 | @Callable(i) | |
665 | 663 | func claimAll (pools) = valueOrElse(isActive(), { | |
666 | 664 | func claimInv (claimTotal,pool) = { | |
667 | 665 | let claimAmount = { | |
668 | 666 | let @ = invoke(this, "claim", [pool], nil) | |
669 | 667 | if ($isInstanceOf(@, "Int")) | |
670 | 668 | then @ | |
671 | 669 | else throw(($getType(@) + " couldn't be cast to Int")) | |
672 | 670 | } | |
673 | 671 | if ((claimAmount == claimAmount)) | |
674 | 672 | then (claimTotal + claimAmount) | |
675 | 673 | else throw("Strict value is not equal to itself.") | |
676 | 674 | } | |
677 | 675 | ||
678 | 676 | let claimTotal = { | |
679 | 677 | let $l = pools | |
680 | 678 | let $s = size($l) | |
681 | 679 | let $acc0 = 0 | |
682 | 680 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
683 | 681 | then $a | |
684 | 682 | else claimInv($a, $l[$i]) | |
685 | 683 | ||
686 | 684 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
687 | 685 | then $a | |
688 | 686 | else throw("List size exceeds 60") | |
689 | 687 | ||
690 | 688 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($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), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20), 21), 22), 23), 24), 25), 26), 27), 28), 29), 30), 31), 32), 33), 34), 35), 36), 37), 38), 39), 40), 41), 42), 43), 44), 45), 46), 47), 48), 49), 50), 51), 52), 53), 54), 55), 56), 57), 58), 59), 60) | |
691 | 689 | } | |
692 | 690 | if ((claimTotal == 0)) | |
693 | 691 | then throw("You have 0 available SWOP") | |
694 | 692 | else [ScriptTransfer(i.caller, claimTotal, SWOP)] | |
695 | 693 | }) | |
696 | 694 | ||
697 | 695 | ||
698 | 696 | ||
699 | 697 | @Callable(i) | |
700 | 698 | func claimAllAndStake (pools) = valueOrElse(isActive(), { | |
701 | 699 | func claimInv (claimTotal,pool) = { | |
702 | 700 | let claimAmount = { | |
703 | 701 | let @ = invoke(this, "claim", [pool], nil) | |
704 | 702 | if ($isInstanceOf(@, "Int")) | |
705 | 703 | then @ | |
706 | 704 | else throw(($getType(@) + " couldn't be cast to Int")) | |
707 | 705 | } | |
708 | 706 | if ((claimAmount == claimAmount)) | |
709 | 707 | then (claimTotal + claimAmount) | |
710 | 708 | else throw("Strict value is not equal to itself.") | |
711 | 709 | } | |
712 | 710 | ||
713 | 711 | let claimTotal = { | |
714 | 712 | let $l = pools | |
715 | 713 | let $s = size($l) | |
716 | 714 | let $acc0 = 0 | |
717 | 715 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
718 | 716 | then $a | |
719 | 717 | else claimInv($a, $l[$i]) | |
720 | 718 | ||
721 | 719 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
722 | 720 | then $a | |
723 | 721 | else throw("List size exceeds 60") | |
724 | 722 | ||
725 | 723 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($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), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20), 21), 22), 23), 24), 25), 26), 27), 28), 29), 30), 31), 32), 33), 34), 35), 36), 37), 38), 39), 40), 41), 42), 43), 44), 45), 46), 47), 48), 49), 50), 51), 52), 53), 54), 55), 56), 57), 58), 59), 60) | |
726 | 724 | } | |
727 | 725 | if ((claimTotal == 0)) | |
728 | 726 | then throw("You have 0 available SWOP") | |
729 | 727 | else { | |
730 | 728 | let stakeToGov = invoke(govAddress, "lockSWOPFromFarming", nil, [AttachedPayment(SWOP, claimTotal)]) | |
731 | 729 | if ((stakeToGov == stakeToGov)) | |
732 | 730 | then nil | |
733 | 731 | else throw("Strict value is not equal to itself.") | |
734 | 732 | } | |
735 | 733 | }) | |
736 | 734 | ||
737 | 735 | ||
738 | 736 | ||
739 | 737 | @Callable(i) | |
740 | 738 | func updateUserBoostInterest (pool,user) = valueOrElse(isActive(), if ((i.caller != votingAddress)) | |
741 | 739 | then throw("Only voiting can call this function") | |
742 | 740 | else { | |
743 | - | let $ | |
744 | - | let farmInterest = $ | |
745 | - | let boostInterest = $ | |
746 | - | let boostLPinterest = $ | |
747 | - | let claimAmount = $ | |
748 | - | let toTreasure = $ | |
741 | + | let $t03396634065 = claimCalc(pool, user) | |
742 | + | let farmInterest = $t03396634065._1 | |
743 | + | let boostInterest = $t03396634065._2 | |
744 | + | let boostLPinterest = $t03396634065._3 | |
745 | + | let claimAmount = $t03396634065._4 | |
746 | + | let toTreasure = $t03396634065._5 | |
749 | 747 | let availableFundsNew = (userAvailableSWOP(pool, user) + claimAmount) | |
750 | 748 | [IntegerEntry((((pool + "_") + user) + kFarmUserLastInterest), farmInterest), IntegerEntry((((pool + "_") + user) + kBoostUserLastInterest), boostInterest), IntegerEntry((((pool + "_") + user) + kBoostLPUserLastInterest), boostLPinterest), IntegerEntry((pool + kFarmLastInterest), farmInterest), IntegerEntry((pool + kBoostLastInterest), boostInterest), IntegerEntry((pool + kBoostLPLastInterest), boostLPinterest), IntegerEntry((pool + kLastInterestHeight), height), IntegerEntry((((pool + "_") + user) + kAvailableSWOP), availableFundsNew), Reissue(SWOP, toTreasure, true), ScriptTransfer(farmingTreasureAddr, toTreasure, SWOP)] | |
751 | 749 | }) | |
752 | 750 | ||
753 | 751 | ||
754 | 752 | ||
755 | 753 | @Callable(i) | |
756 | 754 | func shutdown () = valueOrElse(isAdminCall(i), if (!(active)) | |
757 | 755 | then throw(("DApp is already suspended. Cause: " + valueOrElse(getString(this, kCause), "the cause wasn't specified"))) | |
758 | 756 | else suspend("Paused by admin")) | |
759 | 757 | ||
760 | 758 | ||
761 | 759 | ||
762 | 760 | @Callable(i) | |
763 | 761 | func activate () = valueOrElse(isAdminCall(i), if (active) | |
764 | 762 | then throw("DApp is already active") | |
765 | 763 | else [BooleanEntry(kActive, true), DeleteEntry(kCause)]) | |
766 | 764 | ||
767 | 765 | ||
768 | 766 | @Verifier(tx) | |
769 | 767 | func verify () = match tx { | |
770 | 768 | case _ => | |
771 | 769 | let adminPubKey1Signed = if (sigVerify(tx.bodyBytes, tx.proofs[0], adminPubKey1)) | |
772 | 770 | then 1 | |
773 | 771 | else 0 | |
774 | 772 | let adminPubKey2Signed = if (sigVerify(tx.bodyBytes, tx.proofs[1], adminPubKey2)) | |
775 | 773 | then 1 | |
776 | 774 | else 0 | |
777 | 775 | let adminPubKey3Signed = if (sigVerify(tx.bodyBytes, tx.proofs[2], adminPubKey3)) | |
778 | 776 | then 1 | |
779 | 777 | else 0 | |
780 | 778 | (((adminPubKey1Signed + adminPubKey2Signed) + adminPubKey3Signed) >= 2) | |
781 | 779 | } | |
782 | 780 |
github/deemru/w8io/169f3d6 178.65 ms ◑