tx · HXEVaFZjVZVsCSUayqrGuySUdynyZZmHHc8LP4VP8eip 3Mz7AZHqAeMecF7aaE9HVsK94XVQKf1QCKg: -0.01400000 Waves 2022.03.11 17:10 [1959386] smart account 3Mz7AZHqAeMecF7aaE9HVsK94XVQKf1QCKg > SELF 0.00000000 Waves
{ "type": 13, "id": "HXEVaFZjVZVsCSUayqrGuySUdynyZZmHHc8LP4VP8eip", "fee": 1400000, "feeAssetId": null, "timestamp": 1647007807933, "version": 1, "sender": "3Mz7AZHqAeMecF7aaE9HVsK94XVQKf1QCKg", "senderPublicKey": "9o6mYaNcbcTi647J8XhDQg2VsHJCv5Jon1QFPCbFPoFh", "proofs": [ "56yyFFA8frHqQRqVn4MALLricxH5Zxz5q7L7tYG8MaBa28JDH3bmZRmKZZaCivWzavb9ox2AgJsDYHqbaFbpRnk9" ], "script": "base64:AAIFAAAAAAAAABcIAhIFCgMBAQgSABIDCgEIEgMKAQgSAAAAABIBAAAAE2tleU1hbmFnZXJQdWJsaWNLZXkAAAAAAgAAABQlc19fbWFuYWdlclB1YmxpY0tleQEAAAAaa2V5UGVuZGluZ01hbmFnZXJQdWJsaWNLZXkAAAAAAgAAABslc19fcGVuZGluZ01hbmFnZXJQdWJsaWNLZXkAAAAACXNlcGFyYXRvcgIAAAACX18BAAAAD2dldFN0cmluZ09yRmFpbAAAAAIAAAAHYWRkcmVzcwAAAANrZXkJAQAAABN2YWx1ZU9yRXJyb3JNZXNzYWdlAAAAAgkABB0AAAACBQAAAAdhZGRyZXNzBQAAAANrZXkJAAEsAAAAAgkAASwAAAACCQABLAAAAAIJAAEsAAAAAgIAAAAKbWFuZGF0b3J5IAkABCUAAAABBQAAAAdhZGRyZXNzAgAAAAEuBQAAAANrZXkCAAAADyBpcyBub3QgZGVmaW5lZAAAAAAIa2V5U3RhcnQJAAS5AAAAAgkABEwAAAACAgAAAAIlcwkABEwAAAACAgAAAAVzdGFydAUAAAADbmlsBQAAAAlzZXBhcmF0b3IAAAAAC2tleUR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JQdWJsaWNLZXlPclVuaXQAAAAAAwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAAApCeXRlVmVjdG9yBAAAAAJwawUAAAAHJG1hdGNoMAUAAAACcGsDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAABFVuaXQIBQAAAAJ0eAAAAA9zZW5kZXJQdWJsaWNLZXkJAAACAAAAAQIAAAALTWF0Y2ggZXJyb3IJAAH0AAAAAwgFAAAAAnR4AAAACWJvZHlCeXRlcwkAAZEAAAACCAUAAAACdHgAAAAGcHJvb2ZzAAAAAAAAAAAABQAAAA90YXJnZXRQdWJsaWNLZXmx4s+t", "chainId": 84, "height": 1959386, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: BftZoJ9A1HJVoXugiK3WneSojGCKKXCpRGr318jUfmY6 Next: none Full:
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 5 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | func a () = "%s__managerPublicKey" | |
5 | 5 | ||
6 | 6 | ||
7 | 7 | func b () = "%s__pendingManagerPublicKey" | |
8 | 8 | ||
9 | 9 | ||
10 | 10 | let c = "__" | |
11 | 11 | ||
12 | 12 | func d (e,f) = valueOrErrorMessage(getString(e, f), (((("mandatory " + toString(e)) + ".") + f) + " is not defined")) | |
13 | 13 | ||
14 | 14 | ||
15 | 15 | let g = makeString(["%s", "start"], c) | |
16 | 16 | ||
17 | 17 | let h = makeString(["%s", "duration"], c) | |
18 | 18 | ||
19 | 19 | let i = makeString(["%s", "asset"], c) | |
20 | 20 | ||
21 | 21 | let j = makeString(["%s", "isDataReady"], c) | |
22 | 22 | ||
23 | 23 | func k (e) = makeString(["%s%s", "userRewardInfo", toString(e)], c) | |
24 | 24 | ||
25 | 25 | ||
26 | 26 | func l (e,m) = makeString(["%s%s%s", "claimHistoryRecord", toString(e), toBase58String(m)], c) | |
27 | 27 | ||
28 | 28 | ||
29 | 29 | func n (o) = makeString(["%d%d%d", toString(height), toString(lastBlock.timestamp), toString(o)], c) | |
30 | 30 | ||
31 | 31 | ||
32 | 32 | func p (q,r) = makeString(["%d%d", toString(q), toString(r)], c) | |
33 | 33 | ||
34 | 34 | ||
35 | 35 | func s (t) = split(d(this, k(t)), c) | |
36 | 36 | ||
37 | 37 | ||
38 | 38 | func u () = { | |
39 | 39 | let v = valueOrElse(getBoolean(this, j), false) | |
40 | 40 | if (v) | |
41 | 41 | then true | |
42 | 42 | else throw("Data is not ready") | |
43 | 43 | } | |
44 | 44 | ||
45 | 45 | ||
46 | 46 | func w (e) = { | |
47 | 47 | let x = valueOrErrorMessage(getInteger(this, g), "Start block is not specified") | |
48 | 48 | let y = valueOrErrorMessage(getInteger(this, h), "Duration is not specified") | |
49 | 49 | let z = s(e) | |
50 | 50 | let A = parseIntValue(z[1]) | |
51 | 51 | let B = parseIntValue(z[2]) | |
52 | 52 | let C = fraction(A, min([y, max([0, (height - x)])]), y) | |
53 | 53 | let D = max([0, (C - B)]) | |
54 | 54 | $Tuple3(A, B, D) | |
55 | 55 | } | |
56 | 56 | ||
57 | 57 | ||
58 | 58 | func E () = { | |
59 | 59 | let F = getString(a()) | |
60 | 60 | if ($isInstanceOf(F, "String")) | |
61 | 61 | then { | |
62 | 62 | let G = F | |
63 | 63 | fromBase58String(G) | |
64 | 64 | } | |
65 | 65 | else if ($isInstanceOf(F, "Unit")) | |
66 | 66 | then unit | |
67 | 67 | else throw("Match error") | |
68 | 68 | } | |
69 | 69 | ||
70 | 70 | ||
71 | 71 | func H () = { | |
72 | 72 | let F = getString(b()) | |
73 | 73 | if ($isInstanceOf(F, "String")) | |
74 | 74 | then { | |
75 | 75 | let G = F | |
76 | 76 | fromBase58String(G) | |
77 | 77 | } | |
78 | 78 | else if ($isInstanceOf(F, "Unit")) | |
79 | 79 | then unit | |
80 | 80 | else throw("Match error") | |
81 | 81 | } | |
82 | 82 | ||
83 | 83 | ||
84 | 84 | func I (J) = { | |
85 | 85 | let K = throw("Permission denied") | |
86 | 86 | let F = E() | |
87 | 87 | if ($isInstanceOf(F, "ByteVector")) | |
88 | 88 | then { | |
89 | 89 | let L = F | |
90 | 90 | if ((J.callerPublicKey == L)) | |
91 | 91 | then true | |
92 | 92 | else K | |
93 | 93 | } | |
94 | 94 | else if ($isInstanceOf(F, "Unit")) | |
95 | 95 | then if ((J.caller == this)) | |
96 | 96 | then true | |
97 | 97 | else K | |
98 | 98 | else throw("Match error") | |
99 | 99 | } | |
100 | 100 | ||
101 | 101 | ||
102 | 102 | @Callable(J) | |
103 | 103 | func constructor (x,y,M) = { | |
104 | 104 | let N = I(J) | |
105 | 105 | if ((N == N)) | |
106 | 106 | then [IntegerEntry(g, x), IntegerEntry(h, y), StringEntry(i, M), BooleanEntry(j, false)] | |
107 | 107 | else throw("Strict value is not equal to itself.") | |
108 | 108 | } | |
109 | 109 | ||
110 | 110 | ||
111 | 111 | ||
112 | 112 | @Callable(J) | |
113 | 113 | func claim () = { | |
114 | 114 | let O = w(J.caller) | |
115 | 115 | let A = O._1 | |
116 | 116 | let B = O._2 | |
117 | 117 | let D = O._3 | |
118 | 118 | let P = fromBase58String(d(this, i)) | |
119 | 119 | let Q = assetBalance(this, P) | |
120 | 120 | let R = [u(), if ((D > 0)) | |
121 | 121 | then true | |
122 | 122 | else throw("No reward available"), if ((Q >= D)) | |
123 | 123 | then true | |
124 | 124 | else throw("Insufficient funds. Contact support")] | |
125 | 125 | if ((R == R)) | |
126 | 126 | then [ScriptTransfer(J.caller, D, P), StringEntry(k(J.caller), p(A, (B + D))), StringEntry(l(J.caller, J.transactionId), n(D))] | |
127 | 127 | else throw("Strict value is not equal to itself.") | |
128 | 128 | } | |
129 | 129 | ||
130 | 130 | ||
131 | 131 | ||
132 | 132 | @Callable(J) | |
133 | 133 | func getUserRewardsREADONLY (e) = { | |
134 | 134 | let R = [u()] | |
135 | 135 | if ((R == R)) | |
136 | 136 | then { | |
137 | 137 | let S = w(addressFromStringValue(e)) | |
138 | 138 | let A = S._1 | |
139 | 139 | let B = S._2 | |
140 | 140 | let D = S._3 | |
141 | 141 | $Tuple2(nil, makeString(["%d%d%d", toString(A), toString(B), toString(D)], c)) | |
142 | 142 | } | |
143 | 143 | else throw("Strict value is not equal to itself.") | |
144 | 144 | } | |
145 | 145 | ||
146 | 146 | ||
147 | 147 | ||
148 | 148 | @Callable(J) | |
149 | 149 | func setManager (T) = { | |
150 | 150 | let N = I(J) | |
151 | 151 | if ((N == N)) | |
152 | 152 | then { | |
153 | 153 | let U = fromBase58String(T) | |
154 | 154 | if ((U == U)) | |
155 | 155 | then [StringEntry(b(), T)] | |
156 | 156 | else throw("Strict value is not equal to itself.") | |
157 | 157 | } | |
158 | 158 | else throw("Strict value is not equal to itself.") | |
159 | 159 | } | |
160 | 160 | ||
161 | 161 | ||
162 | 162 | ||
163 | 163 | @Callable(J) | |
164 | 164 | func confirmManager () = { | |
165 | 165 | let V = H() | |
166 | 166 | let W = if (isDefined(V)) | |
167 | 167 | then true | |
168 | 168 | else throw("No pending manager") | |
169 | 169 | if ((W == W)) | |
170 | 170 | then { | |
171 | 171 | let X = if ((J.callerPublicKey == value(V))) | |
172 | 172 | then true | |
173 | 173 | else throw("You are not pending manager") | |
174 | 174 | if ((X == X)) | |
175 | 175 | then [StringEntry(a(), toBase58String(value(V))), DeleteEntry(b())] | |
176 | 176 | else throw("Strict value is not equal to itself.") | |
177 | 177 | } | |
178 | 178 | else throw("Strict value is not equal to itself.") | |
179 | 179 | } | |
180 | 180 | ||
181 | 181 | ||
182 | 182 | @Verifier(Y) | |
183 | 183 | func Z () = { | |
184 | 184 | let aa = { | |
185 | 185 | let F = E() | |
186 | 186 | if ($isInstanceOf(F, "ByteVector")) | |
187 | 187 | then { | |
188 | 188 | let L = F | |
189 | 189 | L | |
190 | 190 | } | |
191 | 191 | else if ($isInstanceOf(F, "Unit")) | |
192 | 192 | then Y.senderPublicKey | |
193 | 193 | else throw("Match error") | |
194 | 194 | } | |
195 | 195 | sigVerify(Y.bodyBytes, Y.proofs[0], aa) | |
196 | 196 | } | |
197 | 197 |
github/deemru/w8io/169f3d6 130.87 ms ◑