tx · 67zAgh5xzku45yJZx2ry9vECoZ6QKEHfdwcWu4popPS 3N7KPSUwpMgvDEVGw1DYBnKDiixSQUXhn2P: -0.01000000 Waves 2023.05.31 08:48 [2601747] smart account 3N7KPSUwpMgvDEVGw1DYBnKDiixSQUXhn2P > SELF 0.00000000 Waves
{ "type": 13, "id": "67zAgh5xzku45yJZx2ry9vECoZ6QKEHfdwcWu4popPS", "fee": 1000000, "feeAssetId": null, "timestamp": 1685512153525, "version": 2, "chainId": 84, "sender": "3N7KPSUwpMgvDEVGw1DYBnKDiixSQUXhn2P", "senderPublicKey": "BTvXQMmkgSf57dbcqWxpEvbi3ZYcEeWFkkXDZC6FrneM", "proofs": [ "58VxGJBe28m9v8JJY8nCSzDEfFiHufuWC9pM8itMpASZ5KfwHffDGyHTrDSn4uj1B1WhxXsq2j5yGmf1WEy9TLEL" ], "script": "base64:BgILCAISABIAEgMKAQEBAAxvd25lckFkZHJlc3MCIzNNdmpBYURZSHBTNEE1SzRDVjNrWk1NRUg5bTlKZEJTdmJxAwFpAQRjYWxsAAQFYXNzZXQJAMMIBwIFQXNzZXQCAAABAAAGBQR1bml0AAAEB2Fzc2V0SWQJALgIAQUFYXNzZXQJAMwIAgkBC0JpbmFyeUVudHJ5AgIDYmluAQAJAMwIAgkBDEJvb2xlYW5FbnRyeQICBGJvb2wGCQDMCAIJAQxJbnRlZ2VyRW50cnkCAgNpbnQAAQkAzAgCCQELU3RyaW5nRW50cnkCAgNzdHICAAkAzAgCCQELRGVsZXRlRW50cnkBAgNzdHIJAMwIAgUFYXNzZXQJAMwIAgkBB1JlaXNzdWUDBQdhc3NldElkAAEHCQDMCAIJAQRCdXJuAgUHYXNzZXRJZAABCQDMCAIJAQ5TY3JpcHRUcmFuc2ZlcgMIBQFpBmNhbGxlcgABBQdhc3NldElkBQNuaWwBaQEHZGVwb3NpdAAECmN1cnJlbnRLZXkJANgEAQgIBQFpBmNhbGxlcgVieXRlcwQNZGVwb3NpdEFtb3VudAkAZQIICQ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XB0VHJhbnNmZXIDCAUBaQZjYWxsZXIFEGFtb3VudFRvV2l0aERyYXcFBHVuaXQFA25pbAECdHgBBnZlcmlmeQAH8QgDEw==", "height": 2601747, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 6py2KX9oKWHjv8AHGXqfSjG1nEcZTzrUDV2LBfz2FCQf Next: none Diff:
Old | New | Differences | |
---|---|---|---|
48 | 48 | } | |
49 | 49 | ||
50 | 50 | ||
51 | + | @Verifier(tx) | |
52 | + | func verify () = false | |
53 | + |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let ownerAddress = "3MvjAaDYHpS4A5K4CV3kZMMEH9m9JdBSvbq" | |
5 | 5 | ||
6 | 6 | @Callable(i) | |
7 | 7 | func call () = { | |
8 | 8 | let asset = Issue("Asset", "", 1, 0, true, unit, 0) | |
9 | 9 | let assetId = calculateAssetId(asset) | |
10 | 10 | [BinaryEntry("bin", base58''), BooleanEntry("bool", true), IntegerEntry("int", 1), StringEntry("str", ""), DeleteEntry("str"), asset, Reissue(assetId, 1, false), Burn(assetId, 1), ScriptTransfer(i.caller, 1, assetId)] | |
11 | 11 | } | |
12 | 12 | ||
13 | 13 | ||
14 | 14 | ||
15 | 15 | @Callable(i) | |
16 | 16 | func deposit () = { | |
17 | 17 | let currentKey = toBase58String(i.caller.bytes) | |
18 | 18 | let depositAmount = (i.payments[0].amount - 50000000) | |
19 | 19 | let platformfee = 50000000 | |
20 | 20 | let totalPlatformFee = match getInteger(this, ("platform_bal_" + ownerAddress)) { | |
21 | 21 | case a: Int => | |
22 | 22 | a | |
23 | 23 | case _ => | |
24 | 24 | 0 | |
25 | 25 | } | |
26 | 26 | let platformFeeInc = (totalPlatformFee + platformfee) | |
27 | 27 | [IntegerEntry(("balance_" + currentKey), depositAmount), IntegerEntry(("platform_bal_" + ownerAddress), platformFeeInc)] | |
28 | 28 | } | |
29 | 29 | ||
30 | 30 | ||
31 | 31 | ||
32 | 32 | @Callable(i) | |
33 | 33 | func withDraw (amountToWithDraw) = { | |
34 | 34 | let Caller = toBase58String(i.caller.bytes) | |
35 | 35 | let currentKey = toBase58String(i.caller.bytes) | |
36 | 36 | let currentPlatformAmount = match getInteger(this, ("platform_bal_" + Caller)) { | |
37 | 37 | case a: Int => | |
38 | 38 | a | |
39 | 39 | case _ => | |
40 | 40 | 0 | |
41 | 41 | } | |
42 | 42 | let newAmount = (currentPlatformAmount - amountToWithDraw) | |
43 | 43 | if ((Caller != ownerAddress)) | |
44 | 44 | then throw("Not Authorized") | |
45 | 45 | else if ((currentPlatformAmount == 0)) | |
46 | 46 | then throw("No sufficent amount available") | |
47 | 47 | else [IntegerEntry(("platform_bal_" + ownerAddress), newAmount), ScriptTransfer(i.caller, amountToWithDraw, unit)] | |
48 | 48 | } | |
49 | 49 | ||
50 | 50 | ||
51 | + | @Verifier(tx) | |
52 | + | func verify () = false | |
53 | + |
github/deemru/w8io/026f985 51.23 ms ◑