tx · Gykwn9MCTqx7LQAbfcqvKZXRRaYAxHbnLJYPT2iayPRB

3N55kCyUFy8M2ooKRwierKnP7L6viqzScNn:  -0.03300000 Waves

2022.12.05 09:29 [2346704] smart account 3N55kCyUFy8M2ooKRwierKnP7L6viqzScNn > SELF 0.00000000 Waves

{ "type": 13, "id": "Gykwn9MCTqx7LQAbfcqvKZXRRaYAxHbnLJYPT2iayPRB", "fee": 3300000, "feeAssetId": null, "timestamp": 1670221783719, "version": 1, "sender": "3N55kCyUFy8M2ooKRwierKnP7L6viqzScNn", "senderPublicKey": "HpuFV1RhaXZ5gaJNgeLjyAKy3D5q7fMKdNFYYbPDafnb", "proofs": [ "52uEfBbwyG7fnVmzbUerv3yjGpu2iXT6EWrLHa1NPS9xthsDiGdCz1QPndCdsj6kNh2ZDJP9NUdt1LMc7x4he4Wh" ], "script": "base64:BgLYKwgCEgMKAQgSABIECgIBBBIDCgEBEgQKAgEEEgQKAggBEgQKAggBEgQKAggBEgUKAwEIARIAEgQKAgEBEgMKAQESBQoDAQEBEgQKAggIEgASABIDCgEIEgUKAwEBARIECgIBARIECgIIARIECgIICBILCgkIAQECAQIIBAQSBgoECAgBCBIAEgMKAQESAwoBARIECgIIASIKbFBkZWNpbWFscyIGc2NhbGU4IgxzY2FsZThCaWdJbnQiB3NjYWxlMTgiCnplcm9CaWdJbnQiBGJpZzAiBGJpZzEiBGJpZzIiC3dhdmVzU3RyaW5nIgNTRVAiClBvb2xBY3RpdmUiD1Bvb2xQdXREaXNhYmxlZCITUG9vbE1hdGNoZXJEaXNhYmxlZCIMUG9vbFNodXRkb3duIg5pZHhQb29sQWRkcmVzcyINaWR4UG9vbFN0YXR1cyIQaWR4UG9vbExQQXNzZXRJZCINaWR4QW10QXNzZXRJZCIPaWR4UHJpY2VBc3NldElkIg5pZHhBbXRBc3NldERjbSIQaWR4UHJpY2VBc3NldERjbSIOaWR4SUFtdEFzc2V0SWQiEGlkeElQcmljZUFzc2V0SWQiDWlkeExQQXNzZX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AzAgCCQCkAwEFAmNiCQDMCAIJAKYDAQUCY2gJAMwIAgkApAMBBQJjYQUDbmlsBQFqAQJncAECZ3EABAJncgQCZEUJAQJlRwADCQABAgUCZEUCCkJ5dGVWZWN0b3IEAmVLBQJkRQUCZUsDCQABAgUCZEUCBFVuaXQIBQJncA9zZW5kZXJQdWJsaWNLZXkJAAIBAgtNYXRjaCBlcnJvcgQCZEUFAmdwAwkAAQIFAmRFAgVPcmRlcgQCZGoFAmRFBAJncwkBAmFNAAQCYXoJAQJkaQEFAmRqBAJhQQkA9AMDCAUCZGoJYm9keUJ5dGVzCQCRAwIIBQJkagZwcm9vZnMAAAgFAmRqD3NlbmRlclB1YmxpY0tleQQCYUIJAPQDAwgFAmRqCWJvZHlCeXRlcwkAkQMCCAUCZGoGcHJvb2ZzAAEFAmdzAwMDBQJhegUCYUEHBQJhQgcGCQECYXkDBQJhegUCYUEFAmFCAwkAAQIFAmRFAhRTZXRTY3JpcHRUcmFuc2FjdGlvbgQCZUgFAmRFBAJndAkA9gMBCQEFdmFsdWUBCAUCZUgGc2NyaXB0BAJndQkA2wQBCQEFdmFsdWUBCQCdCAIFAmFKCQECYXcABAJndgkA8QcBBQR0aGlzAwMJAAACBQJndQUCZ3QJAQIhPQIFAmd2BQJndAcGCQD0AwMIBQJncAlib2R5Qnl0ZXMJAJEDAggFAmdwBnByb29mcwAABQJncgkA9AMDCAUCZ3AJYm9keUJ5dGVzCQCRAwIIBQJncAZwcm9vZnMAAAUCZ3JXKual", "chainId": 84, "height": 2346704, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: BJiAw3Gaebfsxkv7EkNCahETQWcBXA21FtPHktc1c5Rd Next: 5xrqK9igqQ4Mq6v1pXhfWrEeMVZTcrf6j1twcCzBX7zR Diff:
OldNewDifferences
111111
112112 let ae = valueOrElse(getInteger(this, ac), ad)
113113
114-func af () = "%s__factoryConfig"
114+let af = makeString(["%s", "kLp"], j)
115+
116+let ag = makeString(["%s", "kLpRefreshedHeight"], j)
117+
118+let ah = makeString(["%s", "refreshKLpDelay"], j)
119+
120+let ai = 30
121+
122+let aj = valueOrElse(getInteger(this, ah), ai)
123+
124+func ak () = "%s__factoryConfig"
115125
116126
117-func ag () = "%s%s__matcher__publicKey"
127+func al () = "%s%s__matcher__publicKey"
118128
119129
120-func ah (ai) = (("%s%s%s__" + ai) + "__mappings__poolContract2LpAsset")
130+func am (an) = (("%s%s%s__" + an) + "__mappings__poolContract2LpAsset")
121131
122132
123-func aj (ak,al) = (((("%d%d%s__" + ak) + "__") + al) + "__config")
133+func ao (ap,aq) = (((("%d%d%s__" + ap) + "__") + aq) + "__config")
124134
125135
126-func am (an) = ("%s%s%s__mappings__baseAsset2internalId__" + an)
136+func ar (as) = ("%s%s%s__mappings__baseAsset2internalId__" + as)
127137
128138
129-func ao () = "%s__shutdown"
139+func at () = "%s__shutdown"
130140
131141
132-func ap (aq) = ("%s%s__poolWeight__" + aq)
142+func au (av) = ("%s%s__poolWeight__" + av)
133143
134144
135-func ar () = "%s__allowedLpScriptHash"
145+func aw () = "%s__allowedLpScriptHash"
136146
137147
138-let as = "%s__feeCollectorAddress"
148+let ax = "%s__feeCollectorAddress"
139149
140-func at (au,av,aw) = throw(((((("order validation failed: orderValid=" + toString(au)) + " senderValid=") + toString(av)) + " matcherValid=") + toString(aw)))
150+func ay (az,aA,aB) = throw(((((("order validation failed: orderValid=" + toString(az)) + " senderValid=") + toString(aA)) + " matcherValid=") + toString(aB)))
141151
142152
143-func ax (ay,az) = valueOrErrorMessage(getString(ay, az), makeString(["mandatory ", toString(ay), ".", az, " is not defined"], ""))
153+func aC (aD,aE) = valueOrErrorMessage(getString(aD, aE), makeString(["mandatory ", toString(aD), ".", aE, " is not defined"], ""))
144154
145155
146-func aA (ay,az) = valueOrErrorMessage(getInteger(ay, az), makeString(["mandatory ", toString(ay), ".", az, " is not defined"], ""))
156+func aF (aD,aE) = valueOrErrorMessage(getInteger(aD, aE), makeString(["mandatory ", toString(aD), ".", aE, " is not defined"], ""))
147157
148158
149-func aB (aC) = throw(makeString(["lp.ride:", aC], " "))
159+func aG (aH) = throw(makeString(["lp.ride:", aH], " "))
150160
151161
152-let aD = addressFromStringValue(ax(this, P()))
153-
154-let aE = addressFromStringValue(ax(aD, as))
155-
156-func aF () = valueOrElse(getBoolean(aD, ao()), false)
162+func aI (aH) = makeString(["lp.ride:", aH], " ")
157163
158164
159-func aG () = fromBase58String(ax(aD, ag()))
165+let aJ = addressFromStringValue(aC(this, P()))
166+
167+let aK = addressFromStringValue(aC(aJ, ax))
168+
169+func aL () = valueOrElse(getBoolean(aJ, at()), false)
160170
161171
162-func aH () = {
163- let aI = ax(this, aa())
164- let aJ = ax(this, ab())
165- let al = aA(aD, am(aJ))
166- let ak = aA(aD, am(aI))
167- split(ax(aD, aj(toString(ak), toString(al))), j)
172+func aM () = fromBase58String(aC(aJ, al()))
173+
174+
175+func aN () = {
176+ let aO = aC(this, aa())
177+ let aP = aC(this, ab())
178+ let aq = aF(aJ, ar(aP))
179+ let ap = aF(aJ, ar(aO))
180+ split(aC(aJ, ao(toString(ap), toString(aq))), j)
168181 }
169182
170183
171-func aK (aL) = if ((aL == i))
184+func aQ (aR) = if ((aR == i))
172185 then unit
173- else fromBase58String(aL)
186+ else fromBase58String(aR)
174187
175188
176-func aM (aL) = if ((aL == unit))
189+func aS (aR) = if ((aR == unit))
177190 then i
178- else toBase58String(value(aL))
191+ else toBase58String(value(aR))
179192
180193
181-func aN (aO) = $Tuple7(addressFromStringValue(aO[o]), parseIntValue(aO[p]), fromBase58String(aO[q]), aK(aO[r]), aK(aO[s]), parseIntValue(aO[t]), parseIntValue(aO[u]))
194+func aT (aU) = $Tuple7(addressFromStringValue(aU[o]), parseIntValue(aU[p]), fromBase58String(aU[q]), aQ(aU[r]), aQ(aU[s]), parseIntValue(aU[t]), parseIntValue(aU[u]))
182195
183196
184-let aP = aN(aH())
197+let aV = aT(aN())
185198
186-let aQ = aP
199+let aW = aV
187200
188-let aR = aQ._1
201+let aX = aW._1
189202
190-let aS = aQ._2
203+let aY = aW._2
191204
192-let aT = aQ._3
205+let aZ = aW._3
193206
194-let aU = aQ._4
207+let ba = aW._4
195208
196-let aV = aQ._5
209+let bb = aW._5
197210
198-let aW = aQ._6
211+let bc = aW._6
199212
200-let aX = aQ._7
213+let bd = aW._7
201214
202-func aY () = split(ax(aD, af()), j)
215+func be () = split(aC(aJ, ak()), j)
203216
204217
205-let aZ = valueOrErrorMessage(addressFromString(aY()[B]), "incorrect staking address")
218+let bf = valueOrErrorMessage(addressFromString(be()[B]), "incorrect staking address")
206219
207-let ba = valueOrErrorMessage(addressFromString(aY()[C]), "incorrect staking address")
220+let bg = valueOrErrorMessage(addressFromString(be()[C]), "incorrect staking address")
208221
209-func bb (bc,bd,be,bf,bg,bh,bi,bj,bk,bl) = makeString(["%d%d%d%d%d%d%d%d%d%d", toString(bc), toString(bd), toString(be), toString(bf), toString(bg), toString(bh), toString(bi), toString(bj), toString(bk), toString(bl)], j)
222+func bh (bi,bj,bk,bl,bm,bn,bo,bp,bq,br) = makeString(["%d%d%d%d%d%d%d%d%d%d", toString(bi), toString(bj), toString(bk), toString(bl), toString(bm), toString(bn), toString(bo), toString(bp), toString(bq), toString(br)], j)
210223
211224
212-func bm (bn,bo,bp,bf,bi,bj) = makeString(["%d%d%d%d%d%d", toString(bn), toString(bo), toString(bp), toString(bf), toString(bi), toString(bj)], j)
225+func bs (bt,bu,bv,bl,bo,bp) = makeString(["%d%d%d%d%d%d", toString(bt), toString(bu), toString(bv), toString(bl), toString(bo), toString(bp)], j)
213226
214227
215-func bq (br) = if ((br == "WAVES"))
228+func bw (bx) = if ((bx == "WAVES"))
216229 then wavesBalance(this).available
217- else assetBalance(this, fromBase58String(br))
230+ else assetBalance(this, fromBase58String(bx))
218231
219232
220-func bs (bt,bu) = fraction(bt, d, bu)
233+func by (bz,bA) = fraction(bz, d, bA)
221234
222235
223-func bv (bw,bx,by,bz) = {
224- let bA = D(by, bw)
225- let bB = D(bz, bx)
226- bs(bB, bA)
236+func bB (bC,bD,bE,bF) = {
237+ let bG = D(bE, bC)
238+ let bH = D(bF, bD)
239+ by(bH, bG)
227240 }
228241
229242
230-func bC (by,bz,bD) = {
231- let bE = aH()
232- let bF = parseIntValue(bE[t])
233- let bG = parseIntValue(bE[u])
234- let bH = bv(bF, bG, by, bz)
235- let bu = D(by, bF)
236- let bt = D(bz, bG)
237- let bI = D(bD, b)
238- let bJ = bs(bu, bI)
239- let bK = bs(bt, bI)
240-[bH, bJ, bK]
243+func bI (bE,bF,bJ) = {
244+ let bK = aN()
245+ let bL = parseIntValue(bK[t])
246+ let bM = parseIntValue(bK[u])
247+ let bN = bB(bL, bM, bE, bF)
248+ let bA = D(bE, bL)
249+ let bz = D(bF, bM)
250+ let bO = D(bJ, b)
251+ let bP = by(bA, bO)
252+ let bQ = by(bz, bO)
253+[bN, bP, bQ]
241254 }
242255
243256
244-func bL (by,bz,bD) = {
245- let bM = bC(by, bz, bD)
246-[G(bM[0], b), G(bM[1], b), G(bM[2], b)]
257+func bR (bE,bF,bJ) = {
258+ let bS = bI(bE, bF, bJ)
259+[G(bS[0], b), G(bS[1], b), G(bS[2], b)]
247260 }
248261
249262
250-func bN (bO,bP,bQ,X) = {
251- let bE = aH()
252- let bR = bE[q]
253- let bS = bE[r]
254- let bT = bE[s]
255- let bw = parseIntValue(bE[t])
256- let bx = parseIntValue(bE[u])
257- let bU = bE[p]
258- let bV = valueOrErrorMessage(assetInfo(fromBase58String(bR)), (("Asset " + bR) + " doesn't exist")).quantity
259- if ((bR != bP))
263+func bT (bU,bV,bW,X) = {
264+ let bK = aN()
265+ let bX = bK[q]
266+ let bY = bK[r]
267+ let bZ = bK[s]
268+ let bC = parseIntValue(bK[t])
269+ let bD = parseIntValue(bK[u])
270+ let ca = bK[p]
271+ let cb = valueOrErrorMessage(assetInfo(fromBase58String(bX)), (("Asset " + bX) + " doesn't exist")).quantity
272+ if ((bX != bV))
260273 then throw("Invalid asset passed.")
261274 else {
262- let bW = bq(bS)
263- let bX = D(bW, bw)
264- let bY = bq(bT)
265- let bZ = D(bY, bx)
266- let ca = bs(bZ, bX)
267- let cb = G(ca, b)
268- let cc = D(bQ, b)
269- let cd = D(bV, b)
270- let ce = fraction(bX, cc, cd)
271- let cf = fraction(bZ, cc, cd)
272- let cg = G(ce, bw)
273- let ch = G(cf, bx)
274- let ci = if ((bO == ""))
275+ let cc = bw(bY)
276+ let cd = D(cc, bC)
277+ let ce = bw(bZ)
278+ let cf = D(ce, bD)
279+ let cg = by(cf, cd)
280+ let ch = G(cg, b)
281+ let ci = D(bW, b)
282+ let cj = D(cb, b)
283+ let ck = fraction(cd, ci, cj)
284+ let cl = fraction(cf, ci, cj)
285+ let cm = G(ck, bC)
286+ let cn = G(cl, bD)
287+ let co = if ((bU == ""))
275288 then nil
276- else [ScriptTransfer(X, cg, if ((bS == "WAVES"))
289+ else [ScriptTransfer(X, cm, if ((bY == "WAVES"))
277290 then unit
278- else fromBase58String(bS)), ScriptTransfer(X, ch, if ((bT == "WAVES"))
291+ else fromBase58String(bY)), ScriptTransfer(X, cn, if ((bZ == "WAVES"))
279292 then unit
280- else fromBase58String(bT)), StringEntry(Z(toString(X), bO), bm(cg, ch, bQ, cb, height, lastBlock.timestamp)), IntegerEntry(S(), cb), IntegerEntry(T(height, lastBlock.timestamp), cb)]
281- $Tuple10(cg, ch, bS, bT, bW, bY, bV, ca, bU, ci)
293+ else fromBase58String(bZ)), StringEntry(Z(toString(X), bU), bs(cm, cn, bW, ch, height, lastBlock.timestamp)), IntegerEntry(S(), ch), IntegerEntry(T(height, lastBlock.timestamp), ch)]
294+ $Tuple10(cm, cn, bY, bZ, cc, ce, cb, cg, ca, co)
282295 }
283296 }
284297
285298
286-func cj (bO,ck,cl,cm,cn,co,X,cp,cq) = {
287- let bE = aH()
288- let bR = fromBase58String(bE[q])
289- let cr = bE[r]
290- let cs = bE[s]
291- let ct = bE[v]
292- let cu = bE[w]
293- let bF = parseIntValue(bE[t])
294- let bG = parseIntValue(bE[u])
295- let bU = bE[p]
296- let bV = valueOrErrorMessage(assetInfo(bR), (("Asset " + toBase58String(bR)) + " doesn't exist")).quantity
297- let cv = toBase58String(valueOrElse(cm, fromBase58String("WAVES")))
298- let cw = toBase58String(valueOrElse(co, fromBase58String("WAVES")))
299- if (if ((cr != cv))
299+func cp (bU,cq,cr,cs,ct,cu,X,cv,cw) = {
300+ let bK = aN()
301+ let bX = fromBase58String(bK[q])
302+ let cx = bK[r]
303+ let cy = bK[s]
304+ let cz = bK[v]
305+ let cA = bK[w]
306+ let bL = parseIntValue(bK[t])
307+ let bM = parseIntValue(bK[u])
308+ let ca = bK[p]
309+ let cb = valueOrErrorMessage(assetInfo(bX), (("Asset " + toBase58String(bX)) + " doesn't exist")).quantity
310+ let cB = toBase58String(valueOrElse(cs, fromBase58String("WAVES")))
311+ let cC = toBase58String(valueOrElse(cu, fromBase58String("WAVES")))
312+ if (if ((cx != cB))
300313 then true
301- else (cs != cw))
314+ else (cy != cC))
302315 then throw("Invalid amt or price asset passed.")
303316 else {
304- let bW = if (cp)
305- then bq(cr)
306- else (bq(cr) - cl)
307- let bY = if (cp)
308- then bq(cs)
309- else (bq(cs) - cn)
310- let cx = D(cl, bF)
311- let cy = D(cn, bG)
312- let cz = bs(cy, cx)
313- let bX = D(bW, bF)
314- let bZ = D(bY, bG)
315- let cA = if ((bV == 0))
317+ let cc = if (cv)
318+ then bw(cx)
319+ else (bw(cx) - cr)
320+ let ce = if (cv)
321+ then bw(cy)
322+ else (bw(cy) - ct)
323+ let cD = D(cr, bL)
324+ let cE = D(ct, bM)
325+ let cF = by(cE, cD)
326+ let cd = D(cc, bL)
327+ let cf = D(ce, bM)
328+ let cG = if ((cb == 0))
316329 then {
317- let ca = e
318- let cB = e
319- let bI = pow((cx * cy), 0, toBigInt(5), 1, 0, DOWN)
320- $Tuple5(G(bI, b), G(cx, bF), G(cy, bG), bs((bZ + cy), (bX + cx)), cB)
330+ let cg = e
331+ let cH = e
332+ let bO = pow((cD * cE), 0, toBigInt(5), 1, 0, DOWN)
333+ $Tuple5(G(bO, b), G(cD, bL), G(cE, bM), by((cf + cE), (cd + cD)), cH)
321334 }
322335 else {
323- let ca = bs(bZ, bX)
324- let cB = fraction(O((ca - cz)), d, ca)
325- let cC = D(ck, b)
326- if (if ((ca != e))
327- then (cB > cC)
336+ let cg = by(cf, cd)
337+ let cH = fraction(O((cg - cF)), d, cg)
338+ let cI = D(cq, b)
339+ if (if ((cg != e))
340+ then (cH > cI)
328341 else false)
329- then throw(((("Price slippage " + toString(cB)) + " exceeded the passed limit of ") + toString(cC)))
342+ then throw(((("Price slippage " + toString(cH)) + " exceeded the passed limit of ") + toString(cI)))
330343 else {
331- let cd = D(bV, b)
332- let cD = fraction(cx, ca, d)
333- let cE = fraction(cy, d, ca)
334- let cF = if ((cD > cy))
335- then $Tuple2(cE, cy)
336- else $Tuple2(cx, cD)
337- let cG = cF._1
338- let cH = cF._2
339- let bI = fraction(cd, cH, bZ)
340- $Tuple5(G(bI, b), G(cG, bF), G(cH, bG), ca, cB)
344+ let cj = D(cb, b)
345+ let cJ = fraction(cD, cg, d)
346+ let cK = fraction(cE, d, cg)
347+ let cL = if ((cJ > cE))
348+ then $Tuple2(cK, cE)
349+ else $Tuple2(cD, cJ)
350+ let cM = cL._1
351+ let cN = cL._2
352+ let bO = fraction(cj, cN, cf)
353+ $Tuple5(G(bO, b), G(cM, bL), G(cN, bM), cg, cH)
341354 }
342355 }
343- let cI = cA._1
344- let cJ = cA._2
345- let cK = cA._3
346- let cb = G(cA._4, b)
347- let cL = G(cA._5, b)
348- if ((0 >= cI))
356+ let cO = cG._1
357+ let cP = cG._2
358+ let cQ = cG._3
359+ let ch = G(cG._4, b)
360+ let cR = G(cG._5, b)
361+ if ((0 >= cO))
349362 then throw("Invalid calculations. LP calculated is less than zero.")
350363 else {
351- let cM = if (!(cq))
364+ let cS = if (!(cw))
352365 then 0
353- else cI
354- let cN = (cl - cJ)
355- let cO = (cn - cK)
356- let cP = [IntegerEntry(S(), cb), IntegerEntry(T(height, lastBlock.timestamp), cb), StringEntry(W(X, bO), bb(cJ, cK, cM, cb, ck, cL, height, lastBlock.timestamp, cN, cO))]
357- $Tuple13(cI, cM, cb, bW, bY, bV, bR, bU, cP, cN, cO, cm, co)
366+ else cO
367+ let cT = (cr - cP)
368+ let cU = (ct - cQ)
369+ let cV = [IntegerEntry(S(), ch), IntegerEntry(T(height, lastBlock.timestamp), ch), StringEntry(W(X, bU), bh(cP, cQ, cS, ch, cq, cR, height, lastBlock.timestamp, cT, cU))]
370+ $Tuple13(cO, cS, ch, cc, ce, cb, bX, ca, cV, cT, cU, cs, cu)
358371 }
359372 }
360373 }
361374
362375
363-func cQ (cR) = {
364- let bE = aH()
365- let cS = bE[r]
366- let cT = bE[s]
367- let bU = parseIntValue(bE[p])
368- let bF = parseIntValue(bE[t])
369- let bG = parseIntValue(bE[u])
370- let cU = bq(cS)
371- let cV = bq(cT)
372- let ca = if ((cR.orderType == Buy))
373- then bv(bF, bG, (cU + cR.amount), cV)
374- else bv(bF, bG, (cU - cR.amount), cV)
375- let cb = G(ca, b)
376- if (if (if (aF())
377- then true
378- else (bU == m))
379- then true
380- else (bU == n))
381- then throw("Exchange operations disabled")
382- else {
383- let cW = cR.assetPair.amountAsset
384- let cX = if ((cW == unit))
385- then "WAVES"
386- else toBase58String(value(cW))
387- let cY = cR.assetPair.priceAsset
388- let cZ = if ((cY == unit))
389- then "WAVES"
390- else toBase58String(value(cY))
391- if (if ((cX != cS))
392- then true
393- else (cZ != cT))
394- then throw("Wrong order assets.")
395- else {
396- let da = cR.price
397- let db = fraction(b, bG, bF)
398- let dc = J(da, b, db)
399- let dd = if ((cR.orderType == Buy))
400- then (cb >= dc)
401- else (dc >= cb)
402- true
403- }
404- }
376+func cW (cX,cY,cb) = {
377+ let cZ = fraction(pow((cX * cY), 0, toBigInt(5), 1, 0, DOWN), d, cb)
378+ cZ
405379 }
406380
407381
408-func de (df) = if ((size(df.payments) != 1))
382+func da (db,dc,dd) = {
383+ let de = (bw(aS(ba)) + db)
384+ let df = (bw(aS(bb)) + dc)
385+ let dg = (value(assetInfo(aZ)).quantity + dd)
386+ let cZ = cW(toBigInt(de), toBigInt(df), toBigInt(dg))
387+ let dh = [IntegerEntry(ag, height), StringEntry(af, toString(cZ))]
388+ $Tuple2(dh, cZ)
389+ }
390+
391+
392+func di (dj) = {
393+ let dk = dj.amount
394+ let dl = fraction(dj.amount, dj.price, b)
395+ let dm = if ((dj.orderType == Buy))
396+ then $Tuple2(dk, -(dl))
397+ else $Tuple2(-(dk), dl)
398+ let db = dm._1
399+ let dc = dm._2
400+ if (if (if (aL())
401+ then true
402+ else (aY == m))
403+ then true
404+ else (aY == n))
405+ then throw("Exchange operations disabled")
406+ else if (if ((dj.assetPair.amountAsset != ba))
407+ then true
408+ else (dj.assetPair.priceAsset != bb))
409+ then throw("Wrong order assets.")
410+ else {
411+ let dn = valueOrErrorMessage(parseBigInt(valueOrErrorMessage(getString(this, af), aI("kLp is required"))), aI("invalid kLp"))
412+ let do = da(db, dc, 0)
413+ let dp = do._1
414+ let dq = do._2
415+ let dr = (dq > dn)
416+ dr
417+ }
418+ }
419+
420+
421+func ds (dt) = if ((size(dt.payments) != 1))
409422 then throw("exactly 1 payment is expected")
410423 else {
411- let dg = value(df.payments[0])
412- let bP = value(dg.assetId)
413- let dh = dg.amount
414- let cA = bN(toBase58String(df.transactionId), toBase58String(bP), dh, df.caller)
415- let cg = cA._1
416- let ch = cA._2
417- let bU = parseIntValue(cA._9)
418- let ci = cA._10
419- if (if (aF())
424+ let du = value(dt.payments[0])
425+ let bV = value(du.assetId)
426+ let dv = du.amount
427+ let cG = bT(toBase58String(dt.transactionId), toBase58String(bV), dv, dt.caller)
428+ let cm = cG._1
429+ let cn = cG._2
430+ let ca = parseIntValue(cG._9)
431+ let co = cG._10
432+ if (if (aL())
420433 then true
421- else (bU == n))
422- then throw(("Get operation is blocked by admin. Status = " + toString(bU)))
423- else $Tuple5(cg, ch, dh, bP, ci)
434+ else (ca == n))
435+ then throw(("Get operation is blocked by admin. Status = " + toString(ca)))
436+ else $Tuple5(cm, cn, dv, bV, co)
424437 }
425438
426439
427-func di (df,ck,cq) = if ((size(df.payments) != 2))
440+func dw (dt,cq,cw) = if ((size(dt.payments) != 2))
428441 then throw("exactly 2 payments are expected")
429442 else {
430- let dj = value(df.payments[0])
431- let dk = value(df.payments[1])
432- let dl = cj(toBase58String(df.transactionId), ck, dj.amount, dj.assetId, dk.amount, dk.assetId, toString(df.caller), false, cq)
433- let bU = parseIntValue(dl._8)
434- if (if (if (aF())
443+ let dx = value(dt.payments[0])
444+ let dy = value(dt.payments[1])
445+ let dz = cp(toBase58String(dt.transactionId), cq, dx.amount, dx.assetId, dy.amount, dy.assetId, toString(dt.caller), false, cw)
446+ let ca = parseIntValue(dz._8)
447+ if (if (if (aL())
435448 then true
436- else (bU == l))
449+ else (ca == l))
437450 then true
438- else (bU == n))
439- then throw(("Put operation is blocked by admin. Status = " + toString(bU)))
440- else dl
451+ else (ca == n))
452+ then throw(("Put operation is blocked by admin. Status = " + toString(ca)))
453+ else dz
441454 }
442455
443456
444-func dm (dn) = {
445- let do = invoke(aD, "emit", [dn], nil)
446- if ((do == do))
457+func dA (dB) = {
458+ let dC = invoke(aJ, "emit", [dB], nil)
459+ if ((dC == dC))
447460 then {
448- let dp = {
449- let dq = do
450- if ($isInstanceOf(dq, "Address"))
461+ let dD = {
462+ let dE = dC
463+ if ($isInstanceOf(dE, "Address"))
451464 then {
452- let dr = dq
453- invoke(dr, "emit", [dn], nil)
465+ let dF = dE
466+ invoke(dF, "emit", [dB], nil)
454467 }
455468 else unit
456469 }
457- if ((dp == dp))
458- then dn
470+ if ((dD == dD))
471+ then dB
459472 else throw("Strict value is not equal to itself.")
460473 }
461474 else throw("Strict value is not equal to itself.")
462475 }
463476
464477
465-func ds (dn) = {
466- let dt = fraction(dn, ae, b)
467- $Tuple2((dn - dt), dt)
478+func dG (dB) = {
479+ let dH = fraction(dB, ae, b)
480+ $Tuple2((dB - dH), dH)
468481 }
469482
470483
471-func du (dv,dw,X,Y) = {
472- let dx = (Y == unit)
473- let dy = bq(aM(aU))
474- let dz = bq(aM(aV))
475- let dA = if ((dw == aU))
484+func dI (dJ,dK,X,Y) = {
485+ let dL = (Y == unit)
486+ let dM = bw(aS(ba))
487+ let dN = bw(aS(bb))
488+ let dO = if ((dK == ba))
476489 then true
477- else if ((dw == aV))
490+ else if ((dK == bb))
478491 then false
479- else aB("invalid asset")
480- let dB = if (dx)
481- then $Tuple2(dy, dz)
482- else if (dA)
483- then $Tuple2((dy - dv), dz)
484- else $Tuple2(dy, (dz - dv))
485- let dC = dB._1
486- let dD = dB._2
487- let dE = if (dA)
488- then $Tuple2(dv, 0)
489- else $Tuple2(0, dv)
490- let dF = dE._1
491- let dG = dE._2
492- let dH = ds(dF)._1
493- let dI = ds(dG)._1
494- let dJ = ds(dv)
495- let dK = dJ._1
496- let dt = dJ._2
497- let dL = (dC + dH)
498- let dM = (dD + dI)
499- let dN = bs(D(dM, aX), D(dL, aW))
500- let dO = G(dN, b)
501- let dP = if (dA)
502- then dC
503- else dD
504- let dQ = toBigInt(dP)
505- let dR = toBigInt(valueOrErrorMessage(assetInfo(aT), (("asset " + toBase58String(aT)) + " doesn't exist")).quantity)
506- let dS = if ((dR > f))
492+ else aG("invalid asset")
493+ let dP = if (dL)
494+ then $Tuple2(dM, dN)
495+ else if (dO)
496+ then $Tuple2((dM - dJ), dN)
497+ else $Tuple2(dM, (dN - dJ))
498+ let dQ = dP._1
499+ let dR = dP._2
500+ let dS = if (dO)
501+ then $Tuple2(dJ, 0)
502+ else $Tuple2(0, dJ)
503+ let dT = dS._1
504+ let dU = dS._2
505+ let dk = dG(dT)._1
506+ let dl = dG(dU)._1
507+ let dV = dG(dJ)
508+ let dW = dV._1
509+ let dH = dV._2
510+ let dX = (dQ + dk)
511+ let dY = (dR + dl)
512+ let dZ = by(D(dY, bd), D(dX, bc))
513+ let ea = G(dZ, b)
514+ let eb = if (dO)
515+ then dQ
516+ else dR
517+ let ec = toBigInt(eb)
518+ let ed = toBigInt(valueOrErrorMessage(assetInfo(aZ), (("asset " + toBase58String(aZ)) + " doesn't exist")).quantity)
519+ let ee = if ((ed > f))
507520 then true
508- else aB("initial deposit requires all coins")
509- if ((dS == dS))
521+ else aG("initial deposit requires all coins")
522+ if ((ee == ee))
510523 then {
511- let dT = toBigInt(dK)
512- let dU = max([0, toInt(((dR * (sqrtBigInt((d + ((dT * d) / dQ)), 18, 18, DOWN) - d)) / d))])
513- let cP = if (dx)
524+ let ef = toBigInt(dW)
525+ let eg = max([0, toInt(((ed * (sqrtBigInt((d + ((ef * d) / ec)), 18, 18, DOWN) - d)) / d))])
526+ let cV = if (dL)
514527 then nil
515- else [IntegerEntry(S(), dO), IntegerEntry(T(height, lastBlock.timestamp), dO), StringEntry(W(toString(value(X)), toBase58String(value(Y))), bb(dF, dG, dU, dO, 0, 0, height, lastBlock.timestamp, 0, 0))]
516- let dV = bs(D(dD, aX), D(dC, aW))
517- let dW = G(dV, b)
518- let dX = {
519- let dY = if (dA)
520- then $Tuple2(dF, dC)
521- else $Tuple2(dG, dD)
522- let dn = dY._1
523- let dZ = dY._2
524- let ea = toInt(fraction(dR, toBigInt((dn / 2)), toBigInt(dZ)))
525- fraction((dU - ea), b, ea)
528+ else [IntegerEntry(S(), ea), IntegerEntry(T(height, lastBlock.timestamp), ea), StringEntry(W(toString(value(X)), toBase58String(value(Y))), bh(dT, dU, eg, ea, 0, 0, height, lastBlock.timestamp, 0, 0))]
529+ let eh = by(D(dR, bd), D(dQ, bc))
530+ let ei = G(eh, b)
531+ let ej = {
532+ let ek = if (dO)
533+ then $Tuple2(dT, dQ)
534+ else $Tuple2(dU, dR)
535+ let dB = ek._1
536+ let el = ek._2
537+ let em = toInt(fraction(ed, toBigInt((dB / 2)), toBigInt(el)))
538+ fraction((eg - em), b, em)
526539 }
527- $Tuple4(dU, cP, dt, dX)
540+ $Tuple5(eg, cV, dH, ej, dO)
528541 }
529542 else throw("Strict value is not equal to itself.")
530543 }
531544
532545
533-func eb (ec,dK,dw,X,Y) = {
534- let dx = (Y == unit)
535- let ed = [if ((dw == aT))
546+func en (eo,dW,dK,X,Y) = {
547+ let dL = (Y == unit)
548+ let ep = [if ((dK == aZ))
536549 then true
537- else aB("invalid lp asset")]
538- if ((ed == ed))
550+ else aG("invalid lp asset")]
551+ if ((ep == ep))
539552 then {
540- let ee = if ((ec == aU))
553+ let eq = if ((eo == ba))
541554 then true
542- else if ((ec == aV))
555+ else if ((eo == bb))
543556 then false
544- else aB("invalid asset")
545- let ef = if (ee)
546- then toBigInt(bq(aM(aU)))
547- else toBigInt(bq(aM(aV)))
548- let eg = bq(aM(aU))
549- let eh = bq(aM(aV))
550- let ei = if (ee)
551- then eg
552- else eh
553- let ej = toBigInt(ei)
554- let dR = toBigInt(valueOrErrorMessage(assetInfo(aT), (("asset " + toBase58String(aT)) + " doesn't exist")).quantity)
555- let ek = toBigInt(dK)
556- let el = max([0, toInt(((ef * (d - pow((d - ((ek * d) / dR)), 18, h, 0, 18, DOWN))) / d))])
557- let em = ds(el)
558- let en = em._1
559- let dt = em._2
560- let eo = if (ee)
561- then $Tuple4(en, 0, (eg - el), eh)
562- else $Tuple4(0, en, eg, (eh - el))
563- let ep = eo._1
564- let eq = eo._2
565- let er = eo._3
566- let es = eo._4
567- let dN = bs(D(es, aX), D(er, aW))
568- let dO = G(dN, b)
569- let cP = if (dx)
557+ else aG("invalid asset")
558+ let er = if (eq)
559+ then toBigInt(bw(aS(ba)))
560+ else toBigInt(bw(aS(bb)))
561+ let es = bw(aS(ba))
562+ let et = bw(aS(bb))
563+ let eu = if (eq)
564+ then es
565+ else et
566+ let ev = toBigInt(eu)
567+ let ed = toBigInt(valueOrErrorMessage(assetInfo(aZ), (("asset " + toBase58String(aZ)) + " doesn't exist")).quantity)
568+ let ew = toBigInt(dW)
569+ let ex = max([0, toInt(((er * (d - pow((d - ((ew * d) / ed)), 18, h, 0, 18, DOWN))) / d))])
570+ let ey = dG(ex)
571+ let ez = ey._1
572+ let dH = ey._2
573+ let eA = if (eq)
574+ then $Tuple4(ez, 0, (es - ex), et)
575+ else $Tuple4(0, ez, es, (et - ex))
576+ let eB = eA._1
577+ let eC = eA._2
578+ let eD = eA._3
579+ let eE = eA._4
580+ let dZ = by(D(eE, bd), D(eD, bc))
581+ let ea = G(dZ, b)
582+ let cV = if (dL)
570583 then nil
571- else [StringEntry(Z(toString(value(X)), toBase58String(value(Y))), bm(ep, eq, dK, dO, height, lastBlock.timestamp)), IntegerEntry(S(), dO), IntegerEntry(T(height, lastBlock.timestamp), dO)]
572- let dV = bs(D(eh, aX), D(eg, aW))
573- let dW = G(dV, b)
574- let dX = {
575- let et = (toInt(fraction(ef, ek, dR)) * 2)
576- fraction((en - et), b, et)
584+ else [StringEntry(Z(toString(value(X)), toBase58String(value(Y))), bs(eB, eC, dW, ea, height, lastBlock.timestamp)), IntegerEntry(S(), ea), IntegerEntry(T(height, lastBlock.timestamp), ea)]
585+ let eh = by(D(et, bd), D(es, bc))
586+ let ei = G(eh, b)
587+ let ej = {
588+ let eF = (toInt(fraction(er, ew, ed)) * 2)
589+ fraction((ez - eF), b, eF)
577590 }
578- $Tuple4(en, cP, dt, dX)
591+ $Tuple5(ez, cV, dH, ej, eq)
579592 }
580593 else throw("Strict value is not equal to itself.")
581594 }
582595
583596
584-func eu () = {
585- let dq = getString(Q())
586- if ($isInstanceOf(dq, "String"))
597+func eG () = {
598+ let dE = getString(Q())
599+ if ($isInstanceOf(dE, "String"))
587600 then {
588- let ev = dq
589- fromBase58String(ev)
601+ let eH = dE
602+ fromBase58String(eH)
590603 }
591- else if ($isInstanceOf(dq, "Unit"))
604+ else if ($isInstanceOf(dE, "Unit"))
592605 then unit
593606 else throw("Match error")
594607 }
595608
596609
597-func ew () = {
598- let dq = getString(R())
599- if ($isInstanceOf(dq, "String"))
610+func eI () = {
611+ let dE = getString(R())
612+ if ($isInstanceOf(dE, "String"))
600613 then {
601- let ev = dq
602- fromBase58String(ev)
614+ let eH = dE
615+ fromBase58String(eH)
603616 }
604- else if ($isInstanceOf(dq, "Unit"))
617+ else if ($isInstanceOf(dE, "Unit"))
605618 then unit
606619 else throw("Match error")
607620 }
608621
609622
610-func ex (df) = {
611- let dq = eu()
612- if ($isInstanceOf(dq, "ByteVector"))
623+func eJ (dt) = {
624+ let dE = eG()
625+ if ($isInstanceOf(dE, "ByteVector"))
613626 then {
614- let ey = dq
615- (df.callerPublicKey == ey)
627+ let eK = dE
628+ (dt.callerPublicKey == eK)
616629 }
617- else if ($isInstanceOf(dq, "Unit"))
618- then (df.caller == this)
630+ else if ($isInstanceOf(dE, "Unit"))
631+ then (dt.caller == this)
619632 else throw("Match error")
620633 }
621634
622635
623-func ez (df) = {
624- let eA = throw("Permission denied")
625- let dq = eu()
626- if ($isInstanceOf(dq, "ByteVector"))
636+func eL (dt) = {
637+ let eM = throw("Permission denied")
638+ let dE = eG()
639+ if ($isInstanceOf(dE, "ByteVector"))
627640 then {
628- let ey = dq
629- if ((df.callerPublicKey == ey))
641+ let eK = dE
642+ if ((dt.callerPublicKey == eK))
630643 then true
631- else eA
644+ else eM
632645 }
633- else if ($isInstanceOf(dq, "Unit"))
634- then if ((df.caller == this))
646+ else if ($isInstanceOf(dE, "Unit"))
647+ then if ((dt.caller == this))
635648 then true
636- else eA
649+ else eM
637650 else throw("Match error")
638651 }
639652
640653
641-@Callable(df)
642-func setManager (eB) = {
643- let eC = ez(df)
644- if ((eC == eC))
654+@Callable(dt)
655+func setManager (eN) = {
656+ let eO = eL(dt)
657+ if ((eO == eO))
645658 then {
646- let eD = fromBase58String(eB)
647- if ((eD == eD))
648- then [StringEntry(R(), eB)]
659+ let eP = fromBase58String(eN)
660+ if ((eP == eP))
661+ then [StringEntry(R(), eN)]
649662 else throw("Strict value is not equal to itself.")
650663 }
651664 else throw("Strict value is not equal to itself.")
653666
654667
655668
656-@Callable(df)
669+@Callable(dt)
657670 func confirmManager () = {
658- let eE = ew()
659- let eF = if (isDefined(eE))
671+ let eQ = eI()
672+ let eR = if (isDefined(eQ))
660673 then true
661674 else throw("No pending manager")
662- if ((eF == eF))
675+ if ((eR == eR))
663676 then {
664- let eG = if ((df.callerPublicKey == value(eE)))
677+ let eS = if ((dt.callerPublicKey == value(eQ)))
665678 then true
666679 else throw("You are not pending manager")
667- if ((eG == eG))
668- then [StringEntry(Q(), toBase58String(value(eE))), DeleteEntry(R())]
680+ if ((eS == eS))
681+ then [StringEntry(Q(), toBase58String(value(eQ))), DeleteEntry(R())]
669682 else throw("Strict value is not equal to itself.")
670683 }
671684 else throw("Strict value is not equal to itself.")
673686
674687
675688
676-@Callable(df)
677-func put (ck,eH) = if ((0 > ck))
689+@Callable(dt)
690+func put (cq,eT) = if ((0 > cq))
678691 then throw("Invalid slippageTolerance passed")
679692 else {
680- let dl = di(df, ck, true)
681- let cM = dl._2
682- let bR = dl._7
683- let ci = dl._9
684- let cN = dl._10
685- let cO = dl._11
686- let eI = dl._12
687- let eJ = dl._13
688- let do = invoke(aD, "emit", [cM], nil)
689- if ((do == do))
693+ let dz = dw(dt, cq, true)
694+ let cS = dz._2
695+ let bX = dz._7
696+ let co = dz._9
697+ let cT = dz._10
698+ let cU = dz._11
699+ let eU = dz._12
700+ let eV = dz._13
701+ let dC = invoke(aJ, "emit", [cS], nil)
702+ if ((dC == dC))
690703 then {
691- let dp = {
692- let dq = do
693- if ($isInstanceOf(dq, "Address"))
704+ let dD = {
705+ let dE = dC
706+ if ($isInstanceOf(dE, "Address"))
694707 then {
695- let dr = dq
696- invoke(dr, "emit", [cM], nil)
708+ let dF = dE
709+ invoke(dF, "emit", [cS], nil)
697710 }
698711 else unit
699712 }
700- if ((dp == dp))
713+ if ((dD == dD))
701714 then {
702- let eK = if ((cN > 0))
703- then invoke(ba, "put", nil, [AttachedPayment(eI, cN)])
715+ let eW = if ((cT > 0))
716+ then invoke(bg, "put", nil, [AttachedPayment(eU, cT)])
704717 else nil
705- if ((eK == eK))
718+ if ((eW == eW))
706719 then {
707- let eL = if ((cO > 0))
708- then invoke(ba, "put", nil, [AttachedPayment(eJ, cO)])
720+ let eX = if ((cU > 0))
721+ then invoke(bg, "put", nil, [AttachedPayment(eV, cU)])
709722 else nil
710- if ((eL == eL))
723+ if ((eX == eX))
711724 then {
712- let eM = if (eH)
725+ let eY = if (eT)
713726 then {
714- let eN = invoke(aZ, "stake", nil, [AttachedPayment(bR, cM)])
715- if ((eN == eN))
727+ let eZ = invoke(bf, "stake", nil, [AttachedPayment(bX, cS)])
728+ if ((eZ == eZ))
716729 then nil
717730 else throw("Strict value is not equal to itself.")
718731 }
719- else [ScriptTransfer(df.caller, cM, bR)]
720- (ci ++ eM)
732+ else [ScriptTransfer(dt.caller, cS, bX)]
733+ let fa = da(0, 0, 0)
734+ let fb = fa._1
735+ let cZ = fa._2
736+ ((co ++ eY) ++ fb)
721737 }
722738 else throw("Strict value is not equal to itself.")
723739 }
730746
731747
732748
733-@Callable(df)
734-func putForFree (eO) = if ((0 > eO))
749+@Callable(dt)
750+func putForFree (fc) = if ((0 > fc))
735751 then throw("Invalid value passed")
736752 else {
737- let dl = di(df, eO, false)
738- dl._9
753+ let dz = dw(dt, fc, false)
754+ let co = dz._9
755+ let fd = da(0, 0, 0)
756+ let fb = fd._1
757+ let cZ = fd._2
758+ (co ++ fb)
739759 }
740760
741761
742762
743-@Callable(df)
744-func putOneTkn (eP,eQ) = {
745- let eR = {
746- let eS = invoke(aD, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
747- if ($isInstanceOf(eS, "Boolean"))
748- then eS
749- else throw(($getType(eS) + " couldn't be cast to Boolean"))
763+@Callable(dt)
764+func putOneTkn (fe,ff) = {
765+ let fg = {
766+ let fh = invoke(aJ, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
767+ if ($isInstanceOf(fh, "Boolean"))
768+ then fh
769+ else throw(($getType(fh) + " couldn't be cast to Boolean"))
750770 }
751- let eT = if (if (if (aF())
771+ let fi = if (if (if (aL())
752772 then true
753- else (aS == l))
773+ else (aY == l))
754774 then true
755- else (aS == n))
775+ else (aY == n))
756776 then true
757- else eR
758- let ed = [if (if (!(eT))
777+ else fg
778+ let ep = [if (if (!(fi))
759779 then true
760- else ex(df))
780+ else eJ(dt))
761781 then true
762- else aB("put operation is blocked by admin"), if ((size(df.payments) == 1))
782+ else aG("put operation is blocked by admin"), if ((size(dt.payments) == 1))
763783 then true
764- else aB("exactly 1 payment are expected")]
765- if ((ed == ed))
784+ else aG("exactly 1 payment are expected")]
785+ if ((ep == ep))
766786 then {
767- let eU = df.payments[0]
768- let dw = eU.assetId
769- let dv = eU.amount
770- let X = df.caller
771- let Y = df.transactionId
772- let eV = du(dv, dw, X, Y)
773- let eW = eV._1
774- let cP = eV._2
775- let dt = eV._3
776- let eX = eV._4
777- let eY = if (if ((eP > 0))
778- then (eP > eW)
779- else false)
780- then aB(makeString(["amount to receive is less than ", toString(eP)], ""))
781- else eW
782- let do = dm(eY)
783- if ((do == do))
784- then {
785- let eM = if (eQ)
786- then {
787- let eZ = invoke(aZ, "stake", nil, [AttachedPayment(aT, eY)])
788- if ((eZ == eZ))
789- then nil
790- else throw("Strict value is not equal to itself.")
791- }
792- else [ScriptTransfer(df.caller, eY, aT)]
793- let fa = if ((dt > 0))
794- then [ScriptTransfer(aE, dt, dw)]
795- else nil
796- $Tuple2(((cP ++ eM) ++ fa), eY)
797- }
798- else throw("Strict value is not equal to itself.")
799- }
800- else throw("Strict value is not equal to itself.")
801- }
802-
803-
804-
805-@Callable(df)
806-func putOneTknREADONLY (dw,dv) = {
807- let fb = du(dv, aK(dw), unit, unit)
808- let eW = fb._1
809- let cP = fb._2
810- let dt = fb._3
811- let eX = fb._4
812- $Tuple2(nil, $Tuple3(eW, dt, eX))
813- }
814-
815-
816-
817-@Callable(df)
818-func getOneTkn (fc,eP) = {
819- let eR = {
820- let eS = invoke(aD, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
821- if ($isInstanceOf(eS, "Boolean"))
822- then eS
823- else throw(($getType(eS) + " couldn't be cast to Boolean"))
824- }
825- let fd = if (if (aF())
826- then true
827- else (aS == n))
828- then true
829- else eR
830- let ed = [if (if (!(fd))
831- then true
832- else ex(df))
833- then true
834- else aB("get operation is blocked by admin"), if ((size(df.payments) == 1))
835- then true
836- else aB("exactly 1 payment are expected")]
837- if ((ed == ed))
838- then {
839- let ec = aK(fc)
840- let eU = df.payments[0]
841- let dw = eU.assetId
842- let dK = eU.amount
843- let X = df.caller
844- let Y = df.transactionId
845- let fe = eb(ec, dK, dw, X, Y)
846- let ff = fe._1
847- let cP = fe._2
848- let dt = fe._3
849- let eX = fe._4
850- let dn = if (if ((eP > 0))
851- then (eP > ff)
852- else false)
853- then aB(makeString(["amount to receive is less than ", toString(eP)], ""))
854- else ff
855- let fg = invoke(aD, "burn", [dK], [AttachedPayment(dw, dK)])
856- if ((fg == fg))
857- then {
858- let fh = [ScriptTransfer(X, dn, ec)]
859- let fa = if ((dt > 0))
860- then [ScriptTransfer(aE, dt, ec)]
861- else nil
862- $Tuple2(((cP ++ fh) ++ fa), dn)
863- }
864- else throw("Strict value is not equal to itself.")
865- }
866- else throw("Strict value is not equal to itself.")
867- }
868-
869-
870-
871-@Callable(df)
872-func getOneTknREADONLY (ec,dK) = {
873- let fi = eb(aK(ec), dK, aT, unit, unit)
874- let ff = fi._1
875- let cP = fi._2
876- let dt = fi._3
877- let eX = fi._4
878- $Tuple2(nil, $Tuple3(ff, dt, eX))
879- }
880-
881-
882-
883-@Callable(df)
884-func unstakeAndGetOneTkn (fj,fc,eP) = {
885- let eR = {
886- let eS = invoke(aD, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
887- if ($isInstanceOf(eS, "Boolean"))
888- then eS
889- else throw(($getType(eS) + " couldn't be cast to Boolean"))
890- }
891- let fd = if (if (aF())
892- then true
893- else (aS == n))
894- then true
895- else eR
896- let ed = [if (if (!(fd))
897- then true
898- else ex(df))
899- then true
900- else aB("get operation is blocked by admin"), if ((size(df.payments) == 0))
901- then true
902- else aB("no payments are expected")]
903- if ((ed == ed))
904- then {
905- let ec = aK(fc)
906- let X = df.caller
907- let Y = df.transactionId
908- let fk = invoke(aZ, "unstake", [toBase58String(aT), fj], nil)
787+ let fj = dt.payments[0]
788+ let dK = fj.assetId
789+ let dJ = fj.amount
790+ let X = dt.caller
791+ let Y = dt.transactionId
792+ let fk = dI(dJ, dK, X, Y)
909793 if ((fk == fk))
910794 then {
911- let fl = eb(ec, fj, aT, X, Y)
912- let ff = fl._1
913- let cP = fl._2
914- let dt = fl._3
915- let eX = fl._4
916- let dn = if (if ((eP > 0))
917- then (eP > ff)
795+ let dO = fk._5
796+ let fl = fk._4
797+ let dH = fk._3
798+ let cV = fk._2
799+ let fm = fk._1
800+ let fn = if (if ((fe > 0))
801+ then (fe > fm)
918802 else false)
919- then aB(makeString(["amount to receive is less than ", toString(eP)], ""))
920- else ff
921- let fg = invoke(aD, "burn", [fj], [AttachedPayment(aT, fj)])
922- if ((fg == fg))
803+ then aG(makeString(["amount to receive is less than ", toString(fe)], ""))
804+ else fm
805+ let dC = dA(fn)
806+ if ((dC == dC))
923807 then {
924- let fh = [ScriptTransfer(df.caller, dn, ec)]
925- let fa = if ((dt > 0))
926- then [ScriptTransfer(aE, dt, ec)]
808+ let eY = if (ff)
809+ then {
810+ let fo = invoke(bf, "stake", nil, [AttachedPayment(aZ, fn)])
811+ if ((fo == fo))
812+ then nil
813+ else throw("Strict value is not equal to itself.")
814+ }
815+ else [ScriptTransfer(dt.caller, fn, aZ)]
816+ let fp = if ((dH > 0))
817+ then [ScriptTransfer(aK, dH, dK)]
927818 else nil
928- $Tuple2(((cP ++ fh) ++ fa), dn)
819+ let fq = if ((this == aK))
820+ then $Tuple2(0, 0)
821+ else if (dO)
822+ then $Tuple2(-(dH), 0)
823+ else $Tuple2(0, -(dH))
824+ let db = fq._1
825+ let dc = fq._2
826+ let fr = da(db, dc, 0)
827+ let fb = fr._1
828+ let cZ = fr._2
829+ $Tuple2((((cV ++ eY) ++ fp) ++ fb), fn)
929830 }
930831 else throw("Strict value is not equal to itself.")
931832 }
936837
937838
938839
939-@Callable(df)
940-func get () = {
941- let cA = de(df)
942- let fm = cA._1
943- let ch = cA._2
944- let dh = cA._3
945- let bP = cA._4
946- let ci = cA._5
947- let fn = invoke(aD, "burn", [dh], [AttachedPayment(bP, dh)])
948- if ((fn == fn))
949- then ci
840+@Callable(dt)
841+func putOneTknREADONLY (dK,dJ) = {
842+ let fs = dI(dJ, aQ(dK), unit, unit)
843+ let fm = fs._1
844+ let cV = fs._2
845+ let dH = fs._3
846+ let fl = fs._4
847+ let dO = fs._5
848+ $Tuple2(nil, $Tuple3(fm, dH, fl))
849+ }
850+
851+
852+
853+@Callable(dt)
854+func getOneTkn (ft,fe) = {
855+ let fg = {
856+ let fh = invoke(aJ, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
857+ if ($isInstanceOf(fh, "Boolean"))
858+ then fh
859+ else throw(($getType(fh) + " couldn't be cast to Boolean"))
860+ }
861+ let fu = if (if (aL())
862+ then true
863+ else (aY == n))
864+ then true
865+ else fg
866+ let ep = [if (if (!(fu))
867+ then true
868+ else eJ(dt))
869+ then true
870+ else aG("get operation is blocked by admin"), if ((size(dt.payments) == 1))
871+ then true
872+ else aG("exactly 1 payment are expected")]
873+ if ((ep == ep))
874+ then {
875+ let eo = aQ(ft)
876+ let fj = dt.payments[0]
877+ let dK = fj.assetId
878+ let dW = fj.amount
879+ let X = dt.caller
880+ let Y = dt.transactionId
881+ let fv = en(eo, dW, dK, X, Y)
882+ if ((fv == fv))
883+ then {
884+ let eq = fv._5
885+ let fl = fv._4
886+ let dH = fv._3
887+ let cV = fv._2
888+ let fw = fv._1
889+ let dB = if (if ((fe > 0))
890+ then (fe > fw)
891+ else false)
892+ then aG(makeString(["amount to receive is less than ", toString(fe)], ""))
893+ else fw
894+ let fx = invoke(aJ, "burn", [dW], [AttachedPayment(dK, dW)])
895+ if ((fx == fx))
896+ then {
897+ let fy = [ScriptTransfer(X, dB, eo)]
898+ let fp = if ((dH > 0))
899+ then [ScriptTransfer(aK, dH, eo)]
900+ else nil
901+ let fz = {
902+ let fA = if ((this == aK))
903+ then 0
904+ else dH
905+ if (eq)
906+ then $Tuple2(-((dB + fA)), 0)
907+ else $Tuple2(0, -((dB + fA)))
908+ }
909+ let db = fz._1
910+ let dc = fz._2
911+ let fB = da(db, dc, 0)
912+ let fb = fB._1
913+ let cZ = fB._2
914+ $Tuple2((((cV ++ fy) ++ fp) ++ fb), dB)
915+ }
916+ else throw("Strict value is not equal to itself.")
917+ }
918+ else throw("Strict value is not equal to itself.")
919+ }
950920 else throw("Strict value is not equal to itself.")
951921 }
952922
953923
954924
955-@Callable(df)
956-func getNoLess (fo,fp) = {
957- let cA = de(df)
958- let cg = cA._1
959- let ch = cA._2
960- let dh = cA._3
961- let bP = cA._4
962- let ci = cA._5
963- if ((fo > cg))
964- then throw(((("noLessThenAmtAsset failed: " + toString(cg)) + " < ") + toString(fo)))
965- else if ((fp > ch))
966- then throw(((("noLessThenPriceAsset failed: " + toString(ch)) + " < ") + toString(fp)))
967- else {
968- let fn = invoke(aD, "burn", [dh], [AttachedPayment(bP, dh)])
969- if ((fn == fn))
970- then ci
971- else throw("Strict value is not equal to itself.")
972- }
925+@Callable(dt)
926+func getOneTknREADONLY (eo,dW) = {
927+ let fC = en(aQ(eo), dW, aZ, unit, unit)
928+ let fw = fC._1
929+ let cV = fC._2
930+ let dH = fC._3
931+ let fl = fC._4
932+ let eq = fC._5
933+ $Tuple2(nil, $Tuple3(fw, dH, fl))
973934 }
974935
975936
976937
977-@Callable(df)
978-func unstakeAndGet (dn) = {
979- let fq = if ((size(df.payments) != 0))
980- then throw("No payments are expected")
981- else true
982- if ((fq == fq))
938+@Callable(dt)
939+func unstakeAndGetOneTkn (fD,ft,fe) = {
940+ let fg = {
941+ let fh = invoke(aJ, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
942+ if ($isInstanceOf(fh, "Boolean"))
943+ then fh
944+ else throw(($getType(fh) + " couldn't be cast to Boolean"))
945+ }
946+ let fu = if (if (aL())
947+ then true
948+ else (aY == n))
949+ then true
950+ else fg
951+ let ep = [if (if (!(fu))
952+ then true
953+ else eJ(dt))
954+ then true
955+ else aG("get operation is blocked by admin"), if ((size(dt.payments) == 0))
956+ then true
957+ else aG("no payments are expected")]
958+ if ((ep == ep))
983959 then {
984- let bE = aH()
985- let bR = fromBase58String(bE[q])
986- let fk = invoke(aZ, "unstake", [toBase58String(bR), dn], nil)
987- if ((fk == fk))
960+ let eo = aQ(ft)
961+ let X = dt.caller
962+ let Y = dt.transactionId
963+ let fE = invoke(bf, "unstake", [toBase58String(aZ), fD], nil)
964+ if ((fE == fE))
988965 then {
989- let cA = bN(toBase58String(df.transactionId), toBase58String(bR), dn, df.caller)
990- let bU = parseIntValue(cA._9)
991- let ci = cA._10
992- let fr = if (if (aF())
993- then true
994- else (bU == n))
995- then throw(("Get operation is blocked by admin. Status = " + toString(bU)))
996- else true
997- if ((fr == fr))
966+ let fF = en(eo, fD, aZ, X, Y)
967+ if ((fF == fF))
998968 then {
999- let fn = invoke(aD, "burn", [dn], [AttachedPayment(bR, dn)])
1000- if ((fn == fn))
1001- then ci
969+ let eq = fF._5
970+ let fl = fF._4
971+ let dH = fF._3
972+ let cV = fF._2
973+ let fw = fF._1
974+ let dB = if (if ((fe > 0))
975+ then (fe > fw)
976+ else false)
977+ then aG(makeString(["amount to receive is less than ", toString(fe)], ""))
978+ else fw
979+ let fx = invoke(aJ, "burn", [fD], [AttachedPayment(aZ, fD)])
980+ if ((fx == fx))
981+ then {
982+ let fy = [ScriptTransfer(dt.caller, dB, eo)]
983+ let fp = if ((dH > 0))
984+ then [ScriptTransfer(aK, dH, eo)]
985+ else nil
986+ let fG = {
987+ let fA = if ((this == aK))
988+ then 0
989+ else dH
990+ if (eq)
991+ then $Tuple2(-((dB + fA)), 0)
992+ else $Tuple2(0, -((dB + fA)))
993+ }
994+ let db = fG._1
995+ let dc = fG._2
996+ let fH = da(db, dc, 0)
997+ let fb = fH._1
998+ let cZ = fH._2
999+ $Tuple2((((cV ++ fy) ++ fp) ++ fb), dB)
1000+ }
10021001 else throw("Strict value is not equal to itself.")
10031002 }
10041003 else throw("Strict value is not equal to itself.")
10101009
10111010
10121011
1013-@Callable(df)
1014-func unstakeAndGetNoLess (fj,fs,fp) = {
1015- let fd = if (aF())
1016- then true
1017- else (aS == n)
1018- let ed = [if (!(fd))
1019- then true
1020- else throw("get operation is blocked by admin"), if ((size(df.payments) == 0))
1021- then true
1022- else throw("no payments are expected")]
1023- if ((ed == ed))
1012+@Callable(dt)
1013+func get () = {
1014+ let cG = ds(dt)
1015+ let fI = cG._1
1016+ let cn = cG._2
1017+ let dv = cG._3
1018+ let bV = cG._4
1019+ let co = cG._5
1020+ let fJ = invoke(aJ, "burn", [dv], [AttachedPayment(bV, dv)])
1021+ if ((fJ == fJ))
10241022 then {
1025- let fk = invoke(aZ, "unstake", [toBase58String(aT), fj], nil)
1026- if ((fk == fk))
1023+ let fK = da(-(fI), -(cn), 0)
1024+ let fb = fK._1
1025+ let cZ = fK._2
1026+ (co ++ fb)
1027+ }
1028+ else throw("Strict value is not equal to itself.")
1029+ }
1030+
1031+
1032+
1033+@Callable(dt)
1034+func getNoLess (fL,fM) = {
1035+ let cG = ds(dt)
1036+ let cm = cG._1
1037+ let cn = cG._2
1038+ let dv = cG._3
1039+ let bV = cG._4
1040+ let co = cG._5
1041+ if ((fL > cm))
1042+ then throw(((("noLessThenAmtAsset failed: " + toString(cm)) + " < ") + toString(fL)))
1043+ else if ((fM > cn))
1044+ then throw(((("noLessThenPriceAsset failed: " + toString(cn)) + " < ") + toString(fM)))
1045+ else {
1046+ let fJ = invoke(aJ, "burn", [dv], [AttachedPayment(bV, dv)])
1047+ if ((fJ == fJ))
1048+ then {
1049+ let fN = da(-(cm), -(cn), 0)
1050+ let fb = fN._1
1051+ let cZ = fN._2
1052+ (co ++ fb)
1053+ }
1054+ else throw("Strict value is not equal to itself.")
1055+ }
1056+ }
1057+
1058+
1059+
1060+@Callable(dt)
1061+func unstakeAndGet (dB) = {
1062+ let fO = if ((size(dt.payments) != 0))
1063+ then throw("No payments are expected")
1064+ else true
1065+ if ((fO == fO))
1066+ then {
1067+ let bK = aN()
1068+ let bX = fromBase58String(bK[q])
1069+ let fE = invoke(bf, "unstake", [toBase58String(bX), dB], nil)
1070+ if ((fE == fE))
10271071 then {
1028- let cA = bN(toBase58String(df.transactionId), toBase58String(aT), fj, df.caller)
1029- let cg = cA._1
1030- let ch = cA._2
1031- let ci = cA._10
1032- let ft = [if ((cg >= fs))
1072+ let cG = bT(toBase58String(dt.transactionId), toBase58String(bX), dB, dt.caller)
1073+ let cm = cG._1
1074+ let cn = cG._2
1075+ let ca = parseIntValue(cG._9)
1076+ let co = cG._10
1077+ let fP = if (if (aL())
10331078 then true
1034- else throw(makeString(["amount asset amount to receive is less than ", toString(fs)], "")), if ((ch >= fp))
1035- then true
1036- else throw(makeString(["price asset amount to receive is less than ", toString(fp)], ""))]
1037- if ((ft == ft))
1079+ else (ca == n))
1080+ then throw(("Get operation is blocked by admin. Status = " + toString(ca)))
1081+ else true
1082+ if ((fP == fP))
10381083 then {
1039- let fn = invoke(aD, "burn", [fj], [AttachedPayment(aT, fj)])
1040- if ((fn == fn))
1041- then ci
1084+ let fJ = invoke(aJ, "burn", [dB], [AttachedPayment(bX, dB)])
1085+ if ((fJ == fJ))
1086+ then {
1087+ let fQ = da(-(cm), -(cn), 0)
1088+ let fb = fQ._1
1089+ let cZ = fQ._2
1090+ (co ++ fb)
1091+ }
10421092 else throw("Strict value is not equal to itself.")
10431093 }
10441094 else throw("Strict value is not equal to itself.")
10501100
10511101
10521102
1053-@Callable(df)
1054-func activate (fu,fv) = if ((toString(df.caller) != toString(aD)))
1055- then throw("permissions denied")
1056- else $Tuple2([StringEntry(aa(), fu), StringEntry(ab(), fv)], "success")
1057-
1058-
1059-
1060-@Callable(df)
1061-func getPoolConfigWrapperREADONLY () = $Tuple2(nil, aH())
1062-
1063-
1064-
1065-@Callable(df)
1066-func getAccBalanceWrapperREADONLY (br) = $Tuple2(nil, bq(br))
1067-
1068-
1069-
1070-@Callable(df)
1071-func calcPricesWrapperREADONLY (by,bz,bD) = {
1072- let bM = bC(by, bz, bD)
1073- $Tuple2(nil, [toString(bM[0]), toString(bM[1]), toString(bM[2])])
1103+@Callable(dt)
1104+func unstakeAndGetNoLess (fD,fR,fM) = {
1105+ let fu = if (aL())
1106+ then true
1107+ else (aY == n)
1108+ let ep = [if (!(fu))
1109+ then true
1110+ else throw("get operation is blocked by admin"), if ((size(dt.payments) == 0))
1111+ then true
1112+ else throw("no payments are expected")]
1113+ if ((ep == ep))
1114+ then {
1115+ let fE = invoke(bf, "unstake", [toBase58String(aZ), fD], nil)
1116+ if ((fE == fE))
1117+ then {
1118+ let cG = bT(toBase58String(dt.transactionId), toBase58String(aZ), fD, dt.caller)
1119+ let cm = cG._1
1120+ let cn = cG._2
1121+ let co = cG._10
1122+ let fS = [if ((cm >= fR))
1123+ then true
1124+ else throw(makeString(["amount asset amount to receive is less than ", toString(fR)], "")), if ((cn >= fM))
1125+ then true
1126+ else throw(makeString(["price asset amount to receive is less than ", toString(fM)], ""))]
1127+ if ((fS == fS))
1128+ then {
1129+ let fJ = invoke(aJ, "burn", [fD], [AttachedPayment(aZ, fD)])
1130+ if ((fJ == fJ))
1131+ then {
1132+ let fT = da(-(cm), -(cn), 0)
1133+ let fb = fT._1
1134+ let cZ = fT._2
1135+ (co ++ fb)
1136+ }
1137+ else throw("Strict value is not equal to itself.")
1138+ }
1139+ else throw("Strict value is not equal to itself.")
1140+ }
1141+ else throw("Strict value is not equal to itself.")
1142+ }
1143+ else throw("Strict value is not equal to itself.")
10741144 }
10751145
10761146
10771147
1078-@Callable(df)
1148+@Callable(dt)
1149+func activate (fU,fV) = if ((toString(dt.caller) != toString(aJ)))
1150+ then throw("permissions denied")
1151+ else $Tuple2([StringEntry(aa(), fU), StringEntry(ab(), fV)], "success")
1152+
1153+
1154+
1155+@Callable(dt)
1156+func refreshKLp () = {
1157+ let fW = valueOrElse(getInteger(ag), 0)
1158+ let fX = if (((height - fW) >= aj))
1159+ then unit
1160+ else aG(makeString([toString(aj), " blocks have not passed since the previous call"], ""))
1161+ if ((fX == fX))
1162+ then {
1163+ let fY = da(0, 0, 0)
1164+ let dh = fY._1
1165+ let cZ = fY._2
1166+ $Tuple2(dh, toString(cZ))
1167+ }
1168+ else throw("Strict value is not equal to itself.")
1169+ }
1170+
1171+
1172+
1173+@Callable(dt)
1174+func getPoolConfigWrapperREADONLY () = $Tuple2(nil, aN())
1175+
1176+
1177+
1178+@Callable(dt)
1179+func getAccBalanceWrapperREADONLY (bx) = $Tuple2(nil, bw(bx))
1180+
1181+
1182+
1183+@Callable(dt)
1184+func calcPricesWrapperREADONLY (bE,bF,bJ) = {
1185+ let bS = bI(bE, bF, bJ)
1186+ $Tuple2(nil, [toString(bS[0]), toString(bS[1]), toString(bS[2])])
1187+ }
1188+
1189+
1190+
1191+@Callable(dt)
10791192 func toX18WrapperREADONLY (E,F) = $Tuple2(nil, toString(D(E, F)))
10801193
10811194
10821195
1083-@Callable(df)
1196+@Callable(dt)
10841197 func fromX18WrapperREADONLY (H,I) = $Tuple2(nil, G(parseBigIntValue(H), I))
10851198
10861199
10871200
1088-@Callable(df)
1089-func calcPriceBigIntWrapperREADONLY (bt,bu) = $Tuple2(nil, toString(bs(parseBigIntValue(bt), parseBigIntValue(bu))))
1201+@Callable(dt)
1202+func calcPriceBigIntWrapperREADONLY (bz,bA) = $Tuple2(nil, toString(by(parseBigIntValue(bz), parseBigIntValue(bA))))
10901203
10911204
10921205
1093-@Callable(df)
1094-func estimatePutOperationWrapperREADONLY (bO,ck,cl,cm,cn,co,X,cp,cq) = $Tuple2(nil, cj(bO, ck, cl, cm, cn, co, X, cp, cq))
1206+@Callable(dt)
1207+func estimatePutOperationWrapperREADONLY (bU,cq,cr,cs,ct,cu,X,cv,cw) = $Tuple2(nil, cp(bU, cq, cr, cs, ct, cu, X, cv, cw))
10951208
10961209
10971210
1098-@Callable(df)
1099-func estimateGetOperationWrapperREADONLY (bO,bP,bQ,X) = {
1100- let cA = bN(bO, bP, bQ, addressFromStringValue(X))
1101- $Tuple2(nil, $Tuple10(cA._1, cA._2, cA._3, cA._4, cA._5, cA._6, cA._7, toString(cA._8), cA._9, cA._10))
1211+@Callable(dt)
1212+func estimateGetOperationWrapperREADONLY (bU,bV,bW,X) = {
1213+ let cG = bT(bU, bV, bW, addressFromStringValue(X))
1214+ $Tuple2(nil, $Tuple10(cG._1, cG._2, cG._3, cG._4, cG._5, cG._6, cG._7, toString(cG._8), cG._9, cG._10))
11021215 }
11031216
11041217
11051218
1106-@Callable(df)
1219+@Callable(dt)
11071220 func statsREADONLY () = {
1108- let bE = aH()
1109- let bR = fromBase58String(bE[q])
1110- let cS = bE[r]
1111- let cT = bE[s]
1112- let ct = bE[v]
1113- let cu = bE[w]
1114- let bF = parseIntValue(bE[t])
1115- let bG = parseIntValue(bE[u])
1116- let fw = valueOrErrorMessage(assetInfo(bR), (("Asset " + toBase58String(bR)) + " doesn't exist")).quantity
1117- let cU = bq(cS)
1118- let cV = bq(cT)
1119- let fx = if ((fw == 0))
1221+ let bK = aN()
1222+ let bX = fromBase58String(bK[q])
1223+ let fZ = bK[r]
1224+ let ga = bK[s]
1225+ let cz = bK[v]
1226+ let cA = bK[w]
1227+ let bL = parseIntValue(bK[t])
1228+ let bM = parseIntValue(bK[u])
1229+ let gb = valueOrErrorMessage(assetInfo(bX), (("Asset " + toBase58String(bX)) + " doesn't exist")).quantity
1230+ let gc = bw(fZ)
1231+ let gd = bw(ga)
1232+ let ge = if ((gb == 0))
11201233 then [e, e, e]
1121- else bC(cU, cV, fw)
1122- let cb = 0
1123- let fy = G(fx[1], b)
1124- let fz = G(fx[2], b)
1125- let fA = value(getInteger(aD, ap(toString(this))))
1126- $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))
1234+ else bI(gc, gd, gb)
1235+ let ch = 0
1236+ let gf = G(ge[1], b)
1237+ let gg = G(ge[2], b)
1238+ let gh = value(getInteger(aJ, au(toString(this))))
1239+ $Tuple2(nil, makeString(["%d%d%d%d%d%d%d", toString(gc), toString(gd), toString(gb), toString(ch), toString(gf), toString(gg), toString(gh)], j))
11271240 }
11281241
11291242
11301243
1131-@Callable(df)
1132-func evaluatePutByAmountAssetREADONLY (cl) = {
1133- let bE = aH()
1134- let bR = fromBase58String(bE[q])
1135- let cr = bE[r]
1136- let bS = fromBase58String(cr)
1137- let cs = bE[s]
1138- let bT = fromBase58String(cs)
1139- let bF = parseIntValue(bE[t])
1140- let bG = parseIntValue(bE[u])
1141- let bU = bE[p]
1142- let fw = valueOrErrorMessage(assetInfo(bR), (("Asset " + toBase58String(bR)) + " doesn't exist")).quantity
1143- let cU = bq(cr)
1144- let cV = bq(cs)
1145- let bA = D(cU, bF)
1146- let bB = D(cV, bG)
1147- let ca = if ((fw == 0))
1244+@Callable(dt)
1245+func evaluatePutByAmountAssetREADONLY (cr) = {
1246+ let bK = aN()
1247+ let bX = fromBase58String(bK[q])
1248+ let cx = bK[r]
1249+ let bY = fromBase58String(cx)
1250+ let cy = bK[s]
1251+ let bZ = fromBase58String(cy)
1252+ let bL = parseIntValue(bK[t])
1253+ let bM = parseIntValue(bK[u])
1254+ let ca = bK[p]
1255+ let gb = valueOrErrorMessage(assetInfo(bX), (("Asset " + toBase58String(bX)) + " doesn't exist")).quantity
1256+ let gc = bw(cx)
1257+ let gd = bw(cy)
1258+ let bG = D(gc, bL)
1259+ let bH = D(gd, bM)
1260+ let cg = if ((gb == 0))
11481261 then e
1149- else bs(bB, bA)
1150- let cx = D(cl, bF)
1151- let cy = fraction(cx, ca, d)
1152- let cn = G(cy, bG)
1153- let dl = cj("", 500000, cl, bS, cn, bT, "", true, false)
1154- let cI = dl._1
1155- let fB = dl._3
1156- let bW = dl._4
1157- let bY = dl._5
1158- let bV = dl._6
1159- $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))
1262+ else by(bH, bG)
1263+ let cD = D(cr, bL)
1264+ let cE = fraction(cD, cg, d)
1265+ let ct = G(cE, bM)
1266+ let dz = cp("", 500000, cr, bY, ct, bZ, "", true, false)
1267+ let cO = dz._1
1268+ let gi = dz._3
1269+ let cc = dz._4
1270+ let ce = dz._5
1271+ let cb = dz._6
1272+ $Tuple2(nil, makeString(["%d%d%d%d%d%d%d%d", toString(cO), toString(G(cg, b)), toString(cc), toString(ce), toString(cb), ca, toString(cr), toString(ct)], j))
11601273 }
11611274
11621275
11631276
1164-@Callable(df)
1165-func evaluatePutByPriceAssetREADONLY (cn) = {
1166- let bE = aH()
1167- let bR = fromBase58String(bE[q])
1168- let cr = bE[r]
1169- let bS = fromBase58String(cr)
1170- let cs = bE[s]
1171- let bT = fromBase58String(cs)
1172- let bF = parseIntValue(bE[t])
1173- let bG = parseIntValue(bE[u])
1174- let bU = bE[p]
1175- let fw = valueOrErrorMessage(assetInfo(bR), (("Asset " + toBase58String(bR)) + " doesn't exist")).quantity
1176- let fC = bq(cr)
1177- let fD = bq(cs)
1178- let fE = D(fC, bF)
1179- let fF = D(fD, bG)
1180- let ca = if ((fw == 0))
1277+@Callable(dt)
1278+func evaluatePutByPriceAssetREADONLY (ct) = {
1279+ let bK = aN()
1280+ let bX = fromBase58String(bK[q])
1281+ let cx = bK[r]
1282+ let bY = fromBase58String(cx)
1283+ let cy = bK[s]
1284+ let bZ = fromBase58String(cy)
1285+ let bL = parseIntValue(bK[t])
1286+ let bM = parseIntValue(bK[u])
1287+ let ca = bK[p]
1288+ let gb = valueOrErrorMessage(assetInfo(bX), (("Asset " + toBase58String(bX)) + " doesn't exist")).quantity
1289+ let gj = bw(cx)
1290+ let gk = bw(cy)
1291+ let gl = D(gj, bL)
1292+ let gm = D(gk, bM)
1293+ let cg = if ((gb == 0))
11811294 then e
1182- else bs(fF, fE)
1183- let cy = D(cn, bG)
1184- let cx = fraction(cy, d, ca)
1185- let cl = G(cx, bF)
1186- let dl = cj("", 500000, cl, bS, cn, bT, "", true, false)
1187- let cI = dl._1
1188- let fB = dl._3
1189- let bW = dl._4
1190- let bY = dl._5
1191- let bV = dl._6
1192- $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))
1295+ else by(gm, gl)
1296+ let cE = D(ct, bM)
1297+ let cD = fraction(cE, d, cg)
1298+ let cr = G(cD, bL)
1299+ let dz = cp("", 500000, cr, bY, ct, bZ, "", true, false)
1300+ let cO = dz._1
1301+ let gi = dz._3
1302+ let cc = dz._4
1303+ let ce = dz._5
1304+ let cb = dz._6
1305+ $Tuple2(nil, makeString(["%d%d%d%d%d%d%d%d", toString(cO), toString(G(cg, b)), toString(cc), toString(ce), toString(cb), ca, toString(cr), toString(ct)], j))
11931306 }
11941307
11951308
11961309
1197-@Callable(df)
1198-func evaluateGetREADONLY (fG,fH) = {
1199- let cA = bN("", fG, fH, this)
1200- let cg = cA._1
1201- let ch = cA._2
1202- let bW = cA._5
1203- let bY = cA._6
1204- let bV = cA._7
1205- let cb = cA._8
1206- let bU = parseIntValue(cA._9)
1207- $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))
1310+@Callable(dt)
1311+func evaluateGetREADONLY (gn,go) = {
1312+ let cG = bT("", gn, go, this)
1313+ let cm = cG._1
1314+ let cn = cG._2
1315+ let cc = cG._5
1316+ let ce = cG._6
1317+ let cb = cG._7
1318+ let ch = cG._8
1319+ let ca = parseIntValue(cG._9)
1320+ $Tuple2(nil, makeString(["%d%d%d%d%d%d%d", toString(cm), toString(cn), toString(cc), toString(ce), toString(cb), toString(ch), toString(ca)], j))
12081321 }
12091322
12101323
1211-@Verifier(fI)
1212-func fJ () = {
1213- let fK = {
1214- let dq = eu()
1215- if ($isInstanceOf(dq, "ByteVector"))
1324+@Verifier(gp)
1325+func gq () = {
1326+ let gr = {
1327+ let dE = eG()
1328+ if ($isInstanceOf(dE, "ByteVector"))
12161329 then {
1217- let ey = dq
1218- ey
1330+ let eK = dE
1331+ eK
12191332 }
1220- else if ($isInstanceOf(dq, "Unit"))
1221- then fI.senderPublicKey
1333+ else if ($isInstanceOf(dE, "Unit"))
1334+ then gp.senderPublicKey
12221335 else throw("Match error")
12231336 }
1224- let dq = fI
1225- if ($isInstanceOf(dq, "Order"))
1337+ let dE = gp
1338+ if ($isInstanceOf(dE, "Order"))
12261339 then {
1227- let cR = dq
1228- let fL = aG()
1229- let au = cQ(cR)
1230- let av = sigVerify(cR.bodyBytes, cR.proofs[0], cR.senderPublicKey)
1231- let aw = sigVerify(cR.bodyBytes, cR.proofs[1], fL)
1232- if (if (if (au)
1233- then av
1340+ let dj = dE
1341+ let gs = aM()
1342+ let az = di(dj)
1343+ let aA = sigVerify(dj.bodyBytes, dj.proofs[0], dj.senderPublicKey)
1344+ let aB = sigVerify(dj.bodyBytes, dj.proofs[1], gs)
1345+ if (if (if (az)
1346+ then aA
12341347 else false)
1235- then aw
1348+ then aB
12361349 else false)
12371350 then true
1238- else at(au, av, aw)
1351+ else ay(az, aA, aB)
12391352 }
1240- else if ($isInstanceOf(dq, "SetScriptTransaction"))
1353+ else if ($isInstanceOf(dE, "SetScriptTransaction"))
12411354 then {
1242- let ev = dq
1243- let fM = blake2b256(value(ev.script))
1244- let fN = fromBase64String(value(getString(aD, ar())))
1245- let fO = scriptHash(this)
1246- if (if ((fN == fM))
1247- then (fO != fM)
1355+ let eH = dE
1356+ let gt = blake2b256(value(eH.script))
1357+ let gu = fromBase64String(value(getString(aJ, aw())))
1358+ let gv = scriptHash(this)
1359+ if (if ((gu == gt))
1360+ then (gv != gt)
12481361 else false)
12491362 then true
1250- else sigVerify(fI.bodyBytes, fI.proofs[0], fK)
1363+ else sigVerify(gp.bodyBytes, gp.proofs[0], gr)
12511364 }
1252- else sigVerify(fI.bodyBytes, fI.proofs[0], fK)
1365+ else sigVerify(gp.bodyBytes, gp.proofs[0], gr)
12531366 }
12541367
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
8181 func P () = "%s__factoryContract"
8282
8383
8484 func Q () = "%s__managerPublicKey"
8585
8686
8787 func R () = "%s__pendingManagerPublicKey"
8888
8989
9090 func S () = "%s%s__price__last"
9191
9292
9393 func T (U,V) = makeString(["%s%s%d%d__price__history", toString(U), toString(V)], j)
9494
9595
9696 func W (X,Y) = ((("%s%s%s__P__" + X) + "__") + Y)
9797
9898
9999 func Z (X,Y) = ((("%s%s%s__G__" + X) + "__") + Y)
100100
101101
102102 func aa () = "%s__amountAsset"
103103
104104
105105 func ab () = "%s__priceAsset"
106106
107107
108108 let ac = "%s__fee"
109109
110110 let ad = fraction(10, b, 10000)
111111
112112 let ae = valueOrElse(getInteger(this, ac), ad)
113113
114-func af () = "%s__factoryConfig"
114+let af = makeString(["%s", "kLp"], j)
115+
116+let ag = makeString(["%s", "kLpRefreshedHeight"], j)
117+
118+let ah = makeString(["%s", "refreshKLpDelay"], j)
119+
120+let ai = 30
121+
122+let aj = valueOrElse(getInteger(this, ah), ai)
123+
124+func ak () = "%s__factoryConfig"
115125
116126
117-func ag () = "%s%s__matcher__publicKey"
127+func al () = "%s%s__matcher__publicKey"
118128
119129
120-func ah (ai) = (("%s%s%s__" + ai) + "__mappings__poolContract2LpAsset")
130+func am (an) = (("%s%s%s__" + an) + "__mappings__poolContract2LpAsset")
121131
122132
123-func aj (ak,al) = (((("%d%d%s__" + ak) + "__") + al) + "__config")
133+func ao (ap,aq) = (((("%d%d%s__" + ap) + "__") + aq) + "__config")
124134
125135
126-func am (an) = ("%s%s%s__mappings__baseAsset2internalId__" + an)
136+func ar (as) = ("%s%s%s__mappings__baseAsset2internalId__" + as)
127137
128138
129-func ao () = "%s__shutdown"
139+func at () = "%s__shutdown"
130140
131141
132-func ap (aq) = ("%s%s__poolWeight__" + aq)
142+func au (av) = ("%s%s__poolWeight__" + av)
133143
134144
135-func ar () = "%s__allowedLpScriptHash"
145+func aw () = "%s__allowedLpScriptHash"
136146
137147
138-let as = "%s__feeCollectorAddress"
148+let ax = "%s__feeCollectorAddress"
139149
140-func at (au,av,aw) = throw(((((("order validation failed: orderValid=" + toString(au)) + " senderValid=") + toString(av)) + " matcherValid=") + toString(aw)))
150+func ay (az,aA,aB) = throw(((((("order validation failed: orderValid=" + toString(az)) + " senderValid=") + toString(aA)) + " matcherValid=") + toString(aB)))
141151
142152
143-func ax (ay,az) = valueOrErrorMessage(getString(ay, az), makeString(["mandatory ", toString(ay), ".", az, " is not defined"], ""))
153+func aC (aD,aE) = valueOrErrorMessage(getString(aD, aE), makeString(["mandatory ", toString(aD), ".", aE, " is not defined"], ""))
144154
145155
146-func aA (ay,az) = valueOrErrorMessage(getInteger(ay, az), makeString(["mandatory ", toString(ay), ".", az, " is not defined"], ""))
156+func aF (aD,aE) = valueOrErrorMessage(getInteger(aD, aE), makeString(["mandatory ", toString(aD), ".", aE, " is not defined"], ""))
147157
148158
149-func aB (aC) = throw(makeString(["lp.ride:", aC], " "))
159+func aG (aH) = throw(makeString(["lp.ride:", aH], " "))
150160
151161
152-let aD = addressFromStringValue(ax(this, P()))
153-
154-let aE = addressFromStringValue(ax(aD, as))
155-
156-func aF () = valueOrElse(getBoolean(aD, ao()), false)
162+func aI (aH) = makeString(["lp.ride:", aH], " ")
157163
158164
159-func aG () = fromBase58String(ax(aD, ag()))
165+let aJ = addressFromStringValue(aC(this, P()))
166+
167+let aK = addressFromStringValue(aC(aJ, ax))
168+
169+func aL () = valueOrElse(getBoolean(aJ, at()), false)
160170
161171
162-func aH () = {
163- let aI = ax(this, aa())
164- let aJ = ax(this, ab())
165- let al = aA(aD, am(aJ))
166- let ak = aA(aD, am(aI))
167- split(ax(aD, aj(toString(ak), toString(al))), j)
172+func aM () = fromBase58String(aC(aJ, al()))
173+
174+
175+func aN () = {
176+ let aO = aC(this, aa())
177+ let aP = aC(this, ab())
178+ let aq = aF(aJ, ar(aP))
179+ let ap = aF(aJ, ar(aO))
180+ split(aC(aJ, ao(toString(ap), toString(aq))), j)
168181 }
169182
170183
171-func aK (aL) = if ((aL == i))
184+func aQ (aR) = if ((aR == i))
172185 then unit
173- else fromBase58String(aL)
186+ else fromBase58String(aR)
174187
175188
176-func aM (aL) = if ((aL == unit))
189+func aS (aR) = if ((aR == unit))
177190 then i
178- else toBase58String(value(aL))
191+ else toBase58String(value(aR))
179192
180193
181-func aN (aO) = $Tuple7(addressFromStringValue(aO[o]), parseIntValue(aO[p]), fromBase58String(aO[q]), aK(aO[r]), aK(aO[s]), parseIntValue(aO[t]), parseIntValue(aO[u]))
194+func aT (aU) = $Tuple7(addressFromStringValue(aU[o]), parseIntValue(aU[p]), fromBase58String(aU[q]), aQ(aU[r]), aQ(aU[s]), parseIntValue(aU[t]), parseIntValue(aU[u]))
182195
183196
184-let aP = aN(aH())
197+let aV = aT(aN())
185198
186-let aQ = aP
199+let aW = aV
187200
188-let aR = aQ._1
201+let aX = aW._1
189202
190-let aS = aQ._2
203+let aY = aW._2
191204
192-let aT = aQ._3
205+let aZ = aW._3
193206
194-let aU = aQ._4
207+let ba = aW._4
195208
196-let aV = aQ._5
209+let bb = aW._5
197210
198-let aW = aQ._6
211+let bc = aW._6
199212
200-let aX = aQ._7
213+let bd = aW._7
201214
202-func aY () = split(ax(aD, af()), j)
215+func be () = split(aC(aJ, ak()), j)
203216
204217
205-let aZ = valueOrErrorMessage(addressFromString(aY()[B]), "incorrect staking address")
218+let bf = valueOrErrorMessage(addressFromString(be()[B]), "incorrect staking address")
206219
207-let ba = valueOrErrorMessage(addressFromString(aY()[C]), "incorrect staking address")
220+let bg = valueOrErrorMessage(addressFromString(be()[C]), "incorrect staking address")
208221
209-func bb (bc,bd,be,bf,bg,bh,bi,bj,bk,bl) = makeString(["%d%d%d%d%d%d%d%d%d%d", toString(bc), toString(bd), toString(be), toString(bf), toString(bg), toString(bh), toString(bi), toString(bj), toString(bk), toString(bl)], j)
222+func bh (bi,bj,bk,bl,bm,bn,bo,bp,bq,br) = makeString(["%d%d%d%d%d%d%d%d%d%d", toString(bi), toString(bj), toString(bk), toString(bl), toString(bm), toString(bn), toString(bo), toString(bp), toString(bq), toString(br)], j)
210223
211224
212-func bm (bn,bo,bp,bf,bi,bj) = makeString(["%d%d%d%d%d%d", toString(bn), toString(bo), toString(bp), toString(bf), toString(bi), toString(bj)], j)
225+func bs (bt,bu,bv,bl,bo,bp) = makeString(["%d%d%d%d%d%d", toString(bt), toString(bu), toString(bv), toString(bl), toString(bo), toString(bp)], j)
213226
214227
215-func bq (br) = if ((br == "WAVES"))
228+func bw (bx) = if ((bx == "WAVES"))
216229 then wavesBalance(this).available
217- else assetBalance(this, fromBase58String(br))
230+ else assetBalance(this, fromBase58String(bx))
218231
219232
220-func bs (bt,bu) = fraction(bt, d, bu)
233+func by (bz,bA) = fraction(bz, d, bA)
221234
222235
223-func bv (bw,bx,by,bz) = {
224- let bA = D(by, bw)
225- let bB = D(bz, bx)
226- bs(bB, bA)
236+func bB (bC,bD,bE,bF) = {
237+ let bG = D(bE, bC)
238+ let bH = D(bF, bD)
239+ by(bH, bG)
227240 }
228241
229242
230-func bC (by,bz,bD) = {
231- let bE = aH()
232- let bF = parseIntValue(bE[t])
233- let bG = parseIntValue(bE[u])
234- let bH = bv(bF, bG, by, bz)
235- let bu = D(by, bF)
236- let bt = D(bz, bG)
237- let bI = D(bD, b)
238- let bJ = bs(bu, bI)
239- let bK = bs(bt, bI)
240-[bH, bJ, bK]
243+func bI (bE,bF,bJ) = {
244+ let bK = aN()
245+ let bL = parseIntValue(bK[t])
246+ let bM = parseIntValue(bK[u])
247+ let bN = bB(bL, bM, bE, bF)
248+ let bA = D(bE, bL)
249+ let bz = D(bF, bM)
250+ let bO = D(bJ, b)
251+ let bP = by(bA, bO)
252+ let bQ = by(bz, bO)
253+[bN, bP, bQ]
241254 }
242255
243256
244-func bL (by,bz,bD) = {
245- let bM = bC(by, bz, bD)
246-[G(bM[0], b), G(bM[1], b), G(bM[2], b)]
257+func bR (bE,bF,bJ) = {
258+ let bS = bI(bE, bF, bJ)
259+[G(bS[0], b), G(bS[1], b), G(bS[2], b)]
247260 }
248261
249262
250-func bN (bO,bP,bQ,X) = {
251- let bE = aH()
252- let bR = bE[q]
253- let bS = bE[r]
254- let bT = bE[s]
255- let bw = parseIntValue(bE[t])
256- let bx = parseIntValue(bE[u])
257- let bU = bE[p]
258- let bV = valueOrErrorMessage(assetInfo(fromBase58String(bR)), (("Asset " + bR) + " doesn't exist")).quantity
259- if ((bR != bP))
263+func bT (bU,bV,bW,X) = {
264+ let bK = aN()
265+ let bX = bK[q]
266+ let bY = bK[r]
267+ let bZ = bK[s]
268+ let bC = parseIntValue(bK[t])
269+ let bD = parseIntValue(bK[u])
270+ let ca = bK[p]
271+ let cb = valueOrErrorMessage(assetInfo(fromBase58String(bX)), (("Asset " + bX) + " doesn't exist")).quantity
272+ if ((bX != bV))
260273 then throw("Invalid asset passed.")
261274 else {
262- let bW = bq(bS)
263- let bX = D(bW, bw)
264- let bY = bq(bT)
265- let bZ = D(bY, bx)
266- let ca = bs(bZ, bX)
267- let cb = G(ca, b)
268- let cc = D(bQ, b)
269- let cd = D(bV, b)
270- let ce = fraction(bX, cc, cd)
271- let cf = fraction(bZ, cc, cd)
272- let cg = G(ce, bw)
273- let ch = G(cf, bx)
274- let ci = if ((bO == ""))
275+ let cc = bw(bY)
276+ let cd = D(cc, bC)
277+ let ce = bw(bZ)
278+ let cf = D(ce, bD)
279+ let cg = by(cf, cd)
280+ let ch = G(cg, b)
281+ let ci = D(bW, b)
282+ let cj = D(cb, b)
283+ let ck = fraction(cd, ci, cj)
284+ let cl = fraction(cf, ci, cj)
285+ let cm = G(ck, bC)
286+ let cn = G(cl, bD)
287+ let co = if ((bU == ""))
275288 then nil
276- else [ScriptTransfer(X, cg, if ((bS == "WAVES"))
289+ else [ScriptTransfer(X, cm, if ((bY == "WAVES"))
277290 then unit
278- else fromBase58String(bS)), ScriptTransfer(X, ch, if ((bT == "WAVES"))
291+ else fromBase58String(bY)), ScriptTransfer(X, cn, if ((bZ == "WAVES"))
279292 then unit
280- else fromBase58String(bT)), StringEntry(Z(toString(X), bO), bm(cg, ch, bQ, cb, height, lastBlock.timestamp)), IntegerEntry(S(), cb), IntegerEntry(T(height, lastBlock.timestamp), cb)]
281- $Tuple10(cg, ch, bS, bT, bW, bY, bV, ca, bU, ci)
293+ else fromBase58String(bZ)), StringEntry(Z(toString(X), bU), bs(cm, cn, bW, ch, height, lastBlock.timestamp)), IntegerEntry(S(), ch), IntegerEntry(T(height, lastBlock.timestamp), ch)]
294+ $Tuple10(cm, cn, bY, bZ, cc, ce, cb, cg, ca, co)
282295 }
283296 }
284297
285298
286-func cj (bO,ck,cl,cm,cn,co,X,cp,cq) = {
287- let bE = aH()
288- let bR = fromBase58String(bE[q])
289- let cr = bE[r]
290- let cs = bE[s]
291- let ct = bE[v]
292- let cu = bE[w]
293- let bF = parseIntValue(bE[t])
294- let bG = parseIntValue(bE[u])
295- let bU = bE[p]
296- let bV = valueOrErrorMessage(assetInfo(bR), (("Asset " + toBase58String(bR)) + " doesn't exist")).quantity
297- let cv = toBase58String(valueOrElse(cm, fromBase58String("WAVES")))
298- let cw = toBase58String(valueOrElse(co, fromBase58String("WAVES")))
299- if (if ((cr != cv))
299+func cp (bU,cq,cr,cs,ct,cu,X,cv,cw) = {
300+ let bK = aN()
301+ let bX = fromBase58String(bK[q])
302+ let cx = bK[r]
303+ let cy = bK[s]
304+ let cz = bK[v]
305+ let cA = bK[w]
306+ let bL = parseIntValue(bK[t])
307+ let bM = parseIntValue(bK[u])
308+ let ca = bK[p]
309+ let cb = valueOrErrorMessage(assetInfo(bX), (("Asset " + toBase58String(bX)) + " doesn't exist")).quantity
310+ let cB = toBase58String(valueOrElse(cs, fromBase58String("WAVES")))
311+ let cC = toBase58String(valueOrElse(cu, fromBase58String("WAVES")))
312+ if (if ((cx != cB))
300313 then true
301- else (cs != cw))
314+ else (cy != cC))
302315 then throw("Invalid amt or price asset passed.")
303316 else {
304- let bW = if (cp)
305- then bq(cr)
306- else (bq(cr) - cl)
307- let bY = if (cp)
308- then bq(cs)
309- else (bq(cs) - cn)
310- let cx = D(cl, bF)
311- let cy = D(cn, bG)
312- let cz = bs(cy, cx)
313- let bX = D(bW, bF)
314- let bZ = D(bY, bG)
315- let cA = if ((bV == 0))
317+ let cc = if (cv)
318+ then bw(cx)
319+ else (bw(cx) - cr)
320+ let ce = if (cv)
321+ then bw(cy)
322+ else (bw(cy) - ct)
323+ let cD = D(cr, bL)
324+ let cE = D(ct, bM)
325+ let cF = by(cE, cD)
326+ let cd = D(cc, bL)
327+ let cf = D(ce, bM)
328+ let cG = if ((cb == 0))
316329 then {
317- let ca = e
318- let cB = e
319- let bI = pow((cx * cy), 0, toBigInt(5), 1, 0, DOWN)
320- $Tuple5(G(bI, b), G(cx, bF), G(cy, bG), bs((bZ + cy), (bX + cx)), cB)
330+ let cg = e
331+ let cH = e
332+ let bO = pow((cD * cE), 0, toBigInt(5), 1, 0, DOWN)
333+ $Tuple5(G(bO, b), G(cD, bL), G(cE, bM), by((cf + cE), (cd + cD)), cH)
321334 }
322335 else {
323- let ca = bs(bZ, bX)
324- let cB = fraction(O((ca - cz)), d, ca)
325- let cC = D(ck, b)
326- if (if ((ca != e))
327- then (cB > cC)
336+ let cg = by(cf, cd)
337+ let cH = fraction(O((cg - cF)), d, cg)
338+ let cI = D(cq, b)
339+ if (if ((cg != e))
340+ then (cH > cI)
328341 else false)
329- then throw(((("Price slippage " + toString(cB)) + " exceeded the passed limit of ") + toString(cC)))
342+ then throw(((("Price slippage " + toString(cH)) + " exceeded the passed limit of ") + toString(cI)))
330343 else {
331- let cd = D(bV, b)
332- let cD = fraction(cx, ca, d)
333- let cE = fraction(cy, d, ca)
334- let cF = if ((cD > cy))
335- then $Tuple2(cE, cy)
336- else $Tuple2(cx, cD)
337- let cG = cF._1
338- let cH = cF._2
339- let bI = fraction(cd, cH, bZ)
340- $Tuple5(G(bI, b), G(cG, bF), G(cH, bG), ca, cB)
344+ let cj = D(cb, b)
345+ let cJ = fraction(cD, cg, d)
346+ let cK = fraction(cE, d, cg)
347+ let cL = if ((cJ > cE))
348+ then $Tuple2(cK, cE)
349+ else $Tuple2(cD, cJ)
350+ let cM = cL._1
351+ let cN = cL._2
352+ let bO = fraction(cj, cN, cf)
353+ $Tuple5(G(bO, b), G(cM, bL), G(cN, bM), cg, cH)
341354 }
342355 }
343- let cI = cA._1
344- let cJ = cA._2
345- let cK = cA._3
346- let cb = G(cA._4, b)
347- let cL = G(cA._5, b)
348- if ((0 >= cI))
356+ let cO = cG._1
357+ let cP = cG._2
358+ let cQ = cG._3
359+ let ch = G(cG._4, b)
360+ let cR = G(cG._5, b)
361+ if ((0 >= cO))
349362 then throw("Invalid calculations. LP calculated is less than zero.")
350363 else {
351- let cM = if (!(cq))
364+ let cS = if (!(cw))
352365 then 0
353- else cI
354- let cN = (cl - cJ)
355- let cO = (cn - cK)
356- let cP = [IntegerEntry(S(), cb), IntegerEntry(T(height, lastBlock.timestamp), cb), StringEntry(W(X, bO), bb(cJ, cK, cM, cb, ck, cL, height, lastBlock.timestamp, cN, cO))]
357- $Tuple13(cI, cM, cb, bW, bY, bV, bR, bU, cP, cN, cO, cm, co)
366+ else cO
367+ let cT = (cr - cP)
368+ let cU = (ct - cQ)
369+ let cV = [IntegerEntry(S(), ch), IntegerEntry(T(height, lastBlock.timestamp), ch), StringEntry(W(X, bU), bh(cP, cQ, cS, ch, cq, cR, height, lastBlock.timestamp, cT, cU))]
370+ $Tuple13(cO, cS, ch, cc, ce, cb, bX, ca, cV, cT, cU, cs, cu)
358371 }
359372 }
360373 }
361374
362375
363-func cQ (cR) = {
364- let bE = aH()
365- let cS = bE[r]
366- let cT = bE[s]
367- let bU = parseIntValue(bE[p])
368- let bF = parseIntValue(bE[t])
369- let bG = parseIntValue(bE[u])
370- let cU = bq(cS)
371- let cV = bq(cT)
372- let ca = if ((cR.orderType == Buy))
373- then bv(bF, bG, (cU + cR.amount), cV)
374- else bv(bF, bG, (cU - cR.amount), cV)
375- let cb = G(ca, b)
376- if (if (if (aF())
377- then true
378- else (bU == m))
379- then true
380- else (bU == n))
381- then throw("Exchange operations disabled")
382- else {
383- let cW = cR.assetPair.amountAsset
384- let cX = if ((cW == unit))
385- then "WAVES"
386- else toBase58String(value(cW))
387- let cY = cR.assetPair.priceAsset
388- let cZ = if ((cY == unit))
389- then "WAVES"
390- else toBase58String(value(cY))
391- if (if ((cX != cS))
392- then true
393- else (cZ != cT))
394- then throw("Wrong order assets.")
395- else {
396- let da = cR.price
397- let db = fraction(b, bG, bF)
398- let dc = J(da, b, db)
399- let dd = if ((cR.orderType == Buy))
400- then (cb >= dc)
401- else (dc >= cb)
402- true
403- }
404- }
376+func cW (cX,cY,cb) = {
377+ let cZ = fraction(pow((cX * cY), 0, toBigInt(5), 1, 0, DOWN), d, cb)
378+ cZ
405379 }
406380
407381
408-func de (df) = if ((size(df.payments) != 1))
382+func da (db,dc,dd) = {
383+ let de = (bw(aS(ba)) + db)
384+ let df = (bw(aS(bb)) + dc)
385+ let dg = (value(assetInfo(aZ)).quantity + dd)
386+ let cZ = cW(toBigInt(de), toBigInt(df), toBigInt(dg))
387+ let dh = [IntegerEntry(ag, height), StringEntry(af, toString(cZ))]
388+ $Tuple2(dh, cZ)
389+ }
390+
391+
392+func di (dj) = {
393+ let dk = dj.amount
394+ let dl = fraction(dj.amount, dj.price, b)
395+ let dm = if ((dj.orderType == Buy))
396+ then $Tuple2(dk, -(dl))
397+ else $Tuple2(-(dk), dl)
398+ let db = dm._1
399+ let dc = dm._2
400+ if (if (if (aL())
401+ then true
402+ else (aY == m))
403+ then true
404+ else (aY == n))
405+ then throw("Exchange operations disabled")
406+ else if (if ((dj.assetPair.amountAsset != ba))
407+ then true
408+ else (dj.assetPair.priceAsset != bb))
409+ then throw("Wrong order assets.")
410+ else {
411+ let dn = valueOrErrorMessage(parseBigInt(valueOrErrorMessage(getString(this, af), aI("kLp is required"))), aI("invalid kLp"))
412+ let do = da(db, dc, 0)
413+ let dp = do._1
414+ let dq = do._2
415+ let dr = (dq > dn)
416+ dr
417+ }
418+ }
419+
420+
421+func ds (dt) = if ((size(dt.payments) != 1))
409422 then throw("exactly 1 payment is expected")
410423 else {
411- let dg = value(df.payments[0])
412- let bP = value(dg.assetId)
413- let dh = dg.amount
414- let cA = bN(toBase58String(df.transactionId), toBase58String(bP), dh, df.caller)
415- let cg = cA._1
416- let ch = cA._2
417- let bU = parseIntValue(cA._9)
418- let ci = cA._10
419- if (if (aF())
424+ let du = value(dt.payments[0])
425+ let bV = value(du.assetId)
426+ let dv = du.amount
427+ let cG = bT(toBase58String(dt.transactionId), toBase58String(bV), dv, dt.caller)
428+ let cm = cG._1
429+ let cn = cG._2
430+ let ca = parseIntValue(cG._9)
431+ let co = cG._10
432+ if (if (aL())
420433 then true
421- else (bU == n))
422- then throw(("Get operation is blocked by admin. Status = " + toString(bU)))
423- else $Tuple5(cg, ch, dh, bP, ci)
434+ else (ca == n))
435+ then throw(("Get operation is blocked by admin. Status = " + toString(ca)))
436+ else $Tuple5(cm, cn, dv, bV, co)
424437 }
425438
426439
427-func di (df,ck,cq) = if ((size(df.payments) != 2))
440+func dw (dt,cq,cw) = if ((size(dt.payments) != 2))
428441 then throw("exactly 2 payments are expected")
429442 else {
430- let dj = value(df.payments[0])
431- let dk = value(df.payments[1])
432- let dl = cj(toBase58String(df.transactionId), ck, dj.amount, dj.assetId, dk.amount, dk.assetId, toString(df.caller), false, cq)
433- let bU = parseIntValue(dl._8)
434- if (if (if (aF())
443+ let dx = value(dt.payments[0])
444+ let dy = value(dt.payments[1])
445+ let dz = cp(toBase58String(dt.transactionId), cq, dx.amount, dx.assetId, dy.amount, dy.assetId, toString(dt.caller), false, cw)
446+ let ca = parseIntValue(dz._8)
447+ if (if (if (aL())
435448 then true
436- else (bU == l))
449+ else (ca == l))
437450 then true
438- else (bU == n))
439- then throw(("Put operation is blocked by admin. Status = " + toString(bU)))
440- else dl
451+ else (ca == n))
452+ then throw(("Put operation is blocked by admin. Status = " + toString(ca)))
453+ else dz
441454 }
442455
443456
444-func dm (dn) = {
445- let do = invoke(aD, "emit", [dn], nil)
446- if ((do == do))
457+func dA (dB) = {
458+ let dC = invoke(aJ, "emit", [dB], nil)
459+ if ((dC == dC))
447460 then {
448- let dp = {
449- let dq = do
450- if ($isInstanceOf(dq, "Address"))
461+ let dD = {
462+ let dE = dC
463+ if ($isInstanceOf(dE, "Address"))
451464 then {
452- let dr = dq
453- invoke(dr, "emit", [dn], nil)
465+ let dF = dE
466+ invoke(dF, "emit", [dB], nil)
454467 }
455468 else unit
456469 }
457- if ((dp == dp))
458- then dn
470+ if ((dD == dD))
471+ then dB
459472 else throw("Strict value is not equal to itself.")
460473 }
461474 else throw("Strict value is not equal to itself.")
462475 }
463476
464477
465-func ds (dn) = {
466- let dt = fraction(dn, ae, b)
467- $Tuple2((dn - dt), dt)
478+func dG (dB) = {
479+ let dH = fraction(dB, ae, b)
480+ $Tuple2((dB - dH), dH)
468481 }
469482
470483
471-func du (dv,dw,X,Y) = {
472- let dx = (Y == unit)
473- let dy = bq(aM(aU))
474- let dz = bq(aM(aV))
475- let dA = if ((dw == aU))
484+func dI (dJ,dK,X,Y) = {
485+ let dL = (Y == unit)
486+ let dM = bw(aS(ba))
487+ let dN = bw(aS(bb))
488+ let dO = if ((dK == ba))
476489 then true
477- else if ((dw == aV))
490+ else if ((dK == bb))
478491 then false
479- else aB("invalid asset")
480- let dB = if (dx)
481- then $Tuple2(dy, dz)
482- else if (dA)
483- then $Tuple2((dy - dv), dz)
484- else $Tuple2(dy, (dz - dv))
485- let dC = dB._1
486- let dD = dB._2
487- let dE = if (dA)
488- then $Tuple2(dv, 0)
489- else $Tuple2(0, dv)
490- let dF = dE._1
491- let dG = dE._2
492- let dH = ds(dF)._1
493- let dI = ds(dG)._1
494- let dJ = ds(dv)
495- let dK = dJ._1
496- let dt = dJ._2
497- let dL = (dC + dH)
498- let dM = (dD + dI)
499- let dN = bs(D(dM, aX), D(dL, aW))
500- let dO = G(dN, b)
501- let dP = if (dA)
502- then dC
503- else dD
504- let dQ = toBigInt(dP)
505- let dR = toBigInt(valueOrErrorMessage(assetInfo(aT), (("asset " + toBase58String(aT)) + " doesn't exist")).quantity)
506- let dS = if ((dR > f))
492+ else aG("invalid asset")
493+ let dP = if (dL)
494+ then $Tuple2(dM, dN)
495+ else if (dO)
496+ then $Tuple2((dM - dJ), dN)
497+ else $Tuple2(dM, (dN - dJ))
498+ let dQ = dP._1
499+ let dR = dP._2
500+ let dS = if (dO)
501+ then $Tuple2(dJ, 0)
502+ else $Tuple2(0, dJ)
503+ let dT = dS._1
504+ let dU = dS._2
505+ let dk = dG(dT)._1
506+ let dl = dG(dU)._1
507+ let dV = dG(dJ)
508+ let dW = dV._1
509+ let dH = dV._2
510+ let dX = (dQ + dk)
511+ let dY = (dR + dl)
512+ let dZ = by(D(dY, bd), D(dX, bc))
513+ let ea = G(dZ, b)
514+ let eb = if (dO)
515+ then dQ
516+ else dR
517+ let ec = toBigInt(eb)
518+ let ed = toBigInt(valueOrErrorMessage(assetInfo(aZ), (("asset " + toBase58String(aZ)) + " doesn't exist")).quantity)
519+ let ee = if ((ed > f))
507520 then true
508- else aB("initial deposit requires all coins")
509- if ((dS == dS))
521+ else aG("initial deposit requires all coins")
522+ if ((ee == ee))
510523 then {
511- let dT = toBigInt(dK)
512- let dU = max([0, toInt(((dR * (sqrtBigInt((d + ((dT * d) / dQ)), 18, 18, DOWN) - d)) / d))])
513- let cP = if (dx)
524+ let ef = toBigInt(dW)
525+ let eg = max([0, toInt(((ed * (sqrtBigInt((d + ((ef * d) / ec)), 18, 18, DOWN) - d)) / d))])
526+ let cV = if (dL)
514527 then nil
515- else [IntegerEntry(S(), dO), IntegerEntry(T(height, lastBlock.timestamp), dO), StringEntry(W(toString(value(X)), toBase58String(value(Y))), bb(dF, dG, dU, dO, 0, 0, height, lastBlock.timestamp, 0, 0))]
516- let dV = bs(D(dD, aX), D(dC, aW))
517- let dW = G(dV, b)
518- let dX = {
519- let dY = if (dA)
520- then $Tuple2(dF, dC)
521- else $Tuple2(dG, dD)
522- let dn = dY._1
523- let dZ = dY._2
524- let ea = toInt(fraction(dR, toBigInt((dn / 2)), toBigInt(dZ)))
525- fraction((dU - ea), b, ea)
528+ else [IntegerEntry(S(), ea), IntegerEntry(T(height, lastBlock.timestamp), ea), StringEntry(W(toString(value(X)), toBase58String(value(Y))), bh(dT, dU, eg, ea, 0, 0, height, lastBlock.timestamp, 0, 0))]
529+ let eh = by(D(dR, bd), D(dQ, bc))
530+ let ei = G(eh, b)
531+ let ej = {
532+ let ek = if (dO)
533+ then $Tuple2(dT, dQ)
534+ else $Tuple2(dU, dR)
535+ let dB = ek._1
536+ let el = ek._2
537+ let em = toInt(fraction(ed, toBigInt((dB / 2)), toBigInt(el)))
538+ fraction((eg - em), b, em)
526539 }
527- $Tuple4(dU, cP, dt, dX)
540+ $Tuple5(eg, cV, dH, ej, dO)
528541 }
529542 else throw("Strict value is not equal to itself.")
530543 }
531544
532545
533-func eb (ec,dK,dw,X,Y) = {
534- let dx = (Y == unit)
535- let ed = [if ((dw == aT))
546+func en (eo,dW,dK,X,Y) = {
547+ let dL = (Y == unit)
548+ let ep = [if ((dK == aZ))
536549 then true
537- else aB("invalid lp asset")]
538- if ((ed == ed))
550+ else aG("invalid lp asset")]
551+ if ((ep == ep))
539552 then {
540- let ee = if ((ec == aU))
553+ let eq = if ((eo == ba))
541554 then true
542- else if ((ec == aV))
555+ else if ((eo == bb))
543556 then false
544- else aB("invalid asset")
545- let ef = if (ee)
546- then toBigInt(bq(aM(aU)))
547- else toBigInt(bq(aM(aV)))
548- let eg = bq(aM(aU))
549- let eh = bq(aM(aV))
550- let ei = if (ee)
551- then eg
552- else eh
553- let ej = toBigInt(ei)
554- let dR = toBigInt(valueOrErrorMessage(assetInfo(aT), (("asset " + toBase58String(aT)) + " doesn't exist")).quantity)
555- let ek = toBigInt(dK)
556- let el = max([0, toInt(((ef * (d - pow((d - ((ek * d) / dR)), 18, h, 0, 18, DOWN))) / d))])
557- let em = ds(el)
558- let en = em._1
559- let dt = em._2
560- let eo = if (ee)
561- then $Tuple4(en, 0, (eg - el), eh)
562- else $Tuple4(0, en, eg, (eh - el))
563- let ep = eo._1
564- let eq = eo._2
565- let er = eo._3
566- let es = eo._4
567- let dN = bs(D(es, aX), D(er, aW))
568- let dO = G(dN, b)
569- let cP = if (dx)
557+ else aG("invalid asset")
558+ let er = if (eq)
559+ then toBigInt(bw(aS(ba)))
560+ else toBigInt(bw(aS(bb)))
561+ let es = bw(aS(ba))
562+ let et = bw(aS(bb))
563+ let eu = if (eq)
564+ then es
565+ else et
566+ let ev = toBigInt(eu)
567+ let ed = toBigInt(valueOrErrorMessage(assetInfo(aZ), (("asset " + toBase58String(aZ)) + " doesn't exist")).quantity)
568+ let ew = toBigInt(dW)
569+ let ex = max([0, toInt(((er * (d - pow((d - ((ew * d) / ed)), 18, h, 0, 18, DOWN))) / d))])
570+ let ey = dG(ex)
571+ let ez = ey._1
572+ let dH = ey._2
573+ let eA = if (eq)
574+ then $Tuple4(ez, 0, (es - ex), et)
575+ else $Tuple4(0, ez, es, (et - ex))
576+ let eB = eA._1
577+ let eC = eA._2
578+ let eD = eA._3
579+ let eE = eA._4
580+ let dZ = by(D(eE, bd), D(eD, bc))
581+ let ea = G(dZ, b)
582+ let cV = if (dL)
570583 then nil
571- else [StringEntry(Z(toString(value(X)), toBase58String(value(Y))), bm(ep, eq, dK, dO, height, lastBlock.timestamp)), IntegerEntry(S(), dO), IntegerEntry(T(height, lastBlock.timestamp), dO)]
572- let dV = bs(D(eh, aX), D(eg, aW))
573- let dW = G(dV, b)
574- let dX = {
575- let et = (toInt(fraction(ef, ek, dR)) * 2)
576- fraction((en - et), b, et)
584+ else [StringEntry(Z(toString(value(X)), toBase58String(value(Y))), bs(eB, eC, dW, ea, height, lastBlock.timestamp)), IntegerEntry(S(), ea), IntegerEntry(T(height, lastBlock.timestamp), ea)]
585+ let eh = by(D(et, bd), D(es, bc))
586+ let ei = G(eh, b)
587+ let ej = {
588+ let eF = (toInt(fraction(er, ew, ed)) * 2)
589+ fraction((ez - eF), b, eF)
577590 }
578- $Tuple4(en, cP, dt, dX)
591+ $Tuple5(ez, cV, dH, ej, eq)
579592 }
580593 else throw("Strict value is not equal to itself.")
581594 }
582595
583596
584-func eu () = {
585- let dq = getString(Q())
586- if ($isInstanceOf(dq, "String"))
597+func eG () = {
598+ let dE = getString(Q())
599+ if ($isInstanceOf(dE, "String"))
587600 then {
588- let ev = dq
589- fromBase58String(ev)
601+ let eH = dE
602+ fromBase58String(eH)
590603 }
591- else if ($isInstanceOf(dq, "Unit"))
604+ else if ($isInstanceOf(dE, "Unit"))
592605 then unit
593606 else throw("Match error")
594607 }
595608
596609
597-func ew () = {
598- let dq = getString(R())
599- if ($isInstanceOf(dq, "String"))
610+func eI () = {
611+ let dE = getString(R())
612+ if ($isInstanceOf(dE, "String"))
600613 then {
601- let ev = dq
602- fromBase58String(ev)
614+ let eH = dE
615+ fromBase58String(eH)
603616 }
604- else if ($isInstanceOf(dq, "Unit"))
617+ else if ($isInstanceOf(dE, "Unit"))
605618 then unit
606619 else throw("Match error")
607620 }
608621
609622
610-func ex (df) = {
611- let dq = eu()
612- if ($isInstanceOf(dq, "ByteVector"))
623+func eJ (dt) = {
624+ let dE = eG()
625+ if ($isInstanceOf(dE, "ByteVector"))
613626 then {
614- let ey = dq
615- (df.callerPublicKey == ey)
627+ let eK = dE
628+ (dt.callerPublicKey == eK)
616629 }
617- else if ($isInstanceOf(dq, "Unit"))
618- then (df.caller == this)
630+ else if ($isInstanceOf(dE, "Unit"))
631+ then (dt.caller == this)
619632 else throw("Match error")
620633 }
621634
622635
623-func ez (df) = {
624- let eA = throw("Permission denied")
625- let dq = eu()
626- if ($isInstanceOf(dq, "ByteVector"))
636+func eL (dt) = {
637+ let eM = throw("Permission denied")
638+ let dE = eG()
639+ if ($isInstanceOf(dE, "ByteVector"))
627640 then {
628- let ey = dq
629- if ((df.callerPublicKey == ey))
641+ let eK = dE
642+ if ((dt.callerPublicKey == eK))
630643 then true
631- else eA
644+ else eM
632645 }
633- else if ($isInstanceOf(dq, "Unit"))
634- then if ((df.caller == this))
646+ else if ($isInstanceOf(dE, "Unit"))
647+ then if ((dt.caller == this))
635648 then true
636- else eA
649+ else eM
637650 else throw("Match error")
638651 }
639652
640653
641-@Callable(df)
642-func setManager (eB) = {
643- let eC = ez(df)
644- if ((eC == eC))
654+@Callable(dt)
655+func setManager (eN) = {
656+ let eO = eL(dt)
657+ if ((eO == eO))
645658 then {
646- let eD = fromBase58String(eB)
647- if ((eD == eD))
648- then [StringEntry(R(), eB)]
659+ let eP = fromBase58String(eN)
660+ if ((eP == eP))
661+ then [StringEntry(R(), eN)]
649662 else throw("Strict value is not equal to itself.")
650663 }
651664 else throw("Strict value is not equal to itself.")
652665 }
653666
654667
655668
656-@Callable(df)
669+@Callable(dt)
657670 func confirmManager () = {
658- let eE = ew()
659- let eF = if (isDefined(eE))
671+ let eQ = eI()
672+ let eR = if (isDefined(eQ))
660673 then true
661674 else throw("No pending manager")
662- if ((eF == eF))
675+ if ((eR == eR))
663676 then {
664- let eG = if ((df.callerPublicKey == value(eE)))
677+ let eS = if ((dt.callerPublicKey == value(eQ)))
665678 then true
666679 else throw("You are not pending manager")
667- if ((eG == eG))
668- then [StringEntry(Q(), toBase58String(value(eE))), DeleteEntry(R())]
680+ if ((eS == eS))
681+ then [StringEntry(Q(), toBase58String(value(eQ))), DeleteEntry(R())]
669682 else throw("Strict value is not equal to itself.")
670683 }
671684 else throw("Strict value is not equal to itself.")
672685 }
673686
674687
675688
676-@Callable(df)
677-func put (ck,eH) = if ((0 > ck))
689+@Callable(dt)
690+func put (cq,eT) = if ((0 > cq))
678691 then throw("Invalid slippageTolerance passed")
679692 else {
680- let dl = di(df, ck, true)
681- let cM = dl._2
682- let bR = dl._7
683- let ci = dl._9
684- let cN = dl._10
685- let cO = dl._11
686- let eI = dl._12
687- let eJ = dl._13
688- let do = invoke(aD, "emit", [cM], nil)
689- if ((do == do))
693+ let dz = dw(dt, cq, true)
694+ let cS = dz._2
695+ let bX = dz._7
696+ let co = dz._9
697+ let cT = dz._10
698+ let cU = dz._11
699+ let eU = dz._12
700+ let eV = dz._13
701+ let dC = invoke(aJ, "emit", [cS], nil)
702+ if ((dC == dC))
690703 then {
691- let dp = {
692- let dq = do
693- if ($isInstanceOf(dq, "Address"))
704+ let dD = {
705+ let dE = dC
706+ if ($isInstanceOf(dE, "Address"))
694707 then {
695- let dr = dq
696- invoke(dr, "emit", [cM], nil)
708+ let dF = dE
709+ invoke(dF, "emit", [cS], nil)
697710 }
698711 else unit
699712 }
700- if ((dp == dp))
713+ if ((dD == dD))
701714 then {
702- let eK = if ((cN > 0))
703- then invoke(ba, "put", nil, [AttachedPayment(eI, cN)])
715+ let eW = if ((cT > 0))
716+ then invoke(bg, "put", nil, [AttachedPayment(eU, cT)])
704717 else nil
705- if ((eK == eK))
718+ if ((eW == eW))
706719 then {
707- let eL = if ((cO > 0))
708- then invoke(ba, "put", nil, [AttachedPayment(eJ, cO)])
720+ let eX = if ((cU > 0))
721+ then invoke(bg, "put", nil, [AttachedPayment(eV, cU)])
709722 else nil
710- if ((eL == eL))
723+ if ((eX == eX))
711724 then {
712- let eM = if (eH)
725+ let eY = if (eT)
713726 then {
714- let eN = invoke(aZ, "stake", nil, [AttachedPayment(bR, cM)])
715- if ((eN == eN))
727+ let eZ = invoke(bf, "stake", nil, [AttachedPayment(bX, cS)])
728+ if ((eZ == eZ))
716729 then nil
717730 else throw("Strict value is not equal to itself.")
718731 }
719- else [ScriptTransfer(df.caller, cM, bR)]
720- (ci ++ eM)
732+ else [ScriptTransfer(dt.caller, cS, bX)]
733+ let fa = da(0, 0, 0)
734+ let fb = fa._1
735+ let cZ = fa._2
736+ ((co ++ eY) ++ fb)
721737 }
722738 else throw("Strict value is not equal to itself.")
723739 }
724740 else throw("Strict value is not equal to itself.")
725741 }
726742 else throw("Strict value is not equal to itself.")
727743 }
728744 else throw("Strict value is not equal to itself.")
729745 }
730746
731747
732748
733-@Callable(df)
734-func putForFree (eO) = if ((0 > eO))
749+@Callable(dt)
750+func putForFree (fc) = if ((0 > fc))
735751 then throw("Invalid value passed")
736752 else {
737- let dl = di(df, eO, false)
738- dl._9
753+ let dz = dw(dt, fc, false)
754+ let co = dz._9
755+ let fd = da(0, 0, 0)
756+ let fb = fd._1
757+ let cZ = fd._2
758+ (co ++ fb)
739759 }
740760
741761
742762
743-@Callable(df)
744-func putOneTkn (eP,eQ) = {
745- let eR = {
746- let eS = invoke(aD, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
747- if ($isInstanceOf(eS, "Boolean"))
748- then eS
749- else throw(($getType(eS) + " couldn't be cast to Boolean"))
763+@Callable(dt)
764+func putOneTkn (fe,ff) = {
765+ let fg = {
766+ let fh = invoke(aJ, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
767+ if ($isInstanceOf(fh, "Boolean"))
768+ then fh
769+ else throw(($getType(fh) + " couldn't be cast to Boolean"))
750770 }
751- let eT = if (if (if (aF())
771+ let fi = if (if (if (aL())
752772 then true
753- else (aS == l))
773+ else (aY == l))
754774 then true
755- else (aS == n))
775+ else (aY == n))
756776 then true
757- else eR
758- let ed = [if (if (!(eT))
777+ else fg
778+ let ep = [if (if (!(fi))
759779 then true
760- else ex(df))
780+ else eJ(dt))
761781 then true
762- else aB("put operation is blocked by admin"), if ((size(df.payments) == 1))
782+ else aG("put operation is blocked by admin"), if ((size(dt.payments) == 1))
763783 then true
764- else aB("exactly 1 payment are expected")]
765- if ((ed == ed))
784+ else aG("exactly 1 payment are expected")]
785+ if ((ep == ep))
766786 then {
767- let eU = df.payments[0]
768- let dw = eU.assetId
769- let dv = eU.amount
770- let X = df.caller
771- let Y = df.transactionId
772- let eV = du(dv, dw, X, Y)
773- let eW = eV._1
774- let cP = eV._2
775- let dt = eV._3
776- let eX = eV._4
777- let eY = if (if ((eP > 0))
778- then (eP > eW)
779- else false)
780- then aB(makeString(["amount to receive is less than ", toString(eP)], ""))
781- else eW
782- let do = dm(eY)
783- if ((do == do))
784- then {
785- let eM = if (eQ)
786- then {
787- let eZ = invoke(aZ, "stake", nil, [AttachedPayment(aT, eY)])
788- if ((eZ == eZ))
789- then nil
790- else throw("Strict value is not equal to itself.")
791- }
792- else [ScriptTransfer(df.caller, eY, aT)]
793- let fa = if ((dt > 0))
794- then [ScriptTransfer(aE, dt, dw)]
795- else nil
796- $Tuple2(((cP ++ eM) ++ fa), eY)
797- }
798- else throw("Strict value is not equal to itself.")
799- }
800- else throw("Strict value is not equal to itself.")
801- }
802-
803-
804-
805-@Callable(df)
806-func putOneTknREADONLY (dw,dv) = {
807- let fb = du(dv, aK(dw), unit, unit)
808- let eW = fb._1
809- let cP = fb._2
810- let dt = fb._3
811- let eX = fb._4
812- $Tuple2(nil, $Tuple3(eW, dt, eX))
813- }
814-
815-
816-
817-@Callable(df)
818-func getOneTkn (fc,eP) = {
819- let eR = {
820- let eS = invoke(aD, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
821- if ($isInstanceOf(eS, "Boolean"))
822- then eS
823- else throw(($getType(eS) + " couldn't be cast to Boolean"))
824- }
825- let fd = if (if (aF())
826- then true
827- else (aS == n))
828- then true
829- else eR
830- let ed = [if (if (!(fd))
831- then true
832- else ex(df))
833- then true
834- else aB("get operation is blocked by admin"), if ((size(df.payments) == 1))
835- then true
836- else aB("exactly 1 payment are expected")]
837- if ((ed == ed))
838- then {
839- let ec = aK(fc)
840- let eU = df.payments[0]
841- let dw = eU.assetId
842- let dK = eU.amount
843- let X = df.caller
844- let Y = df.transactionId
845- let fe = eb(ec, dK, dw, X, Y)
846- let ff = fe._1
847- let cP = fe._2
848- let dt = fe._3
849- let eX = fe._4
850- let dn = if (if ((eP > 0))
851- then (eP > ff)
852- else false)
853- then aB(makeString(["amount to receive is less than ", toString(eP)], ""))
854- else ff
855- let fg = invoke(aD, "burn", [dK], [AttachedPayment(dw, dK)])
856- if ((fg == fg))
857- then {
858- let fh = [ScriptTransfer(X, dn, ec)]
859- let fa = if ((dt > 0))
860- then [ScriptTransfer(aE, dt, ec)]
861- else nil
862- $Tuple2(((cP ++ fh) ++ fa), dn)
863- }
864- else throw("Strict value is not equal to itself.")
865- }
866- else throw("Strict value is not equal to itself.")
867- }
868-
869-
870-
871-@Callable(df)
872-func getOneTknREADONLY (ec,dK) = {
873- let fi = eb(aK(ec), dK, aT, unit, unit)
874- let ff = fi._1
875- let cP = fi._2
876- let dt = fi._3
877- let eX = fi._4
878- $Tuple2(nil, $Tuple3(ff, dt, eX))
879- }
880-
881-
882-
883-@Callable(df)
884-func unstakeAndGetOneTkn (fj,fc,eP) = {
885- let eR = {
886- let eS = invoke(aD, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
887- if ($isInstanceOf(eS, "Boolean"))
888- then eS
889- else throw(($getType(eS) + " couldn't be cast to Boolean"))
890- }
891- let fd = if (if (aF())
892- then true
893- else (aS == n))
894- then true
895- else eR
896- let ed = [if (if (!(fd))
897- then true
898- else ex(df))
899- then true
900- else aB("get operation is blocked by admin"), if ((size(df.payments) == 0))
901- then true
902- else aB("no payments are expected")]
903- if ((ed == ed))
904- then {
905- let ec = aK(fc)
906- let X = df.caller
907- let Y = df.transactionId
908- let fk = invoke(aZ, "unstake", [toBase58String(aT), fj], nil)
787+ let fj = dt.payments[0]
788+ let dK = fj.assetId
789+ let dJ = fj.amount
790+ let X = dt.caller
791+ let Y = dt.transactionId
792+ let fk = dI(dJ, dK, X, Y)
909793 if ((fk == fk))
910794 then {
911- let fl = eb(ec, fj, aT, X, Y)
912- let ff = fl._1
913- let cP = fl._2
914- let dt = fl._3
915- let eX = fl._4
916- let dn = if (if ((eP > 0))
917- then (eP > ff)
795+ let dO = fk._5
796+ let fl = fk._4
797+ let dH = fk._3
798+ let cV = fk._2
799+ let fm = fk._1
800+ let fn = if (if ((fe > 0))
801+ then (fe > fm)
918802 else false)
919- then aB(makeString(["amount to receive is less than ", toString(eP)], ""))
920- else ff
921- let fg = invoke(aD, "burn", [fj], [AttachedPayment(aT, fj)])
922- if ((fg == fg))
803+ then aG(makeString(["amount to receive is less than ", toString(fe)], ""))
804+ else fm
805+ let dC = dA(fn)
806+ if ((dC == dC))
923807 then {
924- let fh = [ScriptTransfer(df.caller, dn, ec)]
925- let fa = if ((dt > 0))
926- then [ScriptTransfer(aE, dt, ec)]
808+ let eY = if (ff)
809+ then {
810+ let fo = invoke(bf, "stake", nil, [AttachedPayment(aZ, fn)])
811+ if ((fo == fo))
812+ then nil
813+ else throw("Strict value is not equal to itself.")
814+ }
815+ else [ScriptTransfer(dt.caller, fn, aZ)]
816+ let fp = if ((dH > 0))
817+ then [ScriptTransfer(aK, dH, dK)]
927818 else nil
928- $Tuple2(((cP ++ fh) ++ fa), dn)
819+ let fq = if ((this == aK))
820+ then $Tuple2(0, 0)
821+ else if (dO)
822+ then $Tuple2(-(dH), 0)
823+ else $Tuple2(0, -(dH))
824+ let db = fq._1
825+ let dc = fq._2
826+ let fr = da(db, dc, 0)
827+ let fb = fr._1
828+ let cZ = fr._2
829+ $Tuple2((((cV ++ eY) ++ fp) ++ fb), fn)
929830 }
930831 else throw("Strict value is not equal to itself.")
931832 }
932833 else throw("Strict value is not equal to itself.")
933834 }
934835 else throw("Strict value is not equal to itself.")
935836 }
936837
937838
938839
939-@Callable(df)
940-func get () = {
941- let cA = de(df)
942- let fm = cA._1
943- let ch = cA._2
944- let dh = cA._3
945- let bP = cA._4
946- let ci = cA._5
947- let fn = invoke(aD, "burn", [dh], [AttachedPayment(bP, dh)])
948- if ((fn == fn))
949- then ci
840+@Callable(dt)
841+func putOneTknREADONLY (dK,dJ) = {
842+ let fs = dI(dJ, aQ(dK), unit, unit)
843+ let fm = fs._1
844+ let cV = fs._2
845+ let dH = fs._3
846+ let fl = fs._4
847+ let dO = fs._5
848+ $Tuple2(nil, $Tuple3(fm, dH, fl))
849+ }
850+
851+
852+
853+@Callable(dt)
854+func getOneTkn (ft,fe) = {
855+ let fg = {
856+ let fh = invoke(aJ, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
857+ if ($isInstanceOf(fh, "Boolean"))
858+ then fh
859+ else throw(($getType(fh) + " couldn't be cast to Boolean"))
860+ }
861+ let fu = if (if (aL())
862+ then true
863+ else (aY == n))
864+ then true
865+ else fg
866+ let ep = [if (if (!(fu))
867+ then true
868+ else eJ(dt))
869+ then true
870+ else aG("get operation is blocked by admin"), if ((size(dt.payments) == 1))
871+ then true
872+ else aG("exactly 1 payment are expected")]
873+ if ((ep == ep))
874+ then {
875+ let eo = aQ(ft)
876+ let fj = dt.payments[0]
877+ let dK = fj.assetId
878+ let dW = fj.amount
879+ let X = dt.caller
880+ let Y = dt.transactionId
881+ let fv = en(eo, dW, dK, X, Y)
882+ if ((fv == fv))
883+ then {
884+ let eq = fv._5
885+ let fl = fv._4
886+ let dH = fv._3
887+ let cV = fv._2
888+ let fw = fv._1
889+ let dB = if (if ((fe > 0))
890+ then (fe > fw)
891+ else false)
892+ then aG(makeString(["amount to receive is less than ", toString(fe)], ""))
893+ else fw
894+ let fx = invoke(aJ, "burn", [dW], [AttachedPayment(dK, dW)])
895+ if ((fx == fx))
896+ then {
897+ let fy = [ScriptTransfer(X, dB, eo)]
898+ let fp = if ((dH > 0))
899+ then [ScriptTransfer(aK, dH, eo)]
900+ else nil
901+ let fz = {
902+ let fA = if ((this == aK))
903+ then 0
904+ else dH
905+ if (eq)
906+ then $Tuple2(-((dB + fA)), 0)
907+ else $Tuple2(0, -((dB + fA)))
908+ }
909+ let db = fz._1
910+ let dc = fz._2
911+ let fB = da(db, dc, 0)
912+ let fb = fB._1
913+ let cZ = fB._2
914+ $Tuple2((((cV ++ fy) ++ fp) ++ fb), dB)
915+ }
916+ else throw("Strict value is not equal to itself.")
917+ }
918+ else throw("Strict value is not equal to itself.")
919+ }
950920 else throw("Strict value is not equal to itself.")
951921 }
952922
953923
954924
955-@Callable(df)
956-func getNoLess (fo,fp) = {
957- let cA = de(df)
958- let cg = cA._1
959- let ch = cA._2
960- let dh = cA._3
961- let bP = cA._4
962- let ci = cA._5
963- if ((fo > cg))
964- then throw(((("noLessThenAmtAsset failed: " + toString(cg)) + " < ") + toString(fo)))
965- else if ((fp > ch))
966- then throw(((("noLessThenPriceAsset failed: " + toString(ch)) + " < ") + toString(fp)))
967- else {
968- let fn = invoke(aD, "burn", [dh], [AttachedPayment(bP, dh)])
969- if ((fn == fn))
970- then ci
971- else throw("Strict value is not equal to itself.")
972- }
925+@Callable(dt)
926+func getOneTknREADONLY (eo,dW) = {
927+ let fC = en(aQ(eo), dW, aZ, unit, unit)
928+ let fw = fC._1
929+ let cV = fC._2
930+ let dH = fC._3
931+ let fl = fC._4
932+ let eq = fC._5
933+ $Tuple2(nil, $Tuple3(fw, dH, fl))
973934 }
974935
975936
976937
977-@Callable(df)
978-func unstakeAndGet (dn) = {
979- let fq = if ((size(df.payments) != 0))
980- then throw("No payments are expected")
981- else true
982- if ((fq == fq))
938+@Callable(dt)
939+func unstakeAndGetOneTkn (fD,ft,fe) = {
940+ let fg = {
941+ let fh = invoke(aJ, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
942+ if ($isInstanceOf(fh, "Boolean"))
943+ then fh
944+ else throw(($getType(fh) + " couldn't be cast to Boolean"))
945+ }
946+ let fu = if (if (aL())
947+ then true
948+ else (aY == n))
949+ then true
950+ else fg
951+ let ep = [if (if (!(fu))
952+ then true
953+ else eJ(dt))
954+ then true
955+ else aG("get operation is blocked by admin"), if ((size(dt.payments) == 0))
956+ then true
957+ else aG("no payments are expected")]
958+ if ((ep == ep))
983959 then {
984- let bE = aH()
985- let bR = fromBase58String(bE[q])
986- let fk = invoke(aZ, "unstake", [toBase58String(bR), dn], nil)
987- if ((fk == fk))
960+ let eo = aQ(ft)
961+ let X = dt.caller
962+ let Y = dt.transactionId
963+ let fE = invoke(bf, "unstake", [toBase58String(aZ), fD], nil)
964+ if ((fE == fE))
988965 then {
989- let cA = bN(toBase58String(df.transactionId), toBase58String(bR), dn, df.caller)
990- let bU = parseIntValue(cA._9)
991- let ci = cA._10
992- let fr = if (if (aF())
993- then true
994- else (bU == n))
995- then throw(("Get operation is blocked by admin. Status = " + toString(bU)))
996- else true
997- if ((fr == fr))
966+ let fF = en(eo, fD, aZ, X, Y)
967+ if ((fF == fF))
998968 then {
999- let fn = invoke(aD, "burn", [dn], [AttachedPayment(bR, dn)])
1000- if ((fn == fn))
1001- then ci
969+ let eq = fF._5
970+ let fl = fF._4
971+ let dH = fF._3
972+ let cV = fF._2
973+ let fw = fF._1
974+ let dB = if (if ((fe > 0))
975+ then (fe > fw)
976+ else false)
977+ then aG(makeString(["amount to receive is less than ", toString(fe)], ""))
978+ else fw
979+ let fx = invoke(aJ, "burn", [fD], [AttachedPayment(aZ, fD)])
980+ if ((fx == fx))
981+ then {
982+ let fy = [ScriptTransfer(dt.caller, dB, eo)]
983+ let fp = if ((dH > 0))
984+ then [ScriptTransfer(aK, dH, eo)]
985+ else nil
986+ let fG = {
987+ let fA = if ((this == aK))
988+ then 0
989+ else dH
990+ if (eq)
991+ then $Tuple2(-((dB + fA)), 0)
992+ else $Tuple2(0, -((dB + fA)))
993+ }
994+ let db = fG._1
995+ let dc = fG._2
996+ let fH = da(db, dc, 0)
997+ let fb = fH._1
998+ let cZ = fH._2
999+ $Tuple2((((cV ++ fy) ++ fp) ++ fb), dB)
1000+ }
10021001 else throw("Strict value is not equal to itself.")
10031002 }
10041003 else throw("Strict value is not equal to itself.")
10051004 }
10061005 else throw("Strict value is not equal to itself.")
10071006 }
10081007 else throw("Strict value is not equal to itself.")
10091008 }
10101009
10111010
10121011
1013-@Callable(df)
1014-func unstakeAndGetNoLess (fj,fs,fp) = {
1015- let fd = if (aF())
1016- then true
1017- else (aS == n)
1018- let ed = [if (!(fd))
1019- then true
1020- else throw("get operation is blocked by admin"), if ((size(df.payments) == 0))
1021- then true
1022- else throw("no payments are expected")]
1023- if ((ed == ed))
1012+@Callable(dt)
1013+func get () = {
1014+ let cG = ds(dt)
1015+ let fI = cG._1
1016+ let cn = cG._2
1017+ let dv = cG._3
1018+ let bV = cG._4
1019+ let co = cG._5
1020+ let fJ = invoke(aJ, "burn", [dv], [AttachedPayment(bV, dv)])
1021+ if ((fJ == fJ))
10241022 then {
1025- let fk = invoke(aZ, "unstake", [toBase58String(aT), fj], nil)
1026- if ((fk == fk))
1023+ let fK = da(-(fI), -(cn), 0)
1024+ let fb = fK._1
1025+ let cZ = fK._2
1026+ (co ++ fb)
1027+ }
1028+ else throw("Strict value is not equal to itself.")
1029+ }
1030+
1031+
1032+
1033+@Callable(dt)
1034+func getNoLess (fL,fM) = {
1035+ let cG = ds(dt)
1036+ let cm = cG._1
1037+ let cn = cG._2
1038+ let dv = cG._3
1039+ let bV = cG._4
1040+ let co = cG._5
1041+ if ((fL > cm))
1042+ then throw(((("noLessThenAmtAsset failed: " + toString(cm)) + " < ") + toString(fL)))
1043+ else if ((fM > cn))
1044+ then throw(((("noLessThenPriceAsset failed: " + toString(cn)) + " < ") + toString(fM)))
1045+ else {
1046+ let fJ = invoke(aJ, "burn", [dv], [AttachedPayment(bV, dv)])
1047+ if ((fJ == fJ))
1048+ then {
1049+ let fN = da(-(cm), -(cn), 0)
1050+ let fb = fN._1
1051+ let cZ = fN._2
1052+ (co ++ fb)
1053+ }
1054+ else throw("Strict value is not equal to itself.")
1055+ }
1056+ }
1057+
1058+
1059+
1060+@Callable(dt)
1061+func unstakeAndGet (dB) = {
1062+ let fO = if ((size(dt.payments) != 0))
1063+ then throw("No payments are expected")
1064+ else true
1065+ if ((fO == fO))
1066+ then {
1067+ let bK = aN()
1068+ let bX = fromBase58String(bK[q])
1069+ let fE = invoke(bf, "unstake", [toBase58String(bX), dB], nil)
1070+ if ((fE == fE))
10271071 then {
1028- let cA = bN(toBase58String(df.transactionId), toBase58String(aT), fj, df.caller)
1029- let cg = cA._1
1030- let ch = cA._2
1031- let ci = cA._10
1032- let ft = [if ((cg >= fs))
1072+ let cG = bT(toBase58String(dt.transactionId), toBase58String(bX), dB, dt.caller)
1073+ let cm = cG._1
1074+ let cn = cG._2
1075+ let ca = parseIntValue(cG._9)
1076+ let co = cG._10
1077+ let fP = if (if (aL())
10331078 then true
1034- else throw(makeString(["amount asset amount to receive is less than ", toString(fs)], "")), if ((ch >= fp))
1035- then true
1036- else throw(makeString(["price asset amount to receive is less than ", toString(fp)], ""))]
1037- if ((ft == ft))
1079+ else (ca == n))
1080+ then throw(("Get operation is blocked by admin. Status = " + toString(ca)))
1081+ else true
1082+ if ((fP == fP))
10381083 then {
1039- let fn = invoke(aD, "burn", [fj], [AttachedPayment(aT, fj)])
1040- if ((fn == fn))
1041- then ci
1084+ let fJ = invoke(aJ, "burn", [dB], [AttachedPayment(bX, dB)])
1085+ if ((fJ == fJ))
1086+ then {
1087+ let fQ = da(-(cm), -(cn), 0)
1088+ let fb = fQ._1
1089+ let cZ = fQ._2
1090+ (co ++ fb)
1091+ }
10421092 else throw("Strict value is not equal to itself.")
10431093 }
10441094 else throw("Strict value is not equal to itself.")
10451095 }
10461096 else throw("Strict value is not equal to itself.")
10471097 }
10481098 else throw("Strict value is not equal to itself.")
10491099 }
10501100
10511101
10521102
1053-@Callable(df)
1054-func activate (fu,fv) = if ((toString(df.caller) != toString(aD)))
1055- then throw("permissions denied")
1056- else $Tuple2([StringEntry(aa(), fu), StringEntry(ab(), fv)], "success")
1057-
1058-
1059-
1060-@Callable(df)
1061-func getPoolConfigWrapperREADONLY () = $Tuple2(nil, aH())
1062-
1063-
1064-
1065-@Callable(df)
1066-func getAccBalanceWrapperREADONLY (br) = $Tuple2(nil, bq(br))
1067-
1068-
1069-
1070-@Callable(df)
1071-func calcPricesWrapperREADONLY (by,bz,bD) = {
1072- let bM = bC(by, bz, bD)
1073- $Tuple2(nil, [toString(bM[0]), toString(bM[1]), toString(bM[2])])
1103+@Callable(dt)
1104+func unstakeAndGetNoLess (fD,fR,fM) = {
1105+ let fu = if (aL())
1106+ then true
1107+ else (aY == n)
1108+ let ep = [if (!(fu))
1109+ then true
1110+ else throw("get operation is blocked by admin"), if ((size(dt.payments) == 0))
1111+ then true
1112+ else throw("no payments are expected")]
1113+ if ((ep == ep))
1114+ then {
1115+ let fE = invoke(bf, "unstake", [toBase58String(aZ), fD], nil)
1116+ if ((fE == fE))
1117+ then {
1118+ let cG = bT(toBase58String(dt.transactionId), toBase58String(aZ), fD, dt.caller)
1119+ let cm = cG._1
1120+ let cn = cG._2
1121+ let co = cG._10
1122+ let fS = [if ((cm >= fR))
1123+ then true
1124+ else throw(makeString(["amount asset amount to receive is less than ", toString(fR)], "")), if ((cn >= fM))
1125+ then true
1126+ else throw(makeString(["price asset amount to receive is less than ", toString(fM)], ""))]
1127+ if ((fS == fS))
1128+ then {
1129+ let fJ = invoke(aJ, "burn", [fD], [AttachedPayment(aZ, fD)])
1130+ if ((fJ == fJ))
1131+ then {
1132+ let fT = da(-(cm), -(cn), 0)
1133+ let fb = fT._1
1134+ let cZ = fT._2
1135+ (co ++ fb)
1136+ }
1137+ else throw("Strict value is not equal to itself.")
1138+ }
1139+ else throw("Strict value is not equal to itself.")
1140+ }
1141+ else throw("Strict value is not equal to itself.")
1142+ }
1143+ else throw("Strict value is not equal to itself.")
10741144 }
10751145
10761146
10771147
1078-@Callable(df)
1148+@Callable(dt)
1149+func activate (fU,fV) = if ((toString(dt.caller) != toString(aJ)))
1150+ then throw("permissions denied")
1151+ else $Tuple2([StringEntry(aa(), fU), StringEntry(ab(), fV)], "success")
1152+
1153+
1154+
1155+@Callable(dt)
1156+func refreshKLp () = {
1157+ let fW = valueOrElse(getInteger(ag), 0)
1158+ let fX = if (((height - fW) >= aj))
1159+ then unit
1160+ else aG(makeString([toString(aj), " blocks have not passed since the previous call"], ""))
1161+ if ((fX == fX))
1162+ then {
1163+ let fY = da(0, 0, 0)
1164+ let dh = fY._1
1165+ let cZ = fY._2
1166+ $Tuple2(dh, toString(cZ))
1167+ }
1168+ else throw("Strict value is not equal to itself.")
1169+ }
1170+
1171+
1172+
1173+@Callable(dt)
1174+func getPoolConfigWrapperREADONLY () = $Tuple2(nil, aN())
1175+
1176+
1177+
1178+@Callable(dt)
1179+func getAccBalanceWrapperREADONLY (bx) = $Tuple2(nil, bw(bx))
1180+
1181+
1182+
1183+@Callable(dt)
1184+func calcPricesWrapperREADONLY (bE,bF,bJ) = {
1185+ let bS = bI(bE, bF, bJ)
1186+ $Tuple2(nil, [toString(bS[0]), toString(bS[1]), toString(bS[2])])
1187+ }
1188+
1189+
1190+
1191+@Callable(dt)
10791192 func toX18WrapperREADONLY (E,F) = $Tuple2(nil, toString(D(E, F)))
10801193
10811194
10821195
1083-@Callable(df)
1196+@Callable(dt)
10841197 func fromX18WrapperREADONLY (H,I) = $Tuple2(nil, G(parseBigIntValue(H), I))
10851198
10861199
10871200
1088-@Callable(df)
1089-func calcPriceBigIntWrapperREADONLY (bt,bu) = $Tuple2(nil, toString(bs(parseBigIntValue(bt), parseBigIntValue(bu))))
1201+@Callable(dt)
1202+func calcPriceBigIntWrapperREADONLY (bz,bA) = $Tuple2(nil, toString(by(parseBigIntValue(bz), parseBigIntValue(bA))))
10901203
10911204
10921205
1093-@Callable(df)
1094-func estimatePutOperationWrapperREADONLY (bO,ck,cl,cm,cn,co,X,cp,cq) = $Tuple2(nil, cj(bO, ck, cl, cm, cn, co, X, cp, cq))
1206+@Callable(dt)
1207+func estimatePutOperationWrapperREADONLY (bU,cq,cr,cs,ct,cu,X,cv,cw) = $Tuple2(nil, cp(bU, cq, cr, cs, ct, cu, X, cv, cw))
10951208
10961209
10971210
1098-@Callable(df)
1099-func estimateGetOperationWrapperREADONLY (bO,bP,bQ,X) = {
1100- let cA = bN(bO, bP, bQ, addressFromStringValue(X))
1101- $Tuple2(nil, $Tuple10(cA._1, cA._2, cA._3, cA._4, cA._5, cA._6, cA._7, toString(cA._8), cA._9, cA._10))
1211+@Callable(dt)
1212+func estimateGetOperationWrapperREADONLY (bU,bV,bW,X) = {
1213+ let cG = bT(bU, bV, bW, addressFromStringValue(X))
1214+ $Tuple2(nil, $Tuple10(cG._1, cG._2, cG._3, cG._4, cG._5, cG._6, cG._7, toString(cG._8), cG._9, cG._10))
11021215 }
11031216
11041217
11051218
1106-@Callable(df)
1219+@Callable(dt)
11071220 func statsREADONLY () = {
1108- let bE = aH()
1109- let bR = fromBase58String(bE[q])
1110- let cS = bE[r]
1111- let cT = bE[s]
1112- let ct = bE[v]
1113- let cu = bE[w]
1114- let bF = parseIntValue(bE[t])
1115- let bG = parseIntValue(bE[u])
1116- let fw = valueOrErrorMessage(assetInfo(bR), (("Asset " + toBase58String(bR)) + " doesn't exist")).quantity
1117- let cU = bq(cS)
1118- let cV = bq(cT)
1119- let fx = if ((fw == 0))
1221+ let bK = aN()
1222+ let bX = fromBase58String(bK[q])
1223+ let fZ = bK[r]
1224+ let ga = bK[s]
1225+ let cz = bK[v]
1226+ let cA = bK[w]
1227+ let bL = parseIntValue(bK[t])
1228+ let bM = parseIntValue(bK[u])
1229+ let gb = valueOrErrorMessage(assetInfo(bX), (("Asset " + toBase58String(bX)) + " doesn't exist")).quantity
1230+ let gc = bw(fZ)
1231+ let gd = bw(ga)
1232+ let ge = if ((gb == 0))
11201233 then [e, e, e]
1121- else bC(cU, cV, fw)
1122- let cb = 0
1123- let fy = G(fx[1], b)
1124- let fz = G(fx[2], b)
1125- let fA = value(getInteger(aD, ap(toString(this))))
1126- $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))
1234+ else bI(gc, gd, gb)
1235+ let ch = 0
1236+ let gf = G(ge[1], b)
1237+ let gg = G(ge[2], b)
1238+ let gh = value(getInteger(aJ, au(toString(this))))
1239+ $Tuple2(nil, makeString(["%d%d%d%d%d%d%d", toString(gc), toString(gd), toString(gb), toString(ch), toString(gf), toString(gg), toString(gh)], j))
11271240 }
11281241
11291242
11301243
1131-@Callable(df)
1132-func evaluatePutByAmountAssetREADONLY (cl) = {
1133- let bE = aH()
1134- let bR = fromBase58String(bE[q])
1135- let cr = bE[r]
1136- let bS = fromBase58String(cr)
1137- let cs = bE[s]
1138- let bT = fromBase58String(cs)
1139- let bF = parseIntValue(bE[t])
1140- let bG = parseIntValue(bE[u])
1141- let bU = bE[p]
1142- let fw = valueOrErrorMessage(assetInfo(bR), (("Asset " + toBase58String(bR)) + " doesn't exist")).quantity
1143- let cU = bq(cr)
1144- let cV = bq(cs)
1145- let bA = D(cU, bF)
1146- let bB = D(cV, bG)
1147- let ca = if ((fw == 0))
1244+@Callable(dt)
1245+func evaluatePutByAmountAssetREADONLY (cr) = {
1246+ let bK = aN()
1247+ let bX = fromBase58String(bK[q])
1248+ let cx = bK[r]
1249+ let bY = fromBase58String(cx)
1250+ let cy = bK[s]
1251+ let bZ = fromBase58String(cy)
1252+ let bL = parseIntValue(bK[t])
1253+ let bM = parseIntValue(bK[u])
1254+ let ca = bK[p]
1255+ let gb = valueOrErrorMessage(assetInfo(bX), (("Asset " + toBase58String(bX)) + " doesn't exist")).quantity
1256+ let gc = bw(cx)
1257+ let gd = bw(cy)
1258+ let bG = D(gc, bL)
1259+ let bH = D(gd, bM)
1260+ let cg = if ((gb == 0))
11481261 then e
1149- else bs(bB, bA)
1150- let cx = D(cl, bF)
1151- let cy = fraction(cx, ca, d)
1152- let cn = G(cy, bG)
1153- let dl = cj("", 500000, cl, bS, cn, bT, "", true, false)
1154- let cI = dl._1
1155- let fB = dl._3
1156- let bW = dl._4
1157- let bY = dl._5
1158- let bV = dl._6
1159- $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))
1262+ else by(bH, bG)
1263+ let cD = D(cr, bL)
1264+ let cE = fraction(cD, cg, d)
1265+ let ct = G(cE, bM)
1266+ let dz = cp("", 500000, cr, bY, ct, bZ, "", true, false)
1267+ let cO = dz._1
1268+ let gi = dz._3
1269+ let cc = dz._4
1270+ let ce = dz._5
1271+ let cb = dz._6
1272+ $Tuple2(nil, makeString(["%d%d%d%d%d%d%d%d", toString(cO), toString(G(cg, b)), toString(cc), toString(ce), toString(cb), ca, toString(cr), toString(ct)], j))
11601273 }
11611274
11621275
11631276
1164-@Callable(df)
1165-func evaluatePutByPriceAssetREADONLY (cn) = {
1166- let bE = aH()
1167- let bR = fromBase58String(bE[q])
1168- let cr = bE[r]
1169- let bS = fromBase58String(cr)
1170- let cs = bE[s]
1171- let bT = fromBase58String(cs)
1172- let bF = parseIntValue(bE[t])
1173- let bG = parseIntValue(bE[u])
1174- let bU = bE[p]
1175- let fw = valueOrErrorMessage(assetInfo(bR), (("Asset " + toBase58String(bR)) + " doesn't exist")).quantity
1176- let fC = bq(cr)
1177- let fD = bq(cs)
1178- let fE = D(fC, bF)
1179- let fF = D(fD, bG)
1180- let ca = if ((fw == 0))
1277+@Callable(dt)
1278+func evaluatePutByPriceAssetREADONLY (ct) = {
1279+ let bK = aN()
1280+ let bX = fromBase58String(bK[q])
1281+ let cx = bK[r]
1282+ let bY = fromBase58String(cx)
1283+ let cy = bK[s]
1284+ let bZ = fromBase58String(cy)
1285+ let bL = parseIntValue(bK[t])
1286+ let bM = parseIntValue(bK[u])
1287+ let ca = bK[p]
1288+ let gb = valueOrErrorMessage(assetInfo(bX), (("Asset " + toBase58String(bX)) + " doesn't exist")).quantity
1289+ let gj = bw(cx)
1290+ let gk = bw(cy)
1291+ let gl = D(gj, bL)
1292+ let gm = D(gk, bM)
1293+ let cg = if ((gb == 0))
11811294 then e
1182- else bs(fF, fE)
1183- let cy = D(cn, bG)
1184- let cx = fraction(cy, d, ca)
1185- let cl = G(cx, bF)
1186- let dl = cj("", 500000, cl, bS, cn, bT, "", true, false)
1187- let cI = dl._1
1188- let fB = dl._3
1189- let bW = dl._4
1190- let bY = dl._5
1191- let bV = dl._6
1192- $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))
1295+ else by(gm, gl)
1296+ let cE = D(ct, bM)
1297+ let cD = fraction(cE, d, cg)
1298+ let cr = G(cD, bL)
1299+ let dz = cp("", 500000, cr, bY, ct, bZ, "", true, false)
1300+ let cO = dz._1
1301+ let gi = dz._3
1302+ let cc = dz._4
1303+ let ce = dz._5
1304+ let cb = dz._6
1305+ $Tuple2(nil, makeString(["%d%d%d%d%d%d%d%d", toString(cO), toString(G(cg, b)), toString(cc), toString(ce), toString(cb), ca, toString(cr), toString(ct)], j))
11931306 }
11941307
11951308
11961309
1197-@Callable(df)
1198-func evaluateGetREADONLY (fG,fH) = {
1199- let cA = bN("", fG, fH, this)
1200- let cg = cA._1
1201- let ch = cA._2
1202- let bW = cA._5
1203- let bY = cA._6
1204- let bV = cA._7
1205- let cb = cA._8
1206- let bU = parseIntValue(cA._9)
1207- $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))
1310+@Callable(dt)
1311+func evaluateGetREADONLY (gn,go) = {
1312+ let cG = bT("", gn, go, this)
1313+ let cm = cG._1
1314+ let cn = cG._2
1315+ let cc = cG._5
1316+ let ce = cG._6
1317+ let cb = cG._7
1318+ let ch = cG._8
1319+ let ca = parseIntValue(cG._9)
1320+ $Tuple2(nil, makeString(["%d%d%d%d%d%d%d", toString(cm), toString(cn), toString(cc), toString(ce), toString(cb), toString(ch), toString(ca)], j))
12081321 }
12091322
12101323
1211-@Verifier(fI)
1212-func fJ () = {
1213- let fK = {
1214- let dq = eu()
1215- if ($isInstanceOf(dq, "ByteVector"))
1324+@Verifier(gp)
1325+func gq () = {
1326+ let gr = {
1327+ let dE = eG()
1328+ if ($isInstanceOf(dE, "ByteVector"))
12161329 then {
1217- let ey = dq
1218- ey
1330+ let eK = dE
1331+ eK
12191332 }
1220- else if ($isInstanceOf(dq, "Unit"))
1221- then fI.senderPublicKey
1333+ else if ($isInstanceOf(dE, "Unit"))
1334+ then gp.senderPublicKey
12221335 else throw("Match error")
12231336 }
1224- let dq = fI
1225- if ($isInstanceOf(dq, "Order"))
1337+ let dE = gp
1338+ if ($isInstanceOf(dE, "Order"))
12261339 then {
1227- let cR = dq
1228- let fL = aG()
1229- let au = cQ(cR)
1230- let av = sigVerify(cR.bodyBytes, cR.proofs[0], cR.senderPublicKey)
1231- let aw = sigVerify(cR.bodyBytes, cR.proofs[1], fL)
1232- if (if (if (au)
1233- then av
1340+ let dj = dE
1341+ let gs = aM()
1342+ let az = di(dj)
1343+ let aA = sigVerify(dj.bodyBytes, dj.proofs[0], dj.senderPublicKey)
1344+ let aB = sigVerify(dj.bodyBytes, dj.proofs[1], gs)
1345+ if (if (if (az)
1346+ then aA
12341347 else false)
1235- then aw
1348+ then aB
12361349 else false)
12371350 then true
1238- else at(au, av, aw)
1351+ else ay(az, aA, aB)
12391352 }
1240- else if ($isInstanceOf(dq, "SetScriptTransaction"))
1353+ else if ($isInstanceOf(dE, "SetScriptTransaction"))
12411354 then {
1242- let ev = dq
1243- let fM = blake2b256(value(ev.script))
1244- let fN = fromBase64String(value(getString(aD, ar())))
1245- let fO = scriptHash(this)
1246- if (if ((fN == fM))
1247- then (fO != fM)
1355+ let eH = dE
1356+ let gt = blake2b256(value(eH.script))
1357+ let gu = fromBase64String(value(getString(aJ, aw())))
1358+ let gv = scriptHash(this)
1359+ if (if ((gu == gt))
1360+ then (gv != gt)
12481361 else false)
12491362 then true
1250- else sigVerify(fI.bodyBytes, fI.proofs[0], fK)
1363+ else sigVerify(gp.bodyBytes, gp.proofs[0], gr)
12511364 }
1252- else sigVerify(fI.bodyBytes, fI.proofs[0], fK)
1365+ else sigVerify(gp.bodyBytes, gp.proofs[0], gr)
12531366 }
12541367

github/deemru/w8io/026f985 
334.38 ms