tx · 6BuK9gpVA4GnMrzm3owkDVkxhKkR4qetgmidQEev8WJH 3N5avGf1Wr9gmTPHstXo1CECppRgXEbTj8j: -0.01000000 Waves 2022.11.28 16:29 [2337018] smart account 3N5avGf1Wr9gmTPHstXo1CECppRgXEbTj8j > SELF 0.00000000 Waves
{ "type": 13, "id": "6BuK9gpVA4GnMrzm3owkDVkxhKkR4qetgmidQEev8WJH", "fee": 1000000, "feeAssetId": null, "timestamp": 1669642201335, "version": 2, "chainId": 84, "sender": "3N5avGf1Wr9gmTPHstXo1CECppRgXEbTj8j", "senderPublicKey": "4kBZJBZZeh6bSRrKKgJcTzRaat82QWu7Wn81HDDJiXd7", "proofs": [ "mNtpo28UX5Zo343QPsZznLKCXa4UKn8U7feHTJdUebuSybEKQ3VZ2D6b8rCw19eSoXapP6vAYyHJWE6GmK6XPtZ" ], "script": "base64:BgICCAIAAAECdHgBBnZlcmlmeQAEByRtYXRjaDAFAnR4AwkAAQIFByRtYXRjaDACBU9yZGVyBAVvcmRlcgUHJG1hdGNoMAQJcHJpY2VNb2RlCQCwCQEJAMwBAgkAzQECCAUFb3JkZXIJYm9keUJ5dGVzACAAAQQOcHJpY2VNb2RlRWNkc2EJALAJAQkAzAECCQDNAQIIBQVvcmRlcglib2R5Qnl0ZXMAQQABCQACAQkAuQkCCQDMCAIFCXByaWNlTW9kZQkAzAgCBQ5wcmljZU1vZGVFY2RzYQUDbmlsAgEgCQD0AwMIBQJ0eAlib2R5Qnl0ZXMJAJEDAggFAnR4BnByb29mcwAACAUCdHgPc2VuZGVyUHVibGljS2V5KBJWTg==", "height": 2337018, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: CEdnnQ5t29abFP7Ym2YHfLS3Rmfz4xAR6LRhk14PygB8 Next: Gf3huCV5hAt6AvgtoUvPeMEjumEYrsC7adyM3fbCrMP6 Full:
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | - | let pool = Address(base58'3N7b3kPunHUXhZp1vMG9NhPMARNEprCMWxT') | |
5 | 4 | ||
6 | - | let lpAssetId = base58'FLdC14nUVRyiSYjVrMo3X4g8rXQjLbNRaGAyQAm8V68V' | |
7 | 5 | ||
8 | - | @Callable(i) | |
9 | - | func test () = { | |
10 | - | let emitAmount = { | |
11 | - | let @ = invoke(pool, "putOneTkn", [0, false], i.payments) | |
12 | - | if ($isInstanceOf(@, "Int")) | |
13 | - | then @ | |
14 | - | else throw(($getType(@) + " couldn't be cast to Int")) | |
15 | - | } | |
16 | - | if ((emitAmount == emitAmount)) | |
17 | - | then { | |
18 | - | let outAmount = { | |
19 | - | let @ = invoke(pool, "getOneTkn", ["WAVES", 0], [AttachedPayment(lpAssetId, emitAmount)]) | |
20 | - | if ($isInstanceOf(@, "Int")) | |
21 | - | then @ | |
22 | - | else throw(($getType(@) + " couldn't be cast to Int")) | |
23 | - | } | |
24 | - | if ((outAmount == outAmount)) | |
25 | - | then $Tuple2(nil, unit) | |
26 | - | else throw("Strict value is not equal to itself.") | |
27 | - | } | |
28 | - | else throw("Strict value is not equal to itself.") | |
29 | - | } | |
30 | 6 | ||
7 | + | @Verifier(tx) | |
8 | + | func verify () = match tx { | |
9 | + | case order: Order => | |
10 | + | let priceMode = toUtf8String(takeRight(dropRight(order.bodyBytes, 32), 1)) | |
11 | + | let priceModeEcdsa = toUtf8String(takeRight(dropRight(order.bodyBytes, 65), 1)) | |
12 | + | throw(makeString([priceMode, priceModeEcdsa], " ")) | |
13 | + | case _ => | |
14 | + | sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey) | |
15 | + | } | |
31 | 16 |
github/deemru/w8io/169f3d6 26.36 ms ◑