tx · CN4sDsfc51TABLKSWNPuWtCrFD6MfxDpeEqAWC7npzjC 3MsMP2pb2p8MDd6Rxb7XEXqqwEhE8ATfyai: -0.01400000 Waves 2022.04.15 12:39 [2009502] smart account 3MsMP2pb2p8MDd6Rxb7XEXqqwEhE8ATfyai > SELF 0.00000000 Waves
{ "type": 13, "id": "CN4sDsfc51TABLKSWNPuWtCrFD6MfxDpeEqAWC7npzjC", "fee": 1400000, "feeAssetId": null, "timestamp": 1650015600641, "version": 1, "sender": "3MsMP2pb2p8MDd6Rxb7XEXqqwEhE8ATfyai", "senderPublicKey": "2JEaBjtjvMoNGKZmL9QxYefa1VkMJM3vMW8rNvTs9R2H", "proofs": [ "2ZDWLxV8W7eeuzPeWiPshkkakanHaUHUehNvhQWGEWnMi15K5woBhXrY2fnJFrASboNHTAkMGD9RUBh6GjzGd6Pc" ], "script": "base64:AAIFAAAAAAAAAFAIAhIKCggICAgICAgIARIDCgEIEgYKBAgICAgSBAoCCBgSAwoBCBIAEgkKBwgICAgIAQgSBAoCCAESAwoBARIDCgEBEgMKAQESBgoECAgICAAAAE0AAAAABlNDQUxFOAAAAAAAAAAACAAAAAAFTVVMVDgAAAAAAAX14QAAAAAAB1NDQUxFMTgAAAAAAAAAABIAAAAABk1VTFQxOAkAATYAAAABAA3gtrOnZAAAAAAAAA5QT09MV0VJR0hUTVVMVAUAAAAFTVVMVDgAAAAADkdXWHZpcnR1YWxQT09MAgAAAA5HV1h2aXJ0dWFsUE9PTAAAAAARZGVjaW1hbHNNdWx0UHJpY2UJAABoAAAAAgkAAGgAAAACAAAAAAAAAABkAAAAAAAAAAPoAAAAAAAAAAPoAAAAAANTRVACAAAAAl9fAAAAAAVFTVBUWQIAAAAAAAAAAApQb29sQWN0aXZlAAAAAAAAAAABAAAAAA9Qb29sUHV0RGlzYWJsZWQAAAAAAAAAAAIAAAAAE1Bvb2xNYXRjaGVyRGlzYWJsZWQAAAAAAAAAAAMAAAAADFBvb2xTaHV0ZG93bgAAAAAA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AAAtNYXRjaCBlcnJvcgkAAfQAAAADCAUAAAACdHgAAAAJYm9keUJ5dGVzCQABkQAAAAIIBQAAAAJ0eAAAAAZwcm9vZnMAAAAAAAAAAAAFAAAAD3RhcmdldFB1YmxpY0tleejuMzM=", "chainId": 84, "height": 2009502, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 3i9ZTQ6pvbZsJDxZxhjcj1gQX7wrYfW2KvMgMxAsqXAq Next: F1SK7dg4DNo4JgPHTmVLgx5ovnZShKmYFnFWpk7YTBUY Diff:
Old | New | Differences | |
---|---|---|---|
428 | 428 | ||
429 | 429 | ||
430 | 430 | @Callable(i) | |
431 | + | func burn222 (amountToBurn) = { | |
432 | + | let caller = i.caller | |
433 | + | let originCaller = i.originCaller | |
434 | + | let payment = value(i.payments[0]) | |
435 | + | let paymentAmount = value(payment.amount) | |
436 | + | let inAmountAssetId = toBase58String(value(payment.assetId)) | |
437 | + | let lpAssetRequestedForBurning = valueOrErrorMessage(getString(keyMappingPoolContracToLPAsset(toString(caller))), "Invalid LP address called me.") | |
438 | + | if ((inAmountAssetId != lpAssetRequestedForBurning)) | |
439 | + | then throw("Invalid asset passed.") | |
440 | + | else if ((amountToBurn != paymentAmount)) | |
441 | + | then throw("Invalid amount passed.") | |
442 | + | else { | |
443 | + | let lpAsset = fromBase58String(lpAssetRequestedForBurning) | |
444 | + | $Tuple2([Burn(lpAsset, amountToBurn)], "success") | |
445 | + | } | |
446 | + | } | |
447 | + | ||
448 | + | ||
449 | + | ||
450 | + | @Callable(i) | |
431 | 451 | func modifyWeights (btcPoolAddress,ethPoolAddress,ethBtcPoolAddress,usdcUsdtPoolAddress) = { | |
432 | 452 | let checkCaller = mustManager(i) | |
433 | 453 | if ((checkCaller == checkCaller)) |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 5 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let SCALE8 = 8 | |
5 | 5 | ||
6 | 6 | let MULT8 = 100000000 | |
7 | 7 | ||
8 | 8 | let SCALE18 = 18 | |
9 | 9 | ||
10 | 10 | let MULT18 = toBigInt(1000000000000000000) | |
11 | 11 | ||
12 | 12 | let POOLWEIGHTMULT = MULT8 | |
13 | 13 | ||
14 | 14 | let GWXvirtualPOOL = "GWXvirtualPOOL" | |
15 | 15 | ||
16 | 16 | let decimalsMultPrice = ((100 * 1000) * 1000) | |
17 | 17 | ||
18 | 18 | let SEP = "__" | |
19 | 19 | ||
20 | 20 | let EMPTY = "" | |
21 | 21 | ||
22 | 22 | let PoolActive = 1 | |
23 | 23 | ||
24 | 24 | let PoolPutDisabled = 2 | |
25 | 25 | ||
26 | 26 | let PoolMatcherDisabled = 3 | |
27 | 27 | ||
28 | 28 | let PoolShutdown = 4 | |
29 | 29 | ||
30 | 30 | let idxInternalAssetId = 1 | |
31 | 31 | ||
32 | 32 | let idxResutActions = 2 | |
33 | 33 | ||
34 | 34 | let idxIfAssetIdCalculationPerformed = 3 | |
35 | 35 | ||
36 | 36 | let idxPoolAddress = 1 | |
37 | 37 | ||
38 | 38 | let idxPoolStatus = 2 | |
39 | 39 | ||
40 | 40 | let idxPoolLPAssetId = 3 | |
41 | 41 | ||
42 | 42 | let idxAmtAssetId = 4 | |
43 | 43 | ||
44 | 44 | let idxPriceAssetId = 5 | |
45 | 45 | ||
46 | 46 | let idxAmtAssetDcm = 6 | |
47 | 47 | ||
48 | 48 | let idxPriceAssetDcm = 7 | |
49 | 49 | ||
50 | 50 | let idxIAmtAssetId = 8 | |
51 | 51 | ||
52 | 52 | let idxIPriceAssetId = 9 | |
53 | 53 | ||
54 | 54 | let idxLPAssetDcm = 10 | |
55 | 55 | ||
56 | 56 | let idxPoolType = 11 | |
57 | 57 | ||
58 | 58 | func keyFactoryConfig () = "%s__factoryConfig" | |
59 | 59 | ||
60 | 60 | ||
61 | 61 | func keyLpTokensList () = "%s__lpTokensList" | |
62 | 62 | ||
63 | 63 | ||
64 | 64 | func keyPoolScriptHash () = "%s%s__pool__scriptHash" | |
65 | 65 | ||
66 | 66 | ||
67 | 67 | func keyMatcherPub () = "%s%s__matcher__publicKey" | |
68 | 68 | ||
69 | 69 | ||
70 | 70 | func keyLegacyFactoryContract () = "%s__legacyFactoryContract" | |
71 | 71 | ||
72 | 72 | ||
73 | 73 | func keyLegacyPools () = "%s__legacyPools" | |
74 | 74 | ||
75 | 75 | ||
76 | 76 | func keyManagerPublicKey () = "%s__managerPublicKey" | |
77 | 77 | ||
78 | 78 | ||
79 | 79 | func keyPendingManagerPublicKey () = "%s__pendingManagerPublicKey" | |
80 | 80 | ||
81 | 81 | ||
82 | 82 | func keyPriceDecimals () = "%s__priceDecimals" | |
83 | 83 | ||
84 | 84 | ||
85 | 85 | func keyAllPoolsShutdown () = "%s__shutdown" | |
86 | 86 | ||
87 | 87 | ||
88 | 88 | func keyNextInternalAssetId () = "%s__nextInternalAssetId" | |
89 | 89 | ||
90 | 90 | ||
91 | 91 | func keyPoolToWeight (poolAddress) = ("%s%s__poolWeight__" + poolAddress) | |
92 | 92 | ||
93 | 93 | ||
94 | 94 | func keyPoolToWeightHistory (poolAddress,num) = ((("%s%s__poolWeight__" + poolAddress) + "__") + toString(num)) | |
95 | 95 | ||
96 | 96 | ||
97 | 97 | func keyMappingsInternal2baseAssetId (internalBaseAsset) = ("%s%s%d__mappings__internal2baseAssetId__" + toString(internalBaseAsset)) | |
98 | 98 | ||
99 | 99 | ||
100 | 100 | func keyMappingsBaseAsset2internalId (baseAssetStr) = ("%s%s%s__mappings__baseAsset2internalId__" + baseAssetStr) | |
101 | 101 | ||
102 | 102 | ||
103 | 103 | func keyPoolConfig (amountAssetInternal,priceAssetInternal) = (((("%d%d%s__" + amountAssetInternal) + "__") + priceAssetInternal) + "__config") | |
104 | 104 | ||
105 | 105 | ||
106 | 106 | func keyMappingLpAssetToPoolAssets (lpAssetStr) = (("%s%s%s__" + lpAssetStr) + "__mappings__lpAsset2Pool") | |
107 | 107 | ||
108 | 108 | ||
109 | 109 | func keyMappingPoolAssetsToLpasset (internalAmountAssetIdStr,internalPriceAssetIdStr) = (((("%d%d%s%s__" + internalAmountAssetIdStr) + "__") + internalPriceAssetIdStr) + "__mappings__PoolAssets2LpAsset") | |
110 | 110 | ||
111 | 111 | ||
112 | 112 | func keyMappingPoolContractAddressToPoolAssets (poolContractAddress) = (("%s%s%s__" + poolContractAddress) + "__mappings__poolContract2PoolAssets") | |
113 | 113 | ||
114 | 114 | ||
115 | 115 | func keyMappingPoolAssetsToPoolContractAddress (internalAmountAssetIdStr,internalPriceAssetIdStr) = (((("%d%d%s%s__" + toString(internalAmountAssetIdStr)) + "__") + toString(internalPriceAssetIdStr)) + "__mappings__poolAssets2PoolContract") | |
116 | 116 | ||
117 | 117 | ||
118 | 118 | func keyMappingPoolContracToLPAsset (poolContractAddress) = (("%s%s%s__" + poolContractAddress) + "__mappings__poolContract2LpAsset") | |
119 | 119 | ||
120 | 120 | ||
121 | 121 | func keyMappingPoolLPAssetToPoolContractAddress (lpAssetStr) = (("%s%s%s__" + lpAssetStr) + "__mappings__lpAsset2PoolContract") | |
122 | 122 | ||
123 | 123 | ||
124 | 124 | func getStringOrFail (key) = valueOrErrorMessage(getString(this, key), ("No data for this.key=" + key)) | |
125 | 125 | ||
126 | 126 | ||
127 | 127 | func getBooleanOrFail (key) = valueOrErrorMessage(getBoolean(this, key), ("No data for this.key=" + key)) | |
128 | 128 | ||
129 | 129 | ||
130 | 130 | func getIntOrFail (key) = valueOrErrorMessage(getInteger(this, key), ("No data for this.key=" + key)) | |
131 | 131 | ||
132 | 132 | ||
133 | 133 | let IdxFactoryCfgStakingDapp = 1 | |
134 | 134 | ||
135 | 135 | let IdxFactoryCfgBoostingDapp = 2 | |
136 | 136 | ||
137 | 137 | let IdxFactoryCfgIdoDapp = 3 | |
138 | 138 | ||
139 | 139 | let IdxFactoryCfgTeamDapp = 4 | |
140 | 140 | ||
141 | 141 | let IdxFactoryCfgEmissionDapp = 5 | |
142 | 142 | ||
143 | 143 | let IdxFactoryCfgRestDapp = 6 | |
144 | 144 | ||
145 | 145 | let IdxFactoryCfgSlippageDapp = 7 | |
146 | 146 | ||
147 | 147 | let IdxFactoryCfgDaoDapp = 8 | |
148 | 148 | ||
149 | 149 | let IdxFactoryCfgMarketingDapp = 9 | |
150 | 150 | ||
151 | 151 | let IdxFactoryCfgGwxRewardDapp = 10 | |
152 | 152 | ||
153 | 153 | let IdxFactoryCfgBirdsDapp = 11 | |
154 | 154 | ||
155 | 155 | func getBoostingAddressOrFail (factoryCfg) = addressFromStringValue(factoryCfg[IdxFactoryCfgBoostingDapp]) | |
156 | 156 | ||
157 | 157 | ||
158 | 158 | func getEmissionAddressOrFail (factoryCfg) = addressFromStringValue(factoryCfg[IdxFactoryCfgEmissionDapp]) | |
159 | 159 | ||
160 | 160 | ||
161 | 161 | func getStakingAddressOrFail (factoryCfg) = addressFromStringValue(factoryCfg[IdxFactoryCfgStakingDapp]) | |
162 | 162 | ||
163 | 163 | ||
164 | 164 | func getGwxRewardAddressOrFail (factoryCfg) = addressFromStringValue(factoryCfg[IdxFactoryCfgGwxRewardDapp]) | |
165 | 165 | ||
166 | 166 | ||
167 | 167 | func managerPublicKeyOrUnit () = match getString(keyManagerPublicKey()) { | |
168 | 168 | case s: String => | |
169 | 169 | fromBase58String(s) | |
170 | 170 | case _: Unit => | |
171 | 171 | unit | |
172 | 172 | case _ => | |
173 | 173 | throw("Match error") | |
174 | 174 | } | |
175 | 175 | ||
176 | 176 | ||
177 | 177 | func pendingManagerPublicKeyOrUnit () = match getString(keyPendingManagerPublicKey()) { | |
178 | 178 | case s: String => | |
179 | 179 | fromBase58String(s) | |
180 | 180 | case _: Unit => | |
181 | 181 | unit | |
182 | 182 | case _ => | |
183 | 183 | throw("Match error") | |
184 | 184 | } | |
185 | 185 | ||
186 | 186 | ||
187 | 187 | func mustManager (i) = { | |
188 | 188 | let pd = throw("Permission denied") | |
189 | 189 | match managerPublicKeyOrUnit() { | |
190 | 190 | case pk: ByteVector => | |
191 | 191 | if ((i.callerPublicKey == pk)) | |
192 | 192 | then true | |
193 | 193 | else pd | |
194 | 194 | case _: Unit => | |
195 | 195 | if ((i.caller == this)) | |
196 | 196 | then true | |
197 | 197 | else pd | |
198 | 198 | case _ => | |
199 | 199 | throw("Match error") | |
200 | 200 | } | |
201 | 201 | } | |
202 | 202 | ||
203 | 203 | ||
204 | 204 | func dataFactoryCfgV3 (stakingAddress,boostingAddress,idoContract,teamContract,emissionContract,restContract,slippageContract,daoContract,marketingContract,gwxRewardsContract,birdsContract) = makeString(["%s%s%s%s%s%s%s%s%s%s%s", stakingAddress, boostingAddress, idoContract, teamContract, emissionContract, restContract, slippageContract, daoContract, marketingContract, gwxRewardsContract, birdsContract], SEP) | |
205 | 205 | ||
206 | 206 | ||
207 | 207 | func dataFactoryCfg (stakingAddress,boostingAddress,idoContract,teamContract,emissionContract,restContract,slippageContract) = makeString(["%s%s%s%s%s%s", stakingAddress, boostingAddress, idoContract, teamContract, emissionContract, restContract, slippageContract], SEP) | |
208 | 208 | ||
209 | 209 | ||
210 | 210 | func dataPoolCfg (poolAddress,poolStatus,lpAssetId,amountAssetStr,priceAssetStr,amountAssetDecimals,priceAssetDecimals,amountAssetInternalId,priceAssetInternalId,lpAssetDecimals,poolType) = makeString(["%s%d%s%s%s%d%d%d%d%d%s", poolAddress, poolStatus, lpAssetId, amountAssetStr, priceAssetStr, toString(amountAssetDecimals), toString(priceAssetDecimals), toString(amountAssetInternalId), toString(priceAssetInternalId), toString(lpAssetDecimals), poolType], SEP) | |
211 | 211 | ||
212 | 212 | ||
213 | 213 | func dataMappingPoolAssets (internalAmountAssetStr,internalPriceAssetStr) = makeString(["%d%d", toString(internalAmountAssetStr), toString(internalPriceAssetStr)], SEP) | |
214 | 214 | ||
215 | 215 | ||
216 | 216 | func getPoolConfig (poolAddress) = { | |
217 | 217 | let poolAssets = split(getStringOrFail(keyMappingPoolContractAddressToPoolAssets(poolAddress)), SEP) | |
218 | 218 | let amountAssetInternal = poolAssets[1] | |
219 | 219 | let priceAssetInternal = poolAssets[2] | |
220 | 220 | split(getStringOrFail(keyPoolConfig(amountAssetInternal, priceAssetInternal)), SEP) | |
221 | 221 | } | |
222 | 222 | ||
223 | 223 | ||
224 | 224 | func getInternalAssetIdOrCreate (assetIdStr,incrementor) = { | |
225 | 225 | let internalAssetId = valueOrElse(getInteger(this, keyMappingsBaseAsset2internalId(assetIdStr)), 0) | |
226 | 226 | let currentIndexOfInternalId = valueOrElse(getInteger(this, keyNextInternalAssetId()), 0) | |
227 | 227 | let result = if ((internalAssetId == 0)) | |
228 | 228 | then { | |
229 | 229 | let newInternalAssetId = (currentIndexOfInternalId + incrementor) | |
230 | 230 | $Tuple3(newInternalAssetId, [IntegerEntry(keyNextInternalAssetId(), newInternalAssetId), IntegerEntry(keyMappingsBaseAsset2internalId(assetIdStr), newInternalAssetId), StringEntry(keyMappingsInternal2baseAssetId(newInternalAssetId), assetIdStr)], true) | |
231 | 231 | } | |
232 | 232 | else $Tuple3(internalAssetId, nil, false) | |
233 | 233 | result | |
234 | 234 | } | |
235 | 235 | ||
236 | 236 | ||
237 | 237 | func createLpTokensListEntry (newLpToken) = { | |
238 | 238 | let lpTokens = getString(this, keyLpTokensList()) | |
239 | 239 | if (isDefined(lpTokens)) | |
240 | 240 | then ((value(lpTokens) + SEP) + newLpToken) | |
241 | 241 | else newLpToken | |
242 | 242 | } | |
243 | 243 | ||
244 | 244 | ||
245 | 245 | @Callable(i) | |
246 | 246 | func constructor (stakingContract,boostingContract,idoContract,teamContract,emissionContract,restContract,slpipageContract,priceDecimals) = { | |
247 | 247 | let checkCaller = mustManager(i) | |
248 | 248 | if ((checkCaller == checkCaller)) | |
249 | 249 | then [StringEntry(keyFactoryConfig(), dataFactoryCfg(stakingContract, boostingContract, idoContract, teamContract, emissionContract, restContract, slpipageContract)), IntegerEntry(keyPriceDecimals(), priceDecimals)] | |
250 | 250 | else throw("Strict value is not equal to itself.") | |
251 | 251 | } | |
252 | 252 | ||
253 | 253 | ||
254 | 254 | ||
255 | 255 | @Callable(i) | |
256 | 256 | func constructorV2 (mathcherPub58Str) = { | |
257 | 257 | let checkCaller = mustManager(i) | |
258 | 258 | if ((checkCaller == checkCaller)) | |
259 | 259 | then { | |
260 | 260 | let mathcerPub = addressFromPublicKey(fromBase58String(mathcherPub58Str)) | |
261 | 261 | if ((mathcerPub == mathcerPub)) | |
262 | 262 | then [StringEntry(keyMatcherPub(), mathcherPub58Str)] | |
263 | 263 | else throw("Strict value is not equal to itself.") | |
264 | 264 | } | |
265 | 265 | else throw("Strict value is not equal to itself.") | |
266 | 266 | } | |
267 | 267 | ||
268 | 268 | ||
269 | 269 | ||
270 | 270 | @Callable(i) | |
271 | 271 | func constructorV3 (daoContract,marketingContract,gwxRewardsContract,birdsContract) = { | |
272 | 272 | let checkCaller = mustManager(i) | |
273 | 273 | if ((checkCaller == checkCaller)) | |
274 | 274 | then { | |
275 | 275 | let factoryCfg = split(getStringOrFail(keyFactoryConfig()), SEP) | |
276 | 276 | [StringEntry(keyFactoryConfig(), dataFactoryCfgV3(factoryCfg[1], factoryCfg[2], factoryCfg[3], factoryCfg[4], factoryCfg[5], factoryCfg[6], factoryCfg[7], daoContract, marketingContract, gwxRewardsContract, birdsContract))] | |
277 | 277 | } | |
278 | 278 | else throw("Strict value is not equal to itself.") | |
279 | 279 | } | |
280 | 280 | ||
281 | 281 | ||
282 | 282 | ||
283 | 283 | @Callable(i) | |
284 | 284 | func constructorV4 (legacyFactoryContract,legacyPools) = { | |
285 | 285 | let checkCaller = mustManager(i) | |
286 | 286 | if ((checkCaller == checkCaller)) | |
287 | 287 | then [StringEntry(keyLegacyFactoryContract(), legacyFactoryContract), StringEntry(keyLegacyPools(), makeString(legacyPools, SEP))] | |
288 | 288 | else throw("Strict value is not equal to itself.") | |
289 | 289 | } | |
290 | 290 | ||
291 | 291 | ||
292 | 292 | ||
293 | 293 | @Callable(i) | |
294 | 294 | func setManager (pendingManagerPublicKey) = { | |
295 | 295 | let checkCaller = mustManager(i) | |
296 | 296 | if ((checkCaller == checkCaller)) | |
297 | 297 | then { | |
298 | 298 | let checkManagerPublicKey = fromBase58String(pendingManagerPublicKey) | |
299 | 299 | if ((checkManagerPublicKey == checkManagerPublicKey)) | |
300 | 300 | then [StringEntry(keyPendingManagerPublicKey(), pendingManagerPublicKey)] | |
301 | 301 | else throw("Strict value is not equal to itself.") | |
302 | 302 | } | |
303 | 303 | else throw("Strict value is not equal to itself.") | |
304 | 304 | } | |
305 | 305 | ||
306 | 306 | ||
307 | 307 | ||
308 | 308 | @Callable(i) | |
309 | 309 | func confirmManager () = { | |
310 | 310 | let pm = pendingManagerPublicKeyOrUnit() | |
311 | 311 | let hasPM = if (isDefined(pm)) | |
312 | 312 | then true | |
313 | 313 | else throw("No pending manager") | |
314 | 314 | if ((hasPM == hasPM)) | |
315 | 315 | then { | |
316 | 316 | let checkPM = if ((i.callerPublicKey == value(pm))) | |
317 | 317 | then true | |
318 | 318 | else throw("You are not pending manager") | |
319 | 319 | if ((checkPM == checkPM)) | |
320 | 320 | then [StringEntry(keyManagerPublicKey(), toBase58String(value(pm))), DeleteEntry(keyPendingManagerPublicKey())] | |
321 | 321 | else throw("Strict value is not equal to itself.") | |
322 | 322 | } | |
323 | 323 | else throw("Strict value is not equal to itself.") | |
324 | 324 | } | |
325 | 325 | ||
326 | 326 | ||
327 | 327 | ||
328 | 328 | @Callable(i) | |
329 | 329 | func activateNewPool (poolAddress,amountAssetStr,priceAssetStr,lpAssetName,lpAssetDescr,poolWeight,poolType) = { | |
330 | 330 | let checkCaller = mustManager(i) | |
331 | 331 | if ((checkCaller == checkCaller)) | |
332 | 332 | then if (isDefined(getString(keyMappingPoolContractAddressToPoolAssets(poolAddress)))) | |
333 | 333 | then throw((("Pool address " + poolAddress) + " already registered.")) | |
334 | 334 | else { | |
335 | 335 | let internalAmountAssetData = getInternalAssetIdOrCreate(amountAssetStr, 1) | |
336 | 336 | let internalAmountAssetId = internalAmountAssetData._1 | |
337 | 337 | let internalPriceAssetData = getInternalAssetIdOrCreate(priceAssetStr, if (internalAmountAssetData._3) | |
338 | 338 | then 2 | |
339 | 339 | else 1) | |
340 | 340 | let internalPriceAssetId = internalPriceAssetData._1 | |
341 | 341 | let poolAccountScriptHash = valueOrErrorMessage(scriptHash(addressFromStringValue(poolAddress)), ("No script has been found on pool account " + poolAddress)) | |
342 | 342 | let ethalonPoolAccountScriptHash = getBinaryValue(keyPoolScriptHash()) | |
343 | 343 | let poolConfig = getString(this, keyPoolConfig(toString(internalAmountAssetId), toString(internalPriceAssetId))) | |
344 | 344 | if (isDefined(poolConfig)) | |
345 | 345 | then throw((((("Pool " + amountAssetStr) + "/") + priceAssetStr) + " has already been activated.")) | |
346 | 346 | else { | |
347 | 347 | let poolConfigValue = value(getString(this, keyPoolConfig(toString(internalAmountAssetId), toString(internalPriceAssetId)))) | |
348 | 348 | let amountAssetsDecimals = if ((amountAssetStr == "WAVES")) | |
349 | 349 | then decimalsMultPrice | |
350 | 350 | else pow(10, 0, value(assetInfo(fromBase58String(amountAssetStr))).decimals, 0, 0, DOWN) | |
351 | 351 | let priceAssetsDecimals = if ((priceAssetStr == "WAVES")) | |
352 | 352 | then decimalsMultPrice | |
353 | 353 | else pow(10, 0, value(assetInfo(fromBase58String(priceAssetStr))).decimals, 0, 0, DOWN) | |
354 | 354 | let lpAssetIssueAction = Issue(lpAssetName, lpAssetDescr, 1, 8, true) | |
355 | 355 | let lpAssetId = calculateAssetId(lpAssetIssueAction) | |
356 | 356 | let lpAssetIdStr = toBase58String(lpAssetId) | |
357 | 357 | let poolActivateInvokeResult = invoke(addressFromStringValue(poolAddress), "activate", [amountAssetStr, priceAssetStr], nil) | |
358 | 358 | if ((poolActivateInvokeResult == poolActivateInvokeResult)) | |
359 | 359 | then if ((poolActivateInvokeResult != "success")) | |
360 | 360 | then throw("Pool initialisation error happened.") | |
361 | 361 | else $Tuple2(((internalAmountAssetData._2 ++ internalPriceAssetData._2) ++ [lpAssetIssueAction, Burn(lpAssetId, 1), StringEntry(keyPoolConfig(toString(internalAmountAssetId), toString(internalPriceAssetId)), dataPoolCfg(poolAddress, toString(PoolActive), lpAssetIdStr, amountAssetStr, priceAssetStr, amountAssetsDecimals, priceAssetsDecimals, internalAmountAssetId, internalPriceAssetId, decimalsMultPrice, poolType)), StringEntry(keyMappingLpAssetToPoolAssets(lpAssetIdStr), dataMappingPoolAssets(internalAmountAssetId, internalPriceAssetId)), StringEntry(keyMappingPoolAssetsToLpasset(toString(internalAmountAssetId), toString(internalPriceAssetId)), ("%s__" + lpAssetIdStr)), StringEntry(keyMappingPoolContractAddressToPoolAssets(poolAddress), dataMappingPoolAssets(internalAmountAssetId, internalPriceAssetId)), StringEntry(keyMappingPoolAssetsToPoolContractAddress(internalAmountAssetId, internalPriceAssetId), poolAddress), StringEntry(keyMappingPoolLPAssetToPoolContractAddress(lpAssetIdStr), poolAddress), StringEntry(keyMappingPoolContracToLPAsset(poolAddress), lpAssetIdStr), IntegerEntry(keyPoolToWeight(poolAddress), poolWeight), StringEntry(keyLpTokensList(), createLpTokensListEntry(lpAssetIdStr))]), "success") | |
362 | 362 | else throw("Strict value is not equal to itself.") | |
363 | 363 | } | |
364 | 364 | } | |
365 | 365 | else throw("Strict value is not equal to itself.") | |
366 | 366 | } | |
367 | 367 | ||
368 | 368 | ||
369 | 369 | ||
370 | 370 | @Callable(i) | |
371 | 371 | func managePool (poolAddress,newStatus) = { | |
372 | 372 | let checkCaller = mustManager(i) | |
373 | 373 | if ((checkCaller == checkCaller)) | |
374 | 374 | then { | |
375 | 375 | let poolConfig = getPoolConfig(poolAddress) | |
376 | 376 | let poolStatus = poolConfig[idxPoolStatus] | |
377 | 377 | let lpAssetIdStr = poolConfig[idxPoolLPAssetId] | |
378 | 378 | let amountAssetStr = poolConfig[idxAmtAssetId] | |
379 | 379 | let priceAssetStr = poolConfig[idxPriceAssetId] | |
380 | 380 | let amountAssetsDecimals = parseIntValue(poolConfig[idxAmtAssetDcm]) | |
381 | 381 | let priceAssetsDecimals = parseIntValue(poolConfig[idxPriceAssetDcm]) | |
382 | 382 | let internalAmountAssetId = parseIntValue(poolConfig[idxIAmtAssetId]) | |
383 | 383 | let internalPriceAssetId = parseIntValue(poolConfig[idxIPriceAssetId]) | |
384 | 384 | let lpAssetDcm = parseIntValue(poolConfig[idxLPAssetDcm]) | |
385 | 385 | let poolType = poolConfig[idxPoolType] | |
386 | 386 | [StringEntry(keyPoolConfig(toString(internalAmountAssetId), toString(internalPriceAssetId)), dataPoolCfg(poolAddress, toString(newStatus), lpAssetIdStr, amountAssetStr, priceAssetStr, amountAssetsDecimals, priceAssetsDecimals, internalAmountAssetId, internalPriceAssetId, lpAssetDcm, poolType))] | |
387 | 387 | } | |
388 | 388 | else throw("Strict value is not equal to itself.") | |
389 | 389 | } | |
390 | 390 | ||
391 | 391 | ||
392 | 392 | ||
393 | 393 | @Callable(i) | |
394 | 394 | func emit (amountToEmit) = { | |
395 | 395 | let caller = i.caller | |
396 | 396 | let originCaller = i.originCaller | |
397 | 397 | let lpAssetRequested = valueOrErrorMessage(getString(keyMappingPoolContracToLPAsset(toString(caller))), "Invalid LP address called me.") | |
398 | 398 | let lpAsset = fromBase58String(lpAssetRequested) | |
399 | 399 | let legacyPools = split(valueOrElse(getString(keyLegacyPools()), EMPTY), SEP) | |
400 | 400 | let legacyFactoryContract = addressFromStringValue(valueOrErrorMessage(getString(keyLegacyFactoryContract()), "Legacy factory contract does not exists.")) | |
401 | 401 | if ((0 >= amountToEmit)) | |
402 | 402 | then nil | |
403 | 403 | else if (containsElement(legacyPools, toString(caller))) | |
404 | 404 | then $Tuple2(nil, legacyFactoryContract) | |
405 | 405 | else $Tuple2([Reissue(lpAsset, amountToEmit, true), ScriptTransfer(i.caller, amountToEmit, lpAsset)], "success") | |
406 | 406 | } | |
407 | 407 | ||
408 | 408 | ||
409 | 409 | ||
410 | 410 | @Callable(i) | |
411 | 411 | func burn (amountToBurn) = { | |
412 | 412 | let caller = i.caller | |
413 | 413 | let originCaller = i.originCaller | |
414 | 414 | let payment = value(i.payments[0]) | |
415 | 415 | let paymentAmount = value(payment.amount) | |
416 | 416 | let inAmountAssetId = toBase58String(value(payment.assetId)) | |
417 | 417 | let lpAssetRequestedForBurning = valueOrErrorMessage(getString(keyMappingPoolContracToLPAsset(toString(caller))), "Invalid LP address called me.") | |
418 | 418 | if ((inAmountAssetId != lpAssetRequestedForBurning)) | |
419 | 419 | then throw("Invalid asset passed.") | |
420 | 420 | else if ((amountToBurn != paymentAmount)) | |
421 | 421 | then throw("Invalid amount passed.") | |
422 | 422 | else { | |
423 | 423 | let lpAsset = fromBase58String(lpAssetRequestedForBurning) | |
424 | 424 | $Tuple2([Burn(lpAsset, amountToBurn)], "success") | |
425 | 425 | } | |
426 | 426 | } | |
427 | 427 | ||
428 | 428 | ||
429 | 429 | ||
430 | 430 | @Callable(i) | |
431 | + | func burn222 (amountToBurn) = { | |
432 | + | let caller = i.caller | |
433 | + | let originCaller = i.originCaller | |
434 | + | let payment = value(i.payments[0]) | |
435 | + | let paymentAmount = value(payment.amount) | |
436 | + | let inAmountAssetId = toBase58String(value(payment.assetId)) | |
437 | + | let lpAssetRequestedForBurning = valueOrErrorMessage(getString(keyMappingPoolContracToLPAsset(toString(caller))), "Invalid LP address called me.") | |
438 | + | if ((inAmountAssetId != lpAssetRequestedForBurning)) | |
439 | + | then throw("Invalid asset passed.") | |
440 | + | else if ((amountToBurn != paymentAmount)) | |
441 | + | then throw("Invalid amount passed.") | |
442 | + | else { | |
443 | + | let lpAsset = fromBase58String(lpAssetRequestedForBurning) | |
444 | + | $Tuple2([Burn(lpAsset, amountToBurn)], "success") | |
445 | + | } | |
446 | + | } | |
447 | + | ||
448 | + | ||
449 | + | ||
450 | + | @Callable(i) | |
431 | 451 | func modifyWeights (btcPoolAddress,ethPoolAddress,ethBtcPoolAddress,usdcUsdtPoolAddress) = { | |
432 | 452 | let checkCaller = mustManager(i) | |
433 | 453 | if ((checkCaller == checkCaller)) | |
434 | 454 | then { | |
435 | 455 | let ethBtcWeightNew = ((5 * POOLWEIGHTMULT) / 100) | |
436 | 456 | let usdcUsdtWeightNew = ((5 * POOLWEIGHTMULT) / 100) | |
437 | 457 | let weightDecrement = ((5 * POOLWEIGHTMULT) / 100) | |
438 | 458 | let factoryCfg = split(getStringOrFail(keyFactoryConfig()), SEP) | |
439 | 459 | let stakingDapp = getStakingAddressOrFail(factoryCfg) | |
440 | 460 | let gwxRewardDapp = getGwxRewardAddressOrFail(factoryCfg) | |
441 | 461 | let btcWeightKEY = keyPoolToWeight(btcPoolAddress) | |
442 | 462 | let ethWeightKEY = keyPoolToWeight(ethPoolAddress) | |
443 | 463 | let ethBtcWeightKEY = keyPoolToWeight(ethBtcPoolAddress) | |
444 | 464 | let usdcUsdtWeightKEY = keyPoolToWeight(usdcUsdtPoolAddress) | |
445 | 465 | let btcWeight = getIntOrFail(btcWeightKEY) | |
446 | 466 | let ethWeight = getIntOrFail(ethWeightKEY) | |
447 | 467 | let btcWeightNew = (btcWeight - weightDecrement) | |
448 | 468 | let ethWeightNew = (ethWeight - weightDecrement) | |
449 | 469 | if ((0 >= btcWeightNew)) | |
450 | 470 | then throw(("invalid btcWeightNew: " + toString(btcWeightNew))) | |
451 | 471 | else if ((0 >= ethWeightNew)) | |
452 | 472 | then throw(("invalid ethWeightNew: " + toString(ethWeightNew))) | |
453 | 473 | else { | |
454 | 474 | let btcLpAssetIdStr = getStringOrFail(keyMappingPoolContracToLPAsset(btcPoolAddress)) | |
455 | 475 | let ethLpAssetIdStr = getStringOrFail(keyMappingPoolContracToLPAsset(ethPoolAddress)) | |
456 | 476 | let ethBtcLpAssetIdStr = getStringOrFail(keyMappingPoolContracToLPAsset(ethBtcPoolAddress)) | |
457 | 477 | let usdcUsdtLpAssetIdStr = getStringOrFail(keyMappingPoolContracToLPAsset(usdcUsdtPoolAddress)) | |
458 | 478 | let onModifyWeightBtc = invoke(stakingDapp, "onModifyWeight", [btcLpAssetIdStr, btcPoolAddress], nil) | |
459 | 479 | if ((onModifyWeightBtc == onModifyWeightBtc)) | |
460 | 480 | then { | |
461 | 481 | let onModifyWeightEth = invoke(stakingDapp, "onModifyWeight", [ethLpAssetIdStr, ethPoolAddress], nil) | |
462 | 482 | if ((onModifyWeightEth == onModifyWeightEth)) | |
463 | 483 | then { | |
464 | 484 | let onModifyWeightEthBtc = invoke(stakingDapp, "onModifyWeight", [ethBtcLpAssetIdStr, ethBtcPoolAddress], nil) | |
465 | 485 | if ((onModifyWeightEthBtc == onModifyWeightEthBtc)) | |
466 | 486 | then { | |
467 | 487 | let onModifyWeightUsdcUsdt = invoke(stakingDapp, "onModifyWeight", [usdcUsdtLpAssetIdStr, usdcUsdtPoolAddress], nil) | |
468 | 488 | if ((onModifyWeightUsdcUsdt == onModifyWeightUsdcUsdt)) | |
469 | 489 | then [IntegerEntry(btcWeightKEY, btcWeightNew), IntegerEntry(ethWeightKEY, ethWeightNew), IntegerEntry(ethBtcWeightKEY, ethBtcWeightNew), IntegerEntry(usdcUsdtWeightKEY, usdcUsdtWeightNew), IntegerEntry(keyPoolToWeightHistory(btcPoolAddress, 0), btcWeight), IntegerEntry(keyPoolToWeightHistory(ethPoolAddress, 0), ethWeight), IntegerEntry(keyPoolToWeightHistory(ethBtcPoolAddress, 0), ethBtcWeightNew), IntegerEntry(keyPoolToWeightHistory(usdcUsdtPoolAddress, 0), usdcUsdtWeightNew)] | |
470 | 490 | else throw("Strict value is not equal to itself.") | |
471 | 491 | } | |
472 | 492 | else throw("Strict value is not equal to itself.") | |
473 | 493 | } | |
474 | 494 | else throw("Strict value is not equal to itself.") | |
475 | 495 | } | |
476 | 496 | else throw("Strict value is not equal to itself.") | |
477 | 497 | } | |
478 | 498 | } | |
479 | 499 | else throw("Strict value is not equal to itself.") | |
480 | 500 | } | |
481 | 501 | ||
482 | 502 | ||
483 | 503 | @Verifier(tx) | |
484 | 504 | func verify () = { | |
485 | 505 | let targetPublicKey = match managerPublicKeyOrUnit() { | |
486 | 506 | case pk: ByteVector => | |
487 | 507 | pk | |
488 | 508 | case _: Unit => | |
489 | 509 | tx.senderPublicKey | |
490 | 510 | case _ => | |
491 | 511 | throw("Match error") | |
492 | 512 | } | |
493 | 513 | sigVerify(tx.bodyBytes, tx.proofs[0], targetPublicKey) | |
494 | 514 | } | |
495 | 515 |
github/deemru/w8io/169f3d6 99.98 ms ◑