tx · EAgsR9QpzCRDQCbu2PgkdCZ8P1d6zfqnQdMfTkr2xH6G

3N34Zi5VD4m9az4kEXWDJngkMHMTpqLcoqo:  -0.01400000 Waves

2021.10.09 20:47 [1739040] smart account 3N34Zi5VD4m9az4kEXWDJngkMHMTpqLcoqo > SELF 0.00000000 Waves

{ "type": 13, "id": "EAgsR9QpzCRDQCbu2PgkdCZ8P1d6zfqnQdMfTkr2xH6G", "fee": 1400000, "feeAssetId": null, "timestamp": 1633801680390, "version": 2, "chainId": 84, "sender": "3N34Zi5VD4m9az4kEXWDJngkMHMTpqLcoqo", "senderPublicKey": "AmXrJ1inc5jpKhf6D9aDcRU8QWHZXBJdBBvz9VsKDe9x", "proofs": [ "4piymbYdmN1ahpGfVB9QEA1LJjwi4GwWaGhhSGJE9Qr3SemcTjKg9G5wBHGMJLQxbhn6i3YFQ3sBn6yG98ZcL1aX" ], "script": "base64:AAIEAAAAAAAAAAQIAhIAAAAACgAAAAALQ09ERUFzc2V0SUQBAAAAINAEYRpFnLQZXHk7APbo5tWij1YQ2cG3R/UN12TTTH73AAAAAAtTdGFydEhlaWdodAAAAAAAABqFEAAAAAAJYmxvY2tkaWZmCQAAZQAAAAIFAAAABmhlaWdodAUAAAALU3RhcnRIZWlnaHQAAAAAB29uZWhvdXIAAAAAAAA27oAAAAAABm9uZWRheQAAAAAABSZcAAAAAAAHb25ld2VlawAAAAAAJAyEAAAAAAAIb25lbW9udGgAAAAAAJy/kEAAAAAADlN0YXJ0SW5mbGF0aW9uCQAAZAAAAAIJAABrAAAAAwAAAAAAAJiWgAAAAAAAAAAAAQUAAAAJYmxvY2tkaWZmAAAAAAAAAAAGAAAAAApGZWVBZGRyZXNzAQAAACBSg9mgi9eQkjsz5eBARHIbc7Hg/F4fmB0sxZ6ySMfiIAAAAAAKZGV2QWRkcmVzcwEAAAAgcT857UGuwl6lKR6zURKH3pDKrZTlUMsXWQXYxcjWeBsAAAABAAAAAWkBAAAABUNsYWltAAAAAAQAAAADcG10C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QAAAABCQAAZQAAAAIFAAAAC1N0YXJ0SGVpZ2h0BQAAAAZoZWlnaHQCAAAAByBibG9ja3MJAARMAAAAAgkBAAAADEludGVnZXJFbnRyeQAAAAICAAAACUluZmxhdGlvbgUAAAAOU3RhcnRJbmZsYXRpb24JAARMAAAAAgkBAAAADEludGVnZXJFbnRyeQAAAAICAAAAElRvdGFsX0lzc3VlZF9DT0RFOgUAAAAPVG90YWxJc3N1ZWRDT0RFCQAETAAAAAIJAQAAAAxJbnRlZ2VyRW50cnkAAAACAgAAABJUb3RhbF9CdXJuZWRfQ09ERToFAAAAD1RvdGFsQnVybmVkQ09ERQkABEwAAAACCQEAAAAEQnVybgAAAAIFAAAAC0NPREVBc3NldElECAUAAAADcG10AAAABmFtb3VudAkABEwAAAACCQEAAAAOU2NyaXB0VHJhbnNmZXIAAAADCAUAAAABaQAAAAZjYWxsZXIFAAAADU5ld0NPREVUb1VzZXIFAAAAC0NPREVBc3NldElECQAETAAAAAIJAQAAAAtTdHJpbmdFbnRyeQAAAAICAAAAB21lc3NhZ2UCAAAAJjxoMT5DT0RFIElzc3VlZCBTdWNjZXNzZnVsbHkhPC9oMT48YnI+BQAAAANuaWwAAAABAAAAAnR4AQAAAAZ2ZXJpZnkAAAAACQAB9AAAAAMIBQAAAAJ0eAAAAAlib2R5Qnl0ZXMJAAGRAAAAAggFAAAAAnR4AAAABnByb29mcwAAAAAAAAAAAAgFAAAAAnR4AAAAD3NlbmRlclB1YmxpY0tleT4zV+A=", "height": 1739040, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: G7zu2W7hTAZoY7sVnozgcCc7BJmxbMDsPSj2ModjRhmU Next: 5BjC9d6ArZzLKPCntwge3V2ycqryBREeXkqGUbWuznrJ Diff:
OldNewDifferences
2828 let NewCODEToUser = (StartInflation * pmt.amount)
2929 let PreviousIssuedCODE = getIntegerValue(this, "Total_Issued_CODE:")
3030 let TotalIssuedCODE = (PreviousIssuedCODE + NewCODEToUser)
31+ let PreviousBurnedCODE = getIntegerValue(this, "Total_Burned_CODE:")
32+ let TotalBurnedCODE = (PreviousBurnedCODE + pmt.amount)
3133 if ((pmt.assetId != CODEAssetID))
3234 then throw(("Incorrect asset attached, please attach " + toBase58String(CODEAssetID)))
3335 else if ((5000000 > pmt.amount))
3436 then throw("Please Attach minimum 0.05 CODE To Issue CODE Asset.")
3537 else if ((StartHeight > height))
3638 then throw((("DApp is Not Started Yet please Wait until " + toString((StartHeight - height))) + " blocks"))
37- else [IntegerEntry("Inflation", StartInflation), Burn(CODEAssetID, pmt.amount), ScriptTransfer(i.caller, NewCODEToUser, CODEAssetID), StringEntry("message", "<h1>CODE Issued Successfully!</h1><br>")]
39+ else [IntegerEntry("Inflation", StartInflation), IntegerEntry("Total_Issued_CODE:", TotalIssuedCODE), IntegerEntry("Total_Burned_CODE:", TotalBurnedCODE), Burn(CODEAssetID, pmt.amount), ScriptTransfer(i.caller, NewCODEToUser, CODEAssetID), StringEntry("message", "<h1>CODE Issued Successfully!</h1><br>")]
3840 }
3941
4042
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 4 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let CODEAssetID = base58'F11g74azdw3SZN83raygbu9useimfTwSQ7HmTLggAq26'
55
66 let StartHeight = 1738000
77
88 let blockdiff = (height - StartHeight)
99
1010 let onehour = 3600000
1111
1212 let oneday = 86400000
1313
1414 let oneweek = 604800000
1515
1616 let onemonth = 2629800000
1717
1818 let StartInflation = (fraction(10000000, 1, blockdiff) + 6)
1919
2020 let FeeAddress = base58'6Z73KxcX3sugpiStpSRXxKxTmWqCaLVwFeM6kwyiKVDR'
2121
2222 let devAddress = base58'8d4zGuTjT3h67Z4DatzMXdXXW1GvoQhMTjwCGFxJuene'
2323
2424 @Callable(i)
2525 func Claim () = {
2626 let pmt = value(i.payments[0])
2727 let currentKey = toBase58String(i.caller.bytes)
2828 let NewCODEToUser = (StartInflation * pmt.amount)
2929 let PreviousIssuedCODE = getIntegerValue(this, "Total_Issued_CODE:")
3030 let TotalIssuedCODE = (PreviousIssuedCODE + NewCODEToUser)
31+ let PreviousBurnedCODE = getIntegerValue(this, "Total_Burned_CODE:")
32+ let TotalBurnedCODE = (PreviousBurnedCODE + pmt.amount)
3133 if ((pmt.assetId != CODEAssetID))
3234 then throw(("Incorrect asset attached, please attach " + toBase58String(CODEAssetID)))
3335 else if ((5000000 > pmt.amount))
3436 then throw("Please Attach minimum 0.05 CODE To Issue CODE Asset.")
3537 else if ((StartHeight > height))
3638 then throw((("DApp is Not Started Yet please Wait until " + toString((StartHeight - height))) + " blocks"))
37- else [IntegerEntry("Inflation", StartInflation), Burn(CODEAssetID, pmt.amount), ScriptTransfer(i.caller, NewCODEToUser, CODEAssetID), StringEntry("message", "<h1>CODE Issued Successfully!</h1><br>")]
39+ else [IntegerEntry("Inflation", StartInflation), IntegerEntry("Total_Issued_CODE:", TotalIssuedCODE), IntegerEntry("Total_Burned_CODE:", TotalBurnedCODE), Burn(CODEAssetID, pmt.amount), ScriptTransfer(i.caller, NewCODEToUser, CODEAssetID), StringEntry("message", "<h1>CODE Issued Successfully!</h1><br>")]
3840 }
3941
4042
4143 @Verifier(tx)
4244 func verify () = sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey)
4345

github/deemru/w8io/169f3d6 
29.63 ms