tx · 4jBKF6N8YpnumZs3u89hdtyKKCT7qxYymwv8whjbVgNW

3N62UHvyvvdresjwfsmW4UX2ffDjcDPAkbn:  -0.01500000 Waves

2022.07.27 16:06 [2158257] smart account 3N62UHvyvvdresjwfsmW4UX2ffDjcDPAkbn > SELF 0.00000000 Waves

{ "type": 13, "id": "4jBKF6N8YpnumZs3u89hdtyKKCT7qxYymwv8whjbVgNW", "fee": 1500000, "feeAssetId": null, "timestamp": 1658927189373, "version": 2, "chainId": 84, "sender": "3N62UHvyvvdresjwfsmW4UX2ffDjcDPAkbn", "senderPublicKey": "5XyQhNxDw1J4WdCZJr14webbFVzP2oXx9Z2BxoYpATJa", "proofs": [ "XuySybKdd3PeKuEoDwokJoPzJkEpXut1kshCbtW9sT5TbLYT6NqxwJ6B1JczpK9QiaeYniRB4dnWXFnq14fXhgf" ], "script": "base64:AAIFAAAAAAAAAAkIAhIAEgMKAQEAAAACAAAAAAlscFRva2VuSWQBAAAAIMIdBqkZfzV/i4CuJnqr29nJI0J9DWiPzidG/cjZWuLnAAAAAA1yZXdhcmRUb2tlbklkAQAAACCqT/PwWY2xlHOeKCUkm14lKMYYhy6I96TnTvbJ9ReluAAAAAIAAAABaQEAAAAGcmV3YXJkAAAAAAQAAAABcAkBAAAABXZhbHVlAAAAAQkAAZEAAAACCAUAAAABaQAAAAhwYXltZW50cwAAAAAAAAAAAAMJAQAAAAIhPQAAAAIIBQAAAAFwAAAAB2Fzc2V0SWQFAAAACWxwVG9rZW5JZAkAAAIAAAABAgAAABFJbmNvcnJlY3QgcGF5bWVudAQAAAAFbHBRdHkICQEAAAAFdmFsdWUAAAABCQAD7AAAAAEFAAAACWxwVG9rZW5JZAAAAAhxdWFudGl0eQQAAAAJcmV3YXJkUXR5CAkBAAAABXZhbHVlAAAAAQkAA+wAAAABBQAAAA1yZXdhcmRUb2tlbklkAAAACHF1YW50aXR5BAAAAAVzaGFyZQkAAGsAAAADCAUAAAABcAAAAAZhbW91bnQFAAAACXJld2FyZFF0eQUAAAAFbHBRdHkEAAAAAXIJAAP8AAAABAUAAAAEdGhpcwIAAAAEYnVybgkABEwAAAACCAUAAAABcAAAAAZhbW91bnQFAAAAA25pbAUAAAADbmlsAwkAAAAAAAACBQAAAAFyBQAAAAFyCQAETAAAAAIJAQAAAA5TY3JpcHRUcmFuc2ZlcgAAAAMIBQAAAAFpAAAABmNhbGxlcgUAAAAFc2hhcmUFAAAADXJld2FyZFRva2VuSWQFAAAAA25pbAkAAAIAAAABAgAAACRTdHJpY3QgdmFsdWUgaXMgbm90IGVxdWFsIHRvIGl0c2VsZi4AAAABaQEAAAAEYnVybgAAAAEAAAAGYW1vdW50CQAETAAAAAIJAQAAAARCdXJuAAAAAgUAAAAJbHBUb2tlbklkBQAAAAZhbW91bnQFAAAAA25pbAAAAAAmaMeN", "height": 2158257, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 4WeAzy9U2RjZdiYDXMbaPoViHsBBaNdyQmNNYAzaS3sm Next: none Diff:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
4-let lpTokenId = base58'HV6n4nFYYYJCYq8n6jLDm8rG1qUps1JeYQgsNPkgJwbB'
4+let lpTokenId = base58'E4jmKWZ4pBuhNYMwUryuWrHpEngo2mR27ANgAZBVdi5U'
55
66 let rewardTokenId = base58'CTq287qYTyvgyDzaaVYuwWeceZUuTsHSKLEfg9YZQFKu'
77
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
4-let lpTokenId = base58'HV6n4nFYYYJCYq8n6jLDm8rG1qUps1JeYQgsNPkgJwbB'
4+let lpTokenId = base58'E4jmKWZ4pBuhNYMwUryuWrHpEngo2mR27ANgAZBVdi5U'
55
66 let rewardTokenId = base58'CTq287qYTyvgyDzaaVYuwWeceZUuTsHSKLEfg9YZQFKu'
77
88 @Callable(i)
99 func reward () = {
1010 let p = value(i.payments[0])
1111 if ((p.assetId != lpTokenId))
1212 then throw("Incorrect payment")
1313 else {
1414 let lpQty = value(assetInfo(lpTokenId)).quantity
1515 let rewardQty = value(assetInfo(rewardTokenId)).quantity
1616 let share = fraction(p.amount, rewardQty, lpQty)
1717 let r = invoke(this, "burn", [p.amount], nil)
1818 if ((r == r))
1919 then [ScriptTransfer(i.caller, share, rewardTokenId)]
2020 else throw("Strict value is not equal to itself.")
2121 }
2222 }
2323
2424
2525
2626 @Callable(i)
2727 func burn (amount) = [Burn(lpTokenId, amount)]
2828
2929

github/deemru/w8io/169f3d6 
36.54 ms