tx · 9tih9QUyoYcE4Upfv9Eq3z3T4d1EVnt1rEcgTy7GLCvX 3MwPsLy9F1mUQrdP37sCAKvHuE5HvPE674Y: -0.04000000 Waves 2022.04.20 01:15 [2016027] smart account 3MwPsLy9F1mUQrdP37sCAKvHuE5HvPE674Y > SELF 0.00000000 Waves
{ "type": 13, "id": "9tih9QUyoYcE4Upfv9Eq3z3T4d1EVnt1rEcgTy7GLCvX", "fee": 4000000, "feeAssetId": null, "timestamp": 1650406564982, "version": 2, "chainId": 84, "sender": "3MwPsLy9F1mUQrdP37sCAKvHuE5HvPE674Y", "senderPublicKey": "AyAwWbMPM7a4VYkn1bhEBftC5WZgfvUXgrYDe98mvLsv", "proofs": [ "3dFkrWnnabaXdfMo3rj8s5SLXGVwwuftvAVC89FQTVmrwjFqSVUsQXqtyLBDaeVxazFK1uNVG2gXHb17wn81zPVQ" ], "script": "base64:AAIFAAAAAAAAABkIAhIFCgMICAESAwoBCBIECgIICBIDCgEIAAAACAAAAAAOZEFwcEFkZHJlc3NTdHICAAAAIzNON0o2bU1Na2pWVmlCUkV6OXk1M0ptY1g3cjdLWlJYUXBMAAAAAA1kQXBwUHVibGljS2V5AQAAACDgTQYFOGrUwRh8WaYap6j/gLstB4hjfa6yi718/WSaLAAAAAALZEFwcEFkZHJlc3MJAQAAABRhZGRyZXNzRnJvbVB1YmxpY0tleQAAAAEFAAAADWRBcHBQdWJsaWNLZXkAAAAAEmhvbGRpbmdzQWRkcmVzc1N0cgIAAAAjM013UHNMeTlGMW1VUXJkUDM3c0NBS3ZIdUU1SHZQRTY3NFkAAAAAEWhvbGRpbmdzUHVibGljS2V5AQAAACCUHPJXjFSZKhe4nfSREpS677760EMCVtx/1OcRvCWqHQAAAAAPaG9sZGluZ3NBZGRyZXNzCQEAAAAUYWRkcmVzc0Zyb21QdWJsaWNLZXkAAAABBQAAABFob2xkaW5nc1B1YmxpY0tleQAAAAAPdHJhbnNmZXJDb3N0UGN0AAAAAAAAAAAyAQAAAAhidXJ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AAAAAAYQAAAAAAAAAAYgAAAAAAAAAAYwAAAAAAAAAAZAAAAAAAAAAAZQAAAAAAAAAAZgAAAAAAAAAAZwAAAAAAAAAAaAAAAAAAAAAAaQAAAAAAAAAAagAAAAAAAAAAawAAAAAAAAAAbAAAAAAAAAAAbQAAAAAAAAAAbgAAAAAAAAAAbwAAAAAAAAAAcAAAAAAAAAAAcQAAAAAAAAAAcgAAAAAAAAAAcwAAAAEAAAACdHgBAAAABnZlcmlmeQAAAAADAwkAAfQAAAADCAUAAAACdHgAAAAJYm9keUJ5dGVzCQABkQAAAAIIBQAAAAJ0eAAAAAZwcm9vZnMAAAAAAAAAAAAIBQAAAAJ0eAAAAA9zZW5kZXJQdWJsaWNLZXkGCQAAAAAAAAIJAQAAABRhZGRyZXNzRnJvbVB1YmxpY0tleQAAAAEIBQAAAAJ0eAAAAA9zZW5kZXJQdWJsaWNLZXkFAAAAD2hvbGRpbmdzQWRkcmVzcwYJAAAAAAAAAgkBAAAAFGFkZHJlc3NGcm9tUHVibGljS2V5AAAAAQgFAAAAAnR4AAAAD3NlbmRlclB1YmxpY0tleQUAAAALZEFwcEFkZHJlc3M8KSEV", "height": 2016027, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: Gm8JB9YSrucif8a1X7rGkWvFp4WvTpU4yStdyxKeenVr Next: 5JuRprkaNi8XDMkwvBM7yyEs7nvg5tRPGNMRCBi8WaYQ Diff:
Old | New | Differences | |
---|---|---|---|
15 | 15 | ||
16 | 16 | let g = 50 | |
17 | 17 | ||
18 | - | @Callable(h) | |
19 | - | func addOwnerAndAmount (i,j,k) = [StringEntry((("sale_" + j) + "_originalOwner"), i), IntegerEntry((("sale_" + j) + "_amount"), k)] | |
18 | + | func h (i,j) = { | |
19 | + | let k = { | |
20 | + | let l = j | |
21 | + | if ($isInstanceOf(l, "Unit")) | |
22 | + | then "unset" | |
23 | + | else if ($isInstanceOf(l, "String")) | |
24 | + | then { | |
25 | + | let m = l | |
26 | + | m | |
27 | + | } | |
28 | + | else throw("Match error") | |
29 | + | } | |
30 | + | if ((k == "unset")) | |
31 | + | then i | |
32 | + | else { | |
33 | + | let n = { | |
34 | + | let l = getString(this, (k + "_assetId")) | |
35 | + | if ($isInstanceOf(l, "Unit")) | |
36 | + | then "unset" | |
37 | + | else if ($isInstanceOf(l, "String")) | |
38 | + | then { | |
39 | + | let m = l | |
40 | + | m | |
41 | + | } | |
42 | + | else throw("Match error") | |
43 | + | } | |
44 | + | if ((n == "unset")) | |
45 | + | then i | |
46 | + | else (i ++ [Burn(fromBase58String(n), 1)]) | |
47 | + | } | |
48 | + | } | |
49 | + | ||
50 | + | ||
51 | + | @Callable(o) | |
52 | + | func addOwnerAndAmount (p,n,q) = [StringEntry((("sale_" + n) + "_originalOwner"), p), IntegerEntry((("sale_" + n) + "_amount"), q)] | |
20 | 53 | ||
21 | 54 | ||
22 | 55 | ||
23 | - | @Callable( | |
24 | - | func revokeForSale ( | |
25 | - | let | |
26 | - | let | |
27 | - | let | |
28 | - | if ($isInstanceOf( | |
56 | + | @Callable(o) | |
57 | + | func revokeForSale (n) = { | |
58 | + | let r = toBase58String(o.caller.bytes) | |
59 | + | let p = { | |
60 | + | let l = getString(this, (("sale_" + n) + "_originalOwner")) | |
61 | + | if ($isInstanceOf(l, "Unit")) | |
29 | 62 | then "unset" | |
30 | - | else if ($isInstanceOf( | |
63 | + | else if ($isInstanceOf(l, "String")) | |
31 | 64 | then { | |
32 | - | let | |
33 | - | | |
65 | + | let s = l | |
66 | + | s | |
34 | 67 | } | |
35 | 68 | else throw("Match error") | |
36 | 69 | } | |
37 | - | if (( | |
70 | + | if ((r != p)) | |
38 | 71 | then throw("Owners do not match") | |
39 | - | else [StringEntry((("sale_" + | |
72 | + | else [StringEntry((("sale_" + n) + "_originalOwner"), ""), IntegerEntry((("sale_" + n) + "_amount"), 0), ScriptTransfer(o.caller, 1, fromBase58String(n))] | |
40 | 73 | } | |
41 | 74 | ||
42 | 75 | ||
43 | 76 | ||
44 | - | @Callable( | |
45 | - | func buyFromHoldings ( | |
46 | - | let | |
47 | - | let | |
48 | - | if ($isInstanceOf( | |
77 | + | @Callable(o) | |
78 | + | func buyFromHoldings (n,t) = { | |
79 | + | let p = { | |
80 | + | let l = getString(this, (("sale_" + n) + "_originalOwner")) | |
81 | + | if ($isInstanceOf(l, "Unit")) | |
49 | 82 | then "unset" | |
50 | - | else if ($isInstanceOf( | |
83 | + | else if ($isInstanceOf(l, "String")) | |
51 | 84 | then { | |
52 | - | let | |
53 | - | | |
85 | + | let s = l | |
86 | + | s | |
54 | 87 | } | |
55 | 88 | else throw("Match error") | |
56 | 89 | } | |
57 | - | let | |
58 | - | let | |
59 | - | let | |
60 | - | if ($isInstanceOf( | |
90 | + | let u = valueOrElse(o.payments[0].amount, 0) | |
91 | + | let q = { | |
92 | + | let l = getInteger(this, (("sale_" + n) + "_amount")) | |
93 | + | if ($isInstanceOf(l, "Unit")) | |
61 | 94 | then 0 | |
62 | - | else if ($isInstanceOf( | |
95 | + | else if ($isInstanceOf(l, "Int")) | |
63 | 96 | then { | |
64 | - | let | |
65 | - | | |
97 | + | let s = l | |
98 | + | s | |
66 | 99 | } | |
67 | 100 | else throw("Match error") | |
68 | 101 | } | |
69 | - | if (if (( | |
102 | + | if (if ((p == "unset")) | |
70 | 103 | then true | |
71 | - | else ( | |
104 | + | else (p == "")) | |
72 | 105 | then throw("Original owner not found ") | |
73 | - | else if (if (( | |
106 | + | else if (if ((q == 0)) | |
74 | 107 | then true | |
75 | - | else ( | |
76 | - | then throw(((("Payment and amount do not match. This assets costs " + toString( | |
108 | + | else (q > u)) | |
109 | + | then throw(((("Payment and amount do not match. This assets costs " + toString(q)) + "but you sent ") + toString(u))) | |
77 | 110 | else { | |
78 | - | let | |
79 | - | let | |
80 | - | if (( | |
111 | + | let r = toBase58String(o.caller.bytes) | |
112 | + | let v = invoke(c, "finalizeSale", [n, r, t], [AttachedPayment(unit, 0)]) | |
113 | + | if ((v == v)) | |
81 | 114 | then { | |
82 | - | let | |
83 | - | if (( | |
115 | + | let w = [ScriptTransfer(o.caller, 1, fromBase58String(n)), StringEntry((("sale_" + n) + "_originalOwner"), ""), IntegerEntry((("sale_" + n) + "_amount"), 0)] | |
116 | + | if ((p != d)) | |
84 | 117 | then { | |
85 | - | let | |
86 | - | let | |
87 | - | let | |
88 | - | ( | |
118 | + | let x = (u / g) | |
119 | + | let y = (u - x) | |
120 | + | let z = Address(fromBase58String(p)) | |
121 | + | (w ++ [ScriptTransfer(z, y, unit)]) | |
89 | 122 | } | |
90 | - | else | |
123 | + | else w | |
91 | 124 | } | |
92 | 125 | else throw("Strict value is not equal to itself.") | |
93 | 126 | } | |
95 | 128 | ||
96 | 129 | ||
97 | 130 | ||
98 | - | @Callable(h) | |
99 | - | func burnTest (j) = [Burn(fromBase58String(j), 1)] | |
131 | + | @Callable(o) | |
132 | + | func burnSquares (A) = { | |
133 | + | let r = toBase58String(o.caller.bytes) | |
134 | + | if (if ((r != d)) | |
135 | + | then (r != a) | |
136 | + | else false) | |
137 | + | then throw("This can only be triggering internally") | |
138 | + | else { | |
139 | + | let B = split(A, "|") | |
140 | + | let C = size(B) | |
141 | + | let D = nil | |
142 | + | func E (F,G) = if ((G >= C)) | |
143 | + | then F | |
144 | + | else h(F, B[G]) | |
145 | + | ||
146 | + | func H (F,G) = if ((G >= C)) | |
147 | + | then F | |
148 | + | else throw("List size exceeds 115") | |
149 | + | ||
150 | + | H(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(D, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20), 21), 22), 23), 24), 25), 26), 27), 28), 29), 30), 31), 32), 33), 34), 35), 36), 37), 38), 39), 40), 41), 42), 43), 44), 45), 46), 47), 48), 49), 50), 51), 52), 53), 54), 55), 56), 57), 58), 59), 60), 61), 62), 63), 64), 65), 66), 67), 68), 69), 70), 71), 72), 73), 74), 75), 76), 77), 78), 79), 80), 81), 82), 83), 84), 85), 86), 87), 88), 89), 90), 91), 92), 93), 94), 95), 96), 97), 98), 99), 100), 101), 102), 103), 104), 105), 106), 107), 108), 109), 110), 111), 112), 113), 114), 115) | |
151 | + | } | |
152 | + | } | |
100 | 153 | ||
101 | 154 | ||
102 | - | @Verifier( | |
103 | - | func | |
155 | + | @Verifier(I) | |
156 | + | func J () = if (if (sigVerify(I.bodyBytes, I.proofs[0], I.senderPublicKey)) | |
104 | 157 | then true | |
105 | - | else (addressFromPublicKey( | |
158 | + | else (addressFromPublicKey(I.senderPublicKey) == f)) | |
106 | 159 | then true | |
107 | - | else (addressFromPublicKey( | |
160 | + | else (addressFromPublicKey(I.senderPublicKey) == c) | |
108 | 161 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 5 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let a = "3N7J6mMMkjVViBREz9y53JmcX7r7KZRXQpL" | |
5 | 5 | ||
6 | 6 | let b = base58'G6aSmaqLJ4p7jzm7BnQcZuqa2NRRLVtzqdYNjYErnEZZ' | |
7 | 7 | ||
8 | 8 | let c = addressFromPublicKey(b) | |
9 | 9 | ||
10 | 10 | let d = "3MwPsLy9F1mUQrdP37sCAKvHuE5HvPE674Y" | |
11 | 11 | ||
12 | 12 | let e = base58'AyAwWbMPM7a4VYkn1bhEBftC5WZgfvUXgrYDe98mvLsv' | |
13 | 13 | ||
14 | 14 | let f = addressFromPublicKey(e) | |
15 | 15 | ||
16 | 16 | let g = 50 | |
17 | 17 | ||
18 | - | @Callable(h) | |
19 | - | func addOwnerAndAmount (i,j,k) = [StringEntry((("sale_" + j) + "_originalOwner"), i), IntegerEntry((("sale_" + j) + "_amount"), k)] | |
18 | + | func h (i,j) = { | |
19 | + | let k = { | |
20 | + | let l = j | |
21 | + | if ($isInstanceOf(l, "Unit")) | |
22 | + | then "unset" | |
23 | + | else if ($isInstanceOf(l, "String")) | |
24 | + | then { | |
25 | + | let m = l | |
26 | + | m | |
27 | + | } | |
28 | + | else throw("Match error") | |
29 | + | } | |
30 | + | if ((k == "unset")) | |
31 | + | then i | |
32 | + | else { | |
33 | + | let n = { | |
34 | + | let l = getString(this, (k + "_assetId")) | |
35 | + | if ($isInstanceOf(l, "Unit")) | |
36 | + | then "unset" | |
37 | + | else if ($isInstanceOf(l, "String")) | |
38 | + | then { | |
39 | + | let m = l | |
40 | + | m | |
41 | + | } | |
42 | + | else throw("Match error") | |
43 | + | } | |
44 | + | if ((n == "unset")) | |
45 | + | then i | |
46 | + | else (i ++ [Burn(fromBase58String(n), 1)]) | |
47 | + | } | |
48 | + | } | |
49 | + | ||
50 | + | ||
51 | + | @Callable(o) | |
52 | + | func addOwnerAndAmount (p,n,q) = [StringEntry((("sale_" + n) + "_originalOwner"), p), IntegerEntry((("sale_" + n) + "_amount"), q)] | |
20 | 53 | ||
21 | 54 | ||
22 | 55 | ||
23 | - | @Callable( | |
24 | - | func revokeForSale ( | |
25 | - | let | |
26 | - | let | |
27 | - | let | |
28 | - | if ($isInstanceOf( | |
56 | + | @Callable(o) | |
57 | + | func revokeForSale (n) = { | |
58 | + | let r = toBase58String(o.caller.bytes) | |
59 | + | let p = { | |
60 | + | let l = getString(this, (("sale_" + n) + "_originalOwner")) | |
61 | + | if ($isInstanceOf(l, "Unit")) | |
29 | 62 | then "unset" | |
30 | - | else if ($isInstanceOf( | |
63 | + | else if ($isInstanceOf(l, "String")) | |
31 | 64 | then { | |
32 | - | let | |
33 | - | | |
65 | + | let s = l | |
66 | + | s | |
34 | 67 | } | |
35 | 68 | else throw("Match error") | |
36 | 69 | } | |
37 | - | if (( | |
70 | + | if ((r != p)) | |
38 | 71 | then throw("Owners do not match") | |
39 | - | else [StringEntry((("sale_" + | |
72 | + | else [StringEntry((("sale_" + n) + "_originalOwner"), ""), IntegerEntry((("sale_" + n) + "_amount"), 0), ScriptTransfer(o.caller, 1, fromBase58String(n))] | |
40 | 73 | } | |
41 | 74 | ||
42 | 75 | ||
43 | 76 | ||
44 | - | @Callable( | |
45 | - | func buyFromHoldings ( | |
46 | - | let | |
47 | - | let | |
48 | - | if ($isInstanceOf( | |
77 | + | @Callable(o) | |
78 | + | func buyFromHoldings (n,t) = { | |
79 | + | let p = { | |
80 | + | let l = getString(this, (("sale_" + n) + "_originalOwner")) | |
81 | + | if ($isInstanceOf(l, "Unit")) | |
49 | 82 | then "unset" | |
50 | - | else if ($isInstanceOf( | |
83 | + | else if ($isInstanceOf(l, "String")) | |
51 | 84 | then { | |
52 | - | let | |
53 | - | | |
85 | + | let s = l | |
86 | + | s | |
54 | 87 | } | |
55 | 88 | else throw("Match error") | |
56 | 89 | } | |
57 | - | let | |
58 | - | let | |
59 | - | let | |
60 | - | if ($isInstanceOf( | |
90 | + | let u = valueOrElse(o.payments[0].amount, 0) | |
91 | + | let q = { | |
92 | + | let l = getInteger(this, (("sale_" + n) + "_amount")) | |
93 | + | if ($isInstanceOf(l, "Unit")) | |
61 | 94 | then 0 | |
62 | - | else if ($isInstanceOf( | |
95 | + | else if ($isInstanceOf(l, "Int")) | |
63 | 96 | then { | |
64 | - | let | |
65 | - | | |
97 | + | let s = l | |
98 | + | s | |
66 | 99 | } | |
67 | 100 | else throw("Match error") | |
68 | 101 | } | |
69 | - | if (if (( | |
102 | + | if (if ((p == "unset")) | |
70 | 103 | then true | |
71 | - | else ( | |
104 | + | else (p == "")) | |
72 | 105 | then throw("Original owner not found ") | |
73 | - | else if (if (( | |
106 | + | else if (if ((q == 0)) | |
74 | 107 | then true | |
75 | - | else ( | |
76 | - | then throw(((("Payment and amount do not match. This assets costs " + toString( | |
108 | + | else (q > u)) | |
109 | + | then throw(((("Payment and amount do not match. This assets costs " + toString(q)) + "but you sent ") + toString(u))) | |
77 | 110 | else { | |
78 | - | let | |
79 | - | let | |
80 | - | if (( | |
111 | + | let r = toBase58String(o.caller.bytes) | |
112 | + | let v = invoke(c, "finalizeSale", [n, r, t], [AttachedPayment(unit, 0)]) | |
113 | + | if ((v == v)) | |
81 | 114 | then { | |
82 | - | let | |
83 | - | if (( | |
115 | + | let w = [ScriptTransfer(o.caller, 1, fromBase58String(n)), StringEntry((("sale_" + n) + "_originalOwner"), ""), IntegerEntry((("sale_" + n) + "_amount"), 0)] | |
116 | + | if ((p != d)) | |
84 | 117 | then { | |
85 | - | let | |
86 | - | let | |
87 | - | let | |
88 | - | ( | |
118 | + | let x = (u / g) | |
119 | + | let y = (u - x) | |
120 | + | let z = Address(fromBase58String(p)) | |
121 | + | (w ++ [ScriptTransfer(z, y, unit)]) | |
89 | 122 | } | |
90 | - | else | |
123 | + | else w | |
91 | 124 | } | |
92 | 125 | else throw("Strict value is not equal to itself.") | |
93 | 126 | } | |
94 | 127 | } | |
95 | 128 | ||
96 | 129 | ||
97 | 130 | ||
98 | - | @Callable(h) | |
99 | - | func burnTest (j) = [Burn(fromBase58String(j), 1)] | |
131 | + | @Callable(o) | |
132 | + | func burnSquares (A) = { | |
133 | + | let r = toBase58String(o.caller.bytes) | |
134 | + | if (if ((r != d)) | |
135 | + | then (r != a) | |
136 | + | else false) | |
137 | + | then throw("This can only be triggering internally") | |
138 | + | else { | |
139 | + | let B = split(A, "|") | |
140 | + | let C = size(B) | |
141 | + | let D = nil | |
142 | + | func E (F,G) = if ((G >= C)) | |
143 | + | then F | |
144 | + | else h(F, B[G]) | |
145 | + | ||
146 | + | func H (F,G) = if ((G >= C)) | |
147 | + | then F | |
148 | + | else throw("List size exceeds 115") | |
149 | + | ||
150 | + | H(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(E(D, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20), 21), 22), 23), 24), 25), 26), 27), 28), 29), 30), 31), 32), 33), 34), 35), 36), 37), 38), 39), 40), 41), 42), 43), 44), 45), 46), 47), 48), 49), 50), 51), 52), 53), 54), 55), 56), 57), 58), 59), 60), 61), 62), 63), 64), 65), 66), 67), 68), 69), 70), 71), 72), 73), 74), 75), 76), 77), 78), 79), 80), 81), 82), 83), 84), 85), 86), 87), 88), 89), 90), 91), 92), 93), 94), 95), 96), 97), 98), 99), 100), 101), 102), 103), 104), 105), 106), 107), 108), 109), 110), 111), 112), 113), 114), 115) | |
151 | + | } | |
152 | + | } | |
100 | 153 | ||
101 | 154 | ||
102 | - | @Verifier( | |
103 | - | func | |
155 | + | @Verifier(I) | |
156 | + | func J () = if (if (sigVerify(I.bodyBytes, I.proofs[0], I.senderPublicKey)) | |
104 | 157 | then true | |
105 | - | else (addressFromPublicKey( | |
158 | + | else (addressFromPublicKey(I.senderPublicKey) == f)) | |
106 | 159 | then true | |
107 | - | else (addressFromPublicKey( | |
160 | + | else (addressFromPublicKey(I.senderPublicKey) == c) | |
108 | 161 |
github/deemru/w8io/169f3d6 56.72 ms ◑