tx · H3EAeqkPt32TW69LFVYzSQrL6VpyvQcoTTDCpQx6Binu 3N55kCyUFy8M2ooKRwierKnP7L6viqzScNn: -0.02900000 Waves 2022.10.26 09:34 [2289034] smart account 3N55kCyUFy8M2ooKRwierKnP7L6viqzScNn > SELF 0.00000000 Waves
{ "type": 13, "id": "H3EAeqkPt32TW69LFVYzSQrL6VpyvQcoTTDCpQx6Binu", "fee": 2900000, "feeAssetId": null, "timestamp": 1666766057521, "version": 1, "sender": "3N55kCyUFy8M2ooKRwierKnP7L6viqzScNn", "senderPublicKey": "HpuFV1RhaXZ5gaJNgeLjyAKy3D5q7fMKdNFYYbPDafnb", "proofs": [ "27AJd3N9kAV7wjXi1BNpDGa74BPPg93qNJjyGvHfUatfQ2yieRu1N2j28vn1AHLqPUrV59cLYNhHSX35Ytn8ugov" ], "script": "base64:BgKfJwgCEgMKAQgSABIECgIBBBIDCgEBEgQKAgEEEgQKAggBEgQKAggBEgQKAggBEgUKAwEIARIAEgQKAgEBEgMKAQESBAoCCAgSABIDCgEIEgUKAwEBARIECgIBARIECgIIARIECgIICBILCgkIAQECAQIIBAQSBgoECAgBCBIAEgMKAQESAwoBARIECgIIASIKbFBkZWNpbWFscyIGc2NhbGU4IgxzY2FsZThCaWdJbnQiB3NjYWxlMTgiCnplcm9CaWdJbnQiBGJpZzAiBGJpZzEiBGJpZzIiC3dhdmVzU3RyaW5nIgNTRVAiClBvb2xBY3RpdmUiD1Bvb2xQdXREaXNhYmxlZCITUG9vbE1hdGNoZXJEaXNhYmxlZCIMUG9vbFNodXRkb3duIg5pZHhQb29sQWRkcmVzcyINaWR4UG9vbFN0YXR1cyIQaWR4UG9vbExQQXNzZXRJZCINaWR4QW10QXNzZXRJZCIPaWR4UHJpY2VBc3NldElkIg5pZHhBbXRBc3NldERjbSIQaWR4UHJpY2VBc3NldERjbSIOaWR4SUFtdEFzc2V0SWQiEGlkeElQcmljZUFzc2V0SWQiDWlkeExQQXNzZXREY20iEmlkeFBvb2xBbXR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UJ5dGVzCQCRAwIIBQJmSAZwcm9vZnMAAAUCZkoJAPQDAwgFAmZICWJvZHlCeXRlcwkAkQMCCAUCZkgGcHJvb2ZzAAAFAmZKgGPfUg==", "chainId": 84, "height": 2289034, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 2z73ufLaxC3K8A9TWMds9be5AYtvscpJegchgaBGK2bo Next: FRfi6yNCE1vsf3JSZdpvyCAFiZ9gtQ5RfGL5xbqZkrCi Diff:
Old | New | Differences | |
---|---|---|---|
68 | 68 | func J (K,L,M) = fraction(K, L, M) | |
69 | 69 | ||
70 | 70 | ||
71 | - | func N (H) = if (( | |
71 | + | func N (H) = if ((0 > H)) | |
72 | 72 | then -(H) | |
73 | 73 | else H | |
74 | 74 | ||
75 | 75 | ||
76 | - | func O () = "%s__factoryContract" | |
76 | + | func O (H) = if ((e > H)) | |
77 | + | then -(H) | |
78 | + | else H | |
77 | 79 | ||
78 | 80 | ||
79 | - | func P () = "%s__ | |
81 | + | func P () = "%s__factoryContract" | |
80 | 82 | ||
81 | 83 | ||
82 | - | func Q () = "%s__ | |
84 | + | func Q () = "%s__managerPublicKey" | |
83 | 85 | ||
84 | 86 | ||
85 | - | func R () = "%s | |
87 | + | func R () = "%s__pendingManagerPublicKey" | |
86 | 88 | ||
87 | 89 | ||
88 | - | func S ( | |
90 | + | func S () = "%s%s__price__last" | |
89 | 91 | ||
90 | 92 | ||
91 | - | func | |
93 | + | func T (U,V) = makeString(["%s%s%d%d__price__history", toString(U), toString(V)], j) | |
92 | 94 | ||
93 | 95 | ||
94 | - | func | |
96 | + | func W (X,Y) = ((("%s%s%s__P__" + X) + "__") + Y) | |
95 | 97 | ||
96 | 98 | ||
97 | - | func Z () = "%s__ | |
99 | + | func Z (X,Y) = ((("%s%s%s__G__" + X) + "__") + Y) | |
98 | 100 | ||
99 | 101 | ||
100 | - | func aa () = "%s__ | |
102 | + | func aa () = "%s__amountAsset" | |
101 | 103 | ||
102 | 104 | ||
103 | - | let ab = "%s__fee" | |
104 | - | ||
105 | - | let ac = fraction(5, b, 10000) | |
106 | - | ||
107 | - | let ad = valueOrElse(getInteger(this, ab), ac) | |
108 | - | ||
109 | - | func ae () = "%s__factoryConfig" | |
105 | + | func ab () = "%s__priceAsset" | |
110 | 106 | ||
111 | 107 | ||
112 | - | func af () = "%s%s__matcher__publicKey" | |
108 | + | let ac = "%s__fee" | |
109 | + | ||
110 | + | let ad = fraction(5, b, 10000) | |
111 | + | ||
112 | + | let ae = valueOrElse(getInteger(this, ac), ad) | |
113 | + | ||
114 | + | func af () = "%s__factoryConfig" | |
113 | 115 | ||
114 | 116 | ||
115 | - | func ag ( | |
117 | + | func ag () = "%s%s__matcher__publicKey" | |
116 | 118 | ||
117 | 119 | ||
118 | - | func | |
120 | + | func ah (ai) = (("%s%s%s__" + ai) + "__mappings__poolContract2LpAsset") | |
119 | 121 | ||
120 | 122 | ||
121 | - | func | |
123 | + | func aj (ak,al) = (((("%d%d%s__" + ak) + "__") + al) + "__config") | |
122 | 124 | ||
123 | 125 | ||
124 | - | func | |
126 | + | func am (an) = ("%s%s%s__mappings__baseAsset2internalId__" + an) | |
125 | 127 | ||
126 | 128 | ||
127 | - | func ao ( | |
129 | + | func ao () = "%s__shutdown" | |
128 | 130 | ||
129 | 131 | ||
130 | - | func | |
132 | + | func ap (aq) = ("%s%s__poolWeight__" + aq) | |
131 | 133 | ||
132 | 134 | ||
133 | - | let ar = "%s__feeCollectorAddress" | |
134 | - | ||
135 | - | func as (at,au,av) = throw(((((("order validation failed: orderValid=" + toString(at)) + " senderValid=") + toString(au)) + " matcherValid=") + toString(av))) | |
135 | + | func ar () = "%s__allowedLpScriptHash" | |
136 | 136 | ||
137 | 137 | ||
138 | - | func aw (ax,ay) = valueOrErrorMessage(getString(ax, ay), makeString(["mandatory ", toString(ax), ".", ay, " is not defined"], "")) | |
138 | + | let as = "%s__feeCollectorAddress" | |
139 | + | ||
140 | + | func at (au,av,aw) = throw(((((("order validation failed: orderValid=" + toString(au)) + " senderValid=") + toString(av)) + " matcherValid=") + toString(aw))) | |
139 | 141 | ||
140 | 142 | ||
141 | - | func | |
143 | + | func ax (ay,az) = valueOrErrorMessage(getString(ay, az), makeString(["mandatory ", toString(ay), ".", az, " is not defined"], "")) | |
142 | 144 | ||
143 | 145 | ||
144 | - | func aA ( | |
146 | + | func aA (ay,az) = valueOrErrorMessage(getInteger(ay, az), makeString(["mandatory ", toString(ay), ".", az, " is not defined"], "")) | |
145 | 147 | ||
146 | 148 | ||
147 | - | let aC = addressFromStringValue(aw(this, O())) | |
148 | - | ||
149 | - | let aD = addressFromStringValue(aw(aC, ar)) | |
150 | - | ||
151 | - | func aE () = valueOrElse(getBoolean(aC, an()), false) | |
149 | + | func aB (aC) = throw(makeString(["lp.ride:", aC], " ")) | |
152 | 150 | ||
153 | 151 | ||
154 | - | func aF () = fromBase58String(aw(aC, af())) | |
152 | + | let aD = addressFromStringValue(ax(this, P())) | |
153 | + | ||
154 | + | let aE = addressFromStringValue(ax(aD, as)) | |
155 | + | ||
156 | + | func aF () = valueOrElse(getBoolean(aD, ao()), false) | |
155 | 157 | ||
156 | 158 | ||
157 | - | func aG () = { | |
158 | - | let aH = aw(this, Z()) | |
159 | - | let aI = aw(this, aa()) | |
160 | - | let ak = az(aC, al(aI)) | |
161 | - | let aj = az(aC, al(aH)) | |
162 | - | split(aw(aC, ai(toString(aj), toString(ak))), j) | |
159 | + | func aG () = fromBase58String(ax(aD, ag())) | |
160 | + | ||
161 | + | ||
162 | + | func aH () = { | |
163 | + | let aI = ax(this, aa()) | |
164 | + | let aJ = ax(this, ab()) | |
165 | + | let al = aA(aD, am(aJ)) | |
166 | + | let ak = aA(aD, am(aI)) | |
167 | + | split(ax(aD, aj(toString(ak), toString(al))), j) | |
163 | 168 | } | |
164 | 169 | ||
165 | 170 | ||
166 | - | func | |
171 | + | func aK (aL) = if ((aL == i)) | |
167 | 172 | then unit | |
168 | - | else fromBase58String( | |
173 | + | else fromBase58String(aL) | |
169 | 174 | ||
170 | 175 | ||
171 | - | func | |
176 | + | func aM (aL) = if ((aL == unit)) | |
172 | 177 | then i | |
173 | - | else toBase58String(value( | |
178 | + | else toBase58String(value(aL)) | |
174 | 179 | ||
175 | 180 | ||
176 | - | func | |
181 | + | func aN (aO) = $Tuple7(addressFromStringValue(aO[o]), parseIntValue(aO[p]), fromBase58String(aO[q]), aK(aO[r]), aK(aO[s]), parseIntValue(aO[t]), parseIntValue(aO[u])) | |
177 | 182 | ||
178 | 183 | ||
179 | - | let | |
184 | + | let aP = aN(aH()) | |
180 | 185 | ||
181 | - | let | |
186 | + | let aQ = aP | |
182 | 187 | ||
183 | - | let | |
188 | + | let aR = aQ._1 | |
184 | 189 | ||
185 | - | let | |
190 | + | let aS = aQ._2 | |
186 | 191 | ||
187 | - | let | |
192 | + | let aT = aQ._3 | |
188 | 193 | ||
189 | - | let | |
194 | + | let aU = aQ._4 | |
190 | 195 | ||
191 | - | let | |
196 | + | let aV = aQ._5 | |
192 | 197 | ||
193 | - | let | |
198 | + | let aW = aQ._6 | |
194 | 199 | ||
195 | - | let | |
200 | + | let aX = aQ._7 | |
196 | 201 | ||
197 | - | func | |
202 | + | func aY () = split(ax(aD, af()), j) | |
198 | 203 | ||
199 | 204 | ||
200 | - | let | |
205 | + | let aZ = valueOrErrorMessage(addressFromString(aY()[B]), "incorrect staking address") | |
201 | 206 | ||
202 | - | let | |
207 | + | let ba = valueOrErrorMessage(addressFromString(aY()[C]), "incorrect staking address") | |
203 | 208 | ||
204 | - | func | |
209 | + | func bb (bc,bd,be,bf,bg,bh,bi,bj,bk,bl) = makeString(["%d%d%d%d%d%d%d%d%d%d", toString(bc), toString(bd), toString(be), toString(bf), toString(bg), toString(bh), toString(bi), toString(bj), toString(bk), toString(bl)], j) | |
205 | 210 | ||
206 | 211 | ||
207 | - | func | |
212 | + | func bm (bn,bo,bp,bf,bi,bj) = makeString(["%d%d%d%d%d%d", toString(bn), toString(bo), toString(bp), toString(bf), toString(bi), toString(bj)], j) | |
208 | 213 | ||
209 | 214 | ||
210 | - | func | |
215 | + | func bq (br) = if ((br == "WAVES")) | |
211 | 216 | then wavesBalance(this).available | |
212 | - | else assetBalance(this, fromBase58String( | |
217 | + | else assetBalance(this, fromBase58String(br)) | |
213 | 218 | ||
214 | 219 | ||
215 | - | func | |
220 | + | func bs (bt,bu) = fraction(bt, d, bu) | |
216 | 221 | ||
217 | 222 | ||
218 | - | func bu (bv,bw,bx,by) = { | |
219 | - | let bz = D(bx, bv) | |
223 | + | func bv (bw,bx,by,bz) = { | |
220 | 224 | let bA = D(by, bw) | |
221 | - | br(bA, bz) | |
225 | + | let bB = D(bz, bx) | |
226 | + | bs(bB, bA) | |
222 | 227 | } | |
223 | 228 | ||
224 | 229 | ||
225 | - | func | |
226 | - | let | |
227 | - | let | |
228 | - | let | |
229 | - | let | |
230 | - | let | |
231 | - | let | |
232 | - | let | |
233 | - | let | |
234 | - | let | |
235 | - | [ | |
230 | + | func bC (by,bz,bD) = { | |
231 | + | let bE = aH() | |
232 | + | let bF = parseIntValue(bE[t]) | |
233 | + | let bG = parseIntValue(bE[u]) | |
234 | + | let bH = bv(bF, bG, by, bz) | |
235 | + | let bu = D(by, bF) | |
236 | + | let bt = D(bz, bG) | |
237 | + | let bI = D(bD, b) | |
238 | + | let bJ = bs(bu, bI) | |
239 | + | let bK = bs(bt, bI) | |
240 | + | [bH, bJ, bK] | |
236 | 241 | } | |
237 | 242 | ||
238 | 243 | ||
239 | - | func | |
240 | - | let | |
241 | - | [G( | |
244 | + | func bL (by,bz,bD) = { | |
245 | + | let bM = bC(by, bz, bD) | |
246 | + | [G(bM[0], b), G(bM[1], b), G(bM[2], b)] | |
242 | 247 | } | |
243 | 248 | ||
244 | 249 | ||
245 | - | func | |
246 | - | let | |
247 | - | let | |
248 | - | let | |
249 | - | let | |
250 | - | let | |
251 | - | let | |
252 | - | let | |
253 | - | let | |
254 | - | if (( | |
250 | + | func bN (bO,bP,bQ,X) = { | |
251 | + | let bE = aH() | |
252 | + | let bR = bE[q] | |
253 | + | let bS = bE[r] | |
254 | + | let bT = bE[s] | |
255 | + | let bw = parseIntValue(bE[t]) | |
256 | + | let bx = parseIntValue(bE[u]) | |
257 | + | let bU = bE[p] | |
258 | + | let bV = valueOrErrorMessage(assetInfo(fromBase58String(bR)), (("Asset " + bR) + " doesn't exist")).quantity | |
259 | + | if ((bR != bP)) | |
255 | 260 | then throw("Invalid asset passed.") | |
256 | 261 | else { | |
257 | - | let bV = bp(bR) | |
258 | - | let bW = D(bV, bv) | |
259 | - | let bX = bp(bS) | |
260 | - | let bY = D(bX, bw) | |
261 | - | let bZ = br(bY, bW) | |
262 | - | let ca = G(bZ, b) | |
263 | - | let cb = D(bP, b) | |
264 | - | let cc = D(bU, b) | |
265 | - | let cd = fraction(bW, cb, cc) | |
266 | - | let ce = fraction(bY, cb, cc) | |
267 | - | let cf = G(cd, bv) | |
262 | + | let bW = bq(bS) | |
263 | + | let bX = D(bW, bw) | |
264 | + | let bY = bq(bT) | |
265 | + | let bZ = D(bY, bx) | |
266 | + | let ca = bs(bZ, bX) | |
267 | + | let cb = G(ca, b) | |
268 | + | let cc = D(bQ, b) | |
269 | + | let cd = D(bV, b) | |
270 | + | let ce = fraction(bX, cc, cd) | |
271 | + | let cf = fraction(bZ, cc, cd) | |
268 | 272 | let cg = G(ce, bw) | |
269 | - | let ch = if ((bN == "")) | |
273 | + | let ch = G(cf, bx) | |
274 | + | let ci = if ((bO == "")) | |
270 | 275 | then nil | |
271 | - | else [ScriptTransfer( | |
276 | + | else [ScriptTransfer(X, cg, if ((bS == "WAVES")) | |
272 | 277 | then unit | |
273 | - | else fromBase58String( | |
278 | + | else fromBase58String(bS)), ScriptTransfer(X, ch, if ((bT == "WAVES")) | |
274 | 279 | then unit | |
275 | - | else fromBase58String( | |
276 | - | $Tuple10( | |
280 | + | else fromBase58String(bT)), StringEntry(Z(toString(X), bO), bm(cg, ch, bQ, cb, height, lastBlock.timestamp)), IntegerEntry(S(), cb), IntegerEntry(T(height, lastBlock.timestamp), cb)] | |
281 | + | $Tuple10(cg, ch, bS, bT, bW, bY, bV, ca, bU, ci) | |
277 | 282 | } | |
278 | 283 | } | |
279 | 284 | ||
280 | 285 | ||
281 | - | func | |
282 | - | let | |
283 | - | let | |
284 | - | let | |
285 | - | let | |
286 | - | let | |
287 | - | let | |
288 | - | let | |
289 | - | let | |
290 | - | let | |
291 | - | let | |
292 | - | let | |
293 | - | let | |
294 | - | if (if (( | |
286 | + | func cj (bO,ck,cl,cm,cn,co,X,cp,cq) = { | |
287 | + | let bE = aH() | |
288 | + | let bR = fromBase58String(bE[q]) | |
289 | + | let cr = bE[r] | |
290 | + | let cs = bE[s] | |
291 | + | let ct = bE[v] | |
292 | + | let cu = bE[w] | |
293 | + | let bF = parseIntValue(bE[t]) | |
294 | + | let bG = parseIntValue(bE[u]) | |
295 | + | let bU = bE[p] | |
296 | + | let bV = valueOrErrorMessage(assetInfo(bR), (("Asset " + toBase58String(bR)) + " doesn't exist")).quantity | |
297 | + | let cv = toBase58String(valueOrElse(cm, fromBase58String("WAVES"))) | |
298 | + | let cw = toBase58String(valueOrElse(co, fromBase58String("WAVES"))) | |
299 | + | if (if ((cr != cv)) | |
295 | 300 | then true | |
296 | - | else ( | |
301 | + | else (cs != cw)) | |
297 | 302 | then throw("Invalid amt or price asset passed.") | |
298 | 303 | else { | |
299 | - | let | |
300 | - | then | |
301 | - | else ( | |
302 | - | let | |
303 | - | then | |
304 | - | else ( | |
305 | - | let | |
306 | - | let | |
307 | - | let | |
308 | - | let | |
309 | - | let | |
310 | - | let | |
304 | + | let bW = if (cp) | |
305 | + | then bq(cr) | |
306 | + | else (bq(cr) - cl) | |
307 | + | let bY = if (cp) | |
308 | + | then bq(cs) | |
309 | + | else (bq(cs) - cn) | |
310 | + | let cx = D(cl, bF) | |
311 | + | let cy = D(cn, bG) | |
312 | + | let cz = bs(cy, cx) | |
313 | + | let bX = D(bW, bF) | |
314 | + | let bZ = D(bY, bG) | |
315 | + | let cA = if ((bV == 0)) | |
311 | 316 | then { | |
312 | - | let | |
313 | - | let | |
314 | - | let | |
315 | - | $Tuple5(G( | |
317 | + | let ca = e | |
318 | + | let cB = e | |
319 | + | let bI = pow((cx * cy), 0, toBigInt(5), 1, 0, DOWN) | |
320 | + | $Tuple5(G(bI, b), G(cx, bF), G(cy, bG), bs((bZ + cy), (bX + cx)), cB) | |
316 | 321 | } | |
317 | 322 | else { | |
318 | - | let | |
319 | - | let | |
320 | - | let | |
321 | - | if (if (( | |
322 | - | then ( | |
323 | + | let ca = bs(bZ, bX) | |
324 | + | let cB = fraction(O((ca - cz)), d, ca) | |
325 | + | let cC = D(ck, b) | |
326 | + | if (if ((ca != e)) | |
327 | + | then (cB > cC) | |
323 | 328 | else false) | |
324 | - | then throw(((("Price slippage " + toString( | |
329 | + | then throw(((("Price slippage " + toString(cB)) + " exceeded the passed limit of ") + toString(cC))) | |
325 | 330 | else { | |
326 | - | let | |
327 | - | let | |
328 | - | let | |
329 | - | let | |
330 | - | then $Tuple2( | |
331 | - | else $Tuple2( | |
332 | - | let | |
333 | - | let | |
334 | - | let | |
335 | - | $Tuple5(G( | |
331 | + | let cd = D(bV, b) | |
332 | + | let cD = fraction(cx, ca, d) | |
333 | + | let cE = fraction(cy, d, ca) | |
334 | + | let cF = if ((cD > cy)) | |
335 | + | then $Tuple2(cE, cy) | |
336 | + | else $Tuple2(cx, cD) | |
337 | + | let cG = cF._1 | |
338 | + | let cH = cF._2 | |
339 | + | let bI = fraction(cd, cH, bZ) | |
340 | + | $Tuple5(G(bI, b), G(cG, bF), G(cH, bG), ca, cB) | |
336 | 341 | } | |
337 | 342 | } | |
338 | - | let | |
339 | - | let | |
340 | - | let | |
341 | - | let | |
342 | - | let | |
343 | - | if ((0 >= | |
343 | + | let cI = cA._1 | |
344 | + | let cJ = cA._2 | |
345 | + | let cK = cA._3 | |
346 | + | let cb = G(cA._4, b) | |
347 | + | let cL = G(cA._5, b) | |
348 | + | if ((0 >= cI)) | |
344 | 349 | then throw("Invalid calculations. LP calculated is less than zero.") | |
345 | 350 | else { | |
346 | - | let | |
351 | + | let cM = if (!(cq)) | |
347 | 352 | then 0 | |
348 | - | else | |
349 | - | let | |
350 | - | let | |
351 | - | let | |
352 | - | $Tuple13( | |
353 | + | else cI | |
354 | + | let cN = (cl - cJ) | |
355 | + | let cO = (cn - cK) | |
356 | + | let cP = [IntegerEntry(S(), cb), IntegerEntry(T(height, lastBlock.timestamp), cb), StringEntry(W(X, bO), bb(cJ, cK, cM, cb, ck, cL, height, lastBlock.timestamp, cN, cO))] | |
357 | + | $Tuple13(cI, cM, cb, bW, bY, bV, bR, bU, cP, cN, cO, cm, co) | |
353 | 358 | } | |
354 | 359 | } | |
355 | 360 | } | |
356 | 361 | ||
357 | 362 | ||
358 | - | func | |
359 | - | let | |
360 | - | let | |
361 | - | let | |
362 | - | let | |
363 | - | let | |
364 | - | let | |
365 | - | let | |
366 | - | let | |
367 | - | let | |
368 | - | then | |
369 | - | else | |
370 | - | let | |
371 | - | if (if (if ( | |
363 | + | func cQ (cR) = { | |
364 | + | let bE = aH() | |
365 | + | let cS = bE[r] | |
366 | + | let cT = bE[s] | |
367 | + | let bU = parseIntValue(bE[p]) | |
368 | + | let bF = parseIntValue(bE[t]) | |
369 | + | let bG = parseIntValue(bE[u]) | |
370 | + | let cU = bq(cS) | |
371 | + | let cV = bq(cT) | |
372 | + | let ca = if ((cR.orderType == Buy)) | |
373 | + | then bv(bF, bG, (cU + cR.amount), cV) | |
374 | + | else bv(bF, bG, (cU - cR.amount), cV) | |
375 | + | let cb = G(ca, b) | |
376 | + | if (if (if (aF()) | |
372 | 377 | then true | |
373 | - | else ( | |
378 | + | else (bU == m)) | |
374 | 379 | then true | |
375 | - | else ( | |
380 | + | else (bU == n)) | |
376 | 381 | then throw("Exchange operations disabled") | |
377 | 382 | else { | |
378 | - | let | |
379 | - | let | |
383 | + | let cW = cR.assetPair.amountAsset | |
384 | + | let cX = if ((cW == unit)) | |
380 | 385 | then "WAVES" | |
381 | - | else toBase58String(value( | |
382 | - | let | |
383 | - | let | |
386 | + | else toBase58String(value(cW)) | |
387 | + | let cY = cR.assetPair.priceAsset | |
388 | + | let cZ = if ((cY == unit)) | |
384 | 389 | then "WAVES" | |
385 | - | else toBase58String(value( | |
386 | - | if (if (( | |
390 | + | else toBase58String(value(cY)) | |
391 | + | if (if ((cX != cS)) | |
387 | 392 | then true | |
388 | - | else ( | |
393 | + | else (cZ != cT)) | |
389 | 394 | then throw("Wrong order assets.") | |
390 | 395 | else { | |
391 | - | let | |
392 | - | let | |
393 | - | let | |
394 | - | let | |
395 | - | then ( | |
396 | - | else ( | |
396 | + | let da = cR.price | |
397 | + | let db = fraction(b, bG, bF) | |
398 | + | let dc = J(da, b, db) | |
399 | + | let dd = if ((cR.orderType == Buy)) | |
400 | + | then (cb >= dc) | |
401 | + | else (dc >= cb) | |
397 | 402 | true | |
398 | 403 | } | |
399 | 404 | } | |
400 | 405 | } | |
401 | 406 | ||
402 | 407 | ||
403 | - | func | |
408 | + | func de (df) = if ((size(df.payments) != 1)) | |
404 | 409 | then throw("exactly 1 payment is expected") | |
405 | 410 | else { | |
406 | - | let | |
407 | - | let | |
408 | - | let | |
409 | - | let | |
410 | - | let | |
411 | - | let | |
412 | - | let | |
413 | - | let | |
414 | - | if (if ( | |
411 | + | let dg = value(df.payments[0]) | |
412 | + | let bP = value(dg.assetId) | |
413 | + | let dh = dg.amount | |
414 | + | let cA = bN(toBase58String(df.transactionId), toBase58String(bP), dh, df.caller) | |
415 | + | let cg = cA._1 | |
416 | + | let ch = cA._2 | |
417 | + | let bU = parseIntValue(cA._9) | |
418 | + | let ci = cA._10 | |
419 | + | if (if (aF()) | |
415 | 420 | then true | |
416 | - | else ( | |
417 | - | then throw(("Get operation is blocked by admin. Status = " + toString( | |
418 | - | else $Tuple5( | |
421 | + | else (bU == n)) | |
422 | + | then throw(("Get operation is blocked by admin. Status = " + toString(bU))) | |
423 | + | else $Tuple5(cg, ch, dh, bP, ci) | |
419 | 424 | } | |
420 | 425 | ||
421 | 426 | ||
422 | - | func | |
427 | + | func di (df,ck,cq) = if ((size(df.payments) != 2)) | |
423 | 428 | then throw("exactly 2 payments are expected") | |
424 | 429 | else { | |
425 | - | let | |
426 | - | let | |
427 | - | let | |
428 | - | let | |
429 | - | if (if (if ( | |
430 | + | let dj = value(df.payments[0]) | |
431 | + | let dk = value(df.payments[1]) | |
432 | + | let dl = cj(toBase58String(df.transactionId), ck, dj.amount, dj.assetId, dk.amount, dk.assetId, toString(df.caller), false, cq) | |
433 | + | let bU = parseIntValue(dl._8) | |
434 | + | if (if (if (aF()) | |
430 | 435 | then true | |
431 | - | else ( | |
436 | + | else (bU == l)) | |
432 | 437 | then true | |
433 | - | else ( | |
434 | - | then throw(("Put operation is blocked by admin. Status = " + toString( | |
435 | - | else | |
438 | + | else (bU == n)) | |
439 | + | then throw(("Put operation is blocked by admin. Status = " + toString(bU))) | |
440 | + | else dl | |
436 | 441 | } | |
437 | 442 | ||
438 | 443 | ||
439 | - | func | |
440 | - | let | |
441 | - | if (( | |
444 | + | func dm (dn) = { | |
445 | + | let do = invoke(aD, "emit", [dn], nil) | |
446 | + | if ((do == do)) | |
442 | 447 | then { | |
443 | - | let | |
444 | - | let | |
445 | - | if ($isInstanceOf( | |
448 | + | let dp = { | |
449 | + | let dq = do | |
450 | + | if ($isInstanceOf(dq, "Address")) | |
446 | 451 | then { | |
447 | - | let | |
448 | - | invoke( | |
452 | + | let dr = dq | |
453 | + | invoke(dr, "emit", [dn], nil) | |
449 | 454 | } | |
450 | 455 | else unit | |
451 | 456 | } | |
452 | - | if (( | |
453 | - | then | |
457 | + | if ((dp == dp)) | |
458 | + | then dn | |
454 | 459 | else throw("Strict value is not equal to itself.") | |
455 | 460 | } | |
456 | 461 | else throw("Strict value is not equal to itself.") | |
457 | 462 | } | |
458 | 463 | ||
459 | 464 | ||
460 | - | func | |
461 | - | let | |
462 | - | $Tuple2(( | |
465 | + | func ds (dn) = { | |
466 | + | let dt = fraction(dn, ae, b) | |
467 | + | $Tuple2((dn - dt), dt) | |
463 | 468 | } | |
464 | 469 | ||
465 | 470 | ||
466 | - | func | |
467 | - | let | |
468 | - | let | |
469 | - | let | |
470 | - | let | |
471 | - | let | |
472 | - | let | |
473 | - | let | |
474 | - | let | |
475 | - | let | |
476 | - | let | |
477 | - | let | |
478 | - | let | |
471 | + | func du (dv,dw,X,Y) = { | |
472 | + | let dx = (Y == unit) | |
473 | + | let dy = aN(aH()) | |
474 | + | let dz = dy._1 | |
475 | + | let bU = dy._2 | |
476 | + | let bR = dy._3 | |
477 | + | let dA = dy._4 | |
478 | + | let cT = dy._5 | |
479 | + | let dB = dy._6 | |
480 | + | let dC = dy._7 | |
481 | + | let dD = bq(aM(dA)) | |
482 | + | let dE = bq(aM(cT)) | |
483 | + | let dF = if ((dw == dA)) | |
479 | 484 | then true | |
480 | - | else if (( | |
485 | + | else if ((dw == cT)) | |
481 | 486 | then false | |
482 | - | else aA("invalid asset") | |
483 | - | let dF = if (dw) | |
484 | - | then $Tuple2(dC, dD) | |
485 | - | else if (dE) | |
486 | - | then $Tuple2((dC - du), dD) | |
487 | - | else $Tuple2(dC, (dD - du)) | |
488 | - | let dG = dF._1 | |
489 | - | let dH = dF._2 | |
490 | - | let dI = if (dE) | |
491 | - | then $Tuple2(du, 0) | |
492 | - | else $Tuple2(0, du) | |
493 | - | let dJ = dI._1 | |
494 | - | let dK = dI._2 | |
495 | - | let dL = dr(dJ)._1 | |
496 | - | let dM = dr(dK)._1 | |
497 | - | let dN = dr(du) | |
498 | - | let dO = dN._1 | |
499 | - | let ds = dN._2 | |
500 | - | let dP = (dG + dL) | |
487 | + | else aB("invalid asset") | |
488 | + | let dG = if (dx) | |
489 | + | then $Tuple2(dD, dE) | |
490 | + | else if (dF) | |
491 | + | then $Tuple2((dD - dv), dE) | |
492 | + | else $Tuple2(dD, (dE - dv)) | |
493 | + | let dH = dG._1 | |
494 | + | let dI = dG._2 | |
495 | + | let dJ = if (dF) | |
496 | + | then $Tuple2(dv, 0) | |
497 | + | else $Tuple2(0, dv) | |
498 | + | let dK = dJ._1 | |
499 | + | let dL = dJ._2 | |
500 | + | let dM = ds(dK)._1 | |
501 | + | let dN = ds(dL)._1 | |
502 | + | let dO = ds(dv) | |
503 | + | let dP = dO._1 | |
504 | + | let dt = dO._2 | |
501 | 505 | let dQ = (dH + dM) | |
502 | - | let ca = G(br(D(dQ, dB), D(dP, dA)), b) | |
503 | - | let dR = if (dE) | |
504 | - | then dG | |
505 | - | else dH | |
506 | - | let dS = toBigInt(dR) | |
507 | - | let dT = toBigInt(valueOrErrorMessage(assetInfo(bQ), (("asset " + toBase58String(bQ)) + " doesn't exist")).quantity) | |
508 | - | let dU = if ((dT > f)) | |
506 | + | let dR = (dI + dN) | |
507 | + | let dS = bs(D(dR, dC), D(dQ, dB)) | |
508 | + | let dT = G(dS, b) | |
509 | + | let dU = if (dF) | |
510 | + | then dH | |
511 | + | else dI | |
512 | + | let dV = toBigInt(dU) | |
513 | + | let dW = toBigInt(valueOrErrorMessage(assetInfo(bR), (("asset " + toBase58String(bR)) + " doesn't exist")).quantity) | |
514 | + | let dX = if ((dW > f)) | |
509 | 515 | then true | |
510 | - | else | |
511 | - | if (( | |
516 | + | else aB("initial deposit requires all coins") | |
517 | + | if ((dX == dX)) | |
512 | 518 | then { | |
513 | - | let | |
514 | - | let | |
515 | - | let | |
519 | + | let dY = toBigInt(dP) | |
520 | + | let dZ = max([0, toInt(((dW * (sqrtBigInt((d + ((dY * d) / dV)), 18, 18, DOWN) - d)) / d))]) | |
521 | + | let cP = if (dx) | |
516 | 522 | then nil | |
517 | - | else [IntegerEntry(R(), ca), IntegerEntry(S(height, lastBlock.timestamp), ca), StringEntry(V(toString(value(W)), toBase58String(value(X))), ba(dJ, dK, dW, ca, 0, 0, height, lastBlock.timestamp, 0, 0))] | |
518 | - | let dX = fraction(dH, b, dG) | |
519 | - | let dY = fraction(du, b, (dX + b)) | |
520 | - | let dZ = (du - dY) | |
521 | - | let ea = toInt(fraction(dT, toBigInt(dZ), toBigInt(dH))) | |
522 | - | let eb = if ((ea == 0)) | |
523 | - | then if ((dW == 0)) | |
524 | - | then 0 | |
525 | - | else aA("bonus calculation error") | |
526 | - | else fraction((dW - ea), b, ea) | |
527 | - | $Tuple4(dW, cO, ds, eb) | |
523 | + | else [IntegerEntry(S(), dT), IntegerEntry(T(height, lastBlock.timestamp), dT), StringEntry(W(toString(value(X)), toBase58String(value(Y))), bb(dK, dL, dZ, dT, 0, 0, height, lastBlock.timestamp, 0, 0))] | |
524 | + | let ea = bs(D(dI, dC), D(dH, dB)) | |
525 | + | let eb = G(ea, b) | |
526 | + | let ec = N((((dT - eb) * b) / eb)) | |
527 | + | $Tuple4(dZ, cP, dt, ec) | |
528 | 528 | } | |
529 | 529 | else throw("Strict value is not equal to itself.") | |
530 | 530 | } | |
531 | 531 | ||
532 | 532 | ||
533 | - | func | |
534 | - | let | |
535 | - | let | |
536 | - | let | |
537 | - | let | |
538 | - | let | |
539 | - | let | |
540 | - | let | |
541 | - | let | |
542 | - | let | |
543 | - | let | |
533 | + | func ed (ee,dP,dw,X,Y) = { | |
534 | + | let dx = (Y == unit) | |
535 | + | let ef = aN(aH()) | |
536 | + | let dz = ef._1 | |
537 | + | let bU = ef._2 | |
538 | + | let bR = ef._3 | |
539 | + | let dA = ef._4 | |
540 | + | let cT = ef._5 | |
541 | + | let eg = ef._6 | |
542 | + | let eh = ef._7 | |
543 | + | let ei = [if ((dw == bR)) | |
544 | 544 | then true | |
545 | - | else | |
546 | - | if (( | |
545 | + | else aB("invalid lp asset")] | |
546 | + | if ((ei == ei)) | |
547 | 547 | then { | |
548 | - | let | |
548 | + | let ej = if ((ee == dA)) | |
549 | 549 | then true | |
550 | - | else if (( | |
550 | + | else if ((ee == cT)) | |
551 | 551 | then false | |
552 | - | else | |
553 | - | let | |
554 | - | then toBigInt( | |
555 | - | else toBigInt( | |
556 | - | let | |
557 | - | let | |
558 | - | let | |
559 | - | then | |
560 | - | else | |
561 | - | let | |
562 | - | let | |
563 | - | let | |
564 | - | let | |
565 | - | let | |
566 | - | let | |
567 | - | let | |
568 | - | let | |
569 | - | then $Tuple4( | |
570 | - | else $Tuple4(0, | |
571 | - | let | |
572 | - | let | |
573 | - | let | |
574 | - | let | |
575 | - | let | |
576 | - | let | |
577 | - | let | |
552 | + | else aB("invalid asset") | |
553 | + | let ek = if (ej) | |
554 | + | then toBigInt(bq(aM(dA))) | |
555 | + | else toBigInt(bq(aM(cT))) | |
556 | + | let el = bq(aM(dA)) | |
557 | + | let em = bq(aM(cT)) | |
558 | + | let en = if (ej) | |
559 | + | then el | |
560 | + | else em | |
561 | + | let eo = toBigInt(en) | |
562 | + | let dW = toBigInt(valueOrErrorMessage(assetInfo(bR), (("asset " + toBase58String(bR)) + " doesn't exist")).quantity) | |
563 | + | let ep = toBigInt(dP) | |
564 | + | let eq = max([0, toInt(((ek * (d - pow((d - ((ep * d) / dW)), 18, h, 0, 18, DOWN))) / d))]) | |
565 | + | let er = ds(eq) | |
566 | + | let es = er._1 | |
567 | + | let dt = er._2 | |
568 | + | let et = if (ej) | |
569 | + | then $Tuple4(es, 0, (el - eq), em) | |
570 | + | else $Tuple4(0, es, el, (em - eq)) | |
571 | + | let eu = et._1 | |
572 | + | let ev = et._2 | |
573 | + | let ew = et._3 | |
574 | + | let ex = et._4 | |
575 | + | let dS = bs(D(ex, eh), D(ew, eg)) | |
576 | + | let dT = G(dS, b) | |
577 | + | let cP = if (dx) | |
578 | 578 | then nil | |
579 | - | else [StringEntry(Y(toString(value(W)), toBase58String(value(X))), bl(et, eu, dO, ca, height, lastBlock.timestamp)), IntegerEntry(R(), ca), IntegerEntry(S(height, lastBlock.timestamp), ca)] | |
580 | - | let ey = bM("", aL(bQ), dO, this) | |
581 | - | let ez = (ey._1 + ey._2) | |
582 | - | let eb = if ((ez == 0)) | |
583 | - | then if ((er == 0)) | |
584 | - | then 0 | |
585 | - | else aA("bonus calculation error") | |
586 | - | else fraction((er - ez), b, ez) | |
587 | - | $Tuple4(er, cO, ds, eb) | |
579 | + | else [StringEntry(Z(toString(value(X)), toBase58String(value(Y))), bm(eu, ev, dP, dT, height, lastBlock.timestamp)), IntegerEntry(S(), dT), IntegerEntry(T(height, lastBlock.timestamp), dT)] | |
580 | + | let ea = bs(D(em, eh), D(el, eg)) | |
581 | + | let eb = G(ea, b) | |
582 | + | let ec = N((((dT - eb) * b) / eb)) | |
583 | + | $Tuple4(es, cP, dt, ec) | |
588 | 584 | } | |
589 | 585 | else throw("Strict value is not equal to itself.") | |
590 | 586 | } | |
591 | 587 | ||
592 | 588 | ||
593 | - | func | |
594 | - | let | |
595 | - | if ($isInstanceOf( | |
589 | + | func ey () = { | |
590 | + | let dq = getString(Q()) | |
591 | + | if ($isInstanceOf(dq, "String")) | |
596 | 592 | then { | |
597 | - | let | |
598 | - | fromBase58String( | |
593 | + | let ez = dq | |
594 | + | fromBase58String(ez) | |
599 | 595 | } | |
600 | - | else if ($isInstanceOf( | |
596 | + | else if ($isInstanceOf(dq, "Unit")) | |
601 | 597 | then unit | |
602 | 598 | else throw("Match error") | |
603 | 599 | } | |
604 | 600 | ||
605 | 601 | ||
606 | - | func | |
607 | - | let | |
608 | - | if ($isInstanceOf( | |
602 | + | func eA () = { | |
603 | + | let dq = getString(R()) | |
604 | + | if ($isInstanceOf(dq, "String")) | |
609 | 605 | then { | |
610 | - | let | |
611 | - | fromBase58String( | |
606 | + | let ez = dq | |
607 | + | fromBase58String(ez) | |
612 | 608 | } | |
613 | - | else if ($isInstanceOf( | |
609 | + | else if ($isInstanceOf(dq, "Unit")) | |
614 | 610 | then unit | |
615 | 611 | else throw("Match error") | |
616 | 612 | } | |
617 | 613 | ||
618 | 614 | ||
619 | - | func | |
620 | - | let | |
621 | - | let | |
622 | - | if ($isInstanceOf( | |
615 | + | func eB (df) = { | |
616 | + | let eC = throw("Permission denied") | |
617 | + | let dq = ey() | |
618 | + | if ($isInstanceOf(dq, "ByteVector")) | |
623 | 619 | then { | |
624 | - | let | |
625 | - | if (( | |
620 | + | let eD = dq | |
621 | + | if ((df.callerPublicKey == eD)) | |
626 | 622 | then true | |
627 | - | else | |
623 | + | else eC | |
628 | 624 | } | |
629 | - | else if ($isInstanceOf( | |
630 | - | then if (( | |
625 | + | else if ($isInstanceOf(dq, "Unit")) | |
626 | + | then if ((df.caller == this)) | |
631 | 627 | then true | |
632 | - | else | |
628 | + | else eC | |
633 | 629 | else throw("Match error") | |
634 | 630 | } | |
635 | 631 | ||
636 | 632 | ||
637 | - | @Callable( | |
638 | - | func setManager ( | |
639 | - | let | |
640 | - | if (( | |
633 | + | @Callable(df) | |
634 | + | func setManager (eE) = { | |
635 | + | let eF = eB(df) | |
636 | + | if ((eF == eF)) | |
641 | 637 | then { | |
642 | - | let | |
643 | - | if (( | |
644 | - | then [StringEntry( | |
638 | + | let eG = fromBase58String(eE) | |
639 | + | if ((eG == eG)) | |
640 | + | then [StringEntry(R(), eE)] | |
645 | 641 | else throw("Strict value is not equal to itself.") | |
646 | 642 | } | |
647 | 643 | else throw("Strict value is not equal to itself.") | |
649 | 645 | ||
650 | 646 | ||
651 | 647 | ||
652 | - | @Callable( | |
648 | + | @Callable(df) | |
653 | 649 | func confirmManager () = { | |
654 | - | let | |
655 | - | let | |
650 | + | let eH = eA() | |
651 | + | let eI = if (isDefined(eH)) | |
656 | 652 | then true | |
657 | 653 | else throw("No pending manager") | |
658 | - | if (( | |
654 | + | if ((eI == eI)) | |
659 | 655 | then { | |
660 | - | let | |
656 | + | let eJ = if ((df.callerPublicKey == value(eH))) | |
661 | 657 | then true | |
662 | 658 | else throw("You are not pending manager") | |
663 | - | if (( | |
664 | - | then [StringEntry( | |
659 | + | if ((eJ == eJ)) | |
660 | + | then [StringEntry(Q(), toBase58String(value(eH))), DeleteEntry(R())] | |
665 | 661 | else throw("Strict value is not equal to itself.") | |
666 | 662 | } | |
667 | 663 | else throw("Strict value is not equal to itself.") | |
669 | 665 | ||
670 | 666 | ||
671 | 667 | ||
672 | - | @Callable( | |
673 | - | func put ( | |
668 | + | @Callable(df) | |
669 | + | func put (ck,eK) = if ((0 > ck)) | |
674 | 670 | then throw("Invalid slippageTolerance passed") | |
675 | 671 | else { | |
676 | - | let | |
677 | - | let | |
678 | - | let | |
679 | - | let | |
680 | - | let | |
681 | - | let | |
682 | - | let | |
683 | - | let | |
684 | - | let | |
685 | - | if (( | |
672 | + | let dl = di(df, ck, true) | |
673 | + | let cM = dl._2 | |
674 | + | let bR = dl._7 | |
675 | + | let ci = dl._9 | |
676 | + | let cN = dl._10 | |
677 | + | let cO = dl._11 | |
678 | + | let eL = dl._12 | |
679 | + | let eM = dl._13 | |
680 | + | let do = invoke(aD, "emit", [cM], nil) | |
681 | + | if ((do == do)) | |
686 | 682 | then { | |
687 | - | let | |
688 | - | let | |
689 | - | if ($isInstanceOf( | |
683 | + | let dp = { | |
684 | + | let dq = do | |
685 | + | if ($isInstanceOf(dq, "Address")) | |
690 | 686 | then { | |
691 | - | let | |
692 | - | invoke( | |
687 | + | let dr = dq | |
688 | + | invoke(dr, "emit", [cM], nil) | |
693 | 689 | } | |
694 | 690 | else unit | |
695 | 691 | } | |
696 | - | if (( | |
692 | + | if ((dp == dp)) | |
697 | 693 | then { | |
698 | - | let | |
699 | - | then invoke( | |
694 | + | let eN = if ((cN > 0)) | |
695 | + | then invoke(ba, "put", nil, [AttachedPayment(eL, cN)]) | |
700 | 696 | else nil | |
701 | - | if (( | |
697 | + | if ((eN == eN)) | |
702 | 698 | then { | |
703 | - | let | |
704 | - | then invoke( | |
699 | + | let eO = if ((cO > 0)) | |
700 | + | then invoke(ba, "put", nil, [AttachedPayment(eM, cO)]) | |
705 | 701 | else nil | |
706 | - | if (( | |
702 | + | if ((eO == eO)) | |
707 | 703 | then { | |
708 | - | let | |
704 | + | let eP = if (eK) | |
709 | 705 | then { | |
710 | - | let | |
711 | - | if (( | |
706 | + | let eQ = invoke(aZ, "stake", nil, [AttachedPayment(bR, cM)]) | |
707 | + | if ((eQ == eQ)) | |
712 | 708 | then nil | |
713 | 709 | else throw("Strict value is not equal to itself.") | |
714 | 710 | } | |
715 | - | else [ScriptTransfer( | |
716 | - | ( | |
711 | + | else [ScriptTransfer(df.caller, cM, bR)] | |
712 | + | (ci ++ eP) | |
717 | 713 | } | |
718 | 714 | else throw("Strict value is not equal to itself.") | |
719 | 715 | } | |
726 | 722 | ||
727 | 723 | ||
728 | 724 | ||
729 | - | @Callable( | |
730 | - | func putForFree ( | |
725 | + | @Callable(df) | |
726 | + | func putForFree (eR) = if ((0 > eR)) | |
731 | 727 | then throw("Invalid value passed") | |
732 | 728 | else { | |
733 | - | let | |
734 | - | | |
729 | + | let dl = di(df, eR, false) | |
730 | + | dl._9 | |
735 | 731 | } | |
736 | 732 | ||
737 | 733 | ||
738 | 734 | ||
739 | - | @Callable( | |
740 | - | func putOneTkn ( | |
741 | - | let | |
735 | + | @Callable(df) | |
736 | + | func putOneTkn (eS,eT) = { | |
737 | + | let eU = if (if (aF()) | |
742 | 738 | then true | |
743 | - | else ( | |
739 | + | else (aS == l)) | |
744 | 740 | then true | |
745 | - | else ( | |
746 | - | let | |
741 | + | else (aS == n) | |
742 | + | let ei = [if (!(eU)) | |
747 | 743 | then true | |
748 | - | else | |
744 | + | else aB("put operation is blocked by admin"), if ((size(df.payments) == 1)) | |
749 | 745 | then true | |
750 | - | else | |
751 | - | if (( | |
746 | + | else aB("exactly 1 payment are expected")] | |
747 | + | if ((ei == ei)) | |
752 | 748 | then { | |
753 | - | let | |
754 | - | let | |
755 | - | let | |
756 | - | let | |
757 | - | let | |
758 | - | let | |
759 | - | let | |
760 | - | let | |
761 | - | let | |
762 | - | let | |
763 | - | let | |
764 | - | then ( | |
749 | + | let eV = df.payments[0] | |
750 | + | let dw = eV.assetId | |
751 | + | let dv = eV.amount | |
752 | + | let X = df.caller | |
753 | + | let Y = df.transactionId | |
754 | + | let eW = du(dv, dw, X, Y) | |
755 | + | let eX = eW._1 | |
756 | + | let cP = eW._2 | |
757 | + | let dt = eW._3 | |
758 | + | let eY = eW._4 | |
759 | + | let eZ = if (if ((eS > 0)) | |
760 | + | then (eS > eX) | |
765 | 761 | else false) | |
766 | - | then | |
767 | - | else | |
768 | - | let | |
769 | - | if (( | |
762 | + | then aB(makeString(["amount to receive is less than ", toString(eS)], "")) | |
763 | + | else eX | |
764 | + | let do = dm(eZ) | |
765 | + | if ((do == do)) | |
770 | 766 | then { | |
771 | - | let | |
767 | + | let eP = if (eT) | |
772 | 768 | then { | |
773 | - | let | |
774 | - | if (( | |
769 | + | let fa = invoke(aZ, "stake", nil, [AttachedPayment(aT, eZ)]) | |
770 | + | if ((fa == fa)) | |
775 | 771 | then nil | |
776 | 772 | else throw("Strict value is not equal to itself.") | |
777 | 773 | } | |
778 | - | else [ScriptTransfer( | |
779 | - | let | |
780 | - | then [ScriptTransfer( | |
774 | + | else [ScriptTransfer(df.caller, eZ, aT)] | |
775 | + | let fb = if ((dt > 0)) | |
776 | + | then [ScriptTransfer(aE, dt, dw)] | |
781 | 777 | else nil | |
782 | - | $Tuple2((( | |
778 | + | $Tuple2(((cP ++ eP) ++ fb), eZ) | |
783 | 779 | } | |
784 | 780 | else throw("Strict value is not equal to itself.") | |
785 | 781 | } | |
788 | 784 | ||
789 | 785 | ||
790 | 786 | ||
791 | - | @Callable( | |
792 | - | func putOneTknREADONLY (dv | |
793 | - | let | |
794 | - | let | |
795 | - | let | |
796 | - | let | |
797 | - | let | |
798 | - | $Tuple2(nil, $Tuple3( | |
787 | + | @Callable(df) | |
788 | + | func putOneTknREADONLY (dw,dv) = { | |
789 | + | let fc = du(dv, aK(dw), unit, unit) | |
790 | + | let eX = fc._1 | |
791 | + | let cP = fc._2 | |
792 | + | let dt = fc._3 | |
793 | + | let eY = fc._4 | |
794 | + | $Tuple2(nil, $Tuple3(eX, dt, eY)) | |
799 | 795 | } | |
800 | 796 | ||
801 | 797 | ||
802 | 798 | ||
803 | - | @Callable( | |
804 | - | func getOneTkn ( | |
805 | - | let | |
799 | + | @Callable(df) | |
800 | + | func getOneTkn (fd,eS) = { | |
801 | + | let fe = if (aF()) | |
806 | 802 | then true | |
807 | - | else ( | |
808 | - | let | |
803 | + | else (aS == n) | |
804 | + | let ei = [if (!(fe)) | |
809 | 805 | then true | |
810 | - | else | |
806 | + | else aB("get operation is blocked by admin"), if ((size(df.payments) == 1)) | |
811 | 807 | then true | |
812 | - | else | |
813 | - | if (( | |
808 | + | else aB("exactly 1 payment are expected")] | |
809 | + | if ((ei == ei)) | |
814 | 810 | then { | |
815 | - | let | |
816 | - | let | |
817 | - | let | |
818 | - | let | |
819 | - | let | |
820 | - | let | |
821 | - | let | |
822 | - | let | |
823 | - | let | |
824 | - | let | |
825 | - | let | |
826 | - | let | |
827 | - | then ( | |
811 | + | let ee = aK(fd) | |
812 | + | let eV = df.payments[0] | |
813 | + | let dw = eV.assetId | |
814 | + | let dP = eV.amount | |
815 | + | let X = df.caller | |
816 | + | let Y = df.transactionId | |
817 | + | let ff = ed(ee, dP, dw, X, Y) | |
818 | + | let fg = ff._1 | |
819 | + | let cP = ff._2 | |
820 | + | let dt = ff._3 | |
821 | + | let eY = ff._4 | |
822 | + | let dn = if (if ((eS > 0)) | |
823 | + | then (eS > fg) | |
828 | 824 | else false) | |
829 | - | then | |
830 | - | else | |
831 | - | let | |
832 | - | if (( | |
825 | + | then aB(makeString(["amount to receive is less than ", toString(eS)], "")) | |
826 | + | else fg | |
827 | + | let fh = invoke(aD, "burn", [dP], [AttachedPayment(dw, dP)]) | |
828 | + | if ((fh == fh)) | |
833 | 829 | then { | |
834 | - | let | |
835 | - | let | |
836 | - | then [ScriptTransfer( | |
830 | + | let fi = [ScriptTransfer(X, dn, ee)] | |
831 | + | let fb = if ((dt > 0)) | |
832 | + | then [ScriptTransfer(aE, dt, ee)] | |
837 | 833 | else nil | |
838 | - | $Tuple2((( | |
834 | + | $Tuple2(((cP ++ fi) ++ fb), dn) | |
839 | 835 | } | |
840 | 836 | else throw("Strict value is not equal to itself.") | |
841 | 837 | } | |
844 | 840 | ||
845 | 841 | ||
846 | 842 | ||
847 | - | @Callable( | |
848 | - | func getOneTknREADONLY ( | |
849 | - | let | |
850 | - | let | |
851 | - | let | |
852 | - | let | |
853 | - | let | |
854 | - | $Tuple2(nil, $Tuple3( | |
843 | + | @Callable(df) | |
844 | + | func getOneTknREADONLY (ee,dP) = { | |
845 | + | let fj = ed(aK(ee), dP, aT, unit, unit) | |
846 | + | let fg = fj._1 | |
847 | + | let cP = fj._2 | |
848 | + | let dt = fj._3 | |
849 | + | let eY = fj._4 | |
850 | + | $Tuple2(nil, $Tuple3(fg, dt, eY)) | |
855 | 851 | } | |
856 | 852 | ||
857 | 853 | ||
858 | 854 | ||
859 | - | @Callable( | |
860 | - | func unstakeAndGetOneTkn ( | |
861 | - | let | |
855 | + | @Callable(df) | |
856 | + | func unstakeAndGetOneTkn (fk,fd,eS) = { | |
857 | + | let fe = if (aF()) | |
862 | 858 | then true | |
863 | - | else ( | |
864 | - | let | |
859 | + | else (aS == n) | |
860 | + | let ei = [if (!(fe)) | |
865 | 861 | then true | |
866 | - | else | |
862 | + | else aB("get operation is blocked by admin"), if ((size(df.payments) == 0)) | |
867 | 863 | then true | |
868 | - | else | |
869 | - | if (( | |
864 | + | else aB("no payments are expected")] | |
865 | + | if ((ei == ei)) | |
870 | 866 | then { | |
871 | - | let | |
872 | - | let | |
873 | - | if (( | |
867 | + | let ee = aK(fd) | |
868 | + | let fl = invoke(aZ, "unstake", [toBase58String(aT), fk], nil) | |
869 | + | if ((fl == fl)) | |
874 | 870 | then { | |
875 | - | let | |
876 | - | let | |
877 | - | let | |
878 | - | let | |
879 | - | let | |
880 | - | let | |
881 | - | then ( | |
871 | + | let fm = ed(ee, fk, aT, unit, unit) | |
872 | + | let fg = fm._1 | |
873 | + | let cP = fm._2 | |
874 | + | let dt = fm._3 | |
875 | + | let eY = fm._4 | |
876 | + | let dn = if (if ((eS > 0)) | |
877 | + | then (eS > fg) | |
882 | 878 | else false) | |
883 | - | then | |
884 | - | else | |
885 | - | let | |
886 | - | if (( | |
879 | + | then aB(makeString(["amount to receive is less than ", toString(eS)], "")) | |
880 | + | else fg | |
881 | + | let fh = invoke(aD, "burn", [fk], [AttachedPayment(aT, fk)]) | |
882 | + | if ((fh == fh)) | |
887 | 883 | then { | |
888 | - | let | |
889 | - | let | |
890 | - | then [ScriptTransfer( | |
884 | + | let fi = [ScriptTransfer(df.caller, dn, ee)] | |
885 | + | let fb = if ((dt > 0)) | |
886 | + | then [ScriptTransfer(aE, dt, ee)] | |
891 | 887 | else nil | |
892 | - | $Tuple2((( | |
888 | + | $Tuple2(((cP ++ fi) ++ fb), dn) | |
893 | 889 | } | |
894 | 890 | else throw("Strict value is not equal to itself.") | |
895 | 891 | } | |
900 | 896 | ||
901 | 897 | ||
902 | 898 | ||
903 | - | @Callable( | |
899 | + | @Callable(df) | |
904 | 900 | func get () = { | |
905 | - | let | |
906 | - | let | |
907 | - | let | |
908 | - | let | |
909 | - | let | |
910 | - | let | |
911 | - | let | |
912 | - | if (( | |
913 | - | then | |
901 | + | let cA = de(df) | |
902 | + | let fn = cA._1 | |
903 | + | let ch = cA._2 | |
904 | + | let dh = cA._3 | |
905 | + | let bP = cA._4 | |
906 | + | let ci = cA._5 | |
907 | + | let fo = invoke(aD, "burn", [dh], [AttachedPayment(bP, dh)]) | |
908 | + | if ((fo == fo)) | |
909 | + | then ci | |
914 | 910 | else throw("Strict value is not equal to itself.") | |
915 | 911 | } | |
916 | 912 | ||
917 | 913 | ||
918 | 914 | ||
919 | - | @Callable( | |
920 | - | func getNoLess (fq | |
921 | - | let | |
922 | - | let | |
923 | - | let | |
924 | - | let | |
925 | - | let | |
926 | - | let | |
927 | - | if (( | |
928 | - | then throw(((("noLessThenAmtAsset failed: " + toString( | |
929 | - | else if (( | |
930 | - | then throw(((("noLessThenPriceAsset failed: " + toString( | |
915 | + | @Callable(df) | |
916 | + | func getNoLess (fp,fq) = { | |
917 | + | let cA = de(df) | |
918 | + | let cg = cA._1 | |
919 | + | let ch = cA._2 | |
920 | + | let dh = cA._3 | |
921 | + | let bP = cA._4 | |
922 | + | let ci = cA._5 | |
923 | + | if ((fp > cg)) | |
924 | + | then throw(((("noLessThenAmtAsset failed: " + toString(cg)) + " < ") + toString(fp))) | |
925 | + | else if ((fq > ch)) | |
926 | + | then throw(((("noLessThenPriceAsset failed: " + toString(ch)) + " < ") + toString(fq))) | |
931 | 927 | else { | |
932 | - | let | |
933 | - | if (( | |
934 | - | then | |
928 | + | let fo = invoke(aD, "burn", [dh], [AttachedPayment(bP, dh)]) | |
929 | + | if ((fo == fo)) | |
930 | + | then ci | |
935 | 931 | else throw("Strict value is not equal to itself.") | |
936 | 932 | } | |
937 | 933 | } | |
938 | 934 | ||
939 | 935 | ||
940 | 936 | ||
941 | - | @Callable( | |
942 | - | func unstakeAndGet ( | |
943 | - | let | |
937 | + | @Callable(df) | |
938 | + | func unstakeAndGet (dn) = { | |
939 | + | let fr = if ((size(df.payments) != 0)) | |
944 | 940 | then throw("No payments are expected") | |
945 | 941 | else true | |
946 | - | if (( | |
942 | + | if ((fr == fr)) | |
947 | 943 | then { | |
948 | - | let | |
949 | - | let | |
950 | - | let | |
951 | - | if (( | |
944 | + | let bE = aH() | |
945 | + | let bR = fromBase58String(bE[q]) | |
946 | + | let fl = invoke(aZ, "unstake", [toBase58String(bR), dn], nil) | |
947 | + | if ((fl == fl)) | |
952 | 948 | then { | |
953 | - | let | |
954 | - | let | |
955 | - | let | |
956 | - | let | |
949 | + | let cA = bN(toBase58String(df.transactionId), toBase58String(bR), dn, df.caller) | |
950 | + | let bU = parseIntValue(cA._9) | |
951 | + | let ci = cA._10 | |
952 | + | let fs = if (if (aF()) | |
957 | 953 | then true | |
958 | - | else ( | |
959 | - | then throw(("Get operation is blocked by admin. Status = " + toString( | |
954 | + | else (bU == n)) | |
955 | + | then throw(("Get operation is blocked by admin. Status = " + toString(bU))) | |
960 | 956 | else true | |
961 | - | if (( | |
957 | + | if ((fs == fs)) | |
962 | 958 | then { | |
963 | - | let | |
964 | - | if (( | |
965 | - | then | |
959 | + | let fo = invoke(aD, "burn", [dn], [AttachedPayment(bR, dn)]) | |
960 | + | if ((fo == fo)) | |
961 | + | then ci | |
966 | 962 | else throw("Strict value is not equal to itself.") | |
967 | 963 | } | |
968 | 964 | else throw("Strict value is not equal to itself.") | |
974 | 970 | ||
975 | 971 | ||
976 | 972 | ||
977 | - | @Callable( | |
978 | - | func activate (fu | |
973 | + | @Callable(df) | |
974 | + | func activate (ft,fu) = if ((toString(df.caller) != toString(aD))) | |
979 | 975 | then throw("permissions denied") | |
980 | - | else $Tuple2([StringEntry( | |
976 | + | else $Tuple2([StringEntry(aa(), ft), StringEntry(ab(), fu)], "success") | |
981 | 977 | ||
982 | 978 | ||
983 | 979 | ||
984 | - | @Callable( | |
985 | - | func getPoolConfigWrapperREADONLY () = $Tuple2(nil, | |
980 | + | @Callable(df) | |
981 | + | func getPoolConfigWrapperREADONLY () = $Tuple2(nil, aH()) | |
986 | 982 | ||
987 | 983 | ||
988 | 984 | ||
989 | - | @Callable( | |
990 | - | func getAccBalanceWrapperREADONLY ( | |
985 | + | @Callable(df) | |
986 | + | func getAccBalanceWrapperREADONLY (br) = $Tuple2(nil, bq(br)) | |
991 | 987 | ||
992 | 988 | ||
993 | 989 | ||
994 | - | @Callable( | |
995 | - | func calcPricesWrapperREADONLY ( | |
996 | - | let | |
997 | - | $Tuple2(nil, [toString( | |
990 | + | @Callable(df) | |
991 | + | func calcPricesWrapperREADONLY (by,bz,bD) = { | |
992 | + | let bM = bC(by, bz, bD) | |
993 | + | $Tuple2(nil, [toString(bM[0]), toString(bM[1]), toString(bM[2])]) | |
998 | 994 | } | |
999 | 995 | ||
1000 | 996 | ||
1001 | 997 | ||
1002 | - | @Callable( | |
998 | + | @Callable(df) | |
1003 | 999 | func toX18WrapperREADONLY (E,F) = $Tuple2(nil, toString(D(E, F))) | |
1004 | 1000 | ||
1005 | 1001 | ||
1006 | 1002 | ||
1007 | - | @Callable( | |
1003 | + | @Callable(df) | |
1008 | 1004 | func fromX18WrapperREADONLY (H,I) = $Tuple2(nil, G(parseBigIntValue(H), I)) | |
1009 | 1005 | ||
1010 | 1006 | ||
1011 | 1007 | ||
1012 | - | @Callable( | |
1013 | - | func calcPriceBigIntWrapperREADONLY ( | |
1008 | + | @Callable(df) | |
1009 | + | func calcPriceBigIntWrapperREADONLY (bt,bu) = $Tuple2(nil, toString(bs(parseBigIntValue(bt), parseBigIntValue(bu)))) | |
1014 | 1010 | ||
1015 | 1011 | ||
1016 | 1012 | ||
1017 | - | @Callable( | |
1018 | - | func estimatePutOperationWrapperREADONLY ( | |
1013 | + | @Callable(df) | |
1014 | + | func estimatePutOperationWrapperREADONLY (bO,ck,cl,cm,cn,co,X,cp,cq) = $Tuple2(nil, cj(bO, ck, cl, cm, cn, co, X, cp, cq)) | |
1019 | 1015 | ||
1020 | 1016 | ||
1021 | 1017 | ||
1022 | - | @Callable( | |
1023 | - | func estimateGetOperationWrapperREADONLY ( | |
1024 | - | let | |
1025 | - | $Tuple2(nil, $Tuple10( | |
1018 | + | @Callable(df) | |
1019 | + | func estimateGetOperationWrapperREADONLY (bO,bP,bQ,X) = { | |
1020 | + | let cA = bN(bO, bP, bQ, addressFromStringValue(X)) | |
1021 | + | $Tuple2(nil, $Tuple10(cA._1, cA._2, cA._3, cA._4, cA._5, cA._6, cA._7, toString(cA._8), cA._9, cA._10)) | |
1026 | 1022 | } | |
1027 | 1023 | ||
1028 | 1024 | ||
1029 | 1025 | ||
1030 | - | @Callable( | |
1026 | + | @Callable(df) | |
1031 | 1027 | func statsREADONLY () = { | |
1032 | - | let | |
1033 | - | let | |
1034 | - | let | |
1035 | - | let | |
1036 | - | let | |
1037 | - | let | |
1038 | - | let | |
1039 | - | let | |
1040 | - | let | |
1041 | - | let | |
1042 | - | let | |
1043 | - | let | |
1028 | + | let bE = aH() | |
1029 | + | let bR = fromBase58String(bE[q]) | |
1030 | + | let cS = bE[r] | |
1031 | + | let cT = bE[s] | |
1032 | + | let ct = bE[v] | |
1033 | + | let cu = bE[w] | |
1034 | + | let bF = parseIntValue(bE[t]) | |
1035 | + | let bG = parseIntValue(bE[u]) | |
1036 | + | let fv = valueOrErrorMessage(assetInfo(bR), (("Asset " + toBase58String(bR)) + " doesn't exist")).quantity | |
1037 | + | let cU = bq(cS) | |
1038 | + | let cV = bq(cT) | |
1039 | + | let fw = if ((fv == 0)) | |
1044 | 1040 | then [e, e, e] | |
1045 | - | else | |
1046 | - | let | |
1047 | - | let | |
1048 | - | let | |
1049 | - | let | |
1050 | - | $Tuple2(nil, makeString(["%d%d%d%d%d%d%d", toString( | |
1041 | + | else bC(cU, cV, fv) | |
1042 | + | let cb = 0 | |
1043 | + | let fx = G(fw[1], b) | |
1044 | + | let fy = G(fw[2], b) | |
1045 | + | let fz = value(getInteger(aD, ap(toString(this)))) | |
1046 | + | $Tuple2(nil, makeString(["%d%d%d%d%d%d%d", toString(cU), toString(cV), toString(fv), toString(cb), toString(fx), toString(fy), toString(fz)], j)) | |
1051 | 1047 | } | |
1052 | 1048 | ||
1053 | 1049 | ||
1054 | 1050 | ||
1055 | - | @Callable(de) | |
1056 | - | func evaluatePutByAmountAssetREADONLY (ck) = { | |
1057 | - | let bD = aG() | |
1058 | - | let bQ = fromBase58String(bD[q]) | |
1059 | - | let cq = bD[r] | |
1060 | - | let bR = fromBase58String(cq) | |
1061 | - | let cr = bD[s] | |
1051 | + | @Callable(df) | |
1052 | + | func evaluatePutByAmountAssetREADONLY (cl) = { | |
1053 | + | let bE = aH() | |
1054 | + | let bR = fromBase58String(bE[q]) | |
1055 | + | let cr = bE[r] | |
1062 | 1056 | let bS = fromBase58String(cr) | |
1063 | - | let bE = parseIntValue(bD[t]) | |
1064 | - | let bF = parseIntValue(bD[u]) | |
1065 | - | let bT = bD[p] | |
1066 | - | let fw = valueOrErrorMessage(assetInfo(bQ), (("Asset " + toBase58String(bQ)) + " doesn't exist")).quantity | |
1067 | - | let cT = bp(cq) | |
1068 | - | let cU = bp(cr) | |
1069 | - | let bz = D(cT, bE) | |
1057 | + | let cs = bE[s] | |
1058 | + | let bT = fromBase58String(cs) | |
1059 | + | let bF = parseIntValue(bE[t]) | |
1060 | + | let bG = parseIntValue(bE[u]) | |
1061 | + | let bU = bE[p] | |
1062 | + | let fv = valueOrErrorMessage(assetInfo(bR), (("Asset " + toBase58String(bR)) + " doesn't exist")).quantity | |
1063 | + | let cU = bq(cr) | |
1064 | + | let cV = bq(cs) | |
1070 | 1065 | let bA = D(cU, bF) | |
1071 | - | let bZ = if ((fw == 0)) | |
1066 | + | let bB = D(cV, bG) | |
1067 | + | let ca = if ((fv == 0)) | |
1072 | 1068 | then e | |
1073 | - | else | |
1074 | - | let | |
1075 | - | let | |
1076 | - | let | |
1077 | - | let | |
1078 | - | let | |
1079 | - | let | |
1080 | - | let | |
1081 | - | let | |
1082 | - | let | |
1083 | - | $Tuple2(nil, makeString(["%d%d%d%d%d%d%d%d", toString( | |
1069 | + | else bs(bB, bA) | |
1070 | + | let cx = D(cl, bF) | |
1071 | + | let cy = fraction(cx, ca, d) | |
1072 | + | let cn = G(cy, bG) | |
1073 | + | let dl = cj("", 500000, cl, bS, cn, bT, "", true, false) | |
1074 | + | let cI = dl._1 | |
1075 | + | let fA = dl._3 | |
1076 | + | let bW = dl._4 | |
1077 | + | let bY = dl._5 | |
1078 | + | let bV = dl._6 | |
1079 | + | $Tuple2(nil, makeString(["%d%d%d%d%d%d%d%d", toString(cI), toString(G(ca, b)), toString(bW), toString(bY), toString(bV), bU, toString(cl), toString(cn)], j)) | |
1084 | 1080 | } | |
1085 | 1081 | ||
1086 | 1082 | ||
1087 | 1083 | ||
1088 | - | @Callable(de) | |
1089 | - | func evaluatePutByPriceAssetREADONLY (cm) = { | |
1090 | - | let bD = aG() | |
1091 | - | let bQ = fromBase58String(bD[q]) | |
1092 | - | let cq = bD[r] | |
1093 | - | let bR = fromBase58String(cq) | |
1094 | - | let cr = bD[s] | |
1084 | + | @Callable(df) | |
1085 | + | func evaluatePutByPriceAssetREADONLY (cn) = { | |
1086 | + | let bE = aH() | |
1087 | + | let bR = fromBase58String(bE[q]) | |
1088 | + | let cr = bE[r] | |
1095 | 1089 | let bS = fromBase58String(cr) | |
1096 | - | let bE = parseIntValue(bD[t]) | |
1097 | - | let bF = parseIntValue(bD[u]) | |
1098 | - | let bT = bD[p] | |
1099 | - | let fw = valueOrErrorMessage(assetInfo(bQ), (("Asset " + toBase58String(bQ)) + " doesn't exist")).quantity | |
1100 | - | let fC = bp(cq) | |
1101 | - | let fD = bp(cr) | |
1102 | - | let fE = D(fC, bE) | |
1103 | - | let fF = D(fD, bF) | |
1104 | - | let bZ = if ((fw == 0)) | |
1090 | + | let cs = bE[s] | |
1091 | + | let bT = fromBase58String(cs) | |
1092 | + | let bF = parseIntValue(bE[t]) | |
1093 | + | let bG = parseIntValue(bE[u]) | |
1094 | + | let bU = bE[p] | |
1095 | + | let fv = valueOrErrorMessage(assetInfo(bR), (("Asset " + toBase58String(bR)) + " doesn't exist")).quantity | |
1096 | + | let fB = bq(cr) | |
1097 | + | let fC = bq(cs) | |
1098 | + | let fD = D(fB, bF) | |
1099 | + | let fE = D(fC, bG) | |
1100 | + | let ca = if ((fv == 0)) | |
1105 | 1101 | then e | |
1106 | - | else | |
1107 | - | let | |
1108 | - | let | |
1109 | - | let | |
1110 | - | let | |
1111 | - | let | |
1112 | - | let | |
1113 | - | let | |
1114 | - | let | |
1115 | - | let | |
1116 | - | $Tuple2(nil, makeString(["%d%d%d%d%d%d%d%d", toString( | |
1102 | + | else bs(fE, fD) | |
1103 | + | let cy = D(cn, bG) | |
1104 | + | let cx = fraction(cy, d, ca) | |
1105 | + | let cl = G(cx, bF) | |
1106 | + | let dl = cj("", 500000, cl, bS, cn, bT, "", true, false) | |
1107 | + | let cI = dl._1 | |
1108 | + | let fA = dl._3 | |
1109 | + | let bW = dl._4 | |
1110 | + | let bY = dl._5 | |
1111 | + | let bV = dl._6 | |
1112 | + | $Tuple2(nil, makeString(["%d%d%d%d%d%d%d%d", toString(cI), toString(G(ca, b)), toString(bW), toString(bY), toString(bV), bU, toString(cl), toString(cn)], j)) | |
1117 | 1113 | } | |
1118 | 1114 | ||
1119 | 1115 | ||
1120 | 1116 | ||
1121 | - | @Callable( | |
1122 | - | func evaluateGetREADONLY (fG | |
1123 | - | let | |
1124 | - | let | |
1125 | - | let | |
1126 | - | let | |
1127 | - | let | |
1128 | - | let | |
1129 | - | let | |
1130 | - | let | |
1131 | - | $Tuple2(nil, makeString(["%d%d%d%d%d%d%d", toString( | |
1117 | + | @Callable(df) | |
1118 | + | func evaluateGetREADONLY (fF,fG) = { | |
1119 | + | let cA = bN("", fF, fG, this) | |
1120 | + | let cg = cA._1 | |
1121 | + | let ch = cA._2 | |
1122 | + | let bW = cA._5 | |
1123 | + | let bY = cA._6 | |
1124 | + | let bV = cA._7 | |
1125 | + | let cb = cA._8 | |
1126 | + | let bU = parseIntValue(cA._9) | |
1127 | + | $Tuple2(nil, makeString(["%d%d%d%d%d%d%d", toString(cg), toString(ch), toString(bW), toString(bY), toString(bV), toString(cb), toString(bU)], j)) | |
1132 | 1128 | } | |
1133 | 1129 | ||
1134 | 1130 | ||
1135 | - | @Verifier( | |
1136 | - | func | |
1137 | - | let | |
1138 | - | let | |
1139 | - | if ($isInstanceOf( | |
1131 | + | @Verifier(fH) | |
1132 | + | func fI () = { | |
1133 | + | let fJ = { | |
1134 | + | let dq = ey() | |
1135 | + | if ($isInstanceOf(dq, "ByteVector")) | |
1140 | 1136 | then { | |
1141 | - | let | |
1142 | - | | |
1137 | + | let eD = dq | |
1138 | + | eD | |
1143 | 1139 | } | |
1144 | - | else if ($isInstanceOf( | |
1145 | - | then | |
1140 | + | else if ($isInstanceOf(dq, "Unit")) | |
1141 | + | then fH.senderPublicKey | |
1146 | 1142 | else throw("Match error") | |
1147 | 1143 | } | |
1148 | - | let | |
1149 | - | if ($isInstanceOf( | |
1144 | + | let dq = fH | |
1145 | + | if ($isInstanceOf(dq, "Order")) | |
1150 | 1146 | then { | |
1151 | - | let cQ = dp | |
1152 | - | let fL = aF() | |
1153 | - | let at = cP(cQ) | |
1154 | - | let au = sigVerify(cQ.bodyBytes, cQ.proofs[0], cQ.senderPublicKey) | |
1155 | - | let av = sigVerify(cQ.bodyBytes, cQ.proofs[1], fL) | |
1156 | - | if (if (if (at) | |
1157 | - | then au | |
1158 | - | else false) | |
1147 | + | let cR = dq | |
1148 | + | let fK = aG() | |
1149 | + | let au = cQ(cR) | |
1150 | + | let av = sigVerify(cR.bodyBytes, cR.proofs[0], cR.senderPublicKey) | |
1151 | + | let aw = sigVerify(cR.bodyBytes, cR.proofs[1], fK) | |
1152 | + | if (if (if (au) | |
1159 | 1153 | then av | |
1160 | 1154 | else false) | |
1155 | + | then aw | |
1156 | + | else false) | |
1161 | 1157 | then true | |
1162 | - | else | |
1158 | + | else at(au, av, aw) | |
1163 | 1159 | } | |
1164 | - | else if ($isInstanceOf( | |
1160 | + | else if ($isInstanceOf(dq, "SetScriptTransaction")) | |
1165 | 1161 | then { | |
1166 | - | let | |
1167 | - | let | |
1168 | - | let | |
1169 | - | let | |
1170 | - | if (if (( | |
1171 | - | then ( | |
1162 | + | let ez = dq | |
1163 | + | let fL = blake2b256(value(ez.script)) | |
1164 | + | let fM = fromBase64String(value(getString(aD, ar()))) | |
1165 | + | let fN = scriptHash(this) | |
1166 | + | if (if ((fM == fL)) | |
1167 | + | then (fN != fL) | |
1172 | 1168 | else false) | |
1173 | 1169 | then true | |
1174 | - | else sigVerify( | |
1170 | + | else sigVerify(fH.bodyBytes, fH.proofs[0], fJ) | |
1175 | 1171 | } | |
1176 | - | else sigVerify( | |
1172 | + | else sigVerify(fH.bodyBytes, fH.proofs[0], fJ) | |
1177 | 1173 | } | |
1178 | 1174 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let a = 8 | |
5 | 5 | ||
6 | 6 | let b = 100000000 | |
7 | 7 | ||
8 | 8 | let c = toBigInt(100000000) | |
9 | 9 | ||
10 | 10 | let d = toBigInt(1000000000000000000) | |
11 | 11 | ||
12 | 12 | let e = toBigInt(0) | |
13 | 13 | ||
14 | 14 | let f = toBigInt(0) | |
15 | 15 | ||
16 | 16 | let g = toBigInt(1) | |
17 | 17 | ||
18 | 18 | let h = toBigInt(2) | |
19 | 19 | ||
20 | 20 | let i = "WAVES" | |
21 | 21 | ||
22 | 22 | let j = "__" | |
23 | 23 | ||
24 | 24 | let k = 1 | |
25 | 25 | ||
26 | 26 | let l = 2 | |
27 | 27 | ||
28 | 28 | let m = 3 | |
29 | 29 | ||
30 | 30 | let n = 4 | |
31 | 31 | ||
32 | 32 | let o = 1 | |
33 | 33 | ||
34 | 34 | let p = 2 | |
35 | 35 | ||
36 | 36 | let q = 3 | |
37 | 37 | ||
38 | 38 | let r = 4 | |
39 | 39 | ||
40 | 40 | let s = 5 | |
41 | 41 | ||
42 | 42 | let t = 6 | |
43 | 43 | ||
44 | 44 | let u = 7 | |
45 | 45 | ||
46 | 46 | let v = 8 | |
47 | 47 | ||
48 | 48 | let w = 9 | |
49 | 49 | ||
50 | 50 | let x = 10 | |
51 | 51 | ||
52 | 52 | let y = 1 | |
53 | 53 | ||
54 | 54 | let z = 2 | |
55 | 55 | ||
56 | 56 | let A = 3 | |
57 | 57 | ||
58 | 58 | let B = 1 | |
59 | 59 | ||
60 | 60 | let C = 7 | |
61 | 61 | ||
62 | 62 | func D (E,F) = fraction(toBigInt(E), d, toBigInt(F)) | |
63 | 63 | ||
64 | 64 | ||
65 | 65 | func G (H,I) = toInt(fraction(H, toBigInt(I), d)) | |
66 | 66 | ||
67 | 67 | ||
68 | 68 | func J (K,L,M) = fraction(K, L, M) | |
69 | 69 | ||
70 | 70 | ||
71 | - | func N (H) = if (( | |
71 | + | func N (H) = if ((0 > H)) | |
72 | 72 | then -(H) | |
73 | 73 | else H | |
74 | 74 | ||
75 | 75 | ||
76 | - | func O () = "%s__factoryContract" | |
76 | + | func O (H) = if ((e > H)) | |
77 | + | then -(H) | |
78 | + | else H | |
77 | 79 | ||
78 | 80 | ||
79 | - | func P () = "%s__ | |
81 | + | func P () = "%s__factoryContract" | |
80 | 82 | ||
81 | 83 | ||
82 | - | func Q () = "%s__ | |
84 | + | func Q () = "%s__managerPublicKey" | |
83 | 85 | ||
84 | 86 | ||
85 | - | func R () = "%s | |
87 | + | func R () = "%s__pendingManagerPublicKey" | |
86 | 88 | ||
87 | 89 | ||
88 | - | func S ( | |
90 | + | func S () = "%s%s__price__last" | |
89 | 91 | ||
90 | 92 | ||
91 | - | func | |
93 | + | func T (U,V) = makeString(["%s%s%d%d__price__history", toString(U), toString(V)], j) | |
92 | 94 | ||
93 | 95 | ||
94 | - | func | |
96 | + | func W (X,Y) = ((("%s%s%s__P__" + X) + "__") + Y) | |
95 | 97 | ||
96 | 98 | ||
97 | - | func Z () = "%s__ | |
99 | + | func Z (X,Y) = ((("%s%s%s__G__" + X) + "__") + Y) | |
98 | 100 | ||
99 | 101 | ||
100 | - | func aa () = "%s__ | |
102 | + | func aa () = "%s__amountAsset" | |
101 | 103 | ||
102 | 104 | ||
103 | - | let ab = "%s__fee" | |
104 | - | ||
105 | - | let ac = fraction(5, b, 10000) | |
106 | - | ||
107 | - | let ad = valueOrElse(getInteger(this, ab), ac) | |
108 | - | ||
109 | - | func ae () = "%s__factoryConfig" | |
105 | + | func ab () = "%s__priceAsset" | |
110 | 106 | ||
111 | 107 | ||
112 | - | func af () = "%s%s__matcher__publicKey" | |
108 | + | let ac = "%s__fee" | |
109 | + | ||
110 | + | let ad = fraction(5, b, 10000) | |
111 | + | ||
112 | + | let ae = valueOrElse(getInteger(this, ac), ad) | |
113 | + | ||
114 | + | func af () = "%s__factoryConfig" | |
113 | 115 | ||
114 | 116 | ||
115 | - | func ag ( | |
117 | + | func ag () = "%s%s__matcher__publicKey" | |
116 | 118 | ||
117 | 119 | ||
118 | - | func | |
120 | + | func ah (ai) = (("%s%s%s__" + ai) + "__mappings__poolContract2LpAsset") | |
119 | 121 | ||
120 | 122 | ||
121 | - | func | |
123 | + | func aj (ak,al) = (((("%d%d%s__" + ak) + "__") + al) + "__config") | |
122 | 124 | ||
123 | 125 | ||
124 | - | func | |
126 | + | func am (an) = ("%s%s%s__mappings__baseAsset2internalId__" + an) | |
125 | 127 | ||
126 | 128 | ||
127 | - | func ao ( | |
129 | + | func ao () = "%s__shutdown" | |
128 | 130 | ||
129 | 131 | ||
130 | - | func | |
132 | + | func ap (aq) = ("%s%s__poolWeight__" + aq) | |
131 | 133 | ||
132 | 134 | ||
133 | - | let ar = "%s__feeCollectorAddress" | |
134 | - | ||
135 | - | func as (at,au,av) = throw(((((("order validation failed: orderValid=" + toString(at)) + " senderValid=") + toString(au)) + " matcherValid=") + toString(av))) | |
135 | + | func ar () = "%s__allowedLpScriptHash" | |
136 | 136 | ||
137 | 137 | ||
138 | - | func aw (ax,ay) = valueOrErrorMessage(getString(ax, ay), makeString(["mandatory ", toString(ax), ".", ay, " is not defined"], "")) | |
138 | + | let as = "%s__feeCollectorAddress" | |
139 | + | ||
140 | + | func at (au,av,aw) = throw(((((("order validation failed: orderValid=" + toString(au)) + " senderValid=") + toString(av)) + " matcherValid=") + toString(aw))) | |
139 | 141 | ||
140 | 142 | ||
141 | - | func | |
143 | + | func ax (ay,az) = valueOrErrorMessage(getString(ay, az), makeString(["mandatory ", toString(ay), ".", az, " is not defined"], "")) | |
142 | 144 | ||
143 | 145 | ||
144 | - | func aA ( | |
146 | + | func aA (ay,az) = valueOrErrorMessage(getInteger(ay, az), makeString(["mandatory ", toString(ay), ".", az, " is not defined"], "")) | |
145 | 147 | ||
146 | 148 | ||
147 | - | let aC = addressFromStringValue(aw(this, O())) | |
148 | - | ||
149 | - | let aD = addressFromStringValue(aw(aC, ar)) | |
150 | - | ||
151 | - | func aE () = valueOrElse(getBoolean(aC, an()), false) | |
149 | + | func aB (aC) = throw(makeString(["lp.ride:", aC], " ")) | |
152 | 150 | ||
153 | 151 | ||
154 | - | func aF () = fromBase58String(aw(aC, af())) | |
152 | + | let aD = addressFromStringValue(ax(this, P())) | |
153 | + | ||
154 | + | let aE = addressFromStringValue(ax(aD, as)) | |
155 | + | ||
156 | + | func aF () = valueOrElse(getBoolean(aD, ao()), false) | |
155 | 157 | ||
156 | 158 | ||
157 | - | func aG () = { | |
158 | - | let aH = aw(this, Z()) | |
159 | - | let aI = aw(this, aa()) | |
160 | - | let ak = az(aC, al(aI)) | |
161 | - | let aj = az(aC, al(aH)) | |
162 | - | split(aw(aC, ai(toString(aj), toString(ak))), j) | |
159 | + | func aG () = fromBase58String(ax(aD, ag())) | |
160 | + | ||
161 | + | ||
162 | + | func aH () = { | |
163 | + | let aI = ax(this, aa()) | |
164 | + | let aJ = ax(this, ab()) | |
165 | + | let al = aA(aD, am(aJ)) | |
166 | + | let ak = aA(aD, am(aI)) | |
167 | + | split(ax(aD, aj(toString(ak), toString(al))), j) | |
163 | 168 | } | |
164 | 169 | ||
165 | 170 | ||
166 | - | func | |
171 | + | func aK (aL) = if ((aL == i)) | |
167 | 172 | then unit | |
168 | - | else fromBase58String( | |
173 | + | else fromBase58String(aL) | |
169 | 174 | ||
170 | 175 | ||
171 | - | func | |
176 | + | func aM (aL) = if ((aL == unit)) | |
172 | 177 | then i | |
173 | - | else toBase58String(value( | |
178 | + | else toBase58String(value(aL)) | |
174 | 179 | ||
175 | 180 | ||
176 | - | func | |
181 | + | func aN (aO) = $Tuple7(addressFromStringValue(aO[o]), parseIntValue(aO[p]), fromBase58String(aO[q]), aK(aO[r]), aK(aO[s]), parseIntValue(aO[t]), parseIntValue(aO[u])) | |
177 | 182 | ||
178 | 183 | ||
179 | - | let | |
184 | + | let aP = aN(aH()) | |
180 | 185 | ||
181 | - | let | |
186 | + | let aQ = aP | |
182 | 187 | ||
183 | - | let | |
188 | + | let aR = aQ._1 | |
184 | 189 | ||
185 | - | let | |
190 | + | let aS = aQ._2 | |
186 | 191 | ||
187 | - | let | |
192 | + | let aT = aQ._3 | |
188 | 193 | ||
189 | - | let | |
194 | + | let aU = aQ._4 | |
190 | 195 | ||
191 | - | let | |
196 | + | let aV = aQ._5 | |
192 | 197 | ||
193 | - | let | |
198 | + | let aW = aQ._6 | |
194 | 199 | ||
195 | - | let | |
200 | + | let aX = aQ._7 | |
196 | 201 | ||
197 | - | func | |
202 | + | func aY () = split(ax(aD, af()), j) | |
198 | 203 | ||
199 | 204 | ||
200 | - | let | |
205 | + | let aZ = valueOrErrorMessage(addressFromString(aY()[B]), "incorrect staking address") | |
201 | 206 | ||
202 | - | let | |
207 | + | let ba = valueOrErrorMessage(addressFromString(aY()[C]), "incorrect staking address") | |
203 | 208 | ||
204 | - | func | |
209 | + | func bb (bc,bd,be,bf,bg,bh,bi,bj,bk,bl) = makeString(["%d%d%d%d%d%d%d%d%d%d", toString(bc), toString(bd), toString(be), toString(bf), toString(bg), toString(bh), toString(bi), toString(bj), toString(bk), toString(bl)], j) | |
205 | 210 | ||
206 | 211 | ||
207 | - | func | |
212 | + | func bm (bn,bo,bp,bf,bi,bj) = makeString(["%d%d%d%d%d%d", toString(bn), toString(bo), toString(bp), toString(bf), toString(bi), toString(bj)], j) | |
208 | 213 | ||
209 | 214 | ||
210 | - | func | |
215 | + | func bq (br) = if ((br == "WAVES")) | |
211 | 216 | then wavesBalance(this).available | |
212 | - | else assetBalance(this, fromBase58String( | |
217 | + | else assetBalance(this, fromBase58String(br)) | |
213 | 218 | ||
214 | 219 | ||
215 | - | func | |
220 | + | func bs (bt,bu) = fraction(bt, d, bu) | |
216 | 221 | ||
217 | 222 | ||
218 | - | func bu (bv,bw,bx,by) = { | |
219 | - | let bz = D(bx, bv) | |
223 | + | func bv (bw,bx,by,bz) = { | |
220 | 224 | let bA = D(by, bw) | |
221 | - | br(bA, bz) | |
225 | + | let bB = D(bz, bx) | |
226 | + | bs(bB, bA) | |
222 | 227 | } | |
223 | 228 | ||
224 | 229 | ||
225 | - | func | |
226 | - | let | |
227 | - | let | |
228 | - | let | |
229 | - | let | |
230 | - | let | |
231 | - | let | |
232 | - | let | |
233 | - | let | |
234 | - | let | |
235 | - | [ | |
230 | + | func bC (by,bz,bD) = { | |
231 | + | let bE = aH() | |
232 | + | let bF = parseIntValue(bE[t]) | |
233 | + | let bG = parseIntValue(bE[u]) | |
234 | + | let bH = bv(bF, bG, by, bz) | |
235 | + | let bu = D(by, bF) | |
236 | + | let bt = D(bz, bG) | |
237 | + | let bI = D(bD, b) | |
238 | + | let bJ = bs(bu, bI) | |
239 | + | let bK = bs(bt, bI) | |
240 | + | [bH, bJ, bK] | |
236 | 241 | } | |
237 | 242 | ||
238 | 243 | ||
239 | - | func | |
240 | - | let | |
241 | - | [G( | |
244 | + | func bL (by,bz,bD) = { | |
245 | + | let bM = bC(by, bz, bD) | |
246 | + | [G(bM[0], b), G(bM[1], b), G(bM[2], b)] | |
242 | 247 | } | |
243 | 248 | ||
244 | 249 | ||
245 | - | func | |
246 | - | let | |
247 | - | let | |
248 | - | let | |
249 | - | let | |
250 | - | let | |
251 | - | let | |
252 | - | let | |
253 | - | let | |
254 | - | if (( | |
250 | + | func bN (bO,bP,bQ,X) = { | |
251 | + | let bE = aH() | |
252 | + | let bR = bE[q] | |
253 | + | let bS = bE[r] | |
254 | + | let bT = bE[s] | |
255 | + | let bw = parseIntValue(bE[t]) | |
256 | + | let bx = parseIntValue(bE[u]) | |
257 | + | let bU = bE[p] | |
258 | + | let bV = valueOrErrorMessage(assetInfo(fromBase58String(bR)), (("Asset " + bR) + " doesn't exist")).quantity | |
259 | + | if ((bR != bP)) | |
255 | 260 | then throw("Invalid asset passed.") | |
256 | 261 | else { | |
257 | - | let bV = bp(bR) | |
258 | - | let bW = D(bV, bv) | |
259 | - | let bX = bp(bS) | |
260 | - | let bY = D(bX, bw) | |
261 | - | let bZ = br(bY, bW) | |
262 | - | let ca = G(bZ, b) | |
263 | - | let cb = D(bP, b) | |
264 | - | let cc = D(bU, b) | |
265 | - | let cd = fraction(bW, cb, cc) | |
266 | - | let ce = fraction(bY, cb, cc) | |
267 | - | let cf = G(cd, bv) | |
262 | + | let bW = bq(bS) | |
263 | + | let bX = D(bW, bw) | |
264 | + | let bY = bq(bT) | |
265 | + | let bZ = D(bY, bx) | |
266 | + | let ca = bs(bZ, bX) | |
267 | + | let cb = G(ca, b) | |
268 | + | let cc = D(bQ, b) | |
269 | + | let cd = D(bV, b) | |
270 | + | let ce = fraction(bX, cc, cd) | |
271 | + | let cf = fraction(bZ, cc, cd) | |
268 | 272 | let cg = G(ce, bw) | |
269 | - | let ch = if ((bN == "")) | |
273 | + | let ch = G(cf, bx) | |
274 | + | let ci = if ((bO == "")) | |
270 | 275 | then nil | |
271 | - | else [ScriptTransfer( | |
276 | + | else [ScriptTransfer(X, cg, if ((bS == "WAVES")) | |
272 | 277 | then unit | |
273 | - | else fromBase58String( | |
278 | + | else fromBase58String(bS)), ScriptTransfer(X, ch, if ((bT == "WAVES")) | |
274 | 279 | then unit | |
275 | - | else fromBase58String( | |
276 | - | $Tuple10( | |
280 | + | else fromBase58String(bT)), StringEntry(Z(toString(X), bO), bm(cg, ch, bQ, cb, height, lastBlock.timestamp)), IntegerEntry(S(), cb), IntegerEntry(T(height, lastBlock.timestamp), cb)] | |
281 | + | $Tuple10(cg, ch, bS, bT, bW, bY, bV, ca, bU, ci) | |
277 | 282 | } | |
278 | 283 | } | |
279 | 284 | ||
280 | 285 | ||
281 | - | func | |
282 | - | let | |
283 | - | let | |
284 | - | let | |
285 | - | let | |
286 | - | let | |
287 | - | let | |
288 | - | let | |
289 | - | let | |
290 | - | let | |
291 | - | let | |
292 | - | let | |
293 | - | let | |
294 | - | if (if (( | |
286 | + | func cj (bO,ck,cl,cm,cn,co,X,cp,cq) = { | |
287 | + | let bE = aH() | |
288 | + | let bR = fromBase58String(bE[q]) | |
289 | + | let cr = bE[r] | |
290 | + | let cs = bE[s] | |
291 | + | let ct = bE[v] | |
292 | + | let cu = bE[w] | |
293 | + | let bF = parseIntValue(bE[t]) | |
294 | + | let bG = parseIntValue(bE[u]) | |
295 | + | let bU = bE[p] | |
296 | + | let bV = valueOrErrorMessage(assetInfo(bR), (("Asset " + toBase58String(bR)) + " doesn't exist")).quantity | |
297 | + | let cv = toBase58String(valueOrElse(cm, fromBase58String("WAVES"))) | |
298 | + | let cw = toBase58String(valueOrElse(co, fromBase58String("WAVES"))) | |
299 | + | if (if ((cr != cv)) | |
295 | 300 | then true | |
296 | - | else ( | |
301 | + | else (cs != cw)) | |
297 | 302 | then throw("Invalid amt or price asset passed.") | |
298 | 303 | else { | |
299 | - | let | |
300 | - | then | |
301 | - | else ( | |
302 | - | let | |
303 | - | then | |
304 | - | else ( | |
305 | - | let | |
306 | - | let | |
307 | - | let | |
308 | - | let | |
309 | - | let | |
310 | - | let | |
304 | + | let bW = if (cp) | |
305 | + | then bq(cr) | |
306 | + | else (bq(cr) - cl) | |
307 | + | let bY = if (cp) | |
308 | + | then bq(cs) | |
309 | + | else (bq(cs) - cn) | |
310 | + | let cx = D(cl, bF) | |
311 | + | let cy = D(cn, bG) | |
312 | + | let cz = bs(cy, cx) | |
313 | + | let bX = D(bW, bF) | |
314 | + | let bZ = D(bY, bG) | |
315 | + | let cA = if ((bV == 0)) | |
311 | 316 | then { | |
312 | - | let | |
313 | - | let | |
314 | - | let | |
315 | - | $Tuple5(G( | |
317 | + | let ca = e | |
318 | + | let cB = e | |
319 | + | let bI = pow((cx * cy), 0, toBigInt(5), 1, 0, DOWN) | |
320 | + | $Tuple5(G(bI, b), G(cx, bF), G(cy, bG), bs((bZ + cy), (bX + cx)), cB) | |
316 | 321 | } | |
317 | 322 | else { | |
318 | - | let | |
319 | - | let | |
320 | - | let | |
321 | - | if (if (( | |
322 | - | then ( | |
323 | + | let ca = bs(bZ, bX) | |
324 | + | let cB = fraction(O((ca - cz)), d, ca) | |
325 | + | let cC = D(ck, b) | |
326 | + | if (if ((ca != e)) | |
327 | + | then (cB > cC) | |
323 | 328 | else false) | |
324 | - | then throw(((("Price slippage " + toString( | |
329 | + | then throw(((("Price slippage " + toString(cB)) + " exceeded the passed limit of ") + toString(cC))) | |
325 | 330 | else { | |
326 | - | let | |
327 | - | let | |
328 | - | let | |
329 | - | let | |
330 | - | then $Tuple2( | |
331 | - | else $Tuple2( | |
332 | - | let | |
333 | - | let | |
334 | - | let | |
335 | - | $Tuple5(G( | |
331 | + | let cd = D(bV, b) | |
332 | + | let cD = fraction(cx, ca, d) | |
333 | + | let cE = fraction(cy, d, ca) | |
334 | + | let cF = if ((cD > cy)) | |
335 | + | then $Tuple2(cE, cy) | |
336 | + | else $Tuple2(cx, cD) | |
337 | + | let cG = cF._1 | |
338 | + | let cH = cF._2 | |
339 | + | let bI = fraction(cd, cH, bZ) | |
340 | + | $Tuple5(G(bI, b), G(cG, bF), G(cH, bG), ca, cB) | |
336 | 341 | } | |
337 | 342 | } | |
338 | - | let | |
339 | - | let | |
340 | - | let | |
341 | - | let | |
342 | - | let | |
343 | - | if ((0 >= | |
343 | + | let cI = cA._1 | |
344 | + | let cJ = cA._2 | |
345 | + | let cK = cA._3 | |
346 | + | let cb = G(cA._4, b) | |
347 | + | let cL = G(cA._5, b) | |
348 | + | if ((0 >= cI)) | |
344 | 349 | then throw("Invalid calculations. LP calculated is less than zero.") | |
345 | 350 | else { | |
346 | - | let | |
351 | + | let cM = if (!(cq)) | |
347 | 352 | then 0 | |
348 | - | else | |
349 | - | let | |
350 | - | let | |
351 | - | let | |
352 | - | $Tuple13( | |
353 | + | else cI | |
354 | + | let cN = (cl - cJ) | |
355 | + | let cO = (cn - cK) | |
356 | + | let cP = [IntegerEntry(S(), cb), IntegerEntry(T(height, lastBlock.timestamp), cb), StringEntry(W(X, bO), bb(cJ, cK, cM, cb, ck, cL, height, lastBlock.timestamp, cN, cO))] | |
357 | + | $Tuple13(cI, cM, cb, bW, bY, bV, bR, bU, cP, cN, cO, cm, co) | |
353 | 358 | } | |
354 | 359 | } | |
355 | 360 | } | |
356 | 361 | ||
357 | 362 | ||
358 | - | func | |
359 | - | let | |
360 | - | let | |
361 | - | let | |
362 | - | let | |
363 | - | let | |
364 | - | let | |
365 | - | let | |
366 | - | let | |
367 | - | let | |
368 | - | then | |
369 | - | else | |
370 | - | let | |
371 | - | if (if (if ( | |
363 | + | func cQ (cR) = { | |
364 | + | let bE = aH() | |
365 | + | let cS = bE[r] | |
366 | + | let cT = bE[s] | |
367 | + | let bU = parseIntValue(bE[p]) | |
368 | + | let bF = parseIntValue(bE[t]) | |
369 | + | let bG = parseIntValue(bE[u]) | |
370 | + | let cU = bq(cS) | |
371 | + | let cV = bq(cT) | |
372 | + | let ca = if ((cR.orderType == Buy)) | |
373 | + | then bv(bF, bG, (cU + cR.amount), cV) | |
374 | + | else bv(bF, bG, (cU - cR.amount), cV) | |
375 | + | let cb = G(ca, b) | |
376 | + | if (if (if (aF()) | |
372 | 377 | then true | |
373 | - | else ( | |
378 | + | else (bU == m)) | |
374 | 379 | then true | |
375 | - | else ( | |
380 | + | else (bU == n)) | |
376 | 381 | then throw("Exchange operations disabled") | |
377 | 382 | else { | |
378 | - | let | |
379 | - | let | |
383 | + | let cW = cR.assetPair.amountAsset | |
384 | + | let cX = if ((cW == unit)) | |
380 | 385 | then "WAVES" | |
381 | - | else toBase58String(value( | |
382 | - | let | |
383 | - | let | |
386 | + | else toBase58String(value(cW)) | |
387 | + | let cY = cR.assetPair.priceAsset | |
388 | + | let cZ = if ((cY == unit)) | |
384 | 389 | then "WAVES" | |
385 | - | else toBase58String(value( | |
386 | - | if (if (( | |
390 | + | else toBase58String(value(cY)) | |
391 | + | if (if ((cX != cS)) | |
387 | 392 | then true | |
388 | - | else ( | |
393 | + | else (cZ != cT)) | |
389 | 394 | then throw("Wrong order assets.") | |
390 | 395 | else { | |
391 | - | let | |
392 | - | let | |
393 | - | let | |
394 | - | let | |
395 | - | then ( | |
396 | - | else ( | |
396 | + | let da = cR.price | |
397 | + | let db = fraction(b, bG, bF) | |
398 | + | let dc = J(da, b, db) | |
399 | + | let dd = if ((cR.orderType == Buy)) | |
400 | + | then (cb >= dc) | |
401 | + | else (dc >= cb) | |
397 | 402 | true | |
398 | 403 | } | |
399 | 404 | } | |
400 | 405 | } | |
401 | 406 | ||
402 | 407 | ||
403 | - | func | |
408 | + | func de (df) = if ((size(df.payments) != 1)) | |
404 | 409 | then throw("exactly 1 payment is expected") | |
405 | 410 | else { | |
406 | - | let | |
407 | - | let | |
408 | - | let | |
409 | - | let | |
410 | - | let | |
411 | - | let | |
412 | - | let | |
413 | - | let | |
414 | - | if (if ( | |
411 | + | let dg = value(df.payments[0]) | |
412 | + | let bP = value(dg.assetId) | |
413 | + | let dh = dg.amount | |
414 | + | let cA = bN(toBase58String(df.transactionId), toBase58String(bP), dh, df.caller) | |
415 | + | let cg = cA._1 | |
416 | + | let ch = cA._2 | |
417 | + | let bU = parseIntValue(cA._9) | |
418 | + | let ci = cA._10 | |
419 | + | if (if (aF()) | |
415 | 420 | then true | |
416 | - | else ( | |
417 | - | then throw(("Get operation is blocked by admin. Status = " + toString( | |
418 | - | else $Tuple5( | |
421 | + | else (bU == n)) | |
422 | + | then throw(("Get operation is blocked by admin. Status = " + toString(bU))) | |
423 | + | else $Tuple5(cg, ch, dh, bP, ci) | |
419 | 424 | } | |
420 | 425 | ||
421 | 426 | ||
422 | - | func | |
427 | + | func di (df,ck,cq) = if ((size(df.payments) != 2)) | |
423 | 428 | then throw("exactly 2 payments are expected") | |
424 | 429 | else { | |
425 | - | let | |
426 | - | let | |
427 | - | let | |
428 | - | let | |
429 | - | if (if (if ( | |
430 | + | let dj = value(df.payments[0]) | |
431 | + | let dk = value(df.payments[1]) | |
432 | + | let dl = cj(toBase58String(df.transactionId), ck, dj.amount, dj.assetId, dk.amount, dk.assetId, toString(df.caller), false, cq) | |
433 | + | let bU = parseIntValue(dl._8) | |
434 | + | if (if (if (aF()) | |
430 | 435 | then true | |
431 | - | else ( | |
436 | + | else (bU == l)) | |
432 | 437 | then true | |
433 | - | else ( | |
434 | - | then throw(("Put operation is blocked by admin. Status = " + toString( | |
435 | - | else | |
438 | + | else (bU == n)) | |
439 | + | then throw(("Put operation is blocked by admin. Status = " + toString(bU))) | |
440 | + | else dl | |
436 | 441 | } | |
437 | 442 | ||
438 | 443 | ||
439 | - | func | |
440 | - | let | |
441 | - | if (( | |
444 | + | func dm (dn) = { | |
445 | + | let do = invoke(aD, "emit", [dn], nil) | |
446 | + | if ((do == do)) | |
442 | 447 | then { | |
443 | - | let | |
444 | - | let | |
445 | - | if ($isInstanceOf( | |
448 | + | let dp = { | |
449 | + | let dq = do | |
450 | + | if ($isInstanceOf(dq, "Address")) | |
446 | 451 | then { | |
447 | - | let | |
448 | - | invoke( | |
452 | + | let dr = dq | |
453 | + | invoke(dr, "emit", [dn], nil) | |
449 | 454 | } | |
450 | 455 | else unit | |
451 | 456 | } | |
452 | - | if (( | |
453 | - | then | |
457 | + | if ((dp == dp)) | |
458 | + | then dn | |
454 | 459 | else throw("Strict value is not equal to itself.") | |
455 | 460 | } | |
456 | 461 | else throw("Strict value is not equal to itself.") | |
457 | 462 | } | |
458 | 463 | ||
459 | 464 | ||
460 | - | func | |
461 | - | let | |
462 | - | $Tuple2(( | |
465 | + | func ds (dn) = { | |
466 | + | let dt = fraction(dn, ae, b) | |
467 | + | $Tuple2((dn - dt), dt) | |
463 | 468 | } | |
464 | 469 | ||
465 | 470 | ||
466 | - | func | |
467 | - | let | |
468 | - | let | |
469 | - | let | |
470 | - | let | |
471 | - | let | |
472 | - | let | |
473 | - | let | |
474 | - | let | |
475 | - | let | |
476 | - | let | |
477 | - | let | |
478 | - | let | |
471 | + | func du (dv,dw,X,Y) = { | |
472 | + | let dx = (Y == unit) | |
473 | + | let dy = aN(aH()) | |
474 | + | let dz = dy._1 | |
475 | + | let bU = dy._2 | |
476 | + | let bR = dy._3 | |
477 | + | let dA = dy._4 | |
478 | + | let cT = dy._5 | |
479 | + | let dB = dy._6 | |
480 | + | let dC = dy._7 | |
481 | + | let dD = bq(aM(dA)) | |
482 | + | let dE = bq(aM(cT)) | |
483 | + | let dF = if ((dw == dA)) | |
479 | 484 | then true | |
480 | - | else if (( | |
485 | + | else if ((dw == cT)) | |
481 | 486 | then false | |
482 | - | else aA("invalid asset") | |
483 | - | let dF = if (dw) | |
484 | - | then $Tuple2(dC, dD) | |
485 | - | else if (dE) | |
486 | - | then $Tuple2((dC - du), dD) | |
487 | - | else $Tuple2(dC, (dD - du)) | |
488 | - | let dG = dF._1 | |
489 | - | let dH = dF._2 | |
490 | - | let dI = if (dE) | |
491 | - | then $Tuple2(du, 0) | |
492 | - | else $Tuple2(0, du) | |
493 | - | let dJ = dI._1 | |
494 | - | let dK = dI._2 | |
495 | - | let dL = dr(dJ)._1 | |
496 | - | let dM = dr(dK)._1 | |
497 | - | let dN = dr(du) | |
498 | - | let dO = dN._1 | |
499 | - | let ds = dN._2 | |
500 | - | let dP = (dG + dL) | |
487 | + | else aB("invalid asset") | |
488 | + | let dG = if (dx) | |
489 | + | then $Tuple2(dD, dE) | |
490 | + | else if (dF) | |
491 | + | then $Tuple2((dD - dv), dE) | |
492 | + | else $Tuple2(dD, (dE - dv)) | |
493 | + | let dH = dG._1 | |
494 | + | let dI = dG._2 | |
495 | + | let dJ = if (dF) | |
496 | + | then $Tuple2(dv, 0) | |
497 | + | else $Tuple2(0, dv) | |
498 | + | let dK = dJ._1 | |
499 | + | let dL = dJ._2 | |
500 | + | let dM = ds(dK)._1 | |
501 | + | let dN = ds(dL)._1 | |
502 | + | let dO = ds(dv) | |
503 | + | let dP = dO._1 | |
504 | + | let dt = dO._2 | |
501 | 505 | let dQ = (dH + dM) | |
502 | - | let ca = G(br(D(dQ, dB), D(dP, dA)), b) | |
503 | - | let dR = if (dE) | |
504 | - | then dG | |
505 | - | else dH | |
506 | - | let dS = toBigInt(dR) | |
507 | - | let dT = toBigInt(valueOrErrorMessage(assetInfo(bQ), (("asset " + toBase58String(bQ)) + " doesn't exist")).quantity) | |
508 | - | let dU = if ((dT > f)) | |
506 | + | let dR = (dI + dN) | |
507 | + | let dS = bs(D(dR, dC), D(dQ, dB)) | |
508 | + | let dT = G(dS, b) | |
509 | + | let dU = if (dF) | |
510 | + | then dH | |
511 | + | else dI | |
512 | + | let dV = toBigInt(dU) | |
513 | + | let dW = toBigInt(valueOrErrorMessage(assetInfo(bR), (("asset " + toBase58String(bR)) + " doesn't exist")).quantity) | |
514 | + | let dX = if ((dW > f)) | |
509 | 515 | then true | |
510 | - | else | |
511 | - | if (( | |
516 | + | else aB("initial deposit requires all coins") | |
517 | + | if ((dX == dX)) | |
512 | 518 | then { | |
513 | - | let | |
514 | - | let | |
515 | - | let | |
519 | + | let dY = toBigInt(dP) | |
520 | + | let dZ = max([0, toInt(((dW * (sqrtBigInt((d + ((dY * d) / dV)), 18, 18, DOWN) - d)) / d))]) | |
521 | + | let cP = if (dx) | |
516 | 522 | then nil | |
517 | - | else [IntegerEntry(R(), ca), IntegerEntry(S(height, lastBlock.timestamp), ca), StringEntry(V(toString(value(W)), toBase58String(value(X))), ba(dJ, dK, dW, ca, 0, 0, height, lastBlock.timestamp, 0, 0))] | |
518 | - | let dX = fraction(dH, b, dG) | |
519 | - | let dY = fraction(du, b, (dX + b)) | |
520 | - | let dZ = (du - dY) | |
521 | - | let ea = toInt(fraction(dT, toBigInt(dZ), toBigInt(dH))) | |
522 | - | let eb = if ((ea == 0)) | |
523 | - | then if ((dW == 0)) | |
524 | - | then 0 | |
525 | - | else aA("bonus calculation error") | |
526 | - | else fraction((dW - ea), b, ea) | |
527 | - | $Tuple4(dW, cO, ds, eb) | |
523 | + | else [IntegerEntry(S(), dT), IntegerEntry(T(height, lastBlock.timestamp), dT), StringEntry(W(toString(value(X)), toBase58String(value(Y))), bb(dK, dL, dZ, dT, 0, 0, height, lastBlock.timestamp, 0, 0))] | |
524 | + | let ea = bs(D(dI, dC), D(dH, dB)) | |
525 | + | let eb = G(ea, b) | |
526 | + | let ec = N((((dT - eb) * b) / eb)) | |
527 | + | $Tuple4(dZ, cP, dt, ec) | |
528 | 528 | } | |
529 | 529 | else throw("Strict value is not equal to itself.") | |
530 | 530 | } | |
531 | 531 | ||
532 | 532 | ||
533 | - | func | |
534 | - | let | |
535 | - | let | |
536 | - | let | |
537 | - | let | |
538 | - | let | |
539 | - | let | |
540 | - | let | |
541 | - | let | |
542 | - | let | |
543 | - | let | |
533 | + | func ed (ee,dP,dw,X,Y) = { | |
534 | + | let dx = (Y == unit) | |
535 | + | let ef = aN(aH()) | |
536 | + | let dz = ef._1 | |
537 | + | let bU = ef._2 | |
538 | + | let bR = ef._3 | |
539 | + | let dA = ef._4 | |
540 | + | let cT = ef._5 | |
541 | + | let eg = ef._6 | |
542 | + | let eh = ef._7 | |
543 | + | let ei = [if ((dw == bR)) | |
544 | 544 | then true | |
545 | - | else | |
546 | - | if (( | |
545 | + | else aB("invalid lp asset")] | |
546 | + | if ((ei == ei)) | |
547 | 547 | then { | |
548 | - | let | |
548 | + | let ej = if ((ee == dA)) | |
549 | 549 | then true | |
550 | - | else if (( | |
550 | + | else if ((ee == cT)) | |
551 | 551 | then false | |
552 | - | else | |
553 | - | let | |
554 | - | then toBigInt( | |
555 | - | else toBigInt( | |
556 | - | let | |
557 | - | let | |
558 | - | let | |
559 | - | then | |
560 | - | else | |
561 | - | let | |
562 | - | let | |
563 | - | let | |
564 | - | let | |
565 | - | let | |
566 | - | let | |
567 | - | let | |
568 | - | let | |
569 | - | then $Tuple4( | |
570 | - | else $Tuple4(0, | |
571 | - | let | |
572 | - | let | |
573 | - | let | |
574 | - | let | |
575 | - | let | |
576 | - | let | |
577 | - | let | |
552 | + | else aB("invalid asset") | |
553 | + | let ek = if (ej) | |
554 | + | then toBigInt(bq(aM(dA))) | |
555 | + | else toBigInt(bq(aM(cT))) | |
556 | + | let el = bq(aM(dA)) | |
557 | + | let em = bq(aM(cT)) | |
558 | + | let en = if (ej) | |
559 | + | then el | |
560 | + | else em | |
561 | + | let eo = toBigInt(en) | |
562 | + | let dW = toBigInt(valueOrErrorMessage(assetInfo(bR), (("asset " + toBase58String(bR)) + " doesn't exist")).quantity) | |
563 | + | let ep = toBigInt(dP) | |
564 | + | let eq = max([0, toInt(((ek * (d - pow((d - ((ep * d) / dW)), 18, h, 0, 18, DOWN))) / d))]) | |
565 | + | let er = ds(eq) | |
566 | + | let es = er._1 | |
567 | + | let dt = er._2 | |
568 | + | let et = if (ej) | |
569 | + | then $Tuple4(es, 0, (el - eq), em) | |
570 | + | else $Tuple4(0, es, el, (em - eq)) | |
571 | + | let eu = et._1 | |
572 | + | let ev = et._2 | |
573 | + | let ew = et._3 | |
574 | + | let ex = et._4 | |
575 | + | let dS = bs(D(ex, eh), D(ew, eg)) | |
576 | + | let dT = G(dS, b) | |
577 | + | let cP = if (dx) | |
578 | 578 | then nil | |
579 | - | else [StringEntry(Y(toString(value(W)), toBase58String(value(X))), bl(et, eu, dO, ca, height, lastBlock.timestamp)), IntegerEntry(R(), ca), IntegerEntry(S(height, lastBlock.timestamp), ca)] | |
580 | - | let ey = bM("", aL(bQ), dO, this) | |
581 | - | let ez = (ey._1 + ey._2) | |
582 | - | let eb = if ((ez == 0)) | |
583 | - | then if ((er == 0)) | |
584 | - | then 0 | |
585 | - | else aA("bonus calculation error") | |
586 | - | else fraction((er - ez), b, ez) | |
587 | - | $Tuple4(er, cO, ds, eb) | |
579 | + | else [StringEntry(Z(toString(value(X)), toBase58String(value(Y))), bm(eu, ev, dP, dT, height, lastBlock.timestamp)), IntegerEntry(S(), dT), IntegerEntry(T(height, lastBlock.timestamp), dT)] | |
580 | + | let ea = bs(D(em, eh), D(el, eg)) | |
581 | + | let eb = G(ea, b) | |
582 | + | let ec = N((((dT - eb) * b) / eb)) | |
583 | + | $Tuple4(es, cP, dt, ec) | |
588 | 584 | } | |
589 | 585 | else throw("Strict value is not equal to itself.") | |
590 | 586 | } | |
591 | 587 | ||
592 | 588 | ||
593 | - | func | |
594 | - | let | |
595 | - | if ($isInstanceOf( | |
589 | + | func ey () = { | |
590 | + | let dq = getString(Q()) | |
591 | + | if ($isInstanceOf(dq, "String")) | |
596 | 592 | then { | |
597 | - | let | |
598 | - | fromBase58String( | |
593 | + | let ez = dq | |
594 | + | fromBase58String(ez) | |
599 | 595 | } | |
600 | - | else if ($isInstanceOf( | |
596 | + | else if ($isInstanceOf(dq, "Unit")) | |
601 | 597 | then unit | |
602 | 598 | else throw("Match error") | |
603 | 599 | } | |
604 | 600 | ||
605 | 601 | ||
606 | - | func | |
607 | - | let | |
608 | - | if ($isInstanceOf( | |
602 | + | func eA () = { | |
603 | + | let dq = getString(R()) | |
604 | + | if ($isInstanceOf(dq, "String")) | |
609 | 605 | then { | |
610 | - | let | |
611 | - | fromBase58String( | |
606 | + | let ez = dq | |
607 | + | fromBase58String(ez) | |
612 | 608 | } | |
613 | - | else if ($isInstanceOf( | |
609 | + | else if ($isInstanceOf(dq, "Unit")) | |
614 | 610 | then unit | |
615 | 611 | else throw("Match error") | |
616 | 612 | } | |
617 | 613 | ||
618 | 614 | ||
619 | - | func | |
620 | - | let | |
621 | - | let | |
622 | - | if ($isInstanceOf( | |
615 | + | func eB (df) = { | |
616 | + | let eC = throw("Permission denied") | |
617 | + | let dq = ey() | |
618 | + | if ($isInstanceOf(dq, "ByteVector")) | |
623 | 619 | then { | |
624 | - | let | |
625 | - | if (( | |
620 | + | let eD = dq | |
621 | + | if ((df.callerPublicKey == eD)) | |
626 | 622 | then true | |
627 | - | else | |
623 | + | else eC | |
628 | 624 | } | |
629 | - | else if ($isInstanceOf( | |
630 | - | then if (( | |
625 | + | else if ($isInstanceOf(dq, "Unit")) | |
626 | + | then if ((df.caller == this)) | |
631 | 627 | then true | |
632 | - | else | |
628 | + | else eC | |
633 | 629 | else throw("Match error") | |
634 | 630 | } | |
635 | 631 | ||
636 | 632 | ||
637 | - | @Callable( | |
638 | - | func setManager ( | |
639 | - | let | |
640 | - | if (( | |
633 | + | @Callable(df) | |
634 | + | func setManager (eE) = { | |
635 | + | let eF = eB(df) | |
636 | + | if ((eF == eF)) | |
641 | 637 | then { | |
642 | - | let | |
643 | - | if (( | |
644 | - | then [StringEntry( | |
638 | + | let eG = fromBase58String(eE) | |
639 | + | if ((eG == eG)) | |
640 | + | then [StringEntry(R(), eE)] | |
645 | 641 | else throw("Strict value is not equal to itself.") | |
646 | 642 | } | |
647 | 643 | else throw("Strict value is not equal to itself.") | |
648 | 644 | } | |
649 | 645 | ||
650 | 646 | ||
651 | 647 | ||
652 | - | @Callable( | |
648 | + | @Callable(df) | |
653 | 649 | func confirmManager () = { | |
654 | - | let | |
655 | - | let | |
650 | + | let eH = eA() | |
651 | + | let eI = if (isDefined(eH)) | |
656 | 652 | then true | |
657 | 653 | else throw("No pending manager") | |
658 | - | if (( | |
654 | + | if ((eI == eI)) | |
659 | 655 | then { | |
660 | - | let | |
656 | + | let eJ = if ((df.callerPublicKey == value(eH))) | |
661 | 657 | then true | |
662 | 658 | else throw("You are not pending manager") | |
663 | - | if (( | |
664 | - | then [StringEntry( | |
659 | + | if ((eJ == eJ)) | |
660 | + | then [StringEntry(Q(), toBase58String(value(eH))), DeleteEntry(R())] | |
665 | 661 | else throw("Strict value is not equal to itself.") | |
666 | 662 | } | |
667 | 663 | else throw("Strict value is not equal to itself.") | |
668 | 664 | } | |
669 | 665 | ||
670 | 666 | ||
671 | 667 | ||
672 | - | @Callable( | |
673 | - | func put ( | |
668 | + | @Callable(df) | |
669 | + | func put (ck,eK) = if ((0 > ck)) | |
674 | 670 | then throw("Invalid slippageTolerance passed") | |
675 | 671 | else { | |
676 | - | let | |
677 | - | let | |
678 | - | let | |
679 | - | let | |
680 | - | let | |
681 | - | let | |
682 | - | let | |
683 | - | let | |
684 | - | let | |
685 | - | if (( | |
672 | + | let dl = di(df, ck, true) | |
673 | + | let cM = dl._2 | |
674 | + | let bR = dl._7 | |
675 | + | let ci = dl._9 | |
676 | + | let cN = dl._10 | |
677 | + | let cO = dl._11 | |
678 | + | let eL = dl._12 | |
679 | + | let eM = dl._13 | |
680 | + | let do = invoke(aD, "emit", [cM], nil) | |
681 | + | if ((do == do)) | |
686 | 682 | then { | |
687 | - | let | |
688 | - | let | |
689 | - | if ($isInstanceOf( | |
683 | + | let dp = { | |
684 | + | let dq = do | |
685 | + | if ($isInstanceOf(dq, "Address")) | |
690 | 686 | then { | |
691 | - | let | |
692 | - | invoke( | |
687 | + | let dr = dq | |
688 | + | invoke(dr, "emit", [cM], nil) | |
693 | 689 | } | |
694 | 690 | else unit | |
695 | 691 | } | |
696 | - | if (( | |
692 | + | if ((dp == dp)) | |
697 | 693 | then { | |
698 | - | let | |
699 | - | then invoke( | |
694 | + | let eN = if ((cN > 0)) | |
695 | + | then invoke(ba, "put", nil, [AttachedPayment(eL, cN)]) | |
700 | 696 | else nil | |
701 | - | if (( | |
697 | + | if ((eN == eN)) | |
702 | 698 | then { | |
703 | - | let | |
704 | - | then invoke( | |
699 | + | let eO = if ((cO > 0)) | |
700 | + | then invoke(ba, "put", nil, [AttachedPayment(eM, cO)]) | |
705 | 701 | else nil | |
706 | - | if (( | |
702 | + | if ((eO == eO)) | |
707 | 703 | then { | |
708 | - | let | |
704 | + | let eP = if (eK) | |
709 | 705 | then { | |
710 | - | let | |
711 | - | if (( | |
706 | + | let eQ = invoke(aZ, "stake", nil, [AttachedPayment(bR, cM)]) | |
707 | + | if ((eQ == eQ)) | |
712 | 708 | then nil | |
713 | 709 | else throw("Strict value is not equal to itself.") | |
714 | 710 | } | |
715 | - | else [ScriptTransfer( | |
716 | - | ( | |
711 | + | else [ScriptTransfer(df.caller, cM, bR)] | |
712 | + | (ci ++ eP) | |
717 | 713 | } | |
718 | 714 | else throw("Strict value is not equal to itself.") | |
719 | 715 | } | |
720 | 716 | else throw("Strict value is not equal to itself.") | |
721 | 717 | } | |
722 | 718 | else throw("Strict value is not equal to itself.") | |
723 | 719 | } | |
724 | 720 | else throw("Strict value is not equal to itself.") | |
725 | 721 | } | |
726 | 722 | ||
727 | 723 | ||
728 | 724 | ||
729 | - | @Callable( | |
730 | - | func putForFree ( | |
725 | + | @Callable(df) | |
726 | + | func putForFree (eR) = if ((0 > eR)) | |
731 | 727 | then throw("Invalid value passed") | |
732 | 728 | else { | |
733 | - | let | |
734 | - | | |
729 | + | let dl = di(df, eR, false) | |
730 | + | dl._9 | |
735 | 731 | } | |
736 | 732 | ||
737 | 733 | ||
738 | 734 | ||
739 | - | @Callable( | |
740 | - | func putOneTkn ( | |
741 | - | let | |
735 | + | @Callable(df) | |
736 | + | func putOneTkn (eS,eT) = { | |
737 | + | let eU = if (if (aF()) | |
742 | 738 | then true | |
743 | - | else ( | |
739 | + | else (aS == l)) | |
744 | 740 | then true | |
745 | - | else ( | |
746 | - | let | |
741 | + | else (aS == n) | |
742 | + | let ei = [if (!(eU)) | |
747 | 743 | then true | |
748 | - | else | |
744 | + | else aB("put operation is blocked by admin"), if ((size(df.payments) == 1)) | |
749 | 745 | then true | |
750 | - | else | |
751 | - | if (( | |
746 | + | else aB("exactly 1 payment are expected")] | |
747 | + | if ((ei == ei)) | |
752 | 748 | then { | |
753 | - | let | |
754 | - | let | |
755 | - | let | |
756 | - | let | |
757 | - | let | |
758 | - | let | |
759 | - | let | |
760 | - | let | |
761 | - | let | |
762 | - | let | |
763 | - | let | |
764 | - | then ( | |
749 | + | let eV = df.payments[0] | |
750 | + | let dw = eV.assetId | |
751 | + | let dv = eV.amount | |
752 | + | let X = df.caller | |
753 | + | let Y = df.transactionId | |
754 | + | let eW = du(dv, dw, X, Y) | |
755 | + | let eX = eW._1 | |
756 | + | let cP = eW._2 | |
757 | + | let dt = eW._3 | |
758 | + | let eY = eW._4 | |
759 | + | let eZ = if (if ((eS > 0)) | |
760 | + | then (eS > eX) | |
765 | 761 | else false) | |
766 | - | then | |
767 | - | else | |
768 | - | let | |
769 | - | if (( | |
762 | + | then aB(makeString(["amount to receive is less than ", toString(eS)], "")) | |
763 | + | else eX | |
764 | + | let do = dm(eZ) | |
765 | + | if ((do == do)) | |
770 | 766 | then { | |
771 | - | let | |
767 | + | let eP = if (eT) | |
772 | 768 | then { | |
773 | - | let | |
774 | - | if (( | |
769 | + | let fa = invoke(aZ, "stake", nil, [AttachedPayment(aT, eZ)]) | |
770 | + | if ((fa == fa)) | |
775 | 771 | then nil | |
776 | 772 | else throw("Strict value is not equal to itself.") | |
777 | 773 | } | |
778 | - | else [ScriptTransfer( | |
779 | - | let | |
780 | - | then [ScriptTransfer( | |
774 | + | else [ScriptTransfer(df.caller, eZ, aT)] | |
775 | + | let fb = if ((dt > 0)) | |
776 | + | then [ScriptTransfer(aE, dt, dw)] | |
781 | 777 | else nil | |
782 | - | $Tuple2((( | |
778 | + | $Tuple2(((cP ++ eP) ++ fb), eZ) | |
783 | 779 | } | |
784 | 780 | else throw("Strict value is not equal to itself.") | |
785 | 781 | } | |
786 | 782 | else throw("Strict value is not equal to itself.") | |
787 | 783 | } | |
788 | 784 | ||
789 | 785 | ||
790 | 786 | ||
791 | - | @Callable( | |
792 | - | func putOneTknREADONLY (dv | |
793 | - | let | |
794 | - | let | |
795 | - | let | |
796 | - | let | |
797 | - | let | |
798 | - | $Tuple2(nil, $Tuple3( | |
787 | + | @Callable(df) | |
788 | + | func putOneTknREADONLY (dw,dv) = { | |
789 | + | let fc = du(dv, aK(dw), unit, unit) | |
790 | + | let eX = fc._1 | |
791 | + | let cP = fc._2 | |
792 | + | let dt = fc._3 | |
793 | + | let eY = fc._4 | |
794 | + | $Tuple2(nil, $Tuple3(eX, dt, eY)) | |
799 | 795 | } | |
800 | 796 | ||
801 | 797 | ||
802 | 798 | ||
803 | - | @Callable( | |
804 | - | func getOneTkn ( | |
805 | - | let | |
799 | + | @Callable(df) | |
800 | + | func getOneTkn (fd,eS) = { | |
801 | + | let fe = if (aF()) | |
806 | 802 | then true | |
807 | - | else ( | |
808 | - | let | |
803 | + | else (aS == n) | |
804 | + | let ei = [if (!(fe)) | |
809 | 805 | then true | |
810 | - | else | |
806 | + | else aB("get operation is blocked by admin"), if ((size(df.payments) == 1)) | |
811 | 807 | then true | |
812 | - | else | |
813 | - | if (( | |
808 | + | else aB("exactly 1 payment are expected")] | |
809 | + | if ((ei == ei)) | |
814 | 810 | then { | |
815 | - | let | |
816 | - | let | |
817 | - | let | |
818 | - | let | |
819 | - | let | |
820 | - | let | |
821 | - | let | |
822 | - | let | |
823 | - | let | |
824 | - | let | |
825 | - | let | |
826 | - | let | |
827 | - | then ( | |
811 | + | let ee = aK(fd) | |
812 | + | let eV = df.payments[0] | |
813 | + | let dw = eV.assetId | |
814 | + | let dP = eV.amount | |
815 | + | let X = df.caller | |
816 | + | let Y = df.transactionId | |
817 | + | let ff = ed(ee, dP, dw, X, Y) | |
818 | + | let fg = ff._1 | |
819 | + | let cP = ff._2 | |
820 | + | let dt = ff._3 | |
821 | + | let eY = ff._4 | |
822 | + | let dn = if (if ((eS > 0)) | |
823 | + | then (eS > fg) | |
828 | 824 | else false) | |
829 | - | then | |
830 | - | else | |
831 | - | let | |
832 | - | if (( | |
825 | + | then aB(makeString(["amount to receive is less than ", toString(eS)], "")) | |
826 | + | else fg | |
827 | + | let fh = invoke(aD, "burn", [dP], [AttachedPayment(dw, dP)]) | |
828 | + | if ((fh == fh)) | |
833 | 829 | then { | |
834 | - | let | |
835 | - | let | |
836 | - | then [ScriptTransfer( | |
830 | + | let fi = [ScriptTransfer(X, dn, ee)] | |
831 | + | let fb = if ((dt > 0)) | |
832 | + | then [ScriptTransfer(aE, dt, ee)] | |
837 | 833 | else nil | |
838 | - | $Tuple2((( | |
834 | + | $Tuple2(((cP ++ fi) ++ fb), dn) | |
839 | 835 | } | |
840 | 836 | else throw("Strict value is not equal to itself.") | |
841 | 837 | } | |
842 | 838 | else throw("Strict value is not equal to itself.") | |
843 | 839 | } | |
844 | 840 | ||
845 | 841 | ||
846 | 842 | ||
847 | - | @Callable( | |
848 | - | func getOneTknREADONLY ( | |
849 | - | let | |
850 | - | let | |
851 | - | let | |
852 | - | let | |
853 | - | let | |
854 | - | $Tuple2(nil, $Tuple3( | |
843 | + | @Callable(df) | |
844 | + | func getOneTknREADONLY (ee,dP) = { | |
845 | + | let fj = ed(aK(ee), dP, aT, unit, unit) | |
846 | + | let fg = fj._1 | |
847 | + | let cP = fj._2 | |
848 | + | let dt = fj._3 | |
849 | + | let eY = fj._4 | |
850 | + | $Tuple2(nil, $Tuple3(fg, dt, eY)) | |
855 | 851 | } | |
856 | 852 | ||
857 | 853 | ||
858 | 854 | ||
859 | - | @Callable( | |
860 | - | func unstakeAndGetOneTkn ( | |
861 | - | let | |
855 | + | @Callable(df) | |
856 | + | func unstakeAndGetOneTkn (fk,fd,eS) = { | |
857 | + | let fe = if (aF()) | |
862 | 858 | then true | |
863 | - | else ( | |
864 | - | let | |
859 | + | else (aS == n) | |
860 | + | let ei = [if (!(fe)) | |
865 | 861 | then true | |
866 | - | else | |
862 | + | else aB("get operation is blocked by admin"), if ((size(df.payments) == 0)) | |
867 | 863 | then true | |
868 | - | else | |
869 | - | if (( | |
864 | + | else aB("no payments are expected")] | |
865 | + | if ((ei == ei)) | |
870 | 866 | then { | |
871 | - | let | |
872 | - | let | |
873 | - | if (( | |
867 | + | let ee = aK(fd) | |
868 | + | let fl = invoke(aZ, "unstake", [toBase58String(aT), fk], nil) | |
869 | + | if ((fl == fl)) | |
874 | 870 | then { | |
875 | - | let | |
876 | - | let | |
877 | - | let | |
878 | - | let | |
879 | - | let | |
880 | - | let | |
881 | - | then ( | |
871 | + | let fm = ed(ee, fk, aT, unit, unit) | |
872 | + | let fg = fm._1 | |
873 | + | let cP = fm._2 | |
874 | + | let dt = fm._3 | |
875 | + | let eY = fm._4 | |
876 | + | let dn = if (if ((eS > 0)) | |
877 | + | then (eS > fg) | |
882 | 878 | else false) | |
883 | - | then | |
884 | - | else | |
885 | - | let | |
886 | - | if (( | |
879 | + | then aB(makeString(["amount to receive is less than ", toString(eS)], "")) | |
880 | + | else fg | |
881 | + | let fh = invoke(aD, "burn", [fk], [AttachedPayment(aT, fk)]) | |
882 | + | if ((fh == fh)) | |
887 | 883 | then { | |
888 | - | let | |
889 | - | let | |
890 | - | then [ScriptTransfer( | |
884 | + | let fi = [ScriptTransfer(df.caller, dn, ee)] | |
885 | + | let fb = if ((dt > 0)) | |
886 | + | then [ScriptTransfer(aE, dt, ee)] | |
891 | 887 | else nil | |
892 | - | $Tuple2((( | |
888 | + | $Tuple2(((cP ++ fi) ++ fb), dn) | |
893 | 889 | } | |
894 | 890 | else throw("Strict value is not equal to itself.") | |
895 | 891 | } | |
896 | 892 | else throw("Strict value is not equal to itself.") | |
897 | 893 | } | |
898 | 894 | else throw("Strict value is not equal to itself.") | |
899 | 895 | } | |
900 | 896 | ||
901 | 897 | ||
902 | 898 | ||
903 | - | @Callable( | |
899 | + | @Callable(df) | |
904 | 900 | func get () = { | |
905 | - | let | |
906 | - | let | |
907 | - | let | |
908 | - | let | |
909 | - | let | |
910 | - | let | |
911 | - | let | |
912 | - | if (( | |
913 | - | then | |
901 | + | let cA = de(df) | |
902 | + | let fn = cA._1 | |
903 | + | let ch = cA._2 | |
904 | + | let dh = cA._3 | |
905 | + | let bP = cA._4 | |
906 | + | let ci = cA._5 | |
907 | + | let fo = invoke(aD, "burn", [dh], [AttachedPayment(bP, dh)]) | |
908 | + | if ((fo == fo)) | |
909 | + | then ci | |
914 | 910 | else throw("Strict value is not equal to itself.") | |
915 | 911 | } | |
916 | 912 | ||
917 | 913 | ||
918 | 914 | ||
919 | - | @Callable( | |
920 | - | func getNoLess (fq | |
921 | - | let | |
922 | - | let | |
923 | - | let | |
924 | - | let | |
925 | - | let | |
926 | - | let | |
927 | - | if (( | |
928 | - | then throw(((("noLessThenAmtAsset failed: " + toString( | |
929 | - | else if (( | |
930 | - | then throw(((("noLessThenPriceAsset failed: " + toString( | |
915 | + | @Callable(df) | |
916 | + | func getNoLess (fp,fq) = { | |
917 | + | let cA = de(df) | |
918 | + | let cg = cA._1 | |
919 | + | let ch = cA._2 | |
920 | + | let dh = cA._3 | |
921 | + | let bP = cA._4 | |
922 | + | let ci = cA._5 | |
923 | + | if ((fp > cg)) | |
924 | + | then throw(((("noLessThenAmtAsset failed: " + toString(cg)) + " < ") + toString(fp))) | |
925 | + | else if ((fq > ch)) | |
926 | + | then throw(((("noLessThenPriceAsset failed: " + toString(ch)) + " < ") + toString(fq))) | |
931 | 927 | else { | |
932 | - | let | |
933 | - | if (( | |
934 | - | then | |
928 | + | let fo = invoke(aD, "burn", [dh], [AttachedPayment(bP, dh)]) | |
929 | + | if ((fo == fo)) | |
930 | + | then ci | |
935 | 931 | else throw("Strict value is not equal to itself.") | |
936 | 932 | } | |
937 | 933 | } | |
938 | 934 | ||
939 | 935 | ||
940 | 936 | ||
941 | - | @Callable( | |
942 | - | func unstakeAndGet ( | |
943 | - | let | |
937 | + | @Callable(df) | |
938 | + | func unstakeAndGet (dn) = { | |
939 | + | let fr = if ((size(df.payments) != 0)) | |
944 | 940 | then throw("No payments are expected") | |
945 | 941 | else true | |
946 | - | if (( | |
942 | + | if ((fr == fr)) | |
947 | 943 | then { | |
948 | - | let | |
949 | - | let | |
950 | - | let | |
951 | - | if (( | |
944 | + | let bE = aH() | |
945 | + | let bR = fromBase58String(bE[q]) | |
946 | + | let fl = invoke(aZ, "unstake", [toBase58String(bR), dn], nil) | |
947 | + | if ((fl == fl)) | |
952 | 948 | then { | |
953 | - | let | |
954 | - | let | |
955 | - | let | |
956 | - | let | |
949 | + | let cA = bN(toBase58String(df.transactionId), toBase58String(bR), dn, df.caller) | |
950 | + | let bU = parseIntValue(cA._9) | |
951 | + | let ci = cA._10 | |
952 | + | let fs = if (if (aF()) | |
957 | 953 | then true | |
958 | - | else ( | |
959 | - | then throw(("Get operation is blocked by admin. Status = " + toString( | |
954 | + | else (bU == n)) | |
955 | + | then throw(("Get operation is blocked by admin. Status = " + toString(bU))) | |
960 | 956 | else true | |
961 | - | if (( | |
957 | + | if ((fs == fs)) | |
962 | 958 | then { | |
963 | - | let | |
964 | - | if (( | |
965 | - | then | |
959 | + | let fo = invoke(aD, "burn", [dn], [AttachedPayment(bR, dn)]) | |
960 | + | if ((fo == fo)) | |
961 | + | then ci | |
966 | 962 | else throw("Strict value is not equal to itself.") | |
967 | 963 | } | |
968 | 964 | else throw("Strict value is not equal to itself.") | |
969 | 965 | } | |
970 | 966 | else throw("Strict value is not equal to itself.") | |
971 | 967 | } | |
972 | 968 | else throw("Strict value is not equal to itself.") | |
973 | 969 | } | |
974 | 970 | ||
975 | 971 | ||
976 | 972 | ||
977 | - | @Callable( | |
978 | - | func activate (fu | |
973 | + | @Callable(df) | |
974 | + | func activate (ft,fu) = if ((toString(df.caller) != toString(aD))) | |
979 | 975 | then throw("permissions denied") | |
980 | - | else $Tuple2([StringEntry( | |
976 | + | else $Tuple2([StringEntry(aa(), ft), StringEntry(ab(), fu)], "success") | |
981 | 977 | ||
982 | 978 | ||
983 | 979 | ||
984 | - | @Callable( | |
985 | - | func getPoolConfigWrapperREADONLY () = $Tuple2(nil, | |
980 | + | @Callable(df) | |
981 | + | func getPoolConfigWrapperREADONLY () = $Tuple2(nil, aH()) | |
986 | 982 | ||
987 | 983 | ||
988 | 984 | ||
989 | - | @Callable( | |
990 | - | func getAccBalanceWrapperREADONLY ( | |
985 | + | @Callable(df) | |
986 | + | func getAccBalanceWrapperREADONLY (br) = $Tuple2(nil, bq(br)) | |
991 | 987 | ||
992 | 988 | ||
993 | 989 | ||
994 | - | @Callable( | |
995 | - | func calcPricesWrapperREADONLY ( | |
996 | - | let | |
997 | - | $Tuple2(nil, [toString( | |
990 | + | @Callable(df) | |
991 | + | func calcPricesWrapperREADONLY (by,bz,bD) = { | |
992 | + | let bM = bC(by, bz, bD) | |
993 | + | $Tuple2(nil, [toString(bM[0]), toString(bM[1]), toString(bM[2])]) | |
998 | 994 | } | |
999 | 995 | ||
1000 | 996 | ||
1001 | 997 | ||
1002 | - | @Callable( | |
998 | + | @Callable(df) | |
1003 | 999 | func toX18WrapperREADONLY (E,F) = $Tuple2(nil, toString(D(E, F))) | |
1004 | 1000 | ||
1005 | 1001 | ||
1006 | 1002 | ||
1007 | - | @Callable( | |
1003 | + | @Callable(df) | |
1008 | 1004 | func fromX18WrapperREADONLY (H,I) = $Tuple2(nil, G(parseBigIntValue(H), I)) | |
1009 | 1005 | ||
1010 | 1006 | ||
1011 | 1007 | ||
1012 | - | @Callable( | |
1013 | - | func calcPriceBigIntWrapperREADONLY ( | |
1008 | + | @Callable(df) | |
1009 | + | func calcPriceBigIntWrapperREADONLY (bt,bu) = $Tuple2(nil, toString(bs(parseBigIntValue(bt), parseBigIntValue(bu)))) | |
1014 | 1010 | ||
1015 | 1011 | ||
1016 | 1012 | ||
1017 | - | @Callable( | |
1018 | - | func estimatePutOperationWrapperREADONLY ( | |
1013 | + | @Callable(df) | |
1014 | + | func estimatePutOperationWrapperREADONLY (bO,ck,cl,cm,cn,co,X,cp,cq) = $Tuple2(nil, cj(bO, ck, cl, cm, cn, co, X, cp, cq)) | |
1019 | 1015 | ||
1020 | 1016 | ||
1021 | 1017 | ||
1022 | - | @Callable( | |
1023 | - | func estimateGetOperationWrapperREADONLY ( | |
1024 | - | let | |
1025 | - | $Tuple2(nil, $Tuple10( | |
1018 | + | @Callable(df) | |
1019 | + | func estimateGetOperationWrapperREADONLY (bO,bP,bQ,X) = { | |
1020 | + | let cA = bN(bO, bP, bQ, addressFromStringValue(X)) | |
1021 | + | $Tuple2(nil, $Tuple10(cA._1, cA._2, cA._3, cA._4, cA._5, cA._6, cA._7, toString(cA._8), cA._9, cA._10)) | |
1026 | 1022 | } | |
1027 | 1023 | ||
1028 | 1024 | ||
1029 | 1025 | ||
1030 | - | @Callable( | |
1026 | + | @Callable(df) | |
1031 | 1027 | func statsREADONLY () = { | |
1032 | - | let | |
1033 | - | let | |
1034 | - | let | |
1035 | - | let | |
1036 | - | let | |
1037 | - | let | |
1038 | - | let | |
1039 | - | let | |
1040 | - | let | |
1041 | - | let | |
1042 | - | let | |
1043 | - | let | |
1028 | + | let bE = aH() | |
1029 | + | let bR = fromBase58String(bE[q]) | |
1030 | + | let cS = bE[r] | |
1031 | + | let cT = bE[s] | |
1032 | + | let ct = bE[v] | |
1033 | + | let cu = bE[w] | |
1034 | + | let bF = parseIntValue(bE[t]) | |
1035 | + | let bG = parseIntValue(bE[u]) | |
1036 | + | let fv = valueOrErrorMessage(assetInfo(bR), (("Asset " + toBase58String(bR)) + " doesn't exist")).quantity | |
1037 | + | let cU = bq(cS) | |
1038 | + | let cV = bq(cT) | |
1039 | + | let fw = if ((fv == 0)) | |
1044 | 1040 | then [e, e, e] | |
1045 | - | else | |
1046 | - | let | |
1047 | - | let | |
1048 | - | let | |
1049 | - | let | |
1050 | - | $Tuple2(nil, makeString(["%d%d%d%d%d%d%d", toString( | |
1041 | + | else bC(cU, cV, fv) | |
1042 | + | let cb = 0 | |
1043 | + | let fx = G(fw[1], b) | |
1044 | + | let fy = G(fw[2], b) | |
1045 | + | let fz = value(getInteger(aD, ap(toString(this)))) | |
1046 | + | $Tuple2(nil, makeString(["%d%d%d%d%d%d%d", toString(cU), toString(cV), toString(fv), toString(cb), toString(fx), toString(fy), toString(fz)], j)) | |
1051 | 1047 | } | |
1052 | 1048 | ||
1053 | 1049 | ||
1054 | 1050 | ||
1055 | - | @Callable(de) | |
1056 | - | func evaluatePutByAmountAssetREADONLY (ck) = { | |
1057 | - | let bD = aG() | |
1058 | - | let bQ = fromBase58String(bD[q]) | |
1059 | - | let cq = bD[r] | |
1060 | - | let bR = fromBase58String(cq) | |
1061 | - | let cr = bD[s] | |
1051 | + | @Callable(df) | |
1052 | + | func evaluatePutByAmountAssetREADONLY (cl) = { | |
1053 | + | let bE = aH() | |
1054 | + | let bR = fromBase58String(bE[q]) | |
1055 | + | let cr = bE[r] | |
1062 | 1056 | let bS = fromBase58String(cr) | |
1063 | - | let bE = parseIntValue(bD[t]) | |
1064 | - | let bF = parseIntValue(bD[u]) | |
1065 | - | let bT = bD[p] | |
1066 | - | let fw = valueOrErrorMessage(assetInfo(bQ), (("Asset " + toBase58String(bQ)) + " doesn't exist")).quantity | |
1067 | - | let cT = bp(cq) | |
1068 | - | let cU = bp(cr) | |
1069 | - | let bz = D(cT, bE) | |
1057 | + | let cs = bE[s] | |
1058 | + | let bT = fromBase58String(cs) | |
1059 | + | let bF = parseIntValue(bE[t]) | |
1060 | + | let bG = parseIntValue(bE[u]) | |
1061 | + | let bU = bE[p] | |
1062 | + | let fv = valueOrErrorMessage(assetInfo(bR), (("Asset " + toBase58String(bR)) + " doesn't exist")).quantity | |
1063 | + | let cU = bq(cr) | |
1064 | + | let cV = bq(cs) | |
1070 | 1065 | let bA = D(cU, bF) | |
1071 | - | let bZ = if ((fw == 0)) | |
1066 | + | let bB = D(cV, bG) | |
1067 | + | let ca = if ((fv == 0)) | |
1072 | 1068 | then e | |
1073 | - | else | |
1074 | - | let | |
1075 | - | let | |
1076 | - | let | |
1077 | - | let | |
1078 | - | let | |
1079 | - | let | |
1080 | - | let | |
1081 | - | let | |
1082 | - | let | |
1083 | - | $Tuple2(nil, makeString(["%d%d%d%d%d%d%d%d", toString( | |
1069 | + | else bs(bB, bA) | |
1070 | + | let cx = D(cl, bF) | |
1071 | + | let cy = fraction(cx, ca, d) | |
1072 | + | let cn = G(cy, bG) | |
1073 | + | let dl = cj("", 500000, cl, bS, cn, bT, "", true, false) | |
1074 | + | let cI = dl._1 | |
1075 | + | let fA = dl._3 | |
1076 | + | let bW = dl._4 | |
1077 | + | let bY = dl._5 | |
1078 | + | let bV = dl._6 | |
1079 | + | $Tuple2(nil, makeString(["%d%d%d%d%d%d%d%d", toString(cI), toString(G(ca, b)), toString(bW), toString(bY), toString(bV), bU, toString(cl), toString(cn)], j)) | |
1084 | 1080 | } | |
1085 | 1081 | ||
1086 | 1082 | ||
1087 | 1083 | ||
1088 | - | @Callable(de) | |
1089 | - | func evaluatePutByPriceAssetREADONLY (cm) = { | |
1090 | - | let bD = aG() | |
1091 | - | let bQ = fromBase58String(bD[q]) | |
1092 | - | let cq = bD[r] | |
1093 | - | let bR = fromBase58String(cq) | |
1094 | - | let cr = bD[s] | |
1084 | + | @Callable(df) | |
1085 | + | func evaluatePutByPriceAssetREADONLY (cn) = { | |
1086 | + | let bE = aH() | |
1087 | + | let bR = fromBase58String(bE[q]) | |
1088 | + | let cr = bE[r] | |
1095 | 1089 | let bS = fromBase58String(cr) | |
1096 | - | let bE = parseIntValue(bD[t]) | |
1097 | - | let bF = parseIntValue(bD[u]) | |
1098 | - | let bT = bD[p] | |
1099 | - | let fw = valueOrErrorMessage(assetInfo(bQ), (("Asset " + toBase58String(bQ)) + " doesn't exist")).quantity | |
1100 | - | let fC = bp(cq) | |
1101 | - | let fD = bp(cr) | |
1102 | - | let fE = D(fC, bE) | |
1103 | - | let fF = D(fD, bF) | |
1104 | - | let bZ = if ((fw == 0)) | |
1090 | + | let cs = bE[s] | |
1091 | + | let bT = fromBase58String(cs) | |
1092 | + | let bF = parseIntValue(bE[t]) | |
1093 | + | let bG = parseIntValue(bE[u]) | |
1094 | + | let bU = bE[p] | |
1095 | + | let fv = valueOrErrorMessage(assetInfo(bR), (("Asset " + toBase58String(bR)) + " doesn't exist")).quantity | |
1096 | + | let fB = bq(cr) | |
1097 | + | let fC = bq(cs) | |
1098 | + | let fD = D(fB, bF) | |
1099 | + | let fE = D(fC, bG) | |
1100 | + | let ca = if ((fv == 0)) | |
1105 | 1101 | then e | |
1106 | - | else | |
1107 | - | let | |
1108 | - | let | |
1109 | - | let | |
1110 | - | let | |
1111 | - | let | |
1112 | - | let | |
1113 | - | let | |
1114 | - | let | |
1115 | - | let | |
1116 | - | $Tuple2(nil, makeString(["%d%d%d%d%d%d%d%d", toString( | |
1102 | + | else bs(fE, fD) | |
1103 | + | let cy = D(cn, bG) | |
1104 | + | let cx = fraction(cy, d, ca) | |
1105 | + | let cl = G(cx, bF) | |
1106 | + | let dl = cj("", 500000, cl, bS, cn, bT, "", true, false) | |
1107 | + | let cI = dl._1 | |
1108 | + | let fA = dl._3 | |
1109 | + | let bW = dl._4 | |
1110 | + | let bY = dl._5 | |
1111 | + | let bV = dl._6 | |
1112 | + | $Tuple2(nil, makeString(["%d%d%d%d%d%d%d%d", toString(cI), toString(G(ca, b)), toString(bW), toString(bY), toString(bV), bU, toString(cl), toString(cn)], j)) | |
1117 | 1113 | } | |
1118 | 1114 | ||
1119 | 1115 | ||
1120 | 1116 | ||
1121 | - | @Callable( | |
1122 | - | func evaluateGetREADONLY (fG | |
1123 | - | let | |
1124 | - | let | |
1125 | - | let | |
1126 | - | let | |
1127 | - | let | |
1128 | - | let | |
1129 | - | let | |
1130 | - | let | |
1131 | - | $Tuple2(nil, makeString(["%d%d%d%d%d%d%d", toString( | |
1117 | + | @Callable(df) | |
1118 | + | func evaluateGetREADONLY (fF,fG) = { | |
1119 | + | let cA = bN("", fF, fG, this) | |
1120 | + | let cg = cA._1 | |
1121 | + | let ch = cA._2 | |
1122 | + | let bW = cA._5 | |
1123 | + | let bY = cA._6 | |
1124 | + | let bV = cA._7 | |
1125 | + | let cb = cA._8 | |
1126 | + | let bU = parseIntValue(cA._9) | |
1127 | + | $Tuple2(nil, makeString(["%d%d%d%d%d%d%d", toString(cg), toString(ch), toString(bW), toString(bY), toString(bV), toString(cb), toString(bU)], j)) | |
1132 | 1128 | } | |
1133 | 1129 | ||
1134 | 1130 | ||
1135 | - | @Verifier( | |
1136 | - | func | |
1137 | - | let | |
1138 | - | let | |
1139 | - | if ($isInstanceOf( | |
1131 | + | @Verifier(fH) | |
1132 | + | func fI () = { | |
1133 | + | let fJ = { | |
1134 | + | let dq = ey() | |
1135 | + | if ($isInstanceOf(dq, "ByteVector")) | |
1140 | 1136 | then { | |
1141 | - | let | |
1142 | - | | |
1137 | + | let eD = dq | |
1138 | + | eD | |
1143 | 1139 | } | |
1144 | - | else if ($isInstanceOf( | |
1145 | - | then | |
1140 | + | else if ($isInstanceOf(dq, "Unit")) | |
1141 | + | then fH.senderPublicKey | |
1146 | 1142 | else throw("Match error") | |
1147 | 1143 | } | |
1148 | - | let | |
1149 | - | if ($isInstanceOf( | |
1144 | + | let dq = fH | |
1145 | + | if ($isInstanceOf(dq, "Order")) | |
1150 | 1146 | then { | |
1151 | - | let cQ = dp | |
1152 | - | let fL = aF() | |
1153 | - | let at = cP(cQ) | |
1154 | - | let au = sigVerify(cQ.bodyBytes, cQ.proofs[0], cQ.senderPublicKey) | |
1155 | - | let av = sigVerify(cQ.bodyBytes, cQ.proofs[1], fL) | |
1156 | - | if (if (if (at) | |
1157 | - | then au | |
1158 | - | else false) | |
1147 | + | let cR = dq | |
1148 | + | let fK = aG() | |
1149 | + | let au = cQ(cR) | |
1150 | + | let av = sigVerify(cR.bodyBytes, cR.proofs[0], cR.senderPublicKey) | |
1151 | + | let aw = sigVerify(cR.bodyBytes, cR.proofs[1], fK) | |
1152 | + | if (if (if (au) | |
1159 | 1153 | then av | |
1160 | 1154 | else false) | |
1155 | + | then aw | |
1156 | + | else false) | |
1161 | 1157 | then true | |
1162 | - | else | |
1158 | + | else at(au, av, aw) | |
1163 | 1159 | } | |
1164 | - | else if ($isInstanceOf( | |
1160 | + | else if ($isInstanceOf(dq, "SetScriptTransaction")) | |
1165 | 1161 | then { | |
1166 | - | let | |
1167 | - | let | |
1168 | - | let | |
1169 | - | let | |
1170 | - | if (if (( | |
1171 | - | then ( | |
1162 | + | let ez = dq | |
1163 | + | let fL = blake2b256(value(ez.script)) | |
1164 | + | let fM = fromBase64String(value(getString(aD, ar()))) | |
1165 | + | let fN = scriptHash(this) | |
1166 | + | if (if ((fM == fL)) | |
1167 | + | then (fN != fL) | |
1172 | 1168 | else false) | |
1173 | 1169 | then true | |
1174 | - | else sigVerify( | |
1170 | + | else sigVerify(fH.bodyBytes, fH.proofs[0], fJ) | |
1175 | 1171 | } | |
1176 | - | else sigVerify( | |
1172 | + | else sigVerify(fH.bodyBytes, fH.proofs[0], fJ) | |
1177 | 1173 | } | |
1178 | 1174 |
github/deemru/w8io/026f985 453.97 ms ◑