tx · GvAwpcKWukkxh1PUbNgUxnK1yxctB5JspnnZe4LdbPcA 3N3LxL6zCjE2SKmSeuBsuX81AjMcgmrYfpZ: -0.01400000 Waves 2023.05.04 13:11 [2562877] smart account 3N3LxL6zCjE2SKmSeuBsuX81AjMcgmrYfpZ > SELF 0.00000000 Waves
{ "type": 13, "id": "GvAwpcKWukkxh1PUbNgUxnK1yxctB5JspnnZe4LdbPcA", "fee": 1400000, "feeAssetId": null, "timestamp": 1683195113213, "version": 2, "chainId": 84, "sender": "3N3LxL6zCjE2SKmSeuBsuX81AjMcgmrYfpZ", "senderPublicKey": "Dtn5HymigPuZXoT2jADQ1yZeLMcfqrt8n5UJh6GNCpbo", "proofs": [ "4WbNDVejoamwRCmetR8JsTNGR8KJTr3zDPuUZwSTSCeBH8hYtzqqbb3U7wsiShRLC6hreynLvFiE1UHhgJ1EHXdU" ], "script": "base64:AAIFAAAAAAAAABUIAhIFCgMBAQgSAwoBARIAEgMKAQEAAAAgAAAAAANTRVACAAAAAl9fAAAAAAtrZXlSZWZlcnJhbAkABLkAAAACCQAETAAAAAICAAAAAiVzCQAETAAAAAICAAAACHJlZmVycmFsBQAAAANuaWwFAAAAA1NFUAAAAAAMa2V5V3hBc3NldElkCQAEuQAAAAIJAARMAAAAAgIAAAACJXMJAARMAAAAAgIAAAAJd3hBc3NldElkBQAAAANuaWwFAAAAA1NFUAEAAAATa2V5TWFuYWdlclB1YmxpY0tleQAAAAACAAAAFCVzX19tYW5hZ2VyUHVibGljS2V5AQAAABZrZXlNYW5hZ2VyVmF1bHRBZGRyZXNzAAAAAAIAAAAXJXNfX21hbmFnZXJWYXVsdEFkZHJlc3MAAAAAFUlkeENmZ0NsYWltU3RhcnRCbG9jawAAAAAAAAAAAQAAAAAYSWR4Q2ZnQ2xhaW1WZXN0aW5nUGVyaW9kAAAAAAAAAAACAAAAABJJZHhDZmdDbGFpbUFzc2V0SWQAAAAAAAAAAAMAAAAAFElkeENmZ0NsYWltQXNzZXRNdWx0A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lvbiBkZW5pZWQDCQAAAAAAAAIFAAAADG11c3RSZWZlcnJhbAUAAAAMbXVzdFJlZmVycmFsBAAAAAl3eEFzc2V0SWQJAAJZAAAAAQkBAAAABXZhbHVlAAAAAQkABCIAAAABBQAAAAxrZXlXeEFzc2V0SWQJAAUUAAAAAgkABEwAAAACCQEAAAAOU2NyaXB0VHJhbnNmZXIAAAADCAUAAAABaQAAAAZjYWxsZXIFAAAACHd4QW1vdW50BQAAAAl3eEFzc2V0SWQJAARMAAAAAgkBAAAAGkNsYWltT3BlcmF0aW9uSGlzdG9yeUVudHJ5AAAABgUAAAAXcmVmZXJyYWxDb250cmFjdEFkZHJlc3MFAAAACHd4QW1vdW50AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACAUAAAABaQAAAA10cmFuc2FjdGlvbklkBQAAAANuaWwFAAAABHVuaXQJAAACAAAAAQIAAAAkU3RyaWN0IHZhbHVlIGlzIG5vdCBlcXVhbCB0byBpdHNlbGYuAAAAAQAAAAJ0eAEAAAAGdmVyaWZ5AAAAAAQAAAAPdGFyZ2V0UHVibGljS2V5BAAAAAckbWF0Y2gwCQEAAAAWbWFuYWdlclB1YmxpY0tleU9yVW5pdAAAAAADCQAAAQAAAAIFAAAAByRtYXRjaDACAAAACkJ5dGVWZWN0b3IEAAAAAnBrBQAAAAckbWF0Y2gwBQAAAAJwawMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAAEVW5pdAgFAAAAAnR4AAAAD3NlbmRlclB1YmxpY0tleQkAAAIAAAABAgAAAAtNYXRjaCBlcnJvcgkAAfQAAAADCAUAAAACdHgAAAAJYm9keUJ5dGVzCQABkQAAAAIIBQAAAAJ0eAAAAAZwcm9vZnMAAAAAAAAAAAAFAAAAD3RhcmdldFB1YmxpY0tleftuTys=", "height": 2562877, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: EqNmKZuDe62QHegQAivcqSSawSVMxqNAiLkMgKYazZyQ Next: none Diff:
Old | New | Differences | |
---|---|---|---|
10 | 10 | func d () = "%s__managerPublicKey" | |
11 | 11 | ||
12 | 12 | ||
13 | - | func e () = "%s__ | |
13 | + | func e () = "%s__managerVaultAddress" | |
14 | 14 | ||
15 | 15 | ||
16 | 16 | let f = 1 | |
66 | 66 | func T () = split(q(M()), a) | |
67 | 67 | ||
68 | 68 | ||
69 | - | func U (r,V,W,X) = { | |
70 | - | let D = parseIntValue(V[l]) | |
71 | - | let Y = parseIntValue(V[m]) | |
72 | - | let F = parseIntValue(V[n]) | |
73 | - | let Z = (D + W) | |
74 | - | let aa = (Y - W) | |
75 | - | if ((0 > aa)) | |
69 | + | func U () = addressFromStringValue(getStringValue(e())) | |
70 | + | ||
71 | + | ||
72 | + | func V (r,W,X,Y) = { | |
73 | + | let D = parseIntValue(W[l]) | |
74 | + | let Z = parseIntValue(W[m]) | |
75 | + | let F = parseIntValue(W[n]) | |
76 | + | let aa = (D + X) | |
77 | + | let ab = (Z - X) | |
78 | + | if ((0 > ab)) | |
76 | 79 | then throw("invalid math") | |
77 | - | else StringEntry(r, C(toString( | |
80 | + | else StringEntry(r, C(toString(aa), toString(ab), toString(Y))) | |
78 | 81 | } | |
79 | 82 | ||
80 | 83 | ||
81 | - | func | |
84 | + | func ac (Q,H,I,ad,ae,af) = StringEntry(O("claim", Q, toBase58String(af)), G(H, I, ad, ae)) | |
82 | 85 | ||
83 | 86 | ||
84 | - | func af () = { | |
85 | - | let ag = getString(d()) | |
86 | - | if ($isInstanceOf(ag, "String")) | |
87 | + | func ag () = { | |
88 | + | let ah = U() | |
89 | + | let ai = getString(ah, d()) | |
90 | + | if ($isInstanceOf(ai, "String")) | |
87 | 91 | then { | |
88 | - | let | |
89 | - | fromBase58String( | |
92 | + | let aj = ai | |
93 | + | fromBase58String(aj) | |
90 | 94 | } | |
91 | - | else if ($isInstanceOf( | |
95 | + | else if ($isInstanceOf(ai, "Unit")) | |
92 | 96 | then unit | |
93 | 97 | else throw("Match error") | |
94 | 98 | } | |
95 | 99 | ||
96 | 100 | ||
97 | - | func ai () = { | |
98 | - | let ag = getString(e()) | |
99 | - | if ($isInstanceOf(ag, "String")) | |
101 | + | func ak (al) = { | |
102 | + | let am = o("permission denied") | |
103 | + | let ai = ag() | |
104 | + | if ($isInstanceOf(ai, "ByteVector")) | |
100 | 105 | then { | |
101 | - | let ah = ag | |
102 | - | fromBase58String(ah) | |
106 | + | let an = ai | |
107 | + | if ((al.callerPublicKey == an)) | |
108 | + | then true | |
109 | + | else am | |
103 | 110 | } | |
104 | - | else if ($isInstanceOf(ag, "Unit")) | |
105 | - | then unit | |
111 | + | else if ($isInstanceOf(ai, "Unit")) | |
112 | + | then if ((al.caller == this)) | |
113 | + | then true | |
114 | + | else am | |
106 | 115 | else throw("Match error") | |
107 | 116 | } | |
108 | 117 | ||
109 | 118 | ||
110 | - | func aj (ak) = { | |
111 | - | let al = o("permission denied") | |
112 | - | let ag = af() | |
113 | - | if ($isInstanceOf(ag, "ByteVector")) | |
114 | - | then { | |
115 | - | let am = ag | |
116 | - | if ((ak.callerPublicKey == am)) | |
117 | - | then true | |
118 | - | else al | |
119 | - | } | |
120 | - | else if ($isInstanceOf(ag, "Unit")) | |
121 | - | then if ((ak.caller == this)) | |
122 | - | then true | |
123 | - | else al | |
124 | - | else throw("Match error") | |
125 | - | } | |
126 | - | ||
127 | - | ||
128 | - | func an (ak,ao) = { | |
129 | - | let ap = S() | |
130 | - | let aq = parseIntValue(ap[f]) | |
131 | - | let ar = parseIntValue(ap[g]) | |
132 | - | let as = (aq + ar) | |
133 | - | let at = fromBase58String(ap[h]) | |
134 | - | let au = addressFromStringValue(ap[j]) | |
135 | - | let av = parseIntValue(ap[k]) | |
136 | - | let aw = T() | |
137 | - | let D = parseIntValue(aw[l]) | |
138 | - | let ax = parseIntValue(aw[m]) | |
139 | - | let F = parseIntValue(aw[n]) | |
140 | - | if ((ak.caller != au)) | |
119 | + | func ao (al,ap) = { | |
120 | + | let aq = S() | |
121 | + | let ar = parseIntValue(aq[f]) | |
122 | + | let as = parseIntValue(aq[g]) | |
123 | + | let at = (ar + as) | |
124 | + | let au = fromBase58String(aq[h]) | |
125 | + | let av = addressFromStringValue(aq[j]) | |
126 | + | let aw = parseIntValue(aq[k]) | |
127 | + | let ax = T() | |
128 | + | let D = parseIntValue(ax[l]) | |
129 | + | let ay = parseIntValue(ax[m]) | |
130 | + | let F = parseIntValue(ax[n]) | |
131 | + | if ((al.caller != av)) | |
141 | 132 | then throw("permissions denied") | |
142 | - | else if (( | |
143 | - | then throw(("Wait claim start block: " + toString( | |
133 | + | else if ((ar > height)) | |
134 | + | then throw(("Wait claim start block: " + toString(ar))) | |
144 | 135 | else { | |
145 | - | let K = if ((height > | |
146 | - | then | |
136 | + | let K = if ((height > at)) | |
137 | + | then at | |
147 | 138 | else height | |
148 | 139 | let J = if ((F == 0)) | |
149 | - | then | |
140 | + | then ar | |
150 | 141 | else F | |
151 | 142 | let I = (K - J) | |
152 | - | let | |
153 | - | let | |
154 | - | let | |
155 | - | let | |
143 | + | let az = fraction(aw, I, as) | |
144 | + | let aA = valueOrElse(getInteger(this, N), 0) | |
145 | + | let aB = (az + aA) | |
146 | + | let aC = if (if ((0 >= ap)) | |
156 | 147 | then true | |
157 | - | else ( | |
158 | - | then | |
159 | - | else | |
160 | - | let | |
161 | - | $Tuple2([IntegerEntry(N, | |
148 | + | else (ap >= aB)) | |
149 | + | then aB | |
150 | + | else ap | |
151 | + | let aD = (aB - aC) | |
152 | + | $Tuple2([IntegerEntry(N, aD), ScriptTransfer(av, aC, au), V(M(), T(), aC, K), ac(toString(av), aC, I, J, K, al.transactionId)], aC) | |
162 | 153 | } | |
163 | 154 | } | |
164 | 155 | ||
165 | 156 | ||
166 | - | @Callable( | |
167 | - | func constructor (t, | |
168 | - | let | |
157 | + | @Callable(al) | |
158 | + | func constructor (t,aE,aF) = { | |
159 | + | let aG = (t + aE) | |
169 | 160 | if (isDefined(getString(L()))) | |
170 | 161 | then throw("already initialized") | |
171 | - | else if ((size( | |
162 | + | else if ((size(al.payments) != 1)) | |
172 | 163 | then throw("exactly 1 payment must be attached") | |
173 | - | else if (( | |
164 | + | else if ((al.callerPublicKey != base58'2Cbd8ozG7A1RyRNC3nNnZgHu7Ru4K3JCfpyPkhqr9zxq')) | |
174 | 165 | then throw("not authorized") | |
175 | 166 | else { | |
176 | - | let | |
177 | - | let | |
178 | - | let | |
179 | - | let | |
180 | - | let | |
181 | - | let | |
182 | - | let | |
183 | - | [StringEntry(L(), z(t, | |
167 | + | let aH = valueOrErrorMessage(addressFromString(aF), "Invalid beneficiarAddress passed") | |
168 | + | let aI = value(al.payments[0]) | |
169 | + | let aJ = value(aI.assetId) | |
170 | + | let aK = valueOrErrorMessage(assetInfo(aJ), "fail to load ido asset info") | |
171 | + | let aL = toBase58String(aJ) | |
172 | + | let aM = pow(10, 0, aK.decimals, 0, 0, DOWN) | |
173 | + | let aN = aI.amount | |
174 | + | [StringEntry(L(), z(t, aE, aL, aM, toString(aH), aN)), StringEntry(M(), C("0", toString(aN), "0"))] | |
184 | 175 | } | |
185 | 176 | } | |
186 | 177 | ||
187 | 178 | ||
188 | 179 | ||
189 | - | @Callable( | |
190 | - | func claimAmount ( | |
180 | + | @Callable(al) | |
181 | + | func claimAmount (ap) = ao(al, ap) | |
191 | 182 | ||
192 | 183 | ||
193 | 184 | ||
194 | - | @Callable( | |
195 | - | func claim () = | |
185 | + | @Callable(al) | |
186 | + | func claim () = ao(al, -1) | |
196 | 187 | ||
197 | 188 | ||
198 | 189 | ||
199 | - | @Callable( | |
200 | - | func withdrawReferralReward ( | |
201 | - | let | |
202 | - | let | |
190 | + | @Callable(al) | |
191 | + | func withdrawReferralReward (aO) = { | |
192 | + | let aP = value(getString(b)) | |
193 | + | let aQ = if ((toString(al.caller) == aP)) | |
203 | 194 | then true | |
204 | 195 | else o("permission denied") | |
205 | - | if (( | |
196 | + | if ((aQ == aQ)) | |
206 | 197 | then { | |
207 | - | let | |
208 | - | $Tuple2([ScriptTransfer( | |
198 | + | let aR = fromBase58String(value(getString(c))) | |
199 | + | $Tuple2([ScriptTransfer(al.caller, aO, aR), ac(aP, aO, 0, 0, 0, al.transactionId)], unit) | |
209 | 200 | } | |
210 | 201 | else throw("Strict value is not equal to itself.") | |
211 | 202 | } | |
212 | 203 | ||
213 | 204 | ||
214 | - | ||
215 | - | @Callable(ak) | |
216 | - | func setManager (aR) = { | |
217 | - | let aS = aj(ak) | |
218 | - | if ((aS == aS)) | |
219 | - | then { | |
220 | - | let aT = fromBase58String(aR) | |
221 | - | if ((aT == aT)) | |
222 | - | then [StringEntry(e(), aR)] | |
223 | - | else throw("Strict value is not equal to itself.") | |
224 | - | } | |
225 | - | else throw("Strict value is not equal to itself.") | |
226 | - | } | |
227 | - | ||
228 | - | ||
229 | - | ||
230 | - | @Callable(ak) | |
231 | - | func confirmManager () = { | |
232 | - | let aU = ai() | |
233 | - | let aV = if (isDefined(aU)) | |
234 | - | then true | |
235 | - | else o("no pending manager") | |
236 | - | if ((aV == aV)) | |
237 | - | then { | |
238 | - | let aW = if ((ak.callerPublicKey == value(aU))) | |
239 | - | then true | |
240 | - | else o("you are not pending manager") | |
241 | - | if ((aW == aW)) | |
242 | - | then [StringEntry(d(), toBase58String(value(aU))), DeleteEntry(e())] | |
243 | - | else throw("Strict value is not equal to itself.") | |
244 | - | } | |
245 | - | else throw("Strict value is not equal to itself.") | |
246 | - | } | |
247 | - | ||
248 | - | ||
249 | - | @Verifier(aX) | |
250 | - | func aY () = { | |
251 | - | let aZ = { | |
252 | - | let ag = af() | |
253 | - | if ($isInstanceOf(ag, "ByteVector")) | |
205 | + | @Verifier(aS) | |
206 | + | func aT () = { | |
207 | + | let aU = { | |
208 | + | let ai = ag() | |
209 | + | if ($isInstanceOf(ai, "ByteVector")) | |
254 | 210 | then { | |
255 | - | let | |
256 | - | | |
211 | + | let an = ai | |
212 | + | an | |
257 | 213 | } | |
258 | - | else if ($isInstanceOf( | |
259 | - | then | |
214 | + | else if ($isInstanceOf(ai, "Unit")) | |
215 | + | then aS.senderPublicKey | |
260 | 216 | else throw("Match error") | |
261 | 217 | } | |
262 | - | sigVerify( | |
218 | + | sigVerify(aS.bodyBytes, aS.proofs[0], aU) | |
263 | 219 | } | |
264 | 220 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 5 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let a = "__" | |
5 | 5 | ||
6 | 6 | let b = makeString(["%s", "referral"], a) | |
7 | 7 | ||
8 | 8 | let c = makeString(["%s", "wxAssetId"], a) | |
9 | 9 | ||
10 | 10 | func d () = "%s__managerPublicKey" | |
11 | 11 | ||
12 | 12 | ||
13 | - | func e () = "%s__ | |
13 | + | func e () = "%s__managerVaultAddress" | |
14 | 14 | ||
15 | 15 | ||
16 | 16 | let f = 1 | |
17 | 17 | ||
18 | 18 | let g = 2 | |
19 | 19 | ||
20 | 20 | let h = 3 | |
21 | 21 | ||
22 | 22 | let i = 4 | |
23 | 23 | ||
24 | 24 | let j = 5 | |
25 | 25 | ||
26 | 26 | let k = 6 | |
27 | 27 | ||
28 | 28 | let l = 1 | |
29 | 29 | ||
30 | 30 | let m = 2 | |
31 | 31 | ||
32 | 32 | let n = 3 | |
33 | 33 | ||
34 | 34 | func o (p) = throw(makeString(["marketing.ride:", p], " ")) | |
35 | 35 | ||
36 | 36 | ||
37 | 37 | func q (r) = valueOrErrorMessage(getString(r), (("mandatory this." + r) + " is not defined")) | |
38 | 38 | ||
39 | 39 | ||
40 | 40 | func s (t,u,v,w,x,y) = makeString(["%d%d%s%d%s%d%", t, u, v, w, x, y], a) | |
41 | 41 | ||
42 | 42 | ||
43 | 43 | func z (t,u,v,w,A,B) = s(toString(t), toString(u), v, toString(w), A, toString(B)) | |
44 | 44 | ||
45 | 45 | ||
46 | 46 | func C (D,E,F) = makeString(["%d%d%d", D, E, F], a) | |
47 | 47 | ||
48 | 48 | ||
49 | 49 | func G (H,I,J,K) = makeString(["%d%d%d%d%d%d", toString(height), toString(lastBlock.timestamp), toString(H), toString(I), toString(J), toString(K)], a) | |
50 | 50 | ||
51 | 51 | ||
52 | 52 | func L () = "%s__config" | |
53 | 53 | ||
54 | 54 | ||
55 | 55 | func M () = "%s__totals" | |
56 | 56 | ||
57 | 57 | ||
58 | 58 | let N = makeString(["%s", "amountUnclaimed"], a) | |
59 | 59 | ||
60 | 60 | func O (P,Q,R) = makeString(["%s%s%s%s__history", P, Q, R], a) | |
61 | 61 | ||
62 | 62 | ||
63 | 63 | func S () = split(q(L()), a) | |
64 | 64 | ||
65 | 65 | ||
66 | 66 | func T () = split(q(M()), a) | |
67 | 67 | ||
68 | 68 | ||
69 | - | func U (r,V,W,X) = { | |
70 | - | let D = parseIntValue(V[l]) | |
71 | - | let Y = parseIntValue(V[m]) | |
72 | - | let F = parseIntValue(V[n]) | |
73 | - | let Z = (D + W) | |
74 | - | let aa = (Y - W) | |
75 | - | if ((0 > aa)) | |
69 | + | func U () = addressFromStringValue(getStringValue(e())) | |
70 | + | ||
71 | + | ||
72 | + | func V (r,W,X,Y) = { | |
73 | + | let D = parseIntValue(W[l]) | |
74 | + | let Z = parseIntValue(W[m]) | |
75 | + | let F = parseIntValue(W[n]) | |
76 | + | let aa = (D + X) | |
77 | + | let ab = (Z - X) | |
78 | + | if ((0 > ab)) | |
76 | 79 | then throw("invalid math") | |
77 | - | else StringEntry(r, C(toString( | |
80 | + | else StringEntry(r, C(toString(aa), toString(ab), toString(Y))) | |
78 | 81 | } | |
79 | 82 | ||
80 | 83 | ||
81 | - | func | |
84 | + | func ac (Q,H,I,ad,ae,af) = StringEntry(O("claim", Q, toBase58String(af)), G(H, I, ad, ae)) | |
82 | 85 | ||
83 | 86 | ||
84 | - | func af () = { | |
85 | - | let ag = getString(d()) | |
86 | - | if ($isInstanceOf(ag, "String")) | |
87 | + | func ag () = { | |
88 | + | let ah = U() | |
89 | + | let ai = getString(ah, d()) | |
90 | + | if ($isInstanceOf(ai, "String")) | |
87 | 91 | then { | |
88 | - | let | |
89 | - | fromBase58String( | |
92 | + | let aj = ai | |
93 | + | fromBase58String(aj) | |
90 | 94 | } | |
91 | - | else if ($isInstanceOf( | |
95 | + | else if ($isInstanceOf(ai, "Unit")) | |
92 | 96 | then unit | |
93 | 97 | else throw("Match error") | |
94 | 98 | } | |
95 | 99 | ||
96 | 100 | ||
97 | - | func ai () = { | |
98 | - | let ag = getString(e()) | |
99 | - | if ($isInstanceOf(ag, "String")) | |
101 | + | func ak (al) = { | |
102 | + | let am = o("permission denied") | |
103 | + | let ai = ag() | |
104 | + | if ($isInstanceOf(ai, "ByteVector")) | |
100 | 105 | then { | |
101 | - | let ah = ag | |
102 | - | fromBase58String(ah) | |
106 | + | let an = ai | |
107 | + | if ((al.callerPublicKey == an)) | |
108 | + | then true | |
109 | + | else am | |
103 | 110 | } | |
104 | - | else if ($isInstanceOf(ag, "Unit")) | |
105 | - | then unit | |
111 | + | else if ($isInstanceOf(ai, "Unit")) | |
112 | + | then if ((al.caller == this)) | |
113 | + | then true | |
114 | + | else am | |
106 | 115 | else throw("Match error") | |
107 | 116 | } | |
108 | 117 | ||
109 | 118 | ||
110 | - | func aj (ak) = { | |
111 | - | let al = o("permission denied") | |
112 | - | let ag = af() | |
113 | - | if ($isInstanceOf(ag, "ByteVector")) | |
114 | - | then { | |
115 | - | let am = ag | |
116 | - | if ((ak.callerPublicKey == am)) | |
117 | - | then true | |
118 | - | else al | |
119 | - | } | |
120 | - | else if ($isInstanceOf(ag, "Unit")) | |
121 | - | then if ((ak.caller == this)) | |
122 | - | then true | |
123 | - | else al | |
124 | - | else throw("Match error") | |
125 | - | } | |
126 | - | ||
127 | - | ||
128 | - | func an (ak,ao) = { | |
129 | - | let ap = S() | |
130 | - | let aq = parseIntValue(ap[f]) | |
131 | - | let ar = parseIntValue(ap[g]) | |
132 | - | let as = (aq + ar) | |
133 | - | let at = fromBase58String(ap[h]) | |
134 | - | let au = addressFromStringValue(ap[j]) | |
135 | - | let av = parseIntValue(ap[k]) | |
136 | - | let aw = T() | |
137 | - | let D = parseIntValue(aw[l]) | |
138 | - | let ax = parseIntValue(aw[m]) | |
139 | - | let F = parseIntValue(aw[n]) | |
140 | - | if ((ak.caller != au)) | |
119 | + | func ao (al,ap) = { | |
120 | + | let aq = S() | |
121 | + | let ar = parseIntValue(aq[f]) | |
122 | + | let as = parseIntValue(aq[g]) | |
123 | + | let at = (ar + as) | |
124 | + | let au = fromBase58String(aq[h]) | |
125 | + | let av = addressFromStringValue(aq[j]) | |
126 | + | let aw = parseIntValue(aq[k]) | |
127 | + | let ax = T() | |
128 | + | let D = parseIntValue(ax[l]) | |
129 | + | let ay = parseIntValue(ax[m]) | |
130 | + | let F = parseIntValue(ax[n]) | |
131 | + | if ((al.caller != av)) | |
141 | 132 | then throw("permissions denied") | |
142 | - | else if (( | |
143 | - | then throw(("Wait claim start block: " + toString( | |
133 | + | else if ((ar > height)) | |
134 | + | then throw(("Wait claim start block: " + toString(ar))) | |
144 | 135 | else { | |
145 | - | let K = if ((height > | |
146 | - | then | |
136 | + | let K = if ((height > at)) | |
137 | + | then at | |
147 | 138 | else height | |
148 | 139 | let J = if ((F == 0)) | |
149 | - | then | |
140 | + | then ar | |
150 | 141 | else F | |
151 | 142 | let I = (K - J) | |
152 | - | let | |
153 | - | let | |
154 | - | let | |
155 | - | let | |
143 | + | let az = fraction(aw, I, as) | |
144 | + | let aA = valueOrElse(getInteger(this, N), 0) | |
145 | + | let aB = (az + aA) | |
146 | + | let aC = if (if ((0 >= ap)) | |
156 | 147 | then true | |
157 | - | else ( | |
158 | - | then | |
159 | - | else | |
160 | - | let | |
161 | - | $Tuple2([IntegerEntry(N, | |
148 | + | else (ap >= aB)) | |
149 | + | then aB | |
150 | + | else ap | |
151 | + | let aD = (aB - aC) | |
152 | + | $Tuple2([IntegerEntry(N, aD), ScriptTransfer(av, aC, au), V(M(), T(), aC, K), ac(toString(av), aC, I, J, K, al.transactionId)], aC) | |
162 | 153 | } | |
163 | 154 | } | |
164 | 155 | ||
165 | 156 | ||
166 | - | @Callable( | |
167 | - | func constructor (t, | |
168 | - | let | |
157 | + | @Callable(al) | |
158 | + | func constructor (t,aE,aF) = { | |
159 | + | let aG = (t + aE) | |
169 | 160 | if (isDefined(getString(L()))) | |
170 | 161 | then throw("already initialized") | |
171 | - | else if ((size( | |
162 | + | else if ((size(al.payments) != 1)) | |
172 | 163 | then throw("exactly 1 payment must be attached") | |
173 | - | else if (( | |
164 | + | else if ((al.callerPublicKey != base58'2Cbd8ozG7A1RyRNC3nNnZgHu7Ru4K3JCfpyPkhqr9zxq')) | |
174 | 165 | then throw("not authorized") | |
175 | 166 | else { | |
176 | - | let | |
177 | - | let | |
178 | - | let | |
179 | - | let | |
180 | - | let | |
181 | - | let | |
182 | - | let | |
183 | - | [StringEntry(L(), z(t, | |
167 | + | let aH = valueOrErrorMessage(addressFromString(aF), "Invalid beneficiarAddress passed") | |
168 | + | let aI = value(al.payments[0]) | |
169 | + | let aJ = value(aI.assetId) | |
170 | + | let aK = valueOrErrorMessage(assetInfo(aJ), "fail to load ido asset info") | |
171 | + | let aL = toBase58String(aJ) | |
172 | + | let aM = pow(10, 0, aK.decimals, 0, 0, DOWN) | |
173 | + | let aN = aI.amount | |
174 | + | [StringEntry(L(), z(t, aE, aL, aM, toString(aH), aN)), StringEntry(M(), C("0", toString(aN), "0"))] | |
184 | 175 | } | |
185 | 176 | } | |
186 | 177 | ||
187 | 178 | ||
188 | 179 | ||
189 | - | @Callable( | |
190 | - | func claimAmount ( | |
180 | + | @Callable(al) | |
181 | + | func claimAmount (ap) = ao(al, ap) | |
191 | 182 | ||
192 | 183 | ||
193 | 184 | ||
194 | - | @Callable( | |
195 | - | func claim () = | |
185 | + | @Callable(al) | |
186 | + | func claim () = ao(al, -1) | |
196 | 187 | ||
197 | 188 | ||
198 | 189 | ||
199 | - | @Callable( | |
200 | - | func withdrawReferralReward ( | |
201 | - | let | |
202 | - | let | |
190 | + | @Callable(al) | |
191 | + | func withdrawReferralReward (aO) = { | |
192 | + | let aP = value(getString(b)) | |
193 | + | let aQ = if ((toString(al.caller) == aP)) | |
203 | 194 | then true | |
204 | 195 | else o("permission denied") | |
205 | - | if (( | |
196 | + | if ((aQ == aQ)) | |
206 | 197 | then { | |
207 | - | let | |
208 | - | $Tuple2([ScriptTransfer( | |
198 | + | let aR = fromBase58String(value(getString(c))) | |
199 | + | $Tuple2([ScriptTransfer(al.caller, aO, aR), ac(aP, aO, 0, 0, 0, al.transactionId)], unit) | |
209 | 200 | } | |
210 | 201 | else throw("Strict value is not equal to itself.") | |
211 | 202 | } | |
212 | 203 | ||
213 | 204 | ||
214 | - | ||
215 | - | @Callable(ak) | |
216 | - | func setManager (aR) = { | |
217 | - | let aS = aj(ak) | |
218 | - | if ((aS == aS)) | |
219 | - | then { | |
220 | - | let aT = fromBase58String(aR) | |
221 | - | if ((aT == aT)) | |
222 | - | then [StringEntry(e(), aR)] | |
223 | - | else throw("Strict value is not equal to itself.") | |
224 | - | } | |
225 | - | else throw("Strict value is not equal to itself.") | |
226 | - | } | |
227 | - | ||
228 | - | ||
229 | - | ||
230 | - | @Callable(ak) | |
231 | - | func confirmManager () = { | |
232 | - | let aU = ai() | |
233 | - | let aV = if (isDefined(aU)) | |
234 | - | then true | |
235 | - | else o("no pending manager") | |
236 | - | if ((aV == aV)) | |
237 | - | then { | |
238 | - | let aW = if ((ak.callerPublicKey == value(aU))) | |
239 | - | then true | |
240 | - | else o("you are not pending manager") | |
241 | - | if ((aW == aW)) | |
242 | - | then [StringEntry(d(), toBase58String(value(aU))), DeleteEntry(e())] | |
243 | - | else throw("Strict value is not equal to itself.") | |
244 | - | } | |
245 | - | else throw("Strict value is not equal to itself.") | |
246 | - | } | |
247 | - | ||
248 | - | ||
249 | - | @Verifier(aX) | |
250 | - | func aY () = { | |
251 | - | let aZ = { | |
252 | - | let ag = af() | |
253 | - | if ($isInstanceOf(ag, "ByteVector")) | |
205 | + | @Verifier(aS) | |
206 | + | func aT () = { | |
207 | + | let aU = { | |
208 | + | let ai = ag() | |
209 | + | if ($isInstanceOf(ai, "ByteVector")) | |
254 | 210 | then { | |
255 | - | let | |
256 | - | | |
211 | + | let an = ai | |
212 | + | an | |
257 | 213 | } | |
258 | - | else if ($isInstanceOf( | |
259 | - | then | |
214 | + | else if ($isInstanceOf(ai, "Unit")) | |
215 | + | then aS.senderPublicKey | |
260 | 216 | else throw("Match error") | |
261 | 217 | } | |
262 | - | sigVerify( | |
218 | + | sigVerify(aS.bodyBytes, aS.proofs[0], aU) | |
263 | 219 | } | |
264 | 220 |
github/deemru/w8io/169f3d6 56.83 ms ◑