tx · 8cFyMEoz4s7FQ2TKvSqfwyQBQGoWC4pXhtJuLfeEx1mH

3N62UHvyvvdresjwfsmW4UX2ffDjcDPAkbn:  -0.01500000 Waves

2022.07.27 14:57 [2158193] smart account 3N62UHvyvvdresjwfsmW4UX2ffDjcDPAkbn > SELF 0.00000000 Waves

{ "type": 13, "id": "8cFyMEoz4s7FQ2TKvSqfwyQBQGoWC4pXhtJuLfeEx1mH", "fee": 1500000, "feeAssetId": null, "timestamp": 1658923007748, "version": 2, "chainId": 84, "sender": "3N62UHvyvvdresjwfsmW4UX2ffDjcDPAkbn", "senderPublicKey": "5XyQhNxDw1J4WdCZJr14webbFVzP2oXx9Z2BxoYpATJa", "proofs": [ "4qdTsPxE9GPVhXQZQUNjTMWZEHjPC79nMKeY2oWriVkc1B7LWbKuTzcsju6JHLULjb46AZe9TSTG4LHDooky467Y" ], "script": "base64:AAIFAAAAAAAAAAQIAhIAAAAAAgAAAAAJbHBUb2tlbklkAQAAACD07ckYyC0xfprvBupwp+/JlC2r0Ufg/cphwgg13tmbTgAAAAAMcmV3YXJkQW1vdW50AAAAAAAAAAPoAAAAAQAAAAFpAQAAAA1idXJuQW5kUmV3YXJkAAAAAAQAAAABcAkBAAAABXZhbHVlAAAAAQkAAZEAAAACCAUAAAABaQAAAAhwYXltZW50cwAAAAAAAAAAAAMJAQAAAAIhPQAAAAIIBQAAAAFwAAAAB2Fzc2V0SWQFAAAACWxwVG9rZW5JZAkAAAIAAAABAgAAABFJbmNvcnJlY3QgcGF5bWVudAQAAAAFc2hhcmUJAABrAAAAAwgFAAAAAXAAAAAGYW1vdW50BQAAAAxyZXdhcmRBbW91bnQICQEAAAAFdmFsdWUAAAABCQAD7AAAAAEFAAAACWxwVG9rZW5JZAAAAAhxdWFudGl0eQkABEwAAAACCQEAAAAEQnVybgAAAAIFAAAACWxwVG9rZW5JZAgFAAAAAXAAAAAGYW1vdW50CQAETAAAAAIJAQAAAAxJbnRlZ2VyRW50cnkAAAACCQACWAAAAAEICAUAAAABaQAAAAZjYWxsZXIAAAAFYnl0ZXMFAAAABXNoYXJlBQAAAANuaWwAAAAAE2X7qA==", "height": 2158193, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 57WYMgRTAR22yPfJf8zFBwKriokC3gggXz3xQYsahChZ Next: 4WeAzy9U2RjZdiYDXMbaPoViHsBBaNdyQmNNYAzaS3sm Diff:
OldNewDifferences
33 {-# CONTENT_TYPE DAPP #-}
44 let a = base58'HV6n4nFYYYJCYq8n6jLDm8rG1qUps1JeYQgsNPkgJwbB'
55
6-let b = base58'CTq287qYTyvgyDzaaVYuwWeceZUuTsHSKLEfg9YZQFKu'
6+let b = 1000
77
88 @Callable(c)
99 func burnAndReward () = {
1111 if ((d.assetId != a))
1212 then throw("Incorrect payment")
1313 else {
14- let e = fraction(d.amount, value(assetInfo(b)).quantity, value(assetInfo(a)).quantity)
15-[Burn(a, d.amount), ScriptTransfer(c.caller, e, b)]
14+ let e = fraction(d.amount, b, value(assetInfo(a)).quantity)
15+[Burn(a, d.amount), IntegerEntry(toBase58String(c.caller.bytes), e)]
1616 }
1717 }
1818
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let a = base58'HV6n4nFYYYJCYq8n6jLDm8rG1qUps1JeYQgsNPkgJwbB'
55
6-let b = base58'CTq287qYTyvgyDzaaVYuwWeceZUuTsHSKLEfg9YZQFKu'
6+let b = 1000
77
88 @Callable(c)
99 func burnAndReward () = {
1010 let d = value(c.payments[0])
1111 if ((d.assetId != a))
1212 then throw("Incorrect payment")
1313 else {
14- let e = fraction(d.amount, value(assetInfo(b)).quantity, value(assetInfo(a)).quantity)
15-[Burn(a, d.amount), ScriptTransfer(c.caller, e, b)]
14+ let e = fraction(d.amount, b, value(assetInfo(a)).quantity)
15+[Burn(a, d.amount), IntegerEntry(toBase58String(c.caller.bytes), e)]
1616 }
1717 }
1818
1919

github/deemru/w8io/026f985 
22.77 ms