tx · AWAx3ehpPA2XGKm5VAwUixAhv42Nzz6BPokMPRTbyxnk 3MygQawG2gPjoej8wX2cqkxmg7KXAPP6xar: -1.00000000 Waves 2020.09.04 16:41 [1162710] smart asset 3MygQawG2gPjoej8wX2cqkxmg7KXAPP6xar > SELF 0.00000000 Test200
{ "type": 15, "id": "AWAx3ehpPA2XGKm5VAwUixAhv42Nzz6BPokMPRTbyxnk", "fee": 100000000, "feeAssetId": null, "timestamp": 1599226888600, "version": 1, "sender": "3MygQawG2gPjoej8wX2cqkxmg7KXAPP6xar", "senderPublicKey": "BUxg9XtvamV81CZCqrQzi8BxCizU41dpSqoqt5mW56XS", "proofs": [ "61hwuQ8NsFbvAhgTxKD9JdvFAAMpAgTGABUoDT3dQPAZTFmFCxQ8gcJVQ8sYTx15mFihRqe6mKzyq91anDfRttKL" ], "assetId": "ELifKEtwTDt6TVLYYWJKNoCKuNJxzFTDcR5YC8YBWh2e", "script": "base64:AwQAAAALZEFwcEFkZHJlc3MJAQAAABFhZGRyZXNzRnJvbVN0cmluZwAAAAECAAAAIzNNeWdRYXdHMmdQam9lajh3WDJjcWt4bWc3S1hBUFA2eGFyBAAAAAdhZG1pblBLAQAAACCbvoDDAKlv8SHnGnzbjcmS7cF3EYTHum5V5rS3JwBICQQAAAADdGltCQAAaQAAAAIIBQAAAAlsYXN0QmxvY2sAAAAJdGltZXN0YW1wAAAAAAAAAAPoBAAAAAdzcG9uc29yAQAAACBBa8XAYqVvmo8A0b+Cee545P2vz+BaMZNc8EyMlYJWlQQAAAAJc3RhcnRUaW1lAAAAAABfTn4QBAAAAApzdGFydFByaWNlAAAAAAAAAYagBAAAAAxpbnRlcnZhbFRpbWUAAAAAAAAD9IAEAAAADWludGVydmFsUHJpY2UAAAAAAAABhqAEAAAABnBlcmlvZAkAAGkAAAACCQAAZQAAAAIFAAAAA3RpbQUAAAAJc3RhcnRUaW1lBQAAAAxpbnRlcnZhbFRpbWUEAAAACXBlcmlvZEVuZAkAAGQAAAACCQA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AAAAlzZWxsT3JkZXIAAAAFcHJpY2UHBgkAAAIAAAABAgAAABkwLjggPD0gb3JkZXIgcHJpY2UgPD0gMS4yBgJvf8Q=", "chainId": 84, "height": 1162710, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: GrTWKbWFy5QrRRqmAEpzWXJFHCqZiSkirts5weUQcJfo Next: 39ET78RrCbZHVHvuU9ytgdbSFxrVXQZwBkJNM6ZyW2pX Diff:
Old | New | Differences | |
---|---|---|---|
19 | 19 | case t: TransferTransaction => | |
20 | 20 | true | |
21 | 21 | case e: ExchangeTransaction => | |
22 | - | if ((e.buyOrder | |
23 | - | then | |
24 | - | | |
25 | - | | |
26 | - | else if ((e.sellOrder | |
27 | - | then | |
28 | - | | |
29 | - | | |
30 | - | ||
22 | + | if (if (if (isDefined(e.buyOrder)) | |
23 | + | then (e.buyOrder.price >= 80000000) | |
24 | + | else false) | |
25 | + | then true | |
26 | + | else if (isDefined(e.sellOrder)) | |
27 | + | then (120000000 >= e.sellOrder.price) | |
28 | + | else false) | |
29 | + | then true | |
30 | + | else throw("0.8 <= order price <= 1.2") | |
31 | 31 | case _ => | |
32 | 32 | true | |
33 | 33 | } |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 3 #-} | |
2 | 2 | {-# CONTENT_TYPE EXPRESSION #-} | |
3 | 3 | let dAppAddress = addressFromString("3MygQawG2gPjoej8wX2cqkxmg7KXAPP6xar") | |
4 | 4 | let adminPK = base58'BUxg9XtvamV81CZCqrQzi8BxCizU41dpSqoqt5mW56XS' | |
5 | 5 | let tim = (lastBlock.timestamp / 1000) | |
6 | 6 | let sponsor = base58'5QNpGE1TbLFPcKiKcNpnShmJWx9DH2UUtGNWgf8TVDaC' | |
7 | 7 | let startTime = 1598979600 | |
8 | 8 | let startPrice = 100000 | |
9 | 9 | let intervalTime = 259200 | |
10 | 10 | let intervalPrice = 100000 | |
11 | 11 | let period = ((tim - startTime) / intervalTime) | |
12 | 12 | let periodEnd = (((period + 1) * intervalTime) + startTime) | |
13 | 13 | let priceSell = (startPrice + (intervalPrice * period)) | |
14 | 14 | let priceBuyMin = (priceSell - intervalPrice) | |
15 | 15 | let priceBuyMax = (priceSell + intervalPrice) | |
16 | 16 | match tx { | |
17 | 17 | case tx: MassTransferTransaction|BurnTransaction|SetAssetScriptTransaction|ReissueTransaction => | |
18 | 18 | (tx.sender == dAppAddress) | |
19 | 19 | case t: TransferTransaction => | |
20 | 20 | true | |
21 | 21 | case e: ExchangeTransaction => | |
22 | - | if ((e.buyOrder | |
23 | - | then | |
24 | - | | |
25 | - | | |
26 | - | else if ((e.sellOrder | |
27 | - | then | |
28 | - | | |
29 | - | | |
30 | - | ||
22 | + | if (if (if (isDefined(e.buyOrder)) | |
23 | + | then (e.buyOrder.price >= 80000000) | |
24 | + | else false) | |
25 | + | then true | |
26 | + | else if (isDefined(e.sellOrder)) | |
27 | + | then (120000000 >= e.sellOrder.price) | |
28 | + | else false) | |
29 | + | then true | |
30 | + | else throw("0.8 <= order price <= 1.2") | |
31 | 31 | case _ => | |
32 | 32 | true | |
33 | 33 | } |
github/deemru/w8io/169f3d6 75.74 ms ◑