tx · HNFiK4DVdTF96inySdDf3SUpqc7PaxCi1KpSFAk6QyJd 3N86fBeRNMYj4Lbc7po8PKtrXR2oLQXQB8a: -0.05000000 Waves 2024.05.07 08:49 [3095351] smart account 3N86fBeRNMYj4Lbc7po8PKtrXR2oLQXQB8a > SELF 0.00000000 Waves
{ "type": 13, "id": "HNFiK4DVdTF96inySdDf3SUpqc7PaxCi1KpSFAk6QyJd", "fee": 5000000, "feeAssetId": null, "timestamp": 1715061044470, "version": 2, "chainId": 84, "sender": "3N86fBeRNMYj4Lbc7po8PKtrXR2oLQXQB8a", "senderPublicKey": "4uUUD88FFMgtPjui9NEmEstYpUVQNPSLCQw5f8mYHmGz", "proofs": [ "4szi7aTUZSnJGXyKMsCMeANfdJJVYh1ByVryH9211fWPWsU4tabW3HihKFzHVTWyQ4BhYvVvxppcDbWQ4GYq6Ag9" ], "script": "base64:BgIECAISAAUADVVTRFRfQVNTRVRfSUQCLEc1V1dXenpWc1dSeXpHZjMyeG9qYm5mcDdnWGJXcmdxSlQ4UmNWV0VmTG1DAA9VU0RUXzJfQVNTRVRfSUQCLDl3YzNMWE5BNFRFQnNYeUt0b0xFOW1yYkREN1dNSFh2WHJDalp2YWJMQXNpAA1VU0RDX0FTU0VUX0lEAiwzYXlIM1BoV01raEZzeVNzVVZjQzhCdkZmMVF5eEdCNUJadVRQeVZ0bVA0dgAPVVNEQ18yX0FTU0VUX0lEAixIR2dhYlRxVVM4V3RWRlVKemZtclRETWdFY2NKdVpMQlBoRmdRRnh2bnNvVwAMQkFJX0FTU0VUX0lEAiwyZmR6eUh2WEdDcWF6MVhBOG05Zm9kZW1tUDlnaVZCY3BlNEpxOUY2M29GTAEBaQEDYnV5AAQRV0FWRVNfVVNEVF9PUkFDTEUJARFAZXh0ck5hdGl2ZSgxMDYyKQECIzNQS2tvaktkZDZCQnpUZjFSWGJRVmZVRHJhTkZYWEhLelFGBBVXQVZFU19VU0RUX09SQUNMRV9LRVkCFyVzJXNfX3ByaWNlX19XQ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gV2F2ZXMsIFVTREMgb3IgVVNEVCEJAMwIAgkBDlNjcmlwdFRyYW5zZmVyAwUGc2VuZGVyBQZhbW91bnQJANkEAQUMQkFJX0FTU0VUX0lEBQNuaWwBAnR4AQZ2ZXJpZnkACQD0AwMIBQJ0eAlib2R5Qnl0ZXMJAJEDAggFAnR4BnByb29mcwAACAUCdHgPc2VuZGVyUHVibGljS2V5jU60bg==", "height": 3095351, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: AmryZXF89oZzi6XkVbpD9bXHMrGdBwSWeyG2SS67ZAFw Next: F8Sh4zvnU2i9wMHFHgMM9dubtRcFqHrbMvSSahRgK8j8 Full:
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | - | let a = " | |
4 | + | let a = "G5WWWzzVsWRyzGf32xojbnfp7gXbWrgqJT8RcVWEfLmC" | |
5 | 5 | ||
6 | - | let b = " | |
6 | + | let b = "9wc3LXNA4TEBsXyKtoLE9mrbDD7WMHXvXrCjZvabLAsi" | |
7 | 7 | ||
8 | - | let c = " | |
8 | + | let c = "3ayH3PhWMkhFsySsUVcC8BvFf1QyxGB5BZuTPyVtmP4v" | |
9 | 9 | ||
10 | - | let d = " | |
10 | + | let d = "HGgabTqUS8WtVFUJzfmrTDMgEccJuZLBPhFgQFxvnsoW" | |
11 | 11 | ||
12 | - | let e = " | |
12 | + | let e = "2fdzyHvXGCqaz1XA8m9fodemmP9giVBcpe4Jq9F63oFL" | |
13 | 13 | ||
14 | - | func f (g) = { | |
15 | - | let h = getBoolean(this, ("whitelist_" + g)) | |
16 | - | if ($isInstanceOf(h, "Boolean")) | |
17 | - | then { | |
18 | - | let i = h | |
19 | - | i | |
14 | + | @Callable(f) | |
15 | + | func buy () = { | |
16 | + | let g = addressFromStringValue("3PKkojKdd6BBzTf1RXbQVfUDraNFXXHKzQF") | |
17 | + | let h = "%s%s__price__WAVES-USDT" | |
18 | + | let i = size(f.payments) | |
19 | + | let j = f.payments[0].assetId | |
20 | + | let k = f.caller | |
21 | + | if ((i != 1)) | |
22 | + | then throw("Payment necessary!") | |
23 | + | else { | |
24 | + | let l = f.payments[0] | |
25 | + | let m = l.assetId | |
26 | + | let n = { | |
27 | + | let o = m | |
28 | + | if ($isInstanceOf(o, "ByteVector")) | |
29 | + | then { | |
30 | + | let p = o | |
31 | + | toBase58String(p) | |
32 | + | } | |
33 | + | else "" | |
34 | + | } | |
35 | + | let q = l.amount | |
36 | + | let r = if (!(isDefined(m))) | |
37 | + | then { | |
38 | + | let s = { | |
39 | + | let o = getInteger(g, h) | |
40 | + | if ($isInstanceOf(o, "Int")) | |
41 | + | then { | |
42 | + | let t = o | |
43 | + | t | |
44 | + | } | |
45 | + | else 0 | |
46 | + | } | |
47 | + | (fraction((12 * q), s, 100000000) * 10) | |
48 | + | } | |
49 | + | else if ((n == a)) | |
50 | + | then fraction(q, 1000, 12) | |
51 | + | else if ((n == b)) | |
52 | + | then fraction(q, 1000, 12) | |
53 | + | else if ((n == c)) | |
54 | + | then fraction(q, 1000, 12) | |
55 | + | else if ((n == d)) | |
56 | + | then fraction(q, 1000, 12) | |
57 | + | else throw("Payment necessary in Waves, USDC or USDT!") | |
58 | + | [ScriptTransfer(k, r, fromBase58String(e))] | |
20 | 59 | } | |
21 | - | else false | |
22 | 60 | } | |
23 | 61 | ||
24 | 62 | ||
25 | - | @Callable(j) | |
26 | - | func buy () = { | |
27 | - | let k = addressFromStringValue("3N1WjhmF3EyutvrvtsfsSLbhmiLU8Bc1Toy") | |
28 | - | let l = "%s%s__price__WAVES-USDT" | |
29 | - | let m = size(j.payments) | |
30 | - | let n = j.payments[0].assetId | |
31 | - | let o = j.caller | |
32 | - | if (!(f(toString(o)))) | |
33 | - | then throw("Address not whitelisted!") | |
34 | - | else if ((m != 1)) | |
35 | - | then throw("Payment necessary!") | |
36 | - | else { | |
37 | - | let p = j.payments[0] | |
38 | - | let q = p.assetId | |
39 | - | let r = { | |
40 | - | let h = q | |
41 | - | if ($isInstanceOf(h, "ByteVector")) | |
42 | - | then { | |
43 | - | let i = h | |
44 | - | toBase58String(i) | |
45 | - | } | |
46 | - | else "" | |
47 | - | } | |
48 | - | let s = p.amount | |
49 | - | let t = if (!(isDefined(q))) | |
50 | - | then { | |
51 | - | let u = { | |
52 | - | let h = getInteger(k, l) | |
53 | - | if ($isInstanceOf(h, "Int")) | |
54 | - | then { | |
55 | - | let v = h | |
56 | - | v | |
57 | - | } | |
58 | - | else 0 | |
59 | - | } | |
60 | - | (fraction(s, u, 100000000) * 100) | |
61 | - | } | |
62 | - | else if ((r == a)) | |
63 | - | then (s * 100) | |
64 | - | else if ((r == b)) | |
65 | - | then (s * 100) | |
66 | - | else if ((r == c)) | |
67 | - | then (s * 100) | |
68 | - | else if ((r == d)) | |
69 | - | then (s * 100) | |
70 | - | else throw("Payment necessary in Waves, USDC or USDT!") | |
71 | - | [ScriptTransfer(o, t, fromBase58String(e))] | |
72 | - | } | |
73 | - | } | |
74 | - | ||
75 | - | ||
76 | - | @Verifier(w) | |
77 | - | func x () = sigVerify(w.bodyBytes, w.proofs[0], w.senderPublicKey) | |
63 | + | @Verifier(u) | |
64 | + | func v () = sigVerify(u.bodyBytes, u.proofs[0], u.senderPublicKey) | |
78 | 65 |
github/deemru/w8io/169f3d6 25.37 ms ◑