tx · GAJQ8ji76Yyb4PWfijnDSzYaXyCCxAxoDnSJC1G3v5te 3NAwbpcPsGSxuaojbBpYgdUYsGbrNauJ57J: -0.03500000 Waves 2022.06.07 10:30 [2085646] smart account 3NAwbpcPsGSxuaojbBpYgdUYsGbrNauJ57J > SELF 0.00000000 Waves
{ "type": 13, "id": "GAJQ8ji76Yyb4PWfijnDSzYaXyCCxAxoDnSJC1G3v5te", "fee": 3500000, "feeAssetId": null, "timestamp": 1654587055890, "version": 1, "sender": "3NAwbpcPsGSxuaojbBpYgdUYsGbrNauJ57J", "senderPublicKey": "F3cz73sYXXXQegEA2JLAqUWZViMB9jmE26svEgk9PUFm", "proofs": [ "5uAGb4vw62DBbLMinR516utnDFfsBitENSTKBCTkfVapoCNLxuEkpW24MRoEexFggJBjTQeLNzVMBwbjbSVa4NSi" ], "script": "base64:AAIFAAAAAAAAEpIIAhIECgIICBIDCgEIEgASBAoCAQQSBwoFAQEBAQQSAwoBARIAEgcKBQEBAQgBEgQKAgEBEgMKAQESBAoCCAgSBAoCCAgSBAoCCAESABIDCgEIEgUKAwEBARIECgIIARIECgIBARIECgIICBILCgkIAQECAQIIBAQSBgoECAgBCBoKCgFBEgVkZWxheRoHCgFCEgJ0MRoMCgFDEgdvcmlnVmFsGhIKAUQSDW9yaWdTY2FsZU11bHQaBwoBRRICZjEaCAoBRhIDdmFsGhQKAUcSD3Jlc3VsdFNjYWxlTXVsdBoHCgFIEgJ0cxoICgFJEgNhbXQaDQoBShIIcmVzU2NhbGUaDQoBSxIIY3VyU2NhbGUaCAoBTBIDYWJzGgcKAU0SAmZjGggKAU4SA21waxoJCgFPEgRwbXBrGgcKAVASAnBsGgcKAVESAnBoGgYKAVISAWgaBgoBUxIBdBoICgFUEgNwYXUaBwoBVRICdWEaCQoBVhIEdHhJZBoICgFXEgNnYXUaBwoBWBICYWEaBwoBWRICcGEaCAoBWhIDYW1wGgsKAWESBnNjYWxlOBoJCgJhQRIDZ3BjGgsKAmFCEgVhbXRB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xpY0tleQkAAAIAAAABAgAAAAtNYXRjaCBlcnJvcgkAAfQAAAADCAUAAAACZUoAAAAJYm9keUJ5dGVzCQABkQAAAAIIBQAAAAJlSgAAAAZwcm9vZnMAAAAAAAAAAAAFAAAAAmVPfQzbmg==", "chainId": 84, "height": 2085646, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: GmrMbXESxUPhH7mc57bNcCspdbNAVsandzdbuPJoXErr Next: 6pS2W3Qwetd68uX93dWJCVmF5Uc6GQh4jPLUNguJDoMJ Full:
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 5 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let scale8 = 100000000 | |
5 | 5 | ||
6 | 6 | let scale8BigInt = toBigInt(100000000) | |
7 | 7 | ||
8 | 8 | let scale18 = toBigInt(1000000000000000000) | |
9 | 9 | ||
10 | 10 | let zeroBigInt = toBigInt(0) | |
11 | 11 | ||
12 | 12 | let oneBigInt = toBigInt(1) | |
13 | 13 | ||
14 | 14 | let slippage4D = toBigInt((scale8 - ((scale8 * 1) / scale8))) | |
15 | 15 | ||
16 | 16 | let Amult = "100" | |
17 | 17 | ||
18 | 18 | let Dconv = "1" | |
19 | 19 | ||
20 | 20 | let SEP = "__" | |
21 | 21 | ||
22 | 22 | let EMPTY = "" | |
23 | 23 | ||
24 | 24 | let PoolActive = 1 | |
25 | 25 | ||
26 | 26 | let PoolPutDis = 2 | |
27 | 27 | ||
28 | 28 | let PoolMatcherDis = 3 | |
29 | 29 | ||
30 | 30 | let PoolShutdown = 4 | |
31 | 31 | ||
32 | 32 | let idxPoolAddress = 1 | |
33 | 33 | ||
34 | 34 | let idxPoolSt = 2 | |
35 | 35 | ||
36 | 36 | let idxLPAsId = 3 | |
37 | 37 | ||
38 | 38 | let idxAmAsId = 4 | |
39 | 39 | ||
40 | 40 | let idxPrAsId = 5 | |
41 | 41 | ||
42 | 42 | let idxAmtAsDcm = 6 | |
43 | 43 | ||
44 | 44 | let idxPriceAsDcm = 7 | |
45 | 45 | ||
46 | 46 | let idxIAmtAsId = 8 | |
47 | 47 | ||
48 | 48 | let idxIPriceAsId = 9 | |
49 | 49 | ||
50 | 50 | let idxFactStakCntr = 1 | |
51 | 51 | ||
52 | 52 | let idxFactSlippCntr = 7 | |
53 | 53 | ||
54 | 54 | let idxFactGwxRewCntr = 10 | |
55 | 55 | ||
56 | 56 | let delay = "%s__delay" | |
57 | 57 | ||
58 | 58 | func t1 (origVal,origScaleMult) = fraction(toBigInt(origVal), scale18, toBigInt(origScaleMult)) | |
59 | 59 | ||
60 | 60 | ||
61 | 61 | func f1 (val,resultScaleMult) = toInt(fraction(val, toBigInt(resultScaleMult), scale18)) | |
62 | 62 | ||
63 | 63 | ||
64 | 64 | func ts (amt,resScale,curScale) = fraction(amt, resScale, curScale) | |
65 | 65 | ||
66 | 66 | ||
67 | 67 | func abs (val) = if ((zeroBigInt > val)) | |
68 | 68 | then -(val) | |
69 | 69 | else val | |
70 | 70 | ||
71 | 71 | ||
72 | 72 | func fc () = "%s__factoryContract" | |
73 | 73 | ||
74 | 74 | ||
75 | 75 | func mpk () = "%s__managerPublicKey" | |
76 | 76 | ||
77 | 77 | ||
78 | 78 | func pmpk () = "%s__pendingManagerPublicKey" | |
79 | 79 | ||
80 | 80 | ||
81 | 81 | func pl () = "%s%s__price__last" | |
82 | 82 | ||
83 | 83 | ||
84 | 84 | func ph (h,t) = makeString(["%s%s%d%d__price__history", toString(h), toString(t)], SEP) | |
85 | 85 | ||
86 | 86 | ||
87 | 87 | func pau (ua,txId) = ((("%s%s%s__P__" + ua) + "__") + txId) | |
88 | 88 | ||
89 | 89 | ||
90 | 90 | func gau (ua,txId) = ((("%s%s%s__G__" + ua) + "__") + txId) | |
91 | 91 | ||
92 | 92 | ||
93 | 93 | func aa () = "%s__amountAsset" | |
94 | 94 | ||
95 | 95 | ||
96 | 96 | func pa () = "%s__priceAsset" | |
97 | 97 | ||
98 | 98 | ||
99 | 99 | func amp () = "%s__amp" | |
100 | 100 | ||
101 | 101 | ||
102 | 102 | func ada () = "%s__addonAddr" | |
103 | 103 | ||
104 | 104 | ||
105 | 105 | func lgopotc (caller) = makeString(["%s%s__lastGetOrPutOneTknCall", caller], SEP) | |
106 | 106 | ||
107 | 107 | ||
108 | 108 | func fcfg () = "%s__factoryConfig" | |
109 | 109 | ||
110 | 110 | ||
111 | 111 | func mtpk () = "%s%s__matcher__publicKey" | |
112 | 112 | ||
113 | 113 | ||
114 | 114 | func pc (iAmtAs,iPrAs) = (((("%d%d%s__" + iAmtAs) + "__") + iPrAs) + "__config") | |
115 | 115 | ||
116 | 116 | ||
117 | 117 | func mba (bAStr) = ("%s%s%s__mappings__baseAsset2internalId__" + bAStr) | |
118 | 118 | ||
119 | 119 | ||
120 | 120 | func aps () = "%s__shutdown" | |
121 | 121 | ||
122 | 122 | ||
123 | 123 | func toe (orV,sendrV,matchV) = throw(((((("Failed: ordValid=" + toString(orV)) + " sndrValid=") + toString(sendrV)) + " mtchrValid=") + toString(matchV))) | |
124 | 124 | ||
125 | 125 | ||
126 | 126 | func str (val) = match val { | |
127 | 127 | case valStr: String => | |
128 | 128 | valStr | |
129 | 129 | case _ => | |
130 | 130 | throw("fail cast to String") | |
131 | 131 | } | |
132 | 132 | ||
133 | 133 | ||
134 | 134 | func strf (addr,key) = valueOrErrorMessage(getString(addr, key), makeString(["mandatory ", toString(addr), ".", key, " not defined"], "")) | |
135 | 135 | ||
136 | 136 | ||
137 | 137 | func intf (addr,key) = valueOrErrorMessage(getInteger(addr, key), makeString(["mandatory ", toString(addr), ".", key, " not defined"], "")) | |
138 | 138 | ||
139 | 139 | ||
140 | 140 | let fca = addressFromStringValue(strf(this, fc())) | |
141 | 141 | ||
142 | 142 | let A = strf(this, amp()) | |
143 | 143 | ||
144 | 144 | func igs () = valueOrElse(getBoolean(fca, aps()), false) | |
145 | 145 | ||
146 | 146 | ||
147 | 147 | func mp () = fromBase58String(strf(fca, mtpk())) | |
148 | 148 | ||
149 | 149 | ||
150 | 150 | func gpc () = { | |
151 | 151 | let amtAs = strf(this, aa()) | |
152 | 152 | let priceAs = strf(this, pa()) | |
153 | 153 | let iPriceAs = intf(fca, mba(priceAs)) | |
154 | 154 | let iAmtAs = intf(fca, mba(amtAs)) | |
155 | 155 | split(strf(fca, pc(toString(iAmtAs), toString(iPriceAs))), SEP) | |
156 | 156 | } | |
157 | 157 | ||
158 | 158 | ||
159 | 159 | func gfc () = split(strf(fca, fcfg()), SEP) | |
160 | 160 | ||
161 | 161 | ||
162 | 162 | func dataPutActionInfo (inAmtAssetAmt,inPriceAssetAmt,outLpAmt,price,slipByUser,slippageReal,txHeight,txTimestamp,slipageAmAmt,slipagePrAmt) = makeString(["%d%d%d%d%d%d%d%d%d%d", toString(inAmtAssetAmt), toString(inPriceAssetAmt), toString(outLpAmt), toString(price), toString(slipByUser), toString(slippageReal), toString(txHeight), toString(txTimestamp), toString(slipageAmAmt), toString(slipagePrAmt)], SEP) | |
163 | 163 | ||
164 | 164 | ||
165 | 165 | func dataGetActionInfo (outAmtAssetAmt,outPriceAssetAmt,inLpAmt,price,txHeight,txTimestamp) = makeString(["%d%d%d%d%d%d", toString(outAmtAssetAmt), toString(outPriceAssetAmt), toString(inLpAmt), toString(price), toString(txHeight), toString(txTimestamp)], SEP) | |
166 | 166 | ||
167 | 167 | ||
168 | 168 | func getAccBalance (assetId) = if ((assetId == "WAVES")) | |
169 | 169 | then wavesBalance(this).available | |
170 | 170 | else assetBalance(this, fromBase58String(assetId)) | |
171 | 171 | ||
172 | 172 | ||
173 | 173 | func cpbi (prAmtX18,amAmtX18) = fraction(prAmtX18, scale18, amAmtX18) | |
174 | 174 | ||
175 | 175 | ||
176 | 176 | func vad (A1,A2,slippage) = { | |
177 | 177 | let diff = fraction((A1 - A2), scale8BigInt, A2) | |
178 | 178 | let pass = ((slippage - abs(diff)) > zeroBigInt) | |
179 | 179 | if (!(pass)) | |
180 | 180 | then throw(("Big slpg: " + toString(diff))) | |
181 | 181 | else $Tuple2(pass, min([A1, A2])) | |
182 | 182 | } | |
183 | 183 | ||
184 | 184 | ||
185 | 185 | func vd (D1,D0,slpg) = { | |
186 | 186 | let diff = fraction(D0, scale8BigInt, D1) | |
187 | 187 | let fail = (slpg > diff) | |
188 | 188 | if (if (fail) | |
189 | 189 | then true | |
190 | 190 | else (D0 > D1)) | |
191 | 191 | then throw(((((((toString(D0) + " ") + toString(D1)) + " ") + toString(diff)) + " ") + toString(slpg))) | |
192 | 192 | else fail | |
193 | 193 | } | |
194 | 194 | ||
195 | 195 | ||
196 | 196 | func pcp (amAssetDcm,prAssetDcm,amAmt,prAmt) = { | |
197 | 197 | let amtAsAmtX18 = t1(amAmt, amAssetDcm) | |
198 | 198 | let prAsAmtX18 = t1(prAmt, prAssetDcm) | |
199 | 199 | cpbi(prAsAmtX18, amtAsAmtX18) | |
200 | 200 | } | |
201 | 201 | ||
202 | 202 | ||
203 | 203 | func calcPrices (amAmt,prAmt,lpAmt) = { | |
204 | 204 | let cfg = gpc() | |
205 | 205 | let amtAsDcm = parseIntValue(cfg[idxAmtAsDcm]) | |
206 | 206 | let prAsDcm = parseIntValue(cfg[idxPriceAsDcm]) | |
207 | 207 | let priceX18 = pcp(amtAsDcm, prAsDcm, amAmt, prAmt) | |
208 | 208 | let amAmtX18 = t1(amAmt, amtAsDcm) | |
209 | 209 | let prAmtX18 = t1(prAmt, prAsDcm) | |
210 | 210 | let lpAmtX18 = t1(lpAmt, scale8) | |
211 | 211 | let lpPrInAmAsX18 = cpbi(amAmtX18, lpAmtX18) | |
212 | 212 | let lpPrInPrAsX18 = cpbi(prAmtX18, lpAmtX18) | |
213 | 213 | [priceX18, lpPrInAmAsX18, lpPrInPrAsX18] | |
214 | 214 | } | |
215 | 215 | ||
216 | 216 | ||
217 | 217 | func calculatePrices (amAmt,prAmt,lpAmt) = { | |
218 | 218 | let p = calcPrices(amAmt, prAmt, lpAmt) | |
219 | 219 | [f1(p[0], scale8), f1(p[1], scale8), f1(p[2], scale8)] | |
220 | 220 | } | |
221 | 221 | ||
222 | 222 | ||
223 | 223 | func ego (txId58,pmtAssetId,pmtLpAmt,userAddress) = { | |
224 | 224 | let cfg = gpc() | |
225 | 225 | let lpId = cfg[idxLPAsId] | |
226 | 226 | let amId = cfg[idxAmAsId] | |
227 | 227 | let prId = cfg[idxPrAsId] | |
228 | 228 | let amDcm = parseIntValue(cfg[idxAmtAsDcm]) | |
229 | 229 | let prDcm = parseIntValue(cfg[idxPriceAsDcm]) | |
230 | 230 | let sts = cfg[idxPoolSt] | |
231 | 231 | let lpEmiss = valueOrErrorMessage(assetInfo(fromBase58String(lpId)), "Wrong LP id").quantity | |
232 | 232 | if ((lpId != pmtAssetId)) | |
233 | 233 | then throw("Wrong pmt asset") | |
234 | 234 | else { | |
235 | 235 | let amBalance = getAccBalance(amId) | |
236 | 236 | let amBalanceX18 = t1(amBalance, amDcm) | |
237 | 237 | let prBalance = getAccBalance(prId) | |
238 | 238 | let prBalanceX18 = t1(prBalance, prDcm) | |
239 | 239 | let curPriceX18 = cpbi(prBalanceX18, amBalanceX18) | |
240 | 240 | let curPrice = f1(curPriceX18, scale8) | |
241 | 241 | let pmtLpAmtX18 = t1(pmtLpAmt, scale8) | |
242 | 242 | let lpEmissX18 = t1(lpEmiss, scale8) | |
243 | 243 | let outAmAmtX18 = fraction(amBalanceX18, pmtLpAmtX18, lpEmissX18) | |
244 | 244 | let outPrAmtX18 = fraction(prBalanceX18, pmtLpAmtX18, lpEmissX18) | |
245 | 245 | let outAmAmt = f1(outAmAmtX18, amDcm) | |
246 | 246 | let outPrAmt = f1(outPrAmtX18, prDcm) | |
247 | 247 | let state = if ((txId58 == "")) | |
248 | 248 | then nil | |
249 | 249 | else [ScriptTransfer(userAddress, outAmAmt, if ((amId == "WAVES")) | |
250 | 250 | then unit | |
251 | 251 | else fromBase58String(amId)), ScriptTransfer(userAddress, outPrAmt, if ((prId == "WAVES")) | |
252 | 252 | then unit | |
253 | 253 | else fromBase58String(prId)), StringEntry(gau(toString(userAddress), txId58), dataGetActionInfo(outAmAmt, outPrAmt, pmtLpAmt, curPrice, height, lastBlock.timestamp)), IntegerEntry(pl(), curPrice), IntegerEntry(ph(height, lastBlock.timestamp), curPrice)] | |
254 | 254 | $Tuple10(outAmAmt, outPrAmt, amId, prId, amBalance, prBalance, lpEmiss, curPriceX18, sts, state) | |
255 | 255 | } | |
256 | 256 | } | |
257 | 257 | ||
258 | 258 | ||
259 | 259 | func epo (txId58,slippage,inAmAmt,inAmId,inPrAmt,inPrId,userAddress,isEval,emitLp,isOneAsset,pmtAmt,pmtId) = { | |
260 | 260 | let cfg = gpc() | |
261 | 261 | let lpId = fromBase58String(cfg[idxLPAsId]) | |
262 | 262 | let amIdStr = cfg[idxAmAsId] | |
263 | 263 | let prIdStr = cfg[idxPrAsId] | |
264 | 264 | let inAmIdStr = cfg[idxIAmtAsId] | |
265 | 265 | let inPrIdStr = cfg[idxIPriceAsId] | |
266 | 266 | let amtDcm = parseIntValue(cfg[idxAmtAsDcm]) | |
267 | 267 | let priceDcm = parseIntValue(cfg[idxPriceAsDcm]) | |
268 | 268 | let sts = cfg[idxPoolSt] | |
269 | 269 | let lpEm = valueOrErrorMessage(assetInfo(lpId), "Wr lp as").quantity | |
270 | 270 | let amBalance = if (isEval) | |
271 | 271 | then getAccBalance(amIdStr) | |
272 | 272 | else if (if (isOneAsset) | |
273 | 273 | then (pmtId == amIdStr) | |
274 | 274 | else false) | |
275 | 275 | then (getAccBalance(amIdStr) - pmtAmt) | |
276 | 276 | else if (isOneAsset) | |
277 | 277 | then getAccBalance(amIdStr) | |
278 | 278 | else (getAccBalance(amIdStr) - inAmAmt) | |
279 | 279 | let prBalance = if (isEval) | |
280 | 280 | then getAccBalance(prIdStr) | |
281 | 281 | else if (if (isOneAsset) | |
282 | 282 | then (pmtId == prIdStr) | |
283 | 283 | else false) | |
284 | 284 | then (getAccBalance(prIdStr) - pmtAmt) | |
285 | 285 | else if (isOneAsset) | |
286 | 286 | then getAccBalance(prIdStr) | |
287 | 287 | else (getAccBalance(prIdStr) - inPrAmt) | |
288 | 288 | let inAmAssetAmtX18 = t1(inAmAmt, amtDcm) | |
289 | 289 | let inPrAssetAmtX18 = t1(inPrAmt, priceDcm) | |
290 | 290 | let userPriceX18 = cpbi(inPrAssetAmtX18, inAmAssetAmtX18) | |
291 | 291 | let amBalanceX18 = t1(amBalance, amtDcm) | |
292 | 292 | let prBalanceX18 = t1(prBalance, priceDcm) | |
293 | 293 | let r = if ((lpEm == 0)) | |
294 | 294 | then { | |
295 | 295 | let curPriceX18 = zeroBigInt | |
296 | 296 | let slippageX18 = zeroBigInt | |
297 | 297 | let lpAmtX18 = pow((inAmAssetAmtX18 * inPrAssetAmtX18), 0, toBigInt(5), 1, 0, DOWN) | |
298 | 298 | $Tuple5(f1(lpAmtX18, scale8), f1(inAmAssetAmtX18, amtDcm), f1(inPrAssetAmtX18, priceDcm), cpbi((prBalanceX18 + inPrAssetAmtX18), (amBalanceX18 + inAmAssetAmtX18)), slippageX18) | |
299 | 299 | } | |
300 | 300 | else { | |
301 | 301 | let curPriceX18 = cpbi(prBalanceX18, amBalanceX18) | |
302 | 302 | let slippageRealX18 = fraction(abs((curPriceX18 - userPriceX18)), scale18, curPriceX18) | |
303 | 303 | let slippageX18 = t1(slippage, scale8) | |
304 | 304 | if (if ((curPriceX18 != zeroBigInt)) | |
305 | 305 | then (slippageRealX18 > slippageX18) | |
306 | 306 | else false) | |
307 | 307 | then throw(((("Price slippage " + toString(slippageRealX18)) + " > ") + toString(slippageX18))) | |
308 | 308 | else { | |
309 | 309 | let lpEmissionX18 = t1(lpEm, scale8) | |
310 | 310 | let prViaAmX18 = fraction(inAmAssetAmtX18, curPriceX18, scale18) | |
311 | 311 | let amViaPrX18 = fraction(inPrAssetAmtX18, scale18, curPriceX18) | |
312 | 312 | let expectedAmts = if ((prViaAmX18 > inPrAssetAmtX18)) | |
313 | 313 | then $Tuple2(amViaPrX18, inPrAssetAmtX18) | |
314 | 314 | else $Tuple2(inAmAssetAmtX18, prViaAmX18) | |
315 | 315 | let expAmtAssetAmtX18 = expectedAmts._1 | |
316 | 316 | let expPriceAssetAmtX18 = expectedAmts._2 | |
317 | 317 | let lpAmtX18 = fraction(lpEmissionX18, expPriceAssetAmtX18, prBalanceX18) | |
318 | 318 | $Tuple5(f1(lpAmtX18, scale8), f1(expAmtAssetAmtX18, amtDcm), f1(expPriceAssetAmtX18, priceDcm), curPriceX18, slippageX18) | |
319 | 319 | } | |
320 | 320 | } | |
321 | 321 | let calcLpAmt = r._1 | |
322 | 322 | let calcAmAssetPmt = r._2 | |
323 | 323 | let calcPrAssetPmt = r._3 | |
324 | 324 | let curPrice = f1(r._4, scale8) | |
325 | 325 | let slippageCalc = f1(r._5, scale8) | |
326 | 326 | if ((0 >= calcLpAmt)) | |
327 | 327 | then throw("LP <= 0") | |
328 | 328 | else { | |
329 | 329 | let emitLpAmt = if (!(emitLp)) | |
330 | 330 | then 0 | |
331 | 331 | else calcLpAmt | |
332 | 332 | let amDiff = (inAmAmt - calcAmAssetPmt) | |
333 | 333 | let prDiff = (inPrAmt - calcPrAssetPmt) | |
334 | 334 | let $t01572516070 = if (if (isOneAsset) | |
335 | 335 | then (pmtId == amIdStr) | |
336 | 336 | else false) | |
337 | 337 | then $Tuple2(pmtAmt, 0) | |
338 | 338 | else if (if (isOneAsset) | |
339 | 339 | then (pmtId == prIdStr) | |
340 | 340 | else false) | |
341 | 341 | then $Tuple2(0, pmtAmt) | |
342 | 342 | else $Tuple2(calcAmAssetPmt, calcPrAssetPmt) | |
343 | 343 | let writeAmAmt = $t01572516070._1 | |
344 | 344 | let writePrAmt = $t01572516070._2 | |
345 | 345 | let commonState = [IntegerEntry(pl(), curPrice), IntegerEntry(ph(height, lastBlock.timestamp), curPrice), StringEntry(pau(userAddress, txId58), dataPutActionInfo(writeAmAmt, writePrAmt, emitLpAmt, curPrice, slippage, slippageCalc, height, lastBlock.timestamp, amDiff, prDiff))] | |
346 | 346 | $Tuple13(calcLpAmt, emitLpAmt, curPrice, amBalance, prBalance, lpEm, lpId, sts, commonState, amDiff, prDiff, inAmId, inPrId) | |
347 | 347 | } | |
348 | 348 | } | |
349 | 349 | ||
350 | 350 | ||
351 | 351 | func moa (order) = { | |
352 | 352 | let cfg = gpc() | |
353 | 353 | let amtAsId = cfg[idxAmAsId] | |
354 | 354 | let prAsId = cfg[idxPrAsId] | |
355 | 355 | let sts = parseIntValue(cfg[idxPoolSt]) | |
356 | 356 | let amtAsDcm = parseIntValue(cfg[idxAmtAsDcm]) | |
357 | 357 | let prAsDcm = parseIntValue(cfg[idxPriceAsDcm]) | |
358 | 358 | let accAmtAsBalance = getAccBalance(amtAsId) | |
359 | 359 | let accPrAsBalance = getAccBalance(prAsId) | |
360 | 360 | let curPriceX18 = if ((order.orderType == Buy)) | |
361 | 361 | then pcp(amtAsDcm, prAsDcm, (accAmtAsBalance + order.amount), accPrAsBalance) | |
362 | 362 | else pcp(amtAsDcm, prAsDcm, (accAmtAsBalance - order.amount), accPrAsBalance) | |
363 | 363 | let curPrice = f1(curPriceX18, scale8) | |
364 | 364 | if (if (if (igs()) | |
365 | 365 | then true | |
366 | 366 | else (sts == PoolMatcherDis)) | |
367 | 367 | then true | |
368 | 368 | else (sts == PoolShutdown)) | |
369 | 369 | then throw("Admin blocked") | |
370 | 370 | else { | |
371 | 371 | let orAmtAsset = order.assetPair.amountAsset | |
372 | 372 | let orAmtAsStr = if ((orAmtAsset == unit)) | |
373 | 373 | then "WAVES" | |
374 | 374 | else toBase58String(value(orAmtAsset)) | |
375 | 375 | let orPrAsset = order.assetPair.priceAsset | |
376 | 376 | let orPrAsStr = if ((orPrAsset == unit)) | |
377 | 377 | then "WAVES" | |
378 | 378 | else toBase58String(value(orPrAsset)) | |
379 | 379 | if (if ((orAmtAsStr != amtAsId)) | |
380 | 380 | then true | |
381 | 381 | else (orPrAsStr != prAsId)) | |
382 | 382 | then throw("Wr assets") | |
383 | 383 | else { | |
384 | 384 | let orderPrice = order.price | |
385 | 385 | let priceDcm = fraction(scale8, prAsDcm, amtAsDcm) | |
386 | 386 | let castOrderPrice = ts(orderPrice, scale8, priceDcm) | |
387 | 387 | let isOrderPriceValid = if ((order.orderType == Buy)) | |
388 | 388 | then (curPrice >= castOrderPrice) | |
389 | 389 | else (castOrderPrice >= curPrice) | |
390 | 390 | true | |
391 | 391 | } | |
392 | 392 | } | |
393 | 393 | } | |
394 | 394 | ||
395 | 395 | ||
396 | 396 | func cg (i) = if ((size(i.payments) != 1)) | |
397 | 397 | then throw("1 pmnt exp") | |
398 | 398 | else { | |
399 | 399 | let pmt = value(i.payments[0]) | |
400 | 400 | let pmtAssetId = value(pmt.assetId) | |
401 | 401 | let pmtAmt = pmt.amount | |
402 | 402 | let r = ego(toBase58String(i.transactionId), toBase58String(pmtAssetId), pmtAmt, i.caller) | |
403 | 403 | let outAmAmt = r._1 | |
404 | 404 | let outPrAmt = r._2 | |
405 | 405 | let sts = parseIntValue(r._9) | |
406 | 406 | let state = r._10 | |
407 | 407 | if (if (igs()) | |
408 | 408 | then true | |
409 | 409 | else (sts == PoolShutdown)) | |
410 | 410 | then throw(("Admin blocked: " + toString(sts))) | |
411 | 411 | else $Tuple5(outAmAmt, outPrAmt, pmtAmt, pmtAssetId, state) | |
412 | 412 | } | |
413 | 413 | ||
414 | 414 | ||
415 | 415 | func cp (caller,txId,amAsPmt,prAsPmt,slippage,emitLp,isOneAsset,pmtAmt,pmtId) = { | |
416 | 416 | let r = epo(txId, slippage, value(amAsPmt).amount, value(amAsPmt).assetId, value(prAsPmt).amount, value(prAsPmt).assetId, caller, false, emitLp, isOneAsset, pmtAmt, pmtId) | |
417 | 417 | let sts = parseIntValue(r._8) | |
418 | 418 | if (if (if (igs()) | |
419 | 419 | then true | |
420 | 420 | else (sts == PoolPutDis)) | |
421 | 421 | then true | |
422 | 422 | else (sts == PoolShutdown)) | |
423 | 423 | then throw(("Blocked:" + toString(sts))) | |
424 | 424 | else r | |
425 | 425 | } | |
426 | 426 | ||
427 | 427 | ||
428 | 428 | func m () = match getString(mpk()) { | |
429 | 429 | case s: String => | |
430 | 430 | fromBase58String(s) | |
431 | 431 | case _: Unit => | |
432 | 432 | unit | |
433 | 433 | case _ => | |
434 | 434 | throw("Match error") | |
435 | 435 | } | |
436 | 436 | ||
437 | 437 | ||
438 | 438 | func pm () = match getString(pmpk()) { | |
439 | 439 | case s: String => | |
440 | 440 | fromBase58String(s) | |
441 | 441 | case _: Unit => | |
442 | 442 | unit | |
443 | 443 | case _ => | |
444 | 444 | throw("Match error") | |
445 | 445 | } | |
446 | 446 | ||
447 | 447 | ||
448 | 448 | let pd = throw("Permission denied") | |
449 | 449 | ||
450 | 450 | func mm (i) = match m() { | |
451 | 451 | case pk: ByteVector => | |
452 | 452 | if ((i.callerPublicKey == pk)) | |
453 | 453 | then true | |
454 | 454 | else pd | |
455 | 455 | case _: Unit => | |
456 | 456 | if ((i.caller == this)) | |
457 | 457 | then true | |
458 | 458 | else pd | |
459 | 459 | case _ => | |
460 | 460 | throw("Match error") | |
461 | 461 | } | |
462 | 462 | ||
463 | 463 | ||
464 | 464 | @Callable(i) | |
465 | 465 | func constructor (fc,aa) = { | |
466 | 466 | let c = mm(i) | |
467 | 467 | if ((c == c)) | |
468 | 468 | then [StringEntry(fc(), fc)] | |
469 | 469 | else throw("Strict value is not equal to itself.") | |
470 | 470 | } | |
471 | 471 | ||
472 | 472 | ||
473 | 473 | ||
474 | 474 | @Callable(i) | |
475 | 475 | func setManager (pendingManagerPublicKey) = { | |
476 | 476 | let c = mm(i) | |
477 | 477 | if ((c == c)) | |
478 | 478 | then { | |
479 | 479 | let cm = fromBase58String(pendingManagerPublicKey) | |
480 | 480 | if ((cm == cm)) | |
481 | 481 | then [StringEntry(pmpk(), pendingManagerPublicKey)] | |
482 | 482 | else throw("Strict value is not equal to itself.") | |
483 | 483 | } | |
484 | 484 | else throw("Strict value is not equal to itself.") | |
485 | 485 | } | |
486 | 486 | ||
487 | 487 | ||
488 | 488 | ||
489 | 489 | @Callable(i) | |
490 | 490 | func confirmManager () = { | |
491 | 491 | let p = pm() | |
492 | 492 | let hpm = if (isDefined(p)) | |
493 | 493 | then true | |
494 | 494 | else throw("No pending manager") | |
495 | 495 | if ((hpm == hpm)) | |
496 | 496 | then { | |
497 | 497 | let cpm = if ((i.callerPublicKey == value(p))) | |
498 | 498 | then true | |
499 | 499 | else throw("You are not pending manager") | |
500 | 500 | if ((cpm == cpm)) | |
501 | 501 | then [StringEntry(mpk(), toBase58String(value(p))), DeleteEntry(pmpk())] | |
502 | 502 | else throw("Strict value is not equal to itself.") | |
503 | 503 | } | |
504 | 504 | else throw("Strict value is not equal to itself.") | |
505 | 505 | } | |
506 | 506 | ||
507 | 507 | ||
508 | 508 | ||
509 | 509 | @Callable(i) | |
510 | 510 | func put (slip,autoStake) = { | |
511 | 511 | let factCfg = gfc() | |
512 | 512 | let stakingCntr = valueOrErrorMessage(addressFromString(factCfg[idxFactStakCntr]), "Wr st addr") | |
513 | 513 | let slipCntr = valueOrErrorMessage(addressFromString(factCfg[idxFactSlippCntr]), "Wr sl addr") | |
514 | 514 | if ((0 > slip)) | |
515 | 515 | then throw("Wrong slippage") | |
516 | 516 | else if ((size(i.payments) != 2)) | |
517 | 517 | then throw("2 pmnts expd") | |
518 | 518 | else { | |
519 | 519 | let e = cp(toString(i.caller), toBase58String(i.transactionId), AttachedPayment(value(i.payments[0]).assetId, value(i.payments[0]).amount), i.payments[1], slip, true, false, 0, "") | |
520 | 520 | let emitLpAmt = e._2 | |
521 | 521 | let lpAssetId = e._7 | |
522 | 522 | let state = e._9 | |
523 | 523 | let amDiff = e._10 | |
524 | 524 | let prDiff = e._11 | |
525 | 525 | let amId = e._12 | |
526 | 526 | let prId = e._13 | |
527 | 527 | let r = invoke(fca, "emit", [emitLpAmt], nil) | |
528 | 528 | if ((r == r)) | |
529 | 529 | then { | |
530 | 530 | let el = match r { | |
531 | 531 | case legacy: Address => | |
532 | 532 | invoke(legacy, "emit", [emitLpAmt], nil) | |
533 | 533 | case _ => | |
534 | 534 | unit | |
535 | 535 | } | |
536 | 536 | if ((el == el)) | |
537 | 537 | then { | |
538 | 538 | let sa = if ((amDiff > 0)) | |
539 | 539 | then invoke(slipCntr, "put", nil, [AttachedPayment(amId, amDiff)]) | |
540 | 540 | else nil | |
541 | 541 | if ((sa == sa)) | |
542 | 542 | then { | |
543 | 543 | let sp = if ((prDiff > 0)) | |
544 | 544 | then invoke(slipCntr, "put", nil, [AttachedPayment(prId, prDiff)]) | |
545 | 545 | else nil | |
546 | 546 | if ((sp == sp)) | |
547 | 547 | then { | |
548 | 548 | let lpTrnsfr = if (autoStake) | |
549 | 549 | then { | |
550 | 550 | let ss = invoke(stakingCntr, "stake", nil, [AttachedPayment(lpAssetId, emitLpAmt)]) | |
551 | 551 | if ((ss == ss)) | |
552 | 552 | then nil | |
553 | 553 | else throw("Strict value is not equal to itself.") | |
554 | 554 | } | |
555 | 555 | else [ScriptTransfer(i.caller, emitLpAmt, lpAssetId)] | |
556 | 556 | (state ++ lpTrnsfr) | |
557 | 557 | } | |
558 | 558 | else throw("Strict value is not equal to itself.") | |
559 | 559 | } | |
560 | 560 | else throw("Strict value is not equal to itself.") | |
561 | 561 | } | |
562 | 562 | else throw("Strict value is not equal to itself.") | |
563 | 563 | } | |
564 | 564 | else throw("Strict value is not equal to itself.") | |
565 | 565 | } | |
566 | 566 | } | |
567 | 567 | ||
568 | 568 | ||
569 | 569 | ||
570 | 570 | @Callable(i) | |
571 | 571 | func putOneTkn (amAssetPart,prAssetPart,outLp,slippage,autoStake) = { | |
572 | 572 | let cfg = gfc() | |
573 | 573 | let stakingCntr = valueOrErrorMessage(addressFromString(cfg[idxFactStakCntr]), "Wr st addr") | |
574 | 574 | let slipCntr = valueOrErrorMessage(addressFromString(cfg[idxFactSlippCntr]), "Wr sl addr") | |
575 | 575 | let gwxCntr = valueOrErrorMessage(addressFromString(cfg[idxFactGwxRewCntr]), "Wr gwx addr") | |
576 | 576 | let poolCfg = gpc() | |
577 | 577 | let amId = poolCfg[idxAmAsId] | |
578 | 578 | let prId = poolCfg[idxPrAsId] | |
579 | 579 | let amDcm = parseIntValue(poolCfg[idxAmtAsDcm]) | |
580 | 580 | let prDcm = parseIntValue(poolCfg[idxPriceAsDcm]) | |
581 | 581 | let addon = valueOrElse(getString(this, ada()), "") | |
582 | 582 | let userAddress = if ((addon == toString(i.caller))) | |
583 | 583 | then i.originCaller | |
584 | 584 | else i.caller | |
585 | 585 | let addonContract = valueOrErrorMessage(addressFromString(valueOrErrorMessage(getString(ada()), "no addons")), "addon address in not valid") | |
586 | 586 | let check = reentrantInvoke(addonContract, "ensureCanGetOrPutOneTkn", [toString(userAddress)], nil) | |
587 | 587 | if ((check == check)) | |
588 | 588 | then if (if (if (if ((0 >= slippage)) | |
589 | 589 | then true | |
590 | 590 | else (0 >= amAssetPart)) | |
591 | 591 | then true | |
592 | 592 | else (0 >= prAssetPart)) | |
593 | 593 | then true | |
594 | 594 | else (0 >= outLp)) | |
595 | 595 | then throw("Wrong params") | |
596 | 596 | else if ((size(i.payments) != 1)) | |
597 | 597 | then throw("1 pmnt expd") | |
598 | 598 | else { | |
599 | 599 | let pmt = value(i.payments[0]) | |
600 | 600 | let pmtAssetId = toBase58String(value(pmt.assetId)) | |
601 | 601 | let pmtAmt = pmt.amount | |
602 | 602 | if (if (if ((amAssetPart > pmtAmt)) | |
603 | 603 | then true | |
604 | 604 | else (prAssetPart > pmtAmt)) | |
605 | 605 | then true | |
606 | 606 | else (10000000 > pmtAmt)) | |
607 | 607 | then throw("Wrong pmt amt") | |
608 | 608 | else { | |
609 | 609 | let amBalance = getAccBalance(amId) | |
610 | 610 | let prBalance = getAccBalance(prId) | |
611 | 611 | let $t02506325443 = if ((pmtAssetId == amId)) | |
612 | 612 | then $Tuple6((amBalance - pmtAmt), prBalance, (pmtAmt - amAssetPart), prAssetPart, 0, 0) | |
613 | 613 | else if ((pmtAssetId == prId)) | |
614 | 614 | then $Tuple6(amBalance, (prBalance - pmtAmt), 0, 0, (pmtAmt - prAssetPart), amAssetPart) | |
615 | 615 | else throw("wrong pmtAssetId") | |
616 | 616 | let amBalanceNow = $t02506325443._1 | |
617 | 617 | let prBalanceNow = $t02506325443._2 | |
618 | 618 | let virtSwapInAm = $t02506325443._3 | |
619 | 619 | let virtSwapOutPr = $t02506325443._4 | |
620 | 620 | let virtSwapInPr = $t02506325443._5 | |
621 | 621 | let virtSwapOutAm = $t02506325443._6 | |
622 | 622 | let D0 = invoke(gwxCntr, "calcD", [toString(amBalanceNow), toString(prBalanceNow), A, Amult, Dconv], nil) | |
623 | 623 | let D1 = invoke(gwxCntr, "calcD", [toString(toBigInt(((amBalanceNow + virtSwapInAm) - virtSwapOutAm))), toString(toBigInt(((prBalanceNow + virtSwapInPr) - virtSwapOutPr))), A, Amult, Dconv], nil) | |
624 | 624 | let D0vsD1 = vd(parseBigIntValue(str(D1)), parseBigIntValue(str(D0)), slippage4D) | |
625 | 625 | if ((D0vsD1 == D0vsD1)) | |
626 | 626 | then { | |
627 | 627 | let estPut = cp(toString(i.caller), toBase58String(i.transactionId), AttachedPayment(fromBase58String(amId), amAssetPart), AttachedPayment(fromBase58String(prId), prAssetPart), slippage, true, true, pmtAmt, pmtAssetId) | |
628 | 628 | if ((estPut == estPut)) | |
629 | 629 | then { | |
630 | 630 | let error = throw("error after estPut") | |
631 | 631 | if ((error == error)) | |
632 | 632 | then { | |
633 | 633 | let estimLP = estPut._2 | |
634 | 634 | let lpAssetId = estPut._7 | |
635 | 635 | let state = estPut._9 | |
636 | 636 | let amDiff = estPut._10 | |
637 | 637 | let prDiff = estPut._11 | |
638 | 638 | let lpCalcRes = vad(toBigInt(estimLP), toBigInt(outLp), toBigInt(slippage)) | |
639 | 639 | let emitLpAmt = toInt(lpCalcRes._2) | |
640 | 640 | let e = invoke(fca, "emit", [emitLpAmt], nil) | |
641 | 641 | if ((e == e)) | |
642 | 642 | then { | |
643 | 643 | let el = match e { | |
644 | 644 | case legacy: Address => | |
645 | 645 | invoke(legacy, "emit", [emitLpAmt], nil) | |
646 | 646 | case _ => | |
647 | 647 | unit | |
648 | 648 | } | |
649 | 649 | if ((el == el)) | |
650 | 650 | then { | |
651 | 651 | let sa = if ((amDiff > 0)) | |
652 | 652 | then invoke(slipCntr, "put", nil, [AttachedPayment(fromBase58String(amId), amDiff)]) | |
653 | 653 | else nil | |
654 | 654 | if ((sa == sa)) | |
655 | 655 | then { | |
656 | 656 | let sp = if ((prDiff > 0)) | |
657 | 657 | then invoke(slipCntr, "put", nil, [AttachedPayment(fromBase58String(prId), prDiff)]) | |
658 | 658 | else nil | |
659 | 659 | if ((sp == sp)) | |
660 | 660 | then { | |
661 | 661 | let lpTrnsfr = if (autoStake) | |
662 | 662 | then { | |
663 | 663 | let ss = invoke(stakingCntr, "stake", nil, [AttachedPayment(lpAssetId, emitLpAmt)]) | |
664 | 664 | if ((ss == ss)) | |
665 | 665 | then nil | |
666 | 666 | else throw("Strict value is not equal to itself.") | |
667 | 667 | } | |
668 | 668 | else [ScriptTransfer(i.caller, emitLpAmt, lpAssetId)] | |
669 | 669 | (state ++ lpTrnsfr) | |
670 | 670 | } | |
671 | 671 | else throw("Strict value is not equal to itself.") | |
672 | 672 | } | |
673 | 673 | else throw("Strict value is not equal to itself.") | |
674 | 674 | } | |
675 | 675 | else throw("Strict value is not equal to itself.") | |
676 | 676 | } | |
677 | 677 | else throw("Strict value is not equal to itself.") | |
678 | 678 | } | |
679 | 679 | else throw("Strict value is not equal to itself.") | |
680 | 680 | } | |
681 | 681 | else throw("Strict value is not equal to itself.") | |
682 | 682 | } | |
683 | 683 | else throw("Strict value is not equal to itself.") | |
684 | 684 | } | |
685 | 685 | } | |
686 | 686 | else throw("Strict value is not equal to itself.") | |
687 | 687 | } | |
688 | 688 | ||
689 | 689 | ||
690 | 690 | ||
691 | 691 | @Callable(i) | |
692 | 692 | func putForFree (maxSlpg) = if ((0 > maxSlpg)) | |
693 | 693 | then throw("Wrong slpg") | |
694 | 694 | else if ((size(i.payments) != 2)) | |
695 | 695 | then throw("2 pmnts expd") | |
696 | 696 | else { | |
697 | 697 | let estPut = cp(toString(i.caller), toBase58String(i.transactionId), AttachedPayment(value(i.payments[0]).assetId, value(i.payments[0]).amount), i.payments[1], maxSlpg, false, false, 0, "") | |
698 | 698 | estPut._9 | |
699 | 699 | } | |
700 | 700 | ||
701 | 701 | ||
702 | 702 | ||
703 | 703 | @Callable(i) | |
704 | 704 | func get () = { | |
705 | 705 | let r = cg(i) | |
706 | 706 | let outAmtAmt = r._1 | |
707 | 707 | let outPrAmt = r._2 | |
708 | 708 | let pmtAmt = r._3 | |
709 | 709 | let pmtAssetId = r._4 | |
710 | 710 | let state = r._5 | |
711 | 711 | let b = invoke(fca, "burn", [pmtAmt], [AttachedPayment(pmtAssetId, pmtAmt)]) | |
712 | 712 | if ((b == b)) | |
713 | 713 | then state | |
714 | 714 | else throw("Strict value is not equal to itself.") | |
715 | 715 | } | |
716 | 716 | ||
717 | 717 | ||
718 | 718 | ||
719 | 719 | @Callable(i) | |
720 | 720 | func getOneTkn (exchResult,notUsed,outAmount,outAssetId,slippage) = if ((size(i.payments) != 1)) | |
721 | 721 | then throw("1 pmnt expd") | |
722 | 722 | else { | |
723 | 723 | let cfg = gpc() | |
724 | 724 | let lpId = cfg[idxLPAsId] | |
725 | 725 | let amId = cfg[idxAmAsId] | |
726 | 726 | let prId = cfg[idxPrAsId] | |
727 | 727 | let amDcm = parseIntValue(cfg[idxAmtAsDcm]) | |
728 | 728 | let prDcm = parseIntValue(cfg[idxPriceAsDcm]) | |
729 | 729 | let sts = cfg[idxPoolSt] | |
730 | 730 | let factCfg = gfc() | |
731 | 731 | let gwxCntr = valueOrErrorMessage(addressFromString(factCfg[idxFactGwxRewCntr]), "Wr sl addr") | |
732 | 732 | let pmt = value(i.payments[0]) | |
733 | 733 | let addon = valueOrElse(getString(this, ada()), "") | |
734 | 734 | let userAddress = if ((addon == toString(i.caller))) | |
735 | 735 | then i.originCaller | |
736 | 736 | else i.caller | |
737 | 737 | let txId58 = toBase58String(i.transactionId) | |
738 | 738 | let pmtAssetId = value(pmt.assetId) | |
739 | 739 | let pmtAmt = pmt.amount | |
740 | 740 | let addonContract = valueOrErrorMessage(addressFromString(valueOrErrorMessage(getString(ada()), "no addons")), "addon address in not valid") | |
741 | 741 | let check = reentrantInvoke(addonContract, "ensureCanGetOrPutOneTkn", [toString(userAddress)], nil) | |
742 | 742 | if ((check == check)) | |
743 | 743 | then if ((1000000000 > pmtAmt)) | |
744 | 744 | then throw("Min pmt 10 LP") | |
745 | 745 | else if (if (if ((0 > slippage)) | |
746 | 746 | then true | |
747 | 747 | else (0 > exchResult)) | |
748 | 748 | then true | |
749 | 749 | else (0 > outAmount)) | |
750 | 750 | then throw("Wrong params") | |
751 | 751 | else if ((lpId != toBase58String(pmtAssetId))) | |
752 | 752 | then throw("Wrong LP") | |
753 | 753 | else { | |
754 | 754 | let r = ego(toBase58String(i.transactionId), toBase58String(pmtAssetId), pmtAmt, i.caller) | |
755 | 755 | let estimAmAmt = r._1 | |
756 | 756 | let estimPrAmt = r._2 | |
757 | 757 | let amBalance = getAccBalance(amId) | |
758 | 758 | let prBalance = getAccBalance(prId) | |
759 | 759 | let $t03053530992 = if ((outAssetId == amId)) | |
760 | 760 | then $Tuple7((amBalance - estimAmAmt), (prBalance - estimPrAmt), exchResult, estimPrAmt, 0, 0, (estimAmAmt + exchResult)) | |
761 | 761 | else if ((outAssetId == prId)) | |
762 | 762 | then $Tuple7((amBalance - estimAmAmt), (prBalance - estimPrAmt), 0, 0, exchResult, estimAmAmt, (estimPrAmt + exchResult)) | |
763 | 763 | else throw("wrong outAssetId") | |
764 | 764 | let amBalanceNow = $t03053530992._1 | |
765 | 765 | let prBalanceNow = $t03053530992._2 | |
766 | 766 | let virtSwapInAm = $t03053530992._3 | |
767 | 767 | let virtSwapOutPr = $t03053530992._4 | |
768 | 768 | let virtSwapInPr = $t03053530992._5 | |
769 | 769 | let virtSwapOutAm = $t03053530992._6 | |
770 | 770 | let totalGet = $t03053530992._7 | |
771 | 771 | if (if ((0 > virtSwapInAm)) | |
772 | 772 | then true | |
773 | 773 | else (0 > virtSwapInPr)) | |
774 | 774 | then throw("Wrong calc") | |
775 | 775 | else { | |
776 | 776 | let D0 = invoke(gwxCntr, "calcD", [toString(amBalanceNow), toString(prBalanceNow), A, Amult, Dconv], nil) | |
777 | 777 | let D1 = invoke(gwxCntr, "calcD", [toString(((amBalanceNow - virtSwapInAm) + virtSwapOutAm)), toString(((prBalanceNow + virtSwapOutPr) - virtSwapInPr)), A, Amult, Dconv], nil) | |
778 | 778 | let D0vsD1 = vd(parseBigIntValue(str(D1)), parseBigIntValue(str(D0)), slippage4D) | |
779 | 779 | if ((D0vsD1 == D0vsD1)) | |
780 | 780 | then { | |
781 | 781 | let finalRes = vad(toBigInt(totalGet), toBigInt(outAmount), toBigInt(slippage)) | |
782 | 782 | if ((finalRes == finalRes)) | |
783 | 783 | then { | |
784 | 784 | let $t03169731801 = if ((outAssetId == amId)) | |
785 | 785 | then $Tuple2(toInt(finalRes._2), 0) | |
786 | 786 | else $Tuple2(0, toInt(finalRes._2)) | |
787 | 787 | let outAm = $t03169731801._1 | |
788 | 788 | let outPr = $t03169731801._2 | |
789 | 789 | let curPrX18 = cpbi(t1(prBalance, prDcm), t1(amBalance, amDcm)) | |
790 | 790 | let curPr = f1(curPrX18, scale8) | |
791 | 791 | let state = [ScriptTransfer(userAddress, (outAm + outPr), if ((outAssetId == "WAVES")) | |
792 | 792 | then unit | |
793 | 793 | else fromBase58String(outAssetId)), StringEntry(gau(toString(userAddress), txId58), dataGetActionInfo(outAm, outPr, pmtAmt, curPr, height, lastBlock.timestamp)), IntegerEntry(pl(), curPr), IntegerEntry(ph(height, lastBlock.timestamp), curPr)] | |
794 | 794 | if ((state == state)) | |
795 | 795 | then { | |
796 | 796 | let burn = invoke(fca, "burn", [pmtAmt], [AttachedPayment(pmtAssetId, pmtAmt)]) | |
797 | 797 | if ((burn == burn)) | |
798 | 798 | then state | |
799 | 799 | else throw("Strict value is not equal to itself.") | |
800 | 800 | } | |
801 | 801 | else throw("Strict value is not equal to itself.") | |
802 | 802 | } | |
803 | 803 | else throw("Strict value is not equal to itself.") | |
804 | 804 | } | |
805 | 805 | else throw("Strict value is not equal to itself.") | |
806 | 806 | } | |
807 | 807 | } | |
808 | 808 | else throw("Strict value is not equal to itself.") | |
809 | 809 | } | |
810 | 810 | ||
811 | 811 | ||
812 | 812 | ||
813 | 813 | @Callable(i) | |
814 | 814 | func getNoLess (noLessThenAmtAsset,noLessThenPriceAsset) = { | |
815 | 815 | let r = cg(i) | |
816 | 816 | let outAmAmt = r._1 | |
817 | 817 | let outPrAmt = r._2 | |
818 | 818 | let pmtAmt = r._3 | |
819 | 819 | let pmtAssetId = r._4 | |
820 | 820 | let state = r._5 | |
821 | 821 | if ((noLessThenAmtAsset > outAmAmt)) | |
822 | 822 | then throw(((("Failed: " + toString(outAmAmt)) + " < ") + toString(noLessThenAmtAsset))) | |
823 | 823 | else if ((noLessThenPriceAsset > outPrAmt)) | |
824 | 824 | then throw(((("Failed: " + toString(outPrAmt)) + " < ") + toString(noLessThenPriceAsset))) | |
825 | 825 | else { | |
826 | 826 | let burnLPAssetOnFactory = invoke(fca, "burn", [pmtAmt], [AttachedPayment(pmtAssetId, pmtAmt)]) | |
827 | 827 | if ((burnLPAssetOnFactory == burnLPAssetOnFactory)) | |
828 | 828 | then state | |
829 | 829 | else throw("Strict value is not equal to itself.") | |
830 | 830 | } | |
831 | 831 | } | |
832 | 832 | ||
833 | 833 | ||
834 | 834 | ||
835 | 835 | @Callable(i) | |
836 | 836 | func unstakeAndGet (amount) = { | |
837 | 837 | let checkPayments = if ((size(i.payments) != 0)) | |
838 | 838 | then throw("No pmnts expd") | |
839 | 839 | else true | |
840 | 840 | if ((checkPayments == checkPayments)) | |
841 | 841 | then { | |
842 | 842 | let cfg = gpc() | |
843 | 843 | let factoryCfg = gfc() | |
844 | 844 | let lpAssetId = fromBase58String(cfg[idxLPAsId]) | |
845 | 845 | let staking = valueOrErrorMessage(addressFromString(factoryCfg[idxFactStakCntr]), "Wr st addr") | |
846 | 846 | let unstakeInv = invoke(staking, "unstake", [toBase58String(lpAssetId), amount], nil) | |
847 | 847 | if ((unstakeInv == unstakeInv)) | |
848 | 848 | then { | |
849 | 849 | let r = ego(toBase58String(i.transactionId), toBase58String(lpAssetId), amount, i.caller) | |
850 | 850 | let sts = parseIntValue(r._9) | |
851 | 851 | let state = r._10 | |
852 | 852 | let v = if (if (igs()) | |
853 | 853 | then true | |
854 | 854 | else (sts == PoolShutdown)) | |
855 | 855 | then throw(("Blocked: " + toString(sts))) | |
856 | 856 | else true | |
857 | 857 | if ((v == v)) | |
858 | 858 | then { | |
859 | 859 | let burnA = invoke(fca, "burn", [amount], [AttachedPayment(lpAssetId, amount)]) | |
860 | 860 | if ((burnA == burnA)) | |
861 | 861 | then state | |
862 | 862 | else throw("Strict value is not equal to itself.") | |
863 | 863 | } | |
864 | 864 | else throw("Strict value is not equal to itself.") | |
865 | 865 | } | |
866 | 866 | else throw("Strict value is not equal to itself.") | |
867 | 867 | } | |
868 | 868 | else throw("Strict value is not equal to itself.") | |
869 | 869 | } | |
870 | 870 | ||
871 | 871 | ||
872 | 872 | ||
873 | 873 | @Callable(i) | |
874 | 874 | func activate (amtAsStr,prAsStr) = if ((toString(i.caller) != toString(fca))) | |
875 | 875 | then throw("denied") | |
876 | 876 | else $Tuple2([StringEntry(aa(), amtAsStr), StringEntry(pa(), prAsStr)], "success") | |
877 | 877 | ||
878 | 878 | ||
879 | 879 | ||
880 | 880 | @Callable(i) | |
881 | 881 | func setS (k,v) = if ((toString(i.caller) != strf(this, ada()))) | |
882 | 882 | then pd | |
883 | 883 | else [StringEntry(k, v)] | |
884 | 884 | ||
885 | 885 | ||
886 | 886 | ||
887 | 887 | @Callable(i) | |
888 | 888 | func setI (k,v) = if ((toString(i.caller) != strf(this, ada()))) | |
889 | 889 | then pd | |
890 | 890 | else [IntegerEntry(k, v)] | |
891 | 891 | ||
892 | 892 | ||
893 | 893 | ||
894 | 894 | @Callable(i) | |
895 | 895 | func getPoolConfigWrapperREADONLY () = $Tuple2(nil, gpc()) | |
896 | 896 | ||
897 | 897 | ||
898 | 898 | ||
899 | 899 | @Callable(i) | |
900 | 900 | func getAccBalanceWrapperREADONLY (assetId) = $Tuple2(nil, getAccBalance(assetId)) | |
901 | 901 | ||
902 | 902 | ||
903 | 903 | ||
904 | 904 | @Callable(i) | |
905 | 905 | func calcPricesWrapperREADONLY (amAmt,prAmt,lpAmt) = { | |
906 | 906 | let pr = calcPrices(amAmt, prAmt, lpAmt) | |
907 | 907 | $Tuple2(nil, [toString(pr[0]), toString(pr[1]), toString(pr[2])]) | |
908 | 908 | } | |
909 | 909 | ||
910 | 910 | ||
911 | 911 | ||
912 | 912 | @Callable(i) | |
913 | 913 | func fromX18WrapperREADONLY (val,resScaleMult) = $Tuple2(nil, f1(parseBigIntValue(val), resScaleMult)) | |
914 | 914 | ||
915 | 915 | ||
916 | 916 | ||
917 | 917 | @Callable(i) | |
918 | 918 | func toX18WrapperREADONLY (origVal,origScaleMult) = $Tuple2(nil, toString(t1(origVal, origScaleMult))) | |
919 | 919 | ||
920 | 920 | ||
921 | 921 | ||
922 | 922 | @Callable(i) | |
923 | 923 | func calcPriceBigIntWrapperREADONLY (prAmtX18,amAmtX18) = $Tuple2(nil, toString(cpbi(parseBigIntValue(prAmtX18), parseBigIntValue(amAmtX18)))) | |
924 | 924 | ||
925 | 925 | ||
926 | 926 | ||
927 | 927 | @Callable(i) | |
928 | 928 | func estimatePutOperationWrapperREADONLY (txId58,slippage,inAmAmt,inAmId,inPrAmt,inPrId,usrAddr,isEval,emitLp) = $Tuple2(nil, epo(txId58, slippage, inAmAmt, inAmId, inPrAmt, inPrId, usrAddr, isEval, emitLp, false, 0, "")) | |
929 | 929 | ||
930 | 930 | ||
931 | 931 | ||
932 | 932 | @Callable(i) | |
933 | 933 | func estimateGetOperationWrapperREADONLY (txId58,pmtAsId,pmtLpAmt,usrAddr) = { | |
934 | 934 | let r = ego(txId58, pmtAsId, pmtLpAmt, addressFromStringValue(usrAddr)) | |
935 | 935 | $Tuple2(nil, $Tuple10(r._1, r._2, r._3, r._4, r._5, r._6, r._7, toString(r._8), r._9, r._10)) | |
936 | 936 | } | |
937 | 937 | ||
938 | 938 | ||
939 | 939 | @Verifier(tx) | |
940 | 940 | func verify () = match tx { | |
941 | 941 | case order: Order => | |
942 | 942 | let mtchPub = mp() | |
943 | 943 | let orV = moa(order) | |
944 | 944 | let sndrV = sigVerify(order.bodyBytes, order.proofs[0], order.senderPublicKey) | |
945 | 945 | let mtchV = sigVerify(order.bodyBytes, order.proofs[1], mtchPub) | |
946 | 946 | if (if (if (orV) | |
947 | 947 | then sndrV | |
948 | 948 | else false) | |
949 | 949 | then mtchV | |
950 | 950 | else false) | |
951 | 951 | then true | |
952 | 952 | else toe(orV, sndrV, mtchV) | |
953 | 953 | case _ => | |
954 | 954 | let targetPublicKey = match m() { | |
955 | 955 | case pk: ByteVector => | |
956 | 956 | pk | |
957 | 957 | case _: Unit => | |
958 | 958 | tx.senderPublicKey | |
959 | 959 | case _ => | |
960 | 960 | throw("Match error") | |
961 | 961 | } | |
962 | 962 | sigVerify(tx.bodyBytes, tx.proofs[0], targetPublicKey) | |
963 | 963 | } | |
964 | 964 |
github/deemru/w8io/169f3d6 83.39 ms ◑