tx · 45dDeyhUhVVjpKMDBZyhGQMTpoidFAMpjSfunZ7dDsWz

3N6LHjfGb6Fgcy7YsVcNxGyPTj49XbQAijq:  -0.01300000 Waves

2023.02.10 14:38 [2443493] smart account 3N6LHjfGb6Fgcy7YsVcNxGyPTj49XbQAijq > SELF 0.00000000 Waves

{ "type": 13, "id": "45dDeyhUhVVjpKMDBZyhGQMTpoidFAMpjSfunZ7dDsWz", "fee": 1300000, "feeAssetId": null, "timestamp": 1676029101687, "version": 2, "chainId": 84, "sender": "3N6LHjfGb6Fgcy7YsVcNxGyPTj49XbQAijq", "senderPublicKey": "2u2wYYcVBQv43Cc71zkhHPPitkqgg6dqTZ3nUMvYJ1uq", "proofs": [ "5GjxwC4FsB7iPquW1Z5Jwfa4YYmFPvAgkamUNA1boS6xHpSfA98gyrtn6Tf7GRYmzTawgACYRoh2v5un9DbMhhf6" ], "script": "base64:BgIXCAISBQoDAQgIEgUKAwEICBIDCgEIEgAVAANTRVACAl9fAAhmZWVTY2FsZQkAtgIBAKCNBgEPZ2V0U3RyaW5nT3JGYWlsAQNrZXkJARN2YWx1ZU9yRXJyb3JNZXNzYWdlAgkAnQgCBQR0aGlzBQNrZXkJAKwCAgIVTm8gZGF0YSBmb3IgdGhpcy5rZXk9BQNrZXkADHBvb2xEaXNhYmxlZAkAAgECDVBvb2wgZGlzYWJsZWQADHBvb2xOb3RFeGlzdAkAAgECEVBvb2wgaXMgbm90IGV4aXN0AA5zbGlwcGFnZVRvb0JpZwkAAgECE1NsaXBwYWdlIGlzIHRvbyBiaWcBE2tleU1hbmFnZXJQdWJsaWNLZXkAAhQlc19fbWFuYWdlclB1YmxpY0tleQEaa2V5UGVuZGluZ01hbmFnZXJQdWJsaWNLZXkAAhslc19fcGVuZGluZ01hbmFnZXJQdWJsaWNLZXkBAmZjAAITJXNfX2ZhY3RvcnlDb250cmFjdAAPZmFjdG9yeUNvbnRyYWN0CQERQGV4dHJOYXRpdmUoMTA2MikBCQEPZ2V0U3RyaW5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AWkPY2FsbGVyUHVibGljS2V5CQEFdmFsdWUBBQJwbQYJAAIBAht5b3UgYXJlIG5vdCBwZW5kaW5nIG1hbmFnZXIDCQAAAgUHY2hlY2tQTQUHY2hlY2tQTQkAzAgCCQELU3RyaW5nRW50cnkCCQETa2V5TWFuYWdlclB1YmxpY0tleQAJANgEAQkBBXZhbHVlAQUCcG0JAMwIAgkBC0RlbGV0ZUVudHJ5AQkBGmtleVBlbmRpbmdNYW5hZ2VyUHVibGljS2V5AAUDbmlsCQACAQIkU3RyaWN0IHZhbHVlIGlzIG5vdCBlcXVhbCB0byBpdHNlbGYuCQACAQIkU3RyaWN0IHZhbHVlIGlzIG5vdCBlcXVhbCB0byBpdHNlbGYuAQJ0eAEGdmVyaWZ5AAQPdGFyZ2V0UHVibGljS2V5BAckbWF0Y2gwCQEWbWFuYWdlclB1YmxpY0tleU9yVW5pdAADCQABAgUHJG1hdGNoMAIKQnl0ZVZlY3RvcgQCcGsFByRtYXRjaDAFAnBrAwkAAQIFByRtYXRjaDACBFVuaXQIBQJ0eA9zZW5kZXJQdWJsaWNLZXkJAAIBAgtNYXRjaCBlcnJvcgkA9AMDCAUCdHgJYm9keUJ5dGVzCQCRAwIIBQJ0eAZwcm9vZnMAAAUPdGFyZ2V0UHVibGljS2V5mD1w7Q==", "height": 2443493, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 8kuznLzHEABscZitMBk5NannaHhP3yZFWPby1SkdaQnb Next: 9vnSnznJu69UUXtsX2NnvoyBFyoFBCVV8ctQMf9STgLm Diff:
OldNewDifferences
3333 func n () = makeString(["%s", "protocolFee"], a)
3434
3535
36-func o (p) = {
37- let q = p
38- if ($isInstanceOf(q, "Int"))
36+func o () = makeString(["%s", "poolFee"], a)
37+
38+
39+func p (q) = {
40+ let r = q
41+ if ($isInstanceOf(r, "Int"))
3942 then {
40- let r = q
41- r
43+ let s = r
44+ s
4245 }
4346 else throw("fail to cast into Int")
4447 }
4548
4649
47-func s (t,u) = makeString(["%d%d", toString(t), toString(u)], a)
50+func t (u,v) = makeString(["%d%d", toString(u), toString(v)], a)
4851
4952
50-func v () = {
51- let q = getString(h())
52- if ($isInstanceOf(q, "String"))
53+func w () = {
54+ let r = getString(h())
55+ if ($isInstanceOf(r, "String"))
5356 then {
54- let w = q
55- fromBase58String(w)
57+ let x = r
58+ fromBase58String(x)
5659 }
57- else if ($isInstanceOf(q, "Unit"))
60+ else if ($isInstanceOf(r, "Unit"))
5861 then unit
5962 else throw("Match error")
6063 }
6164
6265
63-func x () = {
64- let q = getString(i())
65- if ($isInstanceOf(q, "String"))
66+func y () = {
67+ let r = getString(i())
68+ if ($isInstanceOf(r, "String"))
6669 then {
67- let w = q
68- fromBase58String(w)
70+ let x = r
71+ fromBase58String(x)
6972 }
70- else if ($isInstanceOf(q, "Unit"))
73+ else if ($isInstanceOf(r, "Unit"))
7174 then unit
7275 else throw("Match error")
7376 }
7477
7578
76-func y (z) = {
77- let q = v()
78- if ($isInstanceOf(q, "ByteVector"))
79+func z (A) = {
80+ let r = w()
81+ if ($isInstanceOf(r, "ByteVector"))
7982 then {
80- let A = q
81- (z.callerPublicKey == A)
83+ let B = r
84+ (A.callerPublicKey == B)
8285 }
83- else if ($isInstanceOf(q, "Unit"))
84- then (z.caller == this)
86+ else if ($isInstanceOf(r, "Unit"))
87+ then (A.caller == this)
8588 else throw("Match error")
8689 }
8790
8891
89-func B (z) = if (y(z))
92+func C (A) = if (z(A))
9093 then true
9194 else throw("permission denied")
9295
9396
94-func C (D) = if ((D == "WAVES"))
97+func D (E) = if ((E == "WAVES"))
9598 then wavesBalance(this).available
96- else assetBalance(this, fromBase58String(D))
99+ else assetBalance(this, fromBase58String(E))
97100
98101
99-@Callable(z)
100-func swapCalculateREADONLY (E,F,G) = {
101- let H = value(getInteger(n()))
102- let I = fraction(toBigInt(E), toBigInt(H), b)
103- let J = if ((toInt(I) == 0))
102+@Callable(A)
103+func swapCalculateREADONLY (F,G,H) = {
104+ let I = value(getInteger(n()))
105+ let J = fraction(toBigInt(F), toBigInt(I), b)
106+ let K = value(getInteger(o()))
107+ let L = fraction(toBigInt(F), toBigInt(K), b)
108+ let M = if ((toInt(J) == 0))
104109 then toBigInt(1)
105- else I
106- let K = (toBigInt(E) - J)
107- let L = invoke(k, "getLpAssetFromPoolAssetsREADONLY", [F, G], nil)
108- let M = invoke(k, "getLpAssetFromPoolAssetsREADONLY", [G, F], nil)
109- let N = if ((L != unit))
110+ else J
111+ let N = if ((toInt(L) == 0))
112+ then toBigInt(1)
113+ else L
114+ let O = ((toBigInt(F) - M) - L)
115+ let P = invoke(k, "getLpAssetFromPoolAssetsREADONLY", [G, H], nil)
116+ let Q = invoke(k, "getLpAssetFromPoolAssetsREADONLY", [H, G], nil)
117+ let R = if ((P != unit))
110118 then {
111- let O = false
112- let P = {
113- let Q = invoke(k, "getPoolAddressFromLpAssetREADONLY", [L], nil)
114- if ($isInstanceOf(Q, "String"))
115- then Q
116- else throw(($getType(Q) + " couldn't be cast to String"))
119+ let S = false
120+ let T = {
121+ let U = invoke(k, "getPoolAddressFromLpAssetREADONLY", [P], nil)
122+ if ($isInstanceOf(U, "String"))
123+ then U
124+ else throw(($getType(U) + " couldn't be cast to String"))
117125 }
118- $Tuple2(O, P)
126+ $Tuple2(S, T)
119127 }
120- else if ((M != unit))
128+ else if ((Q != unit))
121129 then {
122- let O = true
123- let P = {
124- let Q = invoke(k, "getPoolAddressFromLpAssetREADONLY", [M], nil)
125- if ($isInstanceOf(Q, "String"))
126- then Q
127- else throw(($getType(Q) + " couldn't be cast to String"))
130+ let S = true
131+ let T = {
132+ let U = invoke(k, "getPoolAddressFromLpAssetREADONLY", [Q], nil)
133+ if ($isInstanceOf(U, "String"))
134+ then U
135+ else throw(($getType(U) + " couldn't be cast to String"))
128136 }
129- $Tuple2(O, P)
137+ $Tuple2(S, T)
130138 }
131139 else f
132- let O = N._1
133- let P = N._2
134- let R = {
135- let Q = invoke(k, "getPoolStatusREADONLY", [P], nil)
136- if ($isInstanceOf(Q, "Int"))
137- then Q
138- else throw(($getType(Q) + " couldn't be cast to Int"))
140+ let S = R._1
141+ let T = R._2
142+ let V = {
143+ let U = invoke(k, "getPoolStatusREADONLY", [T], nil)
144+ if ($isInstanceOf(U, "Int"))
145+ then U
146+ else throw(($getType(U) + " couldn't be cast to Int"))
139147 }
140- let S = if ((R == 1))
148+ let W = if ((V == 1))
141149 then true
142150 else e
143- if ((S == S))
151+ if ((W == W))
144152 then {
145- let T = addressFromStringValue(valueOrElse(P, ""))
146- let U = {
147- let Q = invoke(T, "calculateAmountOutForSwapREADONLY", [toInt(K), O], nil)
148- if ($isInstanceOf(Q, "Int"))
149- then Q
150- else throw(($getType(Q) + " couldn't be cast to Int"))
153+ let X = addressFromStringValue(valueOrElse(T, ""))
154+ let Y = {
155+ let U = invoke(X, "calculateAmountOutForSwapREADONLY", [toInt(O), S], nil)
156+ if ($isInstanceOf(U, "Int"))
157+ then U
158+ else throw(($getType(U) + " couldn't be cast to Int"))
151159 }
152- $Tuple2(nil, U)
160+ $Tuple2(nil, Y)
153161 }
154162 else throw("Strict value is not equal to itself.")
155163 }
156164
157165
158166
159-@Callable(z)
160-func swap (V,G,W) = {
161- let X = value(z.payments[0])
162- let F = if ((X.assetId == unit))
167+@Callable(A)
168+func swap (Z,H,aa) = {
169+ let ab = value(A.payments[0])
170+ let G = if ((ab.assetId == unit))
163171 then toBytes("WAVES")
164- else value(X.assetId)
165- let E = value(X.amount)
166- let H = value(getInteger(n()))
167- let I = fraction(toBigInt(E), toBigInt(H), b)
168- let J = if ((toInt(I) == 0))
172+ else value(ab.assetId)
173+ let F = value(ab.amount)
174+ let I = value(getInteger(n()))
175+ let J = fraction(toBigInt(F), toBigInt(I), b)
176+ let K = value(getInteger(o()))
177+ let L = fraction(toBigInt(F), toBigInt(K), b)
178+ let M = if ((toInt(J) == 0))
169179 then toBigInt(1)
170- else I
171- let K = (toBigInt(E) - J)
172- let Y = [if ((size(z.payments) == 1))
180+ else J
181+ let N = if ((toInt(L) == 0))
182+ then toBigInt(1)
183+ else L
184+ let O = ((toBigInt(F) - M) - L)
185+ let ac = [if ((size(A.payments) == 1))
173186 then true
174187 else throw("exactly 1 payment are expected")]
175- if ((Y == Y))
188+ if ((ac == ac))
176189 then {
177- let L = {
178- let Q = invoke(k, "getLpAssetFromPoolAssetsREADONLY", [toBase58String(F), G], nil)
179- if ($isInstanceOf(Q, "String"))
180- then Q
190+ let P = {
191+ let U = invoke(k, "getLpAssetFromPoolAssetsREADONLY", [toBase58String(G), H], nil)
192+ if ($isInstanceOf(U, "String"))
193+ then U
181194 else unit
182195 }
183- let M = {
184- let Q = invoke(k, "getLpAssetFromPoolAssetsREADONLY", [G, toBase58String(F)], nil)
185- if ($isInstanceOf(Q, "String"))
186- then Q
196+ let Q = {
197+ let U = invoke(k, "getLpAssetFromPoolAssetsREADONLY", [H, toBase58String(G)], nil)
198+ if ($isInstanceOf(U, "String"))
199+ then U
187200 else unit
188201 }
189- let Z = if ((L != unit))
202+ let ad = if ((P != unit))
190203 then {
191- let O = false
192- let P = {
193- let Q = invoke(k, "getPoolAddressFromLpAssetREADONLY", [value(L)], nil)
194- if ($isInstanceOf(Q, "String"))
195- then Q
196- else throw(($getType(Q) + " couldn't be cast to String"))
204+ let S = false
205+ let T = {
206+ let U = invoke(k, "getPoolAddressFromLpAssetREADONLY", [value(P)], nil)
207+ if ($isInstanceOf(U, "String"))
208+ then U
209+ else throw(($getType(U) + " couldn't be cast to String"))
197210 }
198- $Tuple2(O, P)
211+ $Tuple2(S, T)
199212 }
200- else if ((M != unit))
213+ else if ((Q != unit))
201214 then {
202- let O = true
203- let P = {
204- let Q = invoke(k, "getPoolAddressFromLpAssetREADONLY", [value(M)], nil)
205- if ($isInstanceOf(Q, "String"))
206- then Q
207- else throw(($getType(Q) + " couldn't be cast to String"))
215+ let S = true
216+ let T = {
217+ let U = invoke(k, "getPoolAddressFromLpAssetREADONLY", [value(Q)], nil)
218+ if ($isInstanceOf(U, "String"))
219+ then U
220+ else throw(($getType(U) + " couldn't be cast to String"))
208221 }
209- $Tuple2(O, P)
222+ $Tuple2(S, T)
210223 }
211224 else f
212- let O = Z._1
213- let P = Z._2
214- let R = {
215- let Q = invoke(k, "getPoolStatusREADONLY", [P], nil)
216- if ($isInstanceOf(Q, "Int"))
217- then Q
218- else throw(($getType(Q) + " couldn't be cast to Int"))
225+ let S = ad._1
226+ let T = ad._2
227+ let V = {
228+ let U = invoke(k, "getPoolStatusREADONLY", [T], nil)
229+ if ($isInstanceOf(U, "Int"))
230+ then U
231+ else throw(($getType(U) + " couldn't be cast to Int"))
219232 }
220- let S = if ((R == 1))
233+ let W = if ((V == 1))
221234 then true
222235 else e
223- if ((S == S))
236+ if ((W == W))
224237 then {
225- let T = addressFromStringValue(P)
226- let aa = {
227- let Q = invoke(T, "calculateAmountOutForSwapAndSendTokens", [toInt(K), O, V, W], [AttachedPayment(F, toInt(K))])
228- if ($isInstanceOf(Q, "Int"))
229- then Q
230- else throw(($getType(Q) + " couldn't be cast to Int"))
238+ let X = addressFromStringValue(T)
239+ let ae = {
240+ let U = invoke(X, "calculateAmountOutForSwapAndSendTokens", [toInt(O), S, Z, aa], [AttachedPayment(G, toInt(O))])
241+ if ($isInstanceOf(U, "Int"))
242+ then U
243+ else throw(($getType(U) + " couldn't be cast to Int"))
231244 }
232- $Tuple2([ScriptTransfer(m, toInt(J), F)], aa)
245+ $Tuple2([ScriptTransfer(m, toInt(M), G), ScriptTransfer(X, toInt(N), G)], ae)
233246 }
234247 else throw("Strict value is not equal to itself.")
235248 }
238251
239252
240253
241-@Callable(z)
242-func setManager (ab) = {
243- let ac = B(z)
244- if ((ac == ac))
254+@Callable(A)
255+func setManager (af) = {
256+ let ag = C(A)
257+ if ((ag == ag))
245258 then {
246- let ad = fromBase58String(ab)
247- if ((ad == ad))
248- then [StringEntry(i(), ab)]
259+ let ah = fromBase58String(af)
260+ if ((ah == ah))
261+ then [StringEntry(i(), af)]
249262 else throw("Strict value is not equal to itself.")
250263 }
251264 else throw("Strict value is not equal to itself.")
253266
254267
255268
256-@Callable(z)
269+@Callable(A)
257270 func confirmManager () = {
258- let ae = x()
259- let af = if (isDefined(ae))
271+ let ai = y()
272+ let aj = if (isDefined(ai))
260273 then true
261274 else throw("no pending manager")
262- if ((af == af))
275+ if ((aj == aj))
263276 then {
264- let ag = if ((z.callerPublicKey == value(ae)))
277+ let ak = if ((A.callerPublicKey == value(ai)))
265278 then true
266279 else throw("you are not pending manager")
267- if ((ag == ag))
268- then [StringEntry(h(), toBase58String(value(ae))), DeleteEntry(i())]
280+ if ((ak == ak))
281+ then [StringEntry(h(), toBase58String(value(ai))), DeleteEntry(i())]
269282 else throw("Strict value is not equal to itself.")
270283 }
271284 else throw("Strict value is not equal to itself.")
272285 }
273286
274287
275-@Verifier(ah)
276-func ai () = {
277- let aj = {
278- let q = v()
279- if ($isInstanceOf(q, "ByteVector"))
288+@Verifier(al)
289+func am () = {
290+ let an = {
291+ let r = w()
292+ if ($isInstanceOf(r, "ByteVector"))
280293 then {
281- let A = q
282- A
294+ let B = r
295+ B
283296 }
284- else if ($isInstanceOf(q, "Unit"))
285- then ah.senderPublicKey
297+ else if ($isInstanceOf(r, "Unit"))
298+ then al.senderPublicKey
286299 else throw("Match error")
287300 }
288- sigVerify(ah.bodyBytes, ah.proofs[0], aj)
301+ sigVerify(al.bodyBytes, al.proofs[0], an)
289302 }
290303
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 6 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let a = "__"
55
66 let b = toBigInt(100000)
77
88 func c (d) = valueOrErrorMessage(getString(this, d), ("No data for this.key=" + d))
99
1010
1111 let e = throw("Pool disabled")
1212
1313 let f = throw("Pool is not exist")
1414
1515 let g = throw("Slippage is too big")
1616
1717 func h () = "%s__managerPublicKey"
1818
1919
2020 func i () = "%s__pendingManagerPublicKey"
2121
2222
2323 func j () = "%s__factoryContract"
2424
2525
2626 let k = addressFromStringValue(c(j()))
2727
2828 func l () = makeString(["%s", "feeProtocolContractAddress"], a)
2929
3030
3131 let m = addressFromStringValue(c(l()))
3232
3333 func n () = makeString(["%s", "protocolFee"], a)
3434
3535
36-func o (p) = {
37- let q = p
38- if ($isInstanceOf(q, "Int"))
36+func o () = makeString(["%s", "poolFee"], a)
37+
38+
39+func p (q) = {
40+ let r = q
41+ if ($isInstanceOf(r, "Int"))
3942 then {
40- let r = q
41- r
43+ let s = r
44+ s
4245 }
4346 else throw("fail to cast into Int")
4447 }
4548
4649
47-func s (t,u) = makeString(["%d%d", toString(t), toString(u)], a)
50+func t (u,v) = makeString(["%d%d", toString(u), toString(v)], a)
4851
4952
50-func v () = {
51- let q = getString(h())
52- if ($isInstanceOf(q, "String"))
53+func w () = {
54+ let r = getString(h())
55+ if ($isInstanceOf(r, "String"))
5356 then {
54- let w = q
55- fromBase58String(w)
57+ let x = r
58+ fromBase58String(x)
5659 }
57- else if ($isInstanceOf(q, "Unit"))
60+ else if ($isInstanceOf(r, "Unit"))
5861 then unit
5962 else throw("Match error")
6063 }
6164
6265
63-func x () = {
64- let q = getString(i())
65- if ($isInstanceOf(q, "String"))
66+func y () = {
67+ let r = getString(i())
68+ if ($isInstanceOf(r, "String"))
6669 then {
67- let w = q
68- fromBase58String(w)
70+ let x = r
71+ fromBase58String(x)
6972 }
70- else if ($isInstanceOf(q, "Unit"))
73+ else if ($isInstanceOf(r, "Unit"))
7174 then unit
7275 else throw("Match error")
7376 }
7477
7578
76-func y (z) = {
77- let q = v()
78- if ($isInstanceOf(q, "ByteVector"))
79+func z (A) = {
80+ let r = w()
81+ if ($isInstanceOf(r, "ByteVector"))
7982 then {
80- let A = q
81- (z.callerPublicKey == A)
83+ let B = r
84+ (A.callerPublicKey == B)
8285 }
83- else if ($isInstanceOf(q, "Unit"))
84- then (z.caller == this)
86+ else if ($isInstanceOf(r, "Unit"))
87+ then (A.caller == this)
8588 else throw("Match error")
8689 }
8790
8891
89-func B (z) = if (y(z))
92+func C (A) = if (z(A))
9093 then true
9194 else throw("permission denied")
9295
9396
94-func C (D) = if ((D == "WAVES"))
97+func D (E) = if ((E == "WAVES"))
9598 then wavesBalance(this).available
96- else assetBalance(this, fromBase58String(D))
99+ else assetBalance(this, fromBase58String(E))
97100
98101
99-@Callable(z)
100-func swapCalculateREADONLY (E,F,G) = {
101- let H = value(getInteger(n()))
102- let I = fraction(toBigInt(E), toBigInt(H), b)
103- let J = if ((toInt(I) == 0))
102+@Callable(A)
103+func swapCalculateREADONLY (F,G,H) = {
104+ let I = value(getInteger(n()))
105+ let J = fraction(toBigInt(F), toBigInt(I), b)
106+ let K = value(getInteger(o()))
107+ let L = fraction(toBigInt(F), toBigInt(K), b)
108+ let M = if ((toInt(J) == 0))
104109 then toBigInt(1)
105- else I
106- let K = (toBigInt(E) - J)
107- let L = invoke(k, "getLpAssetFromPoolAssetsREADONLY", [F, G], nil)
108- let M = invoke(k, "getLpAssetFromPoolAssetsREADONLY", [G, F], nil)
109- let N = if ((L != unit))
110+ else J
111+ let N = if ((toInt(L) == 0))
112+ then toBigInt(1)
113+ else L
114+ let O = ((toBigInt(F) - M) - L)
115+ let P = invoke(k, "getLpAssetFromPoolAssetsREADONLY", [G, H], nil)
116+ let Q = invoke(k, "getLpAssetFromPoolAssetsREADONLY", [H, G], nil)
117+ let R = if ((P != unit))
110118 then {
111- let O = false
112- let P = {
113- let Q = invoke(k, "getPoolAddressFromLpAssetREADONLY", [L], nil)
114- if ($isInstanceOf(Q, "String"))
115- then Q
116- else throw(($getType(Q) + " couldn't be cast to String"))
119+ let S = false
120+ let T = {
121+ let U = invoke(k, "getPoolAddressFromLpAssetREADONLY", [P], nil)
122+ if ($isInstanceOf(U, "String"))
123+ then U
124+ else throw(($getType(U) + " couldn't be cast to String"))
117125 }
118- $Tuple2(O, P)
126+ $Tuple2(S, T)
119127 }
120- else if ((M != unit))
128+ else if ((Q != unit))
121129 then {
122- let O = true
123- let P = {
124- let Q = invoke(k, "getPoolAddressFromLpAssetREADONLY", [M], nil)
125- if ($isInstanceOf(Q, "String"))
126- then Q
127- else throw(($getType(Q) + " couldn't be cast to String"))
130+ let S = true
131+ let T = {
132+ let U = invoke(k, "getPoolAddressFromLpAssetREADONLY", [Q], nil)
133+ if ($isInstanceOf(U, "String"))
134+ then U
135+ else throw(($getType(U) + " couldn't be cast to String"))
128136 }
129- $Tuple2(O, P)
137+ $Tuple2(S, T)
130138 }
131139 else f
132- let O = N._1
133- let P = N._2
134- let R = {
135- let Q = invoke(k, "getPoolStatusREADONLY", [P], nil)
136- if ($isInstanceOf(Q, "Int"))
137- then Q
138- else throw(($getType(Q) + " couldn't be cast to Int"))
140+ let S = R._1
141+ let T = R._2
142+ let V = {
143+ let U = invoke(k, "getPoolStatusREADONLY", [T], nil)
144+ if ($isInstanceOf(U, "Int"))
145+ then U
146+ else throw(($getType(U) + " couldn't be cast to Int"))
139147 }
140- let S = if ((R == 1))
148+ let W = if ((V == 1))
141149 then true
142150 else e
143- if ((S == S))
151+ if ((W == W))
144152 then {
145- let T = addressFromStringValue(valueOrElse(P, ""))
146- let U = {
147- let Q = invoke(T, "calculateAmountOutForSwapREADONLY", [toInt(K), O], nil)
148- if ($isInstanceOf(Q, "Int"))
149- then Q
150- else throw(($getType(Q) + " couldn't be cast to Int"))
153+ let X = addressFromStringValue(valueOrElse(T, ""))
154+ let Y = {
155+ let U = invoke(X, "calculateAmountOutForSwapREADONLY", [toInt(O), S], nil)
156+ if ($isInstanceOf(U, "Int"))
157+ then U
158+ else throw(($getType(U) + " couldn't be cast to Int"))
151159 }
152- $Tuple2(nil, U)
160+ $Tuple2(nil, Y)
153161 }
154162 else throw("Strict value is not equal to itself.")
155163 }
156164
157165
158166
159-@Callable(z)
160-func swap (V,G,W) = {
161- let X = value(z.payments[0])
162- let F = if ((X.assetId == unit))
167+@Callable(A)
168+func swap (Z,H,aa) = {
169+ let ab = value(A.payments[0])
170+ let G = if ((ab.assetId == unit))
163171 then toBytes("WAVES")
164- else value(X.assetId)
165- let E = value(X.amount)
166- let H = value(getInteger(n()))
167- let I = fraction(toBigInt(E), toBigInt(H), b)
168- let J = if ((toInt(I) == 0))
172+ else value(ab.assetId)
173+ let F = value(ab.amount)
174+ let I = value(getInteger(n()))
175+ let J = fraction(toBigInt(F), toBigInt(I), b)
176+ let K = value(getInteger(o()))
177+ let L = fraction(toBigInt(F), toBigInt(K), b)
178+ let M = if ((toInt(J) == 0))
169179 then toBigInt(1)
170- else I
171- let K = (toBigInt(E) - J)
172- let Y = [if ((size(z.payments) == 1))
180+ else J
181+ let N = if ((toInt(L) == 0))
182+ then toBigInt(1)
183+ else L
184+ let O = ((toBigInt(F) - M) - L)
185+ let ac = [if ((size(A.payments) == 1))
173186 then true
174187 else throw("exactly 1 payment are expected")]
175- if ((Y == Y))
188+ if ((ac == ac))
176189 then {
177- let L = {
178- let Q = invoke(k, "getLpAssetFromPoolAssetsREADONLY", [toBase58String(F), G], nil)
179- if ($isInstanceOf(Q, "String"))
180- then Q
190+ let P = {
191+ let U = invoke(k, "getLpAssetFromPoolAssetsREADONLY", [toBase58String(G), H], nil)
192+ if ($isInstanceOf(U, "String"))
193+ then U
181194 else unit
182195 }
183- let M = {
184- let Q = invoke(k, "getLpAssetFromPoolAssetsREADONLY", [G, toBase58String(F)], nil)
185- if ($isInstanceOf(Q, "String"))
186- then Q
196+ let Q = {
197+ let U = invoke(k, "getLpAssetFromPoolAssetsREADONLY", [H, toBase58String(G)], nil)
198+ if ($isInstanceOf(U, "String"))
199+ then U
187200 else unit
188201 }
189- let Z = if ((L != unit))
202+ let ad = if ((P != unit))
190203 then {
191- let O = false
192- let P = {
193- let Q = invoke(k, "getPoolAddressFromLpAssetREADONLY", [value(L)], nil)
194- if ($isInstanceOf(Q, "String"))
195- then Q
196- else throw(($getType(Q) + " couldn't be cast to String"))
204+ let S = false
205+ let T = {
206+ let U = invoke(k, "getPoolAddressFromLpAssetREADONLY", [value(P)], nil)
207+ if ($isInstanceOf(U, "String"))
208+ then U
209+ else throw(($getType(U) + " couldn't be cast to String"))
197210 }
198- $Tuple2(O, P)
211+ $Tuple2(S, T)
199212 }
200- else if ((M != unit))
213+ else if ((Q != unit))
201214 then {
202- let O = true
203- let P = {
204- let Q = invoke(k, "getPoolAddressFromLpAssetREADONLY", [value(M)], nil)
205- if ($isInstanceOf(Q, "String"))
206- then Q
207- else throw(($getType(Q) + " couldn't be cast to String"))
215+ let S = true
216+ let T = {
217+ let U = invoke(k, "getPoolAddressFromLpAssetREADONLY", [value(Q)], nil)
218+ if ($isInstanceOf(U, "String"))
219+ then U
220+ else throw(($getType(U) + " couldn't be cast to String"))
208221 }
209- $Tuple2(O, P)
222+ $Tuple2(S, T)
210223 }
211224 else f
212- let O = Z._1
213- let P = Z._2
214- let R = {
215- let Q = invoke(k, "getPoolStatusREADONLY", [P], nil)
216- if ($isInstanceOf(Q, "Int"))
217- then Q
218- else throw(($getType(Q) + " couldn't be cast to Int"))
225+ let S = ad._1
226+ let T = ad._2
227+ let V = {
228+ let U = invoke(k, "getPoolStatusREADONLY", [T], nil)
229+ if ($isInstanceOf(U, "Int"))
230+ then U
231+ else throw(($getType(U) + " couldn't be cast to Int"))
219232 }
220- let S = if ((R == 1))
233+ let W = if ((V == 1))
221234 then true
222235 else e
223- if ((S == S))
236+ if ((W == W))
224237 then {
225- let T = addressFromStringValue(P)
226- let aa = {
227- let Q = invoke(T, "calculateAmountOutForSwapAndSendTokens", [toInt(K), O, V, W], [AttachedPayment(F, toInt(K))])
228- if ($isInstanceOf(Q, "Int"))
229- then Q
230- else throw(($getType(Q) + " couldn't be cast to Int"))
238+ let X = addressFromStringValue(T)
239+ let ae = {
240+ let U = invoke(X, "calculateAmountOutForSwapAndSendTokens", [toInt(O), S, Z, aa], [AttachedPayment(G, toInt(O))])
241+ if ($isInstanceOf(U, "Int"))
242+ then U
243+ else throw(($getType(U) + " couldn't be cast to Int"))
231244 }
232- $Tuple2([ScriptTransfer(m, toInt(J), F)], aa)
245+ $Tuple2([ScriptTransfer(m, toInt(M), G), ScriptTransfer(X, toInt(N), G)], ae)
233246 }
234247 else throw("Strict value is not equal to itself.")
235248 }
236249 else throw("Strict value is not equal to itself.")
237250 }
238251
239252
240253
241-@Callable(z)
242-func setManager (ab) = {
243- let ac = B(z)
244- if ((ac == ac))
254+@Callable(A)
255+func setManager (af) = {
256+ let ag = C(A)
257+ if ((ag == ag))
245258 then {
246- let ad = fromBase58String(ab)
247- if ((ad == ad))
248- then [StringEntry(i(), ab)]
259+ let ah = fromBase58String(af)
260+ if ((ah == ah))
261+ then [StringEntry(i(), af)]
249262 else throw("Strict value is not equal to itself.")
250263 }
251264 else throw("Strict value is not equal to itself.")
252265 }
253266
254267
255268
256-@Callable(z)
269+@Callable(A)
257270 func confirmManager () = {
258- let ae = x()
259- let af = if (isDefined(ae))
271+ let ai = y()
272+ let aj = if (isDefined(ai))
260273 then true
261274 else throw("no pending manager")
262- if ((af == af))
275+ if ((aj == aj))
263276 then {
264- let ag = if ((z.callerPublicKey == value(ae)))
277+ let ak = if ((A.callerPublicKey == value(ai)))
265278 then true
266279 else throw("you are not pending manager")
267- if ((ag == ag))
268- then [StringEntry(h(), toBase58String(value(ae))), DeleteEntry(i())]
280+ if ((ak == ak))
281+ then [StringEntry(h(), toBase58String(value(ai))), DeleteEntry(i())]
269282 else throw("Strict value is not equal to itself.")
270283 }
271284 else throw("Strict value is not equal to itself.")
272285 }
273286
274287
275-@Verifier(ah)
276-func ai () = {
277- let aj = {
278- let q = v()
279- if ($isInstanceOf(q, "ByteVector"))
288+@Verifier(al)
289+func am () = {
290+ let an = {
291+ let r = w()
292+ if ($isInstanceOf(r, "ByteVector"))
280293 then {
281- let A = q
282- A
294+ let B = r
295+ B
283296 }
284- else if ($isInstanceOf(q, "Unit"))
285- then ah.senderPublicKey
297+ else if ($isInstanceOf(r, "Unit"))
298+ then al.senderPublicKey
286299 else throw("Match error")
287300 }
288- sigVerify(ah.bodyBytes, ah.proofs[0], aj)
301+ sigVerify(al.bodyBytes, al.proofs[0], an)
289302 }
290303

github/deemru/w8io/169f3d6 
122.76 ms