tx · 4XdiVAKVicTo3q7yQLR6YfzsSXZfTobCYbymbsoLr1s1 3MqsiNaG42muSdN4QxfMQqiwCWccvH368W2: -0.01400000 Waves 2021.07.07 14:08 [1603110] smart account 3MqsiNaG42muSdN4QxfMQqiwCWccvH368W2 > SELF 0.00000000 Waves
{ "type": 13, "id": "4XdiVAKVicTo3q7yQLR6YfzsSXZfTobCYbymbsoLr1s1", "fee": 1400000, "feeAssetId": null, "timestamp": 1625656122280, "version": 2, "chainId": 84, "sender": "3MqsiNaG42muSdN4QxfMQqiwCWccvH368W2", "senderPublicKey": "6wE73N4bMbmjbcyUmThmPeeibTebXptgAEaRipnobJLu", "proofs": [ "5YtSXBZP6rp5923QVkP7MryoY6k6a6KYo63aKeXQ4ZNkVZjwvRU5AG8My8CTRrWB1hF7aT1iL9dfWNbR87hGa9ZA", "4g86tUxSXsrUMbtSgsxEW2NLVYRzwFd959H9UBACQTxYgMj9kvhcHefMB5PUxTpj1jcyGaBhBsjDDud5nDUmw5Qv" ], "script": "base64:AAIEAAAAAAAAACoIAhIDCgEEEgcKBQEBCAgEEgMKAQESAwoBARIAEgMKAQESABIAEgMKAQEAAABGAAAAAAd2ZXJzaW9uAgAAAAUxLjAuMAAAAAAKa2V5VmVyc2lvbgIAAAAHdmVyc2lvbgAAAAAJa2V5QWN0aXZlAgAAAAZhY3RpdmUAAAAAC2tleUFzc2V0SWRBAgAAAApBX2Fzc2V0X2lkAAAAAAtrZXlBc3NldElkQgIAAAAKQl9hc3NldF9pZAAAAAALa2V5QmFsYW5jZUECAAAAD0FfYXNzZXRfYmFsYW5jZQAAAAALa2V5QmFsYW5jZUICAAAAD0JfYXNzZXRfYmFsYW5jZQAAAAAPa2V5QmFsYW5jZUluaXRBAgAAAAxBX2Fzc2V0X2luaXQAAAAAD2tleUJhbGFuY2VJbml0QgIAAAAMQl9hc3NldF9pbml0AAAAAA9rZXlTaGFyZUFzc2V0SWQCAAAADnNoYXJlX2Fzc2V0X2lkAAAAABNrZXlTa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R4AAAABnByb29mcwAAAAAAAAAAAQUAAAAMYWRtaW5QdWJLZXkyAAAAAAAAAAABAAAAAAAAAAAABAAAABJhZG1pblB1YktleTNTaWduZWQDCQAB9AAAAAMIBQAAAAJ0eAAAAAlib2R5Qnl0ZXMJAAGRAAAAAggFAAAAAnR4AAAABnByb29mcwAAAAAAAAAAAgUAAAAMYWRtaW5QdWJLZXkzAAAAAAAAAAABAAAAAAAAAAAACQAAZwAAAAIJAABkAAAAAgkAAGQAAAACBQAAABJhZG1pblB1YktleTFTaWduZWQFAAAAEmFkbWluUHViS2V5MlNpZ25lZAUAAAASYWRtaW5QdWJLZXkzU2lnbmVkAAAAAAAAAAACCzoc0A==", "height": 1603110, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: acfibe37dEyHpy22DGXRS3Md1jVWentqkc68xGuZJh6 Next: CVAQasa3WK2z5YTWXhntgwrTzmXjFnXJoYv9wMRMxMdU Diff:
Old | New | Differences | |
---|---|---|---|
59 | 59 | ||
60 | 60 | let C = Address(base58'3MyVqAbmKWh339gF6hy8faWw1jGeTV2wnGE') | |
61 | 61 | ||
62 | - | let D = | |
62 | + | let D = Address(base58'3MqsiNaG42muSdN4QxfMQqiwCWccvH368W2') | |
63 | 63 | ||
64 | - | let E = valueOrErrorMessage(getInteger(B, | |
64 | + | let E = valueOrErrorMessage(getInteger(B, r), "Empty kBasePeriod") | |
65 | 65 | ||
66 | - | let F = valueOrErrorMessage(getInteger(B, | |
66 | + | let F = valueOrErrorMessage(getInteger(B, t), "Empty kStartHeight") | |
67 | 67 | ||
68 | - | let G = (( | |
68 | + | let G = valueOrErrorMessage(getInteger(B, s), "Empty kPeriodLength") | |
69 | 69 | ||
70 | - | let H = | |
70 | + | let H = ((E + ((height - F) / G)) + 3) | |
71 | 71 | ||
72 | - | let I = | |
72 | + | let I = base58'ECBCkHS68DckpBrzLeoRgYbFg7sCVqR176mPqbXsj9pA' | |
73 | 73 | ||
74 | - | let J = | |
74 | + | let J = 234000 | |
75 | 75 | ||
76 | - | let K = | |
76 | + | let K = getBooleanValue(this, c) | |
77 | 77 | ||
78 | - | let L = getStringValue(this, | |
78 | + | let L = getStringValue(this, d) | |
79 | 79 | ||
80 | - | let M = if ((K == "WAVES")) | |
81 | - | then unit | |
82 | - | else fromBase58String(K) | |
80 | + | let M = getStringValue(this, e) | |
83 | 81 | ||
84 | 82 | let N = if ((L == "WAVES")) | |
85 | 83 | then unit | |
86 | 84 | else fromBase58String(L) | |
87 | 85 | ||
88 | - | let O = { | |
89 | - | let P = M | |
90 | - | if ($isInstanceOf(P, "ByteVector")) | |
86 | + | let O = if ((M == "WAVES")) | |
87 | + | then unit | |
88 | + | else fromBase58String(M) | |
89 | + | ||
90 | + | let P = { | |
91 | + | let Q = N | |
92 | + | if ($isInstanceOf(Q, "ByteVector")) | |
91 | 93 | then { | |
92 | - | let | |
93 | - | value(assetInfo( | |
94 | + | let R = Q | |
95 | + | value(assetInfo(R)).name | |
94 | 96 | } | |
95 | - | else if ($isInstanceOf( | |
97 | + | else if ($isInstanceOf(Q, "Unit")) | |
96 | 98 | then { | |
97 | - | let | |
99 | + | let S = Q | |
98 | 100 | "WAVES" | |
99 | 101 | } | |
100 | 102 | else throw("Match error") | |
101 | 103 | } | |
102 | 104 | ||
103 | - | let | |
104 | - | let | |
105 | - | if ($isInstanceOf( | |
105 | + | let T = { | |
106 | + | let Q = O | |
107 | + | if ($isInstanceOf(Q, "ByteVector")) | |
106 | 108 | then { | |
107 | - | let | |
108 | - | value(assetInfo( | |
109 | + | let R = Q | |
110 | + | value(assetInfo(R)).name | |
109 | 111 | } | |
110 | - | else if ($isInstanceOf( | |
112 | + | else if ($isInstanceOf(Q, "Unit")) | |
111 | 113 | then { | |
112 | - | let | |
114 | + | let S = Q | |
113 | 115 | "WAVES" | |
114 | 116 | } | |
115 | 117 | else throw("Match error") | |
116 | 118 | } | |
117 | 119 | ||
118 | - | let | |
120 | + | let U = getIntegerValue(this, f) | |
119 | 121 | ||
120 | - | let | |
122 | + | let V = getIntegerValue(this, g) | |
121 | 123 | ||
122 | - | let | |
124 | + | let W = fromBase58String(getStringValue(this, j)) | |
123 | 125 | ||
124 | - | let | |
126 | + | let X = getIntegerValue(this, k) | |
125 | 127 | ||
126 | - | let | |
128 | + | let Y = 3000 | |
127 | 129 | ||
128 | - | let | |
130 | + | let Z = 1200 | |
129 | 131 | ||
130 | - | let | |
132 | + | let aa = 1000000 | |
131 | 133 | ||
132 | - | let | |
134 | + | let ab = 1000 | |
133 | 135 | ||
134 | - | let | |
136 | + | let ac = 100000000 | |
135 | 137 | ||
136 | - | let | |
138 | + | let ad = 1000 | |
137 | 139 | ||
138 | - | let | |
140 | + | let ae = 8 | |
139 | 141 | ||
140 | - | func | |
141 | - | let | |
142 | - | if ($isInstanceOf( | |
142 | + | func af (ag) = { | |
143 | + | let Q = ag | |
144 | + | if ($isInstanceOf(Q, "ByteVector")) | |
143 | 145 | then { | |
144 | - | let | |
145 | - | assetBalance(this, | |
146 | + | let R = Q | |
147 | + | assetBalance(this, R) | |
146 | 148 | } | |
147 | - | else if ($isInstanceOf( | |
149 | + | else if ($isInstanceOf(Q, "Unit")) | |
148 | 150 | then { | |
149 | - | let | |
151 | + | let S = Q | |
150 | 152 | wavesBalance(this).available | |
151 | 153 | } | |
152 | 154 | else throw("Match error") | |
153 | 155 | } | |
154 | 156 | ||
155 | 157 | ||
156 | - | let | |
157 | - | let | |
158 | - | if ($isInstanceOf( | |
158 | + | let ah = { | |
159 | + | let Q = getInteger(C, ((("%s%s%s__stakingBalance__" + toBase58String(I)) + "__") + toString(this))) | |
160 | + | if ($isInstanceOf(Q, "Int")) | |
159 | 161 | then { | |
160 | - | let | |
161 | - | | |
162 | + | let ai = Q | |
163 | + | ai | |
162 | 164 | } | |
163 | - | else if ($isInstanceOf( | |
165 | + | else if ($isInstanceOf(Q, "Unit")) | |
164 | 166 | then { | |
165 | - | let | |
167 | + | let aj = Q | |
166 | 168 | 0 | |
167 | 169 | } | |
168 | 170 | else throw("Match error") | |
169 | 171 | } | |
170 | 172 | ||
171 | - | let | |
173 | + | let ak = getIntegerValue(this, h) | |
172 | 174 | ||
173 | - | let | |
175 | + | let al = getIntegerValue(this, i) | |
174 | 176 | ||
175 | - | let | |
176 | - | then | |
177 | + | let am = (U - (if ((N == I)) | |
178 | + | then ah | |
177 | 179 | else 0)) | |
178 | 180 | ||
179 | - | let | |
180 | - | then | |
181 | + | let an = (V - (if ((O == I)) | |
182 | + | then ah | |
181 | 183 | else 0)) | |
182 | 184 | ||
183 | - | let | |
184 | - | then | |
185 | + | let ao = (af(N) + (if ((N == I)) | |
186 | + | then ah | |
185 | 187 | else 0)) | |
186 | 188 | ||
187 | - | let | |
188 | - | then | |
189 | + | let ap = (af(O) + (if ((O == I)) | |
190 | + | then ah | |
189 | 191 | else 0)) | |
190 | 192 | ||
191 | - | let | |
192 | - | then ( | |
193 | + | let aq = if ((ao >= U)) | |
194 | + | then (ap >= V) | |
193 | 195 | else false | |
194 | 196 | ||
195 | - | func | |
196 | - | let | |
197 | - | if ($isInstanceOf( | |
197 | + | func ar (ag) = { | |
198 | + | let Q = ag | |
199 | + | if ($isInstanceOf(Q, "ByteVector")) | |
198 | 200 | then { | |
199 | - | let | |
200 | - | let | |
201 | - | let | |
202 | - | $Tuple3( | |
201 | + | let R = Q | |
202 | + | let as = toBase58String(R) | |
203 | + | let at = valueOrErrorMessage(assetInfo(R), (("Asset " + as) + " doesn't exist")) | |
204 | + | $Tuple3(as, at.name, at.decimals) | |
203 | 205 | } | |
204 | - | else if ($isInstanceOf( | |
206 | + | else if ($isInstanceOf(Q, "Unit")) | |
205 | 207 | then { | |
206 | - | let | |
208 | + | let S = Q | |
207 | 209 | $Tuple3("WAVES", "WAVES", 8) | |
208 | 210 | } | |
209 | 211 | else throw("Match error") | |
210 | 212 | } | |
211 | 213 | ||
212 | 214 | ||
213 | - | func | |
215 | + | func au (av) = if ((av == "WAVES")) | |
214 | 216 | then $Tuple3("WAVES", "WAVES", 8) | |
215 | 217 | else { | |
216 | - | let | |
217 | - | let | |
218 | - | let | |
219 | - | $Tuple3( | |
218 | + | let as = av | |
219 | + | let R = fromBase58String(av) | |
220 | + | let at = valueOrErrorMessage(assetInfo(R), (("Asset " + as) + " doesn't exist")) | |
221 | + | $Tuple3(as, at.name, at.decimals) | |
220 | 222 | } | |
221 | 223 | ||
222 | 224 | ||
223 | - | func | |
225 | + | func aw (ax) = [BooleanEntry(c, false), StringEntry(n, ax)] | |
224 | 226 | ||
225 | 227 | ||
226 | - | func | |
228 | + | func ay (az,ag) = if ((ag == I)) | |
227 | 229 | then { | |
228 | - | let | |
229 | - | if ((0 >= | |
230 | - | then throw((((("Insufficient amount " + toString( | |
231 | - | else | |
230 | + | let aA = (az - J) | |
231 | + | if ((0 >= aA)) | |
232 | + | then throw((((("Insufficient amount " + toString(az)) + " to deduct staking fee ") + toString(J)) + " USD-N")) | |
233 | + | else aA | |
232 | 234 | } | |
233 | - | else | |
235 | + | else az | |
234 | 236 | ||
235 | 237 | ||
236 | - | func | |
238 | + | func aB (az,aC,aD) = throw((((((((("Insufficient DApp balance to pay " + toString(az)) + " ") + aD) + " due to staking. Available: ") + toString(aC)) + " ") + aD) + ". Please contact support in Telegram: https://t.me/swopfisupport")) | |
237 | 239 | ||
238 | 240 | ||
239 | - | func | |
241 | + | func aE (aF,aG) = throw((((((((((((((((("Insufficient DApp balance to pay " + toString(aF)) + " ") + P) + " and ") + toString(aG)) + " ") + T) + " due to staking. Available: ") + toString(am)) + " ") + P) + " and ") + toString(an)) + " ") + T) + ". Please contact support in Telegram: https://t.me/swopfisupport")) | |
240 | 242 | ||
241 | 243 | ||
242 | - | func | |
244 | + | func aH () = aw(((((((((((((((("Suspicious state. Actual balances: " + toString(ao)) + " ") + P) + ", ") + toString(ap)) + " ") + T) + ". State: ") + toString(U)) + " ") + P) + ", ") + toString(V)) + " ") + T)) | |
243 | 245 | ||
244 | 246 | ||
245 | - | @Callable( | |
246 | - | func init ( | |
247 | - | let | |
248 | - | let | |
249 | - | let | |
250 | - | let | |
251 | - | let | |
252 | - | let | |
253 | - | let | |
254 | - | let | |
255 | - | let | |
256 | - | let | |
257 | - | let | |
258 | - | let | |
259 | - | let | |
260 | - | let | |
261 | - | if (!(containsElement([v, w, x, z], | |
247 | + | @Callable(aI) | |
248 | + | func init (aJ) = { | |
249 | + | let aK = $Tuple2(aI.payments[0].amount, aI.payments[0].assetId) | |
250 | + | let aL = aK._1 | |
251 | + | let aM = aK._2 | |
252 | + | let aN = $Tuple2(aI.payments[1].amount, aI.payments[1].assetId) | |
253 | + | let aO = aN._1 | |
254 | + | let aP = aN._2 | |
255 | + | let aQ = ar(aM) | |
256 | + | let aR = aQ._1 | |
257 | + | let aS = aQ._2 | |
258 | + | let aT = aQ._3 | |
259 | + | let aU = ar(aP) | |
260 | + | let aV = aU._1 | |
261 | + | let aW = aU._2 | |
262 | + | let aX = aU._3 | |
263 | + | if (!(containsElement([v, w, x, z], aI.callerPublicKey))) | |
262 | 264 | then throw("Only admin can call this function") | |
263 | 265 | else if (isDefined(getBoolean(this, c))) | |
264 | 266 | then throw("DApp is already active") | |
265 | - | else if (( | |
267 | + | else if ((aM == aP)) | |
266 | 268 | then throw("Assets must be different") | |
267 | 269 | else { | |
268 | - | let | |
269 | - | let | |
270 | - | let | |
271 | - | let | |
272 | - | let | |
273 | - | let | |
274 | - | let | |
275 | - | if ( | |
276 | - | then ( | |
277 | - | else | |
270 | + | let aY = ((("s" + take(aS, 7)) + "_") + take(aW, 7)) | |
271 | + | let aZ = ((((("ShareToken of SwopFi protocol for " + aS) + " and ") + aW) + " at address ") + toString(this)) | |
272 | + | let ba = ((aT + aX) / 2) | |
273 | + | let bb = fraction(pow(aL, aT, 5, 1, aT, HALFDOWN), pow(aO, aX, 5, 1, aX, HALFDOWN), pow(10, 0, ba, 0, 0, HALFDOWN)) | |
274 | + | let bc = Issue(aY, aZ, bb, ba, true) | |
275 | + | let bd = calculateAssetId(bc) | |
276 | + | let be = [StringEntry(b, a), BooleanEntry(c, true), StringEntry(d, aR), StringEntry(e, aV), IntegerEntry(f, aL), IntegerEntry(g, aO), IntegerEntry(l, Y), IntegerEntry(m, aa), bc, StringEntry(j, toBase58String(bd)), IntegerEntry(k, bb), ScriptTransfer(aI.caller, bb, bd)] | |
277 | + | if (aJ) | |
278 | + | then (be ++ [BooleanEntry(o, aJ), IntegerEntry(p, (F + (H * G)))]) | |
279 | + | else be | |
278 | 280 | } | |
279 | 281 | } | |
280 | 282 | ||
281 | 283 | ||
282 | 284 | ||
283 | - | @Callable( | |
284 | - | func initWithInitRatio ( | |
285 | - | let | |
286 | - | let | |
287 | - | let | |
288 | - | let | |
289 | - | let | |
290 | - | let | |
291 | - | let | |
292 | - | let | |
293 | - | if (!(containsElement([v, w, x, z], | |
285 | + | @Callable(aI) | |
286 | + | func initWithInitRatio (bf,bg,L,M,aJ) = { | |
287 | + | let bh = au(L) | |
288 | + | let aR = bh._1 | |
289 | + | let aS = bh._2 | |
290 | + | let aT = bh._3 | |
291 | + | let bi = au(M) | |
292 | + | let aV = bi._1 | |
293 | + | let aW = bi._2 | |
294 | + | let aX = bi._3 | |
295 | + | if (!(containsElement([v, w, x, z], aI.callerPublicKey))) | |
294 | 296 | then throw("Only admin can call this function") | |
295 | 297 | else if (isDefined(getBoolean(this, c))) | |
296 | 298 | then throw("DApp is already active") | |
297 | - | else if (( | |
299 | + | else if ((L == M)) | |
298 | 300 | then throw("Assets must be different") | |
299 | 301 | else { | |
300 | - | let | |
301 | - | let | |
302 | - | let | |
303 | - | let | |
304 | - | let | |
305 | - | let | |
306 | - | let | |
307 | - | if ( | |
308 | - | then ( | |
309 | - | else | |
302 | + | let aY = ((("s" + take(aS, 7)) + "_") + take(aW, 7)) | |
303 | + | let aZ = ((((("ShareToken of SwopFi protocol for " + aS) + " and ") + aW) + " at address ") + toString(this)) | |
304 | + | let ba = ((aT + aX) / 2) | |
305 | + | let bb = 0 | |
306 | + | let bc = Issue(aY, aZ, bb, ba, true) | |
307 | + | let bd = calculateAssetId(bc) | |
308 | + | let be = [StringEntry(b, a), BooleanEntry(c, true), StringEntry(d, aR), StringEntry(e, aV), IntegerEntry(h, bf), IntegerEntry(i, bg), IntegerEntry(f, 0), IntegerEntry(g, 0), IntegerEntry(l, Y), IntegerEntry(m, aa), bc, StringEntry(j, toBase58String(bd)), IntegerEntry(k, bb)] | |
309 | + | if (aJ) | |
310 | + | then (be ++ [BooleanEntry(o, aJ), IntegerEntry(p, (F + (H * G)))]) | |
311 | + | else be | |
310 | 312 | } | |
311 | 313 | } | |
312 | 314 | ||
313 | 315 | ||
314 | 316 | ||
315 | - | @Callable( | |
316 | - | func keepLimitForFirstHarvest ( | |
317 | + | @Callable(aI) | |
318 | + | func keepLimitForFirstHarvest (bj) = if (!(K)) | |
317 | 319 | then throw("DApp is inactive at this moment") | |
318 | - | else if (!(containsElement([v, w, x, z], | |
320 | + | else if (!(containsElement([v, w, x, z], aI.callerPublicKey))) | |
319 | 321 | then throw("Only admin can call this function") | |
320 | - | else [IntegerEntry(q, | |
322 | + | else [IntegerEntry(q, bj)] | |
321 | 323 | ||
322 | 324 | ||
323 | 325 | ||
324 | - | @Callable( | |
325 | - | func replenishWithTwoTokens ( | |
326 | - | let | |
327 | - | let | |
328 | - | let | |
329 | - | let | |
330 | - | if (if (( | |
331 | - | then ( | |
326 | + | @Callable(aI) | |
327 | + | func replenishWithTwoTokens (bk) = { | |
328 | + | let aM = aI.payments[0].assetId | |
329 | + | let aP = aI.payments[1].assetId | |
330 | + | let aL = ay(aI.payments[0].amount, aM) | |
331 | + | let aO = ay(aI.payments[1].amount, aP) | |
332 | + | if (if ((U == 0)) | |
333 | + | then (V == 0) | |
332 | 334 | else false) | |
333 | 335 | then { | |
334 | - | let | |
335 | - | let | |
336 | - | let | |
337 | - | let | |
338 | - | let | |
339 | - | let | |
340 | - | let | |
341 | - | let | |
342 | - | let | |
343 | - | if (( | |
336 | + | let bl = ar(aM) | |
337 | + | let aR = bl._1 | |
338 | + | let aS = bl._2 | |
339 | + | let aT = bl._3 | |
340 | + | let bm = ar(aP) | |
341 | + | let aV = bm._1 | |
342 | + | let aW = bm._2 | |
343 | + | let aX = bm._3 | |
344 | + | let bn = fraction(fraction(ak, ac, aL), ab, fraction(al, ac, aO)) | |
345 | + | if ((aM == aP)) | |
344 | 346 | then throw("Assets must be different") | |
345 | 347 | else { | |
346 | - | let | |
347 | - | let | |
348 | - | if (!( | |
348 | + | let ba = ((aT + aX) / 2) | |
349 | + | let bb = fraction(pow(aL, aT, 5, 1, aT, HALFDOWN), pow(aO, aX, 5, 1, aX, HALFDOWN), pow(10, 0, ba, 0, 0, HALFDOWN)) | |
350 | + | if (!(K)) | |
349 | 351 | then throw("DApp is inactive at this moment") | |
350 | - | else if (if ((0 > | |
352 | + | else if (if ((0 > bk)) | |
351 | 353 | then true | |
352 | - | else ( | |
353 | - | then throw(((("Slippage tolerance must be between 0 and " + toString( | |
354 | - | else if ((size( | |
354 | + | else (bk > ad)) | |
355 | + | then throw(((("Slippage tolerance must be between 0 and " + toString(ad)) + " inclusively. Actual: ") + toString(bk))) | |
356 | + | else if ((size(aI.payments) != 2)) | |
355 | 357 | then throw("Two attached assets expected") | |
356 | - | else if (if (((( | |
358 | + | else if (if ((((ab * (ad - bk)) / ad) > bn)) | |
357 | 359 | then true | |
358 | - | else ( | |
360 | + | else (bn > ((ab * (ad + bk)) / ad))) | |
359 | 361 | then throw("Incorrect assets amount: amounts must have the contract ratio") | |
360 | - | else if (if (( | |
362 | + | else if (if ((aM != N)) | |
361 | 363 | then true | |
362 | - | else ( | |
363 | - | then throw(((("Incorrect assets attached. Expected: " + | |
364 | - | else if (( | |
364 | + | else (aP != O)) | |
365 | + | then throw(((("Incorrect assets attached. Expected: " + L) + " and ") + M)) | |
366 | + | else if ((bb == 0)) | |
365 | 367 | then throw("Too small amount to replenish") | |
366 | - | else if (!( | |
367 | - | then ([ScriptTransfer( | |
368 | - | else [Reissue( | |
368 | + | else if (!(aq)) | |
369 | + | then ([ScriptTransfer(aI.caller, aL, aM), ScriptTransfer(aI.caller, aO, aP)] ++ aH()) | |
370 | + | else [Reissue(W, bb, true), IntegerEntry(f, aL), IntegerEntry(g, aO), IntegerEntry(k, bb), ScriptTransfer(aI.caller, bb, W)] | |
369 | 371 | } | |
370 | 372 | } | |
371 | 373 | else { | |
372 | - | let | |
373 | - | let | |
374 | - | let | |
375 | - | let | |
376 | - | if (!( | |
374 | + | let bn = fraction(fraction(U, ac, aL), ab, fraction(V, ac, aO)) | |
375 | + | let bo = fraction(aL, ac, U) | |
376 | + | let bp = fraction(aO, ac, V) | |
377 | + | let bq = fraction(min([bo, bp]), X, ac) | |
378 | + | if (!(K)) | |
377 | 379 | then throw("DApp is inactive at this moment") | |
378 | - | else if (if ((0 > | |
380 | + | else if (if ((0 > bk)) | |
379 | 381 | then true | |
380 | - | else ( | |
381 | - | then throw(((("Slippage tolerance must be between 0 and " + toString( | |
382 | - | else if ((size( | |
382 | + | else (bk > ad)) | |
383 | + | then throw(((("Slippage tolerance must be between 0 and " + toString(ad)) + " inclusively. Actual: ") + toString(bk))) | |
384 | + | else if ((size(aI.payments) != 2)) | |
383 | 385 | then throw("Two attached assets expected") | |
384 | - | else if (if (( | |
386 | + | else if (if ((aM != N)) | |
385 | 387 | then true | |
386 | - | else ( | |
387 | - | then throw(((("Incorrect assets attached. Expected: " + | |
388 | - | else if (if (((( | |
388 | + | else (aP != O)) | |
389 | + | then throw(((("Incorrect assets attached. Expected: " + L) + " and ") + M)) | |
390 | + | else if (if ((((ab * (ad - bk)) / ad) > bn)) | |
389 | 391 | then true | |
390 | - | else ( | |
392 | + | else (bn > ((ab * (ad + bk)) / ad))) | |
391 | 393 | then throw("Incorrect assets amount: amounts must have the contract ratio") | |
392 | - | else if (( | |
394 | + | else if ((bq == 0)) | |
393 | 395 | then throw("Too small amount to replenish") | |
394 | - | else if (!( | |
395 | - | then ([ScriptTransfer( | |
396 | - | else [IntegerEntry(f, ( | |
396 | + | else if (!(aq)) | |
397 | + | then ([ScriptTransfer(aI.caller, aL, aM), ScriptTransfer(aI.caller, aO, aP)] ++ aH()) | |
398 | + | else [IntegerEntry(f, (U + aL)), IntegerEntry(g, (V + aO)), IntegerEntry(k, (X + bq)), Reissue(W, bq, true), ScriptTransfer(aI.caller, bq, W)] | |
397 | 399 | } | |
398 | 400 | } | |
399 | 401 | ||
400 | 402 | ||
401 | 403 | ||
402 | - | @Callable( | |
404 | + | @Callable(aI) | |
403 | 405 | func withdraw () = { | |
404 | - | let | |
405 | - | let | |
406 | - | let | |
407 | - | let | |
408 | - | let | |
409 | - | if (!( | |
406 | + | let br = $Tuple2(aI.payments[0].amount, aI.payments[0].assetId) | |
407 | + | let bs = br._1 | |
408 | + | let bt = br._2 | |
409 | + | let bu = ay(fraction(bs, U, X), N) | |
410 | + | let bv = ay(fraction(bs, V, X), O) | |
411 | + | if (!(K)) | |
410 | 412 | then throw("DApp is inactive at this moment") | |
411 | - | else if ((size( | |
413 | + | else if ((size(aI.payments) != 1)) | |
412 | 414 | then throw("One attached payment expected") | |
413 | - | else if (( | |
414 | - | then throw(("Incorrect asset attached. Expected: " + toBase58String( | |
415 | - | else if (!( | |
416 | - | then ([ScriptTransfer( | |
417 | - | else if (if (( | |
415 | + | else if ((bt != W)) | |
416 | + | then throw(("Incorrect asset attached. Expected: " + toBase58String(W))) | |
417 | + | else if (!(aq)) | |
418 | + | then ([ScriptTransfer(aI.caller, bs, bt)] ++ aH()) | |
419 | + | else if (if ((bu > am)) | |
418 | 420 | then true | |
419 | - | else ( | |
420 | - | then | |
421 | - | else [IntegerEntry(f, ( | |
421 | + | else (bv > an)) | |
422 | + | then aE(bu, bv) | |
423 | + | else [IntegerEntry(f, (U - bu)), IntegerEntry(g, (V - bv)), IntegerEntry(k, (X - bs)), Burn(W, bs), ScriptTransfer(aI.caller, bu, N), ScriptTransfer(aI.caller, bv, O)] | |
422 | 424 | } | |
423 | 425 | ||
424 | 426 | ||
425 | 427 | ||
426 | - | @Callable( | |
427 | - | func exchange ( | |
428 | - | let | |
429 | - | let | |
430 | - | let | |
431 | - | func | |
432 | - | let | |
433 | - | let | |
434 | - | let | |
435 | - | if (( | |
436 | - | then throw(((("Calculated amount to receive " + toString( | |
437 | - | else $Tuple3( | |
428 | + | @Callable(aI) | |
429 | + | func exchange (bw) = { | |
430 | + | let bx = $Tuple2(aI.payments[0].amount, aI.payments[0].assetId) | |
431 | + | let bs = bx._1 | |
432 | + | let bt = bx._2 | |
433 | + | func by (bz,bA) = { | |
434 | + | let bB = fraction(bA, bs, (bs + bz)) | |
435 | + | let bC = fraction(bB, (aa - Y), aa) | |
436 | + | let bD = fraction(bB, Z, aa) | |
437 | + | if ((bw > bC)) | |
438 | + | then throw(((("Calculated amount to receive " + toString(bC)) + " is less than specified minimum ") + toString(bw))) | |
439 | + | else $Tuple3(bB, bC, bD) | |
438 | 440 | } | |
439 | 441 | ||
440 | - | if (!( | |
442 | + | if (!(K)) | |
441 | 443 | then throw("DApp is inactive at this moment") | |
442 | - | else if (if (( | |
444 | + | else if (if ((U == 0)) | |
443 | 445 | then true | |
444 | - | else ( | |
446 | + | else (V == 0)) | |
445 | 447 | then throw("Can't exchange with zero balance") | |
446 | - | else if ((0 >= | |
447 | - | then throw(("Minimal amount to receive must be positive. Actual: " + toString( | |
448 | - | else if ((size( | |
448 | + | else if ((0 >= bw)) | |
449 | + | then throw(("Minimal amount to receive must be positive. Actual: " + toString(bw))) | |
450 | + | else if ((size(aI.payments) != 1)) | |
449 | 451 | then throw("One attached payment expected") | |
450 | - | else if (!( | |
451 | - | then ([ScriptTransfer( | |
452 | - | else if (( | |
452 | + | else if (!(aq)) | |
453 | + | then ([ScriptTransfer(aI.caller, bs, bt)] ++ aH()) | |
454 | + | else if ((bt == N)) | |
453 | 455 | then { | |
454 | - | let | |
455 | - | let | |
456 | - | let | |
457 | - | let | |
458 | - | let | |
459 | - | let | |
460 | - | let | |
461 | - | if (if (if (( | |
462 | - | then ( | |
456 | + | let bE = O | |
457 | + | let bF = by(U, V) | |
458 | + | let bB = bF._1 | |
459 | + | let bC = bF._2 | |
460 | + | let bD = bF._3 | |
461 | + | let bG = (U + bs) | |
462 | + | let bH = ((V - bC) - bD) | |
463 | + | if (if (if ((N == I)) | |
464 | + | then (ah >= bG) | |
463 | 465 | else false) | |
464 | 466 | then true | |
465 | - | else if (( | |
466 | - | then ( | |
467 | + | else if ((O == I)) | |
468 | + | then (ah >= bH) | |
467 | 469 | else false) | |
468 | - | then | |
469 | - | else [IntegerEntry(f, | |
470 | + | then aB(bC, an, T) | |
471 | + | else [IntegerEntry(f, bG), IntegerEntry(g, bH), ScriptTransfer(aI.caller, bC, bE), ScriptTransfer(A, bD, bE)] | |
470 | 472 | } | |
471 | - | else if (( | |
473 | + | else if ((bt == O)) | |
472 | 474 | then { | |
473 | - | let | |
474 | - | let | |
475 | - | let | |
476 | - | let | |
477 | - | let | |
478 | - | let | |
479 | - | let | |
480 | - | if (if (if (( | |
481 | - | then ( | |
475 | + | let bE = N | |
476 | + | let bI = by(V, U) | |
477 | + | let bB = bI._1 | |
478 | + | let bC = bI._2 | |
479 | + | let bD = bI._3 | |
480 | + | let bG = ((U - bC) - bD) | |
481 | + | let bH = (V + bs) | |
482 | + | if (if (if ((N == I)) | |
483 | + | then (ah >= bG) | |
482 | 484 | else false) | |
483 | 485 | then true | |
484 | - | else if (( | |
485 | - | then ( | |
486 | + | else if ((O == I)) | |
487 | + | then (ah >= bH) | |
486 | 488 | else false) | |
487 | - | then | |
488 | - | else [IntegerEntry(f, | |
489 | + | then aB(bC, am, P) | |
490 | + | else [IntegerEntry(f, bG), IntegerEntry(g, bH), ScriptTransfer(aI.caller, bC, bE), ScriptTransfer(A, bD, bE)] | |
489 | 491 | } | |
490 | - | else throw(((("Incorrect asset attached. Expected: " + | |
492 | + | else throw(((("Incorrect asset attached. Expected: " + L) + " or ") + M)) | |
491 | 493 | } | |
492 | 494 | ||
493 | 495 | ||
494 | 496 | ||
495 | - | @Callable( | |
496 | - | func shutdown () = if (!( | |
497 | + | @Callable(aI) | |
498 | + | func shutdown () = if (!(K)) | |
497 | 499 | then throw(("DApp is already suspended. Cause: " + valueOrElse(getString(this, n), "the cause wasn't specified"))) | |
498 | - | else if (!(containsElement([v, w, x, y], | |
500 | + | else if (!(containsElement([v, w, x, y], aI.callerPublicKey))) | |
499 | 501 | then throw("Only admin can call this function") | |
500 | - | else | |
502 | + | else aw("Paused by admin") | |
501 | 503 | ||
502 | 504 | ||
503 | 505 | ||
504 | - | @Callable( | |
505 | - | func activate () = if ( | |
506 | + | @Callable(aI) | |
507 | + | func activate () = if (K) | |
506 | 508 | then throw("DApp is already active") | |
507 | - | else if (!(containsElement([v, w, x, y], | |
509 | + | else if (!(containsElement([v, w, x, y], aI.callerPublicKey))) | |
508 | 510 | then throw("Only admin can call this function") | |
509 | 511 | else [BooleanEntry(c, true), DeleteEntry(n)] | |
510 | 512 | ||
511 | 513 | ||
512 | 514 | ||
513 | - | @Callable(aH) | |
514 | - | func takeIntoAccountExtraFunds (bI) = { | |
515 | - | let bJ = (an - T) | |
515 | + | @Callable(aI) | |
516 | + | func takeIntoAccountExtraFunds (bJ) = { | |
516 | 517 | let bK = (ao - U) | |
517 | - | let bL = (bJ - (if ((M == unit)) | |
518 | - | then bI | |
518 | + | let bL = (ap - V) | |
519 | + | let bM = (bK - (if ((N == unit)) | |
520 | + | then bJ | |
519 | 521 | else 0)) | |
520 | - | let | |
521 | - | then | |
522 | + | let bN = (bL - (if ((O == unit)) | |
523 | + | then bJ | |
522 | 524 | else 0)) | |
523 | - | if (!( | |
525 | + | if (!(K)) | |
524 | 526 | then throw("DApp is inactive at this moment") | |
525 | - | else if (( | |
527 | + | else if ((aI.caller != this)) | |
526 | 528 | then throw("Only the DApp itself can call this function") | |
527 | - | else if ((0 > | |
528 | - | then throw(("Argument 'amountLeave' cannot be negative. Actual: " + toString( | |
529 | - | else if (if ((0 > | |
529 | + | else if ((0 > bJ)) | |
530 | + | then throw(("Argument 'amountLeave' cannot be negative. Actual: " + toString(bJ))) | |
531 | + | else if (if ((0 > bK)) | |
530 | 532 | then true | |
531 | - | else (0 > | |
532 | - | then | |
533 | - | else if (if ((0 > | |
533 | + | else (0 > bL)) | |
534 | + | then aw("Enroll amount negative") | |
535 | + | else if (if ((0 > bM)) | |
534 | 536 | then true | |
535 | - | else (0 > | |
537 | + | else (0 > bN)) | |
536 | 538 | then throw("Too large amountLeave") | |
537 | - | else [IntegerEntry(f, ( | |
539 | + | else [IntegerEntry(f, (U + bM)), IntegerEntry(g, (V + bN)), IntegerEntry(("last_income_" + L), bM), IntegerEntry(("last_income_" + M), bN)] | |
538 | 540 | } | |
539 | 541 | ||
540 | 542 | ||
541 | - | @Verifier( | |
542 | - | func | |
543 | - | let | |
544 | - | if ($isInstanceOf( | |
543 | + | @Verifier(bO) | |
544 | + | func bP () = { | |
545 | + | let Q = bO | |
546 | + | if ($isInstanceOf(Q, "InvokeScriptTransaction")) | |
545 | 547 | then { | |
546 | - | let | |
547 | - | let | |
548 | - | then ( | |
548 | + | let bQ = Q | |
549 | + | let bR = if ((bQ.dApp == this)) | |
550 | + | then (bQ.function == "takeIntoAccountExtraFunds") | |
549 | 551 | else false | |
550 | - | let | |
551 | - | then if (if (if (( | |
552 | - | then (size( | |
552 | + | let bS = if ((bQ.dApp == C)) | |
553 | + | then if (if (if ((bQ.function == "startStaking")) | |
554 | + | then (size(bQ.payments) == 1) | |
553 | 555 | else false) | |
554 | - | then ( | |
556 | + | then (bQ.payments[0].assetId == I) | |
555 | 557 | else false) | |
556 | 558 | then true | |
557 | - | else if (( | |
558 | - | then (size( | |
559 | + | else if ((bQ.function == "stopStaking")) | |
560 | + | then (size(bQ.payments) == 0) | |
559 | 561 | else false | |
560 | 562 | else false | |
561 | - | let bS = if (if (if (sigVerify(bN.bodyBytes, bN.proofs[0], v)) | |
563 | + | let bT = if (if (if ((bQ.dApp == D)) | |
564 | + | then (bQ.function == "exchange") | |
565 | + | else false) | |
566 | + | then (N == I) | |
567 | + | else false) | |
562 | 568 | then true | |
563 | - | else sigVerify(bN.bodyBytes, bN.proofs[0], w)) | |
569 | + | else if ((O == I)) | |
570 | + | then (bQ.payments[0].assetId == I) | |
571 | + | else false | |
572 | + | let bU = if (if (if (sigVerify(bO.bodyBytes, bO.proofs[0], v)) | |
564 | 573 | then true | |
565 | - | else sigVerify( | |
574 | + | else sigVerify(bO.bodyBytes, bO.proofs[0], w)) | |
566 | 575 | then true | |
567 | - | else sigVerify(bN.bodyBytes, bN.proofs[0], z) | |
568 | - | if (if (bQ) | |
576 | + | else sigVerify(bO.bodyBytes, bO.proofs[0], x)) | |
569 | 577 | then true | |
570 | - | else bR) | |
571 | - | then bS | |
578 | + | else sigVerify(bO.bodyBytes, bO.proofs[0], z) | |
579 | + | if (if (if (bR) | |
580 | + | then true | |
581 | + | else bS) | |
582 | + | then true | |
583 | + | else bT) | |
584 | + | then bU | |
572 | 585 | else false | |
573 | 586 | } | |
574 | 587 | else { | |
575 | - | let | |
588 | + | let bV = if (sigVerify(bO.bodyBytes, bO.proofs[0], v)) | |
576 | 589 | then 1 | |
577 | 590 | else 0 | |
578 | - | let | |
591 | + | let bW = if (sigVerify(bO.bodyBytes, bO.proofs[1], w)) | |
579 | 592 | then 1 | |
580 | 593 | else 0 | |
581 | - | let | |
594 | + | let bX = if (sigVerify(bO.bodyBytes, bO.proofs[2], x)) | |
582 | 595 | then 1 | |
583 | 596 | else 0 | |
584 | - | ((( | |
597 | + | (((bV + bW) + bX) >= 2) | |
585 | 598 | } | |
586 | 599 | } | |
587 | 600 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 4 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let a = "1.0.0" | |
5 | 5 | ||
6 | 6 | let b = "version" | |
7 | 7 | ||
8 | 8 | let c = "active" | |
9 | 9 | ||
10 | 10 | let d = "A_asset_id" | |
11 | 11 | ||
12 | 12 | let e = "B_asset_id" | |
13 | 13 | ||
14 | 14 | let f = "A_asset_balance" | |
15 | 15 | ||
16 | 16 | let g = "B_asset_balance" | |
17 | 17 | ||
18 | 18 | let h = "A_asset_init" | |
19 | 19 | ||
20 | 20 | let i = "B_asset_init" | |
21 | 21 | ||
22 | 22 | let j = "share_asset_id" | |
23 | 23 | ||
24 | 24 | let k = "share_asset_supply" | |
25 | 25 | ||
26 | 26 | let l = "commission" | |
27 | 27 | ||
28 | 28 | let m = "commission_scale_delimiter" | |
29 | 29 | ||
30 | 30 | let n = "shutdown_cause" | |
31 | 31 | ||
32 | 32 | let o = "first_harvest" | |
33 | 33 | ||
34 | 34 | let p = "first_harvest_height" | |
35 | 35 | ||
36 | 36 | let q = "share_limit_on_first_harvest" | |
37 | 37 | ||
38 | 38 | let r = "base_period" | |
39 | 39 | ||
40 | 40 | let s = "period_length" | |
41 | 41 | ||
42 | 42 | let t = "start_height" | |
43 | 43 | ||
44 | 44 | let u = "first_harvest_height" | |
45 | 45 | ||
46 | 46 | let v = base58'Kn7NpzaG12dLZgcHf2ipUftU6hbJygmrhFqQYE4B7ZK' | |
47 | 47 | ||
48 | 48 | let w = base58'Kn7NpzaG12dLZgcHf2ipUftU6hbJygmrhFqQYE4B7ZK' | |
49 | 49 | ||
50 | 50 | let x = base58'Kn7NpzaG12dLZgcHf2ipUftU6hbJygmrhFqQYE4B7ZK' | |
51 | 51 | ||
52 | 52 | let y = base58'Kn7NpzaG12dLZgcHf2ipUftU6hbJygmrhFqQYE4B7ZK' | |
53 | 53 | ||
54 | 54 | let z = base58'Kn7NpzaG12dLZgcHf2ipUftU6hbJygmrhFqQYE4B7ZK' | |
55 | 55 | ||
56 | 56 | let A = Address(base58'3NAGTtZz6WpupSN89NZD5rMZwwziZEg4Kx4') | |
57 | 57 | ||
58 | 58 | let B = Address(base58'3MrJgdL1GniipErHy44YF9idzLaUL2iX5DQ') | |
59 | 59 | ||
60 | 60 | let C = Address(base58'3MyVqAbmKWh339gF6hy8faWw1jGeTV2wnGE') | |
61 | 61 | ||
62 | - | let D = | |
62 | + | let D = Address(base58'3MqsiNaG42muSdN4QxfMQqiwCWccvH368W2') | |
63 | 63 | ||
64 | - | let E = valueOrErrorMessage(getInteger(B, | |
64 | + | let E = valueOrErrorMessage(getInteger(B, r), "Empty kBasePeriod") | |
65 | 65 | ||
66 | - | let F = valueOrErrorMessage(getInteger(B, | |
66 | + | let F = valueOrErrorMessage(getInteger(B, t), "Empty kStartHeight") | |
67 | 67 | ||
68 | - | let G = (( | |
68 | + | let G = valueOrErrorMessage(getInteger(B, s), "Empty kPeriodLength") | |
69 | 69 | ||
70 | - | let H = | |
70 | + | let H = ((E + ((height - F) / G)) + 3) | |
71 | 71 | ||
72 | - | let I = | |
72 | + | let I = base58'ECBCkHS68DckpBrzLeoRgYbFg7sCVqR176mPqbXsj9pA' | |
73 | 73 | ||
74 | - | let J = | |
74 | + | let J = 234000 | |
75 | 75 | ||
76 | - | let K = | |
76 | + | let K = getBooleanValue(this, c) | |
77 | 77 | ||
78 | - | let L = getStringValue(this, | |
78 | + | let L = getStringValue(this, d) | |
79 | 79 | ||
80 | - | let M = if ((K == "WAVES")) | |
81 | - | then unit | |
82 | - | else fromBase58String(K) | |
80 | + | let M = getStringValue(this, e) | |
83 | 81 | ||
84 | 82 | let N = if ((L == "WAVES")) | |
85 | 83 | then unit | |
86 | 84 | else fromBase58String(L) | |
87 | 85 | ||
88 | - | let O = { | |
89 | - | let P = M | |
90 | - | if ($isInstanceOf(P, "ByteVector")) | |
86 | + | let O = if ((M == "WAVES")) | |
87 | + | then unit | |
88 | + | else fromBase58String(M) | |
89 | + | ||
90 | + | let P = { | |
91 | + | let Q = N | |
92 | + | if ($isInstanceOf(Q, "ByteVector")) | |
91 | 93 | then { | |
92 | - | let | |
93 | - | value(assetInfo( | |
94 | + | let R = Q | |
95 | + | value(assetInfo(R)).name | |
94 | 96 | } | |
95 | - | else if ($isInstanceOf( | |
97 | + | else if ($isInstanceOf(Q, "Unit")) | |
96 | 98 | then { | |
97 | - | let | |
99 | + | let S = Q | |
98 | 100 | "WAVES" | |
99 | 101 | } | |
100 | 102 | else throw("Match error") | |
101 | 103 | } | |
102 | 104 | ||
103 | - | let | |
104 | - | let | |
105 | - | if ($isInstanceOf( | |
105 | + | let T = { | |
106 | + | let Q = O | |
107 | + | if ($isInstanceOf(Q, "ByteVector")) | |
106 | 108 | then { | |
107 | - | let | |
108 | - | value(assetInfo( | |
109 | + | let R = Q | |
110 | + | value(assetInfo(R)).name | |
109 | 111 | } | |
110 | - | else if ($isInstanceOf( | |
112 | + | else if ($isInstanceOf(Q, "Unit")) | |
111 | 113 | then { | |
112 | - | let | |
114 | + | let S = Q | |
113 | 115 | "WAVES" | |
114 | 116 | } | |
115 | 117 | else throw("Match error") | |
116 | 118 | } | |
117 | 119 | ||
118 | - | let | |
120 | + | let U = getIntegerValue(this, f) | |
119 | 121 | ||
120 | - | let | |
122 | + | let V = getIntegerValue(this, g) | |
121 | 123 | ||
122 | - | let | |
124 | + | let W = fromBase58String(getStringValue(this, j)) | |
123 | 125 | ||
124 | - | let | |
126 | + | let X = getIntegerValue(this, k) | |
125 | 127 | ||
126 | - | let | |
128 | + | let Y = 3000 | |
127 | 129 | ||
128 | - | let | |
130 | + | let Z = 1200 | |
129 | 131 | ||
130 | - | let | |
132 | + | let aa = 1000000 | |
131 | 133 | ||
132 | - | let | |
134 | + | let ab = 1000 | |
133 | 135 | ||
134 | - | let | |
136 | + | let ac = 100000000 | |
135 | 137 | ||
136 | - | let | |
138 | + | let ad = 1000 | |
137 | 139 | ||
138 | - | let | |
140 | + | let ae = 8 | |
139 | 141 | ||
140 | - | func | |
141 | - | let | |
142 | - | if ($isInstanceOf( | |
142 | + | func af (ag) = { | |
143 | + | let Q = ag | |
144 | + | if ($isInstanceOf(Q, "ByteVector")) | |
143 | 145 | then { | |
144 | - | let | |
145 | - | assetBalance(this, | |
146 | + | let R = Q | |
147 | + | assetBalance(this, R) | |
146 | 148 | } | |
147 | - | else if ($isInstanceOf( | |
149 | + | else if ($isInstanceOf(Q, "Unit")) | |
148 | 150 | then { | |
149 | - | let | |
151 | + | let S = Q | |
150 | 152 | wavesBalance(this).available | |
151 | 153 | } | |
152 | 154 | else throw("Match error") | |
153 | 155 | } | |
154 | 156 | ||
155 | 157 | ||
156 | - | let | |
157 | - | let | |
158 | - | if ($isInstanceOf( | |
158 | + | let ah = { | |
159 | + | let Q = getInteger(C, ((("%s%s%s__stakingBalance__" + toBase58String(I)) + "__") + toString(this))) | |
160 | + | if ($isInstanceOf(Q, "Int")) | |
159 | 161 | then { | |
160 | - | let | |
161 | - | | |
162 | + | let ai = Q | |
163 | + | ai | |
162 | 164 | } | |
163 | - | else if ($isInstanceOf( | |
165 | + | else if ($isInstanceOf(Q, "Unit")) | |
164 | 166 | then { | |
165 | - | let | |
167 | + | let aj = Q | |
166 | 168 | 0 | |
167 | 169 | } | |
168 | 170 | else throw("Match error") | |
169 | 171 | } | |
170 | 172 | ||
171 | - | let | |
173 | + | let ak = getIntegerValue(this, h) | |
172 | 174 | ||
173 | - | let | |
175 | + | let al = getIntegerValue(this, i) | |
174 | 176 | ||
175 | - | let | |
176 | - | then | |
177 | + | let am = (U - (if ((N == I)) | |
178 | + | then ah | |
177 | 179 | else 0)) | |
178 | 180 | ||
179 | - | let | |
180 | - | then | |
181 | + | let an = (V - (if ((O == I)) | |
182 | + | then ah | |
181 | 183 | else 0)) | |
182 | 184 | ||
183 | - | let | |
184 | - | then | |
185 | + | let ao = (af(N) + (if ((N == I)) | |
186 | + | then ah | |
185 | 187 | else 0)) | |
186 | 188 | ||
187 | - | let | |
188 | - | then | |
189 | + | let ap = (af(O) + (if ((O == I)) | |
190 | + | then ah | |
189 | 191 | else 0)) | |
190 | 192 | ||
191 | - | let | |
192 | - | then ( | |
193 | + | let aq = if ((ao >= U)) | |
194 | + | then (ap >= V) | |
193 | 195 | else false | |
194 | 196 | ||
195 | - | func | |
196 | - | let | |
197 | - | if ($isInstanceOf( | |
197 | + | func ar (ag) = { | |
198 | + | let Q = ag | |
199 | + | if ($isInstanceOf(Q, "ByteVector")) | |
198 | 200 | then { | |
199 | - | let | |
200 | - | let | |
201 | - | let | |
202 | - | $Tuple3( | |
201 | + | let R = Q | |
202 | + | let as = toBase58String(R) | |
203 | + | let at = valueOrErrorMessage(assetInfo(R), (("Asset " + as) + " doesn't exist")) | |
204 | + | $Tuple3(as, at.name, at.decimals) | |
203 | 205 | } | |
204 | - | else if ($isInstanceOf( | |
206 | + | else if ($isInstanceOf(Q, "Unit")) | |
205 | 207 | then { | |
206 | - | let | |
208 | + | let S = Q | |
207 | 209 | $Tuple3("WAVES", "WAVES", 8) | |
208 | 210 | } | |
209 | 211 | else throw("Match error") | |
210 | 212 | } | |
211 | 213 | ||
212 | 214 | ||
213 | - | func | |
215 | + | func au (av) = if ((av == "WAVES")) | |
214 | 216 | then $Tuple3("WAVES", "WAVES", 8) | |
215 | 217 | else { | |
216 | - | let | |
217 | - | let | |
218 | - | let | |
219 | - | $Tuple3( | |
218 | + | let as = av | |
219 | + | let R = fromBase58String(av) | |
220 | + | let at = valueOrErrorMessage(assetInfo(R), (("Asset " + as) + " doesn't exist")) | |
221 | + | $Tuple3(as, at.name, at.decimals) | |
220 | 222 | } | |
221 | 223 | ||
222 | 224 | ||
223 | - | func | |
225 | + | func aw (ax) = [BooleanEntry(c, false), StringEntry(n, ax)] | |
224 | 226 | ||
225 | 227 | ||
226 | - | func | |
228 | + | func ay (az,ag) = if ((ag == I)) | |
227 | 229 | then { | |
228 | - | let | |
229 | - | if ((0 >= | |
230 | - | then throw((((("Insufficient amount " + toString( | |
231 | - | else | |
230 | + | let aA = (az - J) | |
231 | + | if ((0 >= aA)) | |
232 | + | then throw((((("Insufficient amount " + toString(az)) + " to deduct staking fee ") + toString(J)) + " USD-N")) | |
233 | + | else aA | |
232 | 234 | } | |
233 | - | else | |
235 | + | else az | |
234 | 236 | ||
235 | 237 | ||
236 | - | func | |
238 | + | func aB (az,aC,aD) = throw((((((((("Insufficient DApp balance to pay " + toString(az)) + " ") + aD) + " due to staking. Available: ") + toString(aC)) + " ") + aD) + ". Please contact support in Telegram: https://t.me/swopfisupport")) | |
237 | 239 | ||
238 | 240 | ||
239 | - | func | |
241 | + | func aE (aF,aG) = throw((((((((((((((((("Insufficient DApp balance to pay " + toString(aF)) + " ") + P) + " and ") + toString(aG)) + " ") + T) + " due to staking. Available: ") + toString(am)) + " ") + P) + " and ") + toString(an)) + " ") + T) + ". Please contact support in Telegram: https://t.me/swopfisupport")) | |
240 | 242 | ||
241 | 243 | ||
242 | - | func | |
244 | + | func aH () = aw(((((((((((((((("Suspicious state. Actual balances: " + toString(ao)) + " ") + P) + ", ") + toString(ap)) + " ") + T) + ". State: ") + toString(U)) + " ") + P) + ", ") + toString(V)) + " ") + T)) | |
243 | 245 | ||
244 | 246 | ||
245 | - | @Callable( | |
246 | - | func init ( | |
247 | - | let | |
248 | - | let | |
249 | - | let | |
250 | - | let | |
251 | - | let | |
252 | - | let | |
253 | - | let | |
254 | - | let | |
255 | - | let | |
256 | - | let | |
257 | - | let | |
258 | - | let | |
259 | - | let | |
260 | - | let | |
261 | - | if (!(containsElement([v, w, x, z], | |
247 | + | @Callable(aI) | |
248 | + | func init (aJ) = { | |
249 | + | let aK = $Tuple2(aI.payments[0].amount, aI.payments[0].assetId) | |
250 | + | let aL = aK._1 | |
251 | + | let aM = aK._2 | |
252 | + | let aN = $Tuple2(aI.payments[1].amount, aI.payments[1].assetId) | |
253 | + | let aO = aN._1 | |
254 | + | let aP = aN._2 | |
255 | + | let aQ = ar(aM) | |
256 | + | let aR = aQ._1 | |
257 | + | let aS = aQ._2 | |
258 | + | let aT = aQ._3 | |
259 | + | let aU = ar(aP) | |
260 | + | let aV = aU._1 | |
261 | + | let aW = aU._2 | |
262 | + | let aX = aU._3 | |
263 | + | if (!(containsElement([v, w, x, z], aI.callerPublicKey))) | |
262 | 264 | then throw("Only admin can call this function") | |
263 | 265 | else if (isDefined(getBoolean(this, c))) | |
264 | 266 | then throw("DApp is already active") | |
265 | - | else if (( | |
267 | + | else if ((aM == aP)) | |
266 | 268 | then throw("Assets must be different") | |
267 | 269 | else { | |
268 | - | let | |
269 | - | let | |
270 | - | let | |
271 | - | let | |
272 | - | let | |
273 | - | let | |
274 | - | let | |
275 | - | if ( | |
276 | - | then ( | |
277 | - | else | |
270 | + | let aY = ((("s" + take(aS, 7)) + "_") + take(aW, 7)) | |
271 | + | let aZ = ((((("ShareToken of SwopFi protocol for " + aS) + " and ") + aW) + " at address ") + toString(this)) | |
272 | + | let ba = ((aT + aX) / 2) | |
273 | + | let bb = fraction(pow(aL, aT, 5, 1, aT, HALFDOWN), pow(aO, aX, 5, 1, aX, HALFDOWN), pow(10, 0, ba, 0, 0, HALFDOWN)) | |
274 | + | let bc = Issue(aY, aZ, bb, ba, true) | |
275 | + | let bd = calculateAssetId(bc) | |
276 | + | let be = [StringEntry(b, a), BooleanEntry(c, true), StringEntry(d, aR), StringEntry(e, aV), IntegerEntry(f, aL), IntegerEntry(g, aO), IntegerEntry(l, Y), IntegerEntry(m, aa), bc, StringEntry(j, toBase58String(bd)), IntegerEntry(k, bb), ScriptTransfer(aI.caller, bb, bd)] | |
277 | + | if (aJ) | |
278 | + | then (be ++ [BooleanEntry(o, aJ), IntegerEntry(p, (F + (H * G)))]) | |
279 | + | else be | |
278 | 280 | } | |
279 | 281 | } | |
280 | 282 | ||
281 | 283 | ||
282 | 284 | ||
283 | - | @Callable( | |
284 | - | func initWithInitRatio ( | |
285 | - | let | |
286 | - | let | |
287 | - | let | |
288 | - | let | |
289 | - | let | |
290 | - | let | |
291 | - | let | |
292 | - | let | |
293 | - | if (!(containsElement([v, w, x, z], | |
285 | + | @Callable(aI) | |
286 | + | func initWithInitRatio (bf,bg,L,M,aJ) = { | |
287 | + | let bh = au(L) | |
288 | + | let aR = bh._1 | |
289 | + | let aS = bh._2 | |
290 | + | let aT = bh._3 | |
291 | + | let bi = au(M) | |
292 | + | let aV = bi._1 | |
293 | + | let aW = bi._2 | |
294 | + | let aX = bi._3 | |
295 | + | if (!(containsElement([v, w, x, z], aI.callerPublicKey))) | |
294 | 296 | then throw("Only admin can call this function") | |
295 | 297 | else if (isDefined(getBoolean(this, c))) | |
296 | 298 | then throw("DApp is already active") | |
297 | - | else if (( | |
299 | + | else if ((L == M)) | |
298 | 300 | then throw("Assets must be different") | |
299 | 301 | else { | |
300 | - | let | |
301 | - | let | |
302 | - | let | |
303 | - | let | |
304 | - | let | |
305 | - | let | |
306 | - | let | |
307 | - | if ( | |
308 | - | then ( | |
309 | - | else | |
302 | + | let aY = ((("s" + take(aS, 7)) + "_") + take(aW, 7)) | |
303 | + | let aZ = ((((("ShareToken of SwopFi protocol for " + aS) + " and ") + aW) + " at address ") + toString(this)) | |
304 | + | let ba = ((aT + aX) / 2) | |
305 | + | let bb = 0 | |
306 | + | let bc = Issue(aY, aZ, bb, ba, true) | |
307 | + | let bd = calculateAssetId(bc) | |
308 | + | let be = [StringEntry(b, a), BooleanEntry(c, true), StringEntry(d, aR), StringEntry(e, aV), IntegerEntry(h, bf), IntegerEntry(i, bg), IntegerEntry(f, 0), IntegerEntry(g, 0), IntegerEntry(l, Y), IntegerEntry(m, aa), bc, StringEntry(j, toBase58String(bd)), IntegerEntry(k, bb)] | |
309 | + | if (aJ) | |
310 | + | then (be ++ [BooleanEntry(o, aJ), IntegerEntry(p, (F + (H * G)))]) | |
311 | + | else be | |
310 | 312 | } | |
311 | 313 | } | |
312 | 314 | ||
313 | 315 | ||
314 | 316 | ||
315 | - | @Callable( | |
316 | - | func keepLimitForFirstHarvest ( | |
317 | + | @Callable(aI) | |
318 | + | func keepLimitForFirstHarvest (bj) = if (!(K)) | |
317 | 319 | then throw("DApp is inactive at this moment") | |
318 | - | else if (!(containsElement([v, w, x, z], | |
320 | + | else if (!(containsElement([v, w, x, z], aI.callerPublicKey))) | |
319 | 321 | then throw("Only admin can call this function") | |
320 | - | else [IntegerEntry(q, | |
322 | + | else [IntegerEntry(q, bj)] | |
321 | 323 | ||
322 | 324 | ||
323 | 325 | ||
324 | - | @Callable( | |
325 | - | func replenishWithTwoTokens ( | |
326 | - | let | |
327 | - | let | |
328 | - | let | |
329 | - | let | |
330 | - | if (if (( | |
331 | - | then ( | |
326 | + | @Callable(aI) | |
327 | + | func replenishWithTwoTokens (bk) = { | |
328 | + | let aM = aI.payments[0].assetId | |
329 | + | let aP = aI.payments[1].assetId | |
330 | + | let aL = ay(aI.payments[0].amount, aM) | |
331 | + | let aO = ay(aI.payments[1].amount, aP) | |
332 | + | if (if ((U == 0)) | |
333 | + | then (V == 0) | |
332 | 334 | else false) | |
333 | 335 | then { | |
334 | - | let | |
335 | - | let | |
336 | - | let | |
337 | - | let | |
338 | - | let | |
339 | - | let | |
340 | - | let | |
341 | - | let | |
342 | - | let | |
343 | - | if (( | |
336 | + | let bl = ar(aM) | |
337 | + | let aR = bl._1 | |
338 | + | let aS = bl._2 | |
339 | + | let aT = bl._3 | |
340 | + | let bm = ar(aP) | |
341 | + | let aV = bm._1 | |
342 | + | let aW = bm._2 | |
343 | + | let aX = bm._3 | |
344 | + | let bn = fraction(fraction(ak, ac, aL), ab, fraction(al, ac, aO)) | |
345 | + | if ((aM == aP)) | |
344 | 346 | then throw("Assets must be different") | |
345 | 347 | else { | |
346 | - | let | |
347 | - | let | |
348 | - | if (!( | |
348 | + | let ba = ((aT + aX) / 2) | |
349 | + | let bb = fraction(pow(aL, aT, 5, 1, aT, HALFDOWN), pow(aO, aX, 5, 1, aX, HALFDOWN), pow(10, 0, ba, 0, 0, HALFDOWN)) | |
350 | + | if (!(K)) | |
349 | 351 | then throw("DApp is inactive at this moment") | |
350 | - | else if (if ((0 > | |
352 | + | else if (if ((0 > bk)) | |
351 | 353 | then true | |
352 | - | else ( | |
353 | - | then throw(((("Slippage tolerance must be between 0 and " + toString( | |
354 | - | else if ((size( | |
354 | + | else (bk > ad)) | |
355 | + | then throw(((("Slippage tolerance must be between 0 and " + toString(ad)) + " inclusively. Actual: ") + toString(bk))) | |
356 | + | else if ((size(aI.payments) != 2)) | |
355 | 357 | then throw("Two attached assets expected") | |
356 | - | else if (if (((( | |
358 | + | else if (if ((((ab * (ad - bk)) / ad) > bn)) | |
357 | 359 | then true | |
358 | - | else ( | |
360 | + | else (bn > ((ab * (ad + bk)) / ad))) | |
359 | 361 | then throw("Incorrect assets amount: amounts must have the contract ratio") | |
360 | - | else if (if (( | |
362 | + | else if (if ((aM != N)) | |
361 | 363 | then true | |
362 | - | else ( | |
363 | - | then throw(((("Incorrect assets attached. Expected: " + | |
364 | - | else if (( | |
364 | + | else (aP != O)) | |
365 | + | then throw(((("Incorrect assets attached. Expected: " + L) + " and ") + M)) | |
366 | + | else if ((bb == 0)) | |
365 | 367 | then throw("Too small amount to replenish") | |
366 | - | else if (!( | |
367 | - | then ([ScriptTransfer( | |
368 | - | else [Reissue( | |
368 | + | else if (!(aq)) | |
369 | + | then ([ScriptTransfer(aI.caller, aL, aM), ScriptTransfer(aI.caller, aO, aP)] ++ aH()) | |
370 | + | else [Reissue(W, bb, true), IntegerEntry(f, aL), IntegerEntry(g, aO), IntegerEntry(k, bb), ScriptTransfer(aI.caller, bb, W)] | |
369 | 371 | } | |
370 | 372 | } | |
371 | 373 | else { | |
372 | - | let | |
373 | - | let | |
374 | - | let | |
375 | - | let | |
376 | - | if (!( | |
374 | + | let bn = fraction(fraction(U, ac, aL), ab, fraction(V, ac, aO)) | |
375 | + | let bo = fraction(aL, ac, U) | |
376 | + | let bp = fraction(aO, ac, V) | |
377 | + | let bq = fraction(min([bo, bp]), X, ac) | |
378 | + | if (!(K)) | |
377 | 379 | then throw("DApp is inactive at this moment") | |
378 | - | else if (if ((0 > | |
380 | + | else if (if ((0 > bk)) | |
379 | 381 | then true | |
380 | - | else ( | |
381 | - | then throw(((("Slippage tolerance must be between 0 and " + toString( | |
382 | - | else if ((size( | |
382 | + | else (bk > ad)) | |
383 | + | then throw(((("Slippage tolerance must be between 0 and " + toString(ad)) + " inclusively. Actual: ") + toString(bk))) | |
384 | + | else if ((size(aI.payments) != 2)) | |
383 | 385 | then throw("Two attached assets expected") | |
384 | - | else if (if (( | |
386 | + | else if (if ((aM != N)) | |
385 | 387 | then true | |
386 | - | else ( | |
387 | - | then throw(((("Incorrect assets attached. Expected: " + | |
388 | - | else if (if (((( | |
388 | + | else (aP != O)) | |
389 | + | then throw(((("Incorrect assets attached. Expected: " + L) + " and ") + M)) | |
390 | + | else if (if ((((ab * (ad - bk)) / ad) > bn)) | |
389 | 391 | then true | |
390 | - | else ( | |
392 | + | else (bn > ((ab * (ad + bk)) / ad))) | |
391 | 393 | then throw("Incorrect assets amount: amounts must have the contract ratio") | |
392 | - | else if (( | |
394 | + | else if ((bq == 0)) | |
393 | 395 | then throw("Too small amount to replenish") | |
394 | - | else if (!( | |
395 | - | then ([ScriptTransfer( | |
396 | - | else [IntegerEntry(f, ( | |
396 | + | else if (!(aq)) | |
397 | + | then ([ScriptTransfer(aI.caller, aL, aM), ScriptTransfer(aI.caller, aO, aP)] ++ aH()) | |
398 | + | else [IntegerEntry(f, (U + aL)), IntegerEntry(g, (V + aO)), IntegerEntry(k, (X + bq)), Reissue(W, bq, true), ScriptTransfer(aI.caller, bq, W)] | |
397 | 399 | } | |
398 | 400 | } | |
399 | 401 | ||
400 | 402 | ||
401 | 403 | ||
402 | - | @Callable( | |
404 | + | @Callable(aI) | |
403 | 405 | func withdraw () = { | |
404 | - | let | |
405 | - | let | |
406 | - | let | |
407 | - | let | |
408 | - | let | |
409 | - | if (!( | |
406 | + | let br = $Tuple2(aI.payments[0].amount, aI.payments[0].assetId) | |
407 | + | let bs = br._1 | |
408 | + | let bt = br._2 | |
409 | + | let bu = ay(fraction(bs, U, X), N) | |
410 | + | let bv = ay(fraction(bs, V, X), O) | |
411 | + | if (!(K)) | |
410 | 412 | then throw("DApp is inactive at this moment") | |
411 | - | else if ((size( | |
413 | + | else if ((size(aI.payments) != 1)) | |
412 | 414 | then throw("One attached payment expected") | |
413 | - | else if (( | |
414 | - | then throw(("Incorrect asset attached. Expected: " + toBase58String( | |
415 | - | else if (!( | |
416 | - | then ([ScriptTransfer( | |
417 | - | else if (if (( | |
415 | + | else if ((bt != W)) | |
416 | + | then throw(("Incorrect asset attached. Expected: " + toBase58String(W))) | |
417 | + | else if (!(aq)) | |
418 | + | then ([ScriptTransfer(aI.caller, bs, bt)] ++ aH()) | |
419 | + | else if (if ((bu > am)) | |
418 | 420 | then true | |
419 | - | else ( | |
420 | - | then | |
421 | - | else [IntegerEntry(f, ( | |
421 | + | else (bv > an)) | |
422 | + | then aE(bu, bv) | |
423 | + | else [IntegerEntry(f, (U - bu)), IntegerEntry(g, (V - bv)), IntegerEntry(k, (X - bs)), Burn(W, bs), ScriptTransfer(aI.caller, bu, N), ScriptTransfer(aI.caller, bv, O)] | |
422 | 424 | } | |
423 | 425 | ||
424 | 426 | ||
425 | 427 | ||
426 | - | @Callable( | |
427 | - | func exchange ( | |
428 | - | let | |
429 | - | let | |
430 | - | let | |
431 | - | func | |
432 | - | let | |
433 | - | let | |
434 | - | let | |
435 | - | if (( | |
436 | - | then throw(((("Calculated amount to receive " + toString( | |
437 | - | else $Tuple3( | |
428 | + | @Callable(aI) | |
429 | + | func exchange (bw) = { | |
430 | + | let bx = $Tuple2(aI.payments[0].amount, aI.payments[0].assetId) | |
431 | + | let bs = bx._1 | |
432 | + | let bt = bx._2 | |
433 | + | func by (bz,bA) = { | |
434 | + | let bB = fraction(bA, bs, (bs + bz)) | |
435 | + | let bC = fraction(bB, (aa - Y), aa) | |
436 | + | let bD = fraction(bB, Z, aa) | |
437 | + | if ((bw > bC)) | |
438 | + | then throw(((("Calculated amount to receive " + toString(bC)) + " is less than specified minimum ") + toString(bw))) | |
439 | + | else $Tuple3(bB, bC, bD) | |
438 | 440 | } | |
439 | 441 | ||
440 | - | if (!( | |
442 | + | if (!(K)) | |
441 | 443 | then throw("DApp is inactive at this moment") | |
442 | - | else if (if (( | |
444 | + | else if (if ((U == 0)) | |
443 | 445 | then true | |
444 | - | else ( | |
446 | + | else (V == 0)) | |
445 | 447 | then throw("Can't exchange with zero balance") | |
446 | - | else if ((0 >= | |
447 | - | then throw(("Minimal amount to receive must be positive. Actual: " + toString( | |
448 | - | else if ((size( | |
448 | + | else if ((0 >= bw)) | |
449 | + | then throw(("Minimal amount to receive must be positive. Actual: " + toString(bw))) | |
450 | + | else if ((size(aI.payments) != 1)) | |
449 | 451 | then throw("One attached payment expected") | |
450 | - | else if (!( | |
451 | - | then ([ScriptTransfer( | |
452 | - | else if (( | |
452 | + | else if (!(aq)) | |
453 | + | then ([ScriptTransfer(aI.caller, bs, bt)] ++ aH()) | |
454 | + | else if ((bt == N)) | |
453 | 455 | then { | |
454 | - | let | |
455 | - | let | |
456 | - | let | |
457 | - | let | |
458 | - | let | |
459 | - | let | |
460 | - | let | |
461 | - | if (if (if (( | |
462 | - | then ( | |
456 | + | let bE = O | |
457 | + | let bF = by(U, V) | |
458 | + | let bB = bF._1 | |
459 | + | let bC = bF._2 | |
460 | + | let bD = bF._3 | |
461 | + | let bG = (U + bs) | |
462 | + | let bH = ((V - bC) - bD) | |
463 | + | if (if (if ((N == I)) | |
464 | + | then (ah >= bG) | |
463 | 465 | else false) | |
464 | 466 | then true | |
465 | - | else if (( | |
466 | - | then ( | |
467 | + | else if ((O == I)) | |
468 | + | then (ah >= bH) | |
467 | 469 | else false) | |
468 | - | then | |
469 | - | else [IntegerEntry(f, | |
470 | + | then aB(bC, an, T) | |
471 | + | else [IntegerEntry(f, bG), IntegerEntry(g, bH), ScriptTransfer(aI.caller, bC, bE), ScriptTransfer(A, bD, bE)] | |
470 | 472 | } | |
471 | - | else if (( | |
473 | + | else if ((bt == O)) | |
472 | 474 | then { | |
473 | - | let | |
474 | - | let | |
475 | - | let | |
476 | - | let | |
477 | - | let | |
478 | - | let | |
479 | - | let | |
480 | - | if (if (if (( | |
481 | - | then ( | |
475 | + | let bE = N | |
476 | + | let bI = by(V, U) | |
477 | + | let bB = bI._1 | |
478 | + | let bC = bI._2 | |
479 | + | let bD = bI._3 | |
480 | + | let bG = ((U - bC) - bD) | |
481 | + | let bH = (V + bs) | |
482 | + | if (if (if ((N == I)) | |
483 | + | then (ah >= bG) | |
482 | 484 | else false) | |
483 | 485 | then true | |
484 | - | else if (( | |
485 | - | then ( | |
486 | + | else if ((O == I)) | |
487 | + | then (ah >= bH) | |
486 | 488 | else false) | |
487 | - | then | |
488 | - | else [IntegerEntry(f, | |
489 | + | then aB(bC, am, P) | |
490 | + | else [IntegerEntry(f, bG), IntegerEntry(g, bH), ScriptTransfer(aI.caller, bC, bE), ScriptTransfer(A, bD, bE)] | |
489 | 491 | } | |
490 | - | else throw(((("Incorrect asset attached. Expected: " + | |
492 | + | else throw(((("Incorrect asset attached. Expected: " + L) + " or ") + M)) | |
491 | 493 | } | |
492 | 494 | ||
493 | 495 | ||
494 | 496 | ||
495 | - | @Callable( | |
496 | - | func shutdown () = if (!( | |
497 | + | @Callable(aI) | |
498 | + | func shutdown () = if (!(K)) | |
497 | 499 | then throw(("DApp is already suspended. Cause: " + valueOrElse(getString(this, n), "the cause wasn't specified"))) | |
498 | - | else if (!(containsElement([v, w, x, y], | |
500 | + | else if (!(containsElement([v, w, x, y], aI.callerPublicKey))) | |
499 | 501 | then throw("Only admin can call this function") | |
500 | - | else | |
502 | + | else aw("Paused by admin") | |
501 | 503 | ||
502 | 504 | ||
503 | 505 | ||
504 | - | @Callable( | |
505 | - | func activate () = if ( | |
506 | + | @Callable(aI) | |
507 | + | func activate () = if (K) | |
506 | 508 | then throw("DApp is already active") | |
507 | - | else if (!(containsElement([v, w, x, y], | |
509 | + | else if (!(containsElement([v, w, x, y], aI.callerPublicKey))) | |
508 | 510 | then throw("Only admin can call this function") | |
509 | 511 | else [BooleanEntry(c, true), DeleteEntry(n)] | |
510 | 512 | ||
511 | 513 | ||
512 | 514 | ||
513 | - | @Callable(aH) | |
514 | - | func takeIntoAccountExtraFunds (bI) = { | |
515 | - | let bJ = (an - T) | |
515 | + | @Callable(aI) | |
516 | + | func takeIntoAccountExtraFunds (bJ) = { | |
516 | 517 | let bK = (ao - U) | |
517 | - | let bL = (bJ - (if ((M == unit)) | |
518 | - | then bI | |
518 | + | let bL = (ap - V) | |
519 | + | let bM = (bK - (if ((N == unit)) | |
520 | + | then bJ | |
519 | 521 | else 0)) | |
520 | - | let | |
521 | - | then | |
522 | + | let bN = (bL - (if ((O == unit)) | |
523 | + | then bJ | |
522 | 524 | else 0)) | |
523 | - | if (!( | |
525 | + | if (!(K)) | |
524 | 526 | then throw("DApp is inactive at this moment") | |
525 | - | else if (( | |
527 | + | else if ((aI.caller != this)) | |
526 | 528 | then throw("Only the DApp itself can call this function") | |
527 | - | else if ((0 > | |
528 | - | then throw(("Argument 'amountLeave' cannot be negative. Actual: " + toString( | |
529 | - | else if (if ((0 > | |
529 | + | else if ((0 > bJ)) | |
530 | + | then throw(("Argument 'amountLeave' cannot be negative. Actual: " + toString(bJ))) | |
531 | + | else if (if ((0 > bK)) | |
530 | 532 | then true | |
531 | - | else (0 > | |
532 | - | then | |
533 | - | else if (if ((0 > | |
533 | + | else (0 > bL)) | |
534 | + | then aw("Enroll amount negative") | |
535 | + | else if (if ((0 > bM)) | |
534 | 536 | then true | |
535 | - | else (0 > | |
537 | + | else (0 > bN)) | |
536 | 538 | then throw("Too large amountLeave") | |
537 | - | else [IntegerEntry(f, ( | |
539 | + | else [IntegerEntry(f, (U + bM)), IntegerEntry(g, (V + bN)), IntegerEntry(("last_income_" + L), bM), IntegerEntry(("last_income_" + M), bN)] | |
538 | 540 | } | |
539 | 541 | ||
540 | 542 | ||
541 | - | @Verifier( | |
542 | - | func | |
543 | - | let | |
544 | - | if ($isInstanceOf( | |
543 | + | @Verifier(bO) | |
544 | + | func bP () = { | |
545 | + | let Q = bO | |
546 | + | if ($isInstanceOf(Q, "InvokeScriptTransaction")) | |
545 | 547 | then { | |
546 | - | let | |
547 | - | let | |
548 | - | then ( | |
548 | + | let bQ = Q | |
549 | + | let bR = if ((bQ.dApp == this)) | |
550 | + | then (bQ.function == "takeIntoAccountExtraFunds") | |
549 | 551 | else false | |
550 | - | let | |
551 | - | then if (if (if (( | |
552 | - | then (size( | |
552 | + | let bS = if ((bQ.dApp == C)) | |
553 | + | then if (if (if ((bQ.function == "startStaking")) | |
554 | + | then (size(bQ.payments) == 1) | |
553 | 555 | else false) | |
554 | - | then ( | |
556 | + | then (bQ.payments[0].assetId == I) | |
555 | 557 | else false) | |
556 | 558 | then true | |
557 | - | else if (( | |
558 | - | then (size( | |
559 | + | else if ((bQ.function == "stopStaking")) | |
560 | + | then (size(bQ.payments) == 0) | |
559 | 561 | else false | |
560 | 562 | else false | |
561 | - | let bS = if (if (if (sigVerify(bN.bodyBytes, bN.proofs[0], v)) | |
563 | + | let bT = if (if (if ((bQ.dApp == D)) | |
564 | + | then (bQ.function == "exchange") | |
565 | + | else false) | |
566 | + | then (N == I) | |
567 | + | else false) | |
562 | 568 | then true | |
563 | - | else sigVerify(bN.bodyBytes, bN.proofs[0], w)) | |
569 | + | else if ((O == I)) | |
570 | + | then (bQ.payments[0].assetId == I) | |
571 | + | else false | |
572 | + | let bU = if (if (if (sigVerify(bO.bodyBytes, bO.proofs[0], v)) | |
564 | 573 | then true | |
565 | - | else sigVerify( | |
574 | + | else sigVerify(bO.bodyBytes, bO.proofs[0], w)) | |
566 | 575 | then true | |
567 | - | else sigVerify(bN.bodyBytes, bN.proofs[0], z) | |
568 | - | if (if (bQ) | |
576 | + | else sigVerify(bO.bodyBytes, bO.proofs[0], x)) | |
569 | 577 | then true | |
570 | - | else bR) | |
571 | - | then bS | |
578 | + | else sigVerify(bO.bodyBytes, bO.proofs[0], z) | |
579 | + | if (if (if (bR) | |
580 | + | then true | |
581 | + | else bS) | |
582 | + | then true | |
583 | + | else bT) | |
584 | + | then bU | |
572 | 585 | else false | |
573 | 586 | } | |
574 | 587 | else { | |
575 | - | let | |
588 | + | let bV = if (sigVerify(bO.bodyBytes, bO.proofs[0], v)) | |
576 | 589 | then 1 | |
577 | 590 | else 0 | |
578 | - | let | |
591 | + | let bW = if (sigVerify(bO.bodyBytes, bO.proofs[1], w)) | |
579 | 592 | then 1 | |
580 | 593 | else 0 | |
581 | - | let | |
594 | + | let bX = if (sigVerify(bO.bodyBytes, bO.proofs[2], x)) | |
582 | 595 | then 1 | |
583 | 596 | else 0 | |
584 | - | ((( | |
597 | + | (((bV + bW) + bX) >= 2) | |
585 | 598 | } | |
586 | 599 | } | |
587 | 600 |
github/deemru/w8io/026f985 217.68 ms ◑