tx · GHWTSgQfkViaSKDsv6fmsVCz5XZc2CW1a7S3ZdkAvCnV

3MzKSdTH2jFbypLsoNfrH7QgkzSbx3EYwCA:  -0.04000000 Waves

2023.02.09 22:45 [2442518] smart account 3MzKSdTH2jFbypLsoNfrH7QgkzSbx3EYwCA > SELF 0.00000000 Waves

{ "type": 13, "id": "GHWTSgQfkViaSKDsv6fmsVCz5XZc2CW1a7S3ZdkAvCnV", "fee": 4000000, "feeAssetId": null, "timestamp": 1675971962930, "version": 2, "chainId": 84, "sender": "3MzKSdTH2jFbypLsoNfrH7QgkzSbx3EYwCA", "senderPublicKey": "35yd3qw1gxKDxKwGAykHN9fANbXNWwseaUwbWDj24o3x", "proofs": [ "iK86Xy1ttaJLKwAxGGsWcoiCTurvMbVmfAAmtyhiDbuVT3g7zvZrQjvz678w4QV47o1ZWmTTe7AqHjQECM4qdoZ" ], "script": "base64:BgLYKggCEgQKAgEEEgYKBAEEAQgSAwoBCBIDCgEIEgASBAoCAQQSBAoCAQQSAwoBARIAEgQKAggBEgASBAoCCAESBAoCCAESBAoCAQESAwoBARIFCgMBAQESBQoDAQgBEgQKAgEIEgQKAgEIEgQKAggIEgQKAggIEgQKAggBEgASAwoBCBIFCgMBAQESBAoCCAESBAoCAQESBAoCCAgSCwoJCAEBAgECCAQEEgYKBAgIAQgiBnNjYWxlOCIMc2NhbGU4QmlnSW50IgdzY2FsZTE4Igp6ZXJvQmlnSW50IgRiaWcwIgRiaWcxIgRiaWcyIgRiaWczIgRiaWc0IgpzbGlwcGFnZTREIgt3YXZlc1N0cmluZyIFQW11bHQiBURjb252IgNTRVAiBUVNUFRZIgpQb29sQWN0aXZlIgpQb29sUHV0RGlzIg5Qb29sTWF0Y2hlckRpcyIMUG9vbFNodXRkb3duIg5pZHhQb29sQWRkcmVzcyIJaWR4UG9vbFN0IglpZHhMUEFzSWQiCWlkeEFtQXNJZCIJaWR4UHJBc0lkIgtpZHhBbXRBc0RjbSINaWR4UHJpY2VBc0RjbSILaWR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wMDBQJhRgUCYUgHBQJhSQcGCQECYUUEBQJhRgUCYUcFAmFIBQJhSQMJAAECBQJnbAIUU2V0U2NyaXB0VHJhbnNhY3Rpb24EAmNDBQJnbAMJAPQDAwgFAmlnCWJvZHlCeXRlcwkAkQMCCAUCaWcGcHJvb2ZzAAAFAmlpBgQCaWwJAPYDAQkBBXZhbHVlAQgFAmNDBnNjcmlwdAQCaW0JANsEAQkBBXZhbHVlAQkAnQgCBQJhUQkBAmFDAAQCaW4JAPEHAQUEdGhpcwMJAAACBQJpbQUCaWwJAQIhPQIFAmluBQJpbAcJAPQDAwgFAmlnCWJvZHlCeXRlcwkAkQMCCAUCaWcGcHJvb2ZzAAAFAmlpODxC4g==", "height": 2442518, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 3eEDc483vUdNc5m5mohEr17UZNGSdaynnSA9CP2Acz6m Next: CzrRPXjVjZRQefAWrVmL37Ru2BN1b28teQJu3QCLoNbX Diff:
OldNewDifferences
2323
2424 let k = "WAVES"
2525
26-let l = 1
26+let l = "100"
2727
28-let m = "100"
28+let m = "1"
2929
30-let n = "1"
30+let n = "__"
3131
32-let o = "__"
32+let o = ""
3333
34-let p = ""
34+let p = 1
3535
36-let q = 1
36+let q = 2
3737
38-let r = 2
38+let r = 3
3939
40-let s = 3
40+let s = 4
4141
42-let t = 4
42+let t = 1
4343
44-let u = 1
44+let u = 2
4545
46-let v = 2
46+let v = 3
4747
48-let w = 3
48+let w = 4
4949
50-let x = 4
50+let x = 5
5151
52-let y = 5
52+let y = 6
5353
54-let z = 6
54+let z = 7
5555
56-let A = 7
56+let A = 8
5757
58-let B = 8
58+let B = 9
5959
60-let C = 9
60+let C = 1
6161
62-let D = 1
62+let D = 6
6363
64-let E = 6
64+let E = 7
6565
66-let F = 7
66+let F = 10
6767
68-let G = 10
68+let G = fraction(10, a, 10000)
6969
70-let H = fraction(10, a, 10000)
71-
72-func I (J,K) = fraction(toBigInt(J), c, toBigInt(K))
70+func H (I,J) = fraction(toBigInt(I), c, toBigInt(J))
7371
7472
75-func L (J,K) = fraction(J, c, K)
73+func K (I,J) = fraction(I, c, J)
7674
7775
78-func M (N,O) = toInt(fraction(N, toBigInt(O), c))
76+func L (M,N) = toInt(fraction(M, toBigInt(N), c))
7977
8078
81-func P (N,O,Q) = toInt(fraction(N, toBigInt(O), c, Q))
79+func O (M,N,P) = toInt(fraction(M, toBigInt(N), c, P))
8280
8381
84-func R (J,K) = fraction(J, c, toBigInt(K))
82+func Q (I,J) = fraction(I, c, toBigInt(J))
8583
8684
87-func S (N,O) = fraction(N, toBigInt(O), c)
85+func R (M,N) = fraction(M, toBigInt(N), c)
8886
8987
90-func T (U,V,W) = fraction(U, V, W)
88+func S (T,U,V) = fraction(T, U, V)
9189
9290
93-func X (N) = if ((d > N))
94- then -(N)
95- else N
91+func W (M) = if ((d > M))
92+ then -(M)
93+ else M
9694
9795
98-func Y (N) = if ((d > N))
99- then -(N)
100- else N
96+func X (M) = if ((d > M))
97+ then -(M)
98+ else M
10199
102100
103-func Z () = "%s__factoryContract"
101+func Y () = "%s__factoryContract"
104102
105103
106-func aa () = "%s__managerPublicKey"
104+func Z () = "%s__managerPublicKey"
107105
108106
109-func ab () = "%s__pendingManagerPublicKey"
107+func aa () = "%s__pendingManagerPublicKey"
110108
111109
112-func ac () = "%s%s__price__last"
110+func ab () = "%s%s__price__last"
113111
114112
115-func ad (ae,af) = makeString(["%s%s%d%d__price__history", toString(ae), toString(af)], o)
113+func ac (ad,ae) = makeString(["%s%s%d%d__price__history", toString(ad), toString(ae)], n)
116114
117115
118-func ag (ah,ai) = ((("%s%s%s__P__" + ah) + "__") + ai)
116+func af (ag,ah) = ((("%s%s%s__P__" + ag) + "__") + ah)
119117
120118
121-func aj (ah,ai) = ((("%s%s%s__G__" + ah) + "__") + ai)
119+func ai (ag,ah) = ((("%s%s%s__G__" + ag) + "__") + ah)
122120
123121
124-func ak () = "%s__amountAsset"
122+func aj () = "%s__amountAsset"
125123
126124
127-func al () = "%s__priceAsset"
125+func ak () = "%s__priceAsset"
128126
129127
130-func am () = "%s__amp"
128+func al () = "%s__amp"
131129
132130
133-func an () = "%s__addonAddr"
131+func am () = "%s__addonAddr"
134132
135133
136-let ao = "%s__fee"
134+let an = "%s__fee"
137135
138-let ap = valueOrElse(getInteger(this, ao), H)
136+let ao = valueOrElse(getInteger(this, an), G)
139137
140-let aq = makeString(["%s", "dLp"], o)
138+let ap = makeString(["%s", "dLp"], n)
141139
142-let ar = makeString(["%s", "dLpRefreshedHeight"], o)
140+let aq = makeString(["%s", "dLpRefreshedHeight"], n)
143141
144-let as = makeString(["%s", "refreshDLpDelay"], o)
142+let ar = makeString(["%s", "refreshDLpDelay"], n)
145143
146-let at = 30
144+let as = 30
147145
148-let au = valueOrElse(getInteger(this, as), at)
146+let at = valueOrElse(getInteger(this, ar), as)
149147
150-func av () = "%s__factoryConfig"
148+func au () = "%s__factoryConfig"
151149
152150
153-func aw () = "%s%s__matcher__publicKey"
151+func av () = "%s%s__matcher__publicKey"
154152
155153
156-func ax (ay,az) = (((("%d%d%s__" + ay) + "__") + az) + "__config")
154+func aw (ax,ay) = (((("%d%d%s__" + ax) + "__") + ay) + "__config")
157155
158156
159-func aA (aB) = ("%s%s%s__mappings__baseAsset2internalId__" + aB)
157+func az (aA) = ("%s%s%s__mappings__baseAsset2internalId__" + aA)
160158
161159
162-func aC () = "%s__shutdown"
160+func aB () = "%s__shutdown"
163161
164162
165-func aD () = "%s__allowedLpStableScriptHash"
163+func aC () = "%s__allowedLpStableScriptHash"
166164
167165
168-func aE () = "%s__feeCollectorAddress"
166+func aD () = "%s__feeCollectorAddress"
169167
170168
171-func aF (aG,aH,aI,aJ) = throw((((((((("order validation failed: orderValid=" + toString(aG)) + " (") + aH) + ")") + " senderValid=") + toString(aI)) + " matcherValid=") + toString(aJ)))
169+func aE (aF,aG,aH,aI) = throw((((((((("order validation failed: orderValid=" + toString(aF)) + " (") + aG) + ")") + " senderValid=") + toString(aH)) + " matcherValid=") + toString(aI)))
172170
173171
174-func aK (aL,aM) = valueOrErrorMessage(getString(aL, aM), makeString(["mandatory ", toString(aL), ".", aM, " not defined"], ""))
172+func aJ (aK,aL) = valueOrErrorMessage(getString(aK, aL), makeString(["mandatory ", toString(aK), ".", aL, " not defined"], ""))
175173
176174
177-func aN (aL,aM) = valueOrErrorMessage(getInteger(aL, aM), makeString(["mandatory ", toString(aL), ".", aM, " not defined"], ""))
175+func aM (aK,aL) = valueOrErrorMessage(getInteger(aK, aL), makeString(["mandatory ", toString(aK), ".", aL, " not defined"], ""))
178176
179177
180-func aO (aP) = throw(makeString(["lp_stable.ride:", aP], " "))
178+func aN (aO) = throw(makeString(["lp_stable.ride:", aO], " "))
181179
182180
183-func aQ (aP) = makeString(["lp_stable.ride:", aP], " ")
181+func aP (aO) = makeString(["lp_stable.ride:", aO], " ")
184182
185183
186-let aR = addressFromStringValue(aK(this, Z()))
184+let aQ = addressFromStringValue(aJ(this, Y()))
187185
188-let aS = {
189- let aT = invoke(aR, "getInFeeREADONLY", [toString(this)], nil)
190- if ($isInstanceOf(aT, "Int"))
191- then aT
192- else throw(($getType(aT) + " couldn't be cast to Int"))
186+let aR = {
187+ let aS = invoke(aQ, "getInFeeREADONLY", [toString(this)], nil)
188+ if ($isInstanceOf(aS, "Int"))
189+ then aS
190+ else throw(($getType(aS) + " couldn't be cast to Int"))
193191 }
194192
195-let aU = {
196- let aT = invoke(aR, "getOutFeeREADONLY", [toString(this)], nil)
197- if ($isInstanceOf(aT, "Int"))
198- then aT
199- else throw(($getType(aT) + " couldn't be cast to Int"))
193+let aT = {
194+ let aS = invoke(aQ, "getOutFeeREADONLY", [toString(this)], nil)
195+ if ($isInstanceOf(aS, "Int"))
196+ then aS
197+ else throw(($getType(aS) + " couldn't be cast to Int"))
200198 }
201199
202-let aV = aK(this, am())
200+let aU = aJ(this, al())
203201
204-func aW () = valueOrElse(getBoolean(aR, aC()), false)
202+func aV () = valueOrElse(getBoolean(aQ, aB()), false)
205203
206204
207-func aX () = fromBase58String(aK(aR, aw()))
205+func aW () = fromBase58String(aJ(aQ, av()))
208206
209207
210-let aY = addressFromStringValue(aK(aR, aE()))
208+let aX = addressFromStringValue(aJ(aQ, aD()))
211209
212-func aZ () = {
213- let ba = aK(this, ak())
214- let bb = aK(this, al())
215- let bc = aN(aR, aA(bb))
216- let ay = aN(aR, aA(ba))
217- split(aK(aR, ax(toString(ay), toString(bc))), o)
210+func aY () = {
211+ let aZ = aJ(this, aj())
212+ let ba = aJ(this, ak())
213+ let bb = aM(aQ, az(ba))
214+ let ax = aM(aQ, az(aZ))
215+ split(aJ(aQ, aw(toString(ax), toString(bb))), n)
218216 }
219217
220218
221-func bd (be) = if ((be == k))
219+func bc (bd) = if ((bd == k))
222220 then unit
223- else fromBase58String(be)
221+ else fromBase58String(bd)
224222
225223
226-func bf (be) = if ((be == unit))
224+func be (bd) = if ((bd == unit))
227225 then k
228- else toBase58String(value(be))
226+ else toBase58String(value(bd))
229227
230228
231-func bg (bh) = $Tuple9(addressFromStringValue(bh[u]), parseIntValue(bh[v]), fromBase58String(bh[w]), bd(bh[x]), bd(bh[y]), parseIntValue(bh[z]), parseIntValue(bh[A]), fromBase58String(bh[B]), fromBase58String(bh[C]))
229+func bf (bg) = $Tuple9(addressFromStringValue(bg[t]), parseIntValue(bg[u]), fromBase58String(bg[v]), bc(bg[w]), bc(bg[x]), parseIntValue(bg[y]), parseIntValue(bg[z]), fromBase58String(bg[A]), fromBase58String(bg[B]))
232230
233231
234-let bi = bg(aZ())
232+let bh = bf(aY())
235233
236-let bj = bi
234+let bi = bh
237235
238-let bk = bj._1
236+let bj = bi._1
239237
240-let bl = bj._2
238+let bk = bi._2
241239
242-let bm = bj._3
240+let bl = bi._3
243241
244-let bn = bj._4
242+let bm = bi._4
245243
246-let bo = bj._5
244+let bn = bi._5
247245
248-let bp = bj._6
246+let bo = bi._6
249247
250-let bq = bj._7
248+let bp = bi._7
251249
252-let br = bj._8
250+let bq = bi._8
253251
254-let bs = bj._9
252+let br = bi._9
255253
256-func bt () = split(aK(aR, av()), o)
254+func bs () = split(aJ(aQ, au()), n)
257255
258256
259-let bu = bt()
257+let bt = bs()
260258
261-let bv = valueOrErrorMessage(addressFromString(bu[D]), "Invalid staking contract address")
259+let bu = valueOrErrorMessage(addressFromString(bt[C]), "Invalid staking contract address")
262260
263-let bw = valueOrErrorMessage(addressFromString(bu[F]), "Invalid slipage contract address")
261+let bv = valueOrErrorMessage(addressFromString(bt[E]), "Invalid slipage contract address")
264262
265-let bx = valueOrErrorMessage(addressFromString(bu[G]), "Invalid gwx contract address")
263+let bw = valueOrErrorMessage(addressFromString(bt[F]), "Invalid gwx contract address")
266264
267-let by = valueOrErrorMessage(addressFromString(bu[E]), "Invalid gwx contract address")
265+let bx = valueOrErrorMessage(addressFromString(bt[D]), "Invalid gwx contract address")
268266
269-func bz (bA,bB,bC,bD,bE,bF,bG,bH,bI,bJ) = makeString(["%d%d%d%d%d%d%d%d%d%d", toString(bA), toString(bB), toString(bC), toString(bD), toString(bE), toString(bF), toString(bG), toString(bH), toString(bI), toString(bJ)], o)
267+func by (bz,bA,bB,bC,bD,bE,bF,bG,bH,bI) = makeString(["%d%d%d%d%d%d%d%d%d%d", toString(bz), toString(bA), toString(bB), toString(bC), toString(bD), toString(bE), toString(bF), toString(bG), toString(bH), toString(bI)], n)
270268
271269
272-func bK (bL,bM,bN,bD,bG,bH) = makeString(["%d%d%d%d%d%d", toString(bL), toString(bM), toString(bN), toString(bD), toString(bG), toString(bH)], o)
270+func bJ (bK,bL,bM,bC,bF,bG) = makeString(["%d%d%d%d%d%d", toString(bK), toString(bL), toString(bM), toString(bC), toString(bF), toString(bG)], n)
273271
274272
275-func bO (bP) = if ((bP == "WAVES"))
273+func bN (bO) = if ((bO == "WAVES"))
276274 then wavesBalance(this).available
277- else assetBalance(this, fromBase58String(bP))
275+ else assetBalance(this, fromBase58String(bO))
278276
279277
280-func bQ (bR,bS) = fraction(bR, c, bS)
278+func bP (bQ,bR) = fraction(bQ, c, bR)
281279
282280
283-func bT (bR,bS,Q) = fraction(bR, c, bS, Q)
281+func bS (bQ,bR,P) = fraction(bQ, c, bR, P)
284282
285283
286-func bU (bV,bW,bX) = {
287- let bY = fraction((bV - bW), b, bW)
288- let bZ = ((bX - X(bY)) > d)
289- if (!(bZ))
290- then throw(("Big slpg: " + toString(bY)))
291- else $Tuple2(bZ, min([bV, bW]))
284+func bT (bU,bV,bW) = {
285+ let bX = fraction((bU - bV), b, bV)
286+ let bY = ((bW - W(bX)) > d)
287+ if (!(bY))
288+ then throw(("Big slpg: " + toString(bX)))
289+ else $Tuple2(bY, min([bU, bV]))
292290 }
293291
294292
295-func ca (cb,cc,cd) = {
296- let bY = fraction(cc, b, cb)
297- let ce = (cd > bY)
298- if (if (ce)
293+func bZ (ca,cb,cc) = {
294+ let bX = fraction(cb, b, ca)
295+ let cd = (cc > bX)
296+ if (if (cd)
299297 then true
300- else (cc > cb))
301- then throw(((((((toString(cc) + " ") + toString(cb)) + " ") + toString(bY)) + " ") + toString(cd)))
302- else ce
298+ else (cb > ca))
299+ then throw(((((((toString(cb) + " ") + toString(ca)) + " ") + toString(bX)) + " ") + toString(cc)))
300+ else cd
303301 }
304302
305303
306-func cf (cg,ch,ci,cj) = {
307- let ck = I(ci, cg)
308- let cl = I(cj, ch)
309- bQ(cl, ck)
304+func ce (cf,cg,ch,ci) = {
305+ let cj = H(ch, cf)
306+ let ck = H(ci, cg)
307+ bP(ck, cj)
310308 }
311309
312310
313-func cm (ci,cj,cn) = {
311+func cl (ch,ci,cm) = {
312+ let cn = bo
314313 let co = bp
315- let cp = bq
316- let cq = cf(co, cp, ci, cj)
317- let bS = I(ci, co)
318- let bR = I(cj, cp)
319- let cr = I(cn, a)
320- let cs = bQ(bS, cr)
321- let ct = bQ(bR, cr)
322-[cq, cs, ct]
314+ let cp = ce(cn, co, ch, ci)
315+ let bR = H(ch, cn)
316+ let bQ = H(ci, co)
317+ let cq = H(cm, a)
318+ let cr = bP(bR, cq)
319+ let cs = bP(bQ, cq)
320+[cp, cr, cs]
323321 }
324322
325323
326-func cu (ci,cj,cn) = {
327- let cv = cm(ci, cj, cn)
328-[M(cv[0], a), M(cv[1], a), M(cv[2], a)]
324+func ct (ch,ci,cm) = {
325+ let cu = cl(ch, ci, cm)
326+[L(cu[0], a), L(cu[1], a), L(cu[2], a)]
329327 }
330328
331329
332-func cw (cx,ap) = {
333- let cy = if ((ap == 0))
330+func cv (cw,ao) = {
331+ let cx = if ((ao == 0))
334332 then 0
335- else fraction(cx, ap, a)
336- $Tuple2((cx - cy), cy)
333+ else fraction(cw, ao, a)
334+ $Tuple2((cw - cx), cx)
337335 }
338336
339337
340-func cz (cA) = {
341- let cB = cA[0]
342- let cC = cA[1]
343- let cD = (cB + cC)
344- if ((cD == e))
338+func cy (cz) = {
339+ let cA = cz[0]
340+ let cB = cz[1]
341+ let cC = (cA + cB)
342+ if ((cC == e))
345343 then e
346344 else {
347- let cE = parseIntValue(aV)
348- let cF = (cE * 2)
349- let cv = fraction(cB, cC, f)
350- let cG = fraction(cv, i, f)
351- let cH = fraction(toBigInt(cF), cD, f)
352- let cI = toBigInt((cF - 1))
353- func cJ (cK) = {
354- let cL = fraction(cK, cK, f)
355- let cM = fraction(cL, cK, f)
356- let cN = fraction(cM, f, cG)
357- fraction((cH + fraction(cN, g, f)), cK, (fraction(cI, cK, f) + fraction(h, cN, f)))
345+ let cD = parseIntValue(aU)
346+ let cE = (cD * 2)
347+ let cu = fraction(cA, cB, f)
348+ let cF = fraction(cu, i, f)
349+ let cG = fraction(toBigInt(cE), cC, f)
350+ let cH = toBigInt((cE - 1))
351+ func cI (cJ) = {
352+ let cK = fraction(cJ, cJ, f)
353+ let cL = fraction(cK, cJ, f)
354+ let cM = fraction(cL, f, cF)
355+ fraction((cG + fraction(cM, g, f)), cJ, (fraction(cH, cJ, f) + fraction(h, cM, f)))
358356 }
359357
360- func cO (cP,cQ) = if (cP._2)
361- then cP
358+ func cN (cO,cP) = if (cO._2)
359+ then cO
362360 else {
363- let cK = cP._1
364- let cR = cJ(cK)
365- let cS = (cR - value(cK))
366- let cT = if ((e > cS))
367- then -(cS)
368- else cS
369- if ((f >= cT))
370- then $Tuple2(cR, true)
371- else $Tuple2(cR, false)
361+ let cJ = cO._1
362+ let cQ = cI(cJ)
363+ let cR = (cQ - value(cJ))
364+ let cS = if ((e > cR))
365+ then -(cR)
366+ else cR
367+ if ((f >= cS))
368+ then $Tuple2(cQ, true)
369+ else $Tuple2(cQ, false)
372370 }
373371
374- let cU = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14]
375- let cV = {
376- let cW = cU
377- let cX = size(cW)
378- let cY = $Tuple2(cD, false)
379- func cZ (da,db) = if ((db >= cX))
380- then da
381- else cO(da, cW[db])
372+ let cT = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14]
373+ let cU = {
374+ let cV = cT
375+ let cW = size(cV)
376+ let cX = $Tuple2(cC, false)
377+ func cY (cZ,da) = if ((da >= cW))
378+ then cZ
379+ else cN(cZ, cV[da])
382380
383- func dc (da,db) = if ((db >= cX))
384- then da
381+ func db (cZ,da) = if ((da >= cW))
382+ then cZ
385383 else throw("List size exceeds 15")
386384
387- dc(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cY, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15)
385+ db(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cX, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15)
388386 }
389- let cK = cV._1
390- let dd = cV._2
391- if (dd)
392- then cK
393- else throw(("D calculation error, D = " + toString(cK)))
387+ let cJ = cU._1
388+ let dc = cU._2
389+ if (dc)
390+ then cJ
391+ else throw(("D calculation error, D = " + toString(cJ)))
394392 }
395393 }
396394
397395
398-func de (df,dg,dh,di) = {
399- let dj = bm
396+func dd (de,df,dg,dh) = {
397+ let di = bl
398+ let dj = toBase58String(value(bm))
400399 let dk = toBase58String(value(bn))
401- let dl = toBase58String(value(bo))
400+ let dl = bo
402401 let dm = bp
403- let dn = bq
404- let do = toString(bl)
405- let dp = valueOrErrorMessage(assetInfo(dj), "Wrong LP id").quantity
406- if ((toBase58String(dj) != dg))
402+ let dn = toString(bk)
403+ let do = valueOrErrorMessage(assetInfo(di), "Wrong LP id").quantity
404+ if ((toBase58String(di) != df))
407405 then throw("Wrong pmt asset")
408406 else {
409- let dq = bO(dk)
410- let dr = I(dq, dm)
411- let ds = bO(dl)
412- let dt = I(ds, dn)
413- let du = bQ(dt, dr)
414- let dv = M(du, a)
415- let dw = I(dh, a)
416- let dx = I(dp, a)
417- let dy = fraction(dr, dw, dx)
418- let dz = fraction(dt, dw, dx)
419- let dA = P(dy, dm, FLOOR)
420- let dB = P(dz, dn, FLOOR)
421- let dC = if ((df == ""))
407+ let dp = bN(dj)
408+ let dq = H(dp, dl)
409+ let dr = bN(dk)
410+ let ds = H(dr, dm)
411+ let dt = bP(ds, dq)
412+ let du = L(dt, a)
413+ let dv = H(dg, a)
414+ let dw = H(do, a)
415+ let dx = fraction(dq, dv, dw)
416+ let dy = fraction(ds, dv, dw)
417+ let dz = O(dx, dl, FLOOR)
418+ let dA = O(dy, dm, FLOOR)
419+ let dB = if ((de == ""))
422420 then nil
423- else [ScriptTransfer(di, dA, if ((dk == "WAVES"))
421+ else [ScriptTransfer(dh, dz, if ((dj == "WAVES"))
424422 then unit
425- else fromBase58String(dk)), ScriptTransfer(di, dB, if ((dl == "WAVES"))
423+ else fromBase58String(dj)), ScriptTransfer(dh, dA, if ((dk == "WAVES"))
426424 then unit
427- else fromBase58String(dl)), StringEntry(aj(toString(di), df), bK(dA, dB, dh, dv, height, lastBlock.timestamp)), IntegerEntry(ac(), dv), IntegerEntry(ad(height, lastBlock.timestamp), dv)]
428- $Tuple10(dA, dB, dk, dl, dq, ds, dp, du, do, dC)
425+ else fromBase58String(dk)), StringEntry(ai(toString(dh), de), bJ(dz, dA, dg, du, height, lastBlock.timestamp)), IntegerEntry(ab(), du), IntegerEntry(ac(height, lastBlock.timestamp), du)]
426+ $Tuple10(dz, dA, dj, dk, dp, dr, do, dt, dn, dB)
429427 }
430428 }
431429
432430
433-func dD (df,bX,dE,dF,dG,dH,di,dI,dJ,dK,dL,dM,dN) = {
434- let dj = bm
431+func dC (de,bW,dD,dE,dF,dG,dh,dH,dI,dJ,dK,dL,dM) = {
432+ let di = bl
433+ let dN = toBase58String(value(bm))
435434 let dO = toBase58String(value(bn))
436- let dP = toBase58String(value(bo))
435+ let dP = bq
437436 let dQ = br
438- let dR = bs
437+ let dR = bo
439438 let dS = bp
440- let dT = bq
441- let do = toString(bl)
442- let dU = valueOrErrorMessage(assetInfo(dj), "Wr lp as").quantity
443- let dq = if (dI)
444- then bO(dO)
445- else if (if (dK)
446- then (dN == dO)
439+ let dn = toString(bk)
440+ let dT = valueOrErrorMessage(assetInfo(di), "Wr lp as").quantity
441+ let dp = if (dH)
442+ then bN(dN)
443+ else if (if (dJ)
444+ then (dM == dN)
447445 else false)
448- then (bO(dO) - dM)
449- else if (dK)
450- then bO(dO)
451- else (bO(dO) - dE)
452- let ds = if (dI)
453- then bO(dP)
454- else if (if (dK)
455- then (dN == dP)
446+ then (bN(dN) - dL)
447+ else if (dJ)
448+ then bN(dN)
449+ else (bN(dN) - dD)
450+ let dr = if (dH)
451+ then bN(dO)
452+ else if (if (dJ)
453+ then (dM == dO)
456454 else false)
457- then (bO(dP) - dM)
458- else if (dK)
459- then bO(dP)
460- else (bO(dP) - dG)
461- let dV = I(dE, dS)
462- let dW = I(dG, dT)
463- let dX = bQ(dW, dV)
464- let dr = I(dq, dS)
465- let dt = I(ds, dT)
466- let cc = cz([dr, dt])
467- let dY = if ((dU == 0))
455+ then (bN(dO) - dL)
456+ else if (dJ)
457+ then bN(dO)
458+ else (bN(dO) - dF)
459+ let dU = H(dD, dR)
460+ let dV = H(dF, dS)
461+ let dW = bP(dV, dU)
462+ let dq = H(dp, dR)
463+ let ds = H(dr, dS)
464+ let cb = cy([dq, ds])
465+ let dX = if ((dT == 0))
468466 then {
469- let cb = cz([(dr + dV), (dt + dW)])
470- let dZ = if ((cb > cc))
467+ let ca = cy([(dq + dU), (ds + dV)])
468+ let dY = if ((ca > cb))
471469 then true
472470 else throw("D1 should be greater than D0")
473- if ((dZ == dZ))
471+ if ((dY == dY))
474472 then {
475- let du = d
476- let ea = d
477- let cr = cb
478- $Tuple5(M(cr, a), M(dV, dS), M(dW, dT), bQ((dt + dW), (dr + dV)), ea)
473+ let dt = d
474+ let dZ = d
475+ let cq = ca
476+ $Tuple5(L(cq, a), L(dU, dR), L(dV, dS), bP((ds + dV), (dq + dU)), dZ)
479477 }
480478 else throw("Strict value is not equal to itself.")
481479 }
482480 else {
483- let du = bQ(dt, dr)
484- let eb = fraction(X((du - dX)), c, du)
485- let ea = I(bX, a)
486- if (if (if (dL)
487- then (du != d)
481+ let dt = bP(ds, dq)
482+ let ea = fraction(W((dt - dW)), c, dt)
483+ let dZ = H(bW, a)
484+ if (if (if (dK)
485+ then (dt != d)
488486 else false)
489- then (eb > ea)
487+ then (ea > dZ)
490488 else false)
491- then throw(((("Price slippage " + toString(eb)) + " > ") + toString(ea)))
489+ then throw(((("Price slippage " + toString(ea)) + " > ") + toString(dZ)))
492490 else {
493- let ec = I(dU, a)
494- let ed = fraction(dV, bT(dt, dr, CEILING), c, CEILING)
495- let ee = fraction(dW, c, bT(dt, dr, FLOOR), CEILING)
496- let ef = if ((ed > dW))
497- then $Tuple2(ee, dW)
498- else $Tuple2(dV, ed)
499- let eg = ef._1
500- let eh = ef._2
501- let cb = cz([(dr + eg), (dt + eh)])
502- let dZ = if ((cb > cc))
491+ let eb = H(dT, a)
492+ let ec = fraction(dU, bS(ds, dq, CEILING), c, CEILING)
493+ let ed = fraction(dV, c, bS(ds, dq, FLOOR), CEILING)
494+ let ee = if ((ec > dV))
495+ then $Tuple2(ed, dV)
496+ else $Tuple2(dU, ec)
497+ let ef = ee._1
498+ let eg = ee._2
499+ let ca = cy([(dq + ef), (ds + eg)])
500+ let dY = if ((ca > cb))
503501 then true
504502 else throw("D1 should be greater than D0")
505- if ((dZ == dZ))
503+ if ((dY == dY))
506504 then {
507- let cr = fraction(ec, (cb - cc), cc)
508- $Tuple5(P(cr, a, FLOOR), P(eg, dS, CEILING), P(eh, dT, CEILING), du, ea)
505+ let cq = fraction(eb, (ca - cb), cb)
506+ $Tuple5(O(cq, a, FLOOR), O(ef, dR, CEILING), O(eg, dS, CEILING), dt, dZ)
509507 }
510508 else throw("Strict value is not equal to itself.")
511509 }
512510 }
513- let ei = dY._1
514- let ej = dY._2
515- let ek = dY._3
516- let dv = M(dY._4, a)
517- let el = M(dY._5, a)
518- if ((0 >= ei))
511+ let eh = dX._1
512+ let ei = dX._2
513+ let ej = dX._3
514+ let du = L(dX._4, a)
515+ let ek = L(dX._5, a)
516+ if ((0 >= eh))
519517 then throw("LP <= 0")
520518 else {
521- let em = if (!(dJ))
519+ let el = if (!(dI))
522520 then 0
523- else ei
524- let en = (dE - ej)
525- let eo = (dG - ek)
526- let ep = if (if (dK)
527- then (dN == dO)
521+ else eh
522+ let em = (dD - ei)
523+ let en = (dF - ej)
524+ let eo = if (if (dJ)
525+ then (dM == dN)
528526 else false)
529- then $Tuple2(dM, 0)
530- else if (if (dK)
531- then (dN == dP)
527+ then $Tuple2(dL, 0)
528+ else if (if (dJ)
529+ then (dM == dO)
532530 else false)
533- then $Tuple2(0, dM)
534- else $Tuple2(ej, ek)
535- let eq = ep._1
536- let er = ep._2
537- let es = [IntegerEntry(ac(), dv), IntegerEntry(ad(height, lastBlock.timestamp), dv), StringEntry(ag(di, df), bz(eq, er, em, dv, bX, el, height, lastBlock.timestamp, en, eo))]
538- $Tuple13(ei, em, dv, dq, ds, dU, dj, do, es, en, eo, dF, dH)
531+ then $Tuple2(0, dL)
532+ else $Tuple2(ei, ej)
533+ let ep = eo._1
534+ let eq = eo._2
535+ let er = [IntegerEntry(ab(), du), IntegerEntry(ac(height, lastBlock.timestamp), du), StringEntry(af(dh, de), by(ep, eq, el, du, bW, ek, height, lastBlock.timestamp, em, en))]
536+ $Tuple13(eh, el, du, dp, dr, dT, di, dn, er, em, en, dE, dG)
539537 }
540538 }
541539
542540
543-func et (cA,cQ,eu) = {
544- let ev = g
545- let ew = cA[if ((cQ == 0))
541+func es (cz,cP,et) = {
542+ let eu = g
543+ let ev = cz[if ((cP == 0))
546544 then 1
547545 else 0]
548- let ex = parseBigIntValue(m)
549- let cE = (parseBigIntValue(aV) * ex)
550- let cD = ew
551- let cF = (cE * ev)
552- let ey = (((((eu * eu) / (ew * ev)) * eu) * ex) / (cF * ev))
553- let ez = ((cD + ((eu * ex) / cF)) - eu)
554- func cO (cP,eA) = {
555- let eB = cP
556- let eC = eB._1
557- let dd = eB._2
558- if ((dd != unit))
559- then cP
546+ let ew = parseBigIntValue(l)
547+ let cD = (parseBigIntValue(aU) * ew)
548+ let cC = ev
549+ let cE = (cD * eu)
550+ let ex = (((((et * et) / (ev * eu)) * et) * ew) / (cE * eu))
551+ let ey = ((cC + ((et * ew) / cE)) - et)
552+ func cN (cO,ez) = {
553+ let eA = cO
554+ let eB = eA._1
555+ let dc = eA._2
556+ if ((dc != unit))
557+ then cO
560558 else {
561- let eD = (((eC * eC) + ey) / ((g * eC) + ez))
562- let eE = Y((eD - value(eC)))
563- if ((f >= eE))
564- then $Tuple2(eD, eA)
565- else $Tuple2(eD, unit)
559+ let eC = (((eB * eB) + ex) / ((g * eB) + ey))
560+ let eD = X((eC - value(eB)))
561+ if ((f >= eD))
562+ then $Tuple2(eC, ez)
563+ else $Tuple2(eC, unit)
566564 }
567565 }
568566
569- let cU = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14]
570- let eF = {
571- let cW = cU
572- let cX = size(cW)
573- let cY = $Tuple2(eu, unit)
574- func cZ (da,db) = if ((db >= cX))
575- then da
576- else cO(da, cW[db])
567+ let cT = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14]
568+ let eE = {
569+ let cV = cT
570+ let cW = size(cV)
571+ let cX = $Tuple2(et, unit)
572+ func cY (cZ,da) = if ((da >= cW))
573+ then cZ
574+ else cN(cZ, cV[da])
577575
578- func dc (da,db) = if ((db >= cX))
579- then da
576+ func db (cZ,da) = if ((da >= cW))
577+ then cZ
580578 else throw("List size exceeds 15")
581579
582- dc(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cY, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15)
580+ db(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cX, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15)
583581 }
584- let eC = eF._1
585- let dd = eF._2
586- if ((dd != unit))
587- then eC
588- else throw(("Y calculation error, Y = " + toString(eC)))
582+ let eB = eE._1
583+ let dc = eE._2
584+ if ((dc != unit))
585+ then eB
586+ else throw(("Y calculation error, Y = " + toString(eB)))
589587 }
590588
591589
592-func eG (eH,eI,eJ) = {
593- let eK = fraction(cz([L(eH, toBigInt(bp)), L(eI, toBigInt(bq))]), c, eJ)
594- if ((eJ == e))
590+func eF (eG,eH,eI) = {
591+ let eJ = fraction(cy([K(eG, toBigInt(bo)), K(eH, toBigInt(bp))]), c, eI)
592+ if ((eI == e))
595593 then e
596- else eK
594+ else eJ
597595 }
598596
599597
600-func eL (eM,eN,eO) = {
601- let eP = (toBigInt(bO(bf(bn))) - eM)
602- let eQ = (toBigInt(bO(bf(bo))) - eN)
603- let eR = (toBigInt(value(assetInfo(bm)).quantity) - eO)
604- let eS = eG(eP, eQ, eR)
605- eS
598+func eK (eL,eM,eN) = {
599+ let eO = (toBigInt(bN(be(bm))) - eL)
600+ let eP = (toBigInt(bN(be(bn))) - eM)
601+ let eQ = (toBigInt(value(assetInfo(bl)).quantity) - eN)
602+ let eR = eF(eO, eP, eQ)
603+ eR
606604 }
607605
608606
609-func eT (eU,eV,eO) = {
610- let eP = (bO(bf(bn)) + eU)
611- let eQ = (bO(bf(bo)) + eV)
612- let eR = (value(assetInfo(bm)).quantity + eO)
613- let eK = eG(toBigInt(eP), toBigInt(eQ), toBigInt(eR))
614- let eW = [IntegerEntry(ar, height), StringEntry(aq, toString(eK))]
615- $Tuple2(eW, eK)
607+func eS (eT,eU,eN) = {
608+ let eO = (bN(be(bm)) + eT)
609+ let eP = (bN(be(bn)) + eU)
610+ let eQ = (value(assetInfo(bl)).quantity + eN)
611+ let eJ = eF(toBigInt(eO), toBigInt(eP), toBigInt(eQ))
612+ let eV = [IntegerEntry(aq, height), StringEntry(ap, toString(eJ))]
613+ $Tuple2(eV, eJ)
616614 }
617615
618616
619-func eX (eY,eK) = if ((eK >= eY))
617+func eW (eX,eJ) = if ((eJ >= eX))
620618 then true
621- else aO("updated DLp lower than current DLp")
619+ else aN("updated DLp lower than current DLp")
622620
623621
624-func eZ (fa) = {
625- let eP = bO(bf(bn))
626- let eQ = bO(bf(bo))
627- let fb = fa.amount
628- let fc = fraction(fa.amount, fa.price, a, FLOOR)
629- let fd = if ((fa.orderType == Buy))
630- then $Tuple2(fb, -(fc))
631- else $Tuple2(-(fb), fc)
632- let eU = fd._1
633- let eV = fd._2
634- if (if (if (aW())
622+func eY (eZ) = {
623+ let eO = bN(be(bm))
624+ let eP = bN(be(bn))
625+ let fa = eZ.amount
626+ let fb = fraction(eZ.amount, eZ.price, a, FLOOR)
627+ let fc = if ((eZ.orderType == Buy))
628+ then $Tuple2(fa, -(fb))
629+ else $Tuple2(-(fa), fb)
630+ let eT = fc._1
631+ let eU = fc._2
632+ if (if (if (aV())
635633 then true
636- else (bl == s))
634+ else (bk == r))
637635 then true
638- else (bl == t))
636+ else (bk == s))
639637 then throw("Admin blocked")
640- else if (if ((fa.assetPair.amountAsset != bn))
638+ else if (if ((eZ.assetPair.amountAsset != bm))
641639 then true
642- else (fa.assetPair.priceAsset != bo))
640+ else (eZ.assetPair.priceAsset != bn))
643641 then throw("Wr assets")
644642 else {
645- let fe = parseBigIntValue(valueOrElse(getString(this, aq), "0"))
646- let ff = eT(eU, eV, 0)
647- let fg = ff._1
648- let fh = ff._2
649- let fi = (fh >= fe)
650- let fj = makeString(["dLp=", toString(fe), " dLpNew=", toString(fh), " amountAssetBalance=", toString(eP), " priceAssetBalance=", toString(eQ), " amountAssetBalanceDelta=", toString(eU), " priceAssetBalanceDelta=", toString(eV), " height=", toString(height)], "")
651- $Tuple2(fi, fj)
643+ let fd = parseBigIntValue(valueOrElse(getString(this, ap), "0"))
644+ let fe = eS(eT, eU, 0)
645+ let ff = fe._1
646+ let fg = fe._2
647+ let fh = (fg >= fd)
648+ let fi = makeString(["dLp=", toString(fd), " dLpNew=", toString(fg), " amountAssetBalance=", toString(eO), " priceAssetBalance=", toString(eP), " amountAssetBalanceDelta=", toString(eT), " priceAssetBalanceDelta=", toString(eU), " height=", toString(height)], "")
649+ $Tuple2(fh, fi)
652650 }
653651 }
654652
655653
656-func fk (cQ) = if ((size(cQ.payments) != 1))
654+func fj (cP) = if ((size(cP.payments) != 1))
657655 then throw("1 pmnt exp")
658656 else {
659- let fl = value(cQ.payments[0])
660- let dg = value(fl.assetId)
661- let dM = fl.amount
662- let dY = de(toBase58String(cQ.transactionId), toBase58String(dg), dM, cQ.caller)
663- let dA = dY._1
664- let dB = dY._2
665- let do = parseIntValue(dY._9)
666- let dC = dY._10
667- if (if (aW())
657+ let fk = value(cP.payments[0])
658+ let df = value(fk.assetId)
659+ let dL = fk.amount
660+ let dX = dd(toBase58String(cP.transactionId), toBase58String(df), dL, cP.caller)
661+ let dz = dX._1
662+ let dA = dX._2
663+ let dn = parseIntValue(dX._9)
664+ let dB = dX._10
665+ if (if (aV())
668666 then true
669- else (do == t))
670- then throw(("Admin blocked: " + toString(do)))
671- else $Tuple5(dA, dB, dM, dg, dC)
667+ else (dn == s))
668+ then throw(("Admin blocked: " + toString(dn)))
669+ else $Tuple5(dz, dA, dL, df, dB)
672670 }
673671
674672
675-func fm (fn,ai,fo,fp,bX,dJ,dK,dL,dM,dN) = {
676- let dY = dD(ai, bX, value(fo).amount, value(fo).assetId, value(fp).amount, value(fp).assetId, fn, (ai == ""), dJ, dK, dL, dM, dN)
677- let do = parseIntValue(dY._8)
678- if (if (if (aW())
673+func fl (fm,ah,fn,fo,bW,dI,dJ,dK,dL,dM) = {
674+ let dX = dC(ah, bW, value(fn).amount, value(fn).assetId, value(fo).amount, value(fo).assetId, fm, (ah == ""), dI, dJ, dK, dL, dM)
675+ let dn = parseIntValue(dX._8)
676+ if (if (if (aV())
679677 then true
680- else (do == r))
678+ else (dn == q))
681679 then true
682- else (do == t))
683- then throw(("Blocked:" + toString(do)))
684- else dY
680+ else (dn == s))
681+ then throw(("Blocked:" + toString(dn)))
682+ else dX
685683 }
686684
687685
688-func fq (fr,dg,di,ai,fs) = {
686+func fp (fq,df,dh,ah,fr) = {
687+ let dj = toBase58String(value(bm))
689688 let dk = toBase58String(value(bn))
690- let dl = toBase58String(value(bo))
691- let dj = bm
689+ let di = bl
690+ let dR = bo
692691 let dS = bp
693- let dT = bq
694- let eR = toBigInt(valueOrErrorMessage(assetInfo(dj), "invalid lp asset").quantity)
695- let ft = if ((eR > e))
692+ let eQ = toBigInt(valueOrErrorMessage(assetInfo(di), "invalid lp asset").quantity)
693+ let fs = if ((eQ > e))
696694 then true
697695 else throw("initial deposit requires all coins")
698- if ((ft == ft))
696+ if ((fs == fs))
699697 then {
700- let dq = bO(dk)
701- let ds = bO(dl)
702- let fu = if ((ai == ""))
703- then $Tuple2(dq, ds)
704- else if ((dg == dk))
705- then if ((fr > dq))
698+ let dp = bN(dj)
699+ let dr = bN(dk)
700+ let ft = if ((ah == ""))
701+ then $Tuple2(dp, dr)
702+ else if ((df == dj))
703+ then if ((fq > dp))
706704 then throw("invalid payment amount")
707- else $Tuple2((dq - fr), ds)
708- else if ((dg == dl))
709- then if ((fr > ds))
705+ else $Tuple2((dp - fq), dr)
706+ else if ((df == dk))
707+ then if ((fq > dr))
710708 then throw("invalid payment amount")
711- else $Tuple2(dq, (ds - fr))
709+ else $Tuple2(dp, (dr - fq))
712710 else throw("wrong pmtAssetId")
713- let fv = fu._1
714- let fw = fu._2
715- let fx = if ((dg == dk))
716- then $Tuple2(fr, 0)
717- else if ((dg == dl))
718- then $Tuple2(0, fr)
711+ let fu = ft._1
712+ let fv = ft._2
713+ let fw = if ((df == dj))
714+ then $Tuple2(fq, 0)
715+ else if ((df == dk))
716+ then $Tuple2(0, fq)
719717 else throw("invalid payment")
720- let fy = fx._1
721- let fz = fx._2
722- let fA = if (fs)
723- then $Tuple3(cw(fy, aS)._1, cw(fz, aS)._1, cw(fr, aS)._2)
724- else $Tuple3(fy, fz, 0)
725- let fB = fA._1
726- let fC = fA._2
727- let cy = fA._3
718+ let fx = fw._1
719+ let fy = fw._2
720+ let fz = if (fr)
721+ then $Tuple3(cv(fx, aR)._1, cv(fy, aR)._1, cv(fq, aR)._2)
722+ else $Tuple3(fx, fy, 0)
723+ let fA = fz._1
724+ let fB = fz._2
725+ let cx = fz._3
726+ let fC = (fu + fA)
728727 let fD = (fv + fB)
729- let fE = (fw + fC)
730- let cc = cz([I(fv, bp), I(fw, bq)])
731- let cb = cz([I(fD, bp), I(fE, bq)])
732- let dZ = if ((cb > cc))
728+ let cb = cy([H(fu, bo), H(fv, bp)])
729+ let ca = cy([H(fC, bo), H(fD, bp)])
730+ let dY = if ((ca > cb))
733731 then true
734732 else throw()
735- if ((dZ == dZ))
733+ if ((dY == dY))
736734 then {
737- let fF = fraction(eR, (cb - cc), cc, FLOOR)
738- let dv = M(bQ(I(fE, dT), I(fD, dS)), a)
739- let es = [IntegerEntry(ac(), dv), IntegerEntry(ad(height, lastBlock.timestamp), dv), StringEntry(ag(di, ai), bz(fy, fz, toInt(fF), dv, 0, 0, height, lastBlock.timestamp, 0, 0))]
740- let fG = fraction(fw, a, fv)
741- let fH = fraction(fr, a, (fG + a))
742- let fI = (fr - fH)
743- let fJ = fraction(eR, toBigInt(fI), toBigInt(fw))
744- let fK = toInt(fraction((fF - fJ), b, fJ))
745- $Tuple4(toInt(fF), es, cy, fK)
735+ let fE = fraction(eQ, (ca - cb), cb, FLOOR)
736+ let du = L(bP(H(fD, dS), H(fC, dR)), a)
737+ let er = [IntegerEntry(ab(), du), IntegerEntry(ac(height, lastBlock.timestamp), du), StringEntry(af(dh, ah), by(fx, fy, toInt(fE), du, 0, 0, height, lastBlock.timestamp, 0, 0))]
738+ let fF = fraction(fv, a, fu)
739+ let fG = fraction(fq, a, (fF + a))
740+ let fH = (fq - fG)
741+ let fI = fraction(eQ, toBigInt(fH), toBigInt(fv))
742+ let fJ = toInt(fraction((fE - fI), b, fI))
743+ $Tuple4(toInt(fE), er, cx, fJ)
746744 }
747745 else throw("Strict value is not equal to itself.")
748746 }
750748 }
751749
752750
753-func fL (fM,fN,fO,fn,fP,fQ) = {
751+func fK (fL,fM,fN,fm,fO,fP) = {
752+ let di = toBase58String(value(bl))
754753 let dj = toBase58String(value(bm))
755754 let dk = toBase58String(value(bn))
756- let dl = toBase58String(value(bo))
755+ let fQ = bo
757756 let fR = bp
758- let fS = bq
759- let fT = bl
760- let di = if ((fn == by))
761- then fP
762- else fn
763- let fl = value(fO[0])
764- let dg = value(fl.assetId)
765- let dM = fl.amount
766- let eS = eL(e, e, e)
767- if ((eS == eS))
757+ let fS = bk
758+ let dh = if ((fm == bx))
759+ then fO
760+ else fm
761+ let fk = value(fN[0])
762+ let df = value(fk.assetId)
763+ let dL = fk.amount
764+ let eR = eK(e, e, e)
765+ if ((eR == eR))
768766 then {
769- let df = toBase58String(fQ)
770- if ((dj != toBase58String(dg)))
767+ let de = toBase58String(fP)
768+ if ((di != toBase58String(df)))
771769 then throw("Wrong LP")
772770 else {
773- let dq = bO(dk)
774- let ds = bO(dl)
775- let fU = {
776- let aT = invoke(this, "getOneTknV2READONLY", [fM, dM], nil)
777- if ($isInstanceOf(aT, "(Int, Int)"))
778- then aT
779- else throw(($getType(aT) + " couldn't be cast to (Int, Int)"))
771+ let dp = bN(dj)
772+ let dr = bN(dk)
773+ let fT = {
774+ let aS = invoke(this, "getOneTknV2READONLY", [fL, dL], nil)
775+ if ($isInstanceOf(aS, "(Int, Int)"))
776+ then aS
777+ else throw(($getType(aS) + " couldn't be cast to (Int, Int)"))
780778 }
781- if ((fU == fU))
779+ if ((fT == fT))
782780 then {
783- let cy = fU._2
784- let fV = fU._1
785- let fW = if (if ((fN > 0))
786- then (fN > fV)
781+ let cx = fT._2
782+ let fU = fT._1
783+ let fV = if (if ((fM > 0))
784+ then (fM > fU)
787785 else false)
788- then aO(makeString(["amount to receive is less than ", toString(fN)], ""))
789- else fV
790- let fX = if ((fM == dk))
791- then $Tuple4(fW, 0, ((dq - fW) - cy), ds)
792- else if ((fM == dl))
793- then $Tuple4(0, fW, dq, ((ds - fW) - cy))
786+ then aN(makeString(["amount to receive is less than ", toString(fM)], ""))
787+ else fU
788+ let fW = if ((fL == dj))
789+ then $Tuple4(fV, 0, ((dp - fV) - cx), dr)
790+ else if ((fL == dk))
791+ then $Tuple4(0, fV, dp, ((dr - fV) - cx))
794792 else throw("invalid out asset id")
795- let fY = fX._1
796- let fZ = fX._2
797- let fD = fX._3
798- let fE = fX._4
799- let ga = bQ(I(fE, fS), I(fD, fR))
800- let gb = M(ga, a)
801- let gc = if ((fM == "WAVES"))
793+ let fX = fW._1
794+ let fY = fW._2
795+ let fC = fW._3
796+ let fD = fW._4
797+ let fZ = bP(H(fD, fR), H(fC, fQ))
798+ let ga = L(fZ, a)
799+ let gb = if ((fL == "WAVES"))
802800 then unit
803- else fromBase58String(fM)
804- let gd = if ((cy > 0))
805- then [ScriptTransfer(aY, cy, gc)]
801+ else fromBase58String(fL)
802+ let gc = if ((cx > 0))
803+ then [ScriptTransfer(aX, cx, gb)]
806804 else nil
807- let dC = ([ScriptTransfer(di, fW, gc), StringEntry(aj(toString(di), df), bK(fY, fZ, dM, gb, height, lastBlock.timestamp)), IntegerEntry(ac(), gb), IntegerEntry(ad(height, lastBlock.timestamp), gb)] ++ gd)
808- if ((dC == dC))
805+ let dB = ([ScriptTransfer(dh, fV, gb), StringEntry(ai(toString(dh), de), bJ(fX, fY, dL, ga, height, lastBlock.timestamp)), IntegerEntry(ab(), ga), IntegerEntry(ac(height, lastBlock.timestamp), ga)] ++ gc)
806+ if ((dB == dB))
809807 then {
810- let ge = invoke(aR, "burn", [dM], [AttachedPayment(dg, dM)])
811- if ((ge == ge))
808+ let gd = invoke(aQ, "burn", [dL], [AttachedPayment(df, dL)])
809+ if ((gd == gd))
812810 then {
813- let gf = {
814- let gg = if ((this == aY))
811+ let ge = {
812+ let gf = if ((this == aX))
815813 then 0
816- else cy
817- let gh = if ((bd(fM) == bn))
814+ else cx
815+ let gg = if ((bc(fL) == bm))
818816 then true
819817 else false
820- if (gh)
821- then $Tuple2(-((fV + gg)), 0)
822- else $Tuple2(0, -((fV + gg)))
818+ if (gg)
819+ then $Tuple2(-((fU + gf)), 0)
820+ else $Tuple2(0, -((fU + gf)))
823821 }
824- let eU = gf._1
825- let eV = gf._2
826- let gi = eT(eU, eV, 0)
827- let gj = gi._1
828- let eK = gi._2
829- let gk = eX(eS, eK)
830- if ((gk == gk))
831- then $Tuple2((dC ++ gj), fW)
822+ let eT = ge._1
823+ let eU = ge._2
824+ let gh = eS(eT, eU, 0)
825+ let gi = gh._1
826+ let eJ = gh._2
827+ let gj = eW(eR, eJ)
828+ if ((gj == gj))
829+ then $Tuple2((dB ++ gi), fV)
832830 else throw("Strict value is not equal to itself.")
833831 }
834832 else throw("Strict value is not equal to itself.")
842840 }
843841
844842
845-func gl () = {
846- let gm = getString(aa())
847- if ($isInstanceOf(gm, "String"))
843+func gk () = {
844+ let gl = getString(Z())
845+ if ($isInstanceOf(gl, "String"))
848846 then {
849- let cD = gm
850- fromBase58String(cD)
847+ let cC = gl
848+ fromBase58String(cC)
851849 }
852- else if ($isInstanceOf(gm, "Unit"))
850+ else if ($isInstanceOf(gl, "Unit"))
853851 then unit
854852 else throw("Match error")
855853 }
856854
857855
858-func gn () = {
859- let gm = getString(ab())
860- if ($isInstanceOf(gm, "String"))
856+func gm () = {
857+ let gl = getString(aa())
858+ if ($isInstanceOf(gl, "String"))
861859 then {
862- let cD = gm
863- fromBase58String(cD)
860+ let cC = gl
861+ fromBase58String(cC)
864862 }
865- else if ($isInstanceOf(gm, "Unit"))
863+ else if ($isInstanceOf(gl, "Unit"))
866864 then unit
867865 else throw("Match error")
868866 }
869867
870868
871-let go = throw("Permission denied")
869+let gn = throw("Permission denied")
872870
873-func gp (cQ) = {
874- let gm = gl()
875- if ($isInstanceOf(gm, "ByteVector"))
871+func go (cP) = {
872+ let gl = gk()
873+ if ($isInstanceOf(gl, "ByteVector"))
876874 then {
877- let gq = gm
878- (cQ.callerPublicKey == gq)
875+ let gp = gl
876+ (cP.callerPublicKey == gp)
879877 }
880- else if ($isInstanceOf(gm, "Unit"))
881- then (cQ.caller == this)
878+ else if ($isInstanceOf(gl, "Unit"))
879+ then (cP.caller == this)
882880 else throw("Match error")
883881 }
884882
885883
886-func gr (cQ) = {
887- let gm = gl()
888- if ($isInstanceOf(gm, "ByteVector"))
884+func gq (cP) = {
885+ let gl = gk()
886+ if ($isInstanceOf(gl, "ByteVector"))
889887 then {
890- let gq = gm
891- if ((cQ.callerPublicKey == gq))
888+ let gp = gl
889+ if ((cP.callerPublicKey == gp))
892890 then true
893- else go
891+ else gn
894892 }
895- else if ($isInstanceOf(gm, "Unit"))
896- then if ((cQ.caller == this))
893+ else if ($isInstanceOf(gl, "Unit"))
894+ then if ((cP.caller == this))
897895 then true
898- else go
896+ else gn
899897 else throw("Match error")
900898 }
901899
902900
903-func gs (gt,eu,gu) = {
904- let bh = aZ()
905- let dk = bh[x]
906- let dl = bh[y]
907- let ev = g
908- let ex = parseBigIntValue(m)
909- let cE = (parseBigIntValue(aV) * ex)
910- let cA = if ((gt == false))
911- then [(toBigInt(bO(dk)) + gu), toBigInt(bO(dl))]
912- else [(toBigInt(bO(dl)) + gu), toBigInt(bO(dk))]
913- let ew = cA[0]
914- let cD = ew
915- let cF = (cE * ev)
916- let ey = (((((eu * eu) / (ew * ev)) * eu) * ex) / (cF * ev))
917- let ez = ((cD + ((eu * ex) / cF)) - eu)
918- func cO (cP,eA) = {
919- let gv = cP
920- let eC = gv._1
921- let dd = gv._2
922- if ((dd != unit))
923- then cP
901+func gr (gs,et,gt) = {
902+ let bg = aY()
903+ let dj = bg[w]
904+ let dk = bg[x]
905+ let eu = g
906+ let ew = parseBigIntValue(l)
907+ let cD = (parseBigIntValue(aU) * ew)
908+ let cz = if ((gs == false))
909+ then [(toBigInt(bN(dj)) + gt), toBigInt(bN(dk))]
910+ else [(toBigInt(bN(dk)) + gt), toBigInt(bN(dj))]
911+ let ev = cz[0]
912+ let cC = ev
913+ let cE = (cD * eu)
914+ let ex = (((((et * et) / (ev * eu)) * et) * ew) / (cE * eu))
915+ let ey = ((cC + ((et * ew) / cE)) - et)
916+ func cN (cO,ez) = {
917+ let gu = cO
918+ let eB = gu._1
919+ let dc = gu._2
920+ if ((dc != unit))
921+ then cO
924922 else {
925- let eD = (((eC * eC) + ey) / ((g * eC) + ez))
926- let eE = Y((eD - value(eC)))
927- if ((f >= eE))
928- then $Tuple2(eD, eA)
929- else $Tuple2(eD, unit)
923+ let eC = (((eB * eB) + ex) / ((g * eB) + ey))
924+ let eD = X((eC - value(eB)))
925+ if ((f >= eD))
926+ then $Tuple2(eC, ez)
927+ else $Tuple2(eC, unit)
930928 }
931929 }
932930
933- let cU = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14]
934- let gw = {
935- let cW = cU
936- let cX = size(cW)
937- let cY = $Tuple2(eu, unit)
938- func cZ (da,db) = if ((db >= cX))
939- then da
940- else cO(da, cW[db])
931+ let cT = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14]
932+ let gv = {
933+ let cV = cT
934+ let cW = size(cV)
935+ let cX = $Tuple2(et, unit)
936+ func cY (cZ,da) = if ((da >= cW))
937+ then cZ
938+ else cN(cZ, cV[da])
941939
942- func dc (da,db) = if ((db >= cX))
943- then da
940+ func db (cZ,da) = if ((da >= cW))
941+ then cZ
944942 else throw("List size exceeds 15")
945943
946- dc(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cY, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15)
944+ db(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cX, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15)
947945 }
948- let eC = gw._1
949- let dd = gw._2
950- if ((dd != unit))
951- then eC
952- else throw(("Y calculation error, Y = " + toString(eC)))
946+ let eB = gv._1
947+ let dc = gv._2
948+ if ((dc != unit))
949+ then eB
950+ else throw(("Y calculation error, Y = " + toString(eB)))
953951 }
954952
955953
956-@Callable(cQ)
957-func calculateAmountOutForSwapREADONLY (gx,gt) = {
958- let gy = if ((gt == false))
954+@Callable(cP)
955+func calculateAmountOutForSwapREADONLY (gw,gs) = {
956+ let gx = if ((gs == false))
959957 then {
960- let gz = aK(this, al())
961- let gu = (toBigInt(bO(aK(this, ak()))) + toBigInt(gx))
962- $Tuple2(gz, gu)
958+ let gy = aJ(this, ak())
959+ let gt = (toBigInt(bN(aJ(this, aj()))) + toBigInt(gw))
960+ $Tuple2(gy, gt)
963961 }
964962 else {
965- let gz = aK(this, ak())
966- let gu = (toBigInt(bO(aK(this, al()))) + toBigInt(gx))
967- $Tuple2(gz, gu)
963+ let gy = aJ(this, aj())
964+ let gt = (toBigInt(bN(aJ(this, ak()))) + toBigInt(gw))
965+ $Tuple2(gy, gt)
968966 }
969- let gz = gy._1
970- let gu = gy._2
971- let bh = aZ()
972- let dk = bh[x]
973- let dl = bh[y]
974- let cA = [toBigInt(bO(dk)), toBigInt(bO(dl))]
975- let eu = cz(cA)
976- let eC = gs(gt, eu, toBigInt(gx))
977- let gA = ((toBigInt(bO(gz)) - eC) - toBigInt(1))
978- let gB = max([0, toInt(gA)])
979- let gC = if ((gt == false))
980- then [(toBigInt(bO(dk)) + toBigInt(gx)), (toBigInt(bO(dl)) - gA)]
981- else [(toBigInt(bO(dk)) - gA), (toBigInt(bO(dl)) + toBigInt(gx))]
982- let gD = cz(gC)
983- let dZ = if ((gD >= eu))
967+ let gy = gx._1
968+ let gt = gx._2
969+ let bg = aY()
970+ let dj = bg[w]
971+ let dk = bg[x]
972+ let cz = [toBigInt(bN(dj)), toBigInt(bN(dk))]
973+ let et = cy(cz)
974+ let eB = gr(gs, et, toBigInt(gw))
975+ let gz = ((toBigInt(bN(gy)) - eB) - toBigInt(1))
976+ let gA = max([0, toInt(gz)])
977+ let gB = if ((gs == false))
978+ then [(toBigInt(bN(dj)) + toBigInt(gw)), (toBigInt(bN(dk)) - gz)]
979+ else [(toBigInt(bN(dj)) - gz), (toBigInt(bN(dk)) + toBigInt(gw))]
980+ let gC = cy(gB)
981+ let dY = if ((gC >= et))
984982 then true
985- else throw(makeString(["new D is fewer error", toString(eu), toString(gD)], "__"))
986- if ((dZ == dZ))
987- then $Tuple2(nil, gB)
983+ else throw(makeString(["new D is fewer error", toString(et), toString(gC)], "__"))
984+ if ((dY == dY))
985+ then $Tuple2(nil, gA)
988986 else throw("Strict value is not equal to itself.")
989987 }
990988
991989
992990
993-@Callable(cQ)
994-func calculateAmountOutForSwapAndSendTokens (gx,gt,gE,gF) = {
995- let gG = {
996- let aT = invoke(aR, "getSwapContractREADONLY", nil, nil)
997- if ($isInstanceOf(aT, "String"))
998- then aT
999- else throw(($getType(aT) + " couldn't be cast to String"))
991+@Callable(cP)
992+func calculateAmountOutForSwapAndSendTokens (gw,gs,gD,gE) = {
993+ let gF = {
994+ let aS = invoke(aQ, "getSwapContractREADONLY", nil, nil)
995+ if ($isInstanceOf(aS, "String"))
996+ then aS
997+ else throw(($getType(aS) + " couldn't be cast to String"))
1000998 }
1001- let gH = [if ((value(cQ.payments[0]).amount >= gx))
999+ let gG = [if ((value(cP.payments[0]).amount >= gw))
10021000 then true
1003- else aO("Wrong amount"), if ((cQ.caller == addressFromStringValue(gG)))
1001+ else aN("Wrong amount"), if ((cP.caller == addressFromStringValue(gF)))
10041002 then true
1005- else aO("Permission denied")]
1006- if ((gH == gH))
1003+ else aN("Permission denied")]
1004+ if ((gG == gG))
10071005 then {
1008- let fl = value(cQ.payments[0])
1009- let gI = if ((fl.assetId == unit))
1006+ let fk = value(cP.payments[0])
1007+ let gH = if ((fk.assetId == unit))
10101008 then toBase58String(toBytes("WAVES"))
1011- else toBase58String(value(fl.assetId))
1012- let gJ = if ((gt == false))
1009+ else toBase58String(value(fk.assetId))
1010+ let gI = if ((gs == false))
10131011 then {
1014- let gz = aK(this, al())
1015- let gu = (bO(gI) - value(cQ.payments[0]).amount)
1016- $Tuple2(gz, gu)
1012+ let gy = aJ(this, ak())
1013+ let gt = (bN(gH) - value(cP.payments[0]).amount)
1014+ $Tuple2(gy, gt)
10171015 }
10181016 else {
1019- let gz = aK(this, ak())
1020- let gu = (bO(gI) - value(cQ.payments[0]).amount)
1021- $Tuple2(gz, gu)
1017+ let gy = aJ(this, aj())
1018+ let gt = (bN(gH) - value(cP.payments[0]).amount)
1019+ $Tuple2(gy, gt)
10221020 }
1023- let gz = gJ._1
1024- let gu = gJ._2
1025- let bh = aZ()
1026- let dk = bh[x]
1027- let dl = bh[y]
1028- let cA = if ((gt == false))
1029- then [(toBigInt(bO(dk)) - toBigInt(value(cQ.payments[0]).amount)), toBigInt(bO(dl))]
1030- else [toBigInt(bO(dk)), (toBigInt(bO(dl)) - toBigInt(value(cQ.payments[0]).amount))]
1031- let eu = cz(cA)
1032- let eC = gs(gt, eu, toBigInt(0))
1033- let gA = ((toBigInt(bO(gz)) - eC) - toBigInt(1))
1034- let gB = max([0, toInt(gA)])
1035- let gK = if ((gB >= gE))
1021+ let gy = gI._1
1022+ let gt = gI._2
1023+ let bg = aY()
1024+ let dj = bg[w]
1025+ let dk = bg[x]
1026+ let cz = if ((gs == false))
1027+ then [(toBigInt(bN(dj)) - toBigInt(value(cP.payments[0]).amount)), toBigInt(bN(dk))]
1028+ else [toBigInt(bN(dj)), (toBigInt(bN(dk)) - toBigInt(value(cP.payments[0]).amount))]
1029+ let et = cy(cz)
1030+ let eB = gr(gs, et, toBigInt(0))
1031+ let gz = ((toBigInt(bN(gy)) - eB) - toBigInt(1))
1032+ let gA = max([0, toInt(gz)])
1033+ let gJ = if ((gA >= gD))
10361034 then true
10371035 else throw("Exchange result is fewer coins than expected")
1038- if ((gK == gK))
1036+ if ((gJ == gJ))
10391037 then {
1040- let gC = if ((gt == false))
1041- then [toBigInt(bO(dk)), (toBigInt(bO(dl)) - gA)]
1042- else [(toBigInt(bO(dk)) - gA), toBigInt(bO(dl))]
1043- let gD = cz(gC)
1044- let dZ = if ((gD >= eu))
1038+ let gB = if ((gs == false))
1039+ then [toBigInt(bN(dj)), (toBigInt(bN(dk)) - gz)]
1040+ else [(toBigInt(bN(dj)) - gz), toBigInt(bN(dk))]
1041+ let gC = cy(gB)
1042+ let dY = if ((gC >= et))
10451043 then true
10461044 else throw("new D is fewer error")
1047- if ((dZ == dZ))
1048- then $Tuple2([ScriptTransfer(addressFromStringValue(gF), gB, bd(gz))], gB)
1045+ if ((dY == dY))
1046+ then $Tuple2([ScriptTransfer(addressFromStringValue(gE), gA, bc(gy))], gA)
10491047 else throw("Strict value is not equal to itself.")
10501048 }
10511049 else throw("Strict value is not equal to itself.")
10551053
10561054
10571055
1058-@Callable(cQ)
1059-func constructor (Z) = {
1060- let ey = gr(cQ)
1061- if ((ey == ey))
1062- then [StringEntry(Z(), Z)]
1056+@Callable(cP)
1057+func constructor (Y) = {
1058+ let ex = gq(cP)
1059+ if ((ex == ex))
1060+ then [StringEntry(Y(), Y)]
10631061 else throw("Strict value is not equal to itself.")
10641062 }
10651063
10661064
10671065
1068-@Callable(cQ)
1069-func setManager (gL) = {
1070- let ey = gr(cQ)
1071- if ((ey == ey))
1066+@Callable(cP)
1067+func setManager (gK) = {
1068+ let ex = gq(cP)
1069+ if ((ex == ex))
10721070 then {
1073- let gM = fromBase58String(gL)
1074- if ((gM == gM))
1075- then [StringEntry(ab(), gL)]
1071+ let gL = fromBase58String(gK)
1072+ if ((gL == gL))
1073+ then [StringEntry(aa(), gK)]
10761074 else throw("Strict value is not equal to itself.")
10771075 }
10781076 else throw("Strict value is not equal to itself.")
10801078
10811079
10821080
1083-@Callable(cQ)
1081+@Callable(cP)
10841082 func confirmManager () = {
1085- let cv = gn()
1086- let gN = if (isDefined(cv))
1083+ let cu = gm()
1084+ let gM = if (isDefined(cu))
10871085 then true
10881086 else throw("No pending manager")
1089- if ((gN == gN))
1087+ if ((gM == gM))
10901088 then {
1091- let gO = if ((cQ.callerPublicKey == value(cv)))
1089+ let gN = if ((cP.callerPublicKey == value(cu)))
10921090 then true
10931091 else throw("You are not pending manager")
1094- if ((gO == gO))
1095- then [StringEntry(aa(), toBase58String(value(cv))), DeleteEntry(ab())]
1092+ if ((gN == gN))
1093+ then [StringEntry(Z(), toBase58String(value(cu))), DeleteEntry(aa())]
10961094 else throw("Strict value is not equal to itself.")
10971095 }
10981096 else throw("Strict value is not equal to itself.")
11001098
11011099
11021100
1103-@Callable(cQ)
1104-func put (gP,gQ) = {
1105- let gR = bt()
1106- let gS = valueOrErrorMessage(addressFromString(gR[D]), "Wr st addr")
1107- let gT = valueOrErrorMessage(addressFromString(gR[F]), "Wr sl addr")
1108- if ((0 > gP))
1101+@Callable(cP)
1102+func put (gO,gP) = {
1103+ let gQ = bs()
1104+ let gR = valueOrErrorMessage(addressFromString(gQ[C]), "Wr st addr")
1105+ let gS = valueOrErrorMessage(addressFromString(gQ[E]), "Wr sl addr")
1106+ if ((0 > gO))
11091107 then throw("Wrong slippage")
1110- else if ((size(cQ.payments) != 2))
1108+ else if ((size(cP.payments) != 2))
11111109 then throw("2 pmnts expd")
11121110 else {
1113- let gU = toBigInt(value(cQ.payments[0]).amount)
1114- let gV = toBigInt(value(cQ.payments[1]).amount)
1115- let eP = (toBigInt(bO(bf(bn))) - gU)
1116- if ((eP == eP))
1111+ let gT = toBigInt(value(cP.payments[0]).amount)
1112+ let gU = toBigInt(value(cP.payments[1]).amount)
1113+ let eO = (toBigInt(bN(be(bm))) - gT)
1114+ if ((eO == eO))
11171115 then {
1118- let eQ = (toBigInt(bO(bf(bo))) - gV)
1119- if ((eQ == eQ))
1116+ let eP = (toBigInt(bN(be(bn))) - gU)
1117+ if ((eP == eP))
11201118 then {
1121- let eR = toBigInt(value(assetInfo(bm)).quantity)
1122- if ((eR == eR))
1119+ let eQ = toBigInt(value(assetInfo(bl)).quantity)
1120+ if ((eQ == eQ))
11231121 then {
1124- let eS = eL(gU, gV, toBigInt(0))
1125- if ((eS == eS))
1122+ let eR = eK(gT, gU, toBigInt(0))
1123+ if ((eR == eR))
11261124 then {
1127- let gW = fm(toString(cQ.caller), toBase58String(cQ.transactionId), AttachedPayment(value(cQ.payments[0]).assetId, value(cQ.payments[0]).amount), cQ.payments[1], gP, true, false, true, 0, "")
1128- let em = gW._2
1129- let gX = gW._7
1130- let dC = gW._9
1131- let en = gW._10
1132- let eo = gW._11
1133- let dk = gW._12
1134- let dl = gW._13
1135- let dY = invoke(aR, "emit", [em], nil)
1136- if ((dY == dY))
1125+ let gV = fl(toString(cP.caller), toBase58String(cP.transactionId), AttachedPayment(value(cP.payments[0]).assetId, value(cP.payments[0]).amount), cP.payments[1], gO, true, false, true, 0, "")
1126+ let el = gV._2
1127+ let gW = gV._7
1128+ let dB = gV._9
1129+ let em = gV._10
1130+ let en = gV._11
1131+ let dj = gV._12
1132+ let dk = gV._13
1133+ let dX = invoke(aQ, "emit", [el], nil)
1134+ if ((dX == dX))
11371135 then {
1138- let gY = {
1139- let gm = dY
1140- if ($isInstanceOf(gm, "Address"))
1136+ let gX = {
1137+ let gl = dX
1138+ if ($isInstanceOf(gl, "Address"))
11411139 then {
1142- let gZ = gm
1143- invoke(gZ, "emit", [em], nil)
1140+ let gY = gl
1141+ invoke(gY, "emit", [el], nil)
11441142 }
11451143 else unit
11461144 }
1147- if ((gY == gY))
1145+ if ((gX == gX))
11481146 then {
1149- let ha = if ((en > 0))
1150- then invoke(gT, "put", nil, [AttachedPayment(dk, en)])
1147+ let gZ = if ((em > 0))
1148+ then invoke(gS, "put", nil, [AttachedPayment(dj, em)])
11511149 else nil
1152- if ((ha == ha))
1150+ if ((gZ == gZ))
11531151 then {
1154- let hb = if ((eo > 0))
1155- then invoke(gT, "put", nil, [AttachedPayment(dl, eo)])
1152+ let ha = if ((en > 0))
1153+ then invoke(gS, "put", nil, [AttachedPayment(dk, en)])
11561154 else nil
1157- if ((hb == hb))
1155+ if ((ha == ha))
11581156 then {
1159- let hc = if (gQ)
1157+ let hb = if (gP)
11601158 then {
1161- let hd = invoke(gS, "stake", nil, [AttachedPayment(gX, em)])
1162- if ((hd == hd))
1159+ let hc = invoke(gR, "stake", nil, [AttachedPayment(gW, el)])
1160+ if ((hc == hc))
11631161 then nil
11641162 else throw("Strict value is not equal to itself.")
11651163 }
1166- else [ScriptTransfer(cQ.caller, em, gX)]
1167- let he = eT(0, 0, 0)
1168- let gj = he._1
1169- let eK = he._2
1170- let hf = if ((eK >= eS))
1164+ else [ScriptTransfer(cP.caller, el, gW)]
1165+ let hd = eS(0, 0, 0)
1166+ let gi = hd._1
1167+ let eJ = hd._2
1168+ let he = if ((eJ >= eR))
11711169 then true
1172- else aO(makeString(["updated DLp lower than current DLp", toString(eP), toString(eQ), toString(eR), toString(eS), toString(eK), toString(en), toString(eo)], " "))
1173- if ((hf == hf))
1170+ else aN(makeString(["updated DLp lower than current DLp", toString(eO), toString(eP), toString(eQ), toString(eR), toString(eJ), toString(em), toString(en)], " "))
1171+ if ((he == he))
11741172 then {
1175- let hg = value(assetInfo(bm)).quantity
1176- if ((hg == hg))
1177- then ((dC ++ hc) ++ gj)
1173+ let hf = value(assetInfo(bl)).quantity
1174+ if ((hf == hf))
1175+ then ((dB ++ hb) ++ gi)
11781176 else throw("Strict value is not equal to itself.")
11791177 }
11801178 else throw("Strict value is not equal to itself.")
11991197
12001198
12011199
1202-@Callable(cQ)
1203-func putOneTknV2 (fN,gQ) = {
1204- let hh = {
1205- let aT = invoke(aR, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
1206- if ($isInstanceOf(aT, "Boolean"))
1207- then aT
1208- else throw(($getType(aT) + " couldn't be cast to Boolean"))
1200+@Callable(cP)
1201+func putOneTknV2 (fM,gP) = {
1202+ let hg = {
1203+ let aS = invoke(aQ, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
1204+ if ($isInstanceOf(aS, "Boolean"))
1205+ then aS
1206+ else throw(($getType(aS) + " couldn't be cast to Boolean"))
12091207 }
1210- let hi = if (if (if (aW())
1208+ let hh = if (if (if (aV())
12111209 then true
1212- else (bl == r))
1210+ else (bk == q))
12131211 then true
1214- else (bl == t))
1212+ else (bk == s))
12151213 then true
1216- else hh
1217- let gH = [if (if (!(hi))
1214+ else hg
1215+ let gG = [if (if (!(hh))
12181216 then true
1219- else gp(cQ))
1217+ else go(cP))
12201218 then true
1221- else aO("put operation is blocked by admin"), if ((size(cQ.payments) == 1))
1219+ else aN("put operation is blocked by admin"), if ((size(cP.payments) == 1))
12221220 then true
1223- else aO("exactly 1 payment are expected")]
1224- if ((gH == gH))
1221+ else aN("exactly 1 payment are expected")]
1222+ if ((gG == gG))
12251223 then {
1224+ let dj = toBase58String(value(bm))
12261225 let dk = toBase58String(value(bn))
1227- let dl = toBase58String(value(bo))
1228- let dj = bm
1226+ let di = bl
1227+ let fQ = bo
12291228 let fR = bp
1230- let fS = bq
1231- let di = if ((cQ.caller == this))
1232- then cQ.originCaller
1233- else cQ.caller
1234- let fl = value(cQ.payments[0])
1235- let dg = toBase58String(value(fl.assetId))
1236- let dM = fl.amount
1237- let eS = if ((fl.assetId == bn))
1238- then eL(toBigInt(dM), toBigInt(0), toBigInt(0))
1239- else eL(toBigInt(0), toBigInt(dM), toBigInt(0))
1240- if ((eS == eS))
1229+ let dh = if ((cP.caller == this))
1230+ then cP.originCaller
1231+ else cP.caller
1232+ let fk = value(cP.payments[0])
1233+ let df = toBase58String(value(fk.assetId))
1234+ let dL = fk.amount
1235+ let eR = if ((fk.assetId == bm))
1236+ then eK(toBigInt(dL), toBigInt(0), toBigInt(0))
1237+ else eK(toBigInt(0), toBigInt(dL), toBigInt(0))
1238+ if ((eR == eR))
12411239 then {
1242- let hj = fq(dM, dg, toString(di), toBase58String(cQ.transactionId), true)
1243- if ((hj == hj))
1240+ let hi = fp(dL, df, toString(dh), toBase58String(cP.transactionId), true)
1241+ if ((hi == hi))
12441242 then {
1245- let cy = hj._3
1246- let dC = hj._2
1247- let hk = hj._1
1248- let em = if (if ((fN > 0))
1249- then (fN > hk)
1243+ let cx = hi._3
1244+ let dB = hi._2
1245+ let hj = hi._1
1246+ let el = if (if ((fM > 0))
1247+ then (fM > hj)
12501248 else false)
1251- then aO(makeString(["amount to receive is less than ", toString(fN)], ""))
1252- else hk
1253- let gW = invoke(aR, "emit", [em], nil)
1254- if ((gW == gW))
1249+ then aN(makeString(["amount to receive is less than ", toString(fM)], ""))
1250+ else hj
1251+ let gV = invoke(aQ, "emit", [el], nil)
1252+ if ((gV == gV))
12551253 then {
1256- let gY = {
1257- let gm = gW
1258- if ($isInstanceOf(gm, "Address"))
1254+ let gX = {
1255+ let gl = gV
1256+ if ($isInstanceOf(gl, "Address"))
12591257 then {
1260- let gZ = gm
1261- invoke(gZ, "emit", [em], nil)
1258+ let gY = gl
1259+ invoke(gY, "emit", [el], nil)
12621260 }
12631261 else unit
12641262 }
1265- if ((gY == gY))
1263+ if ((gX == gX))
12661264 then {
1267- let hc = if (gQ)
1265+ let hb = if (gP)
12681266 then {
1269- let hd = invoke(bv, "stake", nil, [AttachedPayment(dj, em)])
1270- if ((hd == hd))
1267+ let hc = invoke(bu, "stake", nil, [AttachedPayment(di, el)])
1268+ if ((hc == hc))
12711269 then nil
12721270 else throw("Strict value is not equal to itself.")
12731271 }
1274- else [ScriptTransfer(cQ.caller, em, dj)]
1275- let gd = if ((cy > 0))
1276- then [ScriptTransfer(aY, cy, fromBase58String(dg))]
1272+ else [ScriptTransfer(cP.caller, el, di)]
1273+ let gc = if ((cx > 0))
1274+ then [ScriptTransfer(aX, cx, fromBase58String(df))]
12771275 else nil
1278- let hl = if ((this == aY))
1276+ let hk = if ((this == aX))
12791277 then $Tuple2(0, 0)
12801278 else {
1281- let hm = if ((fl.assetId == bn))
1279+ let hl = if ((fk.assetId == bm))
12821280 then true
12831281 else false
1284- if (hm)
1285- then $Tuple2(-(cy), 0)
1286- else $Tuple2(0, -(cy))
1282+ if (hl)
1283+ then $Tuple2(-(cx), 0)
1284+ else $Tuple2(0, -(cx))
12871285 }
1288- let eU = hl._1
1289- let eV = hl._2
1290- let hn = eT(eU, eV, 0)
1291- let gj = hn._1
1292- let eK = hn._2
1293- let gk = eX(eS, eK)
1294- if ((gk == gk))
1295- then $Tuple2((((dC ++ hc) ++ gd) ++ gj), em)
1286+ let eT = hk._1
1287+ let eU = hk._2
1288+ let hm = eS(eT, eU, 0)
1289+ let gi = hm._1
1290+ let eJ = hm._2
1291+ let gj = eW(eR, eJ)
1292+ if ((gj == gj))
1293+ then $Tuple2((((dB ++ hb) ++ gc) ++ gi), el)
12961294 else throw("Strict value is not equal to itself.")
12971295 }
12981296 else throw("Strict value is not equal to itself.")
13081306
13091307
13101308
1311-@Callable(cQ)
1312-func putForFree (ho) = if ((0 > ho))
1309+@Callable(cP)
1310+func putForFree (hn) = if ((0 > hn))
13131311 then throw("Wrong slpg")
1314- else if ((size(cQ.payments) != 2))
1312+ else if ((size(cP.payments) != 2))
13151313 then throw("2 pmnts expd")
13161314 else {
1317- let hp = fm(toString(cQ.caller), toBase58String(cQ.transactionId), AttachedPayment(value(cQ.payments[0]).assetId, value(cQ.payments[0]).amount), cQ.payments[1], ho, false, false, true, 0, "")
1318- let dC = hp._9
1319- let gU = toBigInt(value(cQ.payments[0]).amount)
1320- let gV = toBigInt(value(cQ.payments[1]).amount)
1321- let eS = eL(gU, gV, toBigInt(0))
1322- if ((eS == eS))
1315+ let ho = fl(toString(cP.caller), toBase58String(cP.transactionId), AttachedPayment(value(cP.payments[0]).assetId, value(cP.payments[0]).amount), cP.payments[1], hn, false, false, true, 0, "")
1316+ let dB = ho._9
1317+ let gT = toBigInt(value(cP.payments[0]).amount)
1318+ let gU = toBigInt(value(cP.payments[1]).amount)
1319+ let eR = eK(gT, gU, toBigInt(0))
1320+ if ((eR == eR))
13231321 then {
1324- let hq = eT(0, 0, 0)
1325- let gj = hq._1
1326- let eK = hq._2
1327- let gk = eX(eS, eK)
1328- if ((gk == gk))
1329- then (dC ++ gj)
1322+ let hp = eS(0, 0, 0)
1323+ let gi = hp._1
1324+ let eJ = hp._2
1325+ let gj = eW(eR, eJ)
1326+ if ((gj == gj))
1327+ then (dB ++ gi)
13301328 else throw("Strict value is not equal to itself.")
13311329 }
13321330 else throw("Strict value is not equal to itself.")
13341332
13351333
13361334
1337-@Callable(cQ)
1335+@Callable(cP)
13381336 func get () = {
1339- let eS = eL(toBigInt(0), toBigInt(0), toBigInt(0))
1340- if ((eS == eS))
1337+ let eR = eK(toBigInt(0), toBigInt(0), toBigInt(0))
1338+ if ((eR == eR))
13411339 then {
1342- let dY = fk(cQ)
1343- let hr = dY._1
1344- let dB = dY._2
1345- let dM = dY._3
1346- let dg = dY._4
1347- let dC = dY._5
1348- let ez = invoke(aR, "burn", [dM], [AttachedPayment(dg, dM)])
1349- if ((ez == ez))
1340+ let dX = fj(cP)
1341+ let hq = dX._1
1342+ let dA = dX._2
1343+ let dL = dX._3
1344+ let df = dX._4
1345+ let dB = dX._5
1346+ let ey = invoke(aQ, "burn", [dL], [AttachedPayment(df, dL)])
1347+ if ((ey == ey))
13501348 then {
1351- let hs = eT(-(hr), -(dB), 0)
1352- let gj = hs._1
1353- let eK = hs._2
1354- let gk = eX(eS, eK)
1355- if ((gk == gk))
1356- then (dC ++ gj)
1349+ let hr = eS(-(hq), -(dA), 0)
1350+ let gi = hr._1
1351+ let eJ = hr._2
1352+ let gj = eW(eR, eJ)
1353+ if ((gj == gj))
1354+ then (dB ++ gi)
13571355 else throw("Strict value is not equal to itself.")
13581356 }
13591357 else throw("Strict value is not equal to itself.")
13631361
13641362
13651363
1366-@Callable(cQ)
1367-func getOneTknV2 (fM,fN) = {
1368- let hh = {
1369- let aT = invoke(aR, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
1370- if ($isInstanceOf(aT, "Boolean"))
1371- then aT
1372- else throw(($getType(aT) + " couldn't be cast to Boolean"))
1364+@Callable(cP)
1365+func getOneTknV2 (fL,fM) = {
1366+ let hg = {
1367+ let aS = invoke(aQ, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
1368+ if ($isInstanceOf(aS, "Boolean"))
1369+ then aS
1370+ else throw(($getType(aS) + " couldn't be cast to Boolean"))
13731371 }
1374- let ht = if (if (aW())
1372+ let hs = if (if (aV())
13751373 then true
1376- else (bl == t))
1374+ else (bk == s))
13771375 then true
1378- else hh
1379- let gH = [if (if (!(ht))
1376+ else hg
1377+ let gG = [if (if (!(hs))
13801378 then true
1381- else gp(cQ))
1379+ else go(cP))
13821380 then true
1383- else aO("get operation is blocked by admin"), if ((size(cQ.payments) == 1))
1381+ else aN("get operation is blocked by admin"), if ((size(cP.payments) == 1))
13841382 then true
1385- else aO("exactly 1 payment are expected")]
1386- if ((gH == gH))
1383+ else aN("exactly 1 payment are expected")]
1384+ if ((gG == gG))
13871385 then {
1388- let hu = fL(fM, fN, cQ.payments, cQ.caller, cQ.originCaller, cQ.transactionId)
1389- let dC = hu._1
1390- let fW = hu._2
1391- $Tuple2(dC, fW)
1386+ let ht = fK(fL, fM, cP.payments, cP.caller, cP.originCaller, cP.transactionId)
1387+ let dB = ht._1
1388+ let fV = ht._2
1389+ $Tuple2(dB, fV)
13921390 }
13931391 else throw("Strict value is not equal to itself.")
13941392 }
13951393
13961394
13971395
1398-@Callable(cQ)
1396+@Callable(cP)
13991397 func refreshDLp () = {
1400- let hv = valueOrElse(getInteger(ar), 0)
1401- let hw = if (((height - hv) >= au))
1398+ let hu = valueOrElse(getInteger(aq), 0)
1399+ let hv = if (((height - hu) >= at))
14021400 then unit
1403- else aO(makeString([toString(au), " blocks have not passed since the previous call"], ""))
1404- if ((hw == hw))
1401+ else aN(makeString([toString(at), " blocks have not passed since the previous call"], ""))
1402+ if ((hv == hv))
14051403 then {
1406- let fe = valueOrErrorMessage(parseBigInt(valueOrElse(getString(this, aq), "0")), aQ("invalid dLp"))
1407- let hx = eT(0, 0, 0)
1408- let hy = hx._1
1409- let eK = hx._2
1410- let eW = if ((fe != eK))
1411- then hy
1412- else aO("nothing to refresh")
1413- $Tuple2(eW, toString(eK))
1404+ let fd = valueOrErrorMessage(parseBigInt(valueOrElse(getString(this, ap), "0")), aP("invalid dLp"))
1405+ let hw = eS(0, 0, 0)
1406+ let hx = hw._1
1407+ let eJ = hw._2
1408+ let eV = if ((fd != eJ))
1409+ then hx
1410+ else aN("nothing to refresh")
1411+ $Tuple2(eV, toString(eJ))
14141412 }
14151413 else throw("Strict value is not equal to itself.")
14161414 }
14171415
14181416
14191417
1420-@Callable(cQ)
1421-func getOneTknV2READONLY (fM,hz) = {
1418+@Callable(cP)
1419+func getOneTknV2READONLY (fL,hy) = {
1420+ let dj = toBase58String(value(bm))
14221421 let dk = toBase58String(value(bn))
1423- let dl = toBase58String(value(bo))
1424- let dj = toBase58String(value(bm))
1425- let cA = [toBigInt(bO(dk)), toBigInt(bO(dl))]
1426- let eJ = toBigInt(valueOrErrorMessage(assetInfo(fromBase58String(dj)), "invalid lp asset").quantity)
1427- let cc = cz(cA)
1428- let cb = (cc - fraction(toBigInt(hz), cc, eJ))
1429- let hA = if ((fM == dk))
1422+ let di = toBase58String(value(bl))
1423+ let cz = [toBigInt(bN(dj)), toBigInt(bN(dk))]
1424+ let eI = toBigInt(valueOrErrorMessage(assetInfo(fromBase58String(di)), "invalid lp asset").quantity)
1425+ let cb = cy(cz)
1426+ let ca = (cb - fraction(toBigInt(hy), cb, eI))
1427+ let hz = if ((fL == dj))
14301428 then 0
1431- else if ((fM == dl))
1429+ else if ((fL == dk))
14321430 then 1
14331431 else throw("invalid out asset id")
1434- let hB = et(cA, hA, cb)
1435- let gA = (cA[hA] - hB)
1436- let gB = max([0, toInt((gA - f))])
1437- let hC = cw(gB, aU)
1438- let fV = hC._1
1439- let cy = hC._2
1440- $Tuple2(nil, $Tuple2(fV, cy))
1432+ let hA = es(cz, hz, ca)
1433+ let gz = (cz[hz] - hA)
1434+ let gA = max([0, toInt((gz - f))])
1435+ let hB = cv(gA, aT)
1436+ let fU = hB._1
1437+ let cx = hB._2
1438+ $Tuple2(nil, $Tuple2(fU, cx))
14411439 }
14421440
14431441
14441442
1445-@Callable(cQ)
1446-func getOneTknV2WithBonusREADONLY (fM,hz) = {
1443+@Callable(cP)
1444+func getOneTknV2WithBonusREADONLY (fL,hy) = {
1445+ let dj = toBase58String(value(bm))
14471446 let dk = toBase58String(value(bn))
1448- let dl = toBase58String(value(bo))
1449- let dj = toBase58String(value(bm))
1450- let dq = bO(dk)
1451- let ds = bO(dl)
1452- let hD = {
1453- let aT = invoke(this, "getOneTknV2READONLY", [fM, hz], nil)
1454- if ($isInstanceOf(aT, "(Int, Int)"))
1455- then aT
1456- else throw(($getType(aT) + " couldn't be cast to (Int, Int)"))
1447+ let di = toBase58String(value(bl))
1448+ let dp = bN(dj)
1449+ let dr = bN(dk)
1450+ let hC = {
1451+ let aS = invoke(this, "getOneTknV2READONLY", [fL, hy], nil)
1452+ if ($isInstanceOf(aS, "(Int, Int)"))
1453+ then aS
1454+ else throw(($getType(aS) + " couldn't be cast to (Int, Int)"))
14571455 }
1458- let fV = hD._1
1459- let cy = hD._2
1460- let dY = de("", dj, hz, this)
1461- let dA = dY._1
1462- let dB = dY._2
1463- let hE = (dA + dB)
1464- let fK = if ((hE == 0))
1465- then if ((fV == 0))
1456+ let fU = hC._1
1457+ let cx = hC._2
1458+ let dX = dd("", di, hy, this)
1459+ let dz = dX._1
1460+ let dA = dX._2
1461+ let hD = (dz + dA)
1462+ let fJ = if ((hD == 0))
1463+ then if ((fU == 0))
14661464 then 0
14671465 else throw("bonus calculation error")
1468- else fraction((fV - hE), a, hE)
1469- $Tuple2(nil, $Tuple3(fV, cy, fK))
1466+ else fraction((fU - hD), a, hD)
1467+ $Tuple2(nil, $Tuple3(fU, cx, fJ))
14701468 }
14711469
14721470
14731471
1474-@Callable(cQ)
1475-func getNoLess (hF,hG) = {
1476- let dY = fk(cQ)
1477- let dA = dY._1
1478- let dB = dY._2
1479- let dM = dY._3
1480- let dg = dY._4
1481- let dC = dY._5
1482- if ((hF > dA))
1483- then throw(((("Failed: " + toString(dA)) + " < ") + toString(hF)))
1484- else if ((hG > dB))
1485- then throw(((("Failed: " + toString(dB)) + " < ") + toString(hG)))
1472+@Callable(cP)
1473+func getNoLess (hE,hF) = {
1474+ let dX = fj(cP)
1475+ let dz = dX._1
1476+ let dA = dX._2
1477+ let dL = dX._3
1478+ let df = dX._4
1479+ let dB = dX._5
1480+ if ((hE > dz))
1481+ then throw(((("Failed: " + toString(dz)) + " < ") + toString(hE)))
1482+ else if ((hF > dA))
1483+ then throw(((("Failed: " + toString(dA)) + " < ") + toString(hF)))
14861484 else {
1487- let eS = eL(toBigInt(0), toBigInt(0), toBigInt(0))
1488- if ((eS == eS))
1485+ let eR = eK(toBigInt(0), toBigInt(0), toBigInt(0))
1486+ if ((eR == eR))
14891487 then {
1490- let hH = invoke(aR, "burn", [dM], [AttachedPayment(dg, dM)])
1491- if ((hH == hH))
1488+ let hG = invoke(aQ, "burn", [dL], [AttachedPayment(df, dL)])
1489+ if ((hG == hG))
14921490 then {
1493- let hI = eT(-(dA), -(dB), 0)
1494- let gj = hI._1
1495- let eK = hI._2
1496- let gk = eX(eS, eK)
1497- if ((gk == gk))
1498- then (dC ++ gj)
1491+ let hH = eS(-(dz), -(dA), 0)
1492+ let gi = hH._1
1493+ let eJ = hH._2
1494+ let gj = eW(eR, eJ)
1495+ if ((gj == gj))
1496+ then (dB ++ gi)
14991497 else throw("Strict value is not equal to itself.")
15001498 }
15011499 else throw("Strict value is not equal to itself.")
15061504
15071505
15081506
1509-@Callable(cQ)
1510-func unstakeAndGet (cx) = {
1511- let hJ = if ((size(cQ.payments) != 0))
1507+@Callable(cP)
1508+func unstakeAndGet (cw) = {
1509+ let hI = if ((size(cP.payments) != 0))
15121510 then throw("No pmnts expd")
15131511 else true
1514- if ((hJ == hJ))
1512+ if ((hI == hI))
15151513 then {
1516- let hK = bt()
1517- let gX = bm
1518- let hL = valueOrErrorMessage(addressFromString(hK[D]), "Wr st addr")
1519- let eS = eL(toBigInt(0), toBigInt(0), toBigInt(0))
1520- if ((eS == eS))
1514+ let hJ = bs()
1515+ let gW = bl
1516+ let hK = valueOrErrorMessage(addressFromString(hJ[C]), "Wr st addr")
1517+ let eR = eK(toBigInt(0), toBigInt(0), toBigInt(0))
1518+ if ((eR == eR))
15211519 then {
1522- let hM = invoke(hL, "unstake", [toBase58String(gX), cx], nil)
1523- if ((hM == hM))
1520+ let hL = invoke(hK, "unstake", [toBase58String(gW), cw], nil)
1521+ if ((hL == hL))
15241522 then {
1525- let dY = de(toBase58String(cQ.transactionId), toBase58String(gX), cx, cQ.caller)
1526- let dA = dY._1
1527- let dB = dY._2
1528- let do = parseIntValue(dY._9)
1529- let dC = dY._10
1530- let hN = if (if (aW())
1523+ let dX = dd(toBase58String(cP.transactionId), toBase58String(gW), cw, cP.caller)
1524+ let dz = dX._1
1525+ let dA = dX._2
1526+ let dn = parseIntValue(dX._9)
1527+ let dB = dX._10
1528+ let hM = if (if (aV())
15311529 then true
1532- else (do == t))
1533- then throw(("Blocked: " + toString(do)))
1530+ else (dn == s))
1531+ then throw(("Blocked: " + toString(dn)))
15341532 else true
1535- if ((hN == hN))
1533+ if ((hM == hM))
15361534 then {
1537- let hO = invoke(aR, "burn", [cx], [AttachedPayment(gX, cx)])
1538- if ((hO == hO))
1535+ let hN = invoke(aQ, "burn", [cw], [AttachedPayment(gW, cw)])
1536+ if ((hN == hN))
15391537 then {
1540- let hP = eT(-(dA), -(dB), 0)
1541- let gj = hP._1
1542- let eK = hP._2
1543- let gk = eX(eS, eK)
1544- if ((gk == gk))
1545- then (dC ++ gj)
1538+ let hO = eS(-(dz), -(dA), 0)
1539+ let gi = hO._1
1540+ let eJ = hO._2
1541+ let gj = eW(eR, eJ)
1542+ if ((gj == gj))
1543+ then (dB ++ gi)
15461544 else throw("Strict value is not equal to itself.")
15471545 }
15481546 else throw("Strict value is not equal to itself.")
15581556
15591557
15601558
1561-@Callable(cQ)
1562-func unstakeAndGetNoLess (hQ,hR,hG) = {
1563- let ht = if (aW())
1559+@Callable(cP)
1560+func unstakeAndGetNoLess (hP,hQ,hF) = {
1561+ let hs = if (aV())
15641562 then true
1565- else (bl == t)
1566- let gH = [if (!(ht))
1563+ else (bk == s)
1564+ let gG = [if (!(hs))
15671565 then true
1568- else throw("get operation is blocked by admin"), if ((size(cQ.payments) == 0))
1566+ else throw("get operation is blocked by admin"), if ((size(cP.payments) == 0))
15691567 then true
15701568 else throw("no payments are expected")]
1571- if ((gH == gH))
1569+ if ((gG == gG))
15721570 then {
1573- let eS = eL(toBigInt(0), toBigInt(0), toBigInt(0))
1574- if ((eS == eS))
1571+ let eR = eK(toBigInt(0), toBigInt(0), toBigInt(0))
1572+ if ((eR == eR))
15751573 then {
1576- let hM = invoke(bv, "unstake", [toBase58String(bm), hQ], nil)
1577- if ((hM == hM))
1574+ let hL = invoke(bu, "unstake", [toBase58String(bl), hP], nil)
1575+ if ((hL == hL))
15781576 then {
1579- let hS = de(toBase58String(cQ.transactionId), toBase58String(bm), hQ, cQ.caller)
1580- let dA = hS._1
1581- let dB = hS._2
1582- let dC = hS._10
1583- let hT = [if ((dA >= hR))
1577+ let hR = dd(toBase58String(cP.transactionId), toBase58String(bl), hP, cP.caller)
1578+ let dz = hR._1
1579+ let dA = hR._2
1580+ let dB = hR._10
1581+ let hS = [if ((dz >= hQ))
15841582 then true
1585- else throw(makeString(["amount asset amount to receive is less than ", toString(hR)], "")), if ((dB >= hG))
1583+ else throw(makeString(["amount asset amount to receive is less than ", toString(hQ)], "")), if ((dA >= hF))
15861584 then true
1587- else throw(makeString(["price asset amount to receive is less than ", toString(hG)], ""))]
1588- if ((hT == hT))
1585+ else throw(makeString(["price asset amount to receive is less than ", toString(hF)], ""))]
1586+ if ((hS == hS))
15891587 then {
1590- let hH = invoke(aR, "burn", [hQ], [AttachedPayment(bm, hQ)])
1591- if ((hH == hH))
1588+ let hG = invoke(aQ, "burn", [hP], [AttachedPayment(bl, hP)])
1589+ if ((hG == hG))
15921590 then {
1593- let hU = eT(-(dA), -(dB), 0)
1594- let gj = hU._1
1595- let eK = hU._2
1596- let gk = eX(eS, eK)
1597- if ((gk == gk))
1598- then (dC ++ gj)
1591+ let hT = eS(-(dz), -(dA), 0)
1592+ let gi = hT._1
1593+ let eJ = hT._2
1594+ let gj = eW(eR, eJ)
1595+ if ((gj == gj))
1596+ then (dB ++ gi)
15991597 else throw("Strict value is not equal to itself.")
16001598 }
16011599 else throw("Strict value is not equal to itself.")
16111609
16121610
16131611
1614-@Callable(cQ)
1615-func unstakeAndGetOneTknV2 (hQ,fM,fN) = {
1616- let hh = {
1617- let aT = invoke(aR, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
1618- if ($isInstanceOf(aT, "Boolean"))
1619- then aT
1620- else throw(($getType(aT) + " couldn't be cast to Boolean"))
1612+@Callable(cP)
1613+func unstakeAndGetOneTknV2 (hP,fL,fM) = {
1614+ let hg = {
1615+ let aS = invoke(aQ, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
1616+ if ($isInstanceOf(aS, "Boolean"))
1617+ then aS
1618+ else throw(($getType(aS) + " couldn't be cast to Boolean"))
16211619 }
1622- let ht = if (if (aW())
1620+ let hs = if (if (aV())
16231621 then true
1624- else (bl == t))
1622+ else (bk == s))
16251623 then true
1626- else hh
1627- let gH = [if (if (!(ht))
1624+ else hg
1625+ let gG = [if (if (!(hs))
16281626 then true
1629- else gp(cQ))
1627+ else go(cP))
16301628 then true
1631- else aO("get operation is blocked by admin"), if ((size(cQ.payments) == 0))
1629+ else aN("get operation is blocked by admin"), if ((size(cP.payments) == 0))
16321630 then true
1633- else aO("no payments are expected")]
1634- if ((gH == gH))
1631+ else aN("no payments are expected")]
1632+ if ((gG == gG))
16351633 then {
1636- let hK = bt()
1637- let gX = bm
1638- let hL = valueOrErrorMessage(addressFromString(hK[D]), "Wr st addr")
1639- let hM = invoke(hL, "unstake", [toBase58String(gX), hQ], nil)
1640- if ((hM == hM))
1634+ let hJ = bs()
1635+ let gW = bl
1636+ let hK = valueOrErrorMessage(addressFromString(hJ[C]), "Wr st addr")
1637+ let hL = invoke(hK, "unstake", [toBase58String(gW), hP], nil)
1638+ if ((hL == hL))
16411639 then {
1642- let hV = fL(fM, fN, [AttachedPayment(gX, hQ)], cQ.caller, cQ.originCaller, cQ.transactionId)
1643- let dC = hV._1
1644- let fW = hV._2
1645- $Tuple2(dC, fW)
1640+ let hU = fK(fL, fM, [AttachedPayment(gW, hP)], cP.caller, cP.originCaller, cP.transactionId)
1641+ let dB = hU._1
1642+ let fV = hU._2
1643+ $Tuple2(dB, fV)
16461644 }
16471645 else throw("Strict value is not equal to itself.")
16481646 }
16511649
16521650
16531651
1654-@Callable(cQ)
1655-func putOneTknV2WithBonusREADONLY (hW,hX) = {
1656- let hY = fq(hW, hX, "", "", true)
1657- let fF = hY._1
1658- let dC = hY._2
1659- let cy = hY._3
1660- let fK = hY._4
1661- $Tuple2(nil, $Tuple3(fF, cy, fK))
1652+@Callable(cP)
1653+func putOneTknV2WithBonusREADONLY (hV,hW) = {
1654+ let hX = fp(hV, hW, "", "", true)
1655+ let fE = hX._1
1656+ let dB = hX._2
1657+ let cx = hX._3
1658+ let fJ = hX._4
1659+ $Tuple2(nil, $Tuple3(fE, cx, fJ))
16621660 }
16631661
16641662
16651663
1666-@Callable(cQ)
1667-func putOneTknV2WithoutTakeFeeREADONLY (hW,hX) = {
1668- let hZ = fq(hW, hX, "", "", false)
1669- let fF = hZ._1
1670- let dC = hZ._2
1671- let cy = hZ._3
1672- let fK = hZ._4
1673- $Tuple2(nil, $Tuple3(fF, cy, fK))
1664+@Callable(cP)
1665+func putOneTknV2WithoutTakeFeeREADONLY (hV,hW) = {
1666+ let hY = fp(hV, hW, "", "", false)
1667+ let fE = hY._1
1668+ let dB = hY._2
1669+ let cx = hY._3
1670+ let fJ = hY._4
1671+ $Tuple2(nil, $Tuple3(fE, cx, fJ))
16741672 }
16751673
16761674
16771675
1678-@Callable(cQ)
1679-func activate (ia,ib) = if ((toString(cQ.caller) != toString(aR)))
1676+@Callable(cP)
1677+func activate (hZ,ia) = if ((toString(cP.caller) != toString(aQ)))
16801678 then throw("denied")
1681- else $Tuple2([StringEntry(ak(), ia), StringEntry(al(), ib)], "success")
1679+ else $Tuple2([StringEntry(aj(), hZ), StringEntry(ak(), ia)], "success")
16821680
16831681
16841682
1685-@Callable(cQ)
1686-func setS (ic,hN) = if ((toString(cQ.caller) != aK(this, an())))
1687- then go
1688- else [StringEntry(ic, hN)]
1683+@Callable(cP)
1684+func setS (ib,hM) = if ((toString(cP.caller) != aJ(this, am())))
1685+ then gn
1686+ else [StringEntry(ib, hM)]
16891687
16901688
16911689
1692-@Callable(cQ)
1693-func setI (ic,hN) = if ((toString(cQ.caller) != aK(this, an())))
1694- then go
1695- else [IntegerEntry(ic, hN)]
1690+@Callable(cP)
1691+func setI (ib,hM) = if ((toString(cP.caller) != aJ(this, am())))
1692+ then gn
1693+ else [IntegerEntry(ib, hM)]
16961694
16971695
16981696
1699-@Callable(cQ)
1700-func getPoolConfigWrapperREADONLY () = $Tuple2(nil, aZ())
1697+@Callable(cP)
1698+func getPoolConfigWrapperREADONLY () = $Tuple2(nil, aY())
17011699
17021700
17031701
1704-@Callable(cQ)
1705-func getAccBalanceWrapperREADONLY (bP) = $Tuple2(nil, bO(bP))
1702+@Callable(cP)
1703+func getAccBalanceWrapperREADONLY (bO) = $Tuple2(nil, bN(bO))
17061704
17071705
17081706
1709-@Callable(cQ)
1710-func calcPricesWrapperREADONLY (ci,cj,cn) = {
1711- let id = cm(ci, cj, cn)
1712- $Tuple2(nil, [toString(id[0]), toString(id[1]), toString(id[2])])
1707+@Callable(cP)
1708+func calcPricesWrapperREADONLY (ch,ci,cm) = {
1709+ let ic = cl(ch, ci, cm)
1710+ $Tuple2(nil, [toString(ic[0]), toString(ic[1]), toString(ic[2])])
17131711 }
17141712
17151713
17161714
1717-@Callable(cQ)
1718-func fromX18WrapperREADONLY (N,ie) = $Tuple2(nil, M(parseBigIntValue(N), ie))
1715+@Callable(cP)
1716+func fromX18WrapperREADONLY (M,id) = $Tuple2(nil, L(parseBigIntValue(M), id))
17191717
17201718
17211719
1722-@Callable(cQ)
1723-func toX18WrapperREADONLY (J,K) = $Tuple2(nil, toString(I(J, K)))
1720+@Callable(cP)
1721+func toX18WrapperREADONLY (I,J) = $Tuple2(nil, toString(H(I, J)))
17241722
17251723
17261724
1727-@Callable(cQ)
1728-func calcPriceBigIntWrapperREADONLY (bR,bS) = $Tuple2(nil, toString(bQ(parseBigIntValue(bR), parseBigIntValue(bS))))
1725+@Callable(cP)
1726+func calcPriceBigIntWrapperREADONLY (bQ,bR) = $Tuple2(nil, toString(bP(parseBigIntValue(bQ), parseBigIntValue(bR))))
17291727
17301728
17311729
1732-@Callable(cQ)
1733-func estimatePutOperationWrapperREADONLY (df,bX,dE,dF,dG,dH,if,dI,dJ) = $Tuple2(nil, dD(df, bX, dE, dF, dG, dH, if, dI, dJ, true, false, 0, ""))
1730+@Callable(cP)
1731+func estimatePutOperationWrapperREADONLY (de,bW,dD,dE,dF,dG,ie,dH,dI) = $Tuple2(nil, dC(de, bW, dD, dE, dF, dG, ie, dH, dI, true, false, 0, ""))
17341732
17351733
17361734
1737-@Callable(cQ)
1738-func estimateGetOperationWrapperREADONLY (df,ig,dh,if) = {
1739- let dY = de(df, ig, dh, addressFromStringValue(if))
1740- $Tuple2(nil, $Tuple10(dY._1, dY._2, dY._3, dY._4, dY._5, dY._6, dY._7, toString(dY._8), dY._9, dY._10))
1735+@Callable(cP)
1736+func estimateGetOperationWrapperREADONLY (de,if,dg,ie) = {
1737+ let dX = dd(de, if, dg, addressFromStringValue(ie))
1738+ $Tuple2(nil, $Tuple10(dX._1, dX._2, dX._3, dX._4, dX._5, dX._6, dX._7, toString(dX._8), dX._9, dX._10))
17411739 }
17421740
17431741
1744-@Verifier(ih)
1745-func ii () = {
1746- let ij = {
1747- let gm = gl()
1748- if ($isInstanceOf(gm, "ByteVector"))
1742+@Verifier(ig)
1743+func ih () = {
1744+ let ii = {
1745+ let gl = gk()
1746+ if ($isInstanceOf(gl, "ByteVector"))
17491747 then {
1750- let gq = gm
1751- gq
1748+ let gp = gl
1749+ gp
17521750 }
1753- else if ($isInstanceOf(gm, "Unit"))
1754- then ih.senderPublicKey
1751+ else if ($isInstanceOf(gl, "Unit"))
1752+ then ig.senderPublicKey
17551753 else throw("Match error")
17561754 }
1757- let gm = ih
1758- if ($isInstanceOf(gm, "Order"))
1755+ let gl = ig
1756+ if ($isInstanceOf(gl, "Order"))
17591757 then {
1760- let fa = gm
1761- let ik = aX()
1762- let il = eZ(fa)
1763- let aG = il._1
1764- let aH = il._2
1765- let aI = sigVerify(fa.bodyBytes, fa.proofs[0], fa.senderPublicKey)
1766- let aJ = sigVerify(fa.bodyBytes, fa.proofs[1], ik)
1767- if (if (if (aG)
1758+ let eZ = gl
1759+ let ij = aW()
1760+ let ik = eY(eZ)
1761+ let aF = ik._1
1762+ let aG = ik._2
1763+ let aH = sigVerify(eZ.bodyBytes, eZ.proofs[0], eZ.senderPublicKey)
1764+ let aI = sigVerify(eZ.bodyBytes, eZ.proofs[1], ij)
1765+ if (if (if (aF)
1766+ then aH
1767+ else false)
17681768 then aI
17691769 else false)
1770- then aJ
1771- else false)
17721770 then true
1773- else aF(aG, aH, aI, aJ)
1771+ else aE(aF, aG, aH, aI)
17741772 }
1775- else if ($isInstanceOf(gm, "SetScriptTransaction"))
1773+ else if ($isInstanceOf(gl, "SetScriptTransaction"))
17761774 then {
1777- let cD = gm
1778- if (sigVerify(ih.bodyBytes, ih.proofs[0], ij))
1775+ let cC = gl
1776+ if (sigVerify(ig.bodyBytes, ig.proofs[0], ii))
17791777 then true
17801778 else {
1781- let im = blake2b256(value(cD.script))
1782- let in = fromBase64String(value(getString(aR, aD())))
1783- let io = scriptHash(this)
1784- if ((in == im))
1785- then (io != im)
1779+ let il = blake2b256(value(cC.script))
1780+ let im = fromBase64String(value(getString(aQ, aC())))
1781+ let in = scriptHash(this)
1782+ if ((im == il))
1783+ then (in != il)
17861784 else false
17871785 }
17881786 }
1789- else sigVerify(ih.bodyBytes, ih.proofs[0], ij)
1787+ else sigVerify(ig.bodyBytes, ig.proofs[0], ii)
17901788 }
17911789
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 6 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let a = 100000000
55
66 let b = toBigInt(100000000)
77
88 let c = toBigInt(1000000000000000000)
99
1010 let d = toBigInt(0)
1111
1212 let e = toBigInt(0)
1313
1414 let f = toBigInt(1)
1515
1616 let g = toBigInt(2)
1717
1818 let h = toBigInt(3)
1919
2020 let i = toBigInt(4)
2121
2222 let j = toBigInt((a - ((a * 1) / a)))
2323
2424 let k = "WAVES"
2525
26-let l = 1
26+let l = "100"
2727
28-let m = "100"
28+let m = "1"
2929
30-let n = "1"
30+let n = "__"
3131
32-let o = "__"
32+let o = ""
3333
34-let p = ""
34+let p = 1
3535
36-let q = 1
36+let q = 2
3737
38-let r = 2
38+let r = 3
3939
40-let s = 3
40+let s = 4
4141
42-let t = 4
42+let t = 1
4343
44-let u = 1
44+let u = 2
4545
46-let v = 2
46+let v = 3
4747
48-let w = 3
48+let w = 4
4949
50-let x = 4
50+let x = 5
5151
52-let y = 5
52+let y = 6
5353
54-let z = 6
54+let z = 7
5555
56-let A = 7
56+let A = 8
5757
58-let B = 8
58+let B = 9
5959
60-let C = 9
60+let C = 1
6161
62-let D = 1
62+let D = 6
6363
64-let E = 6
64+let E = 7
6565
66-let F = 7
66+let F = 10
6767
68-let G = 10
68+let G = fraction(10, a, 10000)
6969
70-let H = fraction(10, a, 10000)
71-
72-func I (J,K) = fraction(toBigInt(J), c, toBigInt(K))
70+func H (I,J) = fraction(toBigInt(I), c, toBigInt(J))
7371
7472
75-func L (J,K) = fraction(J, c, K)
73+func K (I,J) = fraction(I, c, J)
7674
7775
78-func M (N,O) = toInt(fraction(N, toBigInt(O), c))
76+func L (M,N) = toInt(fraction(M, toBigInt(N), c))
7977
8078
81-func P (N,O,Q) = toInt(fraction(N, toBigInt(O), c, Q))
79+func O (M,N,P) = toInt(fraction(M, toBigInt(N), c, P))
8280
8381
84-func R (J,K) = fraction(J, c, toBigInt(K))
82+func Q (I,J) = fraction(I, c, toBigInt(J))
8583
8684
87-func S (N,O) = fraction(N, toBigInt(O), c)
85+func R (M,N) = fraction(M, toBigInt(N), c)
8886
8987
90-func T (U,V,W) = fraction(U, V, W)
88+func S (T,U,V) = fraction(T, U, V)
9189
9290
93-func X (N) = if ((d > N))
94- then -(N)
95- else N
91+func W (M) = if ((d > M))
92+ then -(M)
93+ else M
9694
9795
98-func Y (N) = if ((d > N))
99- then -(N)
100- else N
96+func X (M) = if ((d > M))
97+ then -(M)
98+ else M
10199
102100
103-func Z () = "%s__factoryContract"
101+func Y () = "%s__factoryContract"
104102
105103
106-func aa () = "%s__managerPublicKey"
104+func Z () = "%s__managerPublicKey"
107105
108106
109-func ab () = "%s__pendingManagerPublicKey"
107+func aa () = "%s__pendingManagerPublicKey"
110108
111109
112-func ac () = "%s%s__price__last"
110+func ab () = "%s%s__price__last"
113111
114112
115-func ad (ae,af) = makeString(["%s%s%d%d__price__history", toString(ae), toString(af)], o)
113+func ac (ad,ae) = makeString(["%s%s%d%d__price__history", toString(ad), toString(ae)], n)
116114
117115
118-func ag (ah,ai) = ((("%s%s%s__P__" + ah) + "__") + ai)
116+func af (ag,ah) = ((("%s%s%s__P__" + ag) + "__") + ah)
119117
120118
121-func aj (ah,ai) = ((("%s%s%s__G__" + ah) + "__") + ai)
119+func ai (ag,ah) = ((("%s%s%s__G__" + ag) + "__") + ah)
122120
123121
124-func ak () = "%s__amountAsset"
122+func aj () = "%s__amountAsset"
125123
126124
127-func al () = "%s__priceAsset"
125+func ak () = "%s__priceAsset"
128126
129127
130-func am () = "%s__amp"
128+func al () = "%s__amp"
131129
132130
133-func an () = "%s__addonAddr"
131+func am () = "%s__addonAddr"
134132
135133
136-let ao = "%s__fee"
134+let an = "%s__fee"
137135
138-let ap = valueOrElse(getInteger(this, ao), H)
136+let ao = valueOrElse(getInteger(this, an), G)
139137
140-let aq = makeString(["%s", "dLp"], o)
138+let ap = makeString(["%s", "dLp"], n)
141139
142-let ar = makeString(["%s", "dLpRefreshedHeight"], o)
140+let aq = makeString(["%s", "dLpRefreshedHeight"], n)
143141
144-let as = makeString(["%s", "refreshDLpDelay"], o)
142+let ar = makeString(["%s", "refreshDLpDelay"], n)
145143
146-let at = 30
144+let as = 30
147145
148-let au = valueOrElse(getInteger(this, as), at)
146+let at = valueOrElse(getInteger(this, ar), as)
149147
150-func av () = "%s__factoryConfig"
148+func au () = "%s__factoryConfig"
151149
152150
153-func aw () = "%s%s__matcher__publicKey"
151+func av () = "%s%s__matcher__publicKey"
154152
155153
156-func ax (ay,az) = (((("%d%d%s__" + ay) + "__") + az) + "__config")
154+func aw (ax,ay) = (((("%d%d%s__" + ax) + "__") + ay) + "__config")
157155
158156
159-func aA (aB) = ("%s%s%s__mappings__baseAsset2internalId__" + aB)
157+func az (aA) = ("%s%s%s__mappings__baseAsset2internalId__" + aA)
160158
161159
162-func aC () = "%s__shutdown"
160+func aB () = "%s__shutdown"
163161
164162
165-func aD () = "%s__allowedLpStableScriptHash"
163+func aC () = "%s__allowedLpStableScriptHash"
166164
167165
168-func aE () = "%s__feeCollectorAddress"
166+func aD () = "%s__feeCollectorAddress"
169167
170168
171-func aF (aG,aH,aI,aJ) = throw((((((((("order validation failed: orderValid=" + toString(aG)) + " (") + aH) + ")") + " senderValid=") + toString(aI)) + " matcherValid=") + toString(aJ)))
169+func aE (aF,aG,aH,aI) = throw((((((((("order validation failed: orderValid=" + toString(aF)) + " (") + aG) + ")") + " senderValid=") + toString(aH)) + " matcherValid=") + toString(aI)))
172170
173171
174-func aK (aL,aM) = valueOrErrorMessage(getString(aL, aM), makeString(["mandatory ", toString(aL), ".", aM, " not defined"], ""))
172+func aJ (aK,aL) = valueOrErrorMessage(getString(aK, aL), makeString(["mandatory ", toString(aK), ".", aL, " not defined"], ""))
175173
176174
177-func aN (aL,aM) = valueOrErrorMessage(getInteger(aL, aM), makeString(["mandatory ", toString(aL), ".", aM, " not defined"], ""))
175+func aM (aK,aL) = valueOrErrorMessage(getInteger(aK, aL), makeString(["mandatory ", toString(aK), ".", aL, " not defined"], ""))
178176
179177
180-func aO (aP) = throw(makeString(["lp_stable.ride:", aP], " "))
178+func aN (aO) = throw(makeString(["lp_stable.ride:", aO], " "))
181179
182180
183-func aQ (aP) = makeString(["lp_stable.ride:", aP], " ")
181+func aP (aO) = makeString(["lp_stable.ride:", aO], " ")
184182
185183
186-let aR = addressFromStringValue(aK(this, Z()))
184+let aQ = addressFromStringValue(aJ(this, Y()))
187185
188-let aS = {
189- let aT = invoke(aR, "getInFeeREADONLY", [toString(this)], nil)
190- if ($isInstanceOf(aT, "Int"))
191- then aT
192- else throw(($getType(aT) + " couldn't be cast to Int"))
186+let aR = {
187+ let aS = invoke(aQ, "getInFeeREADONLY", [toString(this)], nil)
188+ if ($isInstanceOf(aS, "Int"))
189+ then aS
190+ else throw(($getType(aS) + " couldn't be cast to Int"))
193191 }
194192
195-let aU = {
196- let aT = invoke(aR, "getOutFeeREADONLY", [toString(this)], nil)
197- if ($isInstanceOf(aT, "Int"))
198- then aT
199- else throw(($getType(aT) + " couldn't be cast to Int"))
193+let aT = {
194+ let aS = invoke(aQ, "getOutFeeREADONLY", [toString(this)], nil)
195+ if ($isInstanceOf(aS, "Int"))
196+ then aS
197+ else throw(($getType(aS) + " couldn't be cast to Int"))
200198 }
201199
202-let aV = aK(this, am())
200+let aU = aJ(this, al())
203201
204-func aW () = valueOrElse(getBoolean(aR, aC()), false)
202+func aV () = valueOrElse(getBoolean(aQ, aB()), false)
205203
206204
207-func aX () = fromBase58String(aK(aR, aw()))
205+func aW () = fromBase58String(aJ(aQ, av()))
208206
209207
210-let aY = addressFromStringValue(aK(aR, aE()))
208+let aX = addressFromStringValue(aJ(aQ, aD()))
211209
212-func aZ () = {
213- let ba = aK(this, ak())
214- let bb = aK(this, al())
215- let bc = aN(aR, aA(bb))
216- let ay = aN(aR, aA(ba))
217- split(aK(aR, ax(toString(ay), toString(bc))), o)
210+func aY () = {
211+ let aZ = aJ(this, aj())
212+ let ba = aJ(this, ak())
213+ let bb = aM(aQ, az(ba))
214+ let ax = aM(aQ, az(aZ))
215+ split(aJ(aQ, aw(toString(ax), toString(bb))), n)
218216 }
219217
220218
221-func bd (be) = if ((be == k))
219+func bc (bd) = if ((bd == k))
222220 then unit
223- else fromBase58String(be)
221+ else fromBase58String(bd)
224222
225223
226-func bf (be) = if ((be == unit))
224+func be (bd) = if ((bd == unit))
227225 then k
228- else toBase58String(value(be))
226+ else toBase58String(value(bd))
229227
230228
231-func bg (bh) = $Tuple9(addressFromStringValue(bh[u]), parseIntValue(bh[v]), fromBase58String(bh[w]), bd(bh[x]), bd(bh[y]), parseIntValue(bh[z]), parseIntValue(bh[A]), fromBase58String(bh[B]), fromBase58String(bh[C]))
229+func bf (bg) = $Tuple9(addressFromStringValue(bg[t]), parseIntValue(bg[u]), fromBase58String(bg[v]), bc(bg[w]), bc(bg[x]), parseIntValue(bg[y]), parseIntValue(bg[z]), fromBase58String(bg[A]), fromBase58String(bg[B]))
232230
233231
234-let bi = bg(aZ())
232+let bh = bf(aY())
235233
236-let bj = bi
234+let bi = bh
237235
238-let bk = bj._1
236+let bj = bi._1
239237
240-let bl = bj._2
238+let bk = bi._2
241239
242-let bm = bj._3
240+let bl = bi._3
243241
244-let bn = bj._4
242+let bm = bi._4
245243
246-let bo = bj._5
244+let bn = bi._5
247245
248-let bp = bj._6
246+let bo = bi._6
249247
250-let bq = bj._7
248+let bp = bi._7
251249
252-let br = bj._8
250+let bq = bi._8
253251
254-let bs = bj._9
252+let br = bi._9
255253
256-func bt () = split(aK(aR, av()), o)
254+func bs () = split(aJ(aQ, au()), n)
257255
258256
259-let bu = bt()
257+let bt = bs()
260258
261-let bv = valueOrErrorMessage(addressFromString(bu[D]), "Invalid staking contract address")
259+let bu = valueOrErrorMessage(addressFromString(bt[C]), "Invalid staking contract address")
262260
263-let bw = valueOrErrorMessage(addressFromString(bu[F]), "Invalid slipage contract address")
261+let bv = valueOrErrorMessage(addressFromString(bt[E]), "Invalid slipage contract address")
264262
265-let bx = valueOrErrorMessage(addressFromString(bu[G]), "Invalid gwx contract address")
263+let bw = valueOrErrorMessage(addressFromString(bt[F]), "Invalid gwx contract address")
266264
267-let by = valueOrErrorMessage(addressFromString(bu[E]), "Invalid gwx contract address")
265+let bx = valueOrErrorMessage(addressFromString(bt[D]), "Invalid gwx contract address")
268266
269-func bz (bA,bB,bC,bD,bE,bF,bG,bH,bI,bJ) = makeString(["%d%d%d%d%d%d%d%d%d%d", toString(bA), toString(bB), toString(bC), toString(bD), toString(bE), toString(bF), toString(bG), toString(bH), toString(bI), toString(bJ)], o)
267+func by (bz,bA,bB,bC,bD,bE,bF,bG,bH,bI) = makeString(["%d%d%d%d%d%d%d%d%d%d", toString(bz), toString(bA), toString(bB), toString(bC), toString(bD), toString(bE), toString(bF), toString(bG), toString(bH), toString(bI)], n)
270268
271269
272-func bK (bL,bM,bN,bD,bG,bH) = makeString(["%d%d%d%d%d%d", toString(bL), toString(bM), toString(bN), toString(bD), toString(bG), toString(bH)], o)
270+func bJ (bK,bL,bM,bC,bF,bG) = makeString(["%d%d%d%d%d%d", toString(bK), toString(bL), toString(bM), toString(bC), toString(bF), toString(bG)], n)
273271
274272
275-func bO (bP) = if ((bP == "WAVES"))
273+func bN (bO) = if ((bO == "WAVES"))
276274 then wavesBalance(this).available
277- else assetBalance(this, fromBase58String(bP))
275+ else assetBalance(this, fromBase58String(bO))
278276
279277
280-func bQ (bR,bS) = fraction(bR, c, bS)
278+func bP (bQ,bR) = fraction(bQ, c, bR)
281279
282280
283-func bT (bR,bS,Q) = fraction(bR, c, bS, Q)
281+func bS (bQ,bR,P) = fraction(bQ, c, bR, P)
284282
285283
286-func bU (bV,bW,bX) = {
287- let bY = fraction((bV - bW), b, bW)
288- let bZ = ((bX - X(bY)) > d)
289- if (!(bZ))
290- then throw(("Big slpg: " + toString(bY)))
291- else $Tuple2(bZ, min([bV, bW]))
284+func bT (bU,bV,bW) = {
285+ let bX = fraction((bU - bV), b, bV)
286+ let bY = ((bW - W(bX)) > d)
287+ if (!(bY))
288+ then throw(("Big slpg: " + toString(bX)))
289+ else $Tuple2(bY, min([bU, bV]))
292290 }
293291
294292
295-func ca (cb,cc,cd) = {
296- let bY = fraction(cc, b, cb)
297- let ce = (cd > bY)
298- if (if (ce)
293+func bZ (ca,cb,cc) = {
294+ let bX = fraction(cb, b, ca)
295+ let cd = (cc > bX)
296+ if (if (cd)
299297 then true
300- else (cc > cb))
301- then throw(((((((toString(cc) + " ") + toString(cb)) + " ") + toString(bY)) + " ") + toString(cd)))
302- else ce
298+ else (cb > ca))
299+ then throw(((((((toString(cb) + " ") + toString(ca)) + " ") + toString(bX)) + " ") + toString(cc)))
300+ else cd
303301 }
304302
305303
306-func cf (cg,ch,ci,cj) = {
307- let ck = I(ci, cg)
308- let cl = I(cj, ch)
309- bQ(cl, ck)
304+func ce (cf,cg,ch,ci) = {
305+ let cj = H(ch, cf)
306+ let ck = H(ci, cg)
307+ bP(ck, cj)
310308 }
311309
312310
313-func cm (ci,cj,cn) = {
311+func cl (ch,ci,cm) = {
312+ let cn = bo
314313 let co = bp
315- let cp = bq
316- let cq = cf(co, cp, ci, cj)
317- let bS = I(ci, co)
318- let bR = I(cj, cp)
319- let cr = I(cn, a)
320- let cs = bQ(bS, cr)
321- let ct = bQ(bR, cr)
322-[cq, cs, ct]
314+ let cp = ce(cn, co, ch, ci)
315+ let bR = H(ch, cn)
316+ let bQ = H(ci, co)
317+ let cq = H(cm, a)
318+ let cr = bP(bR, cq)
319+ let cs = bP(bQ, cq)
320+[cp, cr, cs]
323321 }
324322
325323
326-func cu (ci,cj,cn) = {
327- let cv = cm(ci, cj, cn)
328-[M(cv[0], a), M(cv[1], a), M(cv[2], a)]
324+func ct (ch,ci,cm) = {
325+ let cu = cl(ch, ci, cm)
326+[L(cu[0], a), L(cu[1], a), L(cu[2], a)]
329327 }
330328
331329
332-func cw (cx,ap) = {
333- let cy = if ((ap == 0))
330+func cv (cw,ao) = {
331+ let cx = if ((ao == 0))
334332 then 0
335- else fraction(cx, ap, a)
336- $Tuple2((cx - cy), cy)
333+ else fraction(cw, ao, a)
334+ $Tuple2((cw - cx), cx)
337335 }
338336
339337
340-func cz (cA) = {
341- let cB = cA[0]
342- let cC = cA[1]
343- let cD = (cB + cC)
344- if ((cD == e))
338+func cy (cz) = {
339+ let cA = cz[0]
340+ let cB = cz[1]
341+ let cC = (cA + cB)
342+ if ((cC == e))
345343 then e
346344 else {
347- let cE = parseIntValue(aV)
348- let cF = (cE * 2)
349- let cv = fraction(cB, cC, f)
350- let cG = fraction(cv, i, f)
351- let cH = fraction(toBigInt(cF), cD, f)
352- let cI = toBigInt((cF - 1))
353- func cJ (cK) = {
354- let cL = fraction(cK, cK, f)
355- let cM = fraction(cL, cK, f)
356- let cN = fraction(cM, f, cG)
357- fraction((cH + fraction(cN, g, f)), cK, (fraction(cI, cK, f) + fraction(h, cN, f)))
345+ let cD = parseIntValue(aU)
346+ let cE = (cD * 2)
347+ let cu = fraction(cA, cB, f)
348+ let cF = fraction(cu, i, f)
349+ let cG = fraction(toBigInt(cE), cC, f)
350+ let cH = toBigInt((cE - 1))
351+ func cI (cJ) = {
352+ let cK = fraction(cJ, cJ, f)
353+ let cL = fraction(cK, cJ, f)
354+ let cM = fraction(cL, f, cF)
355+ fraction((cG + fraction(cM, g, f)), cJ, (fraction(cH, cJ, f) + fraction(h, cM, f)))
358356 }
359357
360- func cO (cP,cQ) = if (cP._2)
361- then cP
358+ func cN (cO,cP) = if (cO._2)
359+ then cO
362360 else {
363- let cK = cP._1
364- let cR = cJ(cK)
365- let cS = (cR - value(cK))
366- let cT = if ((e > cS))
367- then -(cS)
368- else cS
369- if ((f >= cT))
370- then $Tuple2(cR, true)
371- else $Tuple2(cR, false)
361+ let cJ = cO._1
362+ let cQ = cI(cJ)
363+ let cR = (cQ - value(cJ))
364+ let cS = if ((e > cR))
365+ then -(cR)
366+ else cR
367+ if ((f >= cS))
368+ then $Tuple2(cQ, true)
369+ else $Tuple2(cQ, false)
372370 }
373371
374- let cU = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14]
375- let cV = {
376- let cW = cU
377- let cX = size(cW)
378- let cY = $Tuple2(cD, false)
379- func cZ (da,db) = if ((db >= cX))
380- then da
381- else cO(da, cW[db])
372+ let cT = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14]
373+ let cU = {
374+ let cV = cT
375+ let cW = size(cV)
376+ let cX = $Tuple2(cC, false)
377+ func cY (cZ,da) = if ((da >= cW))
378+ then cZ
379+ else cN(cZ, cV[da])
382380
383- func dc (da,db) = if ((db >= cX))
384- then da
381+ func db (cZ,da) = if ((da >= cW))
382+ then cZ
385383 else throw("List size exceeds 15")
386384
387- dc(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cY, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15)
385+ db(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cX, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15)
388386 }
389- let cK = cV._1
390- let dd = cV._2
391- if (dd)
392- then cK
393- else throw(("D calculation error, D = " + toString(cK)))
387+ let cJ = cU._1
388+ let dc = cU._2
389+ if (dc)
390+ then cJ
391+ else throw(("D calculation error, D = " + toString(cJ)))
394392 }
395393 }
396394
397395
398-func de (df,dg,dh,di) = {
399- let dj = bm
396+func dd (de,df,dg,dh) = {
397+ let di = bl
398+ let dj = toBase58String(value(bm))
400399 let dk = toBase58String(value(bn))
401- let dl = toBase58String(value(bo))
400+ let dl = bo
402401 let dm = bp
403- let dn = bq
404- let do = toString(bl)
405- let dp = valueOrErrorMessage(assetInfo(dj), "Wrong LP id").quantity
406- if ((toBase58String(dj) != dg))
402+ let dn = toString(bk)
403+ let do = valueOrErrorMessage(assetInfo(di), "Wrong LP id").quantity
404+ if ((toBase58String(di) != df))
407405 then throw("Wrong pmt asset")
408406 else {
409- let dq = bO(dk)
410- let dr = I(dq, dm)
411- let ds = bO(dl)
412- let dt = I(ds, dn)
413- let du = bQ(dt, dr)
414- let dv = M(du, a)
415- let dw = I(dh, a)
416- let dx = I(dp, a)
417- let dy = fraction(dr, dw, dx)
418- let dz = fraction(dt, dw, dx)
419- let dA = P(dy, dm, FLOOR)
420- let dB = P(dz, dn, FLOOR)
421- let dC = if ((df == ""))
407+ let dp = bN(dj)
408+ let dq = H(dp, dl)
409+ let dr = bN(dk)
410+ let ds = H(dr, dm)
411+ let dt = bP(ds, dq)
412+ let du = L(dt, a)
413+ let dv = H(dg, a)
414+ let dw = H(do, a)
415+ let dx = fraction(dq, dv, dw)
416+ let dy = fraction(ds, dv, dw)
417+ let dz = O(dx, dl, FLOOR)
418+ let dA = O(dy, dm, FLOOR)
419+ let dB = if ((de == ""))
422420 then nil
423- else [ScriptTransfer(di, dA, if ((dk == "WAVES"))
421+ else [ScriptTransfer(dh, dz, if ((dj == "WAVES"))
424422 then unit
425- else fromBase58String(dk)), ScriptTransfer(di, dB, if ((dl == "WAVES"))
423+ else fromBase58String(dj)), ScriptTransfer(dh, dA, if ((dk == "WAVES"))
426424 then unit
427- else fromBase58String(dl)), StringEntry(aj(toString(di), df), bK(dA, dB, dh, dv, height, lastBlock.timestamp)), IntegerEntry(ac(), dv), IntegerEntry(ad(height, lastBlock.timestamp), dv)]
428- $Tuple10(dA, dB, dk, dl, dq, ds, dp, du, do, dC)
425+ else fromBase58String(dk)), StringEntry(ai(toString(dh), de), bJ(dz, dA, dg, du, height, lastBlock.timestamp)), IntegerEntry(ab(), du), IntegerEntry(ac(height, lastBlock.timestamp), du)]
426+ $Tuple10(dz, dA, dj, dk, dp, dr, do, dt, dn, dB)
429427 }
430428 }
431429
432430
433-func dD (df,bX,dE,dF,dG,dH,di,dI,dJ,dK,dL,dM,dN) = {
434- let dj = bm
431+func dC (de,bW,dD,dE,dF,dG,dh,dH,dI,dJ,dK,dL,dM) = {
432+ let di = bl
433+ let dN = toBase58String(value(bm))
435434 let dO = toBase58String(value(bn))
436- let dP = toBase58String(value(bo))
435+ let dP = bq
437436 let dQ = br
438- let dR = bs
437+ let dR = bo
439438 let dS = bp
440- let dT = bq
441- let do = toString(bl)
442- let dU = valueOrErrorMessage(assetInfo(dj), "Wr lp as").quantity
443- let dq = if (dI)
444- then bO(dO)
445- else if (if (dK)
446- then (dN == dO)
439+ let dn = toString(bk)
440+ let dT = valueOrErrorMessage(assetInfo(di), "Wr lp as").quantity
441+ let dp = if (dH)
442+ then bN(dN)
443+ else if (if (dJ)
444+ then (dM == dN)
447445 else false)
448- then (bO(dO) - dM)
449- else if (dK)
450- then bO(dO)
451- else (bO(dO) - dE)
452- let ds = if (dI)
453- then bO(dP)
454- else if (if (dK)
455- then (dN == dP)
446+ then (bN(dN) - dL)
447+ else if (dJ)
448+ then bN(dN)
449+ else (bN(dN) - dD)
450+ let dr = if (dH)
451+ then bN(dO)
452+ else if (if (dJ)
453+ then (dM == dO)
456454 else false)
457- then (bO(dP) - dM)
458- else if (dK)
459- then bO(dP)
460- else (bO(dP) - dG)
461- let dV = I(dE, dS)
462- let dW = I(dG, dT)
463- let dX = bQ(dW, dV)
464- let dr = I(dq, dS)
465- let dt = I(ds, dT)
466- let cc = cz([dr, dt])
467- let dY = if ((dU == 0))
455+ then (bN(dO) - dL)
456+ else if (dJ)
457+ then bN(dO)
458+ else (bN(dO) - dF)
459+ let dU = H(dD, dR)
460+ let dV = H(dF, dS)
461+ let dW = bP(dV, dU)
462+ let dq = H(dp, dR)
463+ let ds = H(dr, dS)
464+ let cb = cy([dq, ds])
465+ let dX = if ((dT == 0))
468466 then {
469- let cb = cz([(dr + dV), (dt + dW)])
470- let dZ = if ((cb > cc))
467+ let ca = cy([(dq + dU), (ds + dV)])
468+ let dY = if ((ca > cb))
471469 then true
472470 else throw("D1 should be greater than D0")
473- if ((dZ == dZ))
471+ if ((dY == dY))
474472 then {
475- let du = d
476- let ea = d
477- let cr = cb
478- $Tuple5(M(cr, a), M(dV, dS), M(dW, dT), bQ((dt + dW), (dr + dV)), ea)
473+ let dt = d
474+ let dZ = d
475+ let cq = ca
476+ $Tuple5(L(cq, a), L(dU, dR), L(dV, dS), bP((ds + dV), (dq + dU)), dZ)
479477 }
480478 else throw("Strict value is not equal to itself.")
481479 }
482480 else {
483- let du = bQ(dt, dr)
484- let eb = fraction(X((du - dX)), c, du)
485- let ea = I(bX, a)
486- if (if (if (dL)
487- then (du != d)
481+ let dt = bP(ds, dq)
482+ let ea = fraction(W((dt - dW)), c, dt)
483+ let dZ = H(bW, a)
484+ if (if (if (dK)
485+ then (dt != d)
488486 else false)
489- then (eb > ea)
487+ then (ea > dZ)
490488 else false)
491- then throw(((("Price slippage " + toString(eb)) + " > ") + toString(ea)))
489+ then throw(((("Price slippage " + toString(ea)) + " > ") + toString(dZ)))
492490 else {
493- let ec = I(dU, a)
494- let ed = fraction(dV, bT(dt, dr, CEILING), c, CEILING)
495- let ee = fraction(dW, c, bT(dt, dr, FLOOR), CEILING)
496- let ef = if ((ed > dW))
497- then $Tuple2(ee, dW)
498- else $Tuple2(dV, ed)
499- let eg = ef._1
500- let eh = ef._2
501- let cb = cz([(dr + eg), (dt + eh)])
502- let dZ = if ((cb > cc))
491+ let eb = H(dT, a)
492+ let ec = fraction(dU, bS(ds, dq, CEILING), c, CEILING)
493+ let ed = fraction(dV, c, bS(ds, dq, FLOOR), CEILING)
494+ let ee = if ((ec > dV))
495+ then $Tuple2(ed, dV)
496+ else $Tuple2(dU, ec)
497+ let ef = ee._1
498+ let eg = ee._2
499+ let ca = cy([(dq + ef), (ds + eg)])
500+ let dY = if ((ca > cb))
503501 then true
504502 else throw("D1 should be greater than D0")
505- if ((dZ == dZ))
503+ if ((dY == dY))
506504 then {
507- let cr = fraction(ec, (cb - cc), cc)
508- $Tuple5(P(cr, a, FLOOR), P(eg, dS, CEILING), P(eh, dT, CEILING), du, ea)
505+ let cq = fraction(eb, (ca - cb), cb)
506+ $Tuple5(O(cq, a, FLOOR), O(ef, dR, CEILING), O(eg, dS, CEILING), dt, dZ)
509507 }
510508 else throw("Strict value is not equal to itself.")
511509 }
512510 }
513- let ei = dY._1
514- let ej = dY._2
515- let ek = dY._3
516- let dv = M(dY._4, a)
517- let el = M(dY._5, a)
518- if ((0 >= ei))
511+ let eh = dX._1
512+ let ei = dX._2
513+ let ej = dX._3
514+ let du = L(dX._4, a)
515+ let ek = L(dX._5, a)
516+ if ((0 >= eh))
519517 then throw("LP <= 0")
520518 else {
521- let em = if (!(dJ))
519+ let el = if (!(dI))
522520 then 0
523- else ei
524- let en = (dE - ej)
525- let eo = (dG - ek)
526- let ep = if (if (dK)
527- then (dN == dO)
521+ else eh
522+ let em = (dD - ei)
523+ let en = (dF - ej)
524+ let eo = if (if (dJ)
525+ then (dM == dN)
528526 else false)
529- then $Tuple2(dM, 0)
530- else if (if (dK)
531- then (dN == dP)
527+ then $Tuple2(dL, 0)
528+ else if (if (dJ)
529+ then (dM == dO)
532530 else false)
533- then $Tuple2(0, dM)
534- else $Tuple2(ej, ek)
535- let eq = ep._1
536- let er = ep._2
537- let es = [IntegerEntry(ac(), dv), IntegerEntry(ad(height, lastBlock.timestamp), dv), StringEntry(ag(di, df), bz(eq, er, em, dv, bX, el, height, lastBlock.timestamp, en, eo))]
538- $Tuple13(ei, em, dv, dq, ds, dU, dj, do, es, en, eo, dF, dH)
531+ then $Tuple2(0, dL)
532+ else $Tuple2(ei, ej)
533+ let ep = eo._1
534+ let eq = eo._2
535+ let er = [IntegerEntry(ab(), du), IntegerEntry(ac(height, lastBlock.timestamp), du), StringEntry(af(dh, de), by(ep, eq, el, du, bW, ek, height, lastBlock.timestamp, em, en))]
536+ $Tuple13(eh, el, du, dp, dr, dT, di, dn, er, em, en, dE, dG)
539537 }
540538 }
541539
542540
543-func et (cA,cQ,eu) = {
544- let ev = g
545- let ew = cA[if ((cQ == 0))
541+func es (cz,cP,et) = {
542+ let eu = g
543+ let ev = cz[if ((cP == 0))
546544 then 1
547545 else 0]
548- let ex = parseBigIntValue(m)
549- let cE = (parseBigIntValue(aV) * ex)
550- let cD = ew
551- let cF = (cE * ev)
552- let ey = (((((eu * eu) / (ew * ev)) * eu) * ex) / (cF * ev))
553- let ez = ((cD + ((eu * ex) / cF)) - eu)
554- func cO (cP,eA) = {
555- let eB = cP
556- let eC = eB._1
557- let dd = eB._2
558- if ((dd != unit))
559- then cP
546+ let ew = parseBigIntValue(l)
547+ let cD = (parseBigIntValue(aU) * ew)
548+ let cC = ev
549+ let cE = (cD * eu)
550+ let ex = (((((et * et) / (ev * eu)) * et) * ew) / (cE * eu))
551+ let ey = ((cC + ((et * ew) / cE)) - et)
552+ func cN (cO,ez) = {
553+ let eA = cO
554+ let eB = eA._1
555+ let dc = eA._2
556+ if ((dc != unit))
557+ then cO
560558 else {
561- let eD = (((eC * eC) + ey) / ((g * eC) + ez))
562- let eE = Y((eD - value(eC)))
563- if ((f >= eE))
564- then $Tuple2(eD, eA)
565- else $Tuple2(eD, unit)
559+ let eC = (((eB * eB) + ex) / ((g * eB) + ey))
560+ let eD = X((eC - value(eB)))
561+ if ((f >= eD))
562+ then $Tuple2(eC, ez)
563+ else $Tuple2(eC, unit)
566564 }
567565 }
568566
569- let cU = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14]
570- let eF = {
571- let cW = cU
572- let cX = size(cW)
573- let cY = $Tuple2(eu, unit)
574- func cZ (da,db) = if ((db >= cX))
575- then da
576- else cO(da, cW[db])
567+ let cT = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14]
568+ let eE = {
569+ let cV = cT
570+ let cW = size(cV)
571+ let cX = $Tuple2(et, unit)
572+ func cY (cZ,da) = if ((da >= cW))
573+ then cZ
574+ else cN(cZ, cV[da])
577575
578- func dc (da,db) = if ((db >= cX))
579- then da
576+ func db (cZ,da) = if ((da >= cW))
577+ then cZ
580578 else throw("List size exceeds 15")
581579
582- dc(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cY, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15)
580+ db(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cX, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15)
583581 }
584- let eC = eF._1
585- let dd = eF._2
586- if ((dd != unit))
587- then eC
588- else throw(("Y calculation error, Y = " + toString(eC)))
582+ let eB = eE._1
583+ let dc = eE._2
584+ if ((dc != unit))
585+ then eB
586+ else throw(("Y calculation error, Y = " + toString(eB)))
589587 }
590588
591589
592-func eG (eH,eI,eJ) = {
593- let eK = fraction(cz([L(eH, toBigInt(bp)), L(eI, toBigInt(bq))]), c, eJ)
594- if ((eJ == e))
590+func eF (eG,eH,eI) = {
591+ let eJ = fraction(cy([K(eG, toBigInt(bo)), K(eH, toBigInt(bp))]), c, eI)
592+ if ((eI == e))
595593 then e
596- else eK
594+ else eJ
597595 }
598596
599597
600-func eL (eM,eN,eO) = {
601- let eP = (toBigInt(bO(bf(bn))) - eM)
602- let eQ = (toBigInt(bO(bf(bo))) - eN)
603- let eR = (toBigInt(value(assetInfo(bm)).quantity) - eO)
604- let eS = eG(eP, eQ, eR)
605- eS
598+func eK (eL,eM,eN) = {
599+ let eO = (toBigInt(bN(be(bm))) - eL)
600+ let eP = (toBigInt(bN(be(bn))) - eM)
601+ let eQ = (toBigInt(value(assetInfo(bl)).quantity) - eN)
602+ let eR = eF(eO, eP, eQ)
603+ eR
606604 }
607605
608606
609-func eT (eU,eV,eO) = {
610- let eP = (bO(bf(bn)) + eU)
611- let eQ = (bO(bf(bo)) + eV)
612- let eR = (value(assetInfo(bm)).quantity + eO)
613- let eK = eG(toBigInt(eP), toBigInt(eQ), toBigInt(eR))
614- let eW = [IntegerEntry(ar, height), StringEntry(aq, toString(eK))]
615- $Tuple2(eW, eK)
607+func eS (eT,eU,eN) = {
608+ let eO = (bN(be(bm)) + eT)
609+ let eP = (bN(be(bn)) + eU)
610+ let eQ = (value(assetInfo(bl)).quantity + eN)
611+ let eJ = eF(toBigInt(eO), toBigInt(eP), toBigInt(eQ))
612+ let eV = [IntegerEntry(aq, height), StringEntry(ap, toString(eJ))]
613+ $Tuple2(eV, eJ)
616614 }
617615
618616
619-func eX (eY,eK) = if ((eK >= eY))
617+func eW (eX,eJ) = if ((eJ >= eX))
620618 then true
621- else aO("updated DLp lower than current DLp")
619+ else aN("updated DLp lower than current DLp")
622620
623621
624-func eZ (fa) = {
625- let eP = bO(bf(bn))
626- let eQ = bO(bf(bo))
627- let fb = fa.amount
628- let fc = fraction(fa.amount, fa.price, a, FLOOR)
629- let fd = if ((fa.orderType == Buy))
630- then $Tuple2(fb, -(fc))
631- else $Tuple2(-(fb), fc)
632- let eU = fd._1
633- let eV = fd._2
634- if (if (if (aW())
622+func eY (eZ) = {
623+ let eO = bN(be(bm))
624+ let eP = bN(be(bn))
625+ let fa = eZ.amount
626+ let fb = fraction(eZ.amount, eZ.price, a, FLOOR)
627+ let fc = if ((eZ.orderType == Buy))
628+ then $Tuple2(fa, -(fb))
629+ else $Tuple2(-(fa), fb)
630+ let eT = fc._1
631+ let eU = fc._2
632+ if (if (if (aV())
635633 then true
636- else (bl == s))
634+ else (bk == r))
637635 then true
638- else (bl == t))
636+ else (bk == s))
639637 then throw("Admin blocked")
640- else if (if ((fa.assetPair.amountAsset != bn))
638+ else if (if ((eZ.assetPair.amountAsset != bm))
641639 then true
642- else (fa.assetPair.priceAsset != bo))
640+ else (eZ.assetPair.priceAsset != bn))
643641 then throw("Wr assets")
644642 else {
645- let fe = parseBigIntValue(valueOrElse(getString(this, aq), "0"))
646- let ff = eT(eU, eV, 0)
647- let fg = ff._1
648- let fh = ff._2
649- let fi = (fh >= fe)
650- let fj = makeString(["dLp=", toString(fe), " dLpNew=", toString(fh), " amountAssetBalance=", toString(eP), " priceAssetBalance=", toString(eQ), " amountAssetBalanceDelta=", toString(eU), " priceAssetBalanceDelta=", toString(eV), " height=", toString(height)], "")
651- $Tuple2(fi, fj)
643+ let fd = parseBigIntValue(valueOrElse(getString(this, ap), "0"))
644+ let fe = eS(eT, eU, 0)
645+ let ff = fe._1
646+ let fg = fe._2
647+ let fh = (fg >= fd)
648+ let fi = makeString(["dLp=", toString(fd), " dLpNew=", toString(fg), " amountAssetBalance=", toString(eO), " priceAssetBalance=", toString(eP), " amountAssetBalanceDelta=", toString(eT), " priceAssetBalanceDelta=", toString(eU), " height=", toString(height)], "")
649+ $Tuple2(fh, fi)
652650 }
653651 }
654652
655653
656-func fk (cQ) = if ((size(cQ.payments) != 1))
654+func fj (cP) = if ((size(cP.payments) != 1))
657655 then throw("1 pmnt exp")
658656 else {
659- let fl = value(cQ.payments[0])
660- let dg = value(fl.assetId)
661- let dM = fl.amount
662- let dY = de(toBase58String(cQ.transactionId), toBase58String(dg), dM, cQ.caller)
663- let dA = dY._1
664- let dB = dY._2
665- let do = parseIntValue(dY._9)
666- let dC = dY._10
667- if (if (aW())
657+ let fk = value(cP.payments[0])
658+ let df = value(fk.assetId)
659+ let dL = fk.amount
660+ let dX = dd(toBase58String(cP.transactionId), toBase58String(df), dL, cP.caller)
661+ let dz = dX._1
662+ let dA = dX._2
663+ let dn = parseIntValue(dX._9)
664+ let dB = dX._10
665+ if (if (aV())
668666 then true
669- else (do == t))
670- then throw(("Admin blocked: " + toString(do)))
671- else $Tuple5(dA, dB, dM, dg, dC)
667+ else (dn == s))
668+ then throw(("Admin blocked: " + toString(dn)))
669+ else $Tuple5(dz, dA, dL, df, dB)
672670 }
673671
674672
675-func fm (fn,ai,fo,fp,bX,dJ,dK,dL,dM,dN) = {
676- let dY = dD(ai, bX, value(fo).amount, value(fo).assetId, value(fp).amount, value(fp).assetId, fn, (ai == ""), dJ, dK, dL, dM, dN)
677- let do = parseIntValue(dY._8)
678- if (if (if (aW())
673+func fl (fm,ah,fn,fo,bW,dI,dJ,dK,dL,dM) = {
674+ let dX = dC(ah, bW, value(fn).amount, value(fn).assetId, value(fo).amount, value(fo).assetId, fm, (ah == ""), dI, dJ, dK, dL, dM)
675+ let dn = parseIntValue(dX._8)
676+ if (if (if (aV())
679677 then true
680- else (do == r))
678+ else (dn == q))
681679 then true
682- else (do == t))
683- then throw(("Blocked:" + toString(do)))
684- else dY
680+ else (dn == s))
681+ then throw(("Blocked:" + toString(dn)))
682+ else dX
685683 }
686684
687685
688-func fq (fr,dg,di,ai,fs) = {
686+func fp (fq,df,dh,ah,fr) = {
687+ let dj = toBase58String(value(bm))
689688 let dk = toBase58String(value(bn))
690- let dl = toBase58String(value(bo))
691- let dj = bm
689+ let di = bl
690+ let dR = bo
692691 let dS = bp
693- let dT = bq
694- let eR = toBigInt(valueOrErrorMessage(assetInfo(dj), "invalid lp asset").quantity)
695- let ft = if ((eR > e))
692+ let eQ = toBigInt(valueOrErrorMessage(assetInfo(di), "invalid lp asset").quantity)
693+ let fs = if ((eQ > e))
696694 then true
697695 else throw("initial deposit requires all coins")
698- if ((ft == ft))
696+ if ((fs == fs))
699697 then {
700- let dq = bO(dk)
701- let ds = bO(dl)
702- let fu = if ((ai == ""))
703- then $Tuple2(dq, ds)
704- else if ((dg == dk))
705- then if ((fr > dq))
698+ let dp = bN(dj)
699+ let dr = bN(dk)
700+ let ft = if ((ah == ""))
701+ then $Tuple2(dp, dr)
702+ else if ((df == dj))
703+ then if ((fq > dp))
706704 then throw("invalid payment amount")
707- else $Tuple2((dq - fr), ds)
708- else if ((dg == dl))
709- then if ((fr > ds))
705+ else $Tuple2((dp - fq), dr)
706+ else if ((df == dk))
707+ then if ((fq > dr))
710708 then throw("invalid payment amount")
711- else $Tuple2(dq, (ds - fr))
709+ else $Tuple2(dp, (dr - fq))
712710 else throw("wrong pmtAssetId")
713- let fv = fu._1
714- let fw = fu._2
715- let fx = if ((dg == dk))
716- then $Tuple2(fr, 0)
717- else if ((dg == dl))
718- then $Tuple2(0, fr)
711+ let fu = ft._1
712+ let fv = ft._2
713+ let fw = if ((df == dj))
714+ then $Tuple2(fq, 0)
715+ else if ((df == dk))
716+ then $Tuple2(0, fq)
719717 else throw("invalid payment")
720- let fy = fx._1
721- let fz = fx._2
722- let fA = if (fs)
723- then $Tuple3(cw(fy, aS)._1, cw(fz, aS)._1, cw(fr, aS)._2)
724- else $Tuple3(fy, fz, 0)
725- let fB = fA._1
726- let fC = fA._2
727- let cy = fA._3
718+ let fx = fw._1
719+ let fy = fw._2
720+ let fz = if (fr)
721+ then $Tuple3(cv(fx, aR)._1, cv(fy, aR)._1, cv(fq, aR)._2)
722+ else $Tuple3(fx, fy, 0)
723+ let fA = fz._1
724+ let fB = fz._2
725+ let cx = fz._3
726+ let fC = (fu + fA)
728727 let fD = (fv + fB)
729- let fE = (fw + fC)
730- let cc = cz([I(fv, bp), I(fw, bq)])
731- let cb = cz([I(fD, bp), I(fE, bq)])
732- let dZ = if ((cb > cc))
728+ let cb = cy([H(fu, bo), H(fv, bp)])
729+ let ca = cy([H(fC, bo), H(fD, bp)])
730+ let dY = if ((ca > cb))
733731 then true
734732 else throw()
735- if ((dZ == dZ))
733+ if ((dY == dY))
736734 then {
737- let fF = fraction(eR, (cb - cc), cc, FLOOR)
738- let dv = M(bQ(I(fE, dT), I(fD, dS)), a)
739- let es = [IntegerEntry(ac(), dv), IntegerEntry(ad(height, lastBlock.timestamp), dv), StringEntry(ag(di, ai), bz(fy, fz, toInt(fF), dv, 0, 0, height, lastBlock.timestamp, 0, 0))]
740- let fG = fraction(fw, a, fv)
741- let fH = fraction(fr, a, (fG + a))
742- let fI = (fr - fH)
743- let fJ = fraction(eR, toBigInt(fI), toBigInt(fw))
744- let fK = toInt(fraction((fF - fJ), b, fJ))
745- $Tuple4(toInt(fF), es, cy, fK)
735+ let fE = fraction(eQ, (ca - cb), cb, FLOOR)
736+ let du = L(bP(H(fD, dS), H(fC, dR)), a)
737+ let er = [IntegerEntry(ab(), du), IntegerEntry(ac(height, lastBlock.timestamp), du), StringEntry(af(dh, ah), by(fx, fy, toInt(fE), du, 0, 0, height, lastBlock.timestamp, 0, 0))]
738+ let fF = fraction(fv, a, fu)
739+ let fG = fraction(fq, a, (fF + a))
740+ let fH = (fq - fG)
741+ let fI = fraction(eQ, toBigInt(fH), toBigInt(fv))
742+ let fJ = toInt(fraction((fE - fI), b, fI))
743+ $Tuple4(toInt(fE), er, cx, fJ)
746744 }
747745 else throw("Strict value is not equal to itself.")
748746 }
749747 else throw("Strict value is not equal to itself.")
750748 }
751749
752750
753-func fL (fM,fN,fO,fn,fP,fQ) = {
751+func fK (fL,fM,fN,fm,fO,fP) = {
752+ let di = toBase58String(value(bl))
754753 let dj = toBase58String(value(bm))
755754 let dk = toBase58String(value(bn))
756- let dl = toBase58String(value(bo))
755+ let fQ = bo
757756 let fR = bp
758- let fS = bq
759- let fT = bl
760- let di = if ((fn == by))
761- then fP
762- else fn
763- let fl = value(fO[0])
764- let dg = value(fl.assetId)
765- let dM = fl.amount
766- let eS = eL(e, e, e)
767- if ((eS == eS))
757+ let fS = bk
758+ let dh = if ((fm == bx))
759+ then fO
760+ else fm
761+ let fk = value(fN[0])
762+ let df = value(fk.assetId)
763+ let dL = fk.amount
764+ let eR = eK(e, e, e)
765+ if ((eR == eR))
768766 then {
769- let df = toBase58String(fQ)
770- if ((dj != toBase58String(dg)))
767+ let de = toBase58String(fP)
768+ if ((di != toBase58String(df)))
771769 then throw("Wrong LP")
772770 else {
773- let dq = bO(dk)
774- let ds = bO(dl)
775- let fU = {
776- let aT = invoke(this, "getOneTknV2READONLY", [fM, dM], nil)
777- if ($isInstanceOf(aT, "(Int, Int)"))
778- then aT
779- else throw(($getType(aT) + " couldn't be cast to (Int, Int)"))
771+ let dp = bN(dj)
772+ let dr = bN(dk)
773+ let fT = {
774+ let aS = invoke(this, "getOneTknV2READONLY", [fL, dL], nil)
775+ if ($isInstanceOf(aS, "(Int, Int)"))
776+ then aS
777+ else throw(($getType(aS) + " couldn't be cast to (Int, Int)"))
780778 }
781- if ((fU == fU))
779+ if ((fT == fT))
782780 then {
783- let cy = fU._2
784- let fV = fU._1
785- let fW = if (if ((fN > 0))
786- then (fN > fV)
781+ let cx = fT._2
782+ let fU = fT._1
783+ let fV = if (if ((fM > 0))
784+ then (fM > fU)
787785 else false)
788- then aO(makeString(["amount to receive is less than ", toString(fN)], ""))
789- else fV
790- let fX = if ((fM == dk))
791- then $Tuple4(fW, 0, ((dq - fW) - cy), ds)
792- else if ((fM == dl))
793- then $Tuple4(0, fW, dq, ((ds - fW) - cy))
786+ then aN(makeString(["amount to receive is less than ", toString(fM)], ""))
787+ else fU
788+ let fW = if ((fL == dj))
789+ then $Tuple4(fV, 0, ((dp - fV) - cx), dr)
790+ else if ((fL == dk))
791+ then $Tuple4(0, fV, dp, ((dr - fV) - cx))
794792 else throw("invalid out asset id")
795- let fY = fX._1
796- let fZ = fX._2
797- let fD = fX._3
798- let fE = fX._4
799- let ga = bQ(I(fE, fS), I(fD, fR))
800- let gb = M(ga, a)
801- let gc = if ((fM == "WAVES"))
793+ let fX = fW._1
794+ let fY = fW._2
795+ let fC = fW._3
796+ let fD = fW._4
797+ let fZ = bP(H(fD, fR), H(fC, fQ))
798+ let ga = L(fZ, a)
799+ let gb = if ((fL == "WAVES"))
802800 then unit
803- else fromBase58String(fM)
804- let gd = if ((cy > 0))
805- then [ScriptTransfer(aY, cy, gc)]
801+ else fromBase58String(fL)
802+ let gc = if ((cx > 0))
803+ then [ScriptTransfer(aX, cx, gb)]
806804 else nil
807- let dC = ([ScriptTransfer(di, fW, gc), StringEntry(aj(toString(di), df), bK(fY, fZ, dM, gb, height, lastBlock.timestamp)), IntegerEntry(ac(), gb), IntegerEntry(ad(height, lastBlock.timestamp), gb)] ++ gd)
808- if ((dC == dC))
805+ let dB = ([ScriptTransfer(dh, fV, gb), StringEntry(ai(toString(dh), de), bJ(fX, fY, dL, ga, height, lastBlock.timestamp)), IntegerEntry(ab(), ga), IntegerEntry(ac(height, lastBlock.timestamp), ga)] ++ gc)
806+ if ((dB == dB))
809807 then {
810- let ge = invoke(aR, "burn", [dM], [AttachedPayment(dg, dM)])
811- if ((ge == ge))
808+ let gd = invoke(aQ, "burn", [dL], [AttachedPayment(df, dL)])
809+ if ((gd == gd))
812810 then {
813- let gf = {
814- let gg = if ((this == aY))
811+ let ge = {
812+ let gf = if ((this == aX))
815813 then 0
816- else cy
817- let gh = if ((bd(fM) == bn))
814+ else cx
815+ let gg = if ((bc(fL) == bm))
818816 then true
819817 else false
820- if (gh)
821- then $Tuple2(-((fV + gg)), 0)
822- else $Tuple2(0, -((fV + gg)))
818+ if (gg)
819+ then $Tuple2(-((fU + gf)), 0)
820+ else $Tuple2(0, -((fU + gf)))
823821 }
824- let eU = gf._1
825- let eV = gf._2
826- let gi = eT(eU, eV, 0)
827- let gj = gi._1
828- let eK = gi._2
829- let gk = eX(eS, eK)
830- if ((gk == gk))
831- then $Tuple2((dC ++ gj), fW)
822+ let eT = ge._1
823+ let eU = ge._2
824+ let gh = eS(eT, eU, 0)
825+ let gi = gh._1
826+ let eJ = gh._2
827+ let gj = eW(eR, eJ)
828+ if ((gj == gj))
829+ then $Tuple2((dB ++ gi), fV)
832830 else throw("Strict value is not equal to itself.")
833831 }
834832 else throw("Strict value is not equal to itself.")
835833 }
836834 else throw("Strict value is not equal to itself.")
837835 }
838836 else throw("Strict value is not equal to itself.")
839837 }
840838 }
841839 else throw("Strict value is not equal to itself.")
842840 }
843841
844842
845-func gl () = {
846- let gm = getString(aa())
847- if ($isInstanceOf(gm, "String"))
843+func gk () = {
844+ let gl = getString(Z())
845+ if ($isInstanceOf(gl, "String"))
848846 then {
849- let cD = gm
850- fromBase58String(cD)
847+ let cC = gl
848+ fromBase58String(cC)
851849 }
852- else if ($isInstanceOf(gm, "Unit"))
850+ else if ($isInstanceOf(gl, "Unit"))
853851 then unit
854852 else throw("Match error")
855853 }
856854
857855
858-func gn () = {
859- let gm = getString(ab())
860- if ($isInstanceOf(gm, "String"))
856+func gm () = {
857+ let gl = getString(aa())
858+ if ($isInstanceOf(gl, "String"))
861859 then {
862- let cD = gm
863- fromBase58String(cD)
860+ let cC = gl
861+ fromBase58String(cC)
864862 }
865- else if ($isInstanceOf(gm, "Unit"))
863+ else if ($isInstanceOf(gl, "Unit"))
866864 then unit
867865 else throw("Match error")
868866 }
869867
870868
871-let go = throw("Permission denied")
869+let gn = throw("Permission denied")
872870
873-func gp (cQ) = {
874- let gm = gl()
875- if ($isInstanceOf(gm, "ByteVector"))
871+func go (cP) = {
872+ let gl = gk()
873+ if ($isInstanceOf(gl, "ByteVector"))
876874 then {
877- let gq = gm
878- (cQ.callerPublicKey == gq)
875+ let gp = gl
876+ (cP.callerPublicKey == gp)
879877 }
880- else if ($isInstanceOf(gm, "Unit"))
881- then (cQ.caller == this)
878+ else if ($isInstanceOf(gl, "Unit"))
879+ then (cP.caller == this)
882880 else throw("Match error")
883881 }
884882
885883
886-func gr (cQ) = {
887- let gm = gl()
888- if ($isInstanceOf(gm, "ByteVector"))
884+func gq (cP) = {
885+ let gl = gk()
886+ if ($isInstanceOf(gl, "ByteVector"))
889887 then {
890- let gq = gm
891- if ((cQ.callerPublicKey == gq))
888+ let gp = gl
889+ if ((cP.callerPublicKey == gp))
892890 then true
893- else go
891+ else gn
894892 }
895- else if ($isInstanceOf(gm, "Unit"))
896- then if ((cQ.caller == this))
893+ else if ($isInstanceOf(gl, "Unit"))
894+ then if ((cP.caller == this))
897895 then true
898- else go
896+ else gn
899897 else throw("Match error")
900898 }
901899
902900
903-func gs (gt,eu,gu) = {
904- let bh = aZ()
905- let dk = bh[x]
906- let dl = bh[y]
907- let ev = g
908- let ex = parseBigIntValue(m)
909- let cE = (parseBigIntValue(aV) * ex)
910- let cA = if ((gt == false))
911- then [(toBigInt(bO(dk)) + gu), toBigInt(bO(dl))]
912- else [(toBigInt(bO(dl)) + gu), toBigInt(bO(dk))]
913- let ew = cA[0]
914- let cD = ew
915- let cF = (cE * ev)
916- let ey = (((((eu * eu) / (ew * ev)) * eu) * ex) / (cF * ev))
917- let ez = ((cD + ((eu * ex) / cF)) - eu)
918- func cO (cP,eA) = {
919- let gv = cP
920- let eC = gv._1
921- let dd = gv._2
922- if ((dd != unit))
923- then cP
901+func gr (gs,et,gt) = {
902+ let bg = aY()
903+ let dj = bg[w]
904+ let dk = bg[x]
905+ let eu = g
906+ let ew = parseBigIntValue(l)
907+ let cD = (parseBigIntValue(aU) * ew)
908+ let cz = if ((gs == false))
909+ then [(toBigInt(bN(dj)) + gt), toBigInt(bN(dk))]
910+ else [(toBigInt(bN(dk)) + gt), toBigInt(bN(dj))]
911+ let ev = cz[0]
912+ let cC = ev
913+ let cE = (cD * eu)
914+ let ex = (((((et * et) / (ev * eu)) * et) * ew) / (cE * eu))
915+ let ey = ((cC + ((et * ew) / cE)) - et)
916+ func cN (cO,ez) = {
917+ let gu = cO
918+ let eB = gu._1
919+ let dc = gu._2
920+ if ((dc != unit))
921+ then cO
924922 else {
925- let eD = (((eC * eC) + ey) / ((g * eC) + ez))
926- let eE = Y((eD - value(eC)))
927- if ((f >= eE))
928- then $Tuple2(eD, eA)
929- else $Tuple2(eD, unit)
923+ let eC = (((eB * eB) + ex) / ((g * eB) + ey))
924+ let eD = X((eC - value(eB)))
925+ if ((f >= eD))
926+ then $Tuple2(eC, ez)
927+ else $Tuple2(eC, unit)
930928 }
931929 }
932930
933- let cU = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14]
934- let gw = {
935- let cW = cU
936- let cX = size(cW)
937- let cY = $Tuple2(eu, unit)
938- func cZ (da,db) = if ((db >= cX))
939- then da
940- else cO(da, cW[db])
931+ let cT = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14]
932+ let gv = {
933+ let cV = cT
934+ let cW = size(cV)
935+ let cX = $Tuple2(et, unit)
936+ func cY (cZ,da) = if ((da >= cW))
937+ then cZ
938+ else cN(cZ, cV[da])
941939
942- func dc (da,db) = if ((db >= cX))
943- then da
940+ func db (cZ,da) = if ((da >= cW))
941+ then cZ
944942 else throw("List size exceeds 15")
945943
946- dc(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cZ(cY, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15)
944+ db(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cY(cX, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15)
947945 }
948- let eC = gw._1
949- let dd = gw._2
950- if ((dd != unit))
951- then eC
952- else throw(("Y calculation error, Y = " + toString(eC)))
946+ let eB = gv._1
947+ let dc = gv._2
948+ if ((dc != unit))
949+ then eB
950+ else throw(("Y calculation error, Y = " + toString(eB)))
953951 }
954952
955953
956-@Callable(cQ)
957-func calculateAmountOutForSwapREADONLY (gx,gt) = {
958- let gy = if ((gt == false))
954+@Callable(cP)
955+func calculateAmountOutForSwapREADONLY (gw,gs) = {
956+ let gx = if ((gs == false))
959957 then {
960- let gz = aK(this, al())
961- let gu = (toBigInt(bO(aK(this, ak()))) + toBigInt(gx))
962- $Tuple2(gz, gu)
958+ let gy = aJ(this, ak())
959+ let gt = (toBigInt(bN(aJ(this, aj()))) + toBigInt(gw))
960+ $Tuple2(gy, gt)
963961 }
964962 else {
965- let gz = aK(this, ak())
966- let gu = (toBigInt(bO(aK(this, al()))) + toBigInt(gx))
967- $Tuple2(gz, gu)
963+ let gy = aJ(this, aj())
964+ let gt = (toBigInt(bN(aJ(this, ak()))) + toBigInt(gw))
965+ $Tuple2(gy, gt)
968966 }
969- let gz = gy._1
970- let gu = gy._2
971- let bh = aZ()
972- let dk = bh[x]
973- let dl = bh[y]
974- let cA = [toBigInt(bO(dk)), toBigInt(bO(dl))]
975- let eu = cz(cA)
976- let eC = gs(gt, eu, toBigInt(gx))
977- let gA = ((toBigInt(bO(gz)) - eC) - toBigInt(1))
978- let gB = max([0, toInt(gA)])
979- let gC = if ((gt == false))
980- then [(toBigInt(bO(dk)) + toBigInt(gx)), (toBigInt(bO(dl)) - gA)]
981- else [(toBigInt(bO(dk)) - gA), (toBigInt(bO(dl)) + toBigInt(gx))]
982- let gD = cz(gC)
983- let dZ = if ((gD >= eu))
967+ let gy = gx._1
968+ let gt = gx._2
969+ let bg = aY()
970+ let dj = bg[w]
971+ let dk = bg[x]
972+ let cz = [toBigInt(bN(dj)), toBigInt(bN(dk))]
973+ let et = cy(cz)
974+ let eB = gr(gs, et, toBigInt(gw))
975+ let gz = ((toBigInt(bN(gy)) - eB) - toBigInt(1))
976+ let gA = max([0, toInt(gz)])
977+ let gB = if ((gs == false))
978+ then [(toBigInt(bN(dj)) + toBigInt(gw)), (toBigInt(bN(dk)) - gz)]
979+ else [(toBigInt(bN(dj)) - gz), (toBigInt(bN(dk)) + toBigInt(gw))]
980+ let gC = cy(gB)
981+ let dY = if ((gC >= et))
984982 then true
985- else throw(makeString(["new D is fewer error", toString(eu), toString(gD)], "__"))
986- if ((dZ == dZ))
987- then $Tuple2(nil, gB)
983+ else throw(makeString(["new D is fewer error", toString(et), toString(gC)], "__"))
984+ if ((dY == dY))
985+ then $Tuple2(nil, gA)
988986 else throw("Strict value is not equal to itself.")
989987 }
990988
991989
992990
993-@Callable(cQ)
994-func calculateAmountOutForSwapAndSendTokens (gx,gt,gE,gF) = {
995- let gG = {
996- let aT = invoke(aR, "getSwapContractREADONLY", nil, nil)
997- if ($isInstanceOf(aT, "String"))
998- then aT
999- else throw(($getType(aT) + " couldn't be cast to String"))
991+@Callable(cP)
992+func calculateAmountOutForSwapAndSendTokens (gw,gs,gD,gE) = {
993+ let gF = {
994+ let aS = invoke(aQ, "getSwapContractREADONLY", nil, nil)
995+ if ($isInstanceOf(aS, "String"))
996+ then aS
997+ else throw(($getType(aS) + " couldn't be cast to String"))
1000998 }
1001- let gH = [if ((value(cQ.payments[0]).amount >= gx))
999+ let gG = [if ((value(cP.payments[0]).amount >= gw))
10021000 then true
1003- else aO("Wrong amount"), if ((cQ.caller == addressFromStringValue(gG)))
1001+ else aN("Wrong amount"), if ((cP.caller == addressFromStringValue(gF)))
10041002 then true
1005- else aO("Permission denied")]
1006- if ((gH == gH))
1003+ else aN("Permission denied")]
1004+ if ((gG == gG))
10071005 then {
1008- let fl = value(cQ.payments[0])
1009- let gI = if ((fl.assetId == unit))
1006+ let fk = value(cP.payments[0])
1007+ let gH = if ((fk.assetId == unit))
10101008 then toBase58String(toBytes("WAVES"))
1011- else toBase58String(value(fl.assetId))
1012- let gJ = if ((gt == false))
1009+ else toBase58String(value(fk.assetId))
1010+ let gI = if ((gs == false))
10131011 then {
1014- let gz = aK(this, al())
1015- let gu = (bO(gI) - value(cQ.payments[0]).amount)
1016- $Tuple2(gz, gu)
1012+ let gy = aJ(this, ak())
1013+ let gt = (bN(gH) - value(cP.payments[0]).amount)
1014+ $Tuple2(gy, gt)
10171015 }
10181016 else {
1019- let gz = aK(this, ak())
1020- let gu = (bO(gI) - value(cQ.payments[0]).amount)
1021- $Tuple2(gz, gu)
1017+ let gy = aJ(this, aj())
1018+ let gt = (bN(gH) - value(cP.payments[0]).amount)
1019+ $Tuple2(gy, gt)
10221020 }
1023- let gz = gJ._1
1024- let gu = gJ._2
1025- let bh = aZ()
1026- let dk = bh[x]
1027- let dl = bh[y]
1028- let cA = if ((gt == false))
1029- then [(toBigInt(bO(dk)) - toBigInt(value(cQ.payments[0]).amount)), toBigInt(bO(dl))]
1030- else [toBigInt(bO(dk)), (toBigInt(bO(dl)) - toBigInt(value(cQ.payments[0]).amount))]
1031- let eu = cz(cA)
1032- let eC = gs(gt, eu, toBigInt(0))
1033- let gA = ((toBigInt(bO(gz)) - eC) - toBigInt(1))
1034- let gB = max([0, toInt(gA)])
1035- let gK = if ((gB >= gE))
1021+ let gy = gI._1
1022+ let gt = gI._2
1023+ let bg = aY()
1024+ let dj = bg[w]
1025+ let dk = bg[x]
1026+ let cz = if ((gs == false))
1027+ then [(toBigInt(bN(dj)) - toBigInt(value(cP.payments[0]).amount)), toBigInt(bN(dk))]
1028+ else [toBigInt(bN(dj)), (toBigInt(bN(dk)) - toBigInt(value(cP.payments[0]).amount))]
1029+ let et = cy(cz)
1030+ let eB = gr(gs, et, toBigInt(0))
1031+ let gz = ((toBigInt(bN(gy)) - eB) - toBigInt(1))
1032+ let gA = max([0, toInt(gz)])
1033+ let gJ = if ((gA >= gD))
10361034 then true
10371035 else throw("Exchange result is fewer coins than expected")
1038- if ((gK == gK))
1036+ if ((gJ == gJ))
10391037 then {
1040- let gC = if ((gt == false))
1041- then [toBigInt(bO(dk)), (toBigInt(bO(dl)) - gA)]
1042- else [(toBigInt(bO(dk)) - gA), toBigInt(bO(dl))]
1043- let gD = cz(gC)
1044- let dZ = if ((gD >= eu))
1038+ let gB = if ((gs == false))
1039+ then [toBigInt(bN(dj)), (toBigInt(bN(dk)) - gz)]
1040+ else [(toBigInt(bN(dj)) - gz), toBigInt(bN(dk))]
1041+ let gC = cy(gB)
1042+ let dY = if ((gC >= et))
10451043 then true
10461044 else throw("new D is fewer error")
1047- if ((dZ == dZ))
1048- then $Tuple2([ScriptTransfer(addressFromStringValue(gF), gB, bd(gz))], gB)
1045+ if ((dY == dY))
1046+ then $Tuple2([ScriptTransfer(addressFromStringValue(gE), gA, bc(gy))], gA)
10491047 else throw("Strict value is not equal to itself.")
10501048 }
10511049 else throw("Strict value is not equal to itself.")
10521050 }
10531051 else throw("Strict value is not equal to itself.")
10541052 }
10551053
10561054
10571055
1058-@Callable(cQ)
1059-func constructor (Z) = {
1060- let ey = gr(cQ)
1061- if ((ey == ey))
1062- then [StringEntry(Z(), Z)]
1056+@Callable(cP)
1057+func constructor (Y) = {
1058+ let ex = gq(cP)
1059+ if ((ex == ex))
1060+ then [StringEntry(Y(), Y)]
10631061 else throw("Strict value is not equal to itself.")
10641062 }
10651063
10661064
10671065
1068-@Callable(cQ)
1069-func setManager (gL) = {
1070- let ey = gr(cQ)
1071- if ((ey == ey))
1066+@Callable(cP)
1067+func setManager (gK) = {
1068+ let ex = gq(cP)
1069+ if ((ex == ex))
10721070 then {
1073- let gM = fromBase58String(gL)
1074- if ((gM == gM))
1075- then [StringEntry(ab(), gL)]
1071+ let gL = fromBase58String(gK)
1072+ if ((gL == gL))
1073+ then [StringEntry(aa(), gK)]
10761074 else throw("Strict value is not equal to itself.")
10771075 }
10781076 else throw("Strict value is not equal to itself.")
10791077 }
10801078
10811079
10821080
1083-@Callable(cQ)
1081+@Callable(cP)
10841082 func confirmManager () = {
1085- let cv = gn()
1086- let gN = if (isDefined(cv))
1083+ let cu = gm()
1084+ let gM = if (isDefined(cu))
10871085 then true
10881086 else throw("No pending manager")
1089- if ((gN == gN))
1087+ if ((gM == gM))
10901088 then {
1091- let gO = if ((cQ.callerPublicKey == value(cv)))
1089+ let gN = if ((cP.callerPublicKey == value(cu)))
10921090 then true
10931091 else throw("You are not pending manager")
1094- if ((gO == gO))
1095- then [StringEntry(aa(), toBase58String(value(cv))), DeleteEntry(ab())]
1092+ if ((gN == gN))
1093+ then [StringEntry(Z(), toBase58String(value(cu))), DeleteEntry(aa())]
10961094 else throw("Strict value is not equal to itself.")
10971095 }
10981096 else throw("Strict value is not equal to itself.")
10991097 }
11001098
11011099
11021100
1103-@Callable(cQ)
1104-func put (gP,gQ) = {
1105- let gR = bt()
1106- let gS = valueOrErrorMessage(addressFromString(gR[D]), "Wr st addr")
1107- let gT = valueOrErrorMessage(addressFromString(gR[F]), "Wr sl addr")
1108- if ((0 > gP))
1101+@Callable(cP)
1102+func put (gO,gP) = {
1103+ let gQ = bs()
1104+ let gR = valueOrErrorMessage(addressFromString(gQ[C]), "Wr st addr")
1105+ let gS = valueOrErrorMessage(addressFromString(gQ[E]), "Wr sl addr")
1106+ if ((0 > gO))
11091107 then throw("Wrong slippage")
1110- else if ((size(cQ.payments) != 2))
1108+ else if ((size(cP.payments) != 2))
11111109 then throw("2 pmnts expd")
11121110 else {
1113- let gU = toBigInt(value(cQ.payments[0]).amount)
1114- let gV = toBigInt(value(cQ.payments[1]).amount)
1115- let eP = (toBigInt(bO(bf(bn))) - gU)
1116- if ((eP == eP))
1111+ let gT = toBigInt(value(cP.payments[0]).amount)
1112+ let gU = toBigInt(value(cP.payments[1]).amount)
1113+ let eO = (toBigInt(bN(be(bm))) - gT)
1114+ if ((eO == eO))
11171115 then {
1118- let eQ = (toBigInt(bO(bf(bo))) - gV)
1119- if ((eQ == eQ))
1116+ let eP = (toBigInt(bN(be(bn))) - gU)
1117+ if ((eP == eP))
11201118 then {
1121- let eR = toBigInt(value(assetInfo(bm)).quantity)
1122- if ((eR == eR))
1119+ let eQ = toBigInt(value(assetInfo(bl)).quantity)
1120+ if ((eQ == eQ))
11231121 then {
1124- let eS = eL(gU, gV, toBigInt(0))
1125- if ((eS == eS))
1122+ let eR = eK(gT, gU, toBigInt(0))
1123+ if ((eR == eR))
11261124 then {
1127- let gW = fm(toString(cQ.caller), toBase58String(cQ.transactionId), AttachedPayment(value(cQ.payments[0]).assetId, value(cQ.payments[0]).amount), cQ.payments[1], gP, true, false, true, 0, "")
1128- let em = gW._2
1129- let gX = gW._7
1130- let dC = gW._9
1131- let en = gW._10
1132- let eo = gW._11
1133- let dk = gW._12
1134- let dl = gW._13
1135- let dY = invoke(aR, "emit", [em], nil)
1136- if ((dY == dY))
1125+ let gV = fl(toString(cP.caller), toBase58String(cP.transactionId), AttachedPayment(value(cP.payments[0]).assetId, value(cP.payments[0]).amount), cP.payments[1], gO, true, false, true, 0, "")
1126+ let el = gV._2
1127+ let gW = gV._7
1128+ let dB = gV._9
1129+ let em = gV._10
1130+ let en = gV._11
1131+ let dj = gV._12
1132+ let dk = gV._13
1133+ let dX = invoke(aQ, "emit", [el], nil)
1134+ if ((dX == dX))
11371135 then {
1138- let gY = {
1139- let gm = dY
1140- if ($isInstanceOf(gm, "Address"))
1136+ let gX = {
1137+ let gl = dX
1138+ if ($isInstanceOf(gl, "Address"))
11411139 then {
1142- let gZ = gm
1143- invoke(gZ, "emit", [em], nil)
1140+ let gY = gl
1141+ invoke(gY, "emit", [el], nil)
11441142 }
11451143 else unit
11461144 }
1147- if ((gY == gY))
1145+ if ((gX == gX))
11481146 then {
1149- let ha = if ((en > 0))
1150- then invoke(gT, "put", nil, [AttachedPayment(dk, en)])
1147+ let gZ = if ((em > 0))
1148+ then invoke(gS, "put", nil, [AttachedPayment(dj, em)])
11511149 else nil
1152- if ((ha == ha))
1150+ if ((gZ == gZ))
11531151 then {
1154- let hb = if ((eo > 0))
1155- then invoke(gT, "put", nil, [AttachedPayment(dl, eo)])
1152+ let ha = if ((en > 0))
1153+ then invoke(gS, "put", nil, [AttachedPayment(dk, en)])
11561154 else nil
1157- if ((hb == hb))
1155+ if ((ha == ha))
11581156 then {
1159- let hc = if (gQ)
1157+ let hb = if (gP)
11601158 then {
1161- let hd = invoke(gS, "stake", nil, [AttachedPayment(gX, em)])
1162- if ((hd == hd))
1159+ let hc = invoke(gR, "stake", nil, [AttachedPayment(gW, el)])
1160+ if ((hc == hc))
11631161 then nil
11641162 else throw("Strict value is not equal to itself.")
11651163 }
1166- else [ScriptTransfer(cQ.caller, em, gX)]
1167- let he = eT(0, 0, 0)
1168- let gj = he._1
1169- let eK = he._2
1170- let hf = if ((eK >= eS))
1164+ else [ScriptTransfer(cP.caller, el, gW)]
1165+ let hd = eS(0, 0, 0)
1166+ let gi = hd._1
1167+ let eJ = hd._2
1168+ let he = if ((eJ >= eR))
11711169 then true
1172- else aO(makeString(["updated DLp lower than current DLp", toString(eP), toString(eQ), toString(eR), toString(eS), toString(eK), toString(en), toString(eo)], " "))
1173- if ((hf == hf))
1170+ else aN(makeString(["updated DLp lower than current DLp", toString(eO), toString(eP), toString(eQ), toString(eR), toString(eJ), toString(em), toString(en)], " "))
1171+ if ((he == he))
11741172 then {
1175- let hg = value(assetInfo(bm)).quantity
1176- if ((hg == hg))
1177- then ((dC ++ hc) ++ gj)
1173+ let hf = value(assetInfo(bl)).quantity
1174+ if ((hf == hf))
1175+ then ((dB ++ hb) ++ gi)
11781176 else throw("Strict value is not equal to itself.")
11791177 }
11801178 else throw("Strict value is not equal to itself.")
11811179 }
11821180 else throw("Strict value is not equal to itself.")
11831181 }
11841182 else throw("Strict value is not equal to itself.")
11851183 }
11861184 else throw("Strict value is not equal to itself.")
11871185 }
11881186 else throw("Strict value is not equal to itself.")
11891187 }
11901188 else throw("Strict value is not equal to itself.")
11911189 }
11921190 else throw("Strict value is not equal to itself.")
11931191 }
11941192 else throw("Strict value is not equal to itself.")
11951193 }
11961194 else throw("Strict value is not equal to itself.")
11971195 }
11981196 }
11991197
12001198
12011199
1202-@Callable(cQ)
1203-func putOneTknV2 (fN,gQ) = {
1204- let hh = {
1205- let aT = invoke(aR, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
1206- if ($isInstanceOf(aT, "Boolean"))
1207- then aT
1208- else throw(($getType(aT) + " couldn't be cast to Boolean"))
1200+@Callable(cP)
1201+func putOneTknV2 (fM,gP) = {
1202+ let hg = {
1203+ let aS = invoke(aQ, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
1204+ if ($isInstanceOf(aS, "Boolean"))
1205+ then aS
1206+ else throw(($getType(aS) + " couldn't be cast to Boolean"))
12091207 }
1210- let hi = if (if (if (aW())
1208+ let hh = if (if (if (aV())
12111209 then true
1212- else (bl == r))
1210+ else (bk == q))
12131211 then true
1214- else (bl == t))
1212+ else (bk == s))
12151213 then true
1216- else hh
1217- let gH = [if (if (!(hi))
1214+ else hg
1215+ let gG = [if (if (!(hh))
12181216 then true
1219- else gp(cQ))
1217+ else go(cP))
12201218 then true
1221- else aO("put operation is blocked by admin"), if ((size(cQ.payments) == 1))
1219+ else aN("put operation is blocked by admin"), if ((size(cP.payments) == 1))
12221220 then true
1223- else aO("exactly 1 payment are expected")]
1224- if ((gH == gH))
1221+ else aN("exactly 1 payment are expected")]
1222+ if ((gG == gG))
12251223 then {
1224+ let dj = toBase58String(value(bm))
12261225 let dk = toBase58String(value(bn))
1227- let dl = toBase58String(value(bo))
1228- let dj = bm
1226+ let di = bl
1227+ let fQ = bo
12291228 let fR = bp
1230- let fS = bq
1231- let di = if ((cQ.caller == this))
1232- then cQ.originCaller
1233- else cQ.caller
1234- let fl = value(cQ.payments[0])
1235- let dg = toBase58String(value(fl.assetId))
1236- let dM = fl.amount
1237- let eS = if ((fl.assetId == bn))
1238- then eL(toBigInt(dM), toBigInt(0), toBigInt(0))
1239- else eL(toBigInt(0), toBigInt(dM), toBigInt(0))
1240- if ((eS == eS))
1229+ let dh = if ((cP.caller == this))
1230+ then cP.originCaller
1231+ else cP.caller
1232+ let fk = value(cP.payments[0])
1233+ let df = toBase58String(value(fk.assetId))
1234+ let dL = fk.amount
1235+ let eR = if ((fk.assetId == bm))
1236+ then eK(toBigInt(dL), toBigInt(0), toBigInt(0))
1237+ else eK(toBigInt(0), toBigInt(dL), toBigInt(0))
1238+ if ((eR == eR))
12411239 then {
1242- let hj = fq(dM, dg, toString(di), toBase58String(cQ.transactionId), true)
1243- if ((hj == hj))
1240+ let hi = fp(dL, df, toString(dh), toBase58String(cP.transactionId), true)
1241+ if ((hi == hi))
12441242 then {
1245- let cy = hj._3
1246- let dC = hj._2
1247- let hk = hj._1
1248- let em = if (if ((fN > 0))
1249- then (fN > hk)
1243+ let cx = hi._3
1244+ let dB = hi._2
1245+ let hj = hi._1
1246+ let el = if (if ((fM > 0))
1247+ then (fM > hj)
12501248 else false)
1251- then aO(makeString(["amount to receive is less than ", toString(fN)], ""))
1252- else hk
1253- let gW = invoke(aR, "emit", [em], nil)
1254- if ((gW == gW))
1249+ then aN(makeString(["amount to receive is less than ", toString(fM)], ""))
1250+ else hj
1251+ let gV = invoke(aQ, "emit", [el], nil)
1252+ if ((gV == gV))
12551253 then {
1256- let gY = {
1257- let gm = gW
1258- if ($isInstanceOf(gm, "Address"))
1254+ let gX = {
1255+ let gl = gV
1256+ if ($isInstanceOf(gl, "Address"))
12591257 then {
1260- let gZ = gm
1261- invoke(gZ, "emit", [em], nil)
1258+ let gY = gl
1259+ invoke(gY, "emit", [el], nil)
12621260 }
12631261 else unit
12641262 }
1265- if ((gY == gY))
1263+ if ((gX == gX))
12661264 then {
1267- let hc = if (gQ)
1265+ let hb = if (gP)
12681266 then {
1269- let hd = invoke(bv, "stake", nil, [AttachedPayment(dj, em)])
1270- if ((hd == hd))
1267+ let hc = invoke(bu, "stake", nil, [AttachedPayment(di, el)])
1268+ if ((hc == hc))
12711269 then nil
12721270 else throw("Strict value is not equal to itself.")
12731271 }
1274- else [ScriptTransfer(cQ.caller, em, dj)]
1275- let gd = if ((cy > 0))
1276- then [ScriptTransfer(aY, cy, fromBase58String(dg))]
1272+ else [ScriptTransfer(cP.caller, el, di)]
1273+ let gc = if ((cx > 0))
1274+ then [ScriptTransfer(aX, cx, fromBase58String(df))]
12771275 else nil
1278- let hl = if ((this == aY))
1276+ let hk = if ((this == aX))
12791277 then $Tuple2(0, 0)
12801278 else {
1281- let hm = if ((fl.assetId == bn))
1279+ let hl = if ((fk.assetId == bm))
12821280 then true
12831281 else false
1284- if (hm)
1285- then $Tuple2(-(cy), 0)
1286- else $Tuple2(0, -(cy))
1282+ if (hl)
1283+ then $Tuple2(-(cx), 0)
1284+ else $Tuple2(0, -(cx))
12871285 }
1288- let eU = hl._1
1289- let eV = hl._2
1290- let hn = eT(eU, eV, 0)
1291- let gj = hn._1
1292- let eK = hn._2
1293- let gk = eX(eS, eK)
1294- if ((gk == gk))
1295- then $Tuple2((((dC ++ hc) ++ gd) ++ gj), em)
1286+ let eT = hk._1
1287+ let eU = hk._2
1288+ let hm = eS(eT, eU, 0)
1289+ let gi = hm._1
1290+ let eJ = hm._2
1291+ let gj = eW(eR, eJ)
1292+ if ((gj == gj))
1293+ then $Tuple2((((dB ++ hb) ++ gc) ++ gi), el)
12961294 else throw("Strict value is not equal to itself.")
12971295 }
12981296 else throw("Strict value is not equal to itself.")
12991297 }
13001298 else throw("Strict value is not equal to itself.")
13011299 }
13021300 else throw("Strict value is not equal to itself.")
13031301 }
13041302 else throw("Strict value is not equal to itself.")
13051303 }
13061304 else throw("Strict value is not equal to itself.")
13071305 }
13081306
13091307
13101308
1311-@Callable(cQ)
1312-func putForFree (ho) = if ((0 > ho))
1309+@Callable(cP)
1310+func putForFree (hn) = if ((0 > hn))
13131311 then throw("Wrong slpg")
1314- else if ((size(cQ.payments) != 2))
1312+ else if ((size(cP.payments) != 2))
13151313 then throw("2 pmnts expd")
13161314 else {
1317- let hp = fm(toString(cQ.caller), toBase58String(cQ.transactionId), AttachedPayment(value(cQ.payments[0]).assetId, value(cQ.payments[0]).amount), cQ.payments[1], ho, false, false, true, 0, "")
1318- let dC = hp._9
1319- let gU = toBigInt(value(cQ.payments[0]).amount)
1320- let gV = toBigInt(value(cQ.payments[1]).amount)
1321- let eS = eL(gU, gV, toBigInt(0))
1322- if ((eS == eS))
1315+ let ho = fl(toString(cP.caller), toBase58String(cP.transactionId), AttachedPayment(value(cP.payments[0]).assetId, value(cP.payments[0]).amount), cP.payments[1], hn, false, false, true, 0, "")
1316+ let dB = ho._9
1317+ let gT = toBigInt(value(cP.payments[0]).amount)
1318+ let gU = toBigInt(value(cP.payments[1]).amount)
1319+ let eR = eK(gT, gU, toBigInt(0))
1320+ if ((eR == eR))
13231321 then {
1324- let hq = eT(0, 0, 0)
1325- let gj = hq._1
1326- let eK = hq._2
1327- let gk = eX(eS, eK)
1328- if ((gk == gk))
1329- then (dC ++ gj)
1322+ let hp = eS(0, 0, 0)
1323+ let gi = hp._1
1324+ let eJ = hp._2
1325+ let gj = eW(eR, eJ)
1326+ if ((gj == gj))
1327+ then (dB ++ gi)
13301328 else throw("Strict value is not equal to itself.")
13311329 }
13321330 else throw("Strict value is not equal to itself.")
13331331 }
13341332
13351333
13361334
1337-@Callable(cQ)
1335+@Callable(cP)
13381336 func get () = {
1339- let eS = eL(toBigInt(0), toBigInt(0), toBigInt(0))
1340- if ((eS == eS))
1337+ let eR = eK(toBigInt(0), toBigInt(0), toBigInt(0))
1338+ if ((eR == eR))
13411339 then {
1342- let dY = fk(cQ)
1343- let hr = dY._1
1344- let dB = dY._2
1345- let dM = dY._3
1346- let dg = dY._4
1347- let dC = dY._5
1348- let ez = invoke(aR, "burn", [dM], [AttachedPayment(dg, dM)])
1349- if ((ez == ez))
1340+ let dX = fj(cP)
1341+ let hq = dX._1
1342+ let dA = dX._2
1343+ let dL = dX._3
1344+ let df = dX._4
1345+ let dB = dX._5
1346+ let ey = invoke(aQ, "burn", [dL], [AttachedPayment(df, dL)])
1347+ if ((ey == ey))
13501348 then {
1351- let hs = eT(-(hr), -(dB), 0)
1352- let gj = hs._1
1353- let eK = hs._2
1354- let gk = eX(eS, eK)
1355- if ((gk == gk))
1356- then (dC ++ gj)
1349+ let hr = eS(-(hq), -(dA), 0)
1350+ let gi = hr._1
1351+ let eJ = hr._2
1352+ let gj = eW(eR, eJ)
1353+ if ((gj == gj))
1354+ then (dB ++ gi)
13571355 else throw("Strict value is not equal to itself.")
13581356 }
13591357 else throw("Strict value is not equal to itself.")
13601358 }
13611359 else throw("Strict value is not equal to itself.")
13621360 }
13631361
13641362
13651363
1366-@Callable(cQ)
1367-func getOneTknV2 (fM,fN) = {
1368- let hh = {
1369- let aT = invoke(aR, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
1370- if ($isInstanceOf(aT, "Boolean"))
1371- then aT
1372- else throw(($getType(aT) + " couldn't be cast to Boolean"))
1364+@Callable(cP)
1365+func getOneTknV2 (fL,fM) = {
1366+ let hg = {
1367+ let aS = invoke(aQ, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
1368+ if ($isInstanceOf(aS, "Boolean"))
1369+ then aS
1370+ else throw(($getType(aS) + " couldn't be cast to Boolean"))
13731371 }
1374- let ht = if (if (aW())
1372+ let hs = if (if (aV())
13751373 then true
1376- else (bl == t))
1374+ else (bk == s))
13771375 then true
1378- else hh
1379- let gH = [if (if (!(ht))
1376+ else hg
1377+ let gG = [if (if (!(hs))
13801378 then true
1381- else gp(cQ))
1379+ else go(cP))
13821380 then true
1383- else aO("get operation is blocked by admin"), if ((size(cQ.payments) == 1))
1381+ else aN("get operation is blocked by admin"), if ((size(cP.payments) == 1))
13841382 then true
1385- else aO("exactly 1 payment are expected")]
1386- if ((gH == gH))
1383+ else aN("exactly 1 payment are expected")]
1384+ if ((gG == gG))
13871385 then {
1388- let hu = fL(fM, fN, cQ.payments, cQ.caller, cQ.originCaller, cQ.transactionId)
1389- let dC = hu._1
1390- let fW = hu._2
1391- $Tuple2(dC, fW)
1386+ let ht = fK(fL, fM, cP.payments, cP.caller, cP.originCaller, cP.transactionId)
1387+ let dB = ht._1
1388+ let fV = ht._2
1389+ $Tuple2(dB, fV)
13921390 }
13931391 else throw("Strict value is not equal to itself.")
13941392 }
13951393
13961394
13971395
1398-@Callable(cQ)
1396+@Callable(cP)
13991397 func refreshDLp () = {
1400- let hv = valueOrElse(getInteger(ar), 0)
1401- let hw = if (((height - hv) >= au))
1398+ let hu = valueOrElse(getInteger(aq), 0)
1399+ let hv = if (((height - hu) >= at))
14021400 then unit
1403- else aO(makeString([toString(au), " blocks have not passed since the previous call"], ""))
1404- if ((hw == hw))
1401+ else aN(makeString([toString(at), " blocks have not passed since the previous call"], ""))
1402+ if ((hv == hv))
14051403 then {
1406- let fe = valueOrErrorMessage(parseBigInt(valueOrElse(getString(this, aq), "0")), aQ("invalid dLp"))
1407- let hx = eT(0, 0, 0)
1408- let hy = hx._1
1409- let eK = hx._2
1410- let eW = if ((fe != eK))
1411- then hy
1412- else aO("nothing to refresh")
1413- $Tuple2(eW, toString(eK))
1404+ let fd = valueOrErrorMessage(parseBigInt(valueOrElse(getString(this, ap), "0")), aP("invalid dLp"))
1405+ let hw = eS(0, 0, 0)
1406+ let hx = hw._1
1407+ let eJ = hw._2
1408+ let eV = if ((fd != eJ))
1409+ then hx
1410+ else aN("nothing to refresh")
1411+ $Tuple2(eV, toString(eJ))
14141412 }
14151413 else throw("Strict value is not equal to itself.")
14161414 }
14171415
14181416
14191417
1420-@Callable(cQ)
1421-func getOneTknV2READONLY (fM,hz) = {
1418+@Callable(cP)
1419+func getOneTknV2READONLY (fL,hy) = {
1420+ let dj = toBase58String(value(bm))
14221421 let dk = toBase58String(value(bn))
1423- let dl = toBase58String(value(bo))
1424- let dj = toBase58String(value(bm))
1425- let cA = [toBigInt(bO(dk)), toBigInt(bO(dl))]
1426- let eJ = toBigInt(valueOrErrorMessage(assetInfo(fromBase58String(dj)), "invalid lp asset").quantity)
1427- let cc = cz(cA)
1428- let cb = (cc - fraction(toBigInt(hz), cc, eJ))
1429- let hA = if ((fM == dk))
1422+ let di = toBase58String(value(bl))
1423+ let cz = [toBigInt(bN(dj)), toBigInt(bN(dk))]
1424+ let eI = toBigInt(valueOrErrorMessage(assetInfo(fromBase58String(di)), "invalid lp asset").quantity)
1425+ let cb = cy(cz)
1426+ let ca = (cb - fraction(toBigInt(hy), cb, eI))
1427+ let hz = if ((fL == dj))
14301428 then 0
1431- else if ((fM == dl))
1429+ else if ((fL == dk))
14321430 then 1
14331431 else throw("invalid out asset id")
1434- let hB = et(cA, hA, cb)
1435- let gA = (cA[hA] - hB)
1436- let gB = max([0, toInt((gA - f))])
1437- let hC = cw(gB, aU)
1438- let fV = hC._1
1439- let cy = hC._2
1440- $Tuple2(nil, $Tuple2(fV, cy))
1432+ let hA = es(cz, hz, ca)
1433+ let gz = (cz[hz] - hA)
1434+ let gA = max([0, toInt((gz - f))])
1435+ let hB = cv(gA, aT)
1436+ let fU = hB._1
1437+ let cx = hB._2
1438+ $Tuple2(nil, $Tuple2(fU, cx))
14411439 }
14421440
14431441
14441442
1445-@Callable(cQ)
1446-func getOneTknV2WithBonusREADONLY (fM,hz) = {
1443+@Callable(cP)
1444+func getOneTknV2WithBonusREADONLY (fL,hy) = {
1445+ let dj = toBase58String(value(bm))
14471446 let dk = toBase58String(value(bn))
1448- let dl = toBase58String(value(bo))
1449- let dj = toBase58String(value(bm))
1450- let dq = bO(dk)
1451- let ds = bO(dl)
1452- let hD = {
1453- let aT = invoke(this, "getOneTknV2READONLY", [fM, hz], nil)
1454- if ($isInstanceOf(aT, "(Int, Int)"))
1455- then aT
1456- else throw(($getType(aT) + " couldn't be cast to (Int, Int)"))
1447+ let di = toBase58String(value(bl))
1448+ let dp = bN(dj)
1449+ let dr = bN(dk)
1450+ let hC = {
1451+ let aS = invoke(this, "getOneTknV2READONLY", [fL, hy], nil)
1452+ if ($isInstanceOf(aS, "(Int, Int)"))
1453+ then aS
1454+ else throw(($getType(aS) + " couldn't be cast to (Int, Int)"))
14571455 }
1458- let fV = hD._1
1459- let cy = hD._2
1460- let dY = de("", dj, hz, this)
1461- let dA = dY._1
1462- let dB = dY._2
1463- let hE = (dA + dB)
1464- let fK = if ((hE == 0))
1465- then if ((fV == 0))
1456+ let fU = hC._1
1457+ let cx = hC._2
1458+ let dX = dd("", di, hy, this)
1459+ let dz = dX._1
1460+ let dA = dX._2
1461+ let hD = (dz + dA)
1462+ let fJ = if ((hD == 0))
1463+ then if ((fU == 0))
14661464 then 0
14671465 else throw("bonus calculation error")
1468- else fraction((fV - hE), a, hE)
1469- $Tuple2(nil, $Tuple3(fV, cy, fK))
1466+ else fraction((fU - hD), a, hD)
1467+ $Tuple2(nil, $Tuple3(fU, cx, fJ))
14701468 }
14711469
14721470
14731471
1474-@Callable(cQ)
1475-func getNoLess (hF,hG) = {
1476- let dY = fk(cQ)
1477- let dA = dY._1
1478- let dB = dY._2
1479- let dM = dY._3
1480- let dg = dY._4
1481- let dC = dY._5
1482- if ((hF > dA))
1483- then throw(((("Failed: " + toString(dA)) + " < ") + toString(hF)))
1484- else if ((hG > dB))
1485- then throw(((("Failed: " + toString(dB)) + " < ") + toString(hG)))
1472+@Callable(cP)
1473+func getNoLess (hE,hF) = {
1474+ let dX = fj(cP)
1475+ let dz = dX._1
1476+ let dA = dX._2
1477+ let dL = dX._3
1478+ let df = dX._4
1479+ let dB = dX._5
1480+ if ((hE > dz))
1481+ then throw(((("Failed: " + toString(dz)) + " < ") + toString(hE)))
1482+ else if ((hF > dA))
1483+ then throw(((("Failed: " + toString(dA)) + " < ") + toString(hF)))
14861484 else {
1487- let eS = eL(toBigInt(0), toBigInt(0), toBigInt(0))
1488- if ((eS == eS))
1485+ let eR = eK(toBigInt(0), toBigInt(0), toBigInt(0))
1486+ if ((eR == eR))
14891487 then {
1490- let hH = invoke(aR, "burn", [dM], [AttachedPayment(dg, dM)])
1491- if ((hH == hH))
1488+ let hG = invoke(aQ, "burn", [dL], [AttachedPayment(df, dL)])
1489+ if ((hG == hG))
14921490 then {
1493- let hI = eT(-(dA), -(dB), 0)
1494- let gj = hI._1
1495- let eK = hI._2
1496- let gk = eX(eS, eK)
1497- if ((gk == gk))
1498- then (dC ++ gj)
1491+ let hH = eS(-(dz), -(dA), 0)
1492+ let gi = hH._1
1493+ let eJ = hH._2
1494+ let gj = eW(eR, eJ)
1495+ if ((gj == gj))
1496+ then (dB ++ gi)
14991497 else throw("Strict value is not equal to itself.")
15001498 }
15011499 else throw("Strict value is not equal to itself.")
15021500 }
15031501 else throw("Strict value is not equal to itself.")
15041502 }
15051503 }
15061504
15071505
15081506
1509-@Callable(cQ)
1510-func unstakeAndGet (cx) = {
1511- let hJ = if ((size(cQ.payments) != 0))
1507+@Callable(cP)
1508+func unstakeAndGet (cw) = {
1509+ let hI = if ((size(cP.payments) != 0))
15121510 then throw("No pmnts expd")
15131511 else true
1514- if ((hJ == hJ))
1512+ if ((hI == hI))
15151513 then {
1516- let hK = bt()
1517- let gX = bm
1518- let hL = valueOrErrorMessage(addressFromString(hK[D]), "Wr st addr")
1519- let eS = eL(toBigInt(0), toBigInt(0), toBigInt(0))
1520- if ((eS == eS))
1514+ let hJ = bs()
1515+ let gW = bl
1516+ let hK = valueOrErrorMessage(addressFromString(hJ[C]), "Wr st addr")
1517+ let eR = eK(toBigInt(0), toBigInt(0), toBigInt(0))
1518+ if ((eR == eR))
15211519 then {
1522- let hM = invoke(hL, "unstake", [toBase58String(gX), cx], nil)
1523- if ((hM == hM))
1520+ let hL = invoke(hK, "unstake", [toBase58String(gW), cw], nil)
1521+ if ((hL == hL))
15241522 then {
1525- let dY = de(toBase58String(cQ.transactionId), toBase58String(gX), cx, cQ.caller)
1526- let dA = dY._1
1527- let dB = dY._2
1528- let do = parseIntValue(dY._9)
1529- let dC = dY._10
1530- let hN = if (if (aW())
1523+ let dX = dd(toBase58String(cP.transactionId), toBase58String(gW), cw, cP.caller)
1524+ let dz = dX._1
1525+ let dA = dX._2
1526+ let dn = parseIntValue(dX._9)
1527+ let dB = dX._10
1528+ let hM = if (if (aV())
15311529 then true
1532- else (do == t))
1533- then throw(("Blocked: " + toString(do)))
1530+ else (dn == s))
1531+ then throw(("Blocked: " + toString(dn)))
15341532 else true
1535- if ((hN == hN))
1533+ if ((hM == hM))
15361534 then {
1537- let hO = invoke(aR, "burn", [cx], [AttachedPayment(gX, cx)])
1538- if ((hO == hO))
1535+ let hN = invoke(aQ, "burn", [cw], [AttachedPayment(gW, cw)])
1536+ if ((hN == hN))
15391537 then {
1540- let hP = eT(-(dA), -(dB), 0)
1541- let gj = hP._1
1542- let eK = hP._2
1543- let gk = eX(eS, eK)
1544- if ((gk == gk))
1545- then (dC ++ gj)
1538+ let hO = eS(-(dz), -(dA), 0)
1539+ let gi = hO._1
1540+ let eJ = hO._2
1541+ let gj = eW(eR, eJ)
1542+ if ((gj == gj))
1543+ then (dB ++ gi)
15461544 else throw("Strict value is not equal to itself.")
15471545 }
15481546 else throw("Strict value is not equal to itself.")
15491547 }
15501548 else throw("Strict value is not equal to itself.")
15511549 }
15521550 else throw("Strict value is not equal to itself.")
15531551 }
15541552 else throw("Strict value is not equal to itself.")
15551553 }
15561554 else throw("Strict value is not equal to itself.")
15571555 }
15581556
15591557
15601558
1561-@Callable(cQ)
1562-func unstakeAndGetNoLess (hQ,hR,hG) = {
1563- let ht = if (aW())
1559+@Callable(cP)
1560+func unstakeAndGetNoLess (hP,hQ,hF) = {
1561+ let hs = if (aV())
15641562 then true
1565- else (bl == t)
1566- let gH = [if (!(ht))
1563+ else (bk == s)
1564+ let gG = [if (!(hs))
15671565 then true
1568- else throw("get operation is blocked by admin"), if ((size(cQ.payments) == 0))
1566+ else throw("get operation is blocked by admin"), if ((size(cP.payments) == 0))
15691567 then true
15701568 else throw("no payments are expected")]
1571- if ((gH == gH))
1569+ if ((gG == gG))
15721570 then {
1573- let eS = eL(toBigInt(0), toBigInt(0), toBigInt(0))
1574- if ((eS == eS))
1571+ let eR = eK(toBigInt(0), toBigInt(0), toBigInt(0))
1572+ if ((eR == eR))
15751573 then {
1576- let hM = invoke(bv, "unstake", [toBase58String(bm), hQ], nil)
1577- if ((hM == hM))
1574+ let hL = invoke(bu, "unstake", [toBase58String(bl), hP], nil)
1575+ if ((hL == hL))
15781576 then {
1579- let hS = de(toBase58String(cQ.transactionId), toBase58String(bm), hQ, cQ.caller)
1580- let dA = hS._1
1581- let dB = hS._2
1582- let dC = hS._10
1583- let hT = [if ((dA >= hR))
1577+ let hR = dd(toBase58String(cP.transactionId), toBase58String(bl), hP, cP.caller)
1578+ let dz = hR._1
1579+ let dA = hR._2
1580+ let dB = hR._10
1581+ let hS = [if ((dz >= hQ))
15841582 then true
1585- else throw(makeString(["amount asset amount to receive is less than ", toString(hR)], "")), if ((dB >= hG))
1583+ else throw(makeString(["amount asset amount to receive is less than ", toString(hQ)], "")), if ((dA >= hF))
15861584 then true
1587- else throw(makeString(["price asset amount to receive is less than ", toString(hG)], ""))]
1588- if ((hT == hT))
1585+ else throw(makeString(["price asset amount to receive is less than ", toString(hF)], ""))]
1586+ if ((hS == hS))
15891587 then {
1590- let hH = invoke(aR, "burn", [hQ], [AttachedPayment(bm, hQ)])
1591- if ((hH == hH))
1588+ let hG = invoke(aQ, "burn", [hP], [AttachedPayment(bl, hP)])
1589+ if ((hG == hG))
15921590 then {
1593- let hU = eT(-(dA), -(dB), 0)
1594- let gj = hU._1
1595- let eK = hU._2
1596- let gk = eX(eS, eK)
1597- if ((gk == gk))
1598- then (dC ++ gj)
1591+ let hT = eS(-(dz), -(dA), 0)
1592+ let gi = hT._1
1593+ let eJ = hT._2
1594+ let gj = eW(eR, eJ)
1595+ if ((gj == gj))
1596+ then (dB ++ gi)
15991597 else throw("Strict value is not equal to itself.")
16001598 }
16011599 else throw("Strict value is not equal to itself.")
16021600 }
16031601 else throw("Strict value is not equal to itself.")
16041602 }
16051603 else throw("Strict value is not equal to itself.")
16061604 }
16071605 else throw("Strict value is not equal to itself.")
16081606 }
16091607 else throw("Strict value is not equal to itself.")
16101608 }
16111609
16121610
16131611
1614-@Callable(cQ)
1615-func unstakeAndGetOneTknV2 (hQ,fM,fN) = {
1616- let hh = {
1617- let aT = invoke(aR, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
1618- if ($isInstanceOf(aT, "Boolean"))
1619- then aT
1620- else throw(($getType(aT) + " couldn't be cast to Boolean"))
1612+@Callable(cP)
1613+func unstakeAndGetOneTknV2 (hP,fL,fM) = {
1614+ let hg = {
1615+ let aS = invoke(aQ, "isPoolOneTokenOperationsDisabledREADONLY", [toString(this)], nil)
1616+ if ($isInstanceOf(aS, "Boolean"))
1617+ then aS
1618+ else throw(($getType(aS) + " couldn't be cast to Boolean"))
16211619 }
1622- let ht = if (if (aW())
1620+ let hs = if (if (aV())
16231621 then true
1624- else (bl == t))
1622+ else (bk == s))
16251623 then true
1626- else hh
1627- let gH = [if (if (!(ht))
1624+ else hg
1625+ let gG = [if (if (!(hs))
16281626 then true
1629- else gp(cQ))
1627+ else go(cP))
16301628 then true
1631- else aO("get operation is blocked by admin"), if ((size(cQ.payments) == 0))
1629+ else aN("get operation is blocked by admin"), if ((size(cP.payments) == 0))
16321630 then true
1633- else aO("no payments are expected")]
1634- if ((gH == gH))
1631+ else aN("no payments are expected")]
1632+ if ((gG == gG))
16351633 then {
1636- let hK = bt()
1637- let gX = bm
1638- let hL = valueOrErrorMessage(addressFromString(hK[D]), "Wr st addr")
1639- let hM = invoke(hL, "unstake", [toBase58String(gX), hQ], nil)
1640- if ((hM == hM))
1634+ let hJ = bs()
1635+ let gW = bl
1636+ let hK = valueOrErrorMessage(addressFromString(hJ[C]), "Wr st addr")
1637+ let hL = invoke(hK, "unstake", [toBase58String(gW), hP], nil)
1638+ if ((hL == hL))
16411639 then {
1642- let hV = fL(fM, fN, [AttachedPayment(gX, hQ)], cQ.caller, cQ.originCaller, cQ.transactionId)
1643- let dC = hV._1
1644- let fW = hV._2
1645- $Tuple2(dC, fW)
1640+ let hU = fK(fL, fM, [AttachedPayment(gW, hP)], cP.caller, cP.originCaller, cP.transactionId)
1641+ let dB = hU._1
1642+ let fV = hU._2
1643+ $Tuple2(dB, fV)
16461644 }
16471645 else throw("Strict value is not equal to itself.")
16481646 }
16491647 else throw("Strict value is not equal to itself.")
16501648 }
16511649
16521650
16531651
1654-@Callable(cQ)
1655-func putOneTknV2WithBonusREADONLY (hW,hX) = {
1656- let hY = fq(hW, hX, "", "", true)
1657- let fF = hY._1
1658- let dC = hY._2
1659- let cy = hY._3
1660- let fK = hY._4
1661- $Tuple2(nil, $Tuple3(fF, cy, fK))
1652+@Callable(cP)
1653+func putOneTknV2WithBonusREADONLY (hV,hW) = {
1654+ let hX = fp(hV, hW, "", "", true)
1655+ let fE = hX._1
1656+ let dB = hX._2
1657+ let cx = hX._3
1658+ let fJ = hX._4
1659+ $Tuple2(nil, $Tuple3(fE, cx, fJ))
16621660 }
16631661
16641662
16651663
1666-@Callable(cQ)
1667-func putOneTknV2WithoutTakeFeeREADONLY (hW,hX) = {
1668- let hZ = fq(hW, hX, "", "", false)
1669- let fF = hZ._1
1670- let dC = hZ._2
1671- let cy = hZ._3
1672- let fK = hZ._4
1673- $Tuple2(nil, $Tuple3(fF, cy, fK))
1664+@Callable(cP)
1665+func putOneTknV2WithoutTakeFeeREADONLY (hV,hW) = {
1666+ let hY = fp(hV, hW, "", "", false)
1667+ let fE = hY._1
1668+ let dB = hY._2
1669+ let cx = hY._3
1670+ let fJ = hY._4
1671+ $Tuple2(nil, $Tuple3(fE, cx, fJ))
16741672 }
16751673
16761674
16771675
1678-@Callable(cQ)
1679-func activate (ia,ib) = if ((toString(cQ.caller) != toString(aR)))
1676+@Callable(cP)
1677+func activate (hZ,ia) = if ((toString(cP.caller) != toString(aQ)))
16801678 then throw("denied")
1681- else $Tuple2([StringEntry(ak(), ia), StringEntry(al(), ib)], "success")
1679+ else $Tuple2([StringEntry(aj(), hZ), StringEntry(ak(), ia)], "success")
16821680
16831681
16841682
1685-@Callable(cQ)
1686-func setS (ic,hN) = if ((toString(cQ.caller) != aK(this, an())))
1687- then go
1688- else [StringEntry(ic, hN)]
1683+@Callable(cP)
1684+func setS (ib,hM) = if ((toString(cP.caller) != aJ(this, am())))
1685+ then gn
1686+ else [StringEntry(ib, hM)]
16891687
16901688
16911689
1692-@Callable(cQ)
1693-func setI (ic,hN) = if ((toString(cQ.caller) != aK(this, an())))
1694- then go
1695- else [IntegerEntry(ic, hN)]
1690+@Callable(cP)
1691+func setI (ib,hM) = if ((toString(cP.caller) != aJ(this, am())))
1692+ then gn
1693+ else [IntegerEntry(ib, hM)]
16961694
16971695
16981696
1699-@Callable(cQ)
1700-func getPoolConfigWrapperREADONLY () = $Tuple2(nil, aZ())
1697+@Callable(cP)
1698+func getPoolConfigWrapperREADONLY () = $Tuple2(nil, aY())
17011699
17021700
17031701
1704-@Callable(cQ)
1705-func getAccBalanceWrapperREADONLY (bP) = $Tuple2(nil, bO(bP))
1702+@Callable(cP)
1703+func getAccBalanceWrapperREADONLY (bO) = $Tuple2(nil, bN(bO))
17061704
17071705
17081706
1709-@Callable(cQ)
1710-func calcPricesWrapperREADONLY (ci,cj,cn) = {
1711- let id = cm(ci, cj, cn)
1712- $Tuple2(nil, [toString(id[0]), toString(id[1]), toString(id[2])])
1707+@Callable(cP)
1708+func calcPricesWrapperREADONLY (ch,ci,cm) = {
1709+ let ic = cl(ch, ci, cm)
1710+ $Tuple2(nil, [toString(ic[0]), toString(ic[1]), toString(ic[2])])
17131711 }
17141712
17151713
17161714
1717-@Callable(cQ)
1718-func fromX18WrapperREADONLY (N,ie) = $Tuple2(nil, M(parseBigIntValue(N), ie))
1715+@Callable(cP)
1716+func fromX18WrapperREADONLY (M,id) = $Tuple2(nil, L(parseBigIntValue(M), id))
17191717
17201718
17211719
1722-@Callable(cQ)
1723-func toX18WrapperREADONLY (J,K) = $Tuple2(nil, toString(I(J, K)))
1720+@Callable(cP)
1721+func toX18WrapperREADONLY (I,J) = $Tuple2(nil, toString(H(I, J)))
17241722
17251723
17261724
1727-@Callable(cQ)
1728-func calcPriceBigIntWrapperREADONLY (bR,bS) = $Tuple2(nil, toString(bQ(parseBigIntValue(bR), parseBigIntValue(bS))))
1725+@Callable(cP)
1726+func calcPriceBigIntWrapperREADONLY (bQ,bR) = $Tuple2(nil, toString(bP(parseBigIntValue(bQ), parseBigIntValue(bR))))
17291727
17301728
17311729
1732-@Callable(cQ)
1733-func estimatePutOperationWrapperREADONLY (df,bX,dE,dF,dG,dH,if,dI,dJ) = $Tuple2(nil, dD(df, bX, dE, dF, dG, dH, if, dI, dJ, true, false, 0, ""))
1730+@Callable(cP)
1731+func estimatePutOperationWrapperREADONLY (de,bW,dD,dE,dF,dG,ie,dH,dI) = $Tuple2(nil, dC(de, bW, dD, dE, dF, dG, ie, dH, dI, true, false, 0, ""))
17341732
17351733
17361734
1737-@Callable(cQ)
1738-func estimateGetOperationWrapperREADONLY (df,ig,dh,if) = {
1739- let dY = de(df, ig, dh, addressFromStringValue(if))
1740- $Tuple2(nil, $Tuple10(dY._1, dY._2, dY._3, dY._4, dY._5, dY._6, dY._7, toString(dY._8), dY._9, dY._10))
1735+@Callable(cP)
1736+func estimateGetOperationWrapperREADONLY (de,if,dg,ie) = {
1737+ let dX = dd(de, if, dg, addressFromStringValue(ie))
1738+ $Tuple2(nil, $Tuple10(dX._1, dX._2, dX._3, dX._4, dX._5, dX._6, dX._7, toString(dX._8), dX._9, dX._10))
17411739 }
17421740
17431741
1744-@Verifier(ih)
1745-func ii () = {
1746- let ij = {
1747- let gm = gl()
1748- if ($isInstanceOf(gm, "ByteVector"))
1742+@Verifier(ig)
1743+func ih () = {
1744+ let ii = {
1745+ let gl = gk()
1746+ if ($isInstanceOf(gl, "ByteVector"))
17491747 then {
1750- let gq = gm
1751- gq
1748+ let gp = gl
1749+ gp
17521750 }
1753- else if ($isInstanceOf(gm, "Unit"))
1754- then ih.senderPublicKey
1751+ else if ($isInstanceOf(gl, "Unit"))
1752+ then ig.senderPublicKey
17551753 else throw("Match error")
17561754 }
1757- let gm = ih
1758- if ($isInstanceOf(gm, "Order"))
1755+ let gl = ig
1756+ if ($isInstanceOf(gl, "Order"))
17591757 then {
1760- let fa = gm
1761- let ik = aX()
1762- let il = eZ(fa)
1763- let aG = il._1
1764- let aH = il._2
1765- let aI = sigVerify(fa.bodyBytes, fa.proofs[0], fa.senderPublicKey)
1766- let aJ = sigVerify(fa.bodyBytes, fa.proofs[1], ik)
1767- if (if (if (aG)
1758+ let eZ = gl
1759+ let ij = aW()
1760+ let ik = eY(eZ)
1761+ let aF = ik._1
1762+ let aG = ik._2
1763+ let aH = sigVerify(eZ.bodyBytes, eZ.proofs[0], eZ.senderPublicKey)
1764+ let aI = sigVerify(eZ.bodyBytes, eZ.proofs[1], ij)
1765+ if (if (if (aF)
1766+ then aH
1767+ else false)
17681768 then aI
17691769 else false)
1770- then aJ
1771- else false)
17721770 then true
1773- else aF(aG, aH, aI, aJ)
1771+ else aE(aF, aG, aH, aI)
17741772 }
1775- else if ($isInstanceOf(gm, "SetScriptTransaction"))
1773+ else if ($isInstanceOf(gl, "SetScriptTransaction"))
17761774 then {
1777- let cD = gm
1778- if (sigVerify(ih.bodyBytes, ih.proofs[0], ij))
1775+ let cC = gl
1776+ if (sigVerify(ig.bodyBytes, ig.proofs[0], ii))
17791777 then true
17801778 else {
1781- let im = blake2b256(value(cD.script))
1782- let in = fromBase64String(value(getString(aR, aD())))
1783- let io = scriptHash(this)
1784- if ((in == im))
1785- then (io != im)
1779+ let il = blake2b256(value(cC.script))
1780+ let im = fromBase64String(value(getString(aQ, aC())))
1781+ let in = scriptHash(this)
1782+ if ((im == il))
1783+ then (in != il)
17861784 else false
17871785 }
17881786 }
1789- else sigVerify(ih.bodyBytes, ih.proofs[0], ij)
1787+ else sigVerify(ig.bodyBytes, ig.proofs[0], ii)
17901788 }
17911789

github/deemru/w8io/169f3d6 
760.13 ms