tx · 9An7Am6Q36Lv6ZFJwchdJCzpoMB2cKt8VUNWwu6j5J1P

3P7i87v9nfk6Tft8YumLrJJPLRjRrALk4iL:  -0.21000000 Waves

2024.04.16 22:43 [4131729] smart account 3P7i87v9nfk6Tft8YumLrJJPLRjRrALk4iL > SELF 0.00000000 Waves

{ "type": 13, "id": "9An7Am6Q36Lv6ZFJwchdJCzpoMB2cKt8VUNWwu6j5J1P", "fee": 21000000, "feeAssetId": null, "timestamp": 1713296633704, "version": 2, "chainId": 87, "sender": "3P7i87v9nfk6Tft8YumLrJJPLRjRrALk4iL", "senderPublicKey": "5Q7KaPEFgx9Ntm4ZtF9zABB52E1mjRVpJmEyWRJmorzf", "proofs": [ "44pA1JDHtzqieTsUALUKd4WgS1oZPZNrnG7gXA7j32GKFcEbVYFxqcXCHLWMyF6Zn9QCxfhmDWUDyEasiytT8Kbz" ], "script": "base64:AAIFAAAAAAAAACwIAhIDCgEIEgMKAQgSBAoCCAgSBQoDCAgBEgUKAwgEBBIDCgEIEgASAwoBCAAAADcAAAAABVNjYWxlAAAAAAAF9eEAAQAAABR0cnlHZXRTdHJpbmdFeHRlcm5hbAAAAAIAAAAHYWRkcmVzcwAAAANrZXkEAAAAByRtYXRjaDAJAAQdAAAAAgUAAAAHYWRkcmVzcwUAAAADa2V5AwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAAAZTdHJpbmcEAAAAAWEFAAAAByRtYXRjaDAFAAAAAWECAAAAAAEAAAAMdHJ5R2V0U3RyaW5nAAAAAQAAAANrZXkJAQAAABR0cnlHZXRTdHJpbmdFeHRlcm5hbAAAAAIFAAAABHRoaXMFAAAAA2tleQEAAAAcc3RhdGljS2V5X3JlZkNvbnRyYWN0QWRkcmVzcwAAAAACAAAAGXN0YXRpY19yZWZDb250cmFjdEFkZHJlc3MAAAAAFWtleUdsb2JhbExhc3RJbnRlcmVzdAIAAAAZZ2xvYmFsX2xhc3RDaGVja19pbnRlcmVzdAEAAAAXc3RhdGljS2V5X29yY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lU3Rha2luZwYAAAABaQEAAAALY2xhaW1SZXdhcmQAAAABAAAAB2Fzc2V0SWQEAAAADHZhbGlkUGF5bWVudAkBAAAAFmNoZWNrQWRkaXRpb25hbFBheW1lbnQAAAABCQABkQAAAAIIBQAAAAFpAAAACHBheW1lbnRzAAAAAAAAAAAAAwkAAAAAAAACBQAAAAx2YWxpZFBheW1lbnQFAAAADHZhbGlkUGF5bWVudAMJAQAAAAIhPQAAAAIJAQAAAAx0cnlHZXRTdHJpbmcAAAABCQABLAAAAAIFAAAAB2Fzc2V0SWQCAAAABl9vd25lcgkABCUAAAABCAUAAAABaQAAAAZjYWxsZXIJAAACAAAAAQIAAAAZWW91IGRvbid0IG93biB0aGlzIGR1Y2shIQMJAABmAAAAAgkAAZAAAAABCAUAAAABaQAAAAhwYXltZW50cwAAAAAAAAAAAQkAAAIAAAABAgAAAB9QbGVhc2UgZG9uJ3QgYWRkIGV4dHJhIHBheW1lbnRzBAAAAAZyZXN1bHQJAQAAABJjbGFpbVN0YWtpbmdSZXN1bHQAAAADCQAEJQAAAAEIBQAAAAFpAAAABmNhbGxlcgUAAAAHYXNzZXRJZAYJAAUUAAAAAgkABE4AAAACBQAAAAx2YWxpZFBheW1lbnQIBQAAAAZyZXN1bHQAAAACXzEIBQAAAAZyZXN1bHQAAAACXzIJAAACAAAAAQIAAAAkU3RyaWN0IHZhbHVlIGlzIG5vdCBlcXVhbCB0byBpdHNlbGYuAAAAACESaEQ=", "height": 4131729, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: DEpenZeWftsqFWdYDLK4bRJwZzMcQSa8njzMGDAFU7iT Next: 6GKEbnLiWkHxTh9dYEnFFE9heRhecXDEYU6sZsVwC4fB Diff:
OldNewDifferences
448448 @Callable(i)
449449 func unstakeNFT (asset) = {
450450 let address = toString(i.caller)
451- let validPayment = checkAdditionalPayment(i.payments[0])
452- if ((validPayment == validPayment))
451+ let result = claimStakingResult(address, asset, true)
452+ if ((result == result))
453453 then {
454- let color = tryGetString((((("address_" + address) + "_asset_") + asset) + "_perchColor"))
455- let withoutPerch = tryGetBoolean((asset + "_without_perch"))
456- let perches = if (withoutPerch)
457- then nil
458- else {
459- let usePerchOrigin = tryGetBoolean((asset + "_use_origin"))
460- let perchOwner = if (usePerchOrigin)
461- then toString(i.originCaller)
462- else address
454+ let validPayment = checkAdditionalPayment(i.payments[0])
455+ if ((validPayment == validPayment))
456+ then {
457+ let color = tryGetString((((("address_" + address) + "_asset_") + asset) + "_perchColor"))
458+ let withoutPerch = tryGetBoolean((asset + "_without_perch"))
459+ let perches = if (withoutPerch)
460+ then nil
461+ else {
462+ let usePerchOrigin = tryGetBoolean((asset + "_use_origin"))
463+ let perchOwner = if (usePerchOrigin)
464+ then toString(i.originCaller)
465+ else address
463466 [IntegerEntry(((("address_" + address) + "_perchesAvailable_") + color), (tryGetInteger(((("address_" + address) + "_perchesAvailable_") + color)) + 1))]
464- }
465- if ((perches == perches))
466- then {
467- let result = claimStakingResult(address, asset, true)
468- if ((result == result))
467+ }
468+ if ((perches == perches))
469469 then {
470470 let assetFP = tryGetInteger(assetFarmingPower(address, asset))
471471 if ((assetFP == assetFP))
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let Scale = 100000000
55
66 func tryGetStringExternal (address,key) = match getString(address, key) {
77 case a: String =>
88 a
99 case _ =>
1010 ""
1111 }
1212
1313
1414 func tryGetString (key) = tryGetStringExternal(this, key)
1515
1616
1717 func staticKey_refContractAddress () = "static_refContractAddress"
1818
1919
2020 let keyGlobalLastInterest = "global_lastCheck_interest"
2121
2222 func staticKey_oracleAddress () = "static_oracleAddress"
2323
2424
2525 func staticKey_eggAssetId () = "static_eggAssetId"
2626
2727
2828 func staticKey_incubatorAddress () = "static_incubatorAddress"
2929
3030
3131 func staticKey_breederAddress () = "static_breederAddress"
3232
3333
3434 func staticKey_accBoosterAddress () = "static_accBoosterAddress"
3535
3636
3737 func staticKey_couponsAddress () = "static_couponsAddress"
3838
3939
4040 func staticKey_burnAddress () = "static_burnAddress"
4141
4242
4343 func staticKey_extraFee () = "static_extraFee"
4444
4545
4646 func staticKey_feeAggregator () = "static_feeAggregator"
4747
4848
4949 let keyGlobalEarned = "global_earnings"
5050
5151 func staticKey_perchFee () = "static_perchFee"
5252
5353
5454 func staticKey_rebirthAddress () = "static_rebirthAddress"
5555
5656
5757 func staticKey_turtleRebirthAddress () = "static_turtleRebirthAddress"
5858
5959
6060 func staticKey_itemsAddress () = "static_itemsAddress"
6161
6262
6363 func totalStakedKey () = "total_staked"
6464
6565
6666 func staticKey_proxyStakingContracts () = "static_proxyStakingContracts"
6767
6868
6969 func getOracle () = Address(fromBase58String(tryGetString(staticKey_oracleAddress())))
7070
7171
7272 func getRebirthAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_rebirthAddress())))
7373
7474
7575 func getEggAssetId () = fromBase58String(tryGetStringExternal(getOracle(), staticKey_eggAssetId()))
7676
7777
7878 func getIncubatorAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_incubatorAddress())))
7979
8080
8181 func getBreederAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_breederAddress())))
8282
8383
8484 func getAccBoosterAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_accBoosterAddress())))
8585
8686
8787 func getCouponsAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_couponsAddress())))
8888
8989
9090 func getBurnAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_burnAddress())))
9191
9292
9393 func getFeeAggregator () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_feeAggregator())))
9494
9595
9696 func getRefContractAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_refContractAddress())))
9797
9898
9999 func getTurtleRebirthAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_turtleRebirthAddress())))
100100
101101
102102 func getItemsAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_itemsAddress())))
103103
104104
105105 func getProxyStaking () = tryGetStringExternal(getOracle(), staticKey_proxyStakingContracts())
106106
107107
108108 func keyLastCheckInterest (address,asset) = (((("address_" + address) + "_asset_") + asset) + "_lastCheckInterest")
109109
110110
111111 func assetFarmingPower (address,asset) = (((("address_" + address) + "_asset_") + asset) + "_farmingPower")
112112
113113
114114 func rewardClaimedKey (address,asset) = (((address + "_asset_") + asset) + "_claimed")
115115
116116
117117 func totalStakedUserKey (address) = ("total_staked_" + address)
118118
119119
120120 let RefererReward = 5
121121
122122 func checkAdditionalPayment (payment) = if (isDefined(payment.assetId))
123123 then throw("FCAP: Please attach waves")
124124 else {
125125 let feeAmount = getIntegerValue(getOracle(), staticKey_extraFee())
126126 if ((payment.amount != feeAmount))
127127 then throw((("FCAP: Please attach exactly " + toString(feeAmount)) + " amount of wavelets"))
128128 else [ScriptTransfer(getFeeAggregator(), feeAmount, unit)]
129129 }
130130
131131
132132 func tryGetInteger (key) = match getInteger(this, key) {
133133 case b: Int =>
134134 b
135135 case _ =>
136136 0
137137 }
138138
139139
140140 func asInt (value) = match value {
141141 case int: Int =>
142142 int
143143 case _ =>
144144 throw("FAI: wrong type, expected: Int")
145145 }
146146
147147
148148 func asIntTuple (value) = match value {
149149 case int: (Int, Int) =>
150150 int
151151 case _ =>
152152 throw("FAI: wrong type, expected: (Int,Int)")
153153 }
154154
155155
156156 func handleStakingTopUp (amount) = {
157157 let currentInterest = tryGetInteger(keyGlobalLastInterest)
158158 let totalStakedAmount = tryGetInteger(totalStakedKey())
159159 let interestDelta = if ((totalStakedAmount > 0))
160160 then fraction(amount, Scale, totalStakedAmount)
161161 else 0
162162 [IntegerEntry(keyGlobalEarned, (tryGetInteger(keyGlobalEarned) + amount)), IntegerEntry(keyGlobalLastInterest, (currentInterest + interestDelta))]
163163 }
164164
165165
166166 func asString (value) = match value {
167167 case string: String =>
168168 string
169169 case _ =>
170170 throw("FAS: wrong type, expected: String")
171171 }
172172
173173
174174 func tryGetBoolean (key) = match getBoolean(this, key) {
175175 case b: Boolean =>
176176 b
177177 case _ =>
178178 false
179179 }
180180
181181
182182 func tryGetBooleanExternal (address,key) = match getBoolean(address, key) {
183183 case b: Boolean =>
184184 b
185185 case _ =>
186186 false
187187 }
188188
189189
190190 func getAssetOrigin (generation) = if ((generation == "G"))
191191 then getIncubatorAddress()
192192 else getBreederAddress()
193193
194194
195195 func getAssetRarity (genotype,generation) = {
196196 let quantity = valueOrErrorMessage(getInteger(getAssetOrigin(generation), (("stats_" + genotype) + "_quantity")), (("stats_" + genotype) + "_quantity not found"))
197197 let power = pow((10000 / quantity), 4, 5, 1, 2, FLOOR)
198198 if ((power > 0))
199199 then power
200200 else 2
201201 }
202202
203203
204204 func getAssetRarityComplete (isJackpot,assetName) = {
205205 let rarity = if (isJackpot)
206206 then 100
207207 else {
208208 let generation = take(takeRight(assetName, 2), 1)
209209 let farmGen = asString(invoke(getBreederAddress(), "getGenFromName", [assetName], nil))
210210 if ((farmGen == farmGen))
211211 then getAssetRarity(farmGen, generation)
212212 else throw("Strict value is not equal to itself.")
213213 }
214214 rarity
215215 }
216216
217217
218218 func updateFarmingPower (address,asset) = {
219219 let totalStaked = tryGetInteger(totalStakedKey())
220220 let totalStakedUser = tryGetInteger(totalStakedUserKey(address))
221221 let currentFP = tryGetInteger(assetFarmingPower(address, asset))
222222 let newFP = asIntTuple(invoke(this, "calculateFarmPower", [asset], nil))
223223 if ((currentFP != 0))
224224 then [IntegerEntry(totalStakedKey(), ((totalStaked - currentFP) + newFP._1)), IntegerEntry(totalStakedUserKey(address), ((totalStakedUser - currentFP) + newFP._1)), IntegerEntry(assetFarmingPower(address, asset), newFP._1), IntegerEntry("DEBUG_currentFP", currentFP), IntegerEntry("DEBUG_newFP", newFP._1)]
225225 else nil
226226 }
227227
228228
229229 func claimStakingResult (address,asset,recalc) = {
230230 let currentInterest = tryGetInteger(keyGlobalLastInterest)
231231 let lastCheckInterest = tryGetInteger(keyLastCheckInterest(address, asset))
232232 let stakedAmount = tryGetInteger(assetFarmingPower(address, asset))
233233 let fpUpdate = if (recalc)
234234 then updateFarmingPower(address, asset)
235235 else nil
236236 if ((fpUpdate == fpUpdate))
237237 then {
238238 let reward = if ((lastCheckInterest > 0))
239239 then fraction((currentInterest - lastCheckInterest), stakedAmount, Scale)
240240 else 0
241241 $Tuple2(([ScriptTransfer(Address(fromBase58String(address)), reward, getEggAssetId()), IntegerEntry(keyLastCheckInterest(address, asset), currentInterest), IntegerEntry(rewardClaimedKey(address, asset), (tryGetInteger(rewardClaimedKey(address, asset)) + reward))] ++ fpUpdate), reward)
242242 }
243243 else throw("Strict value is not equal to itself.")
244244 }
245245
246246
247247 func asBoolean (value) = match value {
248248 case boolean: Boolean =>
249249 boolean
250250 case _ =>
251251 throw("FAB: wrong type, expected: Boolean")
252252 }
253253
254254
255255 func calculatePerchPrice (address) = {
256256 let hasArtefactStaked = tryGetStringExternal(getAccBoosterAddress(), (("ART-XMISTL_" + address) + "_owner"))
257257 let perchPrice = getIntegerValue(getOracle(), staticKey_perchFee())
258258 if ((hasArtefactStaked == ""))
259259 then perchPrice
260260 else ((perchPrice / 10) * 9)
261261 }
262262
263263
264264 func isProxyStakingSc (address) = {
265265 let allowedContracts = getProxyStaking()
266266 let allowedContractsList = split(allowedContracts, ";")
267267 (indexOf(allowedContractsList, address) != unit)
268268 }
269269
270270
271271 @Callable(i)
272272 func calculateFarmPower (assetId) = if (!(if ((value(assetInfo(fromBase58String(assetId))).issuer == getBreederAddress()))
273273 then true
274274 else (value(assetInfo(fromBase58String(assetId))).issuer == getIncubatorAddress())))
275275 then throw("This does not seem like a valid Duck!")
276276 else {
277277 let assetName = value(assetInfo(fromBase58String(assetId))).name
278278 let gen = takeRight(assetName, 1)
279279 let isJackpot = (takeRight(assetName, 1) == "U")
280280 let rarity = getAssetRarityComplete(isJackpot, assetName)
281281 let genotype = split(dropRight(drop(assetName, 5), 3), "")
282282 func uniqueArrayFilter (accum,nextGen) = if (!(containsElement(accum, nextGen)))
283283 then (accum :+ nextGen)
284284 else accum
285285
286286 let uniqueList = {
287287 let $l = genotype
288288 let $s = size($l)
289289 let $acc0 = nil
290290 func $f0_1 ($a,$i) = if (($i >= $s))
291291 then $a
292292 else uniqueArrayFilter($a, $l[$i])
293293
294294 func $f0_2 ($a,$i) = if (($i >= $s))
295295 then $a
296296 else throw("List size exceeds 8")
297297
298298 $f0_2($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)
299299 }
300300 let totalGenes = if ((gen == "U"))
301301 then 8
302302 else size(uniqueList)
303303 let power = pow(15, 1, totalGenes, 0, 2, DOWN)
304304 let multiplier = (((height - 3750000) * 100) / (((60 * 24) * 30) * 3))
305305 let basePower = tryGetInteger((assetId + "_basePower"))
306306 let finalPower = if ((basePower > 0))
307307 then basePower
308308 else ((power * multiplier) / 100)
309309 let finalPowerRarity = ((finalPower * rarity) / 100)
310310 let farmBoost = asInt(invoke(getItemsAddress(), "calculateFarmingPowerBoost", [assetId, toString(i.originCaller)], nil))
311311 if ((farmBoost == farmBoost))
312312 then {
313313 let finalPowerRarityBoost = (finalPowerRarity + ((finalPowerRarity * farmBoost) / 100))
314314 $Tuple2([IntegerEntry(("DEBUG_" + assetName), finalPower), IntegerEntry(("DEBUG_RARITY" + assetName), rarity), IntegerEntry(("DEBUG_FPRARITY_" + assetName), finalPowerRarity), IntegerEntry(("DEBUG_BASEPOWER_" + assetName), basePower), IntegerEntry(("DEBUG_COEFFICIENT_" + assetName), multiplier), IntegerEntry(("DEBUG_BOOST_" + assetName), farmBoost)], $Tuple2(finalPowerRarityBoost, finalPower))
315315 }
316316 else throw("Strict value is not equal to itself.")
317317 }
318318
319319
320320
321321 @Callable(i)
322322 func configureOracle (oracle) = if ((i.caller != this))
323323 then throw("FCO: admin only")
324324 else [StringEntry(staticKey_oracleAddress(), oracle)]
325325
326326
327327
328328 @Callable(i)
329329 func buyPerch (colorI,refererAddress) = {
330330 let validPayment = checkAdditionalPayment(i.payments[0])
331331 if ((validPayment == validPayment))
332332 then {
333333 let color = if ((colorI == "U"))
334334 then "B"
335335 else colorI
336336 if ((0 > value(indexOf(["B", "R", "G", "Y"], color))))
337337 then throw("you need to set color properly")
338338 else {
339339 let exactPrice = calculatePerchPrice(toString(i.caller))
340340 let leftToPay = if ((i.originCaller == i.caller))
341341 then {
342342 let amountPaidByCoupons = asInt(invoke(getCouponsAddress(), "useCoupons", [exactPrice], nil))
343343 if ((amountPaidByCoupons == amountPaidByCoupons))
344344 then (exactPrice - amountPaidByCoupons)
345345 else throw("Strict value is not equal to itself.")
346346 }
347347 else exactPrice
348348 let firstPayment = if ((size(i.payments) == 2))
349349 then value(i.payments[1])
350350 else value(i.payments[0])
351351 if ((firstPayment.assetId != getEggAssetId()))
352352 then throw(("FBP: You can attach only EGG tokens with the following asset id: " + toBase58String(getEggAssetId())))
353353 else if ((firstPayment.amount != leftToPay))
354354 then throw(((("FBP: To buy a perch you currently need the following amount of EGGlets: " + toString(leftToPay)) + " ") + toString(i.caller)))
355355 else {
356356 let refererRewardForPerch = fraction(leftToPay, 5, 100)
357357 let refCall = asBoolean(invoke(getRefContractAddress(), "refPayment", [refererAddress], [AttachedPayment(getEggAssetId(), refererRewardForPerch)]))
358358 if ((refCall == refCall))
359359 then {
360360 let toBurn = if (refCall)
361361 then (leftToPay - refererRewardForPerch)
362362 else leftToPay
363363 let burnCall = invoke(getBurnAddress(), "burnAttachedPayments", nil, [AttachedPayment(getEggAssetId(), toBurn)])
364364 if ((burnCall == burnCall))
365365 then {
366366 let perchAmountKey = ((("address_" + toString(i.caller)) + "_perchesAvailable_") + color)
367367 let perchAmount = tryGetInteger(perchAmountKey)
368368 ([IntegerEntry(perchAmountKey, (perchAmount + 1))] ++ validPayment)
369369 }
370370 else throw("Strict value is not equal to itself.")
371371 }
372372 else throw("Strict value is not equal to itself.")
373373 }
374374 }
375375 }
376376 else throw("Strict value is not equal to itself.")
377377 }
378378
379379
380380
381381 @Callable(i)
382382 func addFreePerch (address,color,amount) = if ((0 > value(indexOf(["B", "R", "G", "Y"], color))))
383383 then throw("you need to set color properly")
384384 else if (if (if ((i.caller != getRebirthAddress()))
385385 then (i.caller != getTurtleRebirthAddress())
386386 else false)
387387 then (i.caller != this)
388388 else false)
389389 then throw("rebirth and admin only")
390390 else {
391391 let perchAmountKey = ((("address_" + address) + "_perchesAvailable_") + color)
392392 let perchAmount = tryGetInteger(perchAmountKey)
393393 $Tuple2([IntegerEntry(perchAmountKey, (perchAmount + amount))], "")
394394 }
395395
396396
397397
398398 @Callable(i)
399399 func stakeNFT (jColor,usePerchOrigin,stakeWithoutPerch) = if (if (stakeWithoutPerch)
400400 then !(isProxyStakingSc(toString(i.caller)))
401401 else false)
402402 then throw("You can't stake without a perch")
403403 else {
404404 let validPayment = checkAdditionalPayment(i.payments[0])
405405 if ((validPayment == validPayment))
406406 then {
407407 let pmt = value(i.payments[1])
408408 let assetId = value(pmt.assetId)
409409 let assetName = value(value(assetInfo(assetId)).name)
410410 let isJackpot = (takeRight(assetName, 1) == "U")
411411 let address = toString(i.caller)
412412 let perchAddress = if (usePerchOrigin)
413413 then toString(i.originCaller)
414414 else address
415415 let rarity = getAssetRarityComplete(isJackpot, assetName)
416416 let perches = if (stakeWithoutPerch)
417417 then nil
418418 else {
419419 let color = if (isJackpot)
420420 then jColor
421421 else takeRight(assetName, 1)
422422 let availablePerches = tryGetInteger(((("address_" + perchAddress) + "_perchesAvailable_") + color))
423423 if ((0 >= availablePerches))
424424 then throw(("no perches available for the color " + color))
425425 else [IntegerEntry(((("address_" + perchAddress) + "_perchesAvailable_") + color), (availablePerches - 1)), StringEntry((((("address_" + address) + "_asset_") + toBase58String(assetId)) + "_perchColor"), color)]
426426 }
427427 if ((perches == perches))
428428 then if ((pmt.amount != 1))
429429 then throw("NFT is not attached")
430430 else {
431431 let farmingPower = asIntTuple(invoke(this, "calculateFarmPower", [toBase58String(assetId)], nil))
432432 if ((farmingPower == farmingPower))
433433 then {
434434 let result = claimStakingResult(address, toBase58String(assetId), false)
435435 if ((result == result))
436436 then ((([IntegerEntry(totalStakedKey(), (tryGetInteger(totalStakedKey()) + farmingPower._1)), IntegerEntry(totalStakedUserKey(address), (tryGetInteger(totalStakedUserKey(address)) + farmingPower._1)), StringEntry((toBase58String(assetId) + "_owner"), address), BooleanEntry((toBase58String(assetId) + "_use_origin"), usePerchOrigin), StringEntry((toBase58String(assetId) + "_original_caller"), toString(i.originCaller)), IntegerEntry(assetFarmingPower(address, toBase58String(assetId)), farmingPower._1), IntegerEntry((toBase58String(assetId) + "_basePower"), farmingPower._2), BooleanEntry((toBase58String(assetId) + "_without_perch"), stakeWithoutPerch)] ++ validPayment) ++ perches) ++ result._1)
437437 else throw("Strict value is not equal to itself.")
438438 }
439439 else throw("Strict value is not equal to itself.")
440440 }
441441 else throw("Strict value is not equal to itself.")
442442 }
443443 else throw("Strict value is not equal to itself.")
444444 }
445445
446446
447447
448448 @Callable(i)
449449 func unstakeNFT (asset) = {
450450 let address = toString(i.caller)
451- let validPayment = checkAdditionalPayment(i.payments[0])
452- if ((validPayment == validPayment))
451+ let result = claimStakingResult(address, asset, true)
452+ if ((result == result))
453453 then {
454- let color = tryGetString((((("address_" + address) + "_asset_") + asset) + "_perchColor"))
455- let withoutPerch = tryGetBoolean((asset + "_without_perch"))
456- let perches = if (withoutPerch)
457- then nil
458- else {
459- let usePerchOrigin = tryGetBoolean((asset + "_use_origin"))
460- let perchOwner = if (usePerchOrigin)
461- then toString(i.originCaller)
462- else address
454+ let validPayment = checkAdditionalPayment(i.payments[0])
455+ if ((validPayment == validPayment))
456+ then {
457+ let color = tryGetString((((("address_" + address) + "_asset_") + asset) + "_perchColor"))
458+ let withoutPerch = tryGetBoolean((asset + "_without_perch"))
459+ let perches = if (withoutPerch)
460+ then nil
461+ else {
462+ let usePerchOrigin = tryGetBoolean((asset + "_use_origin"))
463+ let perchOwner = if (usePerchOrigin)
464+ then toString(i.originCaller)
465+ else address
463466 [IntegerEntry(((("address_" + address) + "_perchesAvailable_") + color), (tryGetInteger(((("address_" + address) + "_perchesAvailable_") + color)) + 1))]
464- }
465- if ((perches == perches))
466- then {
467- let result = claimStakingResult(address, asset, true)
468- if ((result == result))
467+ }
468+ if ((perches == perches))
469469 then {
470470 let assetFP = tryGetInteger(assetFarmingPower(address, asset))
471471 if ((assetFP == assetFP))
472472 then $Tuple2(((([IntegerEntry(totalStakedKey(), (tryGetInteger(totalStakedKey()) - assetFP)), IntegerEntry(totalStakedUserKey(address), (tryGetInteger(totalStakedUserKey(address)) - assetFP)), DeleteEntry((asset + "_owner")), DeleteEntry(assetFarmingPower(address, asset)), DeleteEntry((((("address_" + address) + "_asset_") + asset) + "_perchColor")), DeleteEntry((asset + "_original_caller")), DeleteEntry((asset + "_use_origin")), DeleteEntry((asset + "_without_perch")), ScriptTransfer(Address(fromBase58String(address)), 1, fromBase58String(asset))] ++ validPayment) ++ perches) ++ result._1), result._2)
473473 else throw("Strict value is not equal to itself.")
474474 }
475475 else throw("Strict value is not equal to itself.")
476476 }
477477 else throw("Strict value is not equal to itself.")
478478 }
479479 else throw("Strict value is not equal to itself.")
480480 }
481481
482482
483483
484484 @Callable(i)
485485 func topUpReward () = {
486486 let firstPayment = value(i.payments[0])
487487 if ((firstPayment.assetId != getEggAssetId()))
488488 then throw(("FBP: You can attach only EGG tokens with the following asset id: " + toBase58String(getEggAssetId())))
489489 else {
490490 let resHandleStaking = handleStakingTopUp(firstPayment.amount)
491491 $Tuple2(resHandleStaking, true)
492492 }
493493 }
494494
495495
496496
497497 @Callable(i)
498498 func claimReward (assetId) = {
499499 let validPayment = checkAdditionalPayment(i.payments[0])
500500 if ((validPayment == validPayment))
501501 then if ((tryGetString((assetId + "_owner")) != toString(i.caller)))
502502 then throw("You don't own this duck!!")
503503 else if ((size(i.payments) > 1))
504504 then throw("Please don't add extra payments")
505505 else {
506506 let result = claimStakingResult(toString(i.caller), assetId, true)
507507 $Tuple2((validPayment ++ result._1), result._2)
508508 }
509509 else throw("Strict value is not equal to itself.")
510510 }
511511
512512

github/deemru/w8io/6500d08 
57.21 ms