tx · 6h3E6j1Q4XoBzDFWnCPJbWtLALLsWPh2tP7bD1Tdj8WL

3N9KXr9JbnPwrN9oacmFjc3qB4tYrzvxWss:  -0.03100000 Waves

2023.01.18 14:42 [2410326] smart account 3N9KXr9JbnPwrN9oacmFjc3qB4tYrzvxWss > SELF 0.00000000 Waves

{ "type": 13, "id": "6h3E6j1Q4XoBzDFWnCPJbWtLALLsWPh2tP7bD1Tdj8WL", "fee": 3100000, "feeAssetId": null, "timestamp": 1674042099710, "version": 1, "sender": "3N9KXr9JbnPwrN9oacmFjc3qB4tYrzvxWss", "senderPublicKey": "CuH6mrgac4GztriBQFELtAx7gw4diUcD94EVLt78E1kt", "proofs": [ "TwZbjuTFfL23jpALoZyQprTpsEMdUmyN63CTTHGN9Vx7wHhxdRHgwLhirQwcKro2CwMR8aQtbQjmBN3AGzMwYEg" ], "script": "base64:BgK3JwgCEgMKAQgSABIECgIBBBIDCgEBEgQKAgEEEgQKAggBEgQKAggBEgQKAggBEgUKAwEIARIAEgQKAgEBEgMKAQESBQoDAQEBEgQKAggIEgASAwoBCBIFCgMBAQESBAoCAQESBAoCCAESBAoCCAgSCwoJCAEBAgECCAQEEgYKBAgIAQgSABIDCgEBEgMKAQESBAoCCAEiCmxQZGVjaW1hbHMiBnNjYWxlOCIMc2NhbGU4QmlnSW50IgdzY2FsZTE4Igp6ZXJvQmlnSW50IgRiaWcwIgRiaWcxIgRiaWcyIgt3YXZlc1N0cmluZyIDU0VQIgpQb29sQWN0aXZlIg9Qb29sUHV0RGlzYWJsZWQiE1Bvb2xNYXRjaGVyRGlzYWJsZWQiDFBvb2xTaHV0ZG93biIOaWR4UG9vbEFkZHJlc3MiDWlkeFBvb2xTdGF0dXMiEGlkeFBvb2xMUEFzc2V0SWQiDWlkeEFtdEFzc2V0SWQiD2lkeFByaWNlQXNzZXRJZCIOaWR4QW10QXNzZXREY20iEGlkeFByaWNlQXNzZXREY20iDmlkeElBbXRBc3NldElkIhBpZHhJUHJpY2VBc3NldEl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J5dGVzCQCRAwIIBQJjUgZwcm9vZnMAAAgFAmNSD3NlbmRlclB1YmxpY0tleQQCYXQJAPQDAwgFAmNSCWJvZHlCeXRlcwkAkQMCCAUCY1IGcHJvb2ZzAAEFAmZMAwMDBQJhcgUCYXMHBQJhdAcGCQECYXEDBQJhcgUCYXMFAmF0AwkAAQIFAmRxAhRTZXRTY3JpcHRUcmFuc2FjdGlvbgQCZXcFAmRxBAJmTQkA9gMBCQEFdmFsdWUBCAUCZXcGc2NyaXB0BAJmTgkA2wQBCQEFdmFsdWUBCQCdCAIFAmFBCQECYW8ABAJmTwkA8QcBBQR0aGlzAwMJAAACBQJmTgUCZk0JAQIhPQIFAmZPBQJmTQcGCQD0AwMIBQJmSQlib2R5Qnl0ZXMJAJEDAggFAmZJBnByb29mcwAABQJmSwkA9AMDCAUCZkkJYm9keUJ5dGVzCQCRAwIIBQJmSQZwcm9vZnMAAAUCZkvBwFdz", "chainId": 84, "height": 2410326, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: CQzDT9Lcm3RgWg9wadbabmLeNr3CpaJtMgEAdPMjFpfK Next: 6orRREUD5yMiE2kNkrLxsHj11qVHyofofZk6ZeCr217m Diff:
OldNewDifferences
7878 else H
7979
8080
81-func P () = "%s__swapContract"
81+func P () = "%s__factoryContract"
8282
8383
84-func Q () = "%s__factoryContract"
84+func Q () = "%s__managerPublicKey"
8585
8686
87-func R () = "%s__managerPublicKey"
87+func R () = "%s__pendingManagerPublicKey"
8888
8989
90-func S () = "%s__pendingManagerPublicKey"
90+func S () = "%s%s__price__last"
9191
9292
93-func T () = "%s%s__price__last"
93+func T (U,V) = makeString(["%s%s%d%d__price__history", toString(U), toString(V)], j)
9494
9595
96-func U (V,W) = makeString(["%s%s%d%d__price__history", toString(V), toString(W)], j)
96+func W (X,Y) = ((("%s%s%s__P__" + X) + "__") + Y)
9797
9898
99-func X (Y,Z) = ((("%s%s%s__P__" + Y) + "__") + Z)
99+func Z (X,Y) = ((("%s%s%s__G__" + X) + "__") + Y)
100100
101101
102-func aa (Y,Z) = ((("%s%s%s__G__" + Y) + "__") + Z)
102+func aa () = "%s__amountAsset"
103103
104104
105-func ab () = "%s__amountAsset"
105+func ab () = "%s__priceAsset"
106106
107107
108-func ac () = "%s__priceAsset"
108+func ac () = "%s__factoryConfig"
109109
110110
111-func ad () = "%s__factoryConfig"
111+func ad () = "%s%s__matcher__publicKey"
112112
113113
114-func ae () = "%s%s__matcher__publicKey"
114+func ae (af) = (("%s%s%s__" + af) + "__mappings__poolContract2LpAsset")
115115
116116
117-func af (ag) = (("%s%s%s__" + ag) + "__mappings__poolContract2LpAsset")
117+func ag (ah,ai) = (((("%d%d%s__" + ah) + "__") + ai) + "__config")
118118
119119
120-func ah (ai,aj) = (((("%d%d%s__" + ai) + "__") + aj) + "__config")
120+func aj (ak) = ("%s%s%s__mappings__baseAsset2internalId__" + ak)
121121
122122
123-func ak (al) = ("%s%s%s__mappings__baseAsset2internalId__" + al)
123+func al () = "%s__shutdown"
124124
125125
126-func am () = "%s__shutdown"
126+func am (an) = ("%s%s__poolWeight__" + an)
127127
128128
129-func an (ao) = ("%s%s__poolWeight__" + ao)
129+func ao () = "%s__allowedLpScriptHash"
130130
131131
132-func ap () = "%s__allowedLpScriptHash"
132+let ap = "%s__feeCollectorAddress"
133+
134+func aq (ar,as,at) = throw(((((("order validation failed: orderValid=" + toString(ar)) + " senderValid=") + toString(as)) + " matcherValid=") + toString(at)))
133135
134136
135-let aq = "%s__feeCollectorAddress"
136-
137-func ar (as,at,au) = throw(((((("order validation failed: orderValid=" + toString(as)) + " senderValid=") + toString(at)) + " matcherValid=") + toString(au)))
137+func au (av,aw) = valueOrErrorMessage(getString(av, aw), makeString(["mandatory ", toString(av), ".", aw, " is not defined"], ""))
138138
139139
140-func av (aw,ax) = valueOrErrorMessage(getString(aw, ax), makeString(["mandatory ", toString(aw), ".", ax, " is not defined"], ""))
140+func ax (av,aw) = valueOrErrorMessage(getInteger(av, aw), makeString(["mandatory ", toString(av), ".", aw, " is not defined"], ""))
141141
142142
143-func ay (aw,ax) = valueOrErrorMessage(getInteger(aw, ax), makeString(["mandatory ", toString(aw), ".", ax, " is not defined"], ""))
143+func ay (az) = throw(makeString(["lp.ride:", az], " "))
144144
145145
146-func az (aA) = throw(makeString(["lp.ride:", aA], " "))
146+let aA = addressFromStringValue(au(this, P()))
147+
148+let aB = addressFromStringValue(au(aA, ap))
149+
150+let aC = {
151+ let aD = invoke(aA, "getInFeeREADONLY", [toString(this)], nil)
152+ if ($isInstanceOf(aD, "Int"))
153+ then aD
154+ else throw(($getType(aD) + " couldn't be cast to Int"))
155+ }
156+
157+let aE = {
158+ let aD = invoke(aA, "getOutFeeREADONLY", [toString(this)], nil)
159+ if ($isInstanceOf(aD, "Int"))
160+ then aD
161+ else throw(($getType(aD) + " couldn't be cast to Int"))
162+ }
163+
164+func aF () = valueOrElse(getBoolean(aA, al()), false)
147165
148166
149-let aB = addressFromStringValue(av(this, Q()))
150-
151-let aC = addressFromStringValue(av(aB, aq))
152-
153-let aD = {
154- let aE = invoke(aB, "getInFeeREADONLY", [toString(this)], nil)
155- if ($isInstanceOf(aE, "Int"))
156- then aE
157- else throw(($getType(aE) + " couldn't be cast to Int"))
158- }
159-
160-let aF = {
161- let aE = invoke(aB, "getOutFeeREADONLY", [toString(this)], nil)
162- if ($isInstanceOf(aE, "Int"))
163- then aE
164- else throw(($getType(aE) + " couldn't be cast to Int"))
165- }
166-
167-func aG () = valueOrElse(getBoolean(aB, am()), false)
167+func aG () = fromBase58String(au(aA, ad()))
168168
169169
170-func aH () = fromBase58String(av(aB, ae()))
171-
172-
173-func aI () = {
174- let aJ = av(this, ab())
175- let aK = av(this, ac())
176- let aj = ay(aB, ak(aK))
177- let ai = ay(aB, ak(aJ))
178- split(av(aB, ah(toString(ai), toString(aj))), j)
170+func aH () = {
171+ let aI = au(this, aa())
172+ let aJ = au(this, ab())
173+ let ai = ax(aA, aj(aJ))
174+ let ah = ax(aA, aj(aI))
175+ split(au(aA, ag(toString(ah), toString(ai))), j)
179176 }
180177
181178
182-func aL (aM) = if ((aM == i))
179+func aK (aL) = if ((aL == i))
183180 then unit
184- else fromBase58String(aM)
181+ else fromBase58String(aL)
185182
186183
187-func aN (aM) = if ((aM == unit))
184+func aM (aL) = if ((aL == unit))
188185 then i
189- else toBase58String(value(aM))
186+ else toBase58String(value(aL))
190187
191188
192-func aO (aP) = $Tuple7(addressFromStringValue(aP[o]), parseIntValue(aP[p]), fromBase58String(aP[q]), aL(aP[r]), aL(aP[s]), parseIntValue(aP[t]), parseIntValue(aP[u]))
189+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]))
193190
194191
195-let aQ = aO(aI())
192+let aP = aN(aH())
196193
197-let aR = aQ
194+let aQ = aP
198195
199-let aS = aR._1
196+let aR = aQ._1
200197
201-let aT = aR._2
198+let aS = aQ._2
202199
203-let aU = aR._3
200+let aT = aQ._3
204201
205-let aV = aR._4
202+let aU = aQ._4
206203
207-let aW = aR._5
204+let aV = aQ._5
208205
209-let aX = aR._6
206+let aW = aQ._6
210207
211-let aY = aR._7
208+let aX = aQ._7
212209
213-func aZ () = split(av(aB, ad()), j)
210+func aY () = split(au(aA, ac()), j)
214211
215212
216-let ba = valueOrErrorMessage(addressFromString(aZ()[B]), "incorrect staking address")
213+let aZ = valueOrErrorMessage(addressFromString(aY()[B]), "incorrect staking address")
217214
218-let bb = valueOrErrorMessage(addressFromString(aZ()[C]), "incorrect staking address")
215+let ba = valueOrErrorMessage(addressFromString(aY()[C]), "incorrect staking address")
219216
220-func bc (bd,be,bf,bg,bh,bi,bj,bk,bl,bm) = makeString(["%d%d%d%d%d%d%d%d%d%d", toString(bd), toString(be), toString(bf), toString(bg), toString(bh), toString(bi), toString(bj), toString(bk), toString(bl), toString(bm)], j)
217+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)
221218
222219
223-func bn (bo,bp,bq,bg,bj,bk) = makeString(["%d%d%d%d%d%d", toString(bo), toString(bp), toString(bq), toString(bg), toString(bj), toString(bk)], j)
220+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)
224221
225222
226-func br (bs) = if ((bs == "WAVES"))
223+func bq (br) = if ((br == "WAVES"))
227224 then wavesBalance(this).available
228- else assetBalance(this, fromBase58String(bs))
225+ else assetBalance(this, fromBase58String(br))
229226
230227
231-func bt (bu,bv) = fraction(bu, d, bv)
228+func bs (bt,bu) = fraction(bt, d, bu)
232229
233230
234-func bw (bx,by,bz,bA) = {
231+func bv (bw,bx,by,bz) = {
232+ let bA = D(by, bw)
235233 let bB = D(bz, bx)
236- let bC = D(bA, by)
237- bt(bC, bB)
234+ bs(bB, bA)
238235 }
239236
240237
241-func bD (bz,bA,bE) = {
242- let bF = aI()
243- let bG = parseIntValue(bF[t])
244- let bH = parseIntValue(bF[u])
245- let bI = bw(bG, bH, bz, bA)
246- let bv = D(bz, bG)
247- let bu = D(bA, bH)
248- let bJ = D(bE, b)
249- let bK = bt(bv, bJ)
250- let bL = bt(bu, bJ)
251-[bI, bK, bL]
238+func bC (by,bz,bD) = {
239+ let bE = aH()
240+ let bF = parseIntValue(bE[t])
241+ let bG = parseIntValue(bE[u])
242+ let bH = bv(bF, bG, by, bz)
243+ let bu = D(by, bF)
244+ let bt = D(bz, bG)
245+ let bI = D(bD, b)
246+ let bJ = bs(bu, bI)
247+ let bK = bs(bt, bI)
248+[bH, bJ, bK]
252249 }
253250
254251
255-func bM (bz,bA,bE) = {
256- let bN = bD(bz, bA, bE)
257-[G(bN[0], b), G(bN[1], b), G(bN[2], b)]
252+func bL (by,bz,bD) = {
253+ let bM = bC(by, bz, bD)
254+[G(bM[0], b), G(bM[1], b), G(bM[2], b)]
258255 }
259256
260257
261-func bO (bP,bQ,bR,Y) = {
262- let bF = aI()
263- let bS = bF[q]
264- let bT = bF[r]
265- let bU = bF[s]
266- let bx = parseIntValue(bF[t])
267- let by = parseIntValue(bF[u])
268- let bV = bF[p]
269- let bW = valueOrErrorMessage(assetInfo(fromBase58String(bS)), (("Asset " + bS) + " doesn't exist")).quantity
270- if ((bS != bQ))
258+func bN (bO,bP,bQ,X) = {
259+ let bE = aH()
260+ let bR = bE[q]
261+ let bS = bE[r]
262+ let bT = bE[s]
263+ let bw = parseIntValue(bE[t])
264+ let bx = parseIntValue(bE[u])
265+ let bU = bE[p]
266+ let bV = valueOrErrorMessage(assetInfo(fromBase58String(bR)), (("Asset " + bR) + " doesn't exist")).quantity
267+ if ((bR != bP))
271268 then throw("Invalid asset passed.")
272269 else {
273- let bX = br(bT)
274- let bY = D(bX, bx)
275- let bZ = br(bU)
276- let ca = D(bZ, by)
277- let cb = bt(ca, bY)
278- let cc = G(cb, b)
279- let cd = D(bR, b)
280- let ce = D(bW, b)
281- let cf = fraction(bY, cd, ce)
282- let cg = fraction(ca, cd, ce)
270+ let bW = bq(bS)
271+ let bX = D(bW, bw)
272+ let bY = bq(bT)
273+ let bZ = D(bY, bx)
274+ let ca = bs(bZ, bX)
275+ let cb = G(ca, b)
276+ let cc = D(bQ, b)
277+ let cd = D(bV, b)
278+ let ce = fraction(bX, cc, cd)
279+ let cf = fraction(bZ, cc, cd)
280+ let cg = G(ce, bw)
283281 let ch = G(cf, bx)
284- let ci = G(cg, by)
285- let cj = if ((bP == ""))
282+ let ci = if ((bO == ""))
286283 then nil
287- else [ScriptTransfer(Y, ch, if ((bT == "WAVES"))
284+ else [ScriptTransfer(X, cg, if ((bS == "WAVES"))
288285 then unit
289- else fromBase58String(bT)), ScriptTransfer(Y, ci, if ((bU == "WAVES"))
286+ else fromBase58String(bS)), ScriptTransfer(X, ch, if ((bT == "WAVES"))
290287 then unit
291- else fromBase58String(bU)), StringEntry(aa(toString(Y), bP), bn(ch, ci, bR, cc, height, lastBlock.timestamp)), IntegerEntry(T(), cc), IntegerEntry(U(height, lastBlock.timestamp), cc)]
292- $Tuple10(ch, ci, bT, bU, bX, bZ, bW, cb, bV, cj)
288+ 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)]
289+ $Tuple10(cg, ch, bS, bT, bW, bY, bV, ca, bU, ci)
293290 }
294291 }
295292
296293
297-func ck (bP,cl,cm,cn,co,cp,Y,cq,cr) = {
298- let bF = aI()
299- let bS = fromBase58String(bF[q])
300- let cs = bF[r]
301- let ct = bF[s]
302- let cu = bF[v]
303- let cv = bF[w]
304- let bG = parseIntValue(bF[t])
305- let bH = parseIntValue(bF[u])
306- let bV = bF[p]
307- let bW = valueOrErrorMessage(assetInfo(bS), (("Asset " + toBase58String(bS)) + " doesn't exist")).quantity
308- let cw = toBase58String(valueOrElse(cn, fromBase58String("WAVES")))
309- let cx = toBase58String(valueOrElse(cp, fromBase58String("WAVES")))
310- if (if ((cs != cw))
294+func cj (bO,ck,cl,cm,cn,co,X,cp,cq) = {
295+ let bE = aH()
296+ let bR = fromBase58String(bE[q])
297+ let cr = bE[r]
298+ let cs = bE[s]
299+ let ct = bE[v]
300+ let cu = bE[w]
301+ let bF = parseIntValue(bE[t])
302+ let bG = parseIntValue(bE[u])
303+ let bU = bE[p]
304+ let bV = valueOrErrorMessage(assetInfo(bR), (("Asset " + toBase58String(bR)) + " doesn't exist")).quantity
305+ let cv = toBase58String(valueOrElse(cm, fromBase58String("WAVES")))
306+ let cw = toBase58String(valueOrElse(co, fromBase58String("WAVES")))
307+ if (if ((cr != cv))
311308 then true
312- else (ct != cx))
309+ else (cs != cw))
313310 then throw("Invalid amt or price asset passed.")
314311 else {
315- let bX = if (cq)
316- then br(cs)
317- else (br(cs) - cm)
318- let bZ = if (cq)
319- then br(ct)
320- else (br(ct) - co)
321- let cy = D(cm, bG)
322- let cz = D(co, bH)
323- let cA = bt(cz, cy)
324- let bY = D(bX, bG)
325- let ca = D(bZ, bH)
326- let cB = if ((bW == 0))
312+ let bW = if (cp)
313+ then bq(cr)
314+ else (bq(cr) - cl)
315+ let bY = if (cp)
316+ then bq(cs)
317+ else (bq(cs) - cn)
318+ let cx = D(cl, bF)
319+ let cy = D(cn, bG)
320+ let cz = bs(cy, cx)
321+ let bX = D(bW, bF)
322+ let bZ = D(bY, bG)
323+ let cA = if ((bV == 0))
327324 then {
328- let cb = e
329- let cC = e
330- let bJ = pow((cy * cz), 0, toBigInt(5), 1, 0, DOWN)
331- $Tuple5(G(bJ, b), G(cy, bG), G(cz, bH), bt((ca + cz), (bY + cy)), cC)
325+ let ca = e
326+ let cB = e
327+ let bI = pow((cx * cy), 0, toBigInt(5), 1, 0, DOWN)
328+ $Tuple5(G(bI, b), G(cx, bF), G(cy, bG), bs((bZ + cy), (bX + cx)), cB)
332329 }
333330 else {
334- let cb = bt(ca, bY)
335- let cC = fraction(O((cb - cA)), d, cb)
336- let cD = D(cl, b)
337- if (if ((cb != e))
338- then (cC > cD)
331+ let ca = bs(bZ, bX)
332+ let cB = fraction(O((ca - cz)), d, ca)
333+ let cC = D(ck, b)
334+ if (if ((ca != e))
335+ then (cB > cC)
339336 else false)
340- then throw(((("Price slippage " + toString(cC)) + " exceeded the passed limit of ") + toString(cD)))
337+ then throw(((("Price slippage " + toString(cB)) + " exceeded the passed limit of ") + toString(cC)))
341338 else {
342- let ce = D(bW, b)
343- let cE = fraction(cy, cb, d)
344- let cF = fraction(cz, d, cb)
345- let cG = if ((cE > cz))
346- then $Tuple2(cF, cz)
347- else $Tuple2(cy, cE)
348- let cH = cG._1
349- let cI = cG._2
350- let bJ = fraction(ce, cI, ca)
351- $Tuple5(G(bJ, b), G(cH, bG), G(cI, bH), cb, cC)
339+ let cd = D(bV, b)
340+ let cD = fraction(cx, ca, d)
341+ let cE = fraction(cy, d, ca)
342+ let cF = if ((cD > cy))
343+ then $Tuple2(cE, cy)
344+ else $Tuple2(cx, cD)
345+ let cG = cF._1
346+ let cH = cF._2
347+ let bI = fraction(cd, cH, bZ)
348+ $Tuple5(G(bI, b), G(cG, bF), G(cH, bG), ca, cB)
352349 }
353350 }
354- let cJ = cB._1
355- let cK = cB._2
356- let cL = cB._3
357- let cc = G(cB._4, b)
358- let cM = G(cB._5, b)
359- if ((0 >= cJ))
351+ let cI = cA._1
352+ let cJ = cA._2
353+ let cK = cA._3
354+ let cb = G(cA._4, b)
355+ let cL = G(cA._5, b)
356+ if ((0 >= cI))
360357 then throw("Invalid calculations. LP calculated is less than zero.")
361358 else {
362- let cN = if (!(cr))
359+ let cM = if (!(cq))
363360 then 0
364- else cJ
365- let cO = (cm - cK)
366- let cP = (co - cL)
367- let cQ = [IntegerEntry(T(), cc), IntegerEntry(U(height, lastBlock.timestamp), cc), StringEntry(X(Y, bP), bc(cK, cL, cN, cc, cl, cM, height, lastBlock.timestamp, cO, cP))]
368- $Tuple13(cJ, cN, cc, bX, bZ, bW, bS, bV, cQ, cO, cP, cn, cp)
361+ else cI
362+ let cN = (cl - cJ)
363+ let cO = (cn - cK)
364+ 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))]
365+ $Tuple13(cI, cM, cb, bW, bY, bV, bR, bU, cP, cN, cO, cm, co)
369366 }
370367 }
371368 }
372369
373370
374-func cR (cS) = {
375- let bF = aI()
376- let cT = bF[r]
377- let cU = bF[s]
378- let bV = parseIntValue(bF[p])
379- let bG = parseIntValue(bF[t])
380- let bH = parseIntValue(bF[u])
381- let cV = br(cT)
382- let cW = br(cU)
383- let cb = if ((cS.orderType == Buy))
384- then bw(bG, bH, (cV + cS.amount), cW)
385- else bw(bG, bH, (cV - cS.amount), cW)
386- let cc = G(cb, b)
387- if (if (if (aG())
371+func cQ (cR) = {
372+ let bE = aH()
373+ let cS = bE[r]
374+ let cT = bE[s]
375+ let bU = parseIntValue(bE[p])
376+ let bF = parseIntValue(bE[t])
377+ let bG = parseIntValue(bE[u])
378+ let cU = bq(cS)
379+ let cV = bq(cT)
380+ let ca = if ((cR.orderType == Buy))
381+ then bv(bF, bG, (cU + cR.amount), cV)
382+ else bv(bF, bG, (cU - cR.amount), cV)
383+ let cb = G(ca, b)
384+ if (if (if (aF())
388385 then true
389- else (bV == m))
386+ else (bU == m))
390387 then true
391- else (bV == n))
388+ else (bU == n))
392389 then throw("Exchange operations disabled")
393390 else {
394- let cX = cS.assetPair.amountAsset
395- let cY = if ((cX == unit))
391+ let cW = cR.assetPair.amountAsset
392+ let cX = if ((cW == unit))
396393 then "WAVES"
397- else toBase58String(value(cX))
398- let cZ = cS.assetPair.priceAsset
399- let da = if ((cZ == unit))
394+ else toBase58String(value(cW))
395+ let cY = cR.assetPair.priceAsset
396+ let cZ = if ((cY == unit))
400397 then "WAVES"
401- else toBase58String(value(cZ))
402- if (if ((cY != cT))
398+ else toBase58String(value(cY))
399+ if (if ((cX != cS))
403400 then true
404- else (da != cU))
401+ else (cZ != cT))
405402 then throw("Wrong order assets.")
406403 else {
407- let db = cS.price
408- let dc = fraction(b, bH, bG)
409- let dd = J(db, b, dc)
410- let de = if ((cS.orderType == Buy))
411- then (cc >= dd)
412- else (dd >= cc)
404+ let da = cR.price
405+ let db = fraction(b, bG, bF)
406+ let dc = J(da, b, db)
407+ let dd = if ((cR.orderType == Buy))
408+ then (cb >= dc)
409+ else (dc >= cb)
413410 true
414411 }
415412 }
416413 }
417414
418415
419-func df (dg) = if ((size(dg.payments) != 1))
416+func de (df) = if ((size(df.payments) != 1))
420417 then throw("exactly 1 payment is expected")
421418 else {
422- let dh = value(dg.payments[0])
423- let bQ = value(dh.assetId)
424- let di = dh.amount
425- let cB = bO(toBase58String(dg.transactionId), toBase58String(bQ), di, dg.caller)
426- let ch = cB._1
427- let ci = cB._2
428- let bV = parseIntValue(cB._9)
429- let cj = cB._10
430- if (if (aG())
419+ let dg = value(df.payments[0])
420+ let bP = value(dg.assetId)
421+ let dh = dg.amount
422+ let cA = bN(toBase58String(df.transactionId), toBase58String(bP), dh, df.caller)
423+ let cg = cA._1
424+ let ch = cA._2
425+ let bU = parseIntValue(cA._9)
426+ let ci = cA._10
427+ if (if (aF())
431428 then true
432- else (bV == n))
433- then throw(("Get operation is blocked by admin. Status = " + toString(bV)))
434- else $Tuple5(ch, ci, di, bQ, cj)
429+ else (bU == n))
430+ then throw(("Get operation is blocked by admin. Status = " + toString(bU)))
431+ else $Tuple5(cg, ch, dh, bP, ci)
435432 }
436433
437434
438-func dj (dg,cl,cr) = if ((size(dg.payments) != 2))
435+func di (df,ck,cq) = if ((size(df.payments) != 2))
439436 then throw("exactly 2 payments are expected")
440437 else {
441- let dk = value(dg.payments[0])
442- let dl = value(dg.payments[1])
443- let dm = ck(toBase58String(dg.transactionId), cl, dk.amount, dk.assetId, dl.amount, dl.assetId, toString(dg.caller), false, cr)
444- let bV = parseIntValue(dm._8)
445- if (if (if (aG())
438+ let dj = value(df.payments[0])
439+ let dk = value(df.payments[1])
440+ let dl = cj(toBase58String(df.transactionId), ck, dj.amount, dj.assetId, dk.amount, dk.assetId, toString(df.caller), false, cq)
441+ let bU = parseIntValue(dl._8)
442+ if (if (if (aF())
446443 then true
447- else (bV == l))
444+ else (bU == l))
448445 then true
449- else (bV == n))
450- then throw(("Put operation is blocked by admin. Status = " + toString(bV)))
451- else dm
446+ else (bU == n))
447+ then throw(("Put operation is blocked by admin. Status = " + toString(bU)))
448+ else dl
452449 }
453450
454451
455-func dn (do) = {
456- let dp = invoke(aB, "emit", [do], nil)
457- if ((dp == dp))
452+func dm (dn) = {
453+ let do = invoke(aA, "emit", [dn], nil)
454+ if ((do == do))
458455 then {
459- let dq = {
460- let dr = dp
461- if ($isInstanceOf(dr, "Address"))
456+ let dp = {
457+ let dq = do
458+ if ($isInstanceOf(dq, "Address"))
462459 then {
463- let ds = dr
464- invoke(ds, "emit", [do], nil)
460+ let dr = dq
461+ invoke(dr, "emit", [dn], nil)
465462 }
466463 else unit
467464 }
468- if ((dq == dq))
469- then do
465+ if ((dp == dp))
466+ then dn
470467 else throw("Strict value is not equal to itself.")
471468 }
472469 else throw("Strict value is not equal to itself.")
473470 }
474471
475472
476-func dt (do,du) = {
477- let dv = if ((du == 0))
473+func ds (dn,dt) = {
474+ let du = if ((dt == 0))
478475 then 0
479- else fraction(do, du, b)
480- $Tuple2((do - dv), dv)
476+ else fraction(dn, dt, b)
477+ $Tuple2((dn - du), du)
481478 }
482479
483480
484-func dw (dx,dy,Y,Z) = {
485- let dz = (Z == unit)
486- let dA = br(aN(aV))
487- let dB = br(aN(aW))
488- let dC = if ((dy == aV))
481+func dv (dw,dx,X,Y) = {
482+ let dy = (Y == unit)
483+ let dz = bq(aM(aU))
484+ let dA = bq(aM(aV))
485+ let dB = if ((dx == aU))
489486 then true
490- else if ((dy == aW))
487+ else if ((dx == aV))
491488 then false
492- else az("invalid asset")
493- let dD = if (dz)
494- then $Tuple2(dA, dB)
495- else if (dC)
496- then $Tuple2((dA - dx), dB)
497- else $Tuple2(dA, (dB - dx))
498- let dE = dD._1
499- let dF = dD._2
500- let dG = if (dC)
501- then $Tuple2(dx, 0)
502- else $Tuple2(0, dx)
503- let dH = dG._1
504- let dI = dG._2
505- let dJ = dt(dH, aD)._1
506- let dK = dt(dI, aD)._1
507- let dL = dt(dx, aD)
508- let dM = dL._1
509- let dv = dL._2
489+ else ay("invalid asset")
490+ let dC = if (dy)
491+ then $Tuple2(dz, dA)
492+ else if (dB)
493+ then $Tuple2((dz - dw), dA)
494+ else $Tuple2(dz, (dA - dw))
495+ let dD = dC._1
496+ let dE = dC._2
497+ let dF = if (dB)
498+ then $Tuple2(dw, 0)
499+ else $Tuple2(0, dw)
500+ let dG = dF._1
501+ let dH = dF._2
502+ let dI = ds(dG, aC)._1
503+ let dJ = ds(dH, aC)._1
504+ let dK = ds(dw, aC)
505+ let dL = dK._1
506+ let du = dK._2
507+ let dM = (dD + dI)
510508 let dN = (dE + dJ)
511- let dO = (dF + dK)
512- let dP = bt(D(dO, aY), D(dN, aX))
513- let dQ = G(dP, b)
514- let dR = if (dC)
515- then dE
516- else dF
517- let dS = toBigInt(dR)
518- let dT = toBigInt(valueOrErrorMessage(assetInfo(aU), (("asset " + toBase58String(aU)) + " doesn't exist")).quantity)
519- let dU = if ((dT > f))
509+ let dO = bs(D(dN, aX), D(dM, aW))
510+ let dP = G(dO, b)
511+ let dQ = if (dB)
512+ then dD
513+ else dE
514+ let dR = toBigInt(dQ)
515+ let dS = toBigInt(valueOrErrorMessage(assetInfo(aT), (("asset " + toBase58String(aT)) + " doesn't exist")).quantity)
516+ let dT = if ((dS > f))
520517 then true
521- else az("initial deposit requires all coins")
522- if ((dU == dU))
518+ else ay("initial deposit requires all coins")
519+ if ((dT == dT))
523520 then {
524- let dV = toBigInt(dM)
525- let dW = max([0, toInt(((dT * (sqrtBigInt((d + ((dV * d) / dS)), 18, 18, DOWN) - d)) / d))])
526- let cQ = if (dz)
521+ let dU = toBigInt(dL)
522+ let dV = max([0, toInt(((dS * (sqrtBigInt((d + ((dU * d) / dR)), 18, 18, DOWN) - d)) / d))])
523+ let cP = if (dy)
527524 then nil
528- else [IntegerEntry(T(), dQ), IntegerEntry(U(height, lastBlock.timestamp), dQ), StringEntry(X(toString(value(Y)), toBase58String(value(Z))), bc(dH, dI, dW, dQ, 0, 0, height, lastBlock.timestamp, 0, 0))]
529- let dX = bt(D(dF, aY), D(dE, aX))
530- let dY = G(dX, b)
531- let dZ = {
532- let ea = if (dC)
533- then $Tuple2(dH, dE)
534- else $Tuple2(dI, dF)
535- let do = ea._1
536- let eb = ea._2
537- let ec = toInt(fraction(dT, toBigInt((do / 2)), toBigInt(eb)))
538- fraction((dW - ec), b, ec)
525+ else [IntegerEntry(S(), dP), IntegerEntry(T(height, lastBlock.timestamp), dP), StringEntry(W(toString(value(X)), toBase58String(value(Y))), bb(dG, dH, dV, dP, 0, 0, height, lastBlock.timestamp, 0, 0))]
526+ let dW = bs(D(dE, aX), D(dD, aW))
527+ let dX = G(dW, b)
528+ let dY = {
529+ let dZ = if (dB)
530+ then $Tuple2(dG, dD)
531+ else $Tuple2(dH, dE)
532+ let dn = dZ._1
533+ let ea = dZ._2
534+ let eb = toInt(fraction(dS, toBigInt((dn / 2)), toBigInt(ea)))
535+ fraction((dV - eb), b, eb)
539536 }
540- $Tuple4(dW, cQ, dv, dZ)
537+ $Tuple4(dV, cP, du, dY)
541538 }
542539 else throw("Strict value is not equal to itself.")
543540 }
544541
545542
546-func ed (ee,dM,dy,Y,Z) = {
547- let dz = (Z == unit)
548- let ef = [if ((dy == aU))
543+func ec (ed,dL,dx,X,Y) = {
544+ let dy = (Y == unit)
545+ let ee = [if ((dx == aT))
549546 then true
550- else az("invalid lp asset")]
551- if ((ef == ef))
547+ else ay("invalid lp asset")]
548+ if ((ee == ee))
552549 then {
553- let eg = if ((ee == aV))
550+ let ef = if ((ed == aU))
554551 then true
555- else if ((ee == aW))
552+ else if ((ed == aV))
556553 then false
557- else az("invalid asset")
558- let eh = if (eg)
559- then toBigInt(br(aN(aV)))
560- else toBigInt(br(aN(aW)))
561- let ei = br(aN(aV))
562- let ej = br(aN(aW))
563- let ek = if (eg)
564- then ei
565- else ej
566- let el = toBigInt(ek)
567- let dT = toBigInt(valueOrErrorMessage(assetInfo(aU), (("asset " + toBase58String(aU)) + " doesn't exist")).quantity)
568- let em = toBigInt(dM)
569- let en = max([0, toInt(((eh * (d - pow((d - ((em * d) / dT)), 18, h, 0, 18, DOWN))) / d))])
570- let eo = dt(en, aF)
571- let ep = eo._1
572- let dv = eo._2
573- let eq = if (eg)
574- then $Tuple4(ep, 0, (ei - en), ej)
575- else $Tuple4(0, ep, ei, (ej - en))
576- let er = eq._1
577- let es = eq._2
578- let et = eq._3
579- let eu = eq._4
580- let dP = bt(D(eu, aY), D(et, aX))
581- let dQ = G(dP, b)
582- let cQ = if (dz)
554+ else ay("invalid asset")
555+ let eg = if (ef)
556+ then toBigInt(bq(aM(aU)))
557+ else toBigInt(bq(aM(aV)))
558+ let eh = bq(aM(aU))
559+ let ei = bq(aM(aV))
560+ let ej = if (ef)
561+ then eh
562+ else ei
563+ let ek = toBigInt(ej)
564+ let dS = toBigInt(valueOrErrorMessage(assetInfo(aT), (("asset " + toBase58String(aT)) + " doesn't exist")).quantity)
565+ let el = toBigInt(dL)
566+ let em = max([0, toInt(((eg * (d - pow((d - ((el * d) / dS)), 18, h, 0, 18, DOWN))) / d))])
567+ let en = ds(em, aE)
568+ let eo = en._1
569+ let du = en._2
570+ let ep = if (ef)
571+ then $Tuple4(eo, 0, (eh - em), ei)
572+ else $Tuple4(0, eo, eh, (ei - em))
573+ let eq = ep._1
574+ let er = ep._2
575+ let es = ep._3
576+ let et = ep._4
577+ let dO = bs(D(et, aX), D(es, aW))
578+ let dP = G(dO, b)
579+ let cP = if (dy)
583580 then nil
584- else [StringEntry(aa(toString(value(Y)), toBase58String(value(Z))), bn(er, es, dM, dQ, height, lastBlock.timestamp)), IntegerEntry(T(), dQ), IntegerEntry(U(height, lastBlock.timestamp), dQ)]
585- let dX = bt(D(ej, aY), D(ei, aX))
586- let dY = G(dX, b)
587- let dZ = {
588- let ev = (toInt(fraction(eh, em, dT)) * 2)
589- fraction((ep - ev), b, ev)
581+ else [StringEntry(Z(toString(value(X)), toBase58String(value(Y))), bm(eq, er, dL, dP, height, lastBlock.timestamp)), IntegerEntry(S(), dP), IntegerEntry(T(height, lastBlock.timestamp), dP)]
582+ let dW = bs(D(ei, aX), D(eh, aW))
583+ let dX = G(dW, b)
584+ let dY = {
585+ let eu = (toInt(fraction(eg, el, dS)) * 2)
586+ fraction((eo - eu), b, eu)
590587 }
591- $Tuple4(ep, cQ, dv, dZ)
588+ $Tuple4(eo, cP, du, dY)
592589 }
593590 else throw("Strict value is not equal to itself.")
594591 }
595592
596593
597-func ew () = {
598- let dr = getString(R())
599- if ($isInstanceOf(dr, "String"))
594+func ev () = {
595+ let dq = getString(Q())
596+ if ($isInstanceOf(dq, "String"))
600597 then {
601- let ex = dr
602- fromBase58String(ex)
598+ let ew = dq
599+ fromBase58String(ew)
603600 }
604- else if ($isInstanceOf(dr, "Unit"))
601+ else if ($isInstanceOf(dq, "Unit"))
605602 then unit
606603 else throw("Match error")
607604 }
608605
609606
610-func ey () = {
611- let dr = getString(S())
612- if ($isInstanceOf(dr, "String"))
607+func ex () = {
608+ let dq = getString(R())
609+ if ($isInstanceOf(dq, "String"))
613610 then {
614- let ex = dr
615- fromBase58String(ex)
611+ let ew = dq
612+ fromBase58String(ew)
616613 }
617- else if ($isInstanceOf(dr, "Unit"))
614+ else if ($isInstanceOf(dq, "Unit"))
618615 then unit
619616 else throw("Match error")
620617 }
621618
622619
623-func ez (dg) = {
624- let dr = ew()
625- if ($isInstanceOf(dr, "ByteVector"))
620+func ey (df) = {
621+ let dq = ev()
622+ if ($isInstanceOf(dq, "ByteVector"))
626623 then {
627- let eA = dr
628- (dg.callerPublicKey == eA)
624+ let ez = dq
625+ (df.callerPublicKey == ez)
629626 }
630- else if ($isInstanceOf(dr, "Unit"))
631- then (dg.caller == this)
627+ else if ($isInstanceOf(dq, "Unit"))
628+ then (df.caller == this)
632629 else throw("Match error")
633630 }
634631
635632
636-func eB (dg) = {
637- let eC = throw("Permission denied")
638- let dr = ew()
639- if ($isInstanceOf(dr, "ByteVector"))
633+func eA (df) = {
634+ let eB = throw("Permission denied")
635+ let dq = ev()
636+ if ($isInstanceOf(dq, "ByteVector"))
640637 then {
641- let eA = dr
642- if ((dg.callerPublicKey == eA))
638+ let ez = dq
639+ if ((df.callerPublicKey == ez))
643640 then true
644- else eC
641+ else eB
645642 }
646- else if ($isInstanceOf(dr, "Unit"))
647- then if ((dg.caller == this))
643+ else if ($isInstanceOf(dq, "Unit"))
644+ then if ((df.caller == this))
648645 then true
649- else eC
646+ else eB
650647 else throw("Match error")
651648 }
652649
653650
654-@Callable(dg)
655-func calculateAmountOutForSwapAndSendTokens (eD,eE,eF,eG) = {
656- let ef = [if ((value(dg.payments[0]).amount >= eD))
657- then true
658- else az("Wrong amount"), if ((dg.caller == addressFromStringValue(av(this, P()))))
659- then true
660- else az("Permission denied")]
661- if ((ef == ef))
651+@Callable(df)
652+func setManager (eC) = {
653+ let eD = eA(df)
654+ if ((eD == eD))
662655 then {
663- let dh = value(dg.payments[0])
664- let eH = toBase58String(value(dh.assetId))
665- let eI = if ((eE == false))
666- then {
667- let eI = av(this, ac())
668- eI
669- }
670- else {
671- let eI = av(this, ab())
672- eI
673- }
674- let eJ = (br(eH) - value(dg.payments[0]).amount)
675- let eK = br(eI)
676- let eL = ((eK * eD) / (eJ + eD))
677- let eM = [(eL >= eF), "Exchange resulted in fewer coins than expected"]
678- if ((eM == eM))
679- then [ScriptTransfer(addressFromStringValue(eG), eL, fromBase58String(eI))]
656+ let eE = fromBase58String(eC)
657+ if ((eE == eE))
658+ then [StringEntry(R(), eC)]
680659 else throw("Strict value is not equal to itself.")
681660 }
682661 else throw("Strict value is not equal to itself.")
684663
685664
686665
687-@Callable(dg)
688-func setSwapContract (eN) = {
689- let eO = eB(dg)
690- if ((eO == eO))
691- then [StringEntry(P(), eN)]
692- else throw("Strict value is not equal to itself.")
693- }
694-
695-
696-
697-@Callable(dg)
698-func setManager (eP) = {
699- let eO = eB(dg)
700- if ((eO == eO))
666+@Callable(df)
667+func confirmManager () = {
668+ let eF = ex()
669+ let eG = if (isDefined(eF))
670+ then true
671+ else throw("No pending manager")
672+ if ((eG == eG))
701673 then {
702- let eQ = fromBase58String(eP)
703- if ((eQ == eQ))
704- then [StringEntry(S(), eP)]
674+ let eH = if ((df.callerPublicKey == value(eF)))
675+ then true
676+ else throw("You are not pending manager")
677+ if ((eH == eH))
678+ then [StringEntry(Q(), toBase58String(value(eF))), DeleteEntry(R())]
705679 else throw("Strict value is not equal to itself.")
706680 }
707681 else throw("Strict value is not equal to itself.")
709683
710684
711685
712-@Callable(dg)
713-func confirmManager () = {
714- let eR = ey()
715- let eS = if (isDefined(eR))
716- then true
717- else throw("No pending manager")
718- if ((eS == eS))
719- then {
720- let eT = if ((dg.callerPublicKey == value(eR)))
721- then true
722- else throw("You are not pending manager")
723- if ((eT == eT))
724- then [StringEntry(R(), toBase58String(value(eR))), DeleteEntry(S())]
725- else throw("Strict value is not equal to itself.")
726- }
727- else throw("Strict value is not equal to itself.")
728- }
729-
730-
731-
732-@Callable(dg)
733-func put (cl,eU) = if ((0 > cl))
686+@Callable(df)
687+func put (ck,eI) = if ((0 > ck))
734688 then throw("Invalid slippageTolerance passed")
735689 else {
736- let dm = dj(dg, cl, true)
737- let cN = dm._2
738- let bS = dm._7
739- let cj = dm._9
740- let cO = dm._10
741- let cP = dm._11
742- let eV = dm._12
743- let eW = dm._13
744- let dp = invoke(aB, "emit", [cN], nil)
745- if ((dp == dp))
690+ let dl = di(df, ck, true)
691+ let cM = dl._2
692+ let bR = dl._7
693+ let ci = dl._9
694+ let cN = dl._10
695+ let cO = dl._11
696+ let eJ = dl._12
697+ let eK = dl._13
698+ let do = invoke(aA, "emit", [cM], nil)
699+ if ((do == do))
746700 then {
747- let dq = {
748- let dr = dp
749- if ($isInstanceOf(dr, "Address"))
701+ let dp = {
702+ let dq = do
703+ if ($isInstanceOf(dq, "Address"))
750704 then {
751- let ds = dr
752- invoke(ds, "emit", [cN], nil)
705+ let dr = dq
706+ invoke(dr, "emit", [cM], nil)
753707 }
754708 else unit
755709 }
756- if ((dq == dq))
710+ if ((dp == dp))
757711 then {
758- let eX = if ((cO > 0))
759- then invoke(bb, "put", nil, [AttachedPayment(eV, cO)])
712+ let eL = if ((cN > 0))
713+ then invoke(ba, "put", nil, [AttachedPayment(eJ, cN)])
760714 else nil
761- if ((eX == eX))
715+ if ((eL == eL))
762716 then {
763- let eY = if ((cP > 0))
764- then invoke(bb, "put", nil, [AttachedPayment(eW, cP)])
717+ let eM = if ((cO > 0))
718+ then invoke(ba, "put", nil, [AttachedPayment(eK, cO)])
765719 else nil
766- if ((eY == eY))
720+ if ((eM == eM))
767721 then {
768- let eZ = if (eU)
722+ let eN = if (eI)
769723 then {
770- let fa = invoke(ba, "stake", nil, [AttachedPayment(bS, cN)])
771- if ((fa == fa))
724+ let eO = invoke(aZ, "stake", nil, [AttachedPayment(bR, cM)])
725+ if ((eO == eO))
772726 then nil
773727 else throw("Strict value is not equal to itself.")
774728 }
775- else [ScriptTransfer(dg.caller, cN, bS)]
776- (cj ++ eZ)
729+ else [ScriptTransfer(df.caller, cM, bR)]
730+ (ci ++ eN)
777731 }
778732 else throw("Strict value is not equal to itself.")
779733 }
786740
787741
788742
789-@Callable(dg)
790-func putForFree (fb) = if ((0 > fb))
743+@Callable(df)
744+func putForFree (eP) = if ((0 > eP))
791745 then throw("Invalid value passed")
792746 else {
793- let dm = dj(dg, fb, false)
794- dm._9
747+ let dl = di(df, eP, false)
748+ dl._9
795749 }
796750
797751
798752
799-@Callable(dg)
800-func putOneTkn (fc,fd) = {
801- let fe = {
802- let aE = invoke(aB, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
803- if ($isInstanceOf(aE, "Boolean"))
804- then aE
805- else throw(($getType(aE) + " couldn't be cast to Boolean"))
753+@Callable(df)
754+func putOneTkn (eQ,eR) = {
755+ let eS = {
756+ let aD = invoke(aA, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
757+ if ($isInstanceOf(aD, "Boolean"))
758+ then aD
759+ else throw(($getType(aD) + " couldn't be cast to Boolean"))
806760 }
807- let ff = if (if (if (aG())
761+ let eT = if (if (if (aF())
808762 then true
809- else (aT == l))
763+ else (aS == l))
810764 then true
811- else (aT == n))
765+ else (aS == n))
812766 then true
813- else fe
814- let ef = [if (if (!(ff))
767+ else eS
768+ let ee = [if (if (!(eT))
815769 then true
816- else ez(dg))
770+ else ey(df))
817771 then true
818- else az("put operation is blocked by admin"), if ((size(dg.payments) == 1))
772+ else ay("put operation is blocked by admin"), if ((size(df.payments) == 1))
819773 then true
820- else az("exactly 1 payment are expected")]
821- if ((ef == ef))
774+ else ay("exactly 1 payment are expected")]
775+ if ((ee == ee))
822776 then {
823- let fg = dg.payments[0]
824- let dy = fg.assetId
825- let dx = fg.amount
826- let Y = dg.caller
827- let Z = dg.transactionId
828- let fh = dw(dx, dy, Y, Z)
829- if ((fh == fh))
777+ let eU = df.payments[0]
778+ let dx = eU.assetId
779+ let dw = eU.amount
780+ let X = df.caller
781+ let Y = df.transactionId
782+ let eV = dv(dw, dx, X, Y)
783+ if ((eV == eV))
830784 then {
831- let fi = fh._4
832- let dv = fh._3
833- let cQ = fh._2
834- let fj = fh._1
835- let fk = if (if ((fc > 0))
836- then (fc > fj)
785+ let eW = eV._4
786+ let du = eV._3
787+ let cP = eV._2
788+ let eX = eV._1
789+ let eY = if (if ((eQ > 0))
790+ then (eQ > eX)
837791 else false)
838- then az(makeString(["amount to receive is less than ", toString(fc)], ""))
839- else fj
840- let dp = dn(fk)
841- if ((dp == dp))
792+ then ay(makeString(["amount to receive is less than ", toString(eQ)], ""))
793+ else eX
794+ let do = dm(eY)
795+ if ((do == do))
842796 then {
843- let eZ = if (fd)
797+ let eN = if (eR)
844798 then {
845- let fl = invoke(ba, "stake", nil, [AttachedPayment(aU, fk)])
846- if ((fl == fl))
799+ let eZ = invoke(aZ, "stake", nil, [AttachedPayment(aT, eY)])
800+ if ((eZ == eZ))
847801 then nil
848802 else throw("Strict value is not equal to itself.")
849803 }
850- else [ScriptTransfer(dg.caller, fk, aU)]
851- let fm = if ((dv > 0))
852- then [ScriptTransfer(aC, dv, dy)]
804+ else [ScriptTransfer(df.caller, eY, aT)]
805+ let fa = if ((du > 0))
806+ then [ScriptTransfer(aB, du, dx)]
853807 else nil
854- $Tuple2(((cQ ++ eZ) ++ fm), fk)
808+ $Tuple2(((cP ++ eN) ++ fa), eY)
855809 }
856810 else throw("Strict value is not equal to itself.")
857811 }
862816
863817
864818
865-@Callable(dg)
866-func putOneTknREADONLY (dy,dx) = {
867- let fn = dw(dx, aL(dy), unit, unit)
868- let fj = fn._1
869- let cQ = fn._2
870- let dv = fn._3
871- let fi = fn._4
872- $Tuple2(nil, $Tuple3(fj, dv, fi))
819+@Callable(df)
820+func putOneTknREADONLY (dx,dw) = {
821+ let fb = dv(dw, aK(dx), unit, unit)
822+ let eX = fb._1
823+ let cP = fb._2
824+ let du = fb._3
825+ let eW = fb._4
826+ $Tuple2(nil, $Tuple3(eX, du, eW))
873827 }
874828
875829
876830
877-@Callable(dg)
878-func getOneTkn (fo,fc) = {
879- let fe = {
880- let aE = invoke(aB, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
881- if ($isInstanceOf(aE, "Boolean"))
882- then aE
883- else throw(($getType(aE) + " couldn't be cast to Boolean"))
831+@Callable(df)
832+func getOneTkn (fc,eQ) = {
833+ let eS = {
834+ let aD = invoke(aA, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
835+ if ($isInstanceOf(aD, "Boolean"))
836+ then aD
837+ else throw(($getType(aD) + " couldn't be cast to Boolean"))
884838 }
885- let fp = if (if (aG())
839+ let fd = if (if (aF())
886840 then true
887- else (aT == n))
841+ else (aS == n))
888842 then true
889- else fe
890- let ef = [if (if (!(fp))
843+ else eS
844+ let ee = [if (if (!(fd))
891845 then true
892- else ez(dg))
846+ else ey(df))
893847 then true
894- else az("get operation is blocked by admin"), if ((size(dg.payments) == 1))
848+ else ay("get operation is blocked by admin"), if ((size(df.payments) == 1))
895849 then true
896- else az("exactly 1 payment are expected")]
897- if ((ef == ef))
850+ else ay("exactly 1 payment are expected")]
851+ if ((ee == ee))
898852 then {
899- let ee = aL(fo)
900- let fg = dg.payments[0]
901- let dy = fg.assetId
902- let dM = fg.amount
903- let Y = dg.caller
904- let Z = dg.transactionId
905- let fq = ed(ee, dM, dy, Y, Z)
906- if ((fq == fq))
853+ let ed = aK(fc)
854+ let eU = df.payments[0]
855+ let dx = eU.assetId
856+ let dL = eU.amount
857+ let X = df.caller
858+ let Y = df.transactionId
859+ let fe = ec(ed, dL, dx, X, Y)
860+ if ((fe == fe))
907861 then {
908- let fi = fq._4
909- let dv = fq._3
910- let cQ = fq._2
911- let fr = fq._1
912- let do = if (if ((fc > 0))
913- then (fc > fr)
862+ let eW = fe._4
863+ let du = fe._3
864+ let cP = fe._2
865+ let ff = fe._1
866+ let dn = if (if ((eQ > 0))
867+ then (eQ > ff)
914868 else false)
915- then az(makeString(["amount to receive is less than ", toString(fc)], ""))
916- else fr
917- let fs = invoke(aB, "burn", [dM], [AttachedPayment(dy, dM)])
918- if ((fs == fs))
869+ then ay(makeString(["amount to receive is less than ", toString(eQ)], ""))
870+ else ff
871+ let fg = invoke(aA, "burn", [dL], [AttachedPayment(dx, dL)])
872+ if ((fg == fg))
919873 then {
920- let ft = [ScriptTransfer(Y, do, ee)]
921- let fm = if ((dv > 0))
922- then [ScriptTransfer(aC, dv, ee)]
874+ let fh = [ScriptTransfer(X, dn, ed)]
875+ let fa = if ((du > 0))
876+ then [ScriptTransfer(aB, du, ed)]
923877 else nil
924- $Tuple2(((cQ ++ ft) ++ fm), do)
878+ $Tuple2(((cP ++ fh) ++ fa), dn)
925879 }
926880 else throw("Strict value is not equal to itself.")
927881 }
932886
933887
934888
935-@Callable(dg)
936-func getOneTknREADONLY (ee,dM) = {
937- let fu = ed(aL(ee), dM, aU, unit, unit)
938- let fr = fu._1
939- let cQ = fu._2
940- let dv = fu._3
941- let fi = fu._4
942- $Tuple2(nil, $Tuple3(fr, dv, fi))
889+@Callable(df)
890+func getOneTknREADONLY (ed,dL) = {
891+ let fi = ec(aK(ed), dL, aT, unit, unit)
892+ let ff = fi._1
893+ let cP = fi._2
894+ let du = fi._3
895+ let eW = fi._4
896+ $Tuple2(nil, $Tuple3(ff, du, eW))
943897 }
944898
945899
946900
947-@Callable(dg)
948-func unstakeAndGetOneTkn (fv,fo,fc) = {
949- let fe = {
950- let aE = invoke(aB, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
951- if ($isInstanceOf(aE, "Boolean"))
952- then aE
953- else throw(($getType(aE) + " couldn't be cast to Boolean"))
901+@Callable(df)
902+func unstakeAndGetOneTkn (fj,fc,eQ) = {
903+ let eS = {
904+ let aD = invoke(aA, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
905+ if ($isInstanceOf(aD, "Boolean"))
906+ then aD
907+ else throw(($getType(aD) + " couldn't be cast to Boolean"))
954908 }
955- let fp = if (if (aG())
909+ let fd = if (if (aF())
956910 then true
957- else (aT == n))
911+ else (aS == n))
958912 then true
959- else fe
960- let ef = [if (if (!(fp))
913+ else eS
914+ let ee = [if (if (!(fd))
961915 then true
962- else ez(dg))
916+ else ey(df))
963917 then true
964- else az("get operation is blocked by admin"), if ((size(dg.payments) == 0))
918+ else ay("get operation is blocked by admin"), if ((size(df.payments) == 0))
965919 then true
966- else az("no payments are expected")]
967- if ((ef == ef))
920+ else ay("no payments are expected")]
921+ if ((ee == ee))
968922 then {
969- let ee = aL(fo)
970- let Y = dg.caller
971- let Z = dg.transactionId
972- let fw = invoke(ba, "unstake", [toBase58String(aU), fv], nil)
973- if ((fw == fw))
923+ let ed = aK(fc)
924+ let X = df.caller
925+ let Y = df.transactionId
926+ let fk = invoke(aZ, "unstake", [toBase58String(aT), fj], nil)
927+ if ((fk == fk))
974928 then {
975- let fx = ed(ee, fv, aU, Y, Z)
976- if ((fx == fx))
929+ let fl = ec(ed, fj, aT, X, Y)
930+ if ((fl == fl))
977931 then {
978- let fi = fx._4
979- let dv = fx._3
980- let cQ = fx._2
981- let fr = fx._1
982- let do = if (if ((fc > 0))
983- then (fc > fr)
932+ let eW = fl._4
933+ let du = fl._3
934+ let cP = fl._2
935+ let ff = fl._1
936+ let dn = if (if ((eQ > 0))
937+ then (eQ > ff)
984938 else false)
985- then az(makeString(["amount to receive is less than ", toString(fc)], ""))
986- else fr
987- let fs = invoke(aB, "burn", [fv], [AttachedPayment(aU, fv)])
988- if ((fs == fs))
939+ then ay(makeString(["amount to receive is less than ", toString(eQ)], ""))
940+ else ff
941+ let fg = invoke(aA, "burn", [fj], [AttachedPayment(aT, fj)])
942+ if ((fg == fg))
989943 then {
990- let ft = [ScriptTransfer(dg.caller, do, ee)]
991- let fm = if ((dv > 0))
992- then [ScriptTransfer(aC, dv, ee)]
944+ let fh = [ScriptTransfer(df.caller, dn, ed)]
945+ let fa = if ((du > 0))
946+ then [ScriptTransfer(aB, du, ed)]
993947 else nil
994- $Tuple2(((cQ ++ ft) ++ fm), do)
948+ $Tuple2(((cP ++ fh) ++ fa), dn)
995949 }
996950 else throw("Strict value is not equal to itself.")
997951 }
1004958
1005959
1006960
1007-@Callable(dg)
961+@Callable(df)
1008962 func get () = {
1009- let cB = df(dg)
1010- let fy = cB._1
1011- let ci = cB._2
1012- let di = cB._3
1013- let bQ = cB._4
1014- let cj = cB._5
1015- let fz = invoke(aB, "burn", [di], [AttachedPayment(bQ, di)])
1016- if ((fz == fz))
1017- then cj
963+ let cA = de(df)
964+ let fm = cA._1
965+ let ch = cA._2
966+ let dh = cA._3
967+ let bP = cA._4
968+ let ci = cA._5
969+ let fn = invoke(aA, "burn", [dh], [AttachedPayment(bP, dh)])
970+ if ((fn == fn))
971+ then ci
1018972 else throw("Strict value is not equal to itself.")
1019973 }
1020974
1021975
1022976
1023-@Callable(dg)
1024-func getNoLess (fA,fB) = {
1025- let cB = df(dg)
1026- let ch = cB._1
1027- let ci = cB._2
1028- let di = cB._3
1029- let bQ = cB._4
1030- let cj = cB._5
1031- if ((fA > ch))
1032- then throw(((("noLessThenAmtAsset failed: " + toString(ch)) + " < ") + toString(fA)))
1033- else if ((fB > ci))
1034- then throw(((("noLessThenPriceAsset failed: " + toString(ci)) + " < ") + toString(fB)))
977+@Callable(df)
978+func getNoLess (fo,fp) = {
979+ let cA = de(df)
980+ let cg = cA._1
981+ let ch = cA._2
982+ let dh = cA._3
983+ let bP = cA._4
984+ let ci = cA._5
985+ if ((fo > cg))
986+ then throw(((("noLessThenAmtAsset failed: " + toString(cg)) + " < ") + toString(fo)))
987+ else if ((fp > ch))
988+ then throw(((("noLessThenPriceAsset failed: " + toString(ch)) + " < ") + toString(fp)))
1035989 else {
1036- let fz = invoke(aB, "burn", [di], [AttachedPayment(bQ, di)])
1037- if ((fz == fz))
1038- then cj
990+ let fn = invoke(aA, "burn", [dh], [AttachedPayment(bP, dh)])
991+ if ((fn == fn))
992+ then ci
1039993 else throw("Strict value is not equal to itself.")
1040994 }
1041995 }
1042996
1043997
1044998
1045-@Callable(dg)
1046-func unstakeAndGet (do) = {
1047- let fC = if ((size(dg.payments) != 0))
999+@Callable(df)
1000+func unstakeAndGet (dn) = {
1001+ let fq = if ((size(df.payments) != 0))
10481002 then throw("No payments are expected")
10491003 else true
1050- if ((fC == fC))
1004+ if ((fq == fq))
10511005 then {
1052- let bF = aI()
1053- let bS = fromBase58String(bF[q])
1054- let fw = invoke(ba, "unstake", [toBase58String(bS), do], nil)
1055- if ((fw == fw))
1006+ let bE = aH()
1007+ let bR = fromBase58String(bE[q])
1008+ let fk = invoke(aZ, "unstake", [toBase58String(bR), dn], nil)
1009+ if ((fk == fk))
10561010 then {
1057- let cB = bO(toBase58String(dg.transactionId), toBase58String(bS), do, dg.caller)
1058- let bV = parseIntValue(cB._9)
1059- let cj = cB._10
1060- let fD = if (if (aG())
1011+ let cA = bN(toBase58String(df.transactionId), toBase58String(bR), dn, df.caller)
1012+ let bU = parseIntValue(cA._9)
1013+ let ci = cA._10
1014+ let fr = if (if (aF())
10611015 then true
1062- else (bV == n))
1063- then throw(("Get operation is blocked by admin. Status = " + toString(bV)))
1016+ else (bU == n))
1017+ then throw(("Get operation is blocked by admin. Status = " + toString(bU)))
10641018 else true
1065- if ((fD == fD))
1019+ if ((fr == fr))
10661020 then {
1067- let fz = invoke(aB, "burn", [do], [AttachedPayment(bS, do)])
1068- if ((fz == fz))
1069- then cj
1021+ let fn = invoke(aA, "burn", [dn], [AttachedPayment(bR, dn)])
1022+ if ((fn == fn))
1023+ then ci
10701024 else throw("Strict value is not equal to itself.")
10711025 }
10721026 else throw("Strict value is not equal to itself.")
10781032
10791033
10801034
1081-@Callable(dg)
1082-func unstakeAndGetNoLess (fv,fE,fB) = {
1083- let fp = if (aG())
1035+@Callable(df)
1036+func unstakeAndGetNoLess (fj,fs,fp) = {
1037+ let fd = if (aF())
10841038 then true
1085- else (aT == n)
1086- let ef = [if (!(fp))
1039+ else (aS == n)
1040+ let ee = [if (!(fd))
10871041 then true
1088- else throw("get operation is blocked by admin"), if ((size(dg.payments) == 0))
1042+ else throw("get operation is blocked by admin"), if ((size(df.payments) == 0))
10891043 then true
10901044 else throw("no payments are expected")]
1091- if ((ef == ef))
1045+ if ((ee == ee))
10921046 then {
1093- let fw = invoke(ba, "unstake", [toBase58String(aU), fv], nil)
1094- if ((fw == fw))
1047+ let fk = invoke(aZ, "unstake", [toBase58String(aT), fj], nil)
1048+ if ((fk == fk))
10951049 then {
1096- let cB = bO(toBase58String(dg.transactionId), toBase58String(aU), fv, dg.caller)
1097- let ch = cB._1
1098- let ci = cB._2
1099- let cj = cB._10
1100- let fF = [if ((ch >= fE))
1050+ let cA = bN(toBase58String(df.transactionId), toBase58String(aT), fj, df.caller)
1051+ let cg = cA._1
1052+ let ch = cA._2
1053+ let ci = cA._10
1054+ let ft = [if ((cg >= fs))
11011055 then true
1102- else throw(makeString(["amount asset amount to receive is less than ", toString(fE)], "")), if ((ci >= fB))
1056+ else throw(makeString(["amount asset amount to receive is less than ", toString(fs)], "")), if ((ch >= fp))
11031057 then true
1104- else throw(makeString(["price asset amount to receive is less than ", toString(fB)], ""))]
1105- if ((fF == fF))
1058+ else throw(makeString(["price asset amount to receive is less than ", toString(fp)], ""))]
1059+ if ((ft == ft))
11061060 then {
1107- let fz = invoke(aB, "burn", [fv], [AttachedPayment(aU, fv)])
1108- if ((fz == fz))
1109- then cj
1061+ let fn = invoke(aA, "burn", [fj], [AttachedPayment(aT, fj)])
1062+ if ((fn == fn))
1063+ then ci
11101064 else throw("Strict value is not equal to itself.")
11111065 }
11121066 else throw("Strict value is not equal to itself.")
11181072
11191073
11201074
1121-@Callable(dg)
1122-func activate (fG,fH) = if ((toString(dg.caller) != toString(aB)))
1075+@Callable(df)
1076+func activate (fu,fv) = if ((toString(df.caller) != toString(aA)))
11231077 then throw("permissions denied")
1124- else $Tuple2([StringEntry(ab(), fG), StringEntry(ac(), fH)], "success")
1078+ else $Tuple2([StringEntry(aa(), fu), StringEntry(ab(), fv)], "success")
11251079
11261080
11271081
1128-@Callable(dg)
1129-func getPoolConfigWrapperREADONLY () = $Tuple2(nil, aI())
1082+@Callable(df)
1083+func getPoolConfigWrapperREADONLY () = $Tuple2(nil, aH())
11301084
11311085
11321086
1133-@Callable(dg)
1134-func getAccBalanceWrapperREADONLY (bs) = $Tuple2(nil, br(bs))
1087+@Callable(df)
1088+func getAccBalanceWrapperREADONLY (br) = $Tuple2(nil, bq(br))
11351089
11361090
11371091
1138-@Callable(dg)
1139-func calcPricesWrapperREADONLY (bz,bA,bE) = {
1140- let bN = bD(bz, bA, bE)
1141- $Tuple2(nil, [toString(bN[0]), toString(bN[1]), toString(bN[2])])
1092+@Callable(df)
1093+func calcPricesWrapperREADONLY (by,bz,bD) = {
1094+ let bM = bC(by, bz, bD)
1095+ $Tuple2(nil, [toString(bM[0]), toString(bM[1]), toString(bM[2])])
11421096 }
11431097
11441098
11451099
1146-@Callable(dg)
1100+@Callable(df)
11471101 func toX18WrapperREADONLY (E,F) = $Tuple2(nil, toString(D(E, F)))
11481102
11491103
11501104
1151-@Callable(dg)
1105+@Callable(df)
11521106 func fromX18WrapperREADONLY (H,I) = $Tuple2(nil, G(parseBigIntValue(H), I))
11531107
11541108
11551109
1156-@Callable(dg)
1157-func calcPriceBigIntWrapperREADONLY (bu,bv) = $Tuple2(nil, toString(bt(parseBigIntValue(bu), parseBigIntValue(bv))))
1110+@Callable(df)
1111+func calcPriceBigIntWrapperREADONLY (bt,bu) = $Tuple2(nil, toString(bs(parseBigIntValue(bt), parseBigIntValue(bu))))
11581112
11591113
11601114
1161-@Callable(dg)
1162-func estimatePutOperationWrapperREADONLY (bP,cl,cm,cn,co,cp,Y,cq,cr) = $Tuple2(nil, ck(bP, cl, cm, cn, co, cp, Y, cq, cr))
1115+@Callable(df)
1116+func estimatePutOperationWrapperREADONLY (bO,ck,cl,cm,cn,co,X,cp,cq) = $Tuple2(nil, cj(bO, ck, cl, cm, cn, co, X, cp, cq))
11631117
11641118
11651119
1166-@Callable(dg)
1167-func estimateGetOperationWrapperREADONLY (bP,bQ,bR,Y) = {
1168- let cB = bO(bP, bQ, bR, addressFromStringValue(Y))
1169- $Tuple2(nil, $Tuple10(cB._1, cB._2, cB._3, cB._4, cB._5, cB._6, cB._7, toString(cB._8), cB._9, cB._10))
1120+@Callable(df)
1121+func estimateGetOperationWrapperREADONLY (bO,bP,bQ,X) = {
1122+ let cA = bN(bO, bP, bQ, addressFromStringValue(X))
1123+ $Tuple2(nil, $Tuple10(cA._1, cA._2, cA._3, cA._4, cA._5, cA._6, cA._7, toString(cA._8), cA._9, cA._10))
11701124 }
11711125
11721126
11731127
1174-@Callable(dg)
1128+@Callable(df)
11751129 func statsREADONLY () = {
1176- let bF = aI()
1177- let bS = fromBase58String(bF[q])
1178- let cT = bF[r]
1179- let cU = bF[s]
1180- let cu = bF[v]
1181- let cv = bF[w]
1182- let bG = parseIntValue(bF[t])
1183- let bH = parseIntValue(bF[u])
1184- let fI = valueOrErrorMessage(assetInfo(bS), (("Asset " + toBase58String(bS)) + " doesn't exist")).quantity
1185- let cV = br(cT)
1186- let cW = br(cU)
1187- let fJ = if ((fI == 0))
1130+ let bE = aH()
1131+ let bR = fromBase58String(bE[q])
1132+ let cS = bE[r]
1133+ let cT = bE[s]
1134+ let ct = bE[v]
1135+ let cu = bE[w]
1136+ let bF = parseIntValue(bE[t])
1137+ let bG = parseIntValue(bE[u])
1138+ let fw = valueOrErrorMessage(assetInfo(bR), (("Asset " + toBase58String(bR)) + " doesn't exist")).quantity
1139+ let cU = bq(cS)
1140+ let cV = bq(cT)
1141+ let fx = if ((fw == 0))
11881142 then [e, e, e]
1189- else bD(cV, cW, fI)
1190- let cc = 0
1191- let fK = G(fJ[1], b)
1192- let fL = G(fJ[2], b)
1193- let fM = value(getInteger(aB, an(toString(this))))
1194- $Tuple2(nil, makeString(["%d%d%d%d%d%d%d", toString(cV), toString(cW), toString(fI), toString(cc), toString(fK), toString(fL), toString(fM)], j))
1143+ else bC(cU, cV, fw)
1144+ let cb = 0
1145+ let fy = G(fx[1], b)
1146+ let fz = G(fx[2], b)
1147+ let fA = value(getInteger(aA, am(toString(this))))
1148+ $Tuple2(nil, makeString(["%d%d%d%d%d%d%d", toString(cU), toString(cV), toString(fw), toString(cb), toString(fy), toString(fz), toString(fA)], j))
11951149 }
11961150
11971151
11981152
1199-@Callable(dg)
1200-func evaluatePutByAmountAssetREADONLY (cm) = {
1201- let bF = aI()
1202- let bS = fromBase58String(bF[q])
1203- let cs = bF[r]
1153+@Callable(df)
1154+func evaluatePutByAmountAssetREADONLY (cl) = {
1155+ let bE = aH()
1156+ let bR = fromBase58String(bE[q])
1157+ let cr = bE[r]
1158+ let bS = fromBase58String(cr)
1159+ let cs = bE[s]
12041160 let bT = fromBase58String(cs)
1205- let ct = bF[s]
1206- let bU = fromBase58String(ct)
1207- let bG = parseIntValue(bF[t])
1208- let bH = parseIntValue(bF[u])
1209- let bV = bF[p]
1210- let fI = valueOrErrorMessage(assetInfo(bS), (("Asset " + toBase58String(bS)) + " doesn't exist")).quantity
1211- let cV = br(cs)
1212- let cW = br(ct)
1161+ let bF = parseIntValue(bE[t])
1162+ let bG = parseIntValue(bE[u])
1163+ let bU = bE[p]
1164+ let fw = valueOrErrorMessage(assetInfo(bR), (("Asset " + toBase58String(bR)) + " doesn't exist")).quantity
1165+ let cU = bq(cr)
1166+ let cV = bq(cs)
1167+ let bA = D(cU, bF)
12131168 let bB = D(cV, bG)
1214- let bC = D(cW, bH)
1215- let cb = if ((fI == 0))
1169+ let ca = if ((fw == 0))
12161170 then e
1217- else bt(bC, bB)
1218- let cy = D(cm, bG)
1219- let cz = fraction(cy, cb, d)
1220- let co = G(cz, bH)
1221- let dm = ck("", 500000, cm, bT, co, bU, "", true, false)
1222- let cJ = dm._1
1223- let fN = dm._3
1224- let bX = dm._4
1225- let bZ = dm._5
1226- let bW = dm._6
1227- $Tuple2(nil, makeString(["%d%d%d%d%d%d%d%d", toString(cJ), toString(G(cb, b)), toString(bX), toString(bZ), toString(bW), bV, toString(cm), toString(co)], j))
1171+ else bs(bB, bA)
1172+ let cx = D(cl, bF)
1173+ let cy = fraction(cx, ca, d)
1174+ let cn = G(cy, bG)
1175+ let dl = cj("", 500000, cl, bS, cn, bT, "", true, false)
1176+ let cI = dl._1
1177+ let fB = dl._3
1178+ let bW = dl._4
1179+ let bY = dl._5
1180+ let bV = dl._6
1181+ $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))
12281182 }
12291183
12301184
12311185
1232-@Callable(dg)
1233-func evaluatePutByPriceAssetREADONLY (co) = {
1234- let bF = aI()
1235- let bS = fromBase58String(bF[q])
1236- let cs = bF[r]
1186+@Callable(df)
1187+func evaluatePutByPriceAssetREADONLY (cn) = {
1188+ let bE = aH()
1189+ let bR = fromBase58String(bE[q])
1190+ let cr = bE[r]
1191+ let bS = fromBase58String(cr)
1192+ let cs = bE[s]
12371193 let bT = fromBase58String(cs)
1238- let ct = bF[s]
1239- let bU = fromBase58String(ct)
1240- let bG = parseIntValue(bF[t])
1241- let bH = parseIntValue(bF[u])
1242- let bV = bF[p]
1243- let fI = valueOrErrorMessage(assetInfo(bS), (("Asset " + toBase58String(bS)) + " doesn't exist")).quantity
1244- let fO = br(cs)
1245- let fP = br(ct)
1246- let fQ = D(fO, bG)
1247- let fR = D(fP, bH)
1248- let cb = if ((fI == 0))
1194+ let bF = parseIntValue(bE[t])
1195+ let bG = parseIntValue(bE[u])
1196+ let bU = bE[p]
1197+ let fw = valueOrErrorMessage(assetInfo(bR), (("Asset " + toBase58String(bR)) + " doesn't exist")).quantity
1198+ let fC = bq(cr)
1199+ let fD = bq(cs)
1200+ let fE = D(fC, bF)
1201+ let fF = D(fD, bG)
1202+ let ca = if ((fw == 0))
12491203 then e
1250- else bt(fR, fQ)
1251- let cz = D(co, bH)
1252- let cy = fraction(cz, d, cb)
1253- let cm = G(cy, bG)
1254- let dm = ck("", 500000, cm, bT, co, bU, "", true, false)
1255- let cJ = dm._1
1256- let fN = dm._3
1257- let bX = dm._4
1258- let bZ = dm._5
1259- let bW = dm._6
1260- $Tuple2(nil, makeString(["%d%d%d%d%d%d%d%d", toString(cJ), toString(G(cb, b)), toString(bX), toString(bZ), toString(bW), bV, toString(cm), toString(co)], j))
1204+ else bs(fF, fE)
1205+ let cy = D(cn, bG)
1206+ let cx = fraction(cy, d, ca)
1207+ let cl = G(cx, bF)
1208+ let dl = cj("", 500000, cl, bS, cn, bT, "", true, false)
1209+ let cI = dl._1
1210+ let fB = dl._3
1211+ let bW = dl._4
1212+ let bY = dl._5
1213+ let bV = dl._6
1214+ $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))
12611215 }
12621216
12631217
12641218
1265-@Callable(dg)
1266-func evaluateGetREADONLY (fS,fT) = {
1267- let cB = bO("", fS, fT, this)
1268- let ch = cB._1
1269- let ci = cB._2
1270- let bX = cB._5
1271- let bZ = cB._6
1272- let bW = cB._7
1273- let cc = cB._8
1274- let bV = parseIntValue(cB._9)
1275- $Tuple2(nil, makeString(["%d%d%d%d%d%d%d", toString(ch), toString(ci), toString(bX), toString(bZ), toString(bW), toString(cc), toString(bV)], j))
1219+@Callable(df)
1220+func evaluateGetREADONLY (fG,fH) = {
1221+ let cA = bN("", fG, fH, this)
1222+ let cg = cA._1
1223+ let ch = cA._2
1224+ let bW = cA._5
1225+ let bY = cA._6
1226+ let bV = cA._7
1227+ let cb = cA._8
1228+ let bU = parseIntValue(cA._9)
1229+ $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))
12761230 }
12771231
12781232
1279-@Verifier(fU)
1280-func fV () = {
1281- let fW = {
1282- let dr = ew()
1283- if ($isInstanceOf(dr, "ByteVector"))
1233+@Verifier(fI)
1234+func fJ () = {
1235+ let fK = {
1236+ let dq = ev()
1237+ if ($isInstanceOf(dq, "ByteVector"))
12841238 then {
1285- let eA = dr
1286- eA
1239+ let ez = dq
1240+ ez
12871241 }
1288- else if ($isInstanceOf(dr, "Unit"))
1289- then fU.senderPublicKey
1242+ else if ($isInstanceOf(dq, "Unit"))
1243+ then fI.senderPublicKey
12901244 else throw("Match error")
12911245 }
1292- let dr = fU
1293- if ($isInstanceOf(dr, "Order"))
1246+ let dq = fI
1247+ if ($isInstanceOf(dq, "Order"))
12941248 then {
1295- let cS = dr
1296- let fX = aH()
1297- let as = cR(cS)
1298- let at = sigVerify(cS.bodyBytes, cS.proofs[0], cS.senderPublicKey)
1299- let au = sigVerify(cS.bodyBytes, cS.proofs[1], fX)
1300- if (if (if (as)
1249+ let cR = dq
1250+ let fL = aG()
1251+ let ar = cQ(cR)
1252+ let as = sigVerify(cR.bodyBytes, cR.proofs[0], cR.senderPublicKey)
1253+ let at = sigVerify(cR.bodyBytes, cR.proofs[1], fL)
1254+ if (if (if (ar)
1255+ then as
1256+ else false)
13011257 then at
13021258 else false)
1303- then au
1304- else false)
13051259 then true
1306- else ar(as, at, au)
1260+ else aq(ar, as, at)
13071261 }
1308- else if ($isInstanceOf(dr, "SetScriptTransaction"))
1262+ else if ($isInstanceOf(dq, "SetScriptTransaction"))
13091263 then {
1310- let ex = dr
1311- let fY = blake2b256(value(ex.script))
1312- let fZ = fromBase64String(value(getString(aB, ap())))
1313- let ga = scriptHash(this)
1314- if (if ((fZ == fY))
1315- then (ga != fY)
1264+ let ew = dq
1265+ let fM = blake2b256(value(ew.script))
1266+ let fN = fromBase64String(value(getString(aA, ao())))
1267+ let fO = scriptHash(this)
1268+ if (if ((fN == fM))
1269+ then (fO != fM)
13161270 else false)
13171271 then true
1318- else sigVerify(fU.bodyBytes, fU.proofs[0], fW)
1272+ else sigVerify(fI.bodyBytes, fI.proofs[0], fK)
13191273 }
1320- else sigVerify(fU.bodyBytes, fU.proofs[0], fW)
1274+ else sigVerify(fI.bodyBytes, fI.proofs[0], fK)
13211275 }
13221276
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 6 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let a = 8
55
66 let b = 100000000
77
88 let c = toBigInt(100000000)
99
1010 let d = toBigInt(1000000000000000000)
1111
1212 let e = toBigInt(0)
1313
1414 let f = toBigInt(0)
1515
1616 let g = toBigInt(1)
1717
1818 let h = toBigInt(2)
1919
2020 let i = "WAVES"
2121
2222 let j = "__"
2323
2424 let k = 1
2525
2626 let l = 2
2727
2828 let m = 3
2929
3030 let n = 4
3131
3232 let o = 1
3333
3434 let p = 2
3535
3636 let q = 3
3737
3838 let r = 4
3939
4040 let s = 5
4141
4242 let t = 6
4343
4444 let u = 7
4545
4646 let v = 8
4747
4848 let w = 9
4949
5050 let x = 10
5151
5252 let y = 1
5353
5454 let z = 2
5555
5656 let A = 3
5757
5858 let B = 1
5959
6060 let C = 7
6161
6262 func D (E,F) = fraction(toBigInt(E), d, toBigInt(F))
6363
6464
6565 func G (H,I) = toInt(fraction(H, toBigInt(I), d))
6666
6767
6868 func J (K,L,M) = fraction(K, L, M)
6969
7070
7171 func N (H) = if ((0 > H))
7272 then -(H)
7373 else H
7474
7575
7676 func O (H) = if ((e > H))
7777 then -(H)
7878 else H
7979
8080
81-func P () = "%s__swapContract"
81+func P () = "%s__factoryContract"
8282
8383
84-func Q () = "%s__factoryContract"
84+func Q () = "%s__managerPublicKey"
8585
8686
87-func R () = "%s__managerPublicKey"
87+func R () = "%s__pendingManagerPublicKey"
8888
8989
90-func S () = "%s__pendingManagerPublicKey"
90+func S () = "%s%s__price__last"
9191
9292
93-func T () = "%s%s__price__last"
93+func T (U,V) = makeString(["%s%s%d%d__price__history", toString(U), toString(V)], j)
9494
9595
96-func U (V,W) = makeString(["%s%s%d%d__price__history", toString(V), toString(W)], j)
96+func W (X,Y) = ((("%s%s%s__P__" + X) + "__") + Y)
9797
9898
99-func X (Y,Z) = ((("%s%s%s__P__" + Y) + "__") + Z)
99+func Z (X,Y) = ((("%s%s%s__G__" + X) + "__") + Y)
100100
101101
102-func aa (Y,Z) = ((("%s%s%s__G__" + Y) + "__") + Z)
102+func aa () = "%s__amountAsset"
103103
104104
105-func ab () = "%s__amountAsset"
105+func ab () = "%s__priceAsset"
106106
107107
108-func ac () = "%s__priceAsset"
108+func ac () = "%s__factoryConfig"
109109
110110
111-func ad () = "%s__factoryConfig"
111+func ad () = "%s%s__matcher__publicKey"
112112
113113
114-func ae () = "%s%s__matcher__publicKey"
114+func ae (af) = (("%s%s%s__" + af) + "__mappings__poolContract2LpAsset")
115115
116116
117-func af (ag) = (("%s%s%s__" + ag) + "__mappings__poolContract2LpAsset")
117+func ag (ah,ai) = (((("%d%d%s__" + ah) + "__") + ai) + "__config")
118118
119119
120-func ah (ai,aj) = (((("%d%d%s__" + ai) + "__") + aj) + "__config")
120+func aj (ak) = ("%s%s%s__mappings__baseAsset2internalId__" + ak)
121121
122122
123-func ak (al) = ("%s%s%s__mappings__baseAsset2internalId__" + al)
123+func al () = "%s__shutdown"
124124
125125
126-func am () = "%s__shutdown"
126+func am (an) = ("%s%s__poolWeight__" + an)
127127
128128
129-func an (ao) = ("%s%s__poolWeight__" + ao)
129+func ao () = "%s__allowedLpScriptHash"
130130
131131
132-func ap () = "%s__allowedLpScriptHash"
132+let ap = "%s__feeCollectorAddress"
133+
134+func aq (ar,as,at) = throw(((((("order validation failed: orderValid=" + toString(ar)) + " senderValid=") + toString(as)) + " matcherValid=") + toString(at)))
133135
134136
135-let aq = "%s__feeCollectorAddress"
136-
137-func ar (as,at,au) = throw(((((("order validation failed: orderValid=" + toString(as)) + " senderValid=") + toString(at)) + " matcherValid=") + toString(au)))
137+func au (av,aw) = valueOrErrorMessage(getString(av, aw), makeString(["mandatory ", toString(av), ".", aw, " is not defined"], ""))
138138
139139
140-func av (aw,ax) = valueOrErrorMessage(getString(aw, ax), makeString(["mandatory ", toString(aw), ".", ax, " is not defined"], ""))
140+func ax (av,aw) = valueOrErrorMessage(getInteger(av, aw), makeString(["mandatory ", toString(av), ".", aw, " is not defined"], ""))
141141
142142
143-func ay (aw,ax) = valueOrErrorMessage(getInteger(aw, ax), makeString(["mandatory ", toString(aw), ".", ax, " is not defined"], ""))
143+func ay (az) = throw(makeString(["lp.ride:", az], " "))
144144
145145
146-func az (aA) = throw(makeString(["lp.ride:", aA], " "))
146+let aA = addressFromStringValue(au(this, P()))
147+
148+let aB = addressFromStringValue(au(aA, ap))
149+
150+let aC = {
151+ let aD = invoke(aA, "getInFeeREADONLY", [toString(this)], nil)
152+ if ($isInstanceOf(aD, "Int"))
153+ then aD
154+ else throw(($getType(aD) + " couldn't be cast to Int"))
155+ }
156+
157+let aE = {
158+ let aD = invoke(aA, "getOutFeeREADONLY", [toString(this)], nil)
159+ if ($isInstanceOf(aD, "Int"))
160+ then aD
161+ else throw(($getType(aD) + " couldn't be cast to Int"))
162+ }
163+
164+func aF () = valueOrElse(getBoolean(aA, al()), false)
147165
148166
149-let aB = addressFromStringValue(av(this, Q()))
150-
151-let aC = addressFromStringValue(av(aB, aq))
152-
153-let aD = {
154- let aE = invoke(aB, "getInFeeREADONLY", [toString(this)], nil)
155- if ($isInstanceOf(aE, "Int"))
156- then aE
157- else throw(($getType(aE) + " couldn't be cast to Int"))
158- }
159-
160-let aF = {
161- let aE = invoke(aB, "getOutFeeREADONLY", [toString(this)], nil)
162- if ($isInstanceOf(aE, "Int"))
163- then aE
164- else throw(($getType(aE) + " couldn't be cast to Int"))
165- }
166-
167-func aG () = valueOrElse(getBoolean(aB, am()), false)
167+func aG () = fromBase58String(au(aA, ad()))
168168
169169
170-func aH () = fromBase58String(av(aB, ae()))
171-
172-
173-func aI () = {
174- let aJ = av(this, ab())
175- let aK = av(this, ac())
176- let aj = ay(aB, ak(aK))
177- let ai = ay(aB, ak(aJ))
178- split(av(aB, ah(toString(ai), toString(aj))), j)
170+func aH () = {
171+ let aI = au(this, aa())
172+ let aJ = au(this, ab())
173+ let ai = ax(aA, aj(aJ))
174+ let ah = ax(aA, aj(aI))
175+ split(au(aA, ag(toString(ah), toString(ai))), j)
179176 }
180177
181178
182-func aL (aM) = if ((aM == i))
179+func aK (aL) = if ((aL == i))
183180 then unit
184- else fromBase58String(aM)
181+ else fromBase58String(aL)
185182
186183
187-func aN (aM) = if ((aM == unit))
184+func aM (aL) = if ((aL == unit))
188185 then i
189- else toBase58String(value(aM))
186+ else toBase58String(value(aL))
190187
191188
192-func aO (aP) = $Tuple7(addressFromStringValue(aP[o]), parseIntValue(aP[p]), fromBase58String(aP[q]), aL(aP[r]), aL(aP[s]), parseIntValue(aP[t]), parseIntValue(aP[u]))
189+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]))
193190
194191
195-let aQ = aO(aI())
192+let aP = aN(aH())
196193
197-let aR = aQ
194+let aQ = aP
198195
199-let aS = aR._1
196+let aR = aQ._1
200197
201-let aT = aR._2
198+let aS = aQ._2
202199
203-let aU = aR._3
200+let aT = aQ._3
204201
205-let aV = aR._4
202+let aU = aQ._4
206203
207-let aW = aR._5
204+let aV = aQ._5
208205
209-let aX = aR._6
206+let aW = aQ._6
210207
211-let aY = aR._7
208+let aX = aQ._7
212209
213-func aZ () = split(av(aB, ad()), j)
210+func aY () = split(au(aA, ac()), j)
214211
215212
216-let ba = valueOrErrorMessage(addressFromString(aZ()[B]), "incorrect staking address")
213+let aZ = valueOrErrorMessage(addressFromString(aY()[B]), "incorrect staking address")
217214
218-let bb = valueOrErrorMessage(addressFromString(aZ()[C]), "incorrect staking address")
215+let ba = valueOrErrorMessage(addressFromString(aY()[C]), "incorrect staking address")
219216
220-func bc (bd,be,bf,bg,bh,bi,bj,bk,bl,bm) = makeString(["%d%d%d%d%d%d%d%d%d%d", toString(bd), toString(be), toString(bf), toString(bg), toString(bh), toString(bi), toString(bj), toString(bk), toString(bl), toString(bm)], j)
217+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)
221218
222219
223-func bn (bo,bp,bq,bg,bj,bk) = makeString(["%d%d%d%d%d%d", toString(bo), toString(bp), toString(bq), toString(bg), toString(bj), toString(bk)], j)
220+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)
224221
225222
226-func br (bs) = if ((bs == "WAVES"))
223+func bq (br) = if ((br == "WAVES"))
227224 then wavesBalance(this).available
228- else assetBalance(this, fromBase58String(bs))
225+ else assetBalance(this, fromBase58String(br))
229226
230227
231-func bt (bu,bv) = fraction(bu, d, bv)
228+func bs (bt,bu) = fraction(bt, d, bu)
232229
233230
234-func bw (bx,by,bz,bA) = {
231+func bv (bw,bx,by,bz) = {
232+ let bA = D(by, bw)
235233 let bB = D(bz, bx)
236- let bC = D(bA, by)
237- bt(bC, bB)
234+ bs(bB, bA)
238235 }
239236
240237
241-func bD (bz,bA,bE) = {
242- let bF = aI()
243- let bG = parseIntValue(bF[t])
244- let bH = parseIntValue(bF[u])
245- let bI = bw(bG, bH, bz, bA)
246- let bv = D(bz, bG)
247- let bu = D(bA, bH)
248- let bJ = D(bE, b)
249- let bK = bt(bv, bJ)
250- let bL = bt(bu, bJ)
251-[bI, bK, bL]
238+func bC (by,bz,bD) = {
239+ let bE = aH()
240+ let bF = parseIntValue(bE[t])
241+ let bG = parseIntValue(bE[u])
242+ let bH = bv(bF, bG, by, bz)
243+ let bu = D(by, bF)
244+ let bt = D(bz, bG)
245+ let bI = D(bD, b)
246+ let bJ = bs(bu, bI)
247+ let bK = bs(bt, bI)
248+[bH, bJ, bK]
252249 }
253250
254251
255-func bM (bz,bA,bE) = {
256- let bN = bD(bz, bA, bE)
257-[G(bN[0], b), G(bN[1], b), G(bN[2], b)]
252+func bL (by,bz,bD) = {
253+ let bM = bC(by, bz, bD)
254+[G(bM[0], b), G(bM[1], b), G(bM[2], b)]
258255 }
259256
260257
261-func bO (bP,bQ,bR,Y) = {
262- let bF = aI()
263- let bS = bF[q]
264- let bT = bF[r]
265- let bU = bF[s]
266- let bx = parseIntValue(bF[t])
267- let by = parseIntValue(bF[u])
268- let bV = bF[p]
269- let bW = valueOrErrorMessage(assetInfo(fromBase58String(bS)), (("Asset " + bS) + " doesn't exist")).quantity
270- if ((bS != bQ))
258+func bN (bO,bP,bQ,X) = {
259+ let bE = aH()
260+ let bR = bE[q]
261+ let bS = bE[r]
262+ let bT = bE[s]
263+ let bw = parseIntValue(bE[t])
264+ let bx = parseIntValue(bE[u])
265+ let bU = bE[p]
266+ let bV = valueOrErrorMessage(assetInfo(fromBase58String(bR)), (("Asset " + bR) + " doesn't exist")).quantity
267+ if ((bR != bP))
271268 then throw("Invalid asset passed.")
272269 else {
273- let bX = br(bT)
274- let bY = D(bX, bx)
275- let bZ = br(bU)
276- let ca = D(bZ, by)
277- let cb = bt(ca, bY)
278- let cc = G(cb, b)
279- let cd = D(bR, b)
280- let ce = D(bW, b)
281- let cf = fraction(bY, cd, ce)
282- let cg = fraction(ca, cd, ce)
270+ let bW = bq(bS)
271+ let bX = D(bW, bw)
272+ let bY = bq(bT)
273+ let bZ = D(bY, bx)
274+ let ca = bs(bZ, bX)
275+ let cb = G(ca, b)
276+ let cc = D(bQ, b)
277+ let cd = D(bV, b)
278+ let ce = fraction(bX, cc, cd)
279+ let cf = fraction(bZ, cc, cd)
280+ let cg = G(ce, bw)
283281 let ch = G(cf, bx)
284- let ci = G(cg, by)
285- let cj = if ((bP == ""))
282+ let ci = if ((bO == ""))
286283 then nil
287- else [ScriptTransfer(Y, ch, if ((bT == "WAVES"))
284+ else [ScriptTransfer(X, cg, if ((bS == "WAVES"))
288285 then unit
289- else fromBase58String(bT)), ScriptTransfer(Y, ci, if ((bU == "WAVES"))
286+ else fromBase58String(bS)), ScriptTransfer(X, ch, if ((bT == "WAVES"))
290287 then unit
291- else fromBase58String(bU)), StringEntry(aa(toString(Y), bP), bn(ch, ci, bR, cc, height, lastBlock.timestamp)), IntegerEntry(T(), cc), IntegerEntry(U(height, lastBlock.timestamp), cc)]
292- $Tuple10(ch, ci, bT, bU, bX, bZ, bW, cb, bV, cj)
288+ 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)]
289+ $Tuple10(cg, ch, bS, bT, bW, bY, bV, ca, bU, ci)
293290 }
294291 }
295292
296293
297-func ck (bP,cl,cm,cn,co,cp,Y,cq,cr) = {
298- let bF = aI()
299- let bS = fromBase58String(bF[q])
300- let cs = bF[r]
301- let ct = bF[s]
302- let cu = bF[v]
303- let cv = bF[w]
304- let bG = parseIntValue(bF[t])
305- let bH = parseIntValue(bF[u])
306- let bV = bF[p]
307- let bW = valueOrErrorMessage(assetInfo(bS), (("Asset " + toBase58String(bS)) + " doesn't exist")).quantity
308- let cw = toBase58String(valueOrElse(cn, fromBase58String("WAVES")))
309- let cx = toBase58String(valueOrElse(cp, fromBase58String("WAVES")))
310- if (if ((cs != cw))
294+func cj (bO,ck,cl,cm,cn,co,X,cp,cq) = {
295+ let bE = aH()
296+ let bR = fromBase58String(bE[q])
297+ let cr = bE[r]
298+ let cs = bE[s]
299+ let ct = bE[v]
300+ let cu = bE[w]
301+ let bF = parseIntValue(bE[t])
302+ let bG = parseIntValue(bE[u])
303+ let bU = bE[p]
304+ let bV = valueOrErrorMessage(assetInfo(bR), (("Asset " + toBase58String(bR)) + " doesn't exist")).quantity
305+ let cv = toBase58String(valueOrElse(cm, fromBase58String("WAVES")))
306+ let cw = toBase58String(valueOrElse(co, fromBase58String("WAVES")))
307+ if (if ((cr != cv))
311308 then true
312- else (ct != cx))
309+ else (cs != cw))
313310 then throw("Invalid amt or price asset passed.")
314311 else {
315- let bX = if (cq)
316- then br(cs)
317- else (br(cs) - cm)
318- let bZ = if (cq)
319- then br(ct)
320- else (br(ct) - co)
321- let cy = D(cm, bG)
322- let cz = D(co, bH)
323- let cA = bt(cz, cy)
324- let bY = D(bX, bG)
325- let ca = D(bZ, bH)
326- let cB = if ((bW == 0))
312+ let bW = if (cp)
313+ then bq(cr)
314+ else (bq(cr) - cl)
315+ let bY = if (cp)
316+ then bq(cs)
317+ else (bq(cs) - cn)
318+ let cx = D(cl, bF)
319+ let cy = D(cn, bG)
320+ let cz = bs(cy, cx)
321+ let bX = D(bW, bF)
322+ let bZ = D(bY, bG)
323+ let cA = if ((bV == 0))
327324 then {
328- let cb = e
329- let cC = e
330- let bJ = pow((cy * cz), 0, toBigInt(5), 1, 0, DOWN)
331- $Tuple5(G(bJ, b), G(cy, bG), G(cz, bH), bt((ca + cz), (bY + cy)), cC)
325+ let ca = e
326+ let cB = e
327+ let bI = pow((cx * cy), 0, toBigInt(5), 1, 0, DOWN)
328+ $Tuple5(G(bI, b), G(cx, bF), G(cy, bG), bs((bZ + cy), (bX + cx)), cB)
332329 }
333330 else {
334- let cb = bt(ca, bY)
335- let cC = fraction(O((cb - cA)), d, cb)
336- let cD = D(cl, b)
337- if (if ((cb != e))
338- then (cC > cD)
331+ let ca = bs(bZ, bX)
332+ let cB = fraction(O((ca - cz)), d, ca)
333+ let cC = D(ck, b)
334+ if (if ((ca != e))
335+ then (cB > cC)
339336 else false)
340- then throw(((("Price slippage " + toString(cC)) + " exceeded the passed limit of ") + toString(cD)))
337+ then throw(((("Price slippage " + toString(cB)) + " exceeded the passed limit of ") + toString(cC)))
341338 else {
342- let ce = D(bW, b)
343- let cE = fraction(cy, cb, d)
344- let cF = fraction(cz, d, cb)
345- let cG = if ((cE > cz))
346- then $Tuple2(cF, cz)
347- else $Tuple2(cy, cE)
348- let cH = cG._1
349- let cI = cG._2
350- let bJ = fraction(ce, cI, ca)
351- $Tuple5(G(bJ, b), G(cH, bG), G(cI, bH), cb, cC)
339+ let cd = D(bV, b)
340+ let cD = fraction(cx, ca, d)
341+ let cE = fraction(cy, d, ca)
342+ let cF = if ((cD > cy))
343+ then $Tuple2(cE, cy)
344+ else $Tuple2(cx, cD)
345+ let cG = cF._1
346+ let cH = cF._2
347+ let bI = fraction(cd, cH, bZ)
348+ $Tuple5(G(bI, b), G(cG, bF), G(cH, bG), ca, cB)
352349 }
353350 }
354- let cJ = cB._1
355- let cK = cB._2
356- let cL = cB._3
357- let cc = G(cB._4, b)
358- let cM = G(cB._5, b)
359- if ((0 >= cJ))
351+ let cI = cA._1
352+ let cJ = cA._2
353+ let cK = cA._3
354+ let cb = G(cA._4, b)
355+ let cL = G(cA._5, b)
356+ if ((0 >= cI))
360357 then throw("Invalid calculations. LP calculated is less than zero.")
361358 else {
362- let cN = if (!(cr))
359+ let cM = if (!(cq))
363360 then 0
364- else cJ
365- let cO = (cm - cK)
366- let cP = (co - cL)
367- let cQ = [IntegerEntry(T(), cc), IntegerEntry(U(height, lastBlock.timestamp), cc), StringEntry(X(Y, bP), bc(cK, cL, cN, cc, cl, cM, height, lastBlock.timestamp, cO, cP))]
368- $Tuple13(cJ, cN, cc, bX, bZ, bW, bS, bV, cQ, cO, cP, cn, cp)
361+ else cI
362+ let cN = (cl - cJ)
363+ let cO = (cn - cK)
364+ 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))]
365+ $Tuple13(cI, cM, cb, bW, bY, bV, bR, bU, cP, cN, cO, cm, co)
369366 }
370367 }
371368 }
372369
373370
374-func cR (cS) = {
375- let bF = aI()
376- let cT = bF[r]
377- let cU = bF[s]
378- let bV = parseIntValue(bF[p])
379- let bG = parseIntValue(bF[t])
380- let bH = parseIntValue(bF[u])
381- let cV = br(cT)
382- let cW = br(cU)
383- let cb = if ((cS.orderType == Buy))
384- then bw(bG, bH, (cV + cS.amount), cW)
385- else bw(bG, bH, (cV - cS.amount), cW)
386- let cc = G(cb, b)
387- if (if (if (aG())
371+func cQ (cR) = {
372+ let bE = aH()
373+ let cS = bE[r]
374+ let cT = bE[s]
375+ let bU = parseIntValue(bE[p])
376+ let bF = parseIntValue(bE[t])
377+ let bG = parseIntValue(bE[u])
378+ let cU = bq(cS)
379+ let cV = bq(cT)
380+ let ca = if ((cR.orderType == Buy))
381+ then bv(bF, bG, (cU + cR.amount), cV)
382+ else bv(bF, bG, (cU - cR.amount), cV)
383+ let cb = G(ca, b)
384+ if (if (if (aF())
388385 then true
389- else (bV == m))
386+ else (bU == m))
390387 then true
391- else (bV == n))
388+ else (bU == n))
392389 then throw("Exchange operations disabled")
393390 else {
394- let cX = cS.assetPair.amountAsset
395- let cY = if ((cX == unit))
391+ let cW = cR.assetPair.amountAsset
392+ let cX = if ((cW == unit))
396393 then "WAVES"
397- else toBase58String(value(cX))
398- let cZ = cS.assetPair.priceAsset
399- let da = if ((cZ == unit))
394+ else toBase58String(value(cW))
395+ let cY = cR.assetPair.priceAsset
396+ let cZ = if ((cY == unit))
400397 then "WAVES"
401- else toBase58String(value(cZ))
402- if (if ((cY != cT))
398+ else toBase58String(value(cY))
399+ if (if ((cX != cS))
403400 then true
404- else (da != cU))
401+ else (cZ != cT))
405402 then throw("Wrong order assets.")
406403 else {
407- let db = cS.price
408- let dc = fraction(b, bH, bG)
409- let dd = J(db, b, dc)
410- let de = if ((cS.orderType == Buy))
411- then (cc >= dd)
412- else (dd >= cc)
404+ let da = cR.price
405+ let db = fraction(b, bG, bF)
406+ let dc = J(da, b, db)
407+ let dd = if ((cR.orderType == Buy))
408+ then (cb >= dc)
409+ else (dc >= cb)
413410 true
414411 }
415412 }
416413 }
417414
418415
419-func df (dg) = if ((size(dg.payments) != 1))
416+func de (df) = if ((size(df.payments) != 1))
420417 then throw("exactly 1 payment is expected")
421418 else {
422- let dh = value(dg.payments[0])
423- let bQ = value(dh.assetId)
424- let di = dh.amount
425- let cB = bO(toBase58String(dg.transactionId), toBase58String(bQ), di, dg.caller)
426- let ch = cB._1
427- let ci = cB._2
428- let bV = parseIntValue(cB._9)
429- let cj = cB._10
430- if (if (aG())
419+ let dg = value(df.payments[0])
420+ let bP = value(dg.assetId)
421+ let dh = dg.amount
422+ let cA = bN(toBase58String(df.transactionId), toBase58String(bP), dh, df.caller)
423+ let cg = cA._1
424+ let ch = cA._2
425+ let bU = parseIntValue(cA._9)
426+ let ci = cA._10
427+ if (if (aF())
431428 then true
432- else (bV == n))
433- then throw(("Get operation is blocked by admin. Status = " + toString(bV)))
434- else $Tuple5(ch, ci, di, bQ, cj)
429+ else (bU == n))
430+ then throw(("Get operation is blocked by admin. Status = " + toString(bU)))
431+ else $Tuple5(cg, ch, dh, bP, ci)
435432 }
436433
437434
438-func dj (dg,cl,cr) = if ((size(dg.payments) != 2))
435+func di (df,ck,cq) = if ((size(df.payments) != 2))
439436 then throw("exactly 2 payments are expected")
440437 else {
441- let dk = value(dg.payments[0])
442- let dl = value(dg.payments[1])
443- let dm = ck(toBase58String(dg.transactionId), cl, dk.amount, dk.assetId, dl.amount, dl.assetId, toString(dg.caller), false, cr)
444- let bV = parseIntValue(dm._8)
445- if (if (if (aG())
438+ let dj = value(df.payments[0])
439+ let dk = value(df.payments[1])
440+ let dl = cj(toBase58String(df.transactionId), ck, dj.amount, dj.assetId, dk.amount, dk.assetId, toString(df.caller), false, cq)
441+ let bU = parseIntValue(dl._8)
442+ if (if (if (aF())
446443 then true
447- else (bV == l))
444+ else (bU == l))
448445 then true
449- else (bV == n))
450- then throw(("Put operation is blocked by admin. Status = " + toString(bV)))
451- else dm
446+ else (bU == n))
447+ then throw(("Put operation is blocked by admin. Status = " + toString(bU)))
448+ else dl
452449 }
453450
454451
455-func dn (do) = {
456- let dp = invoke(aB, "emit", [do], nil)
457- if ((dp == dp))
452+func dm (dn) = {
453+ let do = invoke(aA, "emit", [dn], nil)
454+ if ((do == do))
458455 then {
459- let dq = {
460- let dr = dp
461- if ($isInstanceOf(dr, "Address"))
456+ let dp = {
457+ let dq = do
458+ if ($isInstanceOf(dq, "Address"))
462459 then {
463- let ds = dr
464- invoke(ds, "emit", [do], nil)
460+ let dr = dq
461+ invoke(dr, "emit", [dn], nil)
465462 }
466463 else unit
467464 }
468- if ((dq == dq))
469- then do
465+ if ((dp == dp))
466+ then dn
470467 else throw("Strict value is not equal to itself.")
471468 }
472469 else throw("Strict value is not equal to itself.")
473470 }
474471
475472
476-func dt (do,du) = {
477- let dv = if ((du == 0))
473+func ds (dn,dt) = {
474+ let du = if ((dt == 0))
478475 then 0
479- else fraction(do, du, b)
480- $Tuple2((do - dv), dv)
476+ else fraction(dn, dt, b)
477+ $Tuple2((dn - du), du)
481478 }
482479
483480
484-func dw (dx,dy,Y,Z) = {
485- let dz = (Z == unit)
486- let dA = br(aN(aV))
487- let dB = br(aN(aW))
488- let dC = if ((dy == aV))
481+func dv (dw,dx,X,Y) = {
482+ let dy = (Y == unit)
483+ let dz = bq(aM(aU))
484+ let dA = bq(aM(aV))
485+ let dB = if ((dx == aU))
489486 then true
490- else if ((dy == aW))
487+ else if ((dx == aV))
491488 then false
492- else az("invalid asset")
493- let dD = if (dz)
494- then $Tuple2(dA, dB)
495- else if (dC)
496- then $Tuple2((dA - dx), dB)
497- else $Tuple2(dA, (dB - dx))
498- let dE = dD._1
499- let dF = dD._2
500- let dG = if (dC)
501- then $Tuple2(dx, 0)
502- else $Tuple2(0, dx)
503- let dH = dG._1
504- let dI = dG._2
505- let dJ = dt(dH, aD)._1
506- let dK = dt(dI, aD)._1
507- let dL = dt(dx, aD)
508- let dM = dL._1
509- let dv = dL._2
489+ else ay("invalid asset")
490+ let dC = if (dy)
491+ then $Tuple2(dz, dA)
492+ else if (dB)
493+ then $Tuple2((dz - dw), dA)
494+ else $Tuple2(dz, (dA - dw))
495+ let dD = dC._1
496+ let dE = dC._2
497+ let dF = if (dB)
498+ then $Tuple2(dw, 0)
499+ else $Tuple2(0, dw)
500+ let dG = dF._1
501+ let dH = dF._2
502+ let dI = ds(dG, aC)._1
503+ let dJ = ds(dH, aC)._1
504+ let dK = ds(dw, aC)
505+ let dL = dK._1
506+ let du = dK._2
507+ let dM = (dD + dI)
510508 let dN = (dE + dJ)
511- let dO = (dF + dK)
512- let dP = bt(D(dO, aY), D(dN, aX))
513- let dQ = G(dP, b)
514- let dR = if (dC)
515- then dE
516- else dF
517- let dS = toBigInt(dR)
518- let dT = toBigInt(valueOrErrorMessage(assetInfo(aU), (("asset " + toBase58String(aU)) + " doesn't exist")).quantity)
519- let dU = if ((dT > f))
509+ let dO = bs(D(dN, aX), D(dM, aW))
510+ let dP = G(dO, b)
511+ let dQ = if (dB)
512+ then dD
513+ else dE
514+ let dR = toBigInt(dQ)
515+ let dS = toBigInt(valueOrErrorMessage(assetInfo(aT), (("asset " + toBase58String(aT)) + " doesn't exist")).quantity)
516+ let dT = if ((dS > f))
520517 then true
521- else az("initial deposit requires all coins")
522- if ((dU == dU))
518+ else ay("initial deposit requires all coins")
519+ if ((dT == dT))
523520 then {
524- let dV = toBigInt(dM)
525- let dW = max([0, toInt(((dT * (sqrtBigInt((d + ((dV * d) / dS)), 18, 18, DOWN) - d)) / d))])
526- let cQ = if (dz)
521+ let dU = toBigInt(dL)
522+ let dV = max([0, toInt(((dS * (sqrtBigInt((d + ((dU * d) / dR)), 18, 18, DOWN) - d)) / d))])
523+ let cP = if (dy)
527524 then nil
528- else [IntegerEntry(T(), dQ), IntegerEntry(U(height, lastBlock.timestamp), dQ), StringEntry(X(toString(value(Y)), toBase58String(value(Z))), bc(dH, dI, dW, dQ, 0, 0, height, lastBlock.timestamp, 0, 0))]
529- let dX = bt(D(dF, aY), D(dE, aX))
530- let dY = G(dX, b)
531- let dZ = {
532- let ea = if (dC)
533- then $Tuple2(dH, dE)
534- else $Tuple2(dI, dF)
535- let do = ea._1
536- let eb = ea._2
537- let ec = toInt(fraction(dT, toBigInt((do / 2)), toBigInt(eb)))
538- fraction((dW - ec), b, ec)
525+ else [IntegerEntry(S(), dP), IntegerEntry(T(height, lastBlock.timestamp), dP), StringEntry(W(toString(value(X)), toBase58String(value(Y))), bb(dG, dH, dV, dP, 0, 0, height, lastBlock.timestamp, 0, 0))]
526+ let dW = bs(D(dE, aX), D(dD, aW))
527+ let dX = G(dW, b)
528+ let dY = {
529+ let dZ = if (dB)
530+ then $Tuple2(dG, dD)
531+ else $Tuple2(dH, dE)
532+ let dn = dZ._1
533+ let ea = dZ._2
534+ let eb = toInt(fraction(dS, toBigInt((dn / 2)), toBigInt(ea)))
535+ fraction((dV - eb), b, eb)
539536 }
540- $Tuple4(dW, cQ, dv, dZ)
537+ $Tuple4(dV, cP, du, dY)
541538 }
542539 else throw("Strict value is not equal to itself.")
543540 }
544541
545542
546-func ed (ee,dM,dy,Y,Z) = {
547- let dz = (Z == unit)
548- let ef = [if ((dy == aU))
543+func ec (ed,dL,dx,X,Y) = {
544+ let dy = (Y == unit)
545+ let ee = [if ((dx == aT))
549546 then true
550- else az("invalid lp asset")]
551- if ((ef == ef))
547+ else ay("invalid lp asset")]
548+ if ((ee == ee))
552549 then {
553- let eg = if ((ee == aV))
550+ let ef = if ((ed == aU))
554551 then true
555- else if ((ee == aW))
552+ else if ((ed == aV))
556553 then false
557- else az("invalid asset")
558- let eh = if (eg)
559- then toBigInt(br(aN(aV)))
560- else toBigInt(br(aN(aW)))
561- let ei = br(aN(aV))
562- let ej = br(aN(aW))
563- let ek = if (eg)
564- then ei
565- else ej
566- let el = toBigInt(ek)
567- let dT = toBigInt(valueOrErrorMessage(assetInfo(aU), (("asset " + toBase58String(aU)) + " doesn't exist")).quantity)
568- let em = toBigInt(dM)
569- let en = max([0, toInt(((eh * (d - pow((d - ((em * d) / dT)), 18, h, 0, 18, DOWN))) / d))])
570- let eo = dt(en, aF)
571- let ep = eo._1
572- let dv = eo._2
573- let eq = if (eg)
574- then $Tuple4(ep, 0, (ei - en), ej)
575- else $Tuple4(0, ep, ei, (ej - en))
576- let er = eq._1
577- let es = eq._2
578- let et = eq._3
579- let eu = eq._4
580- let dP = bt(D(eu, aY), D(et, aX))
581- let dQ = G(dP, b)
582- let cQ = if (dz)
554+ else ay("invalid asset")
555+ let eg = if (ef)
556+ then toBigInt(bq(aM(aU)))
557+ else toBigInt(bq(aM(aV)))
558+ let eh = bq(aM(aU))
559+ let ei = bq(aM(aV))
560+ let ej = if (ef)
561+ then eh
562+ else ei
563+ let ek = toBigInt(ej)
564+ let dS = toBigInt(valueOrErrorMessage(assetInfo(aT), (("asset " + toBase58String(aT)) + " doesn't exist")).quantity)
565+ let el = toBigInt(dL)
566+ let em = max([0, toInt(((eg * (d - pow((d - ((el * d) / dS)), 18, h, 0, 18, DOWN))) / d))])
567+ let en = ds(em, aE)
568+ let eo = en._1
569+ let du = en._2
570+ let ep = if (ef)
571+ then $Tuple4(eo, 0, (eh - em), ei)
572+ else $Tuple4(0, eo, eh, (ei - em))
573+ let eq = ep._1
574+ let er = ep._2
575+ let es = ep._3
576+ let et = ep._4
577+ let dO = bs(D(et, aX), D(es, aW))
578+ let dP = G(dO, b)
579+ let cP = if (dy)
583580 then nil
584- else [StringEntry(aa(toString(value(Y)), toBase58String(value(Z))), bn(er, es, dM, dQ, height, lastBlock.timestamp)), IntegerEntry(T(), dQ), IntegerEntry(U(height, lastBlock.timestamp), dQ)]
585- let dX = bt(D(ej, aY), D(ei, aX))
586- let dY = G(dX, b)
587- let dZ = {
588- let ev = (toInt(fraction(eh, em, dT)) * 2)
589- fraction((ep - ev), b, ev)
581+ else [StringEntry(Z(toString(value(X)), toBase58String(value(Y))), bm(eq, er, dL, dP, height, lastBlock.timestamp)), IntegerEntry(S(), dP), IntegerEntry(T(height, lastBlock.timestamp), dP)]
582+ let dW = bs(D(ei, aX), D(eh, aW))
583+ let dX = G(dW, b)
584+ let dY = {
585+ let eu = (toInt(fraction(eg, el, dS)) * 2)
586+ fraction((eo - eu), b, eu)
590587 }
591- $Tuple4(ep, cQ, dv, dZ)
588+ $Tuple4(eo, cP, du, dY)
592589 }
593590 else throw("Strict value is not equal to itself.")
594591 }
595592
596593
597-func ew () = {
598- let dr = getString(R())
599- if ($isInstanceOf(dr, "String"))
594+func ev () = {
595+ let dq = getString(Q())
596+ if ($isInstanceOf(dq, "String"))
600597 then {
601- let ex = dr
602- fromBase58String(ex)
598+ let ew = dq
599+ fromBase58String(ew)
603600 }
604- else if ($isInstanceOf(dr, "Unit"))
601+ else if ($isInstanceOf(dq, "Unit"))
605602 then unit
606603 else throw("Match error")
607604 }
608605
609606
610-func ey () = {
611- let dr = getString(S())
612- if ($isInstanceOf(dr, "String"))
607+func ex () = {
608+ let dq = getString(R())
609+ if ($isInstanceOf(dq, "String"))
613610 then {
614- let ex = dr
615- fromBase58String(ex)
611+ let ew = dq
612+ fromBase58String(ew)
616613 }
617- else if ($isInstanceOf(dr, "Unit"))
614+ else if ($isInstanceOf(dq, "Unit"))
618615 then unit
619616 else throw("Match error")
620617 }
621618
622619
623-func ez (dg) = {
624- let dr = ew()
625- if ($isInstanceOf(dr, "ByteVector"))
620+func ey (df) = {
621+ let dq = ev()
622+ if ($isInstanceOf(dq, "ByteVector"))
626623 then {
627- let eA = dr
628- (dg.callerPublicKey == eA)
624+ let ez = dq
625+ (df.callerPublicKey == ez)
629626 }
630- else if ($isInstanceOf(dr, "Unit"))
631- then (dg.caller == this)
627+ else if ($isInstanceOf(dq, "Unit"))
628+ then (df.caller == this)
632629 else throw("Match error")
633630 }
634631
635632
636-func eB (dg) = {
637- let eC = throw("Permission denied")
638- let dr = ew()
639- if ($isInstanceOf(dr, "ByteVector"))
633+func eA (df) = {
634+ let eB = throw("Permission denied")
635+ let dq = ev()
636+ if ($isInstanceOf(dq, "ByteVector"))
640637 then {
641- let eA = dr
642- if ((dg.callerPublicKey == eA))
638+ let ez = dq
639+ if ((df.callerPublicKey == ez))
643640 then true
644- else eC
641+ else eB
645642 }
646- else if ($isInstanceOf(dr, "Unit"))
647- then if ((dg.caller == this))
643+ else if ($isInstanceOf(dq, "Unit"))
644+ then if ((df.caller == this))
648645 then true
649- else eC
646+ else eB
650647 else throw("Match error")
651648 }
652649
653650
654-@Callable(dg)
655-func calculateAmountOutForSwapAndSendTokens (eD,eE,eF,eG) = {
656- let ef = [if ((value(dg.payments[0]).amount >= eD))
657- then true
658- else az("Wrong amount"), if ((dg.caller == addressFromStringValue(av(this, P()))))
659- then true
660- else az("Permission denied")]
661- if ((ef == ef))
651+@Callable(df)
652+func setManager (eC) = {
653+ let eD = eA(df)
654+ if ((eD == eD))
662655 then {
663- let dh = value(dg.payments[0])
664- let eH = toBase58String(value(dh.assetId))
665- let eI = if ((eE == false))
666- then {
667- let eI = av(this, ac())
668- eI
669- }
670- else {
671- let eI = av(this, ab())
672- eI
673- }
674- let eJ = (br(eH) - value(dg.payments[0]).amount)
675- let eK = br(eI)
676- let eL = ((eK * eD) / (eJ + eD))
677- let eM = [(eL >= eF), "Exchange resulted in fewer coins than expected"]
678- if ((eM == eM))
679- then [ScriptTransfer(addressFromStringValue(eG), eL, fromBase58String(eI))]
656+ let eE = fromBase58String(eC)
657+ if ((eE == eE))
658+ then [StringEntry(R(), eC)]
680659 else throw("Strict value is not equal to itself.")
681660 }
682661 else throw("Strict value is not equal to itself.")
683662 }
684663
685664
686665
687-@Callable(dg)
688-func setSwapContract (eN) = {
689- let eO = eB(dg)
690- if ((eO == eO))
691- then [StringEntry(P(), eN)]
692- else throw("Strict value is not equal to itself.")
693- }
694-
695-
696-
697-@Callable(dg)
698-func setManager (eP) = {
699- let eO = eB(dg)
700- if ((eO == eO))
666+@Callable(df)
667+func confirmManager () = {
668+ let eF = ex()
669+ let eG = if (isDefined(eF))
670+ then true
671+ else throw("No pending manager")
672+ if ((eG == eG))
701673 then {
702- let eQ = fromBase58String(eP)
703- if ((eQ == eQ))
704- then [StringEntry(S(), eP)]
674+ let eH = if ((df.callerPublicKey == value(eF)))
675+ then true
676+ else throw("You are not pending manager")
677+ if ((eH == eH))
678+ then [StringEntry(Q(), toBase58String(value(eF))), DeleteEntry(R())]
705679 else throw("Strict value is not equal to itself.")
706680 }
707681 else throw("Strict value is not equal to itself.")
708682 }
709683
710684
711685
712-@Callable(dg)
713-func confirmManager () = {
714- let eR = ey()
715- let eS = if (isDefined(eR))
716- then true
717- else throw("No pending manager")
718- if ((eS == eS))
719- then {
720- let eT = if ((dg.callerPublicKey == value(eR)))
721- then true
722- else throw("You are not pending manager")
723- if ((eT == eT))
724- then [StringEntry(R(), toBase58String(value(eR))), DeleteEntry(S())]
725- else throw("Strict value is not equal to itself.")
726- }
727- else throw("Strict value is not equal to itself.")
728- }
729-
730-
731-
732-@Callable(dg)
733-func put (cl,eU) = if ((0 > cl))
686+@Callable(df)
687+func put (ck,eI) = if ((0 > ck))
734688 then throw("Invalid slippageTolerance passed")
735689 else {
736- let dm = dj(dg, cl, true)
737- let cN = dm._2
738- let bS = dm._7
739- let cj = dm._9
740- let cO = dm._10
741- let cP = dm._11
742- let eV = dm._12
743- let eW = dm._13
744- let dp = invoke(aB, "emit", [cN], nil)
745- if ((dp == dp))
690+ let dl = di(df, ck, true)
691+ let cM = dl._2
692+ let bR = dl._7
693+ let ci = dl._9
694+ let cN = dl._10
695+ let cO = dl._11
696+ let eJ = dl._12
697+ let eK = dl._13
698+ let do = invoke(aA, "emit", [cM], nil)
699+ if ((do == do))
746700 then {
747- let dq = {
748- let dr = dp
749- if ($isInstanceOf(dr, "Address"))
701+ let dp = {
702+ let dq = do
703+ if ($isInstanceOf(dq, "Address"))
750704 then {
751- let ds = dr
752- invoke(ds, "emit", [cN], nil)
705+ let dr = dq
706+ invoke(dr, "emit", [cM], nil)
753707 }
754708 else unit
755709 }
756- if ((dq == dq))
710+ if ((dp == dp))
757711 then {
758- let eX = if ((cO > 0))
759- then invoke(bb, "put", nil, [AttachedPayment(eV, cO)])
712+ let eL = if ((cN > 0))
713+ then invoke(ba, "put", nil, [AttachedPayment(eJ, cN)])
760714 else nil
761- if ((eX == eX))
715+ if ((eL == eL))
762716 then {
763- let eY = if ((cP > 0))
764- then invoke(bb, "put", nil, [AttachedPayment(eW, cP)])
717+ let eM = if ((cO > 0))
718+ then invoke(ba, "put", nil, [AttachedPayment(eK, cO)])
765719 else nil
766- if ((eY == eY))
720+ if ((eM == eM))
767721 then {
768- let eZ = if (eU)
722+ let eN = if (eI)
769723 then {
770- let fa = invoke(ba, "stake", nil, [AttachedPayment(bS, cN)])
771- if ((fa == fa))
724+ let eO = invoke(aZ, "stake", nil, [AttachedPayment(bR, cM)])
725+ if ((eO == eO))
772726 then nil
773727 else throw("Strict value is not equal to itself.")
774728 }
775- else [ScriptTransfer(dg.caller, cN, bS)]
776- (cj ++ eZ)
729+ else [ScriptTransfer(df.caller, cM, bR)]
730+ (ci ++ eN)
777731 }
778732 else throw("Strict value is not equal to itself.")
779733 }
780734 else throw("Strict value is not equal to itself.")
781735 }
782736 else throw("Strict value is not equal to itself.")
783737 }
784738 else throw("Strict value is not equal to itself.")
785739 }
786740
787741
788742
789-@Callable(dg)
790-func putForFree (fb) = if ((0 > fb))
743+@Callable(df)
744+func putForFree (eP) = if ((0 > eP))
791745 then throw("Invalid value passed")
792746 else {
793- let dm = dj(dg, fb, false)
794- dm._9
747+ let dl = di(df, eP, false)
748+ dl._9
795749 }
796750
797751
798752
799-@Callable(dg)
800-func putOneTkn (fc,fd) = {
801- let fe = {
802- let aE = invoke(aB, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
803- if ($isInstanceOf(aE, "Boolean"))
804- then aE
805- else throw(($getType(aE) + " couldn't be cast to Boolean"))
753+@Callable(df)
754+func putOneTkn (eQ,eR) = {
755+ let eS = {
756+ let aD = invoke(aA, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
757+ if ($isInstanceOf(aD, "Boolean"))
758+ then aD
759+ else throw(($getType(aD) + " couldn't be cast to Boolean"))
806760 }
807- let ff = if (if (if (aG())
761+ let eT = if (if (if (aF())
808762 then true
809- else (aT == l))
763+ else (aS == l))
810764 then true
811- else (aT == n))
765+ else (aS == n))
812766 then true
813- else fe
814- let ef = [if (if (!(ff))
767+ else eS
768+ let ee = [if (if (!(eT))
815769 then true
816- else ez(dg))
770+ else ey(df))
817771 then true
818- else az("put operation is blocked by admin"), if ((size(dg.payments) == 1))
772+ else ay("put operation is blocked by admin"), if ((size(df.payments) == 1))
819773 then true
820- else az("exactly 1 payment are expected")]
821- if ((ef == ef))
774+ else ay("exactly 1 payment are expected")]
775+ if ((ee == ee))
822776 then {
823- let fg = dg.payments[0]
824- let dy = fg.assetId
825- let dx = fg.amount
826- let Y = dg.caller
827- let Z = dg.transactionId
828- let fh = dw(dx, dy, Y, Z)
829- if ((fh == fh))
777+ let eU = df.payments[0]
778+ let dx = eU.assetId
779+ let dw = eU.amount
780+ let X = df.caller
781+ let Y = df.transactionId
782+ let eV = dv(dw, dx, X, Y)
783+ if ((eV == eV))
830784 then {
831- let fi = fh._4
832- let dv = fh._3
833- let cQ = fh._2
834- let fj = fh._1
835- let fk = if (if ((fc > 0))
836- then (fc > fj)
785+ let eW = eV._4
786+ let du = eV._3
787+ let cP = eV._2
788+ let eX = eV._1
789+ let eY = if (if ((eQ > 0))
790+ then (eQ > eX)
837791 else false)
838- then az(makeString(["amount to receive is less than ", toString(fc)], ""))
839- else fj
840- let dp = dn(fk)
841- if ((dp == dp))
792+ then ay(makeString(["amount to receive is less than ", toString(eQ)], ""))
793+ else eX
794+ let do = dm(eY)
795+ if ((do == do))
842796 then {
843- let eZ = if (fd)
797+ let eN = if (eR)
844798 then {
845- let fl = invoke(ba, "stake", nil, [AttachedPayment(aU, fk)])
846- if ((fl == fl))
799+ let eZ = invoke(aZ, "stake", nil, [AttachedPayment(aT, eY)])
800+ if ((eZ == eZ))
847801 then nil
848802 else throw("Strict value is not equal to itself.")
849803 }
850- else [ScriptTransfer(dg.caller, fk, aU)]
851- let fm = if ((dv > 0))
852- then [ScriptTransfer(aC, dv, dy)]
804+ else [ScriptTransfer(df.caller, eY, aT)]
805+ let fa = if ((du > 0))
806+ then [ScriptTransfer(aB, du, dx)]
853807 else nil
854- $Tuple2(((cQ ++ eZ) ++ fm), fk)
808+ $Tuple2(((cP ++ eN) ++ fa), eY)
855809 }
856810 else throw("Strict value is not equal to itself.")
857811 }
858812 else throw("Strict value is not equal to itself.")
859813 }
860814 else throw("Strict value is not equal to itself.")
861815 }
862816
863817
864818
865-@Callable(dg)
866-func putOneTknREADONLY (dy,dx) = {
867- let fn = dw(dx, aL(dy), unit, unit)
868- let fj = fn._1
869- let cQ = fn._2
870- let dv = fn._3
871- let fi = fn._4
872- $Tuple2(nil, $Tuple3(fj, dv, fi))
819+@Callable(df)
820+func putOneTknREADONLY (dx,dw) = {
821+ let fb = dv(dw, aK(dx), unit, unit)
822+ let eX = fb._1
823+ let cP = fb._2
824+ let du = fb._3
825+ let eW = fb._4
826+ $Tuple2(nil, $Tuple3(eX, du, eW))
873827 }
874828
875829
876830
877-@Callable(dg)
878-func getOneTkn (fo,fc) = {
879- let fe = {
880- let aE = invoke(aB, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
881- if ($isInstanceOf(aE, "Boolean"))
882- then aE
883- else throw(($getType(aE) + " couldn't be cast to Boolean"))
831+@Callable(df)
832+func getOneTkn (fc,eQ) = {
833+ let eS = {
834+ let aD = invoke(aA, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
835+ if ($isInstanceOf(aD, "Boolean"))
836+ then aD
837+ else throw(($getType(aD) + " couldn't be cast to Boolean"))
884838 }
885- let fp = if (if (aG())
839+ let fd = if (if (aF())
886840 then true
887- else (aT == n))
841+ else (aS == n))
888842 then true
889- else fe
890- let ef = [if (if (!(fp))
843+ else eS
844+ let ee = [if (if (!(fd))
891845 then true
892- else ez(dg))
846+ else ey(df))
893847 then true
894- else az("get operation is blocked by admin"), if ((size(dg.payments) == 1))
848+ else ay("get operation is blocked by admin"), if ((size(df.payments) == 1))
895849 then true
896- else az("exactly 1 payment are expected")]
897- if ((ef == ef))
850+ else ay("exactly 1 payment are expected")]
851+ if ((ee == ee))
898852 then {
899- let ee = aL(fo)
900- let fg = dg.payments[0]
901- let dy = fg.assetId
902- let dM = fg.amount
903- let Y = dg.caller
904- let Z = dg.transactionId
905- let fq = ed(ee, dM, dy, Y, Z)
906- if ((fq == fq))
853+ let ed = aK(fc)
854+ let eU = df.payments[0]
855+ let dx = eU.assetId
856+ let dL = eU.amount
857+ let X = df.caller
858+ let Y = df.transactionId
859+ let fe = ec(ed, dL, dx, X, Y)
860+ if ((fe == fe))
907861 then {
908- let fi = fq._4
909- let dv = fq._3
910- let cQ = fq._2
911- let fr = fq._1
912- let do = if (if ((fc > 0))
913- then (fc > fr)
862+ let eW = fe._4
863+ let du = fe._3
864+ let cP = fe._2
865+ let ff = fe._1
866+ let dn = if (if ((eQ > 0))
867+ then (eQ > ff)
914868 else false)
915- then az(makeString(["amount to receive is less than ", toString(fc)], ""))
916- else fr
917- let fs = invoke(aB, "burn", [dM], [AttachedPayment(dy, dM)])
918- if ((fs == fs))
869+ then ay(makeString(["amount to receive is less than ", toString(eQ)], ""))
870+ else ff
871+ let fg = invoke(aA, "burn", [dL], [AttachedPayment(dx, dL)])
872+ if ((fg == fg))
919873 then {
920- let ft = [ScriptTransfer(Y, do, ee)]
921- let fm = if ((dv > 0))
922- then [ScriptTransfer(aC, dv, ee)]
874+ let fh = [ScriptTransfer(X, dn, ed)]
875+ let fa = if ((du > 0))
876+ then [ScriptTransfer(aB, du, ed)]
923877 else nil
924- $Tuple2(((cQ ++ ft) ++ fm), do)
878+ $Tuple2(((cP ++ fh) ++ fa), dn)
925879 }
926880 else throw("Strict value is not equal to itself.")
927881 }
928882 else throw("Strict value is not equal to itself.")
929883 }
930884 else throw("Strict value is not equal to itself.")
931885 }
932886
933887
934888
935-@Callable(dg)
936-func getOneTknREADONLY (ee,dM) = {
937- let fu = ed(aL(ee), dM, aU, unit, unit)
938- let fr = fu._1
939- let cQ = fu._2
940- let dv = fu._3
941- let fi = fu._4
942- $Tuple2(nil, $Tuple3(fr, dv, fi))
889+@Callable(df)
890+func getOneTknREADONLY (ed,dL) = {
891+ let fi = ec(aK(ed), dL, aT, unit, unit)
892+ let ff = fi._1
893+ let cP = fi._2
894+ let du = fi._3
895+ let eW = fi._4
896+ $Tuple2(nil, $Tuple3(ff, du, eW))
943897 }
944898
945899
946900
947-@Callable(dg)
948-func unstakeAndGetOneTkn (fv,fo,fc) = {
949- let fe = {
950- let aE = invoke(aB, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
951- if ($isInstanceOf(aE, "Boolean"))
952- then aE
953- else throw(($getType(aE) + " couldn't be cast to Boolean"))
901+@Callable(df)
902+func unstakeAndGetOneTkn (fj,fc,eQ) = {
903+ let eS = {
904+ let aD = invoke(aA, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
905+ if ($isInstanceOf(aD, "Boolean"))
906+ then aD
907+ else throw(($getType(aD) + " couldn't be cast to Boolean"))
954908 }
955- let fp = if (if (aG())
909+ let fd = if (if (aF())
956910 then true
957- else (aT == n))
911+ else (aS == n))
958912 then true
959- else fe
960- let ef = [if (if (!(fp))
913+ else eS
914+ let ee = [if (if (!(fd))
961915 then true
962- else ez(dg))
916+ else ey(df))
963917 then true
964- else az("get operation is blocked by admin"), if ((size(dg.payments) == 0))
918+ else ay("get operation is blocked by admin"), if ((size(df.payments) == 0))
965919 then true
966- else az("no payments are expected")]
967- if ((ef == ef))
920+ else ay("no payments are expected")]
921+ if ((ee == ee))
968922 then {
969- let ee = aL(fo)
970- let Y = dg.caller
971- let Z = dg.transactionId
972- let fw = invoke(ba, "unstake", [toBase58String(aU), fv], nil)
973- if ((fw == fw))
923+ let ed = aK(fc)
924+ let X = df.caller
925+ let Y = df.transactionId
926+ let fk = invoke(aZ, "unstake", [toBase58String(aT), fj], nil)
927+ if ((fk == fk))
974928 then {
975- let fx = ed(ee, fv, aU, Y, Z)
976- if ((fx == fx))
929+ let fl = ec(ed, fj, aT, X, Y)
930+ if ((fl == fl))
977931 then {
978- let fi = fx._4
979- let dv = fx._3
980- let cQ = fx._2
981- let fr = fx._1
982- let do = if (if ((fc > 0))
983- then (fc > fr)
932+ let eW = fl._4
933+ let du = fl._3
934+ let cP = fl._2
935+ let ff = fl._1
936+ let dn = if (if ((eQ > 0))
937+ then (eQ > ff)
984938 else false)
985- then az(makeString(["amount to receive is less than ", toString(fc)], ""))
986- else fr
987- let fs = invoke(aB, "burn", [fv], [AttachedPayment(aU, fv)])
988- if ((fs == fs))
939+ then ay(makeString(["amount to receive is less than ", toString(eQ)], ""))
940+ else ff
941+ let fg = invoke(aA, "burn", [fj], [AttachedPayment(aT, fj)])
942+ if ((fg == fg))
989943 then {
990- let ft = [ScriptTransfer(dg.caller, do, ee)]
991- let fm = if ((dv > 0))
992- then [ScriptTransfer(aC, dv, ee)]
944+ let fh = [ScriptTransfer(df.caller, dn, ed)]
945+ let fa = if ((du > 0))
946+ then [ScriptTransfer(aB, du, ed)]
993947 else nil
994- $Tuple2(((cQ ++ ft) ++ fm), do)
948+ $Tuple2(((cP ++ fh) ++ fa), dn)
995949 }
996950 else throw("Strict value is not equal to itself.")
997951 }
998952 else throw("Strict value is not equal to itself.")
999953 }
1000954 else throw("Strict value is not equal to itself.")
1001955 }
1002956 else throw("Strict value is not equal to itself.")
1003957 }
1004958
1005959
1006960
1007-@Callable(dg)
961+@Callable(df)
1008962 func get () = {
1009- let cB = df(dg)
1010- let fy = cB._1
1011- let ci = cB._2
1012- let di = cB._3
1013- let bQ = cB._4
1014- let cj = cB._5
1015- let fz = invoke(aB, "burn", [di], [AttachedPayment(bQ, di)])
1016- if ((fz == fz))
1017- then cj
963+ let cA = de(df)
964+ let fm = cA._1
965+ let ch = cA._2
966+ let dh = cA._3
967+ let bP = cA._4
968+ let ci = cA._5
969+ let fn = invoke(aA, "burn", [dh], [AttachedPayment(bP, dh)])
970+ if ((fn == fn))
971+ then ci
1018972 else throw("Strict value is not equal to itself.")
1019973 }
1020974
1021975
1022976
1023-@Callable(dg)
1024-func getNoLess (fA,fB) = {
1025- let cB = df(dg)
1026- let ch = cB._1
1027- let ci = cB._2
1028- let di = cB._3
1029- let bQ = cB._4
1030- let cj = cB._5
1031- if ((fA > ch))
1032- then throw(((("noLessThenAmtAsset failed: " + toString(ch)) + " < ") + toString(fA)))
1033- else if ((fB > ci))
1034- then throw(((("noLessThenPriceAsset failed: " + toString(ci)) + " < ") + toString(fB)))
977+@Callable(df)
978+func getNoLess (fo,fp) = {
979+ let cA = de(df)
980+ let cg = cA._1
981+ let ch = cA._2
982+ let dh = cA._3
983+ let bP = cA._4
984+ let ci = cA._5
985+ if ((fo > cg))
986+ then throw(((("noLessThenAmtAsset failed: " + toString(cg)) + " < ") + toString(fo)))
987+ else if ((fp > ch))
988+ then throw(((("noLessThenPriceAsset failed: " + toString(ch)) + " < ") + toString(fp)))
1035989 else {
1036- let fz = invoke(aB, "burn", [di], [AttachedPayment(bQ, di)])
1037- if ((fz == fz))
1038- then cj
990+ let fn = invoke(aA, "burn", [dh], [AttachedPayment(bP, dh)])
991+ if ((fn == fn))
992+ then ci
1039993 else throw("Strict value is not equal to itself.")
1040994 }
1041995 }
1042996
1043997
1044998
1045-@Callable(dg)
1046-func unstakeAndGet (do) = {
1047- let fC = if ((size(dg.payments) != 0))
999+@Callable(df)
1000+func unstakeAndGet (dn) = {
1001+ let fq = if ((size(df.payments) != 0))
10481002 then throw("No payments are expected")
10491003 else true
1050- if ((fC == fC))
1004+ if ((fq == fq))
10511005 then {
1052- let bF = aI()
1053- let bS = fromBase58String(bF[q])
1054- let fw = invoke(ba, "unstake", [toBase58String(bS), do], nil)
1055- if ((fw == fw))
1006+ let bE = aH()
1007+ let bR = fromBase58String(bE[q])
1008+ let fk = invoke(aZ, "unstake", [toBase58String(bR), dn], nil)
1009+ if ((fk == fk))
10561010 then {
1057- let cB = bO(toBase58String(dg.transactionId), toBase58String(bS), do, dg.caller)
1058- let bV = parseIntValue(cB._9)
1059- let cj = cB._10
1060- let fD = if (if (aG())
1011+ let cA = bN(toBase58String(df.transactionId), toBase58String(bR), dn, df.caller)
1012+ let bU = parseIntValue(cA._9)
1013+ let ci = cA._10
1014+ let fr = if (if (aF())
10611015 then true
1062- else (bV == n))
1063- then throw(("Get operation is blocked by admin. Status = " + toString(bV)))
1016+ else (bU == n))
1017+ then throw(("Get operation is blocked by admin. Status = " + toString(bU)))
10641018 else true
1065- if ((fD == fD))
1019+ if ((fr == fr))
10661020 then {
1067- let fz = invoke(aB, "burn", [do], [AttachedPayment(bS, do)])
1068- if ((fz == fz))
1069- then cj
1021+ let fn = invoke(aA, "burn", [dn], [AttachedPayment(bR, dn)])
1022+ if ((fn == fn))
1023+ then ci
10701024 else throw("Strict value is not equal to itself.")
10711025 }
10721026 else throw("Strict value is not equal to itself.")
10731027 }
10741028 else throw("Strict value is not equal to itself.")
10751029 }
10761030 else throw("Strict value is not equal to itself.")
10771031 }
10781032
10791033
10801034
1081-@Callable(dg)
1082-func unstakeAndGetNoLess (fv,fE,fB) = {
1083- let fp = if (aG())
1035+@Callable(df)
1036+func unstakeAndGetNoLess (fj,fs,fp) = {
1037+ let fd = if (aF())
10841038 then true
1085- else (aT == n)
1086- let ef = [if (!(fp))
1039+ else (aS == n)
1040+ let ee = [if (!(fd))
10871041 then true
1088- else throw("get operation is blocked by admin"), if ((size(dg.payments) == 0))
1042+ else throw("get operation is blocked by admin"), if ((size(df.payments) == 0))
10891043 then true
10901044 else throw("no payments are expected")]
1091- if ((ef == ef))
1045+ if ((ee == ee))
10921046 then {
1093- let fw = invoke(ba, "unstake", [toBase58String(aU), fv], nil)
1094- if ((fw == fw))
1047+ let fk = invoke(aZ, "unstake", [toBase58String(aT), fj], nil)
1048+ if ((fk == fk))
10951049 then {
1096- let cB = bO(toBase58String(dg.transactionId), toBase58String(aU), fv, dg.caller)
1097- let ch = cB._1
1098- let ci = cB._2
1099- let cj = cB._10
1100- let fF = [if ((ch >= fE))
1050+ let cA = bN(toBase58String(df.transactionId), toBase58String(aT), fj, df.caller)
1051+ let cg = cA._1
1052+ let ch = cA._2
1053+ let ci = cA._10
1054+ let ft = [if ((cg >= fs))
11011055 then true
1102- else throw(makeString(["amount asset amount to receive is less than ", toString(fE)], "")), if ((ci >= fB))
1056+ else throw(makeString(["amount asset amount to receive is less than ", toString(fs)], "")), if ((ch >= fp))
11031057 then true
1104- else throw(makeString(["price asset amount to receive is less than ", toString(fB)], ""))]
1105- if ((fF == fF))
1058+ else throw(makeString(["price asset amount to receive is less than ", toString(fp)], ""))]
1059+ if ((ft == ft))
11061060 then {
1107- let fz = invoke(aB, "burn", [fv], [AttachedPayment(aU, fv)])
1108- if ((fz == fz))
1109- then cj
1061+ let fn = invoke(aA, "burn", [fj], [AttachedPayment(aT, fj)])
1062+ if ((fn == fn))
1063+ then ci
11101064 else throw("Strict value is not equal to itself.")
11111065 }
11121066 else throw("Strict value is not equal to itself.")
11131067 }
11141068 else throw("Strict value is not equal to itself.")
11151069 }
11161070 else throw("Strict value is not equal to itself.")
11171071 }
11181072
11191073
11201074
1121-@Callable(dg)
1122-func activate (fG,fH) = if ((toString(dg.caller) != toString(aB)))
1075+@Callable(df)
1076+func activate (fu,fv) = if ((toString(df.caller) != toString(aA)))
11231077 then throw("permissions denied")
1124- else $Tuple2([StringEntry(ab(), fG), StringEntry(ac(), fH)], "success")
1078+ else $Tuple2([StringEntry(aa(), fu), StringEntry(ab(), fv)], "success")
11251079
11261080
11271081
1128-@Callable(dg)
1129-func getPoolConfigWrapperREADONLY () = $Tuple2(nil, aI())
1082+@Callable(df)
1083+func getPoolConfigWrapperREADONLY () = $Tuple2(nil, aH())
11301084
11311085
11321086
1133-@Callable(dg)
1134-func getAccBalanceWrapperREADONLY (bs) = $Tuple2(nil, br(bs))
1087+@Callable(df)
1088+func getAccBalanceWrapperREADONLY (br) = $Tuple2(nil, bq(br))
11351089
11361090
11371091
1138-@Callable(dg)
1139-func calcPricesWrapperREADONLY (bz,bA,bE) = {
1140- let bN = bD(bz, bA, bE)
1141- $Tuple2(nil, [toString(bN[0]), toString(bN[1]), toString(bN[2])])
1092+@Callable(df)
1093+func calcPricesWrapperREADONLY (by,bz,bD) = {
1094+ let bM = bC(by, bz, bD)
1095+ $Tuple2(nil, [toString(bM[0]), toString(bM[1]), toString(bM[2])])
11421096 }
11431097
11441098
11451099
1146-@Callable(dg)
1100+@Callable(df)
11471101 func toX18WrapperREADONLY (E,F) = $Tuple2(nil, toString(D(E, F)))
11481102
11491103
11501104
1151-@Callable(dg)
1105+@Callable(df)
11521106 func fromX18WrapperREADONLY (H,I) = $Tuple2(nil, G(parseBigIntValue(H), I))
11531107
11541108
11551109
1156-@Callable(dg)
1157-func calcPriceBigIntWrapperREADONLY (bu,bv) = $Tuple2(nil, toString(bt(parseBigIntValue(bu), parseBigIntValue(bv))))
1110+@Callable(df)
1111+func calcPriceBigIntWrapperREADONLY (bt,bu) = $Tuple2(nil, toString(bs(parseBigIntValue(bt), parseBigIntValue(bu))))
11581112
11591113
11601114
1161-@Callable(dg)
1162-func estimatePutOperationWrapperREADONLY (bP,cl,cm,cn,co,cp,Y,cq,cr) = $Tuple2(nil, ck(bP, cl, cm, cn, co, cp, Y, cq, cr))
1115+@Callable(df)
1116+func estimatePutOperationWrapperREADONLY (bO,ck,cl,cm,cn,co,X,cp,cq) = $Tuple2(nil, cj(bO, ck, cl, cm, cn, co, X, cp, cq))
11631117
11641118
11651119
1166-@Callable(dg)
1167-func estimateGetOperationWrapperREADONLY (bP,bQ,bR,Y) = {
1168- let cB = bO(bP, bQ, bR, addressFromStringValue(Y))
1169- $Tuple2(nil, $Tuple10(cB._1, cB._2, cB._3, cB._4, cB._5, cB._6, cB._7, toString(cB._8), cB._9, cB._10))
1120+@Callable(df)
1121+func estimateGetOperationWrapperREADONLY (bO,bP,bQ,X) = {
1122+ let cA = bN(bO, bP, bQ, addressFromStringValue(X))
1123+ $Tuple2(nil, $Tuple10(cA._1, cA._2, cA._3, cA._4, cA._5, cA._6, cA._7, toString(cA._8), cA._9, cA._10))
11701124 }
11711125
11721126
11731127
1174-@Callable(dg)
1128+@Callable(df)
11751129 func statsREADONLY () = {
1176- let bF = aI()
1177- let bS = fromBase58String(bF[q])
1178- let cT = bF[r]
1179- let cU = bF[s]
1180- let cu = bF[v]
1181- let cv = bF[w]
1182- let bG = parseIntValue(bF[t])
1183- let bH = parseIntValue(bF[u])
1184- let fI = valueOrErrorMessage(assetInfo(bS), (("Asset " + toBase58String(bS)) + " doesn't exist")).quantity
1185- let cV = br(cT)
1186- let cW = br(cU)
1187- let fJ = if ((fI == 0))
1130+ let bE = aH()
1131+ let bR = fromBase58String(bE[q])
1132+ let cS = bE[r]
1133+ let cT = bE[s]
1134+ let ct = bE[v]
1135+ let cu = bE[w]
1136+ let bF = parseIntValue(bE[t])
1137+ let bG = parseIntValue(bE[u])
1138+ let fw = valueOrErrorMessage(assetInfo(bR), (("Asset " + toBase58String(bR)) + " doesn't exist")).quantity
1139+ let cU = bq(cS)
1140+ let cV = bq(cT)
1141+ let fx = if ((fw == 0))
11881142 then [e, e, e]
1189- else bD(cV, cW, fI)
1190- let cc = 0
1191- let fK = G(fJ[1], b)
1192- let fL = G(fJ[2], b)
1193- let fM = value(getInteger(aB, an(toString(this))))
1194- $Tuple2(nil, makeString(["%d%d%d%d%d%d%d", toString(cV), toString(cW), toString(fI), toString(cc), toString(fK), toString(fL), toString(fM)], j))
1143+ else bC(cU, cV, fw)
1144+ let cb = 0
1145+ let fy = G(fx[1], b)
1146+ let fz = G(fx[2], b)
1147+ let fA = value(getInteger(aA, am(toString(this))))
1148+ $Tuple2(nil, makeString(["%d%d%d%d%d%d%d", toString(cU), toString(cV), toString(fw), toString(cb), toString(fy), toString(fz), toString(fA)], j))
11951149 }
11961150
11971151
11981152
1199-@Callable(dg)
1200-func evaluatePutByAmountAssetREADONLY (cm) = {
1201- let bF = aI()
1202- let bS = fromBase58String(bF[q])
1203- let cs = bF[r]
1153+@Callable(df)
1154+func evaluatePutByAmountAssetREADONLY (cl) = {
1155+ let bE = aH()
1156+ let bR = fromBase58String(bE[q])
1157+ let cr = bE[r]
1158+ let bS = fromBase58String(cr)
1159+ let cs = bE[s]
12041160 let bT = fromBase58String(cs)
1205- let ct = bF[s]
1206- let bU = fromBase58String(ct)
1207- let bG = parseIntValue(bF[t])
1208- let bH = parseIntValue(bF[u])
1209- let bV = bF[p]
1210- let fI = valueOrErrorMessage(assetInfo(bS), (("Asset " + toBase58String(bS)) + " doesn't exist")).quantity
1211- let cV = br(cs)
1212- let cW = br(ct)
1161+ let bF = parseIntValue(bE[t])
1162+ let bG = parseIntValue(bE[u])
1163+ let bU = bE[p]
1164+ let fw = valueOrErrorMessage(assetInfo(bR), (("Asset " + toBase58String(bR)) + " doesn't exist")).quantity
1165+ let cU = bq(cr)
1166+ let cV = bq(cs)
1167+ let bA = D(cU, bF)
12131168 let bB = D(cV, bG)
1214- let bC = D(cW, bH)
1215- let cb = if ((fI == 0))
1169+ let ca = if ((fw == 0))
12161170 then e
1217- else bt(bC, bB)
1218- let cy = D(cm, bG)
1219- let cz = fraction(cy, cb, d)
1220- let co = G(cz, bH)
1221- let dm = ck("", 500000, cm, bT, co, bU, "", true, false)
1222- let cJ = dm._1
1223- let fN = dm._3
1224- let bX = dm._4
1225- let bZ = dm._5
1226- let bW = dm._6
1227- $Tuple2(nil, makeString(["%d%d%d%d%d%d%d%d", toString(cJ), toString(G(cb, b)), toString(bX), toString(bZ), toString(bW), bV, toString(cm), toString(co)], j))
1171+ else bs(bB, bA)
1172+ let cx = D(cl, bF)
1173+ let cy = fraction(cx, ca, d)
1174+ let cn = G(cy, bG)
1175+ let dl = cj("", 500000, cl, bS, cn, bT, "", true, false)
1176+ let cI = dl._1
1177+ let fB = dl._3
1178+ let bW = dl._4
1179+ let bY = dl._5
1180+ let bV = dl._6
1181+ $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))
12281182 }
12291183
12301184
12311185
1232-@Callable(dg)
1233-func evaluatePutByPriceAssetREADONLY (co) = {
1234- let bF = aI()
1235- let bS = fromBase58String(bF[q])
1236- let cs = bF[r]
1186+@Callable(df)
1187+func evaluatePutByPriceAssetREADONLY (cn) = {
1188+ let bE = aH()
1189+ let bR = fromBase58String(bE[q])
1190+ let cr = bE[r]
1191+ let bS = fromBase58String(cr)
1192+ let cs = bE[s]
12371193 let bT = fromBase58String(cs)
1238- let ct = bF[s]
1239- let bU = fromBase58String(ct)
1240- let bG = parseIntValue(bF[t])
1241- let bH = parseIntValue(bF[u])
1242- let bV = bF[p]
1243- let fI = valueOrErrorMessage(assetInfo(bS), (("Asset " + toBase58String(bS)) + " doesn't exist")).quantity
1244- let fO = br(cs)
1245- let fP = br(ct)
1246- let fQ = D(fO, bG)
1247- let fR = D(fP, bH)
1248- let cb = if ((fI == 0))
1194+ let bF = parseIntValue(bE[t])
1195+ let bG = parseIntValue(bE[u])
1196+ let bU = bE[p]
1197+ let fw = valueOrErrorMessage(assetInfo(bR), (("Asset " + toBase58String(bR)) + " doesn't exist")).quantity
1198+ let fC = bq(cr)
1199+ let fD = bq(cs)
1200+ let fE = D(fC, bF)
1201+ let fF = D(fD, bG)
1202+ let ca = if ((fw == 0))
12491203 then e
1250- else bt(fR, fQ)
1251- let cz = D(co, bH)
1252- let cy = fraction(cz, d, cb)
1253- let cm = G(cy, bG)
1254- let dm = ck("", 500000, cm, bT, co, bU, "", true, false)
1255- let cJ = dm._1
1256- let fN = dm._3
1257- let bX = dm._4
1258- let bZ = dm._5
1259- let bW = dm._6
1260- $Tuple2(nil, makeString(["%d%d%d%d%d%d%d%d", toString(cJ), toString(G(cb, b)), toString(bX), toString(bZ), toString(bW), bV, toString(cm), toString(co)], j))
1204+ else bs(fF, fE)
1205+ let cy = D(cn, bG)
1206+ let cx = fraction(cy, d, ca)
1207+ let cl = G(cx, bF)
1208+ let dl = cj("", 500000, cl, bS, cn, bT, "", true, false)
1209+ let cI = dl._1
1210+ let fB = dl._3
1211+ let bW = dl._4
1212+ let bY = dl._5
1213+ let bV = dl._6
1214+ $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))
12611215 }
12621216
12631217
12641218
1265-@Callable(dg)
1266-func evaluateGetREADONLY (fS,fT) = {
1267- let cB = bO("", fS, fT, this)
1268- let ch = cB._1
1269- let ci = cB._2
1270- let bX = cB._5
1271- let bZ = cB._6
1272- let bW = cB._7
1273- let cc = cB._8
1274- let bV = parseIntValue(cB._9)
1275- $Tuple2(nil, makeString(["%d%d%d%d%d%d%d", toString(ch), toString(ci), toString(bX), toString(bZ), toString(bW), toString(cc), toString(bV)], j))
1219+@Callable(df)
1220+func evaluateGetREADONLY (fG,fH) = {
1221+ let cA = bN("", fG, fH, this)
1222+ let cg = cA._1
1223+ let ch = cA._2
1224+ let bW = cA._5
1225+ let bY = cA._6
1226+ let bV = cA._7
1227+ let cb = cA._8
1228+ let bU = parseIntValue(cA._9)
1229+ $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))
12761230 }
12771231
12781232
1279-@Verifier(fU)
1280-func fV () = {
1281- let fW = {
1282- let dr = ew()
1283- if ($isInstanceOf(dr, "ByteVector"))
1233+@Verifier(fI)
1234+func fJ () = {
1235+ let fK = {
1236+ let dq = ev()
1237+ if ($isInstanceOf(dq, "ByteVector"))
12841238 then {
1285- let eA = dr
1286- eA
1239+ let ez = dq
1240+ ez
12871241 }
1288- else if ($isInstanceOf(dr, "Unit"))
1289- then fU.senderPublicKey
1242+ else if ($isInstanceOf(dq, "Unit"))
1243+ then fI.senderPublicKey
12901244 else throw("Match error")
12911245 }
1292- let dr = fU
1293- if ($isInstanceOf(dr, "Order"))
1246+ let dq = fI
1247+ if ($isInstanceOf(dq, "Order"))
12941248 then {
1295- let cS = dr
1296- let fX = aH()
1297- let as = cR(cS)
1298- let at = sigVerify(cS.bodyBytes, cS.proofs[0], cS.senderPublicKey)
1299- let au = sigVerify(cS.bodyBytes, cS.proofs[1], fX)
1300- if (if (if (as)
1249+ let cR = dq
1250+ let fL = aG()
1251+ let ar = cQ(cR)
1252+ let as = sigVerify(cR.bodyBytes, cR.proofs[0], cR.senderPublicKey)
1253+ let at = sigVerify(cR.bodyBytes, cR.proofs[1], fL)
1254+ if (if (if (ar)
1255+ then as
1256+ else false)
13011257 then at
13021258 else false)
1303- then au
1304- else false)
13051259 then true
1306- else ar(as, at, au)
1260+ else aq(ar, as, at)
13071261 }
1308- else if ($isInstanceOf(dr, "SetScriptTransaction"))
1262+ else if ($isInstanceOf(dq, "SetScriptTransaction"))
13091263 then {
1310- let ex = dr
1311- let fY = blake2b256(value(ex.script))
1312- let fZ = fromBase64String(value(getString(aB, ap())))
1313- let ga = scriptHash(this)
1314- if (if ((fZ == fY))
1315- then (ga != fY)
1264+ let ew = dq
1265+ let fM = blake2b256(value(ew.script))
1266+ let fN = fromBase64String(value(getString(aA, ao())))
1267+ let fO = scriptHash(this)
1268+ if (if ((fN == fM))
1269+ then (fO != fM)
13161270 else false)
13171271 then true
1318- else sigVerify(fU.bodyBytes, fU.proofs[0], fW)
1272+ else sigVerify(fI.bodyBytes, fI.proofs[0], fK)
13191273 }
1320- else sigVerify(fU.bodyBytes, fU.proofs[0], fW)
1274+ else sigVerify(fI.bodyBytes, fI.proofs[0], fK)
13211275 }
13221276

github/deemru/w8io/026f985 
410.50 ms