tx · dX2UN3RNEztfkuGicESXU9hXDUGFjV91Qcg7cGjTNq2 3Mrcd5V4by5mqq1rcZjBdMCYxwo37TpAtxP: -0.01000000 Waves 2019.09.22 01:23 [686679] smart account 3Mrcd5V4by5mqq1rcZjBdMCYxwo37TpAtxP > SELF 0.00000000 Waves
{ "type": 13, "id": "dX2UN3RNEztfkuGicESXU9hXDUGFjV91Qcg7cGjTNq2", "fee": 1000000, "feeAssetId": null, "timestamp": 1569104621967, "version": 1, "sender": "3Mrcd5V4by5mqq1rcZjBdMCYxwo37TpAtxP", "senderPublicKey": "AQfAEineEN1RXA9QHVe6dr6rrRzjqGJfvmJjeCnQ4bJu", "proofs": [ "3HQpfA9g3EEV8eQyu8JFfY8XY9DdRShLJABuUFWYHDyUF2Dqam6tgi9vPpAohBYf8ruhLJXqvEhP5fyoP685t3Nk" ], "script": "base64:AAIDAAAAAAAAAAAAAAAAAAAAAgAAAAFpAQAAAAdkZXBvc2l0AAAAAAQAAAADcG10CQEAAAAHZXh0cmFjdAAAAAEIBQAAAAFpAAAAB3BheW1lbnQEAAAAB2Fzc2V0SWQBAAAAINQACMqlB9ytuJVvN0N4wlLd392Q18ZJ9k630z9kPueAAwkBAAAACWlzRGVmaW5lZAAAAAEIBQAAAANwbXQAAAAHYXNzZXRJZAkAAAIAAAABAgAAACFjYW4gaG9kbCBBQWljbyBvbmx5IGF0IHRoZSBtb21lbnQEAAAACmN1cnJlbnRLZXkJAAJYAAAAAQgIBQAAAAFpAAAABmNhbGxlcgAAAAVieXRlcwQAAAANY3VycmVudEFtb3VudAQAAAAHJG1hdGNoMAkABBoAAAACBQAAAAR0aGlzBQAAAApjdXJyZW50S2V5AwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAAANJbnQEAAAAAWEFAAAAByRtYXRjaDAFAAAAAWEAAAAAAAAAAAAEAAAACW5ld0Ftb3VudAkAAGQAAAACBQAAAA1jdXJyZW50QW1vdW50CAUAAAADcG10AAAABmFtb3VudAkBAAAACFdyaXRlU2V0AAAAAQkABEwAAAACCQEAAAAJRGF0YUVudHJ5AAAAAgUAAAAKY3VycmVudEtleQUAAAAJbmV3QW1vdW50BQAAAANuaWwAAAABaQEAAAAId2l0aGRyYXcAAAABAAAABmFtb3VudAQAAAAKY3VycmVudEtleQkAAlgAAAABCAgFAAAAAWkAAAAGY2FsbGVyAAAABWJ5dGVzBAAAAA1jdXJyZW50QW1vdW50BAAAAAckbWF0Y2gwCQAEGgAAAAIFAAAABHRoaXMFAAAACmN1cnJlbnRLZXkDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAAA0ludAQAAAABYQUAAAAHJG1hdGNoMAUAAAABYQAAAAAAAAAAAAQAAAAJbmV3QW1vdW50CQAAZQAAAAIFAAAADWN1cnJlbnRBbW91bnQFAAAABmFtb3VudAMJAABmAAAAAgAAAAAAAAAAAAUAAAAGYW1vdW50CQAAAgAAAAECAAAAHkNhbid0IHdpdGhkcmF3IG5lZ2F0aXZlIGFtb3VudAMJAABmAAAAAgAAAAAAAAAAAAUAAAAJbmV3QW1vdW50CQAAAgAAAAECAAAAEk5vdCBlbm91Z2ggYmFsYW5jZQkBAAAADFNjcmlwdFJlc3VsdAAAAAIJAQAAAAhXcml0ZVNldAAAAAEJAARMAAAAAgkBAAAACURhdGFFbnRyeQAAAAIFAAAACmN1cnJlbnRLZXkFAAAACW5ld0Ftb3VudAUAAAADbmlsCQEAAAALVHJhbnNmZXJTZXQAAAABCQAETAAAAAIJAQAAAA5TY3JpcHRUcmFuc2ZlcgAAAAMIBQAAAAFpAAAABmNhbGxlcgUAAAAGYW1vdW50BQAAAAR1bml0BQAAAANuaWwAAAABAAAAAnR4AQAAAAZ2ZXJpZnkAAAAABj4M+88=", "chainId": 84, "height": 686679, "spentComplexity": 0 } View: original | compacted Prev: 48SQ2wFQhZQWEBRnpvsW1B1n3tXyi35TZuXn6BGjuemq Next: wzhbBrdP3PeXq6krnBbpALZhiEuwEzVqN7oc7TL5cM4 Full:
Old | New | Differences | |
---|---|---|---|
1 | - | # no script | |
1 | + | {-# STDLIB_VERSION 3 #-} | |
2 | + | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | + | {-# CONTENT_TYPE DAPP #-} | |
4 | + | ||
5 | + | ||
6 | + | @Callable(a) | |
7 | + | func deposit () = { | |
8 | + | let b = extract(a.payment) | |
9 | + | let c = base58'FGZTpAqL2wwfXwFRX32tAeD88Uaw8LSt3DPS312XodHZ' | |
10 | + | if (isDefined(b.assetId)) | |
11 | + | then throw("can hodl AAico only at the moment") | |
12 | + | else { | |
13 | + | let d = toBase58String(a.caller.bytes) | |
14 | + | let e = { | |
15 | + | let f = getInteger(this, d) | |
16 | + | if ($isInstanceOf(f, "Int")) | |
17 | + | then { | |
18 | + | let g = f | |
19 | + | g | |
20 | + | } | |
21 | + | else 0 | |
22 | + | } | |
23 | + | let h = (e + b.amount) | |
24 | + | WriteSet([DataEntry(d, h)]) | |
25 | + | } | |
26 | + | } | |
27 | + | ||
28 | + | ||
29 | + | ||
30 | + | @Callable(a) | |
31 | + | func withdraw (i) = { | |
32 | + | let d = toBase58String(a.caller.bytes) | |
33 | + | let e = { | |
34 | + | let f = getInteger(this, d) | |
35 | + | if ($isInstanceOf(f, "Int")) | |
36 | + | then { | |
37 | + | let g = f | |
38 | + | g | |
39 | + | } | |
40 | + | else 0 | |
41 | + | } | |
42 | + | let h = (e - i) | |
43 | + | if ((0 > i)) | |
44 | + | then throw("Can't withdraw negative amount") | |
45 | + | else if ((0 > h)) | |
46 | + | then throw("Not enough balance") | |
47 | + | else ScriptResult(WriteSet([DataEntry(d, h)]), TransferSet([ScriptTransfer(a.caller, i, unit)])) | |
48 | + | } | |
49 | + | ||
50 | + | ||
51 | + | @Verifier(j) | |
52 | + | func k () = true | |
53 | + |
github/deemru/w8io/026f985 19.73 ms ◑