tx · AD1YgTuwL84uZ9gpSVht3tNpUPQNWh6MrrzgpeRNJDJD 3N2NxFvbt7RQaebRczCfLyjWZrYXkPBXbwP: -0.01400000 Waves 2019.02.10 18:18 [489212] smart account 3N2NxFvbt7RQaebRczCfLyjWZrYXkPBXbwP > SELF 0.00000000 Waves
{ "type": 13, "id": "AD1YgTuwL84uZ9gpSVht3tNpUPQNWh6MrrzgpeRNJDJD", "fee": 1400000, "feeAssetId": null, "timestamp": 1549811908135, "version": 1, "sender": "3N2NxFvbt7RQaebRczCfLyjWZrYXkPBXbwP", "senderPublicKey": "7MNJWcbtg9vUAPF7P7qnZfL5DwHwWhtnVXBEkDrMgVmD", "proofs": [ "2GmsdSmAUvMCzvKGLS24tvMLeEMizmmMGNYUEKYaENs5s8vsPwJoygCgQ5NJHii2tC64T4oHBAyvkftZjPdEqEZZ" ], "script": "base64:AQQAAAAIb25lV2F2ZXMAAAAAAAX14QAEAAAAC3BheWVkQW1vdW50CQAAaAAAAAIAAAAAAAAAAAEFAAAACG9uZVdhdmVzBAAAAApwYXllZFR4RmVlCQAAaQAAAAIFAAAACG9uZVdhdmVzAAAAAAAAAAAKBAAAAAlkYXRhVHhGZWUJAABpAAAAAgUAAAAIb25lV2F2ZXMAAAAAAAAAAAoEAAAABnNxdWFyZQAAAAAAAAAAMgQAAAAIc3RhcnRQb3MAAAAAAAAAAAAEAAAABmVuZFBvcwkAAGkAAAACCQAAaQAAAAIJAABoAAAAAgAAAAAAAAAD6AAAAAAAAAAD6AUAAAAGc3F1YXJlBQAAAAZzcXVhcmUEAAAAEWxhc3RIZWlnaHRGb3JTYWxlAAAAAAAAB3oQBAAAABVhZGRyZXNzVG9QYXlQdWJsaWNLZXkBAAAAII59m1WbITiydrSsh5p7DTg06jWuC97IwDX0JxhY8UwtBAAAAAxhZGRyZXNzVG9QYXkJAQAAABRhZGRyZXNzRnJvbVB1YmxpY0tleQAAAAEFAAAAFWFkZHJlc3NUb1BheVB1YmxpY0tleQQAAAALbWVQ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GVzCQABkQAAAAIIBQAAAAF0AAAABnByb29mcwAAAAAAAAAAAAgFAAAACXBheW1lbnRUeAAAAA9zZW5kZXJQdWJsaWNLZXkHCQAAAAAAAAIIBQAAAAF0AAAAA2ZlZQUAAAAJZGF0YVR4RmVlBwcJAAH0AAAAAwgFAAAAAnR4AAAACWJvZHlCeXRlcwkAAZEAAAACCAUAAAACdHgAAAAGcHJvb2ZzAAAAAAAAAAAABQAAAAttZVB1YmxpY0tleRTi/kY=", "chainId": 84, "height": 489212, "spentComplexity": 0 } View: original | compacted Prev: 6GAVkAAZtBeL2R3ht5NVYuKHTe19hQoNVzwM1SJnmfHi Next: none Diff:
Old | New | Differences | |
---|---|---|---|
7 | 7 | let square = 50 | |
8 | 8 | let startPos = 0 | |
9 | 9 | let endPos = (((1000 * 1000) / square) / square) | |
10 | - | let lastHeightForSale = | |
10 | + | let lastHeightForSale = 490000 | |
11 | 11 | let addressToPayPublicKey = base58'AbDyruBD8QqodWvMWRxAx8FhwRuf4cMFZu6SA1G4YwWU' | |
12 | 12 | let addressToPay = addressFromPublicKey(addressToPayPublicKey) | |
13 | 13 | let mePublicKey = base58'7MNJWcbtg9vUAPF7P7qnZfL5DwHwWhtnVXBEkDrMgVmD' |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 1 #-} | |
2 | 2 | {-# CONTENT_TYPE EXPRESSION #-} | |
3 | 3 | let oneWaves = 100000000 | |
4 | 4 | let payedAmount = (1 * oneWaves) | |
5 | 5 | let payedTxFee = (oneWaves / 10) | |
6 | 6 | let dataTxFee = (oneWaves / 10) | |
7 | 7 | let square = 50 | |
8 | 8 | let startPos = 0 | |
9 | 9 | let endPos = (((1000 * 1000) / square) / square) | |
10 | - | let lastHeightForSale = | |
10 | + | let lastHeightForSale = 490000 | |
11 | 11 | let addressToPayPublicKey = base58'AbDyruBD8QqodWvMWRxAx8FhwRuf4cMFZu6SA1G4YwWU' | |
12 | 12 | let addressToPay = addressFromPublicKey(addressToPayPublicKey) | |
13 | 13 | let mePublicKey = base58'7MNJWcbtg9vUAPF7P7qnZfL5DwHwWhtnVXBEkDrMgVmD' | |
14 | 14 | let me = addressFromPublicKey(mePublicKey) | |
15 | 15 | match tx { | |
16 | 16 | case t: DataTransaction => | |
17 | 17 | let insertPos = extract(getInteger(t.data, "pos")) | |
18 | 18 | let paymentTxId = extract(getString(t.data, "pTxId")) | |
19 | 19 | let satisfiesFormat = if (if (if (if (if ((size(t.data) == 4)) | |
20 | 20 | then isDefined(getInteger(t.data, "pos")) | |
21 | 21 | else false) | |
22 | 22 | then isDefined(getString(t.data, toString(insertPos))) | |
23 | 23 | else false) | |
24 | 24 | then isDefined(getString(t.data, "pTxId")) | |
25 | 25 | else false) | |
26 | 26 | then isDefined(getBoolean(t.data, paymentTxId)) | |
27 | 27 | else false) | |
28 | 28 | then (extract(getBoolean(t.data, paymentTxId)) == true) | |
29 | 29 | else false | |
30 | 30 | let validPos = if ((insertPos >= startPos)) | |
31 | 31 | then (endPos >= insertPos) | |
32 | 32 | else false | |
33 | 33 | let posNotUsed = if (!(isDefined(getString(me, toString(insertPos))))) | |
34 | 34 | then true | |
35 | 35 | else (insertPos == endPos) | |
36 | 36 | let txIdNotUsed = !(isDefined(getBoolean(me, paymentTxId))) | |
37 | 37 | let dataTransactionIsValid = if (if (if (satisfiesFormat) | |
38 | 38 | then validPos | |
39 | 39 | else false) | |
40 | 40 | then posNotUsed | |
41 | 41 | else false) | |
42 | 42 | then txIdNotUsed | |
43 | 43 | else false | |
44 | 44 | let paymentTx = transactionById(fromBase58String(paymentTxId)) | |
45 | 45 | let heightOfTx = extract(transactionHeightById(fromBase58String(paymentTxId))) | |
46 | 46 | let payedAmountFinal = if ((heightOfTx > lastHeightForSale)) | |
47 | 47 | then payedAmount | |
48 | 48 | else ((payedAmount / 5) * 4) | |
49 | 49 | match paymentTx { | |
50 | 50 | case paymentTx: TransferTransaction => | |
51 | 51 | if (if (if (if (if (dataTransactionIsValid) | |
52 | 52 | then (paymentTx.recipient == addressToPay) | |
53 | 53 | else false) | |
54 | 54 | then (paymentTx.amount >= (payedAmountFinal - payedTxFee)) | |
55 | 55 | else false) | |
56 | 56 | then !(isDefined(paymentTx.assetId)) | |
57 | 57 | else false) | |
58 | 58 | then sigVerify(t.bodyBytes, t.proofs[0], paymentTx.senderPublicKey) | |
59 | 59 | else false) | |
60 | 60 | then (t.fee == dataTxFee) | |
61 | 61 | else false | |
62 | 62 | case _ => | |
63 | 63 | false | |
64 | 64 | } | |
65 | 65 | case _ => | |
66 | 66 | sigVerify(tx.bodyBytes, tx.proofs[0], mePublicKey) | |
67 | 67 | } |
github/deemru/w8io/03bedc9 27.45 ms ◑![]()