tx · 6orvAq5eLYtuVEJ5TZqEwGvGWcWmxEw5cJYcY64tgthf 3N1yLGKxTbjWG76Wfcu3g1mKFy1KwN797Us: -0.03700000 Waves 2022.09.08 14:38 [2220077] smart account 3N1yLGKxTbjWG76Wfcu3g1mKFy1KwN797Us > SELF 0.00000000 Waves
{ "type": 13, "id": "6orvAq5eLYtuVEJ5TZqEwGvGWcWmxEw5cJYcY64tgthf", "fee": 3700000, "feeAssetId": null, "timestamp": 1662637118540, "version": 2, "chainId": 84, "sender": "3N1yLGKxTbjWG76Wfcu3g1mKFy1KwN797Us", "senderPublicKey": "Fde5uhpJbFyNR686oXgTi64Bk9LBabxZiNKCncCk6vKz", "proofs": [ "2gHnZYRJtEye11UekASPVhRaEpyRTJhCLpoSaYxuwoewiC4bi9SZk8kRYKUrTuHv8uv8S5XekXqVeTXYDohSzsaJ", "4Q7U4fudNgGD8bHeGCHGAfy6gmnihphvbQTLQtZgXg68cFGV6nHiCc8KQD9qsk84iUfRHbHqdZjFczApUaJ7n6xH" ], "script": "base64:BgJjCAISBAoCEQESBgoECAEBBBIECgIBBBIDCgEBEgYKBAgIAQgSBAoCCAESAwoBERIECgIRARIFCgMBCAgSBAoCCAESBQoDCAEBEgASABIECgIRBBIECgIBARIAEgASABIDCgEBXQAJUFJFQ0lTSU9OAMCEPQAFTUFYX0EAwIQ9AAxNQVhfQV9DSEFOR0UACgAIREVDSU1BTFMABgANTUlOX1JBTVBfVElNRQkAaQIAgKMFADwAB3ZlcnNpb24CBTMuMC4wAAhrVmVyc2lvbgIHdmVyc2lvbgAHa0Fzc2V0cwIJYXNzZXRfaWRzAA1rQXNzZXRCYWxhbmNlAghfYmFsYW5jZQAHa0FjdGl2ZQIGYWN0aXZlAAZrQ2F1c2UCDnNodXRkb3duX2NhdXNlAA1rU2hhcmVBc3NldElkAg5zaGFyZV9hc3NldF9pZAARa1NoYXJlQXNzZXRTdXBwbHkCEnNoYXJlX2Fzc2V0X3N1cHBseQAEa0ZlZQIKY29t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ity": 0 } View: original | compacted Prev: 2Em19eDMHEmTLhecUMcwgcc3sbPRTQbcWUCS7nNm949P Next: 2qx92co4SR1AudRP8jjYiG4t3DftPsgsLCwded8nqLzr Diff:
Old | New | Differences | |
---|---|---|---|
95 | 95 | ||
96 | 96 | let farmingAddress = Address(getBase58FromOracle(kFarmingAddress)) | |
97 | 97 | ||
98 | - | let capMoneyBoxAddress = Address(base58' | |
98 | + | let capMoneyBoxAddress = Address(base58'3NBBWfzZtZtszaXbitTKnrB2xXwv26Bn7H9') | |
99 | 99 | ||
100 | 100 | let USDN = base58'8UrfDVd5GreeUwm7uPk7eYz1eMv376kzR52C6sANPkwS' | |
101 | 101 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let PRECISION = 1000000 | |
5 | 5 | ||
6 | 6 | let MAX_A = 1000000 | |
7 | 7 | ||
8 | 8 | let MAX_A_CHANGE = 10 | |
9 | 9 | ||
10 | 10 | let DECIMALS = 6 | |
11 | 11 | ||
12 | 12 | let MIN_RAMP_TIME = (86400 / 60) | |
13 | 13 | ||
14 | 14 | let version = "3.0.0" | |
15 | 15 | ||
16 | 16 | let kVersion = "version" | |
17 | 17 | ||
18 | 18 | let kAssets = "asset_ids" | |
19 | 19 | ||
20 | 20 | let kAssetBalance = "_balance" | |
21 | 21 | ||
22 | 22 | let kActive = "active" | |
23 | 23 | ||
24 | 24 | let kCause = "shutdown_cause" | |
25 | 25 | ||
26 | 26 | let kShareAssetId = "share_asset_id" | |
27 | 27 | ||
28 | 28 | let kShareAssetSupply = "share_asset_supply" | |
29 | 29 | ||
30 | 30 | let kFee = "commission" | |
31 | 31 | ||
32 | 32 | let kDAppThresholdCoef = "dAppThresholdCoef" | |
33 | 33 | ||
34 | 34 | let kUSDNAddress = "staking_usdnnsbt_address" | |
35 | 35 | ||
36 | 36 | let kDiscounts = "discounts" | |
37 | 37 | ||
38 | 38 | let kDiscountValues = "discount_values" | |
39 | 39 | ||
40 | 40 | let kUserSwopInGov = "_SWOP_amount" | |
41 | 41 | ||
42 | 42 | let kFirstHarvest = "first_harvest" | |
43 | 43 | ||
44 | 44 | let kFirstHarvestHeight = "first_harvest_height" | |
45 | 45 | ||
46 | 46 | let kShareLimit = "share_limit_on_first_harvest" | |
47 | 47 | ||
48 | 48 | let kBasePeriod = "base_period" | |
49 | 49 | ||
50 | 50 | let kPeriodLength = "period_length" | |
51 | 51 | ||
52 | 52 | let kStartHeight = "start_height" | |
53 | 53 | ||
54 | 54 | let kAdminPubKey1 = "admin_pub_1" | |
55 | 55 | ||
56 | 56 | let kAdminPubKey2 = "admin_pub_2" | |
57 | 57 | ||
58 | 58 | let kAdminPubKey3 = "admin_pub_3" | |
59 | 59 | ||
60 | 60 | let kAdminInvokePubKey = "admin_invoke_pub" | |
61 | 61 | ||
62 | 62 | let kMoneyBoxAddress = "money_box_address" | |
63 | 63 | ||
64 | 64 | let kGovAddress = "governance_address" | |
65 | 65 | ||
66 | 66 | let kVotingAddress = "voting_address" | |
67 | 67 | ||
68 | 68 | let kFarmingAddress = "farming_address" | |
69 | 69 | ||
70 | 70 | let oracle = Address(base58'3NBBWfzZtZtszaXbitTKnrB2xXwv26Bn7H9') | |
71 | 71 | ||
72 | 72 | func getBase58FromOracle (key) = match getString(oracle, key) { | |
73 | 73 | case string: String => | |
74 | 74 | fromBase58String(string) | |
75 | 75 | case nothing => | |
76 | 76 | throw((key + "is empty")) | |
77 | 77 | } | |
78 | 78 | ||
79 | 79 | ||
80 | 80 | let adminPubKey1 = getBase58FromOracle(kAdminPubKey1) | |
81 | 81 | ||
82 | 82 | let adminPubKey2 = getBase58FromOracle(kAdminPubKey2) | |
83 | 83 | ||
84 | 84 | let adminPubKey3 = getBase58FromOracle(kAdminPubKey3) | |
85 | 85 | ||
86 | 86 | let adminPubKeyInvoke = getBase58FromOracle(kAdminInvokePubKey) | |
87 | 87 | ||
88 | 88 | let moneyBoxAddress = Address(getBase58FromOracle(kMoneyBoxAddress)) | |
89 | 89 | ||
90 | 90 | let govAddress = Address(getBase58FromOracle(kGovAddress)) | |
91 | 91 | ||
92 | 92 | let stakingUSDNAddress = Address(getBase58FromOracle(kUSDNAddress)) | |
93 | 93 | ||
94 | 94 | let votingAddress = Address(getBase58FromOracle(kVotingAddress)) | |
95 | 95 | ||
96 | 96 | let farmingAddress = Address(getBase58FromOracle(kFarmingAddress)) | |
97 | 97 | ||
98 | - | let capMoneyBoxAddress = Address(base58' | |
98 | + | let capMoneyBoxAddress = Address(base58'3NBBWfzZtZtszaXbitTKnrB2xXwv26Bn7H9') | |
99 | 99 | ||
100 | 100 | let USDN = base58'8UrfDVd5GreeUwm7uPk7eYz1eMv376kzR52C6sANPkwS' | |
101 | 101 | ||
102 | 102 | let stakingAssets = [toBase58String(USDN)] | |
103 | 103 | ||
104 | 104 | let basePeriod = valueOrErrorMessage(getInteger(votingAddress, kBasePeriod), "Empty kBasePeriod") | |
105 | 105 | ||
106 | 106 | let startHeight = valueOrErrorMessage(getInteger(votingAddress, kStartHeight), "Empty kStartHeight") | |
107 | 107 | ||
108 | 108 | let periodLength = valueOrErrorMessage(getInteger(votingAddress, kPeriodLength), "Empty kPeriodLength") | |
109 | 109 | ||
110 | 110 | let firstHarvestEndPeriod = ((basePeriod + ((height - startHeight) / periodLength)) + 3) | |
111 | 111 | ||
112 | 112 | let active = getBooleanValue(this, kActive) | |
113 | 113 | ||
114 | 114 | let shareAssetId = fromBase58String(getStringValue(this, kShareAssetId)) | |
115 | 115 | ||
116 | 116 | let shareSupply = getIntegerValue(this, kShareAssetSupply) | |
117 | 117 | ||
118 | 118 | let feeScale6 = 1000000 | |
119 | 119 | ||
120 | 120 | let fee = getIntegerValue(this, kFee) | |
121 | 121 | ||
122 | 122 | let feeGovernance = fraction(40, feeScale6, 100) | |
123 | 123 | ||
124 | 124 | let initial_A = getIntegerValue(this, "initial_A") | |
125 | 125 | ||
126 | 126 | let future_A = getIntegerValue(this, "future_A") | |
127 | 127 | ||
128 | 128 | let initial_A_time = valueOrElse(getInteger(this, "initial_A_time"), 0) | |
129 | 129 | ||
130 | 130 | let future_A_time = valueOrElse(getInteger(this, "future_A_time"), 0) | |
131 | 131 | ||
132 | 132 | let assetIds = split(getStringValue(this, kAssets), ",") | |
133 | 133 | ||
134 | 134 | let nCoins = size(assetIds) | |
135 | 135 | ||
136 | 136 | func suspend (cause) = [BooleanEntry(kActive, false), StringEntry(kCause, cause)] | |
137 | 137 | ||
138 | 138 | ||
139 | 139 | func throwIsActive () = throw("DApp is already active") | |
140 | 140 | ||
141 | 141 | ||
142 | 142 | func isActive () = if (active) | |
143 | 143 | then unit | |
144 | 144 | else throw("DApp is inactive at this moment") | |
145 | 145 | ||
146 | 146 | ||
147 | 147 | func isAdminCall (i) = if (containsElement([adminPubKey1, adminPubKey2, adminPubKey3], i.callerPublicKey)) | |
148 | 148 | then unit | |
149 | 149 | else throw("Only admin can call this function") | |
150 | 150 | ||
151 | 151 | ||
152 | 152 | func isSelfCall (i) = if ((this == i.caller)) | |
153 | 153 | then unit | |
154 | 154 | else throw("Only contract itself can call this function") | |
155 | 155 | ||
156 | 156 | ||
157 | 157 | let big2 = toBigInt(2) | |
158 | 158 | ||
159 | 159 | let blockTimestamp = height | |
160 | 160 | ||
161 | 161 | func assert (a) = if (a) | |
162 | 162 | then false | |
163 | 163 | else true | |
164 | 164 | ||
165 | 165 | ||
166 | 166 | func calculateFeeDiscount (userAddr) = { | |
167 | 167 | let swopAmount = valueOrElse(getInteger(govAddress, (toString(userAddr) + kUserSwopInGov)), 0) | |
168 | 168 | let discountValues = split(getStringValue(oracle, kDiscountValues), ",") | |
169 | 169 | let discounts = split(getStringValue(oracle, kDiscounts), ",") | |
170 | 170 | if (if ((swopAmount >= parseIntValue(discountValues[0]))) | |
171 | 171 | then (parseIntValue(discountValues[1]) > swopAmount) | |
172 | 172 | else false) | |
173 | 173 | then (feeScale6 - parseIntValue(discounts[0])) | |
174 | 174 | else if (if ((swopAmount >= parseIntValue(discountValues[1]))) | |
175 | 175 | then (parseIntValue(discountValues[2]) > swopAmount) | |
176 | 176 | else false) | |
177 | 177 | then (feeScale6 - parseIntValue(discounts[1])) | |
178 | 178 | else if (if ((swopAmount >= parseIntValue(discountValues[2]))) | |
179 | 179 | then (parseIntValue(discountValues[3]) > swopAmount) | |
180 | 180 | else false) | |
181 | 181 | then (feeScale6 - parseIntValue(discounts[2])) | |
182 | 182 | else if (if ((swopAmount >= parseIntValue(discountValues[3]))) | |
183 | 183 | then (parseIntValue(discountValues[4]) > swopAmount) | |
184 | 184 | else false) | |
185 | 185 | then (feeScale6 - parseIntValue(discounts[3])) | |
186 | 186 | else if ((swopAmount >= parseIntValue(discountValues[4]))) | |
187 | 187 | then (feeScale6 - parseIntValue(discounts[4])) | |
188 | 188 | else feeScale6 | |
189 | 189 | } | |
190 | 190 | ||
191 | 191 | ||
192 | 192 | func _A () = { | |
193 | 193 | let t1 = future_A_time | |
194 | 194 | let A1 = future_A | |
195 | 195 | if ((t1 > blockTimestamp)) | |
196 | 196 | then { | |
197 | 197 | let A0 = initial_A | |
198 | 198 | let t0 = initial_A_time | |
199 | 199 | if ((A1 > A0)) | |
200 | 200 | then (A0 + (((A1 - A0) * (blockTimestamp - t0)) / (t1 - t0))) | |
201 | 201 | else (A0 - (((A0 - A1) * (blockTimestamp - t0)) / (t1 - t0))) | |
202 | 202 | } | |
203 | 203 | else A1 | |
204 | 204 | } | |
205 | 205 | ||
206 | 206 | ||
207 | 207 | func _xp () = { | |
208 | 208 | func assetBalances (acc,assetId) = (acc :+ valueOrElse(getInteger(this, (assetId + kAssetBalance)), 0)) | |
209 | 209 | ||
210 | 210 | let $l = assetIds | |
211 | 211 | let $s = size($l) | |
212 | 212 | let $acc0 = nil | |
213 | 213 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
214 | 214 | then $a | |
215 | 215 | else assetBalances($a, $l[$i]) | |
216 | 216 | ||
217 | 217 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
218 | 218 | then $a | |
219 | 219 | else throw("List size exceeds 15") | |
220 | 220 | ||
221 | 221 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15) | |
222 | 222 | } | |
223 | 223 | ||
224 | 224 | ||
225 | 225 | func _xp_mem (xp) = xp | |
226 | 226 | ||
227 | 227 | ||
228 | 228 | func sumList (acc,element) = (acc + element) | |
229 | 229 | ||
230 | 230 | ||
231 | 231 | func get_D (xp,amp) = { | |
232 | 232 | let @ = invoke(this, "D", [xp, amp], nil) | |
233 | 233 | if ($isInstanceOf(@, "Int")) | |
234 | 234 | then @ | |
235 | 235 | else throw(($getType(invoke(this, "D", [xp, amp], nil)) + " couldn't be cast to Int")) | |
236 | 236 | } | |
237 | 237 | ||
238 | 238 | ||
239 | 239 | func get_D_internal (xp,amp) = { | |
240 | 240 | let S = { | |
241 | 241 | let $l = xp | |
242 | 242 | let $s = size($l) | |
243 | 243 | let $acc0 = 0 | |
244 | 244 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
245 | 245 | then $a | |
246 | 246 | else sumList($a, $l[$i]) | |
247 | 247 | ||
248 | 248 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
249 | 249 | then $a | |
250 | 250 | else throw("List size exceeds 15") | |
251 | 251 | ||
252 | 252 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15) | |
253 | 253 | } | |
254 | 254 | if ((S == 0)) | |
255 | 255 | then 0 | |
256 | 256 | else { | |
257 | 257 | let Ann = (amp * nCoins) | |
258 | 258 | let AnnS = (toBigInt(Ann) * toBigInt(S)) | |
259 | 259 | let Ann1 = toBigInt((Ann - 1)) | |
260 | 260 | func Dproc (acc,i) = if ((acc._2 == true)) | |
261 | 261 | then acc | |
262 | 262 | else { | |
263 | 263 | let Dprev = acc._1 | |
264 | 264 | func D_PProc (D_P,i) = if ((nCoins > i)) | |
265 | 265 | then ((D_P * Dprev) / (toBigInt(xp[i]) * toBigInt(nCoins))) | |
266 | 266 | else D_P | |
267 | 267 | ||
268 | 268 | let D_P = { | |
269 | 269 | let $l = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14] | |
270 | 270 | let $s = size($l) | |
271 | 271 | let $acc0 = Dprev | |
272 | 272 | func $f1_1 ($a,$i) = if (($i >= $s)) | |
273 | 273 | then $a | |
274 | 274 | else D_PProc($a, $l[$i]) | |
275 | 275 | ||
276 | 276 | func $f1_2 ($a,$i) = if (($i >= $s)) | |
277 | 277 | then $a | |
278 | 278 | else throw("List size exceeds 15") | |
279 | 279 | ||
280 | 280 | $f1_2($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15) | |
281 | 281 | } | |
282 | 282 | let D = fraction((AnnS + (toBigInt(nCoins) * D_P)), Dprev, ((Ann1 * Dprev) + (toBigInt((nCoins + 1)) * D_P))) | |
283 | 283 | if ((D > Dprev)) | |
284 | 284 | then if ((1 >= toInt((D - Dprev)))) | |
285 | 285 | then $Tuple2(D, true) | |
286 | 286 | else $Tuple2(D, false) | |
287 | 287 | else if ((1 >= toInt((Dprev - D)))) | |
288 | 288 | then $Tuple2(D, true) | |
289 | 289 | else $Tuple2(D, false) | |
290 | 290 | } | |
291 | 291 | ||
292 | 292 | let $t066756787 = { | |
293 | 293 | let $l = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14] | |
294 | 294 | let $s = size($l) | |
295 | 295 | let $acc0 = $Tuple2(toBigInt(S), false) | |
296 | 296 | func $f1_1 ($a,$i) = if (($i >= $s)) | |
297 | 297 | then $a | |
298 | 298 | else Dproc($a, $l[$i]) | |
299 | 299 | ||
300 | 300 | func $f1_2 ($a,$i) = if (($i >= $s)) | |
301 | 301 | then $a | |
302 | 302 | else throw("List size exceeds 15") | |
303 | 303 | ||
304 | 304 | $f1_2($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15) | |
305 | 305 | } | |
306 | 306 | let D = $t066756787._1 | |
307 | 307 | let finished = $t066756787._2 | |
308 | 308 | if ((finished == false)) | |
309 | 309 | then throw(("get_D() not finished with " + toString(D))) | |
310 | 310 | else toInt(D) | |
311 | 311 | } | |
312 | 312 | } | |
313 | 313 | ||
314 | 314 | ||
315 | 315 | func getDMem (xp,amp) = get_D(_xp_mem(xp), amp) | |
316 | 316 | ||
317 | 317 | ||
318 | 318 | func getY (in,out,x,xp_) = if (assert((in != out))) | |
319 | 319 | then throw("same coin") | |
320 | 320 | else if (assert(if ((out >= 0)) | |
321 | 321 | then (in >= 0) | |
322 | 322 | else false)) | |
323 | 323 | then throw("below zero") | |
324 | 324 | else if (assert(if ((nCoins > out)) | |
325 | 325 | then (nCoins > in) | |
326 | 326 | else false)) | |
327 | 327 | then throw("above N_COINS") | |
328 | 328 | else { | |
329 | 329 | let amp = _A() | |
330 | 330 | let D = get_D(xp_, amp) | |
331 | 331 | let Ann = (amp * nCoins) | |
332 | 332 | func S_c (acc,i) = { | |
333 | 333 | let $t073587375 = acc | |
334 | 334 | let S_ = $t073587375._1 | |
335 | 335 | let c = $t073587375._2 | |
336 | 336 | let x_ = if ((in == i)) | |
337 | 337 | then x | |
338 | 338 | else xp_[i] | |
339 | 339 | if (if ((i != out)) | |
340 | 340 | then (nCoins > i) | |
341 | 341 | else false) | |
342 | 342 | then $Tuple2((S_ + x_), fraction(c, toBigInt(D), toBigInt((x_ * nCoins)))) | |
343 | 343 | else $Tuple2(S_, c) | |
344 | 344 | } | |
345 | 345 | ||
346 | 346 | let $t075837684 = { | |
347 | 347 | let $l = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14] | |
348 | 348 | let $s = size($l) | |
349 | 349 | let $acc0 = $Tuple2(0, toBigInt(D)) | |
350 | 350 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
351 | 351 | then $a | |
352 | 352 | else S_c($a, $l[$i]) | |
353 | 353 | ||
354 | 354 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
355 | 355 | then $a | |
356 | 356 | else throw("List size exceeds 15") | |
357 | 357 | ||
358 | 358 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15) | |
359 | 359 | } | |
360 | 360 | let S_ = $t075837684._1 | |
361 | 361 | let c_ = $t075837684._2 | |
362 | 362 | let c = fraction(c_, toBigInt(D), toBigInt((Ann * nCoins))) | |
363 | 363 | let bD = toBigInt(((S_ + (D / Ann)) - D)) | |
364 | 364 | func y_proc (acc,_i) = if ((acc._2 == true)) | |
365 | 365 | then acc | |
366 | 366 | else { | |
367 | 367 | let y_prev = acc._1 | |
368 | 368 | let y = (((y_prev * y_prev) + c) / ((big2 * y_prev) + bD)) | |
369 | 369 | if ((y > y_prev)) | |
370 | 370 | then if ((1 >= toInt((y - y_prev)))) | |
371 | 371 | then $Tuple2(y, true) | |
372 | 372 | else $Tuple2(y, false) | |
373 | 373 | else if ((1 >= toInt((y_prev - y)))) | |
374 | 374 | then $Tuple2(y, true) | |
375 | 375 | else $Tuple2(y, false) | |
376 | 376 | } | |
377 | 377 | ||
378 | 378 | let $t081668283 = { | |
379 | 379 | let $l = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15] | |
380 | 380 | let $s = size($l) | |
381 | 381 | let $acc0 = $Tuple2(toBigInt(D), false) | |
382 | 382 | func $f1_1 ($a,$i) = if (($i >= $s)) | |
383 | 383 | then $a | |
384 | 384 | else y_proc($a, $l[$i]) | |
385 | 385 | ||
386 | 386 | func $f1_2 ($a,$i) = if (($i >= $s)) | |
387 | 387 | then $a | |
388 | 388 | else throw("List size exceeds 16") | |
389 | 389 | ||
390 | 390 | $f1_2($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16) | |
391 | 391 | } | |
392 | 392 | let y = $t081668283._1 | |
393 | 393 | let finished = $t081668283._2 | |
394 | 394 | if ((finished == false)) | |
395 | 395 | then throw(("getY() not finished with " + toString(y))) | |
396 | 396 | else toInt(y) | |
397 | 397 | } | |
398 | 398 | ||
399 | 399 | ||
400 | 400 | func get_y_D (A_,in,xp,D) = if (assert((in >= 0))) | |
401 | 401 | then throw("i below zero") | |
402 | 402 | else if (assert((nCoins > in))) | |
403 | 403 | then throw("i above N_COINS") | |
404 | 404 | else { | |
405 | 405 | let Ann = (A_ * nCoins) | |
406 | 406 | func S_c (acc,i) = { | |
407 | 407 | let $t086628679 = acc | |
408 | 408 | let S_ = $t086628679._1 | |
409 | 409 | let c = $t086628679._2 | |
410 | 410 | let x_ = if (if ((in != i)) | |
411 | 411 | then (nCoins > i) | |
412 | 412 | else false) | |
413 | 413 | then xp[i] | |
414 | 414 | else 0 | |
415 | 415 | if (if ((nCoins > i)) | |
416 | 416 | then (in != i) | |
417 | 417 | else false) | |
418 | 418 | then $Tuple2((S_ + x_), fraction(c, toBigInt(D), toBigInt((x_ * nCoins)))) | |
419 | 419 | else $Tuple2(S_, c) | |
420 | 420 | } | |
421 | 421 | ||
422 | 422 | let $t088999000 = { | |
423 | 423 | let $l = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14] | |
424 | 424 | let $s = size($l) | |
425 | 425 | let $acc0 = $Tuple2(0, toBigInt(D)) | |
426 | 426 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
427 | 427 | then $a | |
428 | 428 | else S_c($a, $l[$i]) | |
429 | 429 | ||
430 | 430 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
431 | 431 | then $a | |
432 | 432 | else throw("List size exceeds 15") | |
433 | 433 | ||
434 | 434 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15) | |
435 | 435 | } | |
436 | 436 | let S_ = $t088999000._1 | |
437 | 437 | let c_ = $t088999000._2 | |
438 | 438 | let c = fraction(c_, toBigInt(D), toBigInt((Ann * nCoins))) | |
439 | 439 | let bD = toBigInt(((S_ + (D / Ann)) - D)) | |
440 | 440 | func y_D_proc (acc,i) = if ((acc._2 == true)) | |
441 | 441 | then acc | |
442 | 442 | else { | |
443 | 443 | let y_prev = acc._1 | |
444 | 444 | let y = (((y_prev * y_prev) + c) / ((big2 * y_prev) + bD)) | |
445 | 445 | if ((y > y_prev)) | |
446 | 446 | then if ((1 >= toInt((y - y_prev)))) | |
447 | 447 | then $Tuple2(y, true) | |
448 | 448 | else $Tuple2(y, false) | |
449 | 449 | else if ((1 >= toInt((y_prev - y)))) | |
450 | 450 | then $Tuple2(y, true) | |
451 | 451 | else $Tuple2(y, false) | |
452 | 452 | } | |
453 | 453 | ||
454 | 454 | let $t094839602 = { | |
455 | 455 | let $l = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15] | |
456 | 456 | let $s = size($l) | |
457 | 457 | let $acc0 = $Tuple2(toBigInt(D), false) | |
458 | 458 | func $f1_1 ($a,$i) = if (($i >= $s)) | |
459 | 459 | then $a | |
460 | 460 | else y_D_proc($a, $l[$i]) | |
461 | 461 | ||
462 | 462 | func $f1_2 ($a,$i) = if (($i >= $s)) | |
463 | 463 | then $a | |
464 | 464 | else throw("List size exceeds 16") | |
465 | 465 | ||
466 | 466 | $f1_2($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16) | |
467 | 467 | } | |
468 | 468 | let y = $t094839602._1 | |
469 | 469 | let finished = $t094839602._2 | |
470 | 470 | if ((finished == false)) | |
471 | 471 | then throw(("get_y_D() not finished with " + toString(y))) | |
472 | 472 | else toInt(y) | |
473 | 473 | } | |
474 | 474 | ||
475 | 475 | ||
476 | 476 | func _calcWithdrawOneCoin (xp,_token_amount,i,caller) = { | |
477 | 477 | let feeDiscount = calculateFeeDiscount(caller) | |
478 | 478 | let amp = _A() | |
479 | 479 | let _fee = ((fraction(fee, feeDiscount, feeScale6, CEILING) * nCoins) / (4 * (nCoins - 1))) | |
480 | 480 | let total_supply = shareSupply | |
481 | 481 | let D0 = get_D(xp, amp) | |
482 | 482 | let D1 = (D0 - fraction(_token_amount, D0, total_supply)) | |
483 | 483 | let new_y = get_y_D(amp, i, xp, D1) | |
484 | 484 | let dy_0 = (xp[i] - new_y) | |
485 | 485 | func xp_reduced_proc (acc,xp_j) = { | |
486 | 486 | let $t01024310272 = acc | |
487 | 487 | let xp_reduced = $t01024310272._1 | |
488 | 488 | let index = $t01024310272._2 | |
489 | 489 | let dx_expected = if ((index == i)) | |
490 | 490 | then (fraction(xp_j, D1, D0) - new_y) | |
491 | 491 | else (xp_j - fraction(xp_j, D1, D0)) | |
492 | 492 | $Tuple2((xp_reduced :+ (xp_j - fraction(_fee, dx_expected, feeScale6))), (index + 1)) | |
493 | 493 | } | |
494 | 494 | ||
495 | 495 | let $t01053410598 = { | |
496 | 496 | let $l = xp | |
497 | 497 | let $s = size($l) | |
498 | 498 | let $acc0 = $Tuple2(nil, 0) | |
499 | 499 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
500 | 500 | then $a | |
501 | 501 | else xp_reduced_proc($a, $l[$i]) | |
502 | 502 | ||
503 | 503 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
504 | 504 | then $a | |
505 | 505 | else throw("List size exceeds 15") | |
506 | 506 | ||
507 | 507 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15) | |
508 | 508 | } | |
509 | 509 | let xp_reduced = $t01053410598._1 | |
510 | 510 | let index = $t01053410598._2 | |
511 | 511 | let xp_reduced_i = xp_reduced[i] | |
512 | 512 | let dy = ((xp_reduced_i - get_y_D(amp, i, xp_reduced, D1)) - 1) | |
513 | 513 | $Tuple2(dy, (dy_0 - dy)) | |
514 | 514 | } | |
515 | 515 | ||
516 | 516 | ||
517 | 517 | func getStrAssetId (assetId) = match assetId { | |
518 | 518 | case id: ByteVector => | |
519 | 519 | toBase58String(id) | |
520 | 520 | case waves: Unit => | |
521 | 521 | "WAVES" | |
522 | 522 | case _ => | |
523 | 523 | throw("Match error") | |
524 | 524 | } | |
525 | 525 | ||
526 | 526 | ||
527 | 527 | func calcStakingFuncAndAddres (stake,assetId) = if (stake) | |
528 | 528 | then $Tuple2("lockNeutrino", stakingUSDNAddress) | |
529 | 529 | else $Tuple2("unlockNeutrino", stakingUSDNAddress) | |
530 | 530 | ||
531 | 531 | ||
532 | 532 | func calcStakingParams (stake,amount,assetId) = if (stake) | |
533 | 533 | then { | |
534 | 534 | let $t01116211228 = calcStakingFuncAndAddres(stake, assetId) | |
535 | 535 | let call = $t01116211228._1 | |
536 | 536 | let stakingAddr = $t01116211228._2 | |
537 | 537 | $Tuple4(call, stakingAddr, nil, [AttachedPayment(assetId, amount)]) | |
538 | 538 | } | |
539 | 539 | else { | |
540 | 540 | let $t01131411380 = calcStakingFuncAndAddres(stake, assetId) | |
541 | 541 | let call = $t01131411380._1 | |
542 | 542 | let stakingAddr = $t01131411380._2 | |
543 | 543 | $Tuple4(call, stakingAddr, [amount, toBase58String(assetId)], nil) | |
544 | 544 | } | |
545 | 545 | ||
546 | 546 | ||
547 | 547 | func stake (amount,assetIdString) = if (containsElement(stakingAssets, assetIdString)) | |
548 | 548 | then { | |
549 | 549 | let $t01156711669 = calcStakingParams(true, amount, fromBase58String(assetIdString)) | |
550 | 550 | let call = $t01156711669._1 | |
551 | 551 | let addr = $t01156711669._2 | |
552 | 552 | let params = $t01156711669._3 | |
553 | 553 | let payments = $t01156711669._4 | |
554 | 554 | invoke(addr, call, params, payments) | |
555 | 555 | } | |
556 | 556 | else 0 | |
557 | 557 | ||
558 | 558 | ||
559 | 559 | func unstake (amount,assetIdString) = if (containsElement(stakingAssets, assetIdString)) | |
560 | 560 | then { | |
561 | 561 | let $t01185411957 = calcStakingParams(false, amount, fromBase58String(assetIdString)) | |
562 | 562 | let call = $t01185411957._1 | |
563 | 563 | let addr = $t01185411957._2 | |
564 | 564 | let params = $t01185411957._3 | |
565 | 565 | let payments = $t01185411957._4 | |
566 | 566 | invoke(addr, call, params, payments) | |
567 | 567 | } | |
568 | 568 | else 0 | |
569 | 569 | ||
570 | 570 | ||
571 | 571 | func stakedAmount (assetId) = { | |
572 | 572 | let stakedAmountCalculated = match assetId { | |
573 | 573 | case aId: ByteVector => | |
574 | 574 | if ((aId == USDN)) | |
575 | 575 | then getInteger(stakingUSDNAddress, ((("rpd_balance_" + toBase58String(aId)) + "_") + toString(this))) | |
576 | 576 | else 0 | |
577 | 577 | case _: Unit => | |
578 | 578 | 0 | |
579 | 579 | case _ => | |
580 | 580 | throw("Match error") | |
581 | 581 | } | |
582 | 582 | match stakedAmountCalculated { | |
583 | 583 | case i: Int => | |
584 | 584 | i | |
585 | 585 | case _ => | |
586 | 586 | 0 | |
587 | 587 | } | |
588 | 588 | } | |
589 | 589 | ||
590 | 590 | ||
591 | 591 | func checkSuspicious () = { | |
592 | 592 | let contractBalances = _xp() | |
593 | 593 | func checkBalance (acc,assetId) = { | |
594 | 594 | let $t01256812593 = acc | |
595 | 595 | let suspicious = $t01256812593._1 | |
596 | 596 | let i = $t01256812593._2 | |
597 | 597 | if (suspicious) | |
598 | 598 | then $Tuple2(suspicious, i) | |
599 | 599 | else { | |
600 | 600 | let aBalance = (assetBalance(this, fromBase58String(assetId)) + stakedAmount(fromBase58String(assetId))) | |
601 | 601 | if ((contractBalances[i] > aBalance)) | |
602 | 602 | then $Tuple2(true, i) | |
603 | 603 | else $Tuple2(false, (i + 1)) | |
604 | 604 | } | |
605 | 605 | } | |
606 | 606 | ||
607 | 607 | let $l = assetIds | |
608 | 608 | let $s = size($l) | |
609 | 609 | let $acc0 = $Tuple2(false, 0) | |
610 | 610 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
611 | 611 | then $a | |
612 | 612 | else checkBalance($a, $l[$i]) | |
613 | 613 | ||
614 | 614 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
615 | 615 | then $a | |
616 | 616 | else throw("List size exceeds 15") | |
617 | 617 | ||
618 | 618 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15) | |
619 | 619 | } | |
620 | 620 | ||
621 | 621 | ||
622 | 622 | func suspendSuspicious (i) = suspend(("Suspicious state with asset: " + assetIds[i])) | |
623 | 623 | ||
624 | 624 | ||
625 | 625 | func returnPayments (caller,payments) = { | |
626 | 626 | func parsePayments (acc,payment) = (acc :+ ScriptTransfer(caller, payment.amount, payment.assetId)) | |
627 | 627 | ||
628 | 628 | let $l = payments | |
629 | 629 | let $s = size($l) | |
630 | 630 | let $acc0 = nil | |
631 | 631 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
632 | 632 | then $a | |
633 | 633 | else parsePayments($a, $l[$i]) | |
634 | 634 | ||
635 | 635 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
636 | 636 | then $a | |
637 | 637 | else throw("List size exceeds 15") | |
638 | 638 | ||
639 | 639 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15) | |
640 | 640 | } | |
641 | 641 | ||
642 | 642 | ||
643 | 643 | func checkDAppThreshold (newBalances) = { | |
644 | 644 | let dAppThresholdCoef = valueOrErrorMessage(getInteger(this, kDAppThresholdCoef), "No dAppThresholdCoef key") | |
645 | 645 | let thresholdScale = 10000 | |
646 | 646 | let maxBalance = max(newBalances) | |
647 | 647 | let minBalance = min(newBalances) | |
648 | 648 | let ratio = fraction(maxBalance, thresholdScale, minBalance) | |
649 | 649 | if ((ratio > (dAppThresholdCoef * thresholdScale))) | |
650 | 650 | then throw("New balance in assets of the DApp is less than threshold") | |
651 | 651 | else false | |
652 | 652 | } | |
653 | 653 | ||
654 | 654 | ||
655 | 655 | func checkCoins (assetIds) = { | |
656 | 656 | let coins = split(assetIds, ",") | |
657 | 657 | func checkCoin (error,assetId) = { | |
658 | 658 | let asset = valueOrErrorMessage(fromBase58String(assetId), ("fromBase58String: " + assetId)) | |
659 | 659 | let decimals = valueOrErrorMessage(assetInfo(asset), ("assetInfo: " + assetId)).decimals | |
660 | 660 | if ((decimals != DECIMALS)) | |
661 | 661 | then throw("wrong decimals") | |
662 | 662 | else false | |
663 | 663 | } | |
664 | 664 | ||
665 | 665 | let $l = coins | |
666 | 666 | let $s = size($l) | |
667 | 667 | let $acc0 = false | |
668 | 668 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
669 | 669 | then $a | |
670 | 670 | else checkCoin($a, $l[$i]) | |
671 | 671 | ||
672 | 672 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
673 | 673 | then $a | |
674 | 674 | else throw("List size exceeds 15") | |
675 | 675 | ||
676 | 676 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15) | |
677 | 677 | } | |
678 | 678 | ||
679 | 679 | ||
680 | 680 | @Callable(msg) | |
681 | 681 | func D (xp,amp) = { | |
682 | 682 | let D = get_D_internal(xp, amp) | |
683 | 683 | $Tuple2([IntegerEntry("D", D)], D) | |
684 | 684 | } | |
685 | 685 | ||
686 | 686 | ||
687 | 687 | ||
688 | 688 | @Callable(msg) | |
689 | 689 | func init (assetIds,_A,_dAppThresholdCoef,firstHarvest) = if (!(isDataStorageUntouched(this))) | |
690 | 690 | then throw("Already initialized") | |
691 | 691 | else if ((0 >= _A)) | |
692 | 692 | then throw("Amp must be must > 0") | |
693 | 693 | else if ((0 >= _dAppThresholdCoef)) | |
694 | 694 | then throw("dApp Threshold Coef must be > 0") | |
695 | 695 | else { | |
696 | 696 | let shareName = "s_Multi_USD" | |
697 | 697 | let shareDescription = ("ShareToken of SwopFi protocol for MultiStable USD pool at address " + toString(this)) | |
698 | 698 | let issueToken = Issue(shareName, shareDescription, 0, 6, true) | |
699 | 699 | let tokenId = calculateAssetId(issueToken) | |
700 | 700 | if (checkCoins(assetIds)) | |
701 | 701 | then throw() | |
702 | 702 | else { | |
703 | 703 | let baseEntry = [StringEntry(kVersion, version), StringEntry(kAssets, assetIds), IntegerEntry("initial_A", _A), IntegerEntry("future_A", _A), IntegerEntry(kFee, getIntegerValue(oracle, "base_fee_flat")), StringEntry(kShareAssetId, toBase58String(tokenId)), IntegerEntry(kShareAssetSupply, 0), IntegerEntry(kDAppThresholdCoef, _dAppThresholdCoef), BooleanEntry(kActive, true), issueToken] | |
704 | 704 | if (firstHarvest) | |
705 | 705 | then (baseEntry ++ [BooleanEntry(kFirstHarvest, firstHarvest), IntegerEntry(kFirstHarvestHeight, (startHeight + (firstHarvestEndPeriod * periodLength)))]) | |
706 | 706 | else baseEntry | |
707 | 707 | } | |
708 | 708 | } | |
709 | 709 | ||
710 | 710 | ||
711 | 711 | ||
712 | 712 | @Callable(msg) | |
713 | 713 | func addLiquidity (minMintAmount,stakeFarming) = valueOrElse(isActive(), { | |
714 | 714 | let amp = _A() | |
715 | 715 | let xp = _xp() | |
716 | 716 | let D0 = if ((shareSupply == 0)) | |
717 | 717 | then 0 | |
718 | 718 | else getDMem(xp, amp) | |
719 | 719 | let payments = msg.payments | |
720 | 720 | let paymentsSize = size(payments) | |
721 | 721 | func validPayments (n) = if ((paymentsSize > nCoins)) | |
722 | 722 | then throw(("payments size > " + toString(nCoins))) | |
723 | 723 | else if ((1 > paymentsSize)) | |
724 | 724 | then throw("payments size < 1") | |
725 | 725 | else if (if ((shareSupply == 0)) | |
726 | 726 | then (nCoins != paymentsSize) | |
727 | 727 | else false) | |
728 | 728 | then throw("initial deposit requires all coins") | |
729 | 729 | else { | |
730 | 730 | func paymantValid (acc,payment) = if (containsElement(assetIds, getStrAssetId(payment.assetId))) | |
731 | 731 | then true | |
732 | 732 | else throw("Invalid asset in payment") | |
733 | 733 | ||
734 | 734 | let $l = payments | |
735 | 735 | let $s = size($l) | |
736 | 736 | let $acc0 = false | |
737 | 737 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
738 | 738 | then $a | |
739 | 739 | else paymantValid($a, $l[$i]) | |
740 | 740 | ||
741 | 741 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
742 | 742 | then $a | |
743 | 743 | else throw("List size exceeds 15") | |
744 | 744 | ||
745 | 745 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15) | |
746 | 746 | } | |
747 | 747 | ||
748 | 748 | if (!(validPayments(paymentsSize))) | |
749 | 749 | then throw() | |
750 | 750 | else { | |
751 | 751 | let suspicious = checkSuspicious() | |
752 | 752 | if (suspicious._1) | |
753 | 753 | then (suspendSuspicious(suspicious._2) ++ returnPayments(msg.caller, payments)) | |
754 | 754 | else { | |
755 | 755 | func parsePayments (acc,assetId) = { | |
756 | 756 | let $t01690116930 = acc | |
757 | 757 | let newBalances = $t01690116930._1 | |
758 | 758 | let i = $t01690116930._2 | |
759 | 759 | let j = $t01690116930._3 | |
760 | 760 | if (if ((paymentsSize > j)) | |
761 | 761 | then (getStrAssetId(payments[j].assetId) == assetId) | |
762 | 762 | else false) | |
763 | 763 | then $Tuple3((newBalances :+ (xp[i] + payments[j].amount)), (i + 1), (j + 1)) | |
764 | 764 | else $Tuple3((newBalances :+ xp[i]), (i + 1), j) | |
765 | 765 | } | |
766 | 766 | ||
767 | 767 | let $t01715017236 = { | |
768 | 768 | let $l = assetIds | |
769 | 769 | let $s = size($l) | |
770 | 770 | let $acc0 = $Tuple3(nil, 0, 0) | |
771 | 771 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
772 | 772 | then $a | |
773 | 773 | else parsePayments($a, $l[$i]) | |
774 | 774 | ||
775 | 775 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
776 | 776 | then $a | |
777 | 777 | else throw("List size exceeds 15") | |
778 | 778 | ||
779 | 779 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15) | |
780 | 780 | } | |
781 | 781 | let newBalances = $t01715017236._1 | |
782 | 782 | let k = $t01715017236._2 | |
783 | 783 | let parsedPayments = $t01715017236._3 | |
784 | 784 | if ((paymentsSize > parsedPayments)) | |
785 | 785 | then throw("Incorect payments order") | |
786 | 786 | else if (checkDAppThreshold(newBalances)) | |
787 | 787 | then throw() | |
788 | 788 | else { | |
789 | 789 | let D1 = getDMem(newBalances, amp) | |
790 | 790 | if (assert((D1 > D0))) | |
791 | 791 | then throw("D1 > D0") | |
792 | 792 | else { | |
793 | 793 | let feeDiscount = calculateFeeDiscount(msg.caller) | |
794 | 794 | func calcScriptActions (acc,newBalance) = { | |
795 | 795 | let $t01763717678 = acc | |
796 | 796 | let invBalances = $t01763717678._1 | |
797 | 797 | let scriptActions = $t01763717678._2 | |
798 | 798 | let i = $t01763717678._3 | |
799 | 799 | if ((shareSupply > 0)) | |
800 | 800 | then { | |
801 | 801 | let _fee = ((fraction(fee, feeDiscount, feeScale6, CEILING) * nCoins) / (4 * (nCoins - 1))) | |
802 | 802 | let fees = { | |
803 | 803 | let idealBalance = fraction(D1, xp[i], D0) | |
804 | 804 | let difference = if ((idealBalance > newBalance)) | |
805 | 805 | then (idealBalance - newBalance) | |
806 | 806 | else (newBalance - idealBalance) | |
807 | 807 | fraction(_fee, difference, feeScale6) | |
808 | 808 | } | |
809 | 809 | let governanceFees = fraction(fees, feeGovernance, feeScale6) | |
810 | 810 | let finalBalance = (newBalance - fees) | |
811 | 811 | let invariantBalance = (newBalance - fees) | |
812 | 812 | let pmt = (newBalance - xp[i]) | |
813 | 813 | let inv = if ((pmt > 0)) | |
814 | 814 | then stake((pmt - fees), assetIds[i]) | |
815 | 815 | else unstake(fees, assetIds[i]) | |
816 | 816 | if ((inv == inv)) | |
817 | 817 | then $Tuple3((invBalances :+ invariantBalance), (scriptActions ++ [ScriptTransfer(capMoneyBoxAddress, (fees - governanceFees), fromBase58String(assetIds[i])), ScriptTransfer(moneyBoxAddress, governanceFees, fromBase58String(assetIds[i])), IntegerEntry((assetIds[i] + kAssetBalance), finalBalance)]), (i + 1)) | |
818 | 818 | else throw("Strict value is not equal to itself.") | |
819 | 819 | } | |
820 | 820 | else { | |
821 | 821 | let inv = stake(newBalance, assetIds[i]) | |
822 | 822 | if ((inv == inv)) | |
823 | 823 | then $Tuple3((invBalances :+ newBalance), (scriptActions :+ IntegerEntry((assetIds[i] + kAssetBalance), newBalance)), (i + 1)) | |
824 | 824 | else throw("Strict value is not equal to itself.") | |
825 | 825 | } | |
826 | 826 | } | |
827 | 827 | ||
828 | 828 | let $t01922619314 = { | |
829 | 829 | let $l = newBalances | |
830 | 830 | let $s = size($l) | |
831 | 831 | let $acc0 = $Tuple3(nil, nil, 0) | |
832 | 832 | func $f1_1 ($a,$i) = if (($i >= $s)) | |
833 | 833 | then $a | |
834 | 834 | else calcScriptActions($a, $l[$i]) | |
835 | 835 | ||
836 | 836 | func $f1_2 ($a,$i) = if (($i >= $s)) | |
837 | 837 | then $a | |
838 | 838 | else throw("List size exceeds 15") | |
839 | 839 | ||
840 | 840 | $f1_2($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15) | |
841 | 841 | } | |
842 | 842 | let invBalances = $t01922619314._1 | |
843 | 843 | let scriptActions = $t01922619314._2 | |
844 | 844 | let D2 = getDMem(invBalances, amp) | |
845 | 845 | let mint_amount = if ((shareSupply == 0)) | |
846 | 846 | then D1 | |
847 | 847 | else fraction(shareSupply, (D2 - D0), D0) | |
848 | 848 | if (assert((mint_amount >= minMintAmount))) | |
849 | 849 | then throw("Slippage screwed you") | |
850 | 850 | else if (stakeFarming) | |
851 | 851 | then { | |
852 | 852 | let re = invoke(this, "reissueShare", [mint_amount], nil) | |
853 | 853 | if ((re == re)) | |
854 | 854 | then { | |
855 | 855 | let s = invoke(farmingAddress, "lockShareTokens", [toString(this)], [AttachedPayment(shareAssetId, mint_amount)]) | |
856 | 856 | if ((s == s)) | |
857 | 857 | then (scriptActions :+ IntegerEntry(kShareAssetSupply, (shareSupply + mint_amount))) | |
858 | 858 | else throw("Strict value is not equal to itself.") | |
859 | 859 | } | |
860 | 860 | else throw("Strict value is not equal to itself.") | |
861 | 861 | } | |
862 | 862 | else (scriptActions ++ [Reissue(shareAssetId, mint_amount, true), ScriptTransfer(msg.caller, mint_amount, shareAssetId), IntegerEntry(kShareAssetSupply, (shareSupply + mint_amount))]) | |
863 | 863 | } | |
864 | 864 | } | |
865 | 865 | } | |
866 | 866 | } | |
867 | 867 | }) | |
868 | 868 | ||
869 | 869 | ||
870 | 870 | ||
871 | 871 | @Callable(msg) | |
872 | 872 | func reissueShare (amount) = valueOrElse(isSelfCall(msg), [Reissue(shareAssetId, amount, true)]) | |
873 | 873 | ||
874 | 874 | ||
875 | 875 | ||
876 | 876 | @Callable(msg) | |
877 | 877 | func getDy (assetFrom,assetTo,dx,userAddress) = { | |
878 | 878 | let xp = _xp() | |
879 | 879 | let fromIndex = valueOrErrorMessage(indexOf(assetIds, assetFrom), "unknown token in") | |
880 | 880 | let toIndex = valueOrErrorMessage(indexOf(assetIds, assetTo), "unknown token out") | |
881 | 881 | let x = (xp[fromIndex] + dx) | |
882 | 882 | let y = getY(fromIndex, toIndex, x, xp) | |
883 | 883 | let dy = ((xp[toIndex] - y) - 1) | |
884 | 884 | let feeDiscount = calculateFeeDiscount(Address(fromBase58String(userAddress))) | |
885 | 885 | let _fee = fraction(fraction(fee, feeDiscount, feeScale6, CEILING), dy, feeScale6) | |
886 | 886 | $Tuple2(nil, $Tuple2((dy - _fee), _fee)) | |
887 | 887 | } | |
888 | 888 | ||
889 | 889 | ||
890 | 890 | ||
891 | 891 | @Callable(msg) | |
892 | 892 | func exchange (tokenOut,min_dy) = valueOrElse(isActive(), if ((size(msg.payments) != 1)) | |
893 | 893 | then throw("size(payments) != 1") | |
894 | 894 | else { | |
895 | 895 | let suspicious = checkSuspicious() | |
896 | 896 | if (suspicious._1) | |
897 | 897 | then (suspendSuspicious(suspicious._2) ++ returnPayments(msg.caller, msg.payments)) | |
898 | 898 | else { | |
899 | 899 | let payment = msg.payments[0] | |
900 | 900 | let tokenIn = getStrAssetId(payment.assetId) | |
901 | 901 | let tokenOutB58 = fromBase58String(tokenOut) | |
902 | 902 | let dx = payment.amount | |
903 | 903 | let fromIndex = valueOrErrorMessage(indexOf(assetIds, tokenIn), "unknown token in") | |
904 | 904 | let toIndex = valueOrErrorMessage(indexOf(assetIds, tokenOut), "unknown token out") | |
905 | 905 | let xp = _xp() | |
906 | 906 | let x = (xp[fromIndex] + dx) | |
907 | 907 | let y = getY(fromIndex, toIndex, x, xp) | |
908 | 908 | let _dy = ((xp[toIndex] - y) - 1) | |
909 | 909 | let feeDiscount = calculateFeeDiscount(msg.caller) | |
910 | 910 | let _fee = fraction(_dy, fraction(fee, feeDiscount, feeScale6, CEILING), feeScale6) | |
911 | 911 | let dy = (_dy - _fee) | |
912 | 912 | let governanceFees = fraction(_fee, feeGovernance, feeScale6) | |
913 | 913 | if (assert((dy >= min_dy))) | |
914 | 914 | then throw("Exchange resulted in fewer coins than expected") | |
915 | 915 | else { | |
916 | 916 | func makeNewBalances (acc,tokenBalance) = { | |
917 | 917 | let $t02202622052 = acc | |
918 | 918 | let newBalances = $t02202622052._1 | |
919 | 919 | let i = $t02202622052._2 | |
920 | 920 | if ((i == fromIndex)) | |
921 | 921 | then $Tuple2((newBalances :+ (tokenBalance + dx)), (i + 1)) | |
922 | 922 | else if ((i == toIndex)) | |
923 | 923 | then $Tuple2((newBalances :+ (tokenBalance - _dy)), (i + 1)) | |
924 | 924 | else $Tuple2((newBalances :+ tokenBalance), (i + 1)) | |
925 | 925 | } | |
926 | 926 | ||
927 | 927 | let $t02230322364 = { | |
928 | 928 | let $l = xp | |
929 | 929 | let $s = size($l) | |
930 | 930 | let $acc0 = $Tuple2(nil, 0) | |
931 | 931 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
932 | 932 | then $a | |
933 | 933 | else makeNewBalances($a, $l[$i]) | |
934 | 934 | ||
935 | 935 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
936 | 936 | then $a | |
937 | 937 | else throw("List size exceeds 15") | |
938 | 938 | ||
939 | 939 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15) | |
940 | 940 | } | |
941 | 941 | let newBalances = $t02230322364._1 | |
942 | 942 | let i = $t02230322364._2 | |
943 | 943 | if (checkDAppThreshold(newBalances)) | |
944 | 944 | then throw() | |
945 | 945 | else { | |
946 | 946 | let s = stake(payment.amount, getStrAssetId(payment.assetId)) | |
947 | 947 | if ((s == s)) | |
948 | 948 | then { | |
949 | 949 | let us = unstake(_dy, tokenOut) | |
950 | 950 | if ((us == us)) | |
951 | 951 | then $Tuple2([IntegerEntry((tokenIn + kAssetBalance), x), IntegerEntry((tokenOut + kAssetBalance), (xp[toIndex] - _dy)), ScriptTransfer(msg.caller, dy, tokenOutB58), ScriptTransfer(moneyBoxAddress, governanceFees, tokenOutB58), ScriptTransfer(capMoneyBoxAddress, (_fee - governanceFees), tokenOutB58)], [dy, tokenOutB58]) | |
952 | 952 | else throw("Strict value is not equal to itself.") | |
953 | 953 | } | |
954 | 954 | else throw("Strict value is not equal to itself.") | |
955 | 955 | } | |
956 | 956 | } | |
957 | 957 | } | |
958 | 958 | }) | |
959 | 959 | ||
960 | 960 | ||
961 | 961 | ||
962 | 962 | @Callable(msg) | |
963 | 963 | func withdraw (minAmounts) = valueOrElse(isActive(), if ((size(msg.payments) != 1)) | |
964 | 964 | then throw("size(payments) != 1") | |
965 | 965 | else { | |
966 | 966 | let pmtAmount = msg.payments[0].amount | |
967 | 967 | let pmtAssetId = msg.payments[0].assetId | |
968 | 968 | if ((shareAssetId != pmtAssetId)) | |
969 | 969 | then throw("unknown payment token") | |
970 | 970 | else { | |
971 | 971 | let suspicious = checkSuspicious() | |
972 | 972 | if (suspicious._1) | |
973 | 973 | then (suspendSuspicious(suspicious._2) ++ returnPayments(msg.originCaller, msg.payments)) | |
974 | 974 | else { | |
975 | 975 | func calcScriptActions (acc,balance) = { | |
976 | 976 | let $t02350523533 = acc | |
977 | 977 | let scriptActions = $t02350523533._1 | |
978 | 978 | let i = $t02350523533._2 | |
979 | 979 | let wAmount = fraction(balance, pmtAmount, shareSupply) | |
980 | 980 | if (assert((wAmount >= minAmounts[i]))) | |
981 | 981 | then throw("Withdrawal resulted in fewer coins than expected") | |
982 | 982 | else { | |
983 | 983 | let us = unstake(wAmount, assetIds[i]) | |
984 | 984 | if ((us == us)) | |
985 | 985 | then $Tuple2((scriptActions ++ [IntegerEntry((assetIds[i] + kAssetBalance), (balance - wAmount)), ScriptTransfer(msg.originCaller, wAmount, fromBase58String(assetIds[i]))]), (i + 1)) | |
986 | 986 | else throw("Strict value is not equal to itself.") | |
987 | 987 | } | |
988 | 988 | } | |
989 | 989 | ||
990 | 990 | let $t02402324091 = { | |
991 | 991 | let $l = _xp() | |
992 | 992 | let $s = size($l) | |
993 | 993 | let $acc0 = $Tuple2(nil, 0) | |
994 | 994 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
995 | 995 | then $a | |
996 | 996 | else calcScriptActions($a, $l[$i]) | |
997 | 997 | ||
998 | 998 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
999 | 999 | then $a | |
1000 | 1000 | else throw("List size exceeds 15") | |
1001 | 1001 | ||
1002 | 1002 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15) | |
1003 | 1003 | } | |
1004 | 1004 | let scriptActions = $t02402324091._1 | |
1005 | 1005 | let i = $t02402324091._2 | |
1006 | 1006 | (scriptActions ++ [Burn(shareAssetId, pmtAmount), IntegerEntry(kShareAssetSupply, (shareSupply - pmtAmount))]) | |
1007 | 1007 | } | |
1008 | 1008 | } | |
1009 | 1009 | }) | |
1010 | 1010 | ||
1011 | 1011 | ||
1012 | 1012 | ||
1013 | 1013 | @Callable(msg) | |
1014 | 1014 | func withdrawWithUnlock (minAmounts,unlockAmount) = valueOrElse(isActive(), if ((0 >= unlockAmount)) | |
1015 | 1015 | then throw("Unlock amount must be positive") | |
1016 | 1016 | else { | |
1017 | 1017 | let suspicious = checkSuspicious() | |
1018 | 1018 | if (suspicious._1) | |
1019 | 1019 | then (suspendSuspicious(suspicious._2) ++ returnPayments(msg.caller, msg.payments)) | |
1020 | 1020 | else { | |
1021 | 1021 | let pmtAmount = if ((size(msg.payments) > 0)) | |
1022 | 1022 | then if ((size(msg.payments) != 1)) | |
1023 | 1023 | then throw("size(payments) != 1") | |
1024 | 1024 | else { | |
1025 | 1025 | let pmtAssetId = msg.payments[0].assetId | |
1026 | 1026 | if ((shareAssetId != pmtAssetId)) | |
1027 | 1027 | then throw("unknown payment token") | |
1028 | 1028 | else msg.payments[0].amount | |
1029 | 1029 | } | |
1030 | 1030 | else 0 | |
1031 | 1031 | let unlock = invoke(farmingAddress, "withdrawShareTokens", [toString(this), unlockAmount], nil) | |
1032 | 1032 | if ((unlock == unlock)) | |
1033 | 1033 | then { | |
1034 | 1034 | let withdrawAmount = (pmtAmount + unlockAmount) | |
1035 | 1035 | let inv = invoke(this, "withdraw", [minAmounts], [AttachedPayment(shareAssetId, withdrawAmount)]) | |
1036 | 1036 | if ((inv == inv)) | |
1037 | 1037 | then nil | |
1038 | 1038 | else throw("Strict value is not equal to itself.") | |
1039 | 1039 | } | |
1040 | 1040 | else throw("Strict value is not equal to itself.") | |
1041 | 1041 | } | |
1042 | 1042 | }) | |
1043 | 1043 | ||
1044 | 1044 | ||
1045 | 1045 | ||
1046 | 1046 | @Callable(msg) | |
1047 | 1047 | func calcWithdrawOneCoin (tokenAmount,tokenOut,user) = { | |
1048 | 1048 | let i = valueOrErrorMessage(indexOf(assetIds, tokenOut), "unknown token out") | |
1049 | 1049 | $Tuple2(nil, _calcWithdrawOneCoin(_xp(), tokenAmount, i, Address(fromBase58String(user)))._1) | |
1050 | 1050 | } | |
1051 | 1051 | ||
1052 | 1052 | ||
1053 | 1053 | ||
1054 | 1054 | @Callable(msg) | |
1055 | 1055 | func withdrawOneCoin (tokenOut,minAmount) = valueOrElse(isActive(), if ((size(msg.payments) != 1)) | |
1056 | 1056 | then throw("size(payments) != 1") | |
1057 | 1057 | else { | |
1058 | 1058 | let suspicious = checkSuspicious() | |
1059 | 1059 | if (suspicious._1) | |
1060 | 1060 | then (suspendSuspicious(suspicious._2) ++ returnPayments(msg.originCaller, msg.payments)) | |
1061 | 1061 | else { | |
1062 | 1062 | let pmtAmount = msg.payments[0].amount | |
1063 | 1063 | let pmtAssetId = msg.payments[0].assetId | |
1064 | 1064 | if ((pmtAssetId != shareAssetId)) | |
1065 | 1065 | then throw("unknown token") | |
1066 | 1066 | else { | |
1067 | 1067 | let outIndex = valueOrErrorMessage(indexOf(assetIds, tokenOut), "unknown token out") | |
1068 | 1068 | let xp = _xp() | |
1069 | 1069 | let $t02600526087 = _calcWithdrawOneCoin(xp, pmtAmount, outIndex, msg.originCaller) | |
1070 | 1070 | let dy = $t02600526087._1 | |
1071 | 1071 | let dy_fee = $t02600526087._2 | |
1072 | 1072 | if (assert((dy >= minAmount))) | |
1073 | 1073 | then throw("Not enough coins removed") | |
1074 | 1074 | else { | |
1075 | 1075 | let governanceFees = fraction(dy_fee, feeGovernance, feeScale6) | |
1076 | 1076 | let dy_and_fee = (dy + dy_fee) | |
1077 | 1077 | func makeNewBalances (acc,tokenBalance) = { | |
1078 | 1078 | let $t02634526371 = acc | |
1079 | 1079 | let newBalances = $t02634526371._1 | |
1080 | 1080 | let i = $t02634526371._2 | |
1081 | 1081 | if ((i == outIndex)) | |
1082 | 1082 | then $Tuple2((newBalances :+ (tokenBalance - dy_and_fee)), (i + 1)) | |
1083 | 1083 | else $Tuple2((newBalances :+ tokenBalance), (i + 1)) | |
1084 | 1084 | } | |
1085 | 1085 | ||
1086 | 1086 | let $t02653826599 = { | |
1087 | 1087 | let $l = xp | |
1088 | 1088 | let $s = size($l) | |
1089 | 1089 | let $acc0 = $Tuple2(nil, 0) | |
1090 | 1090 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
1091 | 1091 | then $a | |
1092 | 1092 | else makeNewBalances($a, $l[$i]) | |
1093 | 1093 | ||
1094 | 1094 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
1095 | 1095 | then $a | |
1096 | 1096 | else throw("List size exceeds 15") | |
1097 | 1097 | ||
1098 | 1098 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15) | |
1099 | 1099 | } | |
1100 | 1100 | let newBalances = $t02653826599._1 | |
1101 | 1101 | let v = $t02653826599._2 | |
1102 | 1102 | if (checkDAppThreshold(newBalances)) | |
1103 | 1103 | then throw() | |
1104 | 1104 | else { | |
1105 | 1105 | let us = unstake(dy_and_fee, tokenOut) | |
1106 | 1106 | if ((us == us)) | |
1107 | 1107 | then [ScriptTransfer(msg.originCaller, dy, fromBase58String(tokenOut)), IntegerEntry((assetIds[outIndex] + kAssetBalance), (xp[outIndex] - dy_and_fee)), Burn(shareAssetId, pmtAmount), ScriptTransfer(moneyBoxAddress, governanceFees, fromBase58String(tokenOut)), ScriptTransfer(capMoneyBoxAddress, (dy_fee - governanceFees), fromBase58String(tokenOut)), IntegerEntry(kShareAssetSupply, (shareSupply - pmtAmount))] | |
1108 | 1108 | else throw("Strict value is not equal to itself.") | |
1109 | 1109 | } | |
1110 | 1110 | } | |
1111 | 1111 | } | |
1112 | 1112 | } | |
1113 | 1113 | }) | |
1114 | 1114 | ||
1115 | 1115 | ||
1116 | 1116 | ||
1117 | 1117 | @Callable(msg) | |
1118 | 1118 | func withdrawOneCoinWithUnlock (tokenOut,minAmount,unlockAmount) = valueOrElse(isActive(), if ((0 >= unlockAmount)) | |
1119 | 1119 | then throw("Unlock amount must be positive") | |
1120 | 1120 | else { | |
1121 | 1121 | let suspicious = checkSuspicious() | |
1122 | 1122 | if (suspicious._1) | |
1123 | 1123 | then (suspendSuspicious(suspicious._2) ++ returnPayments(msg.caller, msg.payments)) | |
1124 | 1124 | else { | |
1125 | 1125 | let pmtAmount = if ((size(msg.payments) > 0)) | |
1126 | 1126 | then if ((size(msg.payments) != 1)) | |
1127 | 1127 | then throw("size(payments) != 1") | |
1128 | 1128 | else { | |
1129 | 1129 | let pmtAssetId = msg.payments[0].assetId | |
1130 | 1130 | if ((shareAssetId != pmtAssetId)) | |
1131 | 1131 | then throw("unknown payment token") | |
1132 | 1132 | else msg.payments[0].amount | |
1133 | 1133 | } | |
1134 | 1134 | else 0 | |
1135 | 1135 | let unlock = invoke(farmingAddress, "withdrawShareTokens", [toString(this), unlockAmount], nil) | |
1136 | 1136 | if ((unlock == unlock)) | |
1137 | 1137 | then { | |
1138 | 1138 | let withdrawAmount = (pmtAmount + unlockAmount) | |
1139 | 1139 | let inv = invoke(this, "withdrawOneCoin", [tokenOut, minAmount], [AttachedPayment(shareAssetId, withdrawAmount)]) | |
1140 | 1140 | if ((inv == inv)) | |
1141 | 1141 | then nil | |
1142 | 1142 | else throw("Strict value is not equal to itself.") | |
1143 | 1143 | } | |
1144 | 1144 | else throw("Strict value is not equal to itself.") | |
1145 | 1145 | } | |
1146 | 1146 | }) | |
1147 | 1147 | ||
1148 | 1148 | ||
1149 | 1149 | ||
1150 | 1150 | @Callable(msg) | |
1151 | 1151 | func A () = $Tuple2(nil, _A()) | |
1152 | 1152 | ||
1153 | 1153 | ||
1154 | 1154 | ||
1155 | 1155 | @Callable(msg) | |
1156 | 1156 | func getVirtualPrice () = { | |
1157 | 1157 | let D = get_D(_xp(), _A()) | |
1158 | 1158 | $Tuple2(nil, fraction(D, PRECISION, shareSupply)) | |
1159 | 1159 | } | |
1160 | 1160 | ||
1161 | 1161 | ||
1162 | 1162 | ||
1163 | 1163 | @Callable(msg) | |
1164 | 1164 | func calcTokenAmount (amounts,deposit) = { | |
1165 | 1165 | let amp = _A() | |
1166 | 1166 | let balances = _xp() | |
1167 | 1167 | let D0 = getDMem(balances, amp) | |
1168 | 1168 | func calcNewBalances (acc,balance) = { | |
1169 | 1169 | let $t02852328549 = acc | |
1170 | 1170 | let newBalances = $t02852328549._1 | |
1171 | 1171 | let i = $t02852328549._2 | |
1172 | 1172 | let newBalance = (balance + (if (deposit) | |
1173 | 1173 | then amounts[i] | |
1174 | 1174 | else -(amounts[i]))) | |
1175 | 1175 | $Tuple2((newBalances :+ newBalance), (i + 1)) | |
1176 | 1176 | } | |
1177 | 1177 | ||
1178 | 1178 | let newBalances = ( let $l = balances | |
1179 | 1179 | let $s = size($l) | |
1180 | 1180 | let $acc0 = $Tuple2(nil, 0) | |
1181 | 1181 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
1182 | 1182 | then $a | |
1183 | 1183 | else calcNewBalances($a, $l[$i]) | |
1184 | 1184 | ||
1185 | 1185 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
1186 | 1186 | then $a | |
1187 | 1187 | else throw("List size exceeds 15") | |
1188 | 1188 | ||
1189 | 1189 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15))._1 | |
1190 | 1190 | let D1 = getDMem(newBalances, amp) | |
1191 | 1191 | let diff = if (deposit) | |
1192 | 1192 | then (D1 - D0) | |
1193 | 1193 | else (D0 - D1) | |
1194 | 1194 | $Tuple2(nil, fraction(diff, shareSupply, D0)) | |
1195 | 1195 | } | |
1196 | 1196 | ||
1197 | 1197 | ||
1198 | 1198 | ||
1199 | 1199 | @Callable(msg) | |
1200 | 1200 | func rampA (_futureA,_futureTime) = valueOrElse(isActive(), valueOrElse(isAdminCall(msg), if (assert((blockTimestamp >= (initial_A_time + MIN_RAMP_TIME)))) | |
1201 | 1201 | then throw("too often") | |
1202 | 1202 | else if (assert((_futureTime >= (blockTimestamp + MIN_RAMP_TIME)))) | |
1203 | 1203 | then throw("insufficient time") | |
1204 | 1204 | else { | |
1205 | 1205 | let _initial_A = _A() | |
1206 | 1206 | if (assert(if ((_futureA > 0)) | |
1207 | 1207 | then (MAX_A > _futureA) | |
1208 | 1208 | else false)) | |
1209 | 1209 | then throw("out of base range") | |
1210 | 1210 | else if (assert(if (if ((_futureA >= _initial_A)) | |
1211 | 1211 | then ((_initial_A * MAX_A_CHANGE) >= _futureA) | |
1212 | 1212 | else false) | |
1213 | 1213 | then true | |
1214 | 1214 | else if ((_initial_A > _futureA)) | |
1215 | 1215 | then ((_futureA * MAX_A_CHANGE) >= _initial_A) | |
1216 | 1216 | else false)) | |
1217 | 1217 | then throw("out of range") | |
1218 | 1218 | else [IntegerEntry("initial_A", _initial_A), IntegerEntry("future_A", _futureA), IntegerEntry("initial_A_time", blockTimestamp), IntegerEntry("future_A_time", _futureTime)] | |
1219 | 1219 | })) | |
1220 | 1220 | ||
1221 | 1221 | ||
1222 | 1222 | ||
1223 | 1223 | @Callable(msg) | |
1224 | 1224 | func stopRampA () = valueOrElse(isActive(), valueOrElse(isAdminCall(msg), { | |
1225 | 1225 | let currentA = _A() | |
1226 | 1226 | [IntegerEntry("initial_A", currentA), IntegerEntry("future_A", currentA), IntegerEntry("initial_A_time", blockTimestamp), IntegerEntry("future_A_time", blockTimestamp)] | |
1227 | 1227 | })) | |
1228 | 1228 | ||
1229 | 1229 | ||
1230 | 1230 | ||
1231 | 1231 | @Callable(msg) | |
1232 | 1232 | func shutdown () = valueOrElse(isAdminCall(msg), if (!(active)) | |
1233 | 1233 | then throw(("DApp is already suspended. Cause: " + valueOrElse(getString(this, kCause), "the cause wasn't specified"))) | |
1234 | 1234 | else suspend("Paused by admin")) | |
1235 | 1235 | ||
1236 | 1236 | ||
1237 | 1237 | ||
1238 | 1238 | @Callable(msg) | |
1239 | 1239 | func activate () = valueOrElse(isAdminCall(msg), if (active) | |
1240 | 1240 | then throwIsActive() | |
1241 | 1241 | else [BooleanEntry(kActive, true), DeleteEntry(kCause)]) | |
1242 | 1242 | ||
1243 | 1243 | ||
1244 | 1244 | ||
1245 | 1245 | @Callable(msg) | |
1246 | 1246 | func keepLimitForFirstHarvest (shareLimit) = valueOrElse(isActive(), valueOrElse(isAdminCall(msg), [IntegerEntry(kShareLimit, shareLimit)])) | |
1247 | 1247 | ||
1248 | 1248 | ||
1249 | 1249 | @Verifier(tx) | |
1250 | 1250 | func verify () = { | |
1251 | 1251 | let multiSignedByAdmins = { | |
1252 | 1252 | let adminPubKey1Signed = if (sigVerify(tx.bodyBytes, tx.proofs[0], adminPubKey1)) | |
1253 | 1253 | then 1 | |
1254 | 1254 | else 0 | |
1255 | 1255 | let adminPubKey2Signed = if (sigVerify(tx.bodyBytes, tx.proofs[1], adminPubKey2)) | |
1256 | 1256 | then 1 | |
1257 | 1257 | else 0 | |
1258 | 1258 | let adminPubKey3Signed = if (sigVerify(tx.bodyBytes, tx.proofs[2], adminPubKey3)) | |
1259 | 1259 | then 1 | |
1260 | 1260 | else 0 | |
1261 | 1261 | (((adminPubKey1Signed + adminPubKey2Signed) + adminPubKey3Signed) >= 2) | |
1262 | 1262 | } | |
1263 | 1263 | match tx { | |
1264 | 1264 | case inv: InvokeScriptTransaction => | |
1265 | 1265 | let callTakeIntoAccount = if ((inv.dApp == this)) | |
1266 | 1266 | then (inv.function == "takeIntoAccountExtraFunds") | |
1267 | 1267 | else false | |
1268 | 1268 | let signedByAdmin = if (if (if (sigVerify(tx.bodyBytes, tx.proofs[0], adminPubKey1)) | |
1269 | 1269 | then true | |
1270 | 1270 | else sigVerify(tx.bodyBytes, tx.proofs[0], adminPubKey2)) | |
1271 | 1271 | then true | |
1272 | 1272 | else sigVerify(tx.bodyBytes, tx.proofs[0], adminPubKey3)) | |
1273 | 1273 | then true | |
1274 | 1274 | else sigVerify(tx.bodyBytes, tx.proofs[0], adminPubKeyInvoke) | |
1275 | 1275 | if (if (callTakeIntoAccount) | |
1276 | 1276 | then signedByAdmin | |
1277 | 1277 | else false) | |
1278 | 1278 | then true | |
1279 | 1279 | else multiSignedByAdmins | |
1280 | 1280 | case _ => | |
1281 | 1281 | multiSignedByAdmins | |
1282 | 1282 | } | |
1283 | 1283 | } | |
1284 | 1284 |
github/deemru/w8io/026f985 112.53 ms ◑