tx · 348YvZ9W4o9UPwcw3SjWEhNncUg7ZDPWywySSxgX4Cp7 3MvxjufyuqvWF7Xow4Cr5f4pt8pDBjhZk3z: -0.03000000 Waves 2019.02.11 16:00 [490516] smart account 3MvxjufyuqvWF7Xow4Cr5f4pt8pDBjhZk3z > SELF 0.00000000 Waves
{ "type": 13, "id": "348YvZ9W4o9UPwcw3SjWEhNncUg7ZDPWywySSxgX4Cp7", "fee": 3000000, "feeAssetId": null, "timestamp": 1549890025436, "version": 1, "sender": "3MvxjufyuqvWF7Xow4Cr5f4pt8pDBjhZk3z", "senderPublicKey": "BevoHd8L9zbiLiS2S9EeHooPhoYhGtLAiE7nHtPvCJiM", "proofs": [ "5uGNFqJLjtrG9rNSbUzFHKrPhzvpVwU5GZ2AQwXcbeEw8fE6ESQaWtu6CWx2wfxWBXW79ZgR4gLydKNfTLz7g7L6" ], "script": "base64:AQQAAAAJYmV0QW1vdW50AAAAAAAF9eEABAAAAAlkYXRhVHhGZWUAAAAAAACYloAEAAAACXBheW91dEZlZQAAAAAAAAehIAQAAAAGcGxheWVyCAUAAAACdHgAAAAGc2VuZGVyBAAAAAN3aW4AAAAAAAAAAAIEAAAAByRtYXRjaDAFAAAAAnR4AwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAAA9EYXRhVHJhbnNhY3Rpb24EAAAAAXQFAAAAByRtYXRjaDAEAAAACXRtcENob2ljZQkBAAAAB2V4dHJhY3QAAAABCQAEEAAAAAIIBQAAAAF0AAAABGRhdGECAAAABkNob2ljZQQAAAALcGF5bWVudFR4SWQJAQAAAAdleHRyYWN0AAAAAQkABBMAAAACCAUAAAABdAAAAARkYXRhAgAAAAtsYXN0UGF5bWVudAQAAAAJcGF5bWVudFR4CQAD6AAAAAEJAAJZAAAAAQUAAAALcGF5bWVudFR4SWQEAAAAByRtYXRjaDEFAAAACXBheW1lbnRUeAMJAAABAAAAAgUAAAAHJG1hdGNoMQIAAAATVHJhbnNmZXJUcmFuc2FjdGlvbgQAAAAJcGF5bWVudFR4BQAAAAckbWF0Y2gxAwMDCQAAZwAAAAIAAAAAAAAAAAMFAAAACXRtcENob2ljZQkAAGcAAAACBQAAAAl0bXBDaG9pY2UAAAAAAAAAAAEHCQAAAAAAAAIJAAGQAAAAAQgFAAAAAXQAAAAEZGF0YQAAAAAAAAAAAwcJAAH0AAAAAwgFAAAAAXQAAAAJYm9keUJ5dGVzCQABkQAAAAIIBQAAAAF0AAAABnByb29mcwAAAAAAAAAAAAgFAAAACXBheW1lbnRUeAAAAA9zZW5kZXJQdWJsaWNLZXkHBgMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAATVHJhbnNmZXJUcmFuc2FjdGlvbgQAAAAGcGF5b3V0BQAAAAckbWF0Y2gwBAAAAAtwYXltZW50VHhJZAkBAAAAB2V4dHJhY3QAAAABCQAEHQAAAAIFAAAABnBsYXllcgIAAAALbGFzdFBheW1lbnQEAAAACXBheW1lbnRUeAkAA+gAAAABCQACWQAAAAEFAAAAC3BheW1lbnRUeElkBAAAAAxoZWlnaHRDaG9pY2UJAQAAAAdleHRyYWN0AAAAAQkABBoAAAACBQAAAAZwbGF5ZXIFAAAAC3BheW1lbnRUeElkBAAAAAckbWF0Y2gxBQAAAAlwYXltZW50VHgDCQAAAQAAAAIFAAAAByRtYXRjaDECAAAAE1RyYW5zZmVyVHJhbnNhY3Rpb24EAAAACXBheW1lbnRUeAUAAAAHJG1hdGNoMQMJAAAAAAAAAgkBAAAAB2V4dHJhY3QAAAABCQAEGgAAAAIFAAAABnBsYXllcgIAAAAGQ2hvaWNlBQAAAAN3aW4JAAAAAAAAAggFAAAACXBheW1lbnRUeAAAAAZzZW5kZXIIBQAAAAZwYXlvdXQAAAAJcmVjaXBpZW50BwcHch/iIA==", "chainId": 84, "height": 490516, "spentComplexity": 0 } View: original | compacted Prev: none Next: none Full:
Old | New | Differences | |
---|---|---|---|
1 | - | # no script | |
1 | + | {-# STDLIB_VERSION 1 #-} | |
2 | + | {-# CONTENT_TYPE EXPRESSION #-} | |
3 | + | let betAmount = 100000000 | |
4 | + | let dataTxFee = 10000000 | |
5 | + | let payoutFee = 500000 | |
6 | + | let player = tx.sender | |
7 | + | let win = 2 | |
8 | + | match tx { | |
9 | + | case t: DataTransaction => | |
10 | + | let tmpChoice = extract(getInteger(t.data, "Choice")) | |
11 | + | let paymentTxId = extract(getString(t.data, "lastPayment")) | |
12 | + | let paymentTx = transactionById(fromBase58String(paymentTxId)) | |
13 | + | match paymentTx { | |
14 | + | case paymentTx: TransferTransaction => | |
15 | + | if (if (if ((3 >= tmpChoice)) | |
16 | + | then (tmpChoice >= 1) | |
17 | + | else false) | |
18 | + | then (size(t.data) == 3) | |
19 | + | else false) | |
20 | + | then sigVerify(t.bodyBytes, t.proofs[0], paymentTx.senderPublicKey) | |
21 | + | else false | |
22 | + | case _ => | |
23 | + | true | |
24 | + | } | |
25 | + | case payout: TransferTransaction => | |
26 | + | let paymentTxId = extract(getString(player, "lastPayment")) | |
27 | + | let paymentTx = transactionById(fromBase58String(paymentTxId)) | |
28 | + | let heightChoice = extract(getInteger(player, paymentTxId)) | |
29 | + | match paymentTx { | |
30 | + | case paymentTx: TransferTransaction => | |
31 | + | if ((extract(getInteger(player, "Choice")) == win)) | |
32 | + | then (paymentTx.sender == payout.recipient) | |
33 | + | else false | |
34 | + | case _ => | |
35 | + | false | |
36 | + | } | |
37 | + | case _ => | |
38 | + | false | |
39 | + | } |
github/deemru/w8io/169f3d6 20.17 ms ◑