tx · 9fjuJxtDD4ETGMgXdGVsj2zGtrHDoH2AY1g3oejoUPRc 3MzqQ3HKdkHmJmk9mDhAeAMxmK5D2ztdAe5: -0.42000000 Waves 2023.06.16 11:41 [2624962] smart account 3MzqQ3HKdkHmJmk9mDhAeAMxmK5D2ztdAe5 > SELF 0.00000000 Waves
{ "type": 13, "id": "9fjuJxtDD4ETGMgXdGVsj2zGtrHDoH2AY1g3oejoUPRc", "fee": 42000000, "feeAssetId": null, "timestamp": 1686904884775, "version": 2, "chainId": 84, "sender": "3MzqQ3HKdkHmJmk9mDhAeAMxmK5D2ztdAe5", "senderPublicKey": "FEnkfXnQZkk1FmjhH6QZqyK2taN6ngnZBexevKxouLUM", "proofs": [ "x3mcVMjJYReaKSqFZeNsDfzmWANfjXfhUmRm3UotSvhqU4RfYX9NFhRBy9853tcibZ3g9eoWk2TyeBfw8T1PY8h", "56pKcCixFMH75n3JvzBVF3edLFxB9tGNzgHygYU38NnwJ63bC3UYC7dsqC8E6BEz4AGcNmticPewKZyTuBexmSaP" ], "script": "base64:BgJaCAISBgoEAhgREhIGCgQCGBESEgYKBAIYERISBgoEAhgREhIGCgQCGBESEgYKBAIYERISBgoEAhgREhIGCgQCGBESEgYKBAIYERISBgoEAhgREhIGCgQCGBESUwAHdmVyc2lvbgIFMS4wLjAACGtWZXJzaW9uAgd2ZXJzaW9uAAdrQWN0aXZlAgZhY3RpdmUAC2tEZXByZWNhdGVkAgtkZXByZWNhdGVkXwAJa0Fzc2V0SWRBAgpBX2Fzc2V0X2lkAAlrQXNzZXRJZEICCkJfYXNzZXRfaWQACWtCYWxhbmNlQQIPQV9hc3NldF9iYWxhbmNlAAlrQmFsYW5jZUICD0JfYXNzZXRfYmFsYW5jZQANa0JhbGFuY2VJbml0QQIMQV9hc3NldF9pbml0AA1rQmFsYW5jZUluaXRCAgxCX2Fzc2V0X2luaXQADWtTaGFyZUFzc2V0SWQCDnNoYXJlX2Fzc2V0X2lkABFrU2hhcmVBc3NldFN1cHB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tdWx0aVNpZ25lZEJ5QWRtaW5z+j/sUQ==", "height": 2624962, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: DcPFXUgWvt7aFcegn2UvABrxMdhknJuENJpFuwyNKnLQ Next: none Diff:
Old | New | Differences | |
---|---|---|---|
83 | 83 | ||
84 | 84 | let kFarmingAddress = "farming_address" | |
85 | 85 | ||
86 | - | let oracle = Address(base58' | |
86 | + | let oracle = Address(base58'3PEbqViERCoKnmcSULh6n2aiMvUdSQdCsom') | |
87 | 87 | ||
88 | 88 | func getBase58FromOracle (key) = match getString(oracle, key) { | |
89 | 89 | case string: String => | |
343 | 343 | func calcLPAmountReplansishOneToken (pmtAmount,pmtAssetId,aId,bId,balA,balB,lpSupply,fee,govFee,teamFee,virtGetMinAmount) = if ((pmtAssetId == aId)) | |
344 | 344 | then { | |
345 | 345 | let virtPayAmount = calculateVirtPay(pmtAmount, balA, fee) | |
346 | - | let $ | |
347 | - | let amountWithoutFee = $ | |
348 | - | let amountWithFee = $ | |
349 | - | let governanceReward = $ | |
350 | - | let tReward = $ | |
346 | + | let $t01127811425 = calculateFees(virtPayAmount, virtGetMinAmount, balA, balB, fee, govFee, teamFee) | |
347 | + | let amountWithoutFee = $t01127811425._1 | |
348 | + | let amountWithFee = $t01127811425._2 | |
349 | + | let governanceReward = $t01127811425._3 | |
350 | + | let tReward = $t01127811425._4 | |
351 | 351 | let balanceAVirt = (balA + virtPayAmount) | |
352 | 352 | let balanceBVirt = (((balB + amountWithoutFee) - governanceReward) - tReward) | |
353 | 353 | let newBalanceA = (balA + pmtAmount) | |
355 | 355 | let ratioShareTokensInA = fraction(toBigInt((pmtAmount - virtPayAmount)), scale16, toBigInt(balanceAVirt)) | |
356 | 356 | let ratioShareTokensInB = fraction(toBigInt(amountWithFee), scale16, toBigInt(balanceBVirt)) | |
357 | 357 | let shareTokenToPayAmount = toInt(fraction(min([ratioShareTokensInA, ratioShareTokensInB]), toBigInt(lpSupply), scale16)) | |
358 | - | $Tuple6(shareTokenToPayAmount, newBalanceA, newBalanceB, governanceReward, tReward, bId) | |
358 | + | let shareTokenToPayAmountInBoth = toInt(fraction(fraction(toBigInt(pmtAmount), scale16, toBigInt(balA)), toBigInt(lpSupply), scale16)) | |
359 | + | let loss = fraction((shareTokenToPayAmount - shareTokenToPayAmountInBoth), scale8, shareTokenToPayAmountInBoth) | |
360 | + | $Tuple7(shareTokenToPayAmount, newBalanceA, newBalanceB, governanceReward, tReward, bId, loss) | |
359 | 361 | } | |
360 | 362 | else { | |
361 | 363 | let virtPayAmount = calculateVirtPay(pmtAmount, balB, fee) | |
362 | - | let $ | |
363 | - | let amountWithoutFee = $ | |
364 | - | let amountWithFee = $ | |
365 | - | let governanceReward = $ | |
366 | - | let tReward = $ | |
364 | + | let $t01245112598 = calculateFees(virtPayAmount, virtGetMinAmount, balB, balA, fee, govFee, teamFee) | |
365 | + | let amountWithoutFee = $t01245112598._1 | |
366 | + | let amountWithFee = $t01245112598._2 | |
367 | + | let governanceReward = $t01245112598._3 | |
368 | + | let tReward = $t01245112598._4 | |
367 | 369 | let balanceAVirt = (((balA + amountWithoutFee) - governanceReward) - tReward) | |
368 | 370 | let balanceBVirt = (balB + virtPayAmount) | |
369 | 371 | let newBalanceA = ((balA - governanceReward) - tReward) | |
371 | 373 | let ratioShareTokensInA = fraction(toBigInt(amountWithFee), scale16, toBigInt(balanceAVirt)) | |
372 | 374 | let ratioShareTokensInB = fraction(toBigInt((pmtAmount - virtPayAmount)), scale16, toBigInt(balanceBVirt)) | |
373 | 375 | let shareTokenToPayAmount = toInt(fraction(min([ratioShareTokensInA, ratioShareTokensInB]), toBigInt(lpSupply), scale16)) | |
374 | - | $Tuple6(shareTokenToPayAmount, newBalanceA, newBalanceB, governanceReward, tReward, aId) | |
376 | + | let shareTokenToPayAmountInBoth = toInt(fraction(fraction(toBigInt(pmtAmount), scale16, toBigInt(balB)), toBigInt(lpSupply), scale16)) | |
377 | + | let loss = fraction((shareTokenToPayAmount - shareTokenToPayAmountInBoth), scale8, shareTokenToPayAmountInBoth) | |
378 | + | $Tuple7(shareTokenToPayAmount, newBalanceA, newBalanceB, governanceReward, tReward, aId, loss) | |
375 | 379 | } | |
376 | 380 | ||
377 | 381 | ||
378 | 382 | func calcLPReplenishDiffProp (pmtA,pmtB,pmtIdA,pmtIdB,balA,balB,lpSupply,fee,govFee,teamFee,virtGetMinAmount) = { | |
379 | - | let $ | |
380 | - | let lpTwoAmount = $ | |
381 | - | let change = $ | |
382 | - | let changeAssetId = $ | |
383 | - | let pmtAmountA = $ | |
384 | - | let pmtAmountB = $ | |
383 | + | let $t01374713895 = calcLPAmountReplensishTwoTokens(pmtA, pmtB, pmtIdA, pmtIdB, balA, balB, lpSupply) | |
384 | + | let lpTwoAmount = $t01374713895._1 | |
385 | + | let change = $t01374713895._2 | |
386 | + | let changeAssetId = $t01374713895._3 | |
387 | + | let pmtAmountA = $t01374713895._4 | |
388 | + | let pmtAmountB = $t01374713895._5 | |
385 | 389 | if ((change > 0)) | |
386 | 390 | then { | |
387 | - | let $t01330313532 = calcLPAmountReplansishOneToken(change, changeAssetId, pmtIdA, pmtIdB, (balA + pmtAmountA), (balB + pmtAmountB), lpSupply, fee, govFee, teamFee, virtGetMinAmount) | |
388 | - | let lpOne = $t01330313532._1 | |
389 | - | let newBalanceA = $t01330313532._2 | |
390 | - | let newBalanceB = $t01330313532._3 | |
391 | - | let governanceReward = $t01330313532._4 | |
392 | - | let tReward = $t01330313532._5 | |
393 | - | let gId = $t01330313532._6 | |
394 | - | $Tuple6((lpTwoAmount + lpOne), newBalanceA, newBalanceB, governanceReward, tReward, gId) | |
391 | + | let $t01392714162 = calcLPAmountReplansishOneToken(change, changeAssetId, pmtIdA, pmtIdB, (balA + pmtAmountA), (balB + pmtAmountB), lpSupply, fee, govFee, teamFee, virtGetMinAmount) | |
392 | + | let lpOne = $t01392714162._1 | |
393 | + | let newBalanceA = $t01392714162._2 | |
394 | + | let newBalanceB = $t01392714162._3 | |
395 | + | let governanceReward = $t01392714162._4 | |
396 | + | let tReward = $t01392714162._5 | |
397 | + | let gId = $t01392714162._6 | |
398 | + | let loss = $t01392714162._7 | |
399 | + | $Tuple7((lpTwoAmount + lpOne), loss, newBalanceA, newBalanceB, governanceReward, tReward, gId) | |
395 | 400 | } | |
396 | - | else $ | |
401 | + | else $Tuple7(lpTwoAmount, 0, (balA + pmtAmountA), (balB + pmtAmountB), 0, 0, unit) | |
397 | 402 | } | |
398 | 403 | ||
399 | 404 | ||
400 | 405 | @Callable(i) | |
401 | 406 | func calcLPReplenishDiffPropREADONLY (callerBytes,args,pAmounts,pAssetIds) = { | |
402 | - | let $ | |
403 | - | let strAssetIdA = $ | |
404 | - | let strAssetIdB = $ | |
405 | - | let assetIdA = $ | |
406 | - | let assetIdB = $ | |
407 | - | let shareAssetId = $ | |
408 | - | let $ | |
409 | - | let balA = $ | |
410 | - | let balB = $ | |
411 | - | let accBalA = $ | |
412 | - | let accBalB = $ | |
413 | - | let lpSupply = $ | |
407 | + | let $t01449814588 = getPoolAssets(i.caller) | |
408 | + | let strAssetIdA = $t01449814588._1 | |
409 | + | let strAssetIdB = $t01449814588._2 | |
410 | + | let assetIdA = $t01449814588._3 | |
411 | + | let assetIdB = $t01449814588._4 | |
412 | + | let shareAssetId = $t01449814588._5 | |
413 | + | let $t01459314685 = getPoolBalances(i.caller, assetIdA, assetIdB) | |
414 | + | let balA = $t01459314685._1 | |
415 | + | let balB = $t01459314685._2 | |
416 | + | let accBalA = $t01459314685._3 | |
417 | + | let accBalB = $t01459314685._4 | |
418 | + | let lpSupply = $t01459314685._5 | |
414 | 419 | let pmtA = parseIntValue(args[0]) | |
415 | 420 | let pmtB = parseIntValue(args[1]) | |
416 | 421 | let virtGetMinAmount = parseIntValue(args[2]) | |
417 | - | let $t01418014247 = getFeeParams(i.caller, i.originCaller) | |
418 | - | let fee = $t01418014247._1 | |
419 | - | let govFee = $t01418014247._2 | |
420 | - | let teamFee = $t01418014247._3 | |
421 | - | let $t01425214438 = calcLPReplenishDiffProp(pmtA, pmtB, assetIdA, assetIdB, balA, balB, lpSupply, fee, govFee, teamFee, virtGetMinAmount) | |
422 | - | let lp = $t01425214438._1 | |
423 | - | let newBalanceA = $t01425214438._2 | |
424 | - | let newBalanceB = $t01425214438._3 | |
425 | - | let governanceReward = $t01425214438._4 | |
426 | - | let tReward = $t01425214438._5 | |
427 | - | let aId = $t01425214438._6 | |
428 | - | $Tuple2(nil, $Tuple2(nil, [lp, newBalanceA, newBalanceB, governanceReward, tReward, aId])) | |
422 | + | let $t01481914886 = getFeeParams(i.caller, i.originCaller) | |
423 | + | let fee = $t01481914886._1 | |
424 | + | let govFee = $t01481914886._2 | |
425 | + | let teamFee = $t01481914886._3 | |
426 | + | let $t01489115083 = calcLPReplenishDiffProp(pmtA, pmtB, assetIdA, assetIdB, balA, balB, lpSupply, fee, govFee, teamFee, virtGetMinAmount) | |
427 | + | let lp = $t01489115083._1 | |
428 | + | let loss = $t01489115083._2 | |
429 | + | let newBalanceA = $t01489115083._3 | |
430 | + | let newBalanceB = $t01489115083._4 | |
431 | + | let governanceReward = $t01489115083._5 | |
432 | + | let tReward = $t01489115083._6 | |
433 | + | let aId = $t01489115083._7 | |
434 | + | $Tuple2(nil, $Tuple2(nil, [lp, loss, newBalanceA, newBalanceB, governanceReward, tReward, aId])) | |
429 | 435 | } | |
430 | 436 | ||
431 | 437 | ||
432 | 438 | ||
433 | 439 | @Callable(i) | |
434 | 440 | func withdrawREADONLY (callerBytes,args,pAmounts,pAssetIds) = { | |
435 | - | let $ | |
436 | - | let strAssetIdA = $ | |
437 | - | let strAssetIdB = $ | |
438 | - | let assetIdA = $ | |
439 | - | let assetIdB = $ | |
440 | - | let shareAssetId = $ | |
441 | - | let $ | |
442 | - | let balanceA = $ | |
443 | - | let balanceB = $ | |
444 | - | let accountBalanceA = $ | |
445 | - | let accountBalanceB = $ | |
446 | - | let shareAssetSupply = $ | |
441 | + | let $t01531015400 = getPoolAssets(i.caller) | |
442 | + | let strAssetIdA = $t01531015400._1 | |
443 | + | let strAssetIdB = $t01531015400._2 | |
444 | + | let assetIdA = $t01531015400._3 | |
445 | + | let assetIdB = $t01531015400._4 | |
446 | + | let shareAssetId = $t01531015400._5 | |
447 | + | let $t01540515529 = getPoolBalances(i.caller, assetIdA, assetIdB) | |
448 | + | let balanceA = $t01540515529._1 | |
449 | + | let balanceB = $t01540515529._2 | |
450 | + | let accountBalanceA = $t01540515529._3 | |
451 | + | let accountBalanceB = $t01540515529._4 | |
452 | + | let shareAssetSupply = $t01540515529._5 | |
447 | 453 | let withdrawAmount = parseIntValue(args[0]) | |
448 | - | let $ | |
454 | + | let $t01558315745 = if ((size(args) == 3)) | |
449 | 455 | then $Tuple2(parseIntValue(args[1]), parseIntValue(args[2])) | |
450 | 456 | else $Tuple2(balanceA, balanceB) | |
451 | - | let balA = $ | |
452 | - | let balB = $ | |
457 | + | let balA = $t01558315745._1 | |
458 | + | let balB = $t01558315745._2 | |
453 | 459 | let amountToPayA = fraction(withdrawAmount, balA, shareAssetSupply) | |
454 | 460 | let amountToPayB = fraction(withdrawAmount, balB, shareAssetSupply) | |
455 | 461 | $Tuple2(nil, $Tuple2(nil, [amountToPayA, amountToPayB])) | |
460 | 466 | @Callable(i) | |
461 | 467 | func init (callerBytes,args,pAmounts,pAssetIds) = { | |
462 | 468 | let caller = Address(callerBytes) | |
463 | - | let $ | |
464 | - | let pmtAmountA = $ | |
465 | - | let pmtAssetIdA = $ | |
466 | - | let $ | |
467 | - | let pmtAmountB = $ | |
468 | - | let pmtAssetIdB = $ | |
469 | + | let $t01610016178 = $Tuple2(pAmounts[0], parsePaymentAsset(pAssetIds[0])) | |
470 | + | let pmtAmountA = $t01610016178._1 | |
471 | + | let pmtAssetIdA = $t01610016178._2 | |
472 | + | let $t01618316261 = $Tuple2(pAmounts[1], parsePaymentAsset(pAssetIds[1])) | |
473 | + | let pmtAmountB = $t01618316261._1 | |
474 | + | let pmtAssetIdB = $t01618316261._2 | |
469 | 475 | if (!(containsElement([adminPubKey1, adminPubKey2, adminPubKey3, adminInvokePubKey], i.originCallerPublicKey))) | |
470 | 476 | then throw("Only admin can call this function") | |
471 | 477 | else if ((size(args) != 1)) | |
475 | 481 | else if ((pmtAssetIdA == pmtAssetIdB)) | |
476 | 482 | then throw("Assets must be different") | |
477 | 483 | else { | |
478 | - | let $ | |
479 | - | let pmtStrAssetIdA = $ | |
480 | - | let pmtAssetNameA = $ | |
481 | - | let pmtDecimalsA = $ | |
482 | - | let $ | |
483 | - | let pmtStrAssetIdB = $ | |
484 | - | let pmtAssetNameB = $ | |
485 | - | let pmtDecimalsB = $ | |
484 | + | let $t01669616773 = getAssetInfo(pmtAssetIdA) | |
485 | + | let pmtStrAssetIdA = $t01669616773._1 | |
486 | + | let pmtAssetNameA = $t01669616773._2 | |
487 | + | let pmtDecimalsA = $t01669616773._3 | |
488 | + | let $t01678216859 = getAssetInfo(pmtAssetIdB) | |
489 | + | let pmtStrAssetIdB = $t01678216859._1 | |
490 | + | let pmtAssetNameB = $t01678216859._2 | |
491 | + | let pmtDecimalsB = $t01678216859._3 | |
486 | 492 | let firstHarvest = (args[0] == "true") | |
487 | 493 | let shareName = ((("s" + take(pmtAssetNameA, 7)) + "_") + take(pmtAssetNameB, 7)) | |
488 | 494 | let shareDescription = ((((("ShareToken of SwopFi protocol for " + pmtAssetNameA) + " and ") + pmtAssetNameB) + " at address ") + toString(this)) | |
519 | 525 | @Callable(i) | |
520 | 526 | func initWithInitRatio (callerBytes,args,pAmounts,pAssetIds) = { | |
521 | 527 | let caller = Address(callerBytes) | |
522 | - | let $ | |
523 | - | let amtAssetA = $ | |
524 | - | let amtAssetB = $ | |
525 | - | let assetIdAStr = $ | |
526 | - | let assetIdBStr = $ | |
527 | - | let firstHarvest = $ | |
528 | + | let $t01908019280 = $Tuple5(parseIntValue(args[0]), parseIntValue(args[1]), args[2], args[3], (args[4] == "true")) | |
529 | + | let amtAssetA = $t01908019280._1 | |
530 | + | let amtAssetB = $t01908019280._2 | |
531 | + | let assetIdAStr = $t01908019280._3 | |
532 | + | let assetIdBStr = $t01908019280._4 | |
533 | + | let firstHarvest = $t01908019280._5 | |
528 | 534 | if (!(containsElement([adminPubKey1, adminPubKey2, adminPubKey3, adminInvokePubKey], i.originCallerPublicKey))) | |
529 | 535 | then throw("Only admin can call this function") | |
530 | 536 | else if ((size(args) != 5)) | |
534 | 540 | else if ((assetIdAStr == assetIdBStr)) | |
535 | 541 | then throw("Assets must be different") | |
536 | 542 | else { | |
537 | - | let $ | |
538 | - | let pmtStrAssetIdA = $ | |
539 | - | let pmtAssetNameA = $ | |
540 | - | let pmtDecimalsA = $ | |
541 | - | let $ | |
542 | - | let pmtStrAssetIdB = $ | |
543 | - | let pmtAssetNameB = $ | |
544 | - | let pmtDecimalsB = $ | |
543 | + | let $t01971519792 = getAssetInfo(assetIdAStr) | |
544 | + | let pmtStrAssetIdA = $t01971519792._1 | |
545 | + | let pmtAssetNameA = $t01971519792._2 | |
546 | + | let pmtDecimalsA = $t01971519792._3 | |
547 | + | let $t01980119878 = getAssetInfo(assetIdBStr) | |
548 | + | let pmtStrAssetIdB = $t01980119878._1 | |
549 | + | let pmtAssetNameB = $t01980119878._2 | |
550 | + | let pmtDecimalsB = $t01980119878._3 | |
545 | 551 | let shareName = ((("s" + take(pmtAssetNameA, 7)) + "_") + take(pmtAssetNameB, 7)) | |
546 | 552 | let shareDescription = ((((("ShareToken of SwopFi protocol for " + pmtAssetNameA) + " and ") + pmtAssetNameB) + " at address ") + toString(this)) | |
547 | 553 | let shareDecimals = ((pmtDecimalsA + pmtDecimalsB) / 2) | |
572 | 578 | @Callable(i) | |
573 | 579 | func exchange (callerBytes,args,pAmounts,pAssetIds) = valueOrElse(isOraclePool(toString(i.caller)), valueOrElse(isDepricated(toString(i.caller)), valueOrElse(isActive(), { | |
574 | 580 | let caller = Address(callerBytes) | |
575 | - | let $ | |
576 | - | let pmtAmount = $ | |
577 | - | let pmtAssetId = $ | |
581 | + | let $t02230422380 = $Tuple2(pAmounts[0], parsePaymentAsset(pAssetIds[0])) | |
582 | + | let pmtAmount = $t02230422380._1 | |
583 | + | let pmtAssetId = $t02230422380._2 | |
578 | 584 | let minAmountToReceive = parseIntValue(args[0]) | |
579 | - | let $ | |
580 | - | let strAssetIdA = $ | |
581 | - | let strAssetIdB = $ | |
582 | - | let assetIdA = $ | |
583 | - | let assetIdB = $ | |
584 | - | let $ | |
585 | - | let balanceA = $ | |
586 | - | let balanceB = $ | |
587 | - | let accountBalanceA = $ | |
588 | - | let accountBalanceB = $ | |
585 | + | let $t02244522521 = getPoolAssets(i.caller) | |
586 | + | let strAssetIdA = $t02244522521._1 | |
587 | + | let strAssetIdB = $t02244522521._2 | |
588 | + | let assetIdA = $t02244522521._3 | |
589 | + | let assetIdB = $t02244522521._4 | |
590 | + | let $t02253022636 = getPoolBalances(i.caller, assetIdA, assetIdB) | |
591 | + | let balanceA = $t02253022636._1 | |
592 | + | let balanceB = $t02253022636._2 | |
593 | + | let accountBalanceA = $t02253022636._3 | |
594 | + | let accountBalanceB = $t02253022636._4 | |
589 | 595 | if ((size(args) != 1)) | |
590 | 596 | then throw("Wrong args size") | |
591 | 597 | else if (if ((balanceA == 0)) | |
603 | 609 | else (balanceB > accountBalanceB)) | |
604 | 610 | then $Tuple2(nil, ([ScriptTransfer(caller, pmtAmount, pmtAssetId)] ++ suspendSuspicious(accountBalanceA, accountBalanceB, balanceA, balanceB, strAssetIdA, strAssetIdB))) | |
605 | 611 | else { | |
606 | - | let $ | |
607 | - | let fee = $ | |
608 | - | let govFee = $ | |
609 | - | let teamFee = $ | |
610 | - | let $ | |
612 | + | let $t02353623603 = getFeeParams(i.caller, i.originCaller) | |
613 | + | let fee = $t02353623603._1 | |
614 | + | let govFee = $t02353623603._2 | |
615 | + | let teamFee = $t02353623603._3 | |
616 | + | let $t02361623967 = if ((pmtAssetId == assetIdA)) | |
611 | 617 | then calculateFees(pmtAmount, minAmountToReceive, balanceA, balanceB, fee, govFee, teamFee) | |
612 | 618 | else calculateFees(pmtAmount, minAmountToReceive, balanceB, balanceA, fee, govFee, teamFee) | |
613 | - | let amountWithoutFee = $ | |
614 | - | let amountWithFee = $ | |
615 | - | let governanceReward = $ | |
616 | - | let teamReward = $ | |
617 | - | let $ | |
619 | + | let amountWithoutFee = $t02361623967._1 | |
620 | + | let amountWithFee = $t02361623967._2 | |
621 | + | let governanceReward = $t02361623967._3 | |
622 | + | let teamReward = $t02361623967._4 | |
623 | + | let $t02398124316 = if ((pmtAssetId == assetIdA)) | |
618 | 624 | then $Tuple3((balanceA + pmtAmount), (((balanceB - amountWithFee) - governanceReward) - teamReward), assetIdB) | |
619 | 625 | else $Tuple3((((balanceA - amountWithFee) - governanceReward) - teamReward), (balanceB + pmtAmount), assetIdA) | |
620 | - | let newBalanceA = $ | |
621 | - | let newBalanceB = $ | |
622 | - | let assetIdSend = $ | |
623 | - | let $ | |
626 | + | let newBalanceA = $t02398124316._1 | |
627 | + | let newBalanceB = $t02398124316._2 | |
628 | + | let assetIdSend = $t02398124316._3 | |
629 | + | let $t02433024590 = if ((pmtAssetId == assetIdA)) | |
624 | 630 | then $Tuple2(pmtAmount, ((amountWithFee + governanceReward) + teamReward)) | |
625 | 631 | else $Tuple2(((amountWithFee + governanceReward) + teamReward), pmtAmount) | |
626 | - | let stakeAmountA = $ | |
627 | - | let stakeAmountB = $ | |
632 | + | let stakeAmountA = $t02433024590._1 | |
633 | + | let stakeAmountB = $t02433024590._2 | |
628 | 634 | let stake1 = if (contains(stakingAssets, strAssetIdA)) | |
629 | 635 | then invoke(i.caller, "stakeUnstake", [(pmtAssetId == assetIdA), stakeAmountA, strAssetIdA], nil) | |
630 | 636 | else 0 | |
650 | 656 | let pmtAssetIdB = parsePaymentAsset(pAssetIds[1]) | |
651 | 657 | let stakeFarming = (args[0] == "true") | |
652 | 658 | let lockType = parseIntValue(args[1]) | |
653 | - | let $ | |
654 | - | let strAssetIdA = $ | |
655 | - | let strAssetIdB = $ | |
656 | - | let assetIdA = $ | |
657 | - | let assetIdB = $ | |
658 | - | let shareAssetId = $ | |
659 | - | let $ | |
660 | - | let balanceA = $ | |
661 | - | let balanceB = $ | |
662 | - | let accountBalanceA = $ | |
663 | - | let accountBalanceB = $ | |
664 | - | let shareAssetSupply = $ | |
659 | + | let $t02590525995 = getPoolAssets(i.caller) | |
660 | + | let strAssetIdA = $t02590525995._1 | |
661 | + | let strAssetIdB = $t02590525995._2 | |
662 | + | let assetIdA = $t02590525995._3 | |
663 | + | let assetIdB = $t02590525995._4 | |
664 | + | let shareAssetId = $t02590525995._5 | |
665 | + | let $t02600426128 = getPoolBalances(i.caller, assetIdA, assetIdB) | |
666 | + | let balanceA = $t02600426128._1 | |
667 | + | let balanceB = $t02600426128._2 | |
668 | + | let accountBalanceA = $t02600426128._3 | |
669 | + | let accountBalanceB = $t02600426128._4 | |
670 | + | let shareAssetSupply = $t02600426128._5 | |
665 | 671 | if ((size(args) != 2)) | |
666 | 672 | then throw("Wrong args size") | |
667 | 673 | else if (if ((size(pAmounts) != 2)) | |
681 | 687 | else pAssetIds[2], pAmounts[2])] | |
682 | 688 | else (nil ++ suspendSuspicious(accountBalanceA, accountBalanceB, balanceA, balanceB, strAssetIdA, strAssetIdB))))) | |
683 | 689 | else { | |
684 | - | let $ | |
685 | - | let shareTokenToPayAmount = $ | |
686 | - | let change = $ | |
687 | - | let changeAssetId = $ | |
688 | - | let pmtAmountA = $ | |
689 | - | let pmtAmountB = $ | |
690 | + | let $t02706527263 = calcLPAmountReplensishTwoTokens(pAmounts[0], pAmounts[1], pmtAssetIdA, pmtAssetIdB, balanceA, balanceB, shareAssetSupply) | |
691 | + | let shareTokenToPayAmount = $t02706527263._1 | |
692 | + | let change = $t02706527263._2 | |
693 | + | let changeAssetId = $t02706527263._3 | |
694 | + | let pmtAmountA = $t02706527263._4 | |
695 | + | let pmtAmountB = $t02706527263._5 | |
690 | 696 | if ((shareTokenToPayAmount == 0)) | |
691 | 697 | then throw("Too small amount to replenish") | |
692 | 698 | else if ((0 > change)) | |
739 | 745 | let virtGetMinAmount = parseIntValue(args[0]) | |
740 | 746 | let stakeFarming = (args[1] == "true") | |
741 | 747 | let lockType = parseIntValue(args[2]) | |
742 | - | let $ | |
743 | - | let strAssetIdA = $ | |
744 | - | let strAssetIdB = $ | |
745 | - | let assetIdA = $ | |
746 | - | let assetIdB = $ | |
747 | - | let shareAssetId = $ | |
748 | - | let $ | |
749 | - | let balanceA = $ | |
750 | - | let balanceB = $ | |
751 | - | let accountBalanceA = $ | |
752 | - | let accountBalanceB = $ | |
753 | - | let shareAssetSupply = $ | |
748 | + | let $t02952229612 = getPoolAssets(i.caller) | |
749 | + | let strAssetIdA = $t02952229612._1 | |
750 | + | let strAssetIdB = $t02952229612._2 | |
751 | + | let assetIdA = $t02952229612._3 | |
752 | + | let assetIdB = $t02952229612._4 | |
753 | + | let shareAssetId = $t02952229612._5 | |
754 | + | let $t02961729741 = getPoolBalances(i.caller, assetIdA, assetIdB) | |
755 | + | let balanceA = $t02961729741._1 | |
756 | + | let balanceB = $t02961729741._2 | |
757 | + | let accountBalanceA = $t02961729741._3 | |
758 | + | let accountBalanceB = $t02961729741._4 | |
759 | + | let shareAssetSupply = $t02961729741._5 | |
754 | 760 | let initial = ((balanceA + balanceB) == 0) | |
755 | 761 | if ((size(args) != 3)) | |
756 | 762 | then throw("Wrong args size") | |
773 | 779 | else pAssetIds[2], pAmounts[2])] | |
774 | 780 | else (nil ++ suspendSuspicious(accountBalanceA, accountBalanceB, balanceA, balanceB, strAssetIdA, strAssetIdB))))) | |
775 | 781 | else { | |
776 | - | let $ | |
777 | - | let fee = $ | |
778 | - | let govFee = $ | |
779 | - | let teamFee = $ | |
780 | - | let $ | |
781 | - | let pmtAssetIdStr = $ | |
782 | - | let pmtAssetIdName = $ | |
783 | - | let $ | |
784 | - | let shareTokenToPayAmount = $ | |
785 | - | let newBalanceA = $ | |
786 | - | let newBalanceB = $ | |
787 | - | let govReward = $ | |
788 | - | let teamReward = $ | |
789 | - | let govRewardAsset = $ | |
782 | + | let $t03065330720 = getFeeParams(i.caller, i.originCaller) | |
783 | + | let fee = $t03065330720._1 | |
784 | + | let govFee = $t03065330720._2 | |
785 | + | let teamFee = $t03065330720._3 | |
786 | + | let $t03072930791 = getAssetInfo(pmtAssetId) | |
787 | + | let pmtAssetIdStr = $t03072930791._1 | |
788 | + | let pmtAssetIdName = $t03072930791._2 | |
789 | + | let $t03080931055 = calcLPAmountReplansishOneToken(pmtAmount, pmtAssetId, assetIdA, assetIdB, balanceA, balanceB, shareAssetSupply, fee, govFee, teamFee, virtGetMinAmount) | |
790 | + | let shareTokenToPayAmount = $t03080931055._1 | |
791 | + | let newBalanceA = $t03080931055._2 | |
792 | + | let newBalanceB = $t03080931055._3 | |
793 | + | let govReward = $t03080931055._4 | |
794 | + | let teamReward = $t03080931055._5 | |
795 | + | let govRewardAsset = $t03080931055._6 | |
790 | 796 | let govRewardAssetStr = if ((govRewardAsset == assetIdA)) | |
791 | 797 | then strAssetIdA | |
792 | 798 | else strAssetIdB | |
835 | 841 | @Callable(i) | |
836 | 842 | func withdraw (callerBytes,args,pAmounts,pAssetIds) = valueOrElse(isOraclePool(toString(i.caller)), valueOrElse(isActive(), { | |
837 | 843 | let caller = Address(callerBytes) | |
838 | - | let $ | |
839 | - | let strAssetIdA = $ | |
840 | - | let strAssetIdB = $ | |
841 | - | let assetIdA = $ | |
842 | - | let assetIdB = $ | |
843 | - | let shareAssetId = $ | |
844 | - | let $ | |
845 | - | let balanceA = $ | |
846 | - | let balanceB = $ | |
847 | - | let accountBalanceA = $ | |
848 | - | let accountBalanceB = $ | |
849 | - | let shareAssetSupply = $ | |
850 | - | let $ | |
844 | + | let $t03312333213 = getPoolAssets(i.caller) | |
845 | + | let strAssetIdA = $t03312333213._1 | |
846 | + | let strAssetIdB = $t03312333213._2 | |
847 | + | let assetIdA = $t03312333213._3 | |
848 | + | let assetIdB = $t03312333213._4 | |
849 | + | let shareAssetId = $t03312333213._5 | |
850 | + | let $t03322233346 = getPoolBalances(i.caller, assetIdA, assetIdB) | |
851 | + | let balanceA = $t03322233346._1 | |
852 | + | let balanceB = $t03322233346._2 | |
853 | + | let accountBalanceA = $t03322233346._3 | |
854 | + | let accountBalanceB = $t03322233346._4 | |
855 | + | let shareAssetSupply = $t03322233346._5 | |
856 | + | let $t03335533735 = if ((size(pAmounts) == 1)) | |
851 | 857 | then { | |
852 | 858 | let pAsset = parsePaymentAsset(pAssetIds[0]) | |
853 | 859 | if ((pAsset != shareAssetId)) | |
855 | 861 | else $Tuple2(pAmounts[0], pAsset) | |
856 | 862 | } | |
857 | 863 | else $Tuple2(0, shareAssetId) | |
858 | - | let pmtAmount = $ | |
859 | - | let pmtAssetId = $ | |
864 | + | let pmtAmount = $t03335533735._1 | |
865 | + | let pmtAssetId = $t03335533735._2 | |
860 | 866 | if ((size(args) != 1)) | |
861 | 867 | then throw("Wrong args size") | |
862 | 868 | else if ((size(pAmounts) > 1)) | |
901 | 907 | let withdrawAsset = if ((args[0] == "")) | |
902 | 908 | then unit | |
903 | 909 | else fromBase58String(args[0]) | |
904 | - | let $ | |
905 | - | let strAssetIdA = $ | |
906 | - | let strAssetIdB = $ | |
907 | - | let assetIdA = $ | |
908 | - | let assetIdB = $ | |
909 | - | let shareAssetId = $ | |
910 | - | let $ | |
911 | - | let balanceA = $ | |
912 | - | let balanceB = $ | |
913 | - | let accountBalanceA = $ | |
914 | - | let accountBalanceB = $ | |
915 | - | let shareAssetSupply = $ | |
916 | - | let $ | |
910 | + | let $t03595336043 = getPoolAssets(i.caller) | |
911 | + | let strAssetIdA = $t03595336043._1 | |
912 | + | let strAssetIdB = $t03595336043._2 | |
913 | + | let assetIdA = $t03595336043._3 | |
914 | + | let assetIdB = $t03595336043._4 | |
915 | + | let shareAssetId = $t03595336043._5 | |
916 | + | let $t03605236176 = getPoolBalances(i.caller, assetIdA, assetIdB) | |
917 | + | let balanceA = $t03605236176._1 | |
918 | + | let balanceB = $t03605236176._2 | |
919 | + | let accountBalanceA = $t03605236176._3 | |
920 | + | let accountBalanceB = $t03605236176._4 | |
921 | + | let shareAssetSupply = $t03605236176._5 | |
922 | + | let $t03618536537 = if ((size(pAmounts) == 1)) | |
917 | 923 | then { | |
918 | 924 | let pAsset = parsePaymentAsset(pAssetIds[0]) | |
919 | 925 | if ((pAsset != shareAssetId)) | |
921 | 927 | else $Tuple2(pAmounts[0], pAsset) | |
922 | 928 | } | |
923 | 929 | else $Tuple2(0, shareAssetId) | |
924 | - | let pmtAmount = $ | |
925 | - | let pmtAssetId = $ | |
930 | + | let pmtAmount = $t03618536537._1 | |
931 | + | let pmtAssetId = $t03618536537._2 | |
926 | 932 | let virtMinToRecive = parseIntValue(args[1]) | |
927 | 933 | if ((size(args) != 3)) | |
928 | 934 | then throw("Wrong args size") | |
946 | 952 | let withdrawAmount = (pmtAmount + unlockAmount) | |
947 | 953 | let amountToPayA = fraction(withdrawAmount, balanceA, shareAssetSupply) | |
948 | 954 | let amountToPayB = fraction(withdrawAmount, balanceB, shareAssetSupply) | |
949 | - | let $ | |
950 | - | let fee = $ | |
951 | - | let govFee = $ | |
952 | - | let teamFee = $ | |
953 | - | let $ | |
955 | + | let $t03780437871 = getFeeParams(i.caller, i.originCaller) | |
956 | + | let fee = $t03780437871._1 | |
957 | + | let govFee = $t03780437871._2 | |
958 | + | let teamFee = $t03780437871._3 | |
959 | + | let $t03788438298 = if ((withdrawAsset == assetIdA)) | |
954 | 960 | then calculateFees(amountToPayB, virtMinToRecive, (balanceB - amountToPayB), (balanceA - amountToPayA), fee, govFee, teamFee) | |
955 | 961 | else calculateFees(amountToPayA, virtMinToRecive, (balanceA - amountToPayA), (balanceB - amountToPayB), fee, govFee, teamFee) | |
956 | - | let amountWithoutFee = $ | |
957 | - | let amountWithFee = $ | |
958 | - | let governanceReward = $ | |
959 | - | let teamReward = $ | |
960 | - | let $ | |
962 | + | let amountWithoutFee = $t03788438298._1 | |
963 | + | let amountWithFee = $t03788438298._2 | |
964 | + | let governanceReward = $t03788438298._3 | |
965 | + | let teamReward = $t03788438298._4 | |
966 | + | let $t03831139621 = if ((withdrawAsset == assetIdA)) | |
961 | 967 | then { | |
962 | 968 | let unstake = if (contains(stakingAssets, strAssetIdA)) | |
963 | 969 | then invoke(i.caller, "stakeUnstake", [false, (((amountToPayA + amountWithFee) + governanceReward) + teamReward), strAssetIdA], nil) | |
974 | 980 | then $Tuple4(balanceA, ((((balanceB - amountToPayB) - amountWithFee) - governanceReward) - teamReward), assetIdB, [ScriptTransfer(caller, (amountToPayB + amountWithFee), assetIdB)]) | |
975 | 981 | else throw("Strict value is not equal to itself.") | |
976 | 982 | } | |
977 | - | let newBalanceA = $ | |
978 | - | let newBalanceB = $ | |
979 | - | let govRewardAssetId = $ | |
980 | - | let userTransfer = $ | |
983 | + | let newBalanceA = $t03831139621._1 | |
984 | + | let newBalanceB = $t03831139621._2 | |
985 | + | let govRewardAssetId = $t03831139621._3 | |
986 | + | let userTransfer = $t03831139621._4 | |
981 | 987 | $Tuple2([ScriptTransfer(i.caller, unlockAmount, shareAssetId)], $Tuple2(([IntegerEntry(kBalanceA, newBalanceA), IntegerEntry(kBalanceB, newBalanceB), IntegerEntry(kShareAssetSupply, (shareAssetSupply - withdrawAmount)), Burn(shareAssetId, withdrawAmount), ScriptTransfer(moneyBoxAddress, governanceReward, govRewardAssetId), ScriptTransfer(teamBoxAddress, teamReward, govRewardAssetId)] ++ userTransfer), nil)) | |
982 | 988 | } | |
983 | 989 | else throw("Strict value is not equal to itself.") | |
988 | 994 | ||
989 | 995 | @Callable(i) | |
990 | 996 | func takeIntoAccountExtraFunds (callerBytes,args,pAmounts,pAssetIds) = valueOrElse(isOraclePool(toString(i.caller)), valueOrElse(isActive(), { | |
991 | - | let $ | |
992 | - | let strAssetIdA = $ | |
993 | - | let strAssetIdB = $ | |
994 | - | let assetIdA = $ | |
995 | - | let assetIdB = $ | |
997 | + | let $t04038140457 = getPoolAssets(i.caller) | |
998 | + | let strAssetIdA = $t04038140457._1 | |
999 | + | let strAssetIdB = $t04038140457._2 | |
1000 | + | let assetIdA = $t04038140457._3 | |
1001 | + | let assetIdB = $t04038140457._4 | |
996 | 1002 | let claim = if (if ((assetIdA == USDN)) | |
997 | 1003 | then true | |
998 | 1004 | else (assetIdB == USDN)) | |
1000 | 1006 | else 0 | |
1001 | 1007 | if ((claim == claim)) | |
1002 | 1008 | then { | |
1003 | - | let $ | |
1004 | - | let balanceA = $ | |
1005 | - | let balanceB = $ | |
1006 | - | let accountBalanceA = $ | |
1007 | - | let accountBalanceB = $ | |
1009 | + | let $t04061740723 = getPoolBalances(i.caller, assetIdA, assetIdB) | |
1010 | + | let balanceA = $t04061740723._1 | |
1011 | + | let balanceB = $t04061740723._2 | |
1012 | + | let accountBalanceA = $t04061740723._3 | |
1013 | + | let accountBalanceB = $t04061740723._4 | |
1008 | 1014 | let amountEnrollA = (accountBalanceA - balanceA) | |
1009 | 1015 | let amountEnrollB = (accountBalanceB - balanceB) | |
1010 | 1016 | if ((size(args) != 0)) |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let version = "1.0.0" | |
5 | 5 | ||
6 | 6 | let kVersion = "version" | |
7 | 7 | ||
8 | 8 | let kActive = "active" | |
9 | 9 | ||
10 | 10 | let kDeprecated = "deprecated_" | |
11 | 11 | ||
12 | 12 | let kAssetIdA = "A_asset_id" | |
13 | 13 | ||
14 | 14 | let kAssetIdB = "B_asset_id" | |
15 | 15 | ||
16 | 16 | let kBalanceA = "A_asset_balance" | |
17 | 17 | ||
18 | 18 | let kBalanceB = "B_asset_balance" | |
19 | 19 | ||
20 | 20 | let kBalanceInitA = "A_asset_init" | |
21 | 21 | ||
22 | 22 | let kBalanceInitB = "B_asset_init" | |
23 | 23 | ||
24 | 24 | let kShareAssetId = "share_asset_id" | |
25 | 25 | ||
26 | 26 | let kShareAssetSupply = "share_asset_supply" | |
27 | 27 | ||
28 | 28 | let kFee = "commission" | |
29 | 29 | ||
30 | 30 | let kCause = "shutdown_cause" | |
31 | 31 | ||
32 | 32 | let kFirstHarvest = "first_harvest" | |
33 | 33 | ||
34 | 34 | let kFirstHarvestHeight = "first_harvest_height" | |
35 | 35 | ||
36 | 36 | let kShareLimit = "share_limit_on_first_harvest" | |
37 | 37 | ||
38 | 38 | let kBasePeriod = "base_period" | |
39 | 39 | ||
40 | 40 | let kPeriodLength = "period_length" | |
41 | 41 | ||
42 | 42 | let kStartHeight = "start_height" | |
43 | 43 | ||
44 | 44 | let kUSDNAddress = "staking_usdnnsbt_address" | |
45 | 45 | ||
46 | 46 | let kEURNAddress = "staking_eurn_address" | |
47 | 47 | ||
48 | 48 | let kLeasingAmount = "leasing_amount" | |
49 | 49 | ||
50 | 50 | let kUSDNAssetId = "usdn_asset_id" | |
51 | 51 | ||
52 | 52 | let kEURNAssetId = "eurn_asset_id" | |
53 | 53 | ||
54 | 54 | let kStakingAssets = "staking_assets" | |
55 | 55 | ||
56 | 56 | let kOracleActive = "active_all_contracts" | |
57 | 57 | ||
58 | 58 | let kDiscounts = "discounts" | |
59 | 59 | ||
60 | 60 | let kDiscountValues = "discount_values" | |
61 | 61 | ||
62 | 62 | let kUserGSwopInGov = "_GSwop_amount" | |
63 | 63 | ||
64 | 64 | let kUserSwopInGov = "_SWOP_amount" | |
65 | 65 | ||
66 | 66 | let kOraclePool = "pool_" | |
67 | 67 | ||
68 | 68 | let kAdminPubKey1 = "admin_pub_1" | |
69 | 69 | ||
70 | 70 | let kAdminPubKey2 = "admin_pub_2" | |
71 | 71 | ||
72 | 72 | let kAdminPubKey3 = "admin_pub_3" | |
73 | 73 | ||
74 | 74 | let kAdminInvokePubKey = "admin_invoke_pub" | |
75 | 75 | ||
76 | 76 | let kMoneyBoxAddress = "money_box_address" | |
77 | 77 | ||
78 | 78 | let kTeamBoxAddress = "team_box_address" | |
79 | 79 | ||
80 | 80 | let kVotingAddress = "voting_address" | |
81 | 81 | ||
82 | 82 | let kGovAddress = "governance_address" | |
83 | 83 | ||
84 | 84 | let kFarmingAddress = "farming_address" | |
85 | 85 | ||
86 | - | let oracle = Address(base58' | |
86 | + | let oracle = Address(base58'3PEbqViERCoKnmcSULh6n2aiMvUdSQdCsom') | |
87 | 87 | ||
88 | 88 | func getBase58FromOracle (key) = match getString(oracle, key) { | |
89 | 89 | case string: String => | |
90 | 90 | fromBase58String(string) | |
91 | 91 | case nothing => | |
92 | 92 | throw((key + "is empty")) | |
93 | 93 | } | |
94 | 94 | ||
95 | 95 | ||
96 | 96 | let adminPubKey1 = getBase58FromOracle(kAdminPubKey1) | |
97 | 97 | ||
98 | 98 | let adminPubKey2 = getBase58FromOracle(kAdminPubKey2) | |
99 | 99 | ||
100 | 100 | let adminPubKey3 = getBase58FromOracle(kAdminPubKey3) | |
101 | 101 | ||
102 | 102 | let adminInvokePubKey = getBase58FromOracle(kAdminInvokePubKey) | |
103 | 103 | ||
104 | 104 | let moneyBoxAddress = Address(getBase58FromOracle(kMoneyBoxAddress)) | |
105 | 105 | ||
106 | 106 | let teamBoxAddress = Address(getBase58FromOracle(kTeamBoxAddress)) | |
107 | 107 | ||
108 | 108 | let votingAddress = Address(getBase58FromOracle(kVotingAddress)) | |
109 | 109 | ||
110 | 110 | let govAddress = Address(getBase58FromOracle(kGovAddress)) | |
111 | 111 | ||
112 | 112 | let farmingAddress = Address(getBase58FromOracle(kFarmingAddress)) | |
113 | 113 | ||
114 | 114 | let USDN = getBase58FromOracle(kUSDNAssetId) | |
115 | 115 | ||
116 | 116 | let EURN = getBase58FromOracle(kEURNAssetId) | |
117 | 117 | ||
118 | 118 | let stakingAssets = getStringValue(oracle, kStakingAssets) | |
119 | 119 | ||
120 | 120 | let stakingUSDNAddress = Address(getBase58FromOracle(kUSDNAddress)) | |
121 | 121 | ||
122 | 122 | let stakingEURNAddress = Address(getBase58FromOracle(kEURNAddress)) | |
123 | 123 | ||
124 | 124 | let basePeriod = valueOrErrorMessage(getInteger(votingAddress, kBasePeriod), "Empty kBasePeriod") | |
125 | 125 | ||
126 | 126 | let startHeight = valueOrErrorMessage(getInteger(votingAddress, kStartHeight), "Empty kStartHeight") | |
127 | 127 | ||
128 | 128 | let periodLength = valueOrErrorMessage(getInteger(votingAddress, kPeriodLength), "Empty kPeriodLength") | |
129 | 129 | ||
130 | 130 | let firstHarvestEndPeriod = ((basePeriod + ((height - startHeight) / periodLength)) + 3) | |
131 | 131 | ||
132 | 132 | let active = getBooleanValue(oracle, kOracleActive) | |
133 | 133 | ||
134 | 134 | let feeScale6 = 1000000 | |
135 | 135 | ||
136 | 136 | let scale8 = 100000000 | |
137 | 137 | ||
138 | 138 | let scale16 = toBigInt(10000000000000000) | |
139 | 139 | ||
140 | 140 | func accountBalance (assetId,pool) = match assetId { | |
141 | 141 | case id: ByteVector => | |
142 | 142 | assetBalance(pool, id) | |
143 | 143 | case waves: Unit => | |
144 | 144 | wavesBalance(pool).available | |
145 | 145 | case _ => | |
146 | 146 | throw("Match error") | |
147 | 147 | } | |
148 | 148 | ||
149 | 149 | ||
150 | 150 | func stakedAmount (assetId,pool) = { | |
151 | 151 | let stakedAmountCalculated = match assetId { | |
152 | 152 | case aId: ByteVector => | |
153 | 153 | if ((aId == USDN)) | |
154 | 154 | then getInteger(stakingUSDNAddress, ((("rpd_balance_" + toBase58String(aId)) + "_") + toString(pool))) | |
155 | 155 | else if ((aId == EURN)) | |
156 | 156 | then getInteger(stakingEURNAddress, ((("%s%s%s__stakingBalance__" + toBase58String(aId)) + "__") + toString(pool))) | |
157 | 157 | else 0 | |
158 | 158 | case _: Unit => | |
159 | 159 | valueOrElse(getInteger(pool, kLeasingAmount), 0) | |
160 | 160 | case _ => | |
161 | 161 | throw("Match error") | |
162 | 162 | } | |
163 | 163 | match stakedAmountCalculated { | |
164 | 164 | case i: Int => | |
165 | 165 | i | |
166 | 166 | case _ => | |
167 | 167 | 0 | |
168 | 168 | } | |
169 | 169 | } | |
170 | 170 | ||
171 | 171 | ||
172 | 172 | func getAssetInfo (assetId) = match assetId { | |
173 | 173 | case id: String|ByteVector => | |
174 | 174 | let $t040794251 = match id { | |
175 | 175 | case aId: ByteVector => | |
176 | 176 | $Tuple2(toBase58String(aId), aId) | |
177 | 177 | case aId: String => | |
178 | 178 | $Tuple2(aId, fromBase58String(aId)) | |
179 | 179 | case _ => | |
180 | 180 | throw("Match error") | |
181 | 181 | } | |
182 | 182 | let stringId = $t040794251._1 | |
183 | 183 | let bytesId = $t040794251._2 | |
184 | 184 | let info = valueOrErrorMessage(assetInfo(bytesId), (("Asset " + stringId) + " doesn't exist")) | |
185 | 185 | $Tuple3(stringId, info.name, info.decimals) | |
186 | 186 | case waves: Unit => | |
187 | 187 | $Tuple3("WAVES", "WAVES", 8) | |
188 | 188 | case _ => | |
189 | 189 | throw("Match error") | |
190 | 190 | } | |
191 | 191 | ||
192 | 192 | ||
193 | 193 | func suspend (cause) = [BooleanEntry(kActive, false), StringEntry(kCause, cause)] | |
194 | 194 | ||
195 | 195 | ||
196 | 196 | func calculateFeeDiscount (userAddr) = { | |
197 | 197 | let swopAmount = valueOrElse(getInteger(govAddress, (toString(userAddr) + kUserSwopInGov)), 0) | |
198 | 198 | let gSwopAmount = valueOrElse(getInteger(govAddress, (toString(userAddr) + kUserGSwopInGov)), swopAmount) | |
199 | 199 | let discountValues = split(getStringValue(oracle, kDiscountValues), ",") | |
200 | 200 | let discounts = split(getStringValue(oracle, kDiscounts), ",") | |
201 | 201 | if (if ((gSwopAmount >= parseIntValue(discountValues[0]))) | |
202 | 202 | then (parseIntValue(discountValues[1]) > gSwopAmount) | |
203 | 203 | else false) | |
204 | 204 | then (feeScale6 - parseIntValue(discounts[0])) | |
205 | 205 | else if (if ((gSwopAmount >= parseIntValue(discountValues[1]))) | |
206 | 206 | then (parseIntValue(discountValues[2]) > gSwopAmount) | |
207 | 207 | else false) | |
208 | 208 | then (feeScale6 - parseIntValue(discounts[1])) | |
209 | 209 | else if (if ((gSwopAmount >= parseIntValue(discountValues[2]))) | |
210 | 210 | then (parseIntValue(discountValues[3]) > gSwopAmount) | |
211 | 211 | else false) | |
212 | 212 | then (feeScale6 - parseIntValue(discounts[2])) | |
213 | 213 | else if (if ((gSwopAmount >= parseIntValue(discountValues[3]))) | |
214 | 214 | then (parseIntValue(discountValues[4]) > gSwopAmount) | |
215 | 215 | else false) | |
216 | 216 | then (feeScale6 - parseIntValue(discounts[3])) | |
217 | 217 | else if ((gSwopAmount >= parseIntValue(discountValues[4]))) | |
218 | 218 | then (feeScale6 - parseIntValue(discounts[4])) | |
219 | 219 | else feeScale6 | |
220 | 220 | } | |
221 | 221 | ||
222 | 222 | ||
223 | 223 | func calculateFees (pmtAmount,minAmountToReceive,tokenFrom,tokenTo,fee,feeGov,feeTeam) = { | |
224 | 224 | let amountWithoutFee = fraction(tokenTo, pmtAmount, (pmtAmount + tokenFrom)) | |
225 | 225 | let amountWithFee = fraction(amountWithoutFee, (feeScale6 - fee), feeScale6) | |
226 | 226 | let governanceReward = fraction(amountWithoutFee, feeGov, feeScale6) | |
227 | 227 | let teamReward = fraction(amountWithoutFee, feeTeam, feeScale6) | |
228 | 228 | if ((minAmountToReceive > amountWithFee)) | |
229 | 229 | then throw(((("Calculated amount to receive " + toString(amountWithFee)) + " is less than specified minimum ") + toString(minAmountToReceive))) | |
230 | 230 | else $Tuple4(amountWithoutFee, amountWithFee, governanceReward, teamReward) | |
231 | 231 | } | |
232 | 232 | ||
233 | 233 | ||
234 | 234 | func calculateVirtPay (pmtAmount,balance,fee) = { | |
235 | 235 | let F = (feeScale6 - fee) | |
236 | 236 | let k = fraction(fee, 55, 100) | |
237 | 237 | let a = (scale8 + fraction((F * k), scale8, (feeScale6 * feeScale6))) | |
238 | 238 | let b = ((((balance + fraction(balance, F, feeScale6)) + fraction(pmtAmount, F, feeScale6)) - pmtAmount) - fraction(pmtAmount, (F * k), (feeScale6 * feeScale6))) | |
239 | 239 | let c = (-(toBigInt(balance)) * toBigInt(pmtAmount)) | |
240 | 240 | let D = ((toBigInt(b) * toBigInt(b)) - fraction((toBigInt(4) * c), toBigInt(a), toBigInt(scale8))) | |
241 | 241 | toInt(fraction((-(toBigInt(b)) + sqrtBigInt(D, 0, 0, DOWN)), toBigInt(scale8), toBigInt((2 * a)))) | |
242 | 242 | } | |
243 | 243 | ||
244 | 244 | ||
245 | 245 | func parsePaymentAsset (assetId) = if ((assetId == base58'')) | |
246 | 246 | then unit | |
247 | 247 | else assetId | |
248 | 248 | ||
249 | 249 | ||
250 | 250 | func suspendSuspicious (accountBalanceA,accountBalanceB,balanceA,balanceB,assetIdA,assetIdB) = suspend(((((((((((((((("Suspicious state. Actual balances: " + toString(accountBalanceA)) + " ") + assetIdA) + ", ") + toString(accountBalanceB)) + " ") + assetIdB) + ". State: ") + toString(balanceA)) + " ") + assetIdA) + ", ") + toString(balanceB)) + " ") + assetIdB)) | |
251 | 251 | ||
252 | 252 | ||
253 | 253 | func isActive () = if (active) | |
254 | 254 | then unit | |
255 | 255 | else throw("DApp is inactive at this moment") | |
256 | 256 | ||
257 | 257 | ||
258 | 258 | func isOraclePool (poolAddress) = if (isDefined(getString(oracle, (kOraclePool + poolAddress)))) | |
259 | 259 | then unit | |
260 | 260 | else throw("DApp is not registered pool") | |
261 | 261 | ||
262 | 262 | ||
263 | 263 | func isDepricated (poolAddress) = if (!(valueOrElse(getBoolean(oracle, (kDeprecated + poolAddress)), false))) | |
264 | 264 | then unit | |
265 | 265 | else throw("Pool is deprecated. Only withdraw action allowed.") | |
266 | 266 | ||
267 | 267 | ||
268 | 268 | func getPoolBalances (pool,assetIdA,assetIdB) = { | |
269 | 269 | let balanceA = getIntegerValue(pool, kBalanceA) | |
270 | 270 | let balanceB = getIntegerValue(pool, kBalanceB) | |
271 | 271 | let stakedAmountA = stakedAmount(assetIdA, pool) | |
272 | 272 | let stakedAmountB = stakedAmount(assetIdB, pool) | |
273 | 273 | let accountBalanceA = (accountBalance(assetIdA, pool) + stakedAmountA) | |
274 | 274 | let accountBalanceB = (accountBalance(assetIdB, pool) + stakedAmountB) | |
275 | 275 | let shareSupply = getIntegerValue(pool, kShareAssetSupply) | |
276 | 276 | $Tuple5(balanceA, balanceB, accountBalanceA, accountBalanceB, shareSupply) | |
277 | 277 | } | |
278 | 278 | ||
279 | 279 | ||
280 | 280 | func getPoolAssets (pool) = { | |
281 | 281 | let strAssetIdA = getStringValue(pool, kAssetIdA) | |
282 | 282 | let strAssetIdB = getStringValue(pool, kAssetIdB) | |
283 | 283 | let assetIdA = if ((strAssetIdA == "WAVES")) | |
284 | 284 | then unit | |
285 | 285 | else fromBase58String(strAssetIdA) | |
286 | 286 | let assetIdB = if ((strAssetIdB == "WAVES")) | |
287 | 287 | then unit | |
288 | 288 | else fromBase58String(strAssetIdB) | |
289 | 289 | let shareAssetId = fromBase58String(getStringValue(pool, kShareAssetId)) | |
290 | 290 | $Tuple5(strAssetIdA, strAssetIdB, assetIdA, assetIdB, shareAssetId) | |
291 | 291 | } | |
292 | 292 | ||
293 | 293 | ||
294 | 294 | func getFeeParams (pool,caller) = { | |
295 | 295 | let feeDiscount = calculateFeeDiscount(caller) | |
296 | 296 | let fee = fraction(getIntegerValue(pool, kFee), feeDiscount, feeScale6, CEILING) | |
297 | 297 | let govFee = fraction(fee, 35, 100) | |
298 | 298 | let teamFee = fraction(fee, 10, 100) | |
299 | 299 | $Tuple3(fee, govFee, teamFee) | |
300 | 300 | } | |
301 | 301 | ||
302 | 302 | ||
303 | 303 | func calcLPAmountReplensishTwoTokens (pmtA,pmtB,pmtIdA,pmtIdB,balA,balB,shareAssetSupply) = { | |
304 | 304 | let $t095629634 = getAssetInfo(pmtIdA) | |
305 | 305 | let pmtStrAssetIdA = $t095629634._1 | |
306 | 306 | let pmtAssetNameA = $t095629634._2 | |
307 | 307 | let pmtDecimalsA = $t095629634._3 | |
308 | 308 | let $t096399711 = getAssetInfo(pmtIdB) | |
309 | 309 | let pmtStrAssetIdB = $t096399711._1 | |
310 | 310 | let pmtAssetNameB = $t096399711._2 | |
311 | 311 | let pmtDecimalsB = $t096399711._3 | |
312 | 312 | let initial = ((balA + balB) == 0) | |
313 | 313 | let $t0975410413 = if (initial) | |
314 | 314 | then $Tuple5(pmtA, pmtB, 0, pmtIdA, toBigInt(1)) | |
315 | 315 | else { | |
316 | 316 | let ratioShareTokensInA = fraction(scale16, toBigInt(pmtA), toBigInt(balA)) | |
317 | 317 | let ratioShareTokensInB = fraction(scale16, toBigInt(pmtB), toBigInt(balB)) | |
318 | 318 | if ((ratioShareTokensInB > ratioShareTokensInA)) | |
319 | 319 | then { | |
320 | 320 | let pmt = fraction(pmtA, balB, balA) | |
321 | 321 | $Tuple5(pmtA, pmt, (pmtB - pmt), pmtIdB, ratioShareTokensInA) | |
322 | 322 | } | |
323 | 323 | else { | |
324 | 324 | let pmt = fraction(pmtB, balA, balB) | |
325 | 325 | $Tuple5(pmt, pmtB, (pmtA - pmt), pmtIdA, ratioShareTokensInB) | |
326 | 326 | } | |
327 | 327 | } | |
328 | 328 | let pmtAmountA = $t0975410413._1 | |
329 | 329 | let pmtAmountB = $t0975410413._2 | |
330 | 330 | let change = $t0975410413._3 | |
331 | 331 | let changeAssetId = $t0975410413._4 | |
332 | 332 | let shareTokenRatio = $t0975410413._5 | |
333 | 333 | let shareTokenToPayAmount = if (initial) | |
334 | 334 | then { | |
335 | 335 | let shareDecimals = ((pmtDecimalsA + pmtDecimalsB) / 2) | |
336 | 336 | fraction(pow(pmtAmountA, pmtDecimalsA, 5, 1, pmtDecimalsA, DOWN), pow(pmtAmountB, pmtDecimalsB, 5, 1, pmtDecimalsB, DOWN), pow(10, 0, shareDecimals, 0, 0, DOWN)) | |
337 | 337 | } | |
338 | 338 | else toInt(fraction(shareTokenRatio, toBigInt(shareAssetSupply), scale16)) | |
339 | 339 | $Tuple5(shareTokenToPayAmount, change, changeAssetId, pmtAmountA, pmtAmountB) | |
340 | 340 | } | |
341 | 341 | ||
342 | 342 | ||
343 | 343 | func calcLPAmountReplansishOneToken (pmtAmount,pmtAssetId,aId,bId,balA,balB,lpSupply,fee,govFee,teamFee,virtGetMinAmount) = if ((pmtAssetId == aId)) | |
344 | 344 | then { | |
345 | 345 | let virtPayAmount = calculateVirtPay(pmtAmount, balA, fee) | |
346 | - | let $ | |
347 | - | let amountWithoutFee = $ | |
348 | - | let amountWithFee = $ | |
349 | - | let governanceReward = $ | |
350 | - | let tReward = $ | |
346 | + | let $t01127811425 = calculateFees(virtPayAmount, virtGetMinAmount, balA, balB, fee, govFee, teamFee) | |
347 | + | let amountWithoutFee = $t01127811425._1 | |
348 | + | let amountWithFee = $t01127811425._2 | |
349 | + | let governanceReward = $t01127811425._3 | |
350 | + | let tReward = $t01127811425._4 | |
351 | 351 | let balanceAVirt = (balA + virtPayAmount) | |
352 | 352 | let balanceBVirt = (((balB + amountWithoutFee) - governanceReward) - tReward) | |
353 | 353 | let newBalanceA = (balA + pmtAmount) | |
354 | 354 | let newBalanceB = ((balB - governanceReward) - tReward) | |
355 | 355 | let ratioShareTokensInA = fraction(toBigInt((pmtAmount - virtPayAmount)), scale16, toBigInt(balanceAVirt)) | |
356 | 356 | let ratioShareTokensInB = fraction(toBigInt(amountWithFee), scale16, toBigInt(balanceBVirt)) | |
357 | 357 | let shareTokenToPayAmount = toInt(fraction(min([ratioShareTokensInA, ratioShareTokensInB]), toBigInt(lpSupply), scale16)) | |
358 | - | $Tuple6(shareTokenToPayAmount, newBalanceA, newBalanceB, governanceReward, tReward, bId) | |
358 | + | let shareTokenToPayAmountInBoth = toInt(fraction(fraction(toBigInt(pmtAmount), scale16, toBigInt(balA)), toBigInt(lpSupply), scale16)) | |
359 | + | let loss = fraction((shareTokenToPayAmount - shareTokenToPayAmountInBoth), scale8, shareTokenToPayAmountInBoth) | |
360 | + | $Tuple7(shareTokenToPayAmount, newBalanceA, newBalanceB, governanceReward, tReward, bId, loss) | |
359 | 361 | } | |
360 | 362 | else { | |
361 | 363 | let virtPayAmount = calculateVirtPay(pmtAmount, balB, fee) | |
362 | - | let $ | |
363 | - | let amountWithoutFee = $ | |
364 | - | let amountWithFee = $ | |
365 | - | let governanceReward = $ | |
366 | - | let tReward = $ | |
364 | + | let $t01245112598 = calculateFees(virtPayAmount, virtGetMinAmount, balB, balA, fee, govFee, teamFee) | |
365 | + | let amountWithoutFee = $t01245112598._1 | |
366 | + | let amountWithFee = $t01245112598._2 | |
367 | + | let governanceReward = $t01245112598._3 | |
368 | + | let tReward = $t01245112598._4 | |
367 | 369 | let balanceAVirt = (((balA + amountWithoutFee) - governanceReward) - tReward) | |
368 | 370 | let balanceBVirt = (balB + virtPayAmount) | |
369 | 371 | let newBalanceA = ((balA - governanceReward) - tReward) | |
370 | 372 | let newBalanceB = (balB + pmtAmount) | |
371 | 373 | let ratioShareTokensInA = fraction(toBigInt(amountWithFee), scale16, toBigInt(balanceAVirt)) | |
372 | 374 | let ratioShareTokensInB = fraction(toBigInt((pmtAmount - virtPayAmount)), scale16, toBigInt(balanceBVirt)) | |
373 | 375 | let shareTokenToPayAmount = toInt(fraction(min([ratioShareTokensInA, ratioShareTokensInB]), toBigInt(lpSupply), scale16)) | |
374 | - | $Tuple6(shareTokenToPayAmount, newBalanceA, newBalanceB, governanceReward, tReward, aId) | |
376 | + | let shareTokenToPayAmountInBoth = toInt(fraction(fraction(toBigInt(pmtAmount), scale16, toBigInt(balB)), toBigInt(lpSupply), scale16)) | |
377 | + | let loss = fraction((shareTokenToPayAmount - shareTokenToPayAmountInBoth), scale8, shareTokenToPayAmountInBoth) | |
378 | + | $Tuple7(shareTokenToPayAmount, newBalanceA, newBalanceB, governanceReward, tReward, aId, loss) | |
375 | 379 | } | |
376 | 380 | ||
377 | 381 | ||
378 | 382 | func calcLPReplenishDiffProp (pmtA,pmtB,pmtIdA,pmtIdB,balA,balB,lpSupply,fee,govFee,teamFee,virtGetMinAmount) = { | |
379 | - | let $ | |
380 | - | let lpTwoAmount = $ | |
381 | - | let change = $ | |
382 | - | let changeAssetId = $ | |
383 | - | let pmtAmountA = $ | |
384 | - | let pmtAmountB = $ | |
383 | + | let $t01374713895 = calcLPAmountReplensishTwoTokens(pmtA, pmtB, pmtIdA, pmtIdB, balA, balB, lpSupply) | |
384 | + | let lpTwoAmount = $t01374713895._1 | |
385 | + | let change = $t01374713895._2 | |
386 | + | let changeAssetId = $t01374713895._3 | |
387 | + | let pmtAmountA = $t01374713895._4 | |
388 | + | let pmtAmountB = $t01374713895._5 | |
385 | 389 | if ((change > 0)) | |
386 | 390 | then { | |
387 | - | let $t01330313532 = calcLPAmountReplansishOneToken(change, changeAssetId, pmtIdA, pmtIdB, (balA + pmtAmountA), (balB + pmtAmountB), lpSupply, fee, govFee, teamFee, virtGetMinAmount) | |
388 | - | let lpOne = $t01330313532._1 | |
389 | - | let newBalanceA = $t01330313532._2 | |
390 | - | let newBalanceB = $t01330313532._3 | |
391 | - | let governanceReward = $t01330313532._4 | |
392 | - | let tReward = $t01330313532._5 | |
393 | - | let gId = $t01330313532._6 | |
394 | - | $Tuple6((lpTwoAmount + lpOne), newBalanceA, newBalanceB, governanceReward, tReward, gId) | |
391 | + | let $t01392714162 = calcLPAmountReplansishOneToken(change, changeAssetId, pmtIdA, pmtIdB, (balA + pmtAmountA), (balB + pmtAmountB), lpSupply, fee, govFee, teamFee, virtGetMinAmount) | |
392 | + | let lpOne = $t01392714162._1 | |
393 | + | let newBalanceA = $t01392714162._2 | |
394 | + | let newBalanceB = $t01392714162._3 | |
395 | + | let governanceReward = $t01392714162._4 | |
396 | + | let tReward = $t01392714162._5 | |
397 | + | let gId = $t01392714162._6 | |
398 | + | let loss = $t01392714162._7 | |
399 | + | $Tuple7((lpTwoAmount + lpOne), loss, newBalanceA, newBalanceB, governanceReward, tReward, gId) | |
395 | 400 | } | |
396 | - | else $ | |
401 | + | else $Tuple7(lpTwoAmount, 0, (balA + pmtAmountA), (balB + pmtAmountB), 0, 0, unit) | |
397 | 402 | } | |
398 | 403 | ||
399 | 404 | ||
400 | 405 | @Callable(i) | |
401 | 406 | func calcLPReplenishDiffPropREADONLY (callerBytes,args,pAmounts,pAssetIds) = { | |
402 | - | let $ | |
403 | - | let strAssetIdA = $ | |
404 | - | let strAssetIdB = $ | |
405 | - | let assetIdA = $ | |
406 | - | let assetIdB = $ | |
407 | - | let shareAssetId = $ | |
408 | - | let $ | |
409 | - | let balA = $ | |
410 | - | let balB = $ | |
411 | - | let accBalA = $ | |
412 | - | let accBalB = $ | |
413 | - | let lpSupply = $ | |
407 | + | let $t01449814588 = getPoolAssets(i.caller) | |
408 | + | let strAssetIdA = $t01449814588._1 | |
409 | + | let strAssetIdB = $t01449814588._2 | |
410 | + | let assetIdA = $t01449814588._3 | |
411 | + | let assetIdB = $t01449814588._4 | |
412 | + | let shareAssetId = $t01449814588._5 | |
413 | + | let $t01459314685 = getPoolBalances(i.caller, assetIdA, assetIdB) | |
414 | + | let balA = $t01459314685._1 | |
415 | + | let balB = $t01459314685._2 | |
416 | + | let accBalA = $t01459314685._3 | |
417 | + | let accBalB = $t01459314685._4 | |
418 | + | let lpSupply = $t01459314685._5 | |
414 | 419 | let pmtA = parseIntValue(args[0]) | |
415 | 420 | let pmtB = parseIntValue(args[1]) | |
416 | 421 | let virtGetMinAmount = parseIntValue(args[2]) | |
417 | - | let $t01418014247 = getFeeParams(i.caller, i.originCaller) | |
418 | - | let fee = $t01418014247._1 | |
419 | - | let govFee = $t01418014247._2 | |
420 | - | let teamFee = $t01418014247._3 | |
421 | - | let $t01425214438 = calcLPReplenishDiffProp(pmtA, pmtB, assetIdA, assetIdB, balA, balB, lpSupply, fee, govFee, teamFee, virtGetMinAmount) | |
422 | - | let lp = $t01425214438._1 | |
423 | - | let newBalanceA = $t01425214438._2 | |
424 | - | let newBalanceB = $t01425214438._3 | |
425 | - | let governanceReward = $t01425214438._4 | |
426 | - | let tReward = $t01425214438._5 | |
427 | - | let aId = $t01425214438._6 | |
428 | - | $Tuple2(nil, $Tuple2(nil, [lp, newBalanceA, newBalanceB, governanceReward, tReward, aId])) | |
422 | + | let $t01481914886 = getFeeParams(i.caller, i.originCaller) | |
423 | + | let fee = $t01481914886._1 | |
424 | + | let govFee = $t01481914886._2 | |
425 | + | let teamFee = $t01481914886._3 | |
426 | + | let $t01489115083 = calcLPReplenishDiffProp(pmtA, pmtB, assetIdA, assetIdB, balA, balB, lpSupply, fee, govFee, teamFee, virtGetMinAmount) | |
427 | + | let lp = $t01489115083._1 | |
428 | + | let loss = $t01489115083._2 | |
429 | + | let newBalanceA = $t01489115083._3 | |
430 | + | let newBalanceB = $t01489115083._4 | |
431 | + | let governanceReward = $t01489115083._5 | |
432 | + | let tReward = $t01489115083._6 | |
433 | + | let aId = $t01489115083._7 | |
434 | + | $Tuple2(nil, $Tuple2(nil, [lp, loss, newBalanceA, newBalanceB, governanceReward, tReward, aId])) | |
429 | 435 | } | |
430 | 436 | ||
431 | 437 | ||
432 | 438 | ||
433 | 439 | @Callable(i) | |
434 | 440 | func withdrawREADONLY (callerBytes,args,pAmounts,pAssetIds) = { | |
435 | - | let $ | |
436 | - | let strAssetIdA = $ | |
437 | - | let strAssetIdB = $ | |
438 | - | let assetIdA = $ | |
439 | - | let assetIdB = $ | |
440 | - | let shareAssetId = $ | |
441 | - | let $ | |
442 | - | let balanceA = $ | |
443 | - | let balanceB = $ | |
444 | - | let accountBalanceA = $ | |
445 | - | let accountBalanceB = $ | |
446 | - | let shareAssetSupply = $ | |
441 | + | let $t01531015400 = getPoolAssets(i.caller) | |
442 | + | let strAssetIdA = $t01531015400._1 | |
443 | + | let strAssetIdB = $t01531015400._2 | |
444 | + | let assetIdA = $t01531015400._3 | |
445 | + | let assetIdB = $t01531015400._4 | |
446 | + | let shareAssetId = $t01531015400._5 | |
447 | + | let $t01540515529 = getPoolBalances(i.caller, assetIdA, assetIdB) | |
448 | + | let balanceA = $t01540515529._1 | |
449 | + | let balanceB = $t01540515529._2 | |
450 | + | let accountBalanceA = $t01540515529._3 | |
451 | + | let accountBalanceB = $t01540515529._4 | |
452 | + | let shareAssetSupply = $t01540515529._5 | |
447 | 453 | let withdrawAmount = parseIntValue(args[0]) | |
448 | - | let $ | |
454 | + | let $t01558315745 = if ((size(args) == 3)) | |
449 | 455 | then $Tuple2(parseIntValue(args[1]), parseIntValue(args[2])) | |
450 | 456 | else $Tuple2(balanceA, balanceB) | |
451 | - | let balA = $ | |
452 | - | let balB = $ | |
457 | + | let balA = $t01558315745._1 | |
458 | + | let balB = $t01558315745._2 | |
453 | 459 | let amountToPayA = fraction(withdrawAmount, balA, shareAssetSupply) | |
454 | 460 | let amountToPayB = fraction(withdrawAmount, balB, shareAssetSupply) | |
455 | 461 | $Tuple2(nil, $Tuple2(nil, [amountToPayA, amountToPayB])) | |
456 | 462 | } | |
457 | 463 | ||
458 | 464 | ||
459 | 465 | ||
460 | 466 | @Callable(i) | |
461 | 467 | func init (callerBytes,args,pAmounts,pAssetIds) = { | |
462 | 468 | let caller = Address(callerBytes) | |
463 | - | let $ | |
464 | - | let pmtAmountA = $ | |
465 | - | let pmtAssetIdA = $ | |
466 | - | let $ | |
467 | - | let pmtAmountB = $ | |
468 | - | let pmtAssetIdB = $ | |
469 | + | let $t01610016178 = $Tuple2(pAmounts[0], parsePaymentAsset(pAssetIds[0])) | |
470 | + | let pmtAmountA = $t01610016178._1 | |
471 | + | let pmtAssetIdA = $t01610016178._2 | |
472 | + | let $t01618316261 = $Tuple2(pAmounts[1], parsePaymentAsset(pAssetIds[1])) | |
473 | + | let pmtAmountB = $t01618316261._1 | |
474 | + | let pmtAssetIdB = $t01618316261._2 | |
469 | 475 | if (!(containsElement([adminPubKey1, adminPubKey2, adminPubKey3, adminInvokePubKey], i.originCallerPublicKey))) | |
470 | 476 | then throw("Only admin can call this function") | |
471 | 477 | else if ((size(args) != 1)) | |
472 | 478 | then throw("Wrong args size") | |
473 | 479 | else if (isDefined(getBoolean(caller, kActive))) | |
474 | 480 | then throw("DApp is already active") | |
475 | 481 | else if ((pmtAssetIdA == pmtAssetIdB)) | |
476 | 482 | then throw("Assets must be different") | |
477 | 483 | else { | |
478 | - | let $ | |
479 | - | let pmtStrAssetIdA = $ | |
480 | - | let pmtAssetNameA = $ | |
481 | - | let pmtDecimalsA = $ | |
482 | - | let $ | |
483 | - | let pmtStrAssetIdB = $ | |
484 | - | let pmtAssetNameB = $ | |
485 | - | let pmtDecimalsB = $ | |
484 | + | let $t01669616773 = getAssetInfo(pmtAssetIdA) | |
485 | + | let pmtStrAssetIdA = $t01669616773._1 | |
486 | + | let pmtAssetNameA = $t01669616773._2 | |
487 | + | let pmtDecimalsA = $t01669616773._3 | |
488 | + | let $t01678216859 = getAssetInfo(pmtAssetIdB) | |
489 | + | let pmtStrAssetIdB = $t01678216859._1 | |
490 | + | let pmtAssetNameB = $t01678216859._2 | |
491 | + | let pmtDecimalsB = $t01678216859._3 | |
486 | 492 | let firstHarvest = (args[0] == "true") | |
487 | 493 | let shareName = ((("s" + take(pmtAssetNameA, 7)) + "_") + take(pmtAssetNameB, 7)) | |
488 | 494 | let shareDescription = ((((("ShareToken of SwopFi protocol for " + pmtAssetNameA) + " and ") + pmtAssetNameB) + " at address ") + toString(this)) | |
489 | 495 | let shareDecimals = ((pmtDecimalsA + pmtDecimalsB) / 2) | |
490 | 496 | let arg1 = pow(pmtAmountA, pmtDecimalsA, 5, 1, pmtDecimalsA, DOWN) | |
491 | 497 | let arg2 = pow(pmtAmountB, pmtDecimalsB, 5, 1, pmtDecimalsB, DOWN) | |
492 | 498 | let arg3 = pow(10, 0, shareDecimals, 0, 0, DOWN) | |
493 | 499 | let shareInitialSupply = fraction(arg1, arg2, arg3) | |
494 | 500 | let shareIssue = Issue(shareName, shareDescription, shareInitialSupply, shareDecimals, true) | |
495 | 501 | let shareIssueId = calculateAssetId(shareIssue) | |
496 | 502 | let stake1 = if (contains(stakingAssets, pmtStrAssetIdA)) | |
497 | 503 | then invoke(i.caller, "stakeUnstake", [true, pmtAmountA, pmtStrAssetIdA], nil) | |
498 | 504 | else 0 | |
499 | 505 | if ((stake1 == stake1)) | |
500 | 506 | then { | |
501 | 507 | let stake2 = if (contains(stakingAssets, pmtStrAssetIdB)) | |
502 | 508 | then invoke(i.caller, "stakeUnstake", [true, pmtAmountB, pmtStrAssetIdB], nil) | |
503 | 509 | else 0 | |
504 | 510 | if ((stake2 == stake2)) | |
505 | 511 | then { | |
506 | 512 | let baseEntry = [StringEntry(kVersion, version), BooleanEntry(kActive, true), StringEntry(kAssetIdA, pmtStrAssetIdA), StringEntry(kAssetIdB, pmtStrAssetIdB), IntegerEntry(kBalanceA, pmtAmountA), IntegerEntry(kBalanceB, pmtAmountB), IntegerEntry(kFee, getIntegerValue(oracle, "base_fee_cpmm")), shareIssue, StringEntry(kShareAssetId, toBase58String(shareIssueId)), IntegerEntry(kShareAssetSupply, shareInitialSupply), ScriptTransfer(caller, shareInitialSupply, shareIssueId)] | |
507 | 513 | if (firstHarvest) | |
508 | 514 | then $Tuple2(nil, $Tuple2((baseEntry ++ [BooleanEntry(kFirstHarvest, firstHarvest), IntegerEntry(kFirstHarvestHeight, (startHeight + (firstHarvestEndPeriod * periodLength)))]), nil)) | |
509 | 515 | else $Tuple2(nil, $Tuple2(baseEntry, nil)) | |
510 | 516 | } | |
511 | 517 | else throw("Strict value is not equal to itself.") | |
512 | 518 | } | |
513 | 519 | else throw("Strict value is not equal to itself.") | |
514 | 520 | } | |
515 | 521 | } | |
516 | 522 | ||
517 | 523 | ||
518 | 524 | ||
519 | 525 | @Callable(i) | |
520 | 526 | func initWithInitRatio (callerBytes,args,pAmounts,pAssetIds) = { | |
521 | 527 | let caller = Address(callerBytes) | |
522 | - | let $ | |
523 | - | let amtAssetA = $ | |
524 | - | let amtAssetB = $ | |
525 | - | let assetIdAStr = $ | |
526 | - | let assetIdBStr = $ | |
527 | - | let firstHarvest = $ | |
528 | + | let $t01908019280 = $Tuple5(parseIntValue(args[0]), parseIntValue(args[1]), args[2], args[3], (args[4] == "true")) | |
529 | + | let amtAssetA = $t01908019280._1 | |
530 | + | let amtAssetB = $t01908019280._2 | |
531 | + | let assetIdAStr = $t01908019280._3 | |
532 | + | let assetIdBStr = $t01908019280._4 | |
533 | + | let firstHarvest = $t01908019280._5 | |
528 | 534 | if (!(containsElement([adminPubKey1, adminPubKey2, adminPubKey3, adminInvokePubKey], i.originCallerPublicKey))) | |
529 | 535 | then throw("Only admin can call this function") | |
530 | 536 | else if ((size(args) != 5)) | |
531 | 537 | then throw("Wrong args size") | |
532 | 538 | else if (isDefined(getBoolean(caller, kActive))) | |
533 | 539 | then throw("DApp is already active") | |
534 | 540 | else if ((assetIdAStr == assetIdBStr)) | |
535 | 541 | then throw("Assets must be different") | |
536 | 542 | else { | |
537 | - | let $ | |
538 | - | let pmtStrAssetIdA = $ | |
539 | - | let pmtAssetNameA = $ | |
540 | - | let pmtDecimalsA = $ | |
541 | - | let $ | |
542 | - | let pmtStrAssetIdB = $ | |
543 | - | let pmtAssetNameB = $ | |
544 | - | let pmtDecimalsB = $ | |
543 | + | let $t01971519792 = getAssetInfo(assetIdAStr) | |
544 | + | let pmtStrAssetIdA = $t01971519792._1 | |
545 | + | let pmtAssetNameA = $t01971519792._2 | |
546 | + | let pmtDecimalsA = $t01971519792._3 | |
547 | + | let $t01980119878 = getAssetInfo(assetIdBStr) | |
548 | + | let pmtStrAssetIdB = $t01980119878._1 | |
549 | + | let pmtAssetNameB = $t01980119878._2 | |
550 | + | let pmtDecimalsB = $t01980119878._3 | |
545 | 551 | let shareName = ((("s" + take(pmtAssetNameA, 7)) + "_") + take(pmtAssetNameB, 7)) | |
546 | 552 | let shareDescription = ((((("ShareToken of SwopFi protocol for " + pmtAssetNameA) + " and ") + pmtAssetNameB) + " at address ") + toString(this)) | |
547 | 553 | let shareDecimals = ((pmtDecimalsA + pmtDecimalsB) / 2) | |
548 | 554 | let shareInitialSupply = 0 | |
549 | 555 | let shareIssue = Issue(shareName, shareDescription, shareInitialSupply, shareDecimals, true) | |
550 | 556 | let shareIssueId = calculateAssetId(shareIssue) | |
551 | 557 | let baseEntry = [StringEntry(kVersion, version), BooleanEntry(kActive, true), StringEntry(kAssetIdA, pmtStrAssetIdA), StringEntry(kAssetIdB, pmtStrAssetIdB), IntegerEntry(kBalanceInitA, amtAssetA), IntegerEntry(kBalanceInitB, amtAssetB), IntegerEntry(kBalanceA, 0), IntegerEntry(kBalanceB, 0), IntegerEntry(kFee, getIntegerValue(oracle, "base_fee_cpmm")), shareIssue, StringEntry(kShareAssetId, toBase58String(shareIssueId)), IntegerEntry(kShareAssetSupply, shareInitialSupply)] | |
552 | 558 | if (firstHarvest) | |
553 | 559 | then $Tuple2(nil, $Tuple2((baseEntry ++ [BooleanEntry(kFirstHarvest, firstHarvest), IntegerEntry(kFirstHarvestHeight, (startHeight + (firstHarvestEndPeriod * periodLength)))]), nil)) | |
554 | 560 | else $Tuple2(nil, $Tuple2(baseEntry, nil)) | |
555 | 561 | } | |
556 | 562 | } | |
557 | 563 | ||
558 | 564 | ||
559 | 565 | ||
560 | 566 | @Callable(i) | |
561 | 567 | func keepLimitForFirstHarvest (callerBytes,args,pAmounts,pAssetIds) = valueOrElse(isOraclePool(toString(i.caller)), valueOrElse(isActive(), if (!(containsElement([adminPubKey1, adminPubKey2, adminPubKey3, adminInvokePubKey], i.originCallerPublicKey))) | |
562 | 568 | then throw("Only admin can call this function") | |
563 | 569 | else if ((size(args) != 1)) | |
564 | 570 | then throw("Wrong args size") | |
565 | 571 | else { | |
566 | 572 | let shareLimit = parseIntValue(args[0]) | |
567 | 573 | $Tuple2(nil, $Tuple2([IntegerEntry(kShareLimit, shareLimit)], nil)) | |
568 | 574 | })) | |
569 | 575 | ||
570 | 576 | ||
571 | 577 | ||
572 | 578 | @Callable(i) | |
573 | 579 | func exchange (callerBytes,args,pAmounts,pAssetIds) = valueOrElse(isOraclePool(toString(i.caller)), valueOrElse(isDepricated(toString(i.caller)), valueOrElse(isActive(), { | |
574 | 580 | let caller = Address(callerBytes) | |
575 | - | let $ | |
576 | - | let pmtAmount = $ | |
577 | - | let pmtAssetId = $ | |
581 | + | let $t02230422380 = $Tuple2(pAmounts[0], parsePaymentAsset(pAssetIds[0])) | |
582 | + | let pmtAmount = $t02230422380._1 | |
583 | + | let pmtAssetId = $t02230422380._2 | |
578 | 584 | let minAmountToReceive = parseIntValue(args[0]) | |
579 | - | let $ | |
580 | - | let strAssetIdA = $ | |
581 | - | let strAssetIdB = $ | |
582 | - | let assetIdA = $ | |
583 | - | let assetIdB = $ | |
584 | - | let $ | |
585 | - | let balanceA = $ | |
586 | - | let balanceB = $ | |
587 | - | let accountBalanceA = $ | |
588 | - | let accountBalanceB = $ | |
585 | + | let $t02244522521 = getPoolAssets(i.caller) | |
586 | + | let strAssetIdA = $t02244522521._1 | |
587 | + | let strAssetIdB = $t02244522521._2 | |
588 | + | let assetIdA = $t02244522521._3 | |
589 | + | let assetIdB = $t02244522521._4 | |
590 | + | let $t02253022636 = getPoolBalances(i.caller, assetIdA, assetIdB) | |
591 | + | let balanceA = $t02253022636._1 | |
592 | + | let balanceB = $t02253022636._2 | |
593 | + | let accountBalanceA = $t02253022636._3 | |
594 | + | let accountBalanceB = $t02253022636._4 | |
589 | 595 | if ((size(args) != 1)) | |
590 | 596 | then throw("Wrong args size") | |
591 | 597 | else if (if ((balanceA == 0)) | |
592 | 598 | then true | |
593 | 599 | else (balanceB == 0)) | |
594 | 600 | then throw("Can't exchange with zero balance") | |
595 | 601 | else if ((0 >= minAmountToReceive)) | |
596 | 602 | then throw(("Minimal amount to receive must be positive. Actual: " + toString(minAmountToReceive))) | |
597 | 603 | else if ((size(pAmounts) != 1)) | |
598 | 604 | then throw("One attached payment expected") | |
599 | 605 | else if (!(containsElement([assetIdA, assetIdB], pmtAssetId))) | |
600 | 606 | then throw(((("Incorrect asset attached. Expected: " + strAssetIdA) + " or ") + strAssetIdB)) | |
601 | 607 | else if (if ((balanceA > accountBalanceA)) | |
602 | 608 | then true | |
603 | 609 | else (balanceB > accountBalanceB)) | |
604 | 610 | then $Tuple2(nil, ([ScriptTransfer(caller, pmtAmount, pmtAssetId)] ++ suspendSuspicious(accountBalanceA, accountBalanceB, balanceA, balanceB, strAssetIdA, strAssetIdB))) | |
605 | 611 | else { | |
606 | - | let $ | |
607 | - | let fee = $ | |
608 | - | let govFee = $ | |
609 | - | let teamFee = $ | |
610 | - | let $ | |
612 | + | let $t02353623603 = getFeeParams(i.caller, i.originCaller) | |
613 | + | let fee = $t02353623603._1 | |
614 | + | let govFee = $t02353623603._2 | |
615 | + | let teamFee = $t02353623603._3 | |
616 | + | let $t02361623967 = if ((pmtAssetId == assetIdA)) | |
611 | 617 | then calculateFees(pmtAmount, minAmountToReceive, balanceA, balanceB, fee, govFee, teamFee) | |
612 | 618 | else calculateFees(pmtAmount, minAmountToReceive, balanceB, balanceA, fee, govFee, teamFee) | |
613 | - | let amountWithoutFee = $ | |
614 | - | let amountWithFee = $ | |
615 | - | let governanceReward = $ | |
616 | - | let teamReward = $ | |
617 | - | let $ | |
619 | + | let amountWithoutFee = $t02361623967._1 | |
620 | + | let amountWithFee = $t02361623967._2 | |
621 | + | let governanceReward = $t02361623967._3 | |
622 | + | let teamReward = $t02361623967._4 | |
623 | + | let $t02398124316 = if ((pmtAssetId == assetIdA)) | |
618 | 624 | then $Tuple3((balanceA + pmtAmount), (((balanceB - amountWithFee) - governanceReward) - teamReward), assetIdB) | |
619 | 625 | else $Tuple3((((balanceA - amountWithFee) - governanceReward) - teamReward), (balanceB + pmtAmount), assetIdA) | |
620 | - | let newBalanceA = $ | |
621 | - | let newBalanceB = $ | |
622 | - | let assetIdSend = $ | |
623 | - | let $ | |
626 | + | let newBalanceA = $t02398124316._1 | |
627 | + | let newBalanceB = $t02398124316._2 | |
628 | + | let assetIdSend = $t02398124316._3 | |
629 | + | let $t02433024590 = if ((pmtAssetId == assetIdA)) | |
624 | 630 | then $Tuple2(pmtAmount, ((amountWithFee + governanceReward) + teamReward)) | |
625 | 631 | else $Tuple2(((amountWithFee + governanceReward) + teamReward), pmtAmount) | |
626 | - | let stakeAmountA = $ | |
627 | - | let stakeAmountB = $ | |
632 | + | let stakeAmountA = $t02433024590._1 | |
633 | + | let stakeAmountB = $t02433024590._2 | |
628 | 634 | let stake1 = if (contains(stakingAssets, strAssetIdA)) | |
629 | 635 | then invoke(i.caller, "stakeUnstake", [(pmtAssetId == assetIdA), stakeAmountA, strAssetIdA], nil) | |
630 | 636 | else 0 | |
631 | 637 | if ((stake1 == stake1)) | |
632 | 638 | then { | |
633 | 639 | let stake2 = if (contains(stakingAssets, strAssetIdB)) | |
634 | 640 | then invoke(i.caller, "stakeUnstake", [(pmtAssetId == assetIdB), stakeAmountB, strAssetIdB], nil) | |
635 | 641 | else 0 | |
636 | 642 | if ((stake2 == stake2)) | |
637 | 643 | then $Tuple2(nil, $Tuple2([IntegerEntry(kBalanceA, newBalanceA), IntegerEntry(kBalanceB, newBalanceB), ScriptTransfer(caller, amountWithFee, assetIdSend), ScriptTransfer(moneyBoxAddress, governanceReward, assetIdSend), ScriptTransfer(teamBoxAddress, teamReward, assetIdSend)], [amountWithFee, assetIdSend])) | |
638 | 644 | else throw("Strict value is not equal to itself.") | |
639 | 645 | } | |
640 | 646 | else throw("Strict value is not equal to itself.") | |
641 | 647 | } | |
642 | 648 | }))) | |
643 | 649 | ||
644 | 650 | ||
645 | 651 | ||
646 | 652 | @Callable(i) | |
647 | 653 | func replenishWithTwoTokens (callerBytes,args,pAmounts,pAssetIds) = valueOrElse(isOraclePool(toString(i.caller)), valueOrElse(isDepricated(toString(i.caller)), valueOrElse(isActive(), { | |
648 | 654 | let caller = Address(callerBytes) | |
649 | 655 | let pmtAssetIdA = parsePaymentAsset(pAssetIds[0]) | |
650 | 656 | let pmtAssetIdB = parsePaymentAsset(pAssetIds[1]) | |
651 | 657 | let stakeFarming = (args[0] == "true") | |
652 | 658 | let lockType = parseIntValue(args[1]) | |
653 | - | let $ | |
654 | - | let strAssetIdA = $ | |
655 | - | let strAssetIdB = $ | |
656 | - | let assetIdA = $ | |
657 | - | let assetIdB = $ | |
658 | - | let shareAssetId = $ | |
659 | - | let $ | |
660 | - | let balanceA = $ | |
661 | - | let balanceB = $ | |
662 | - | let accountBalanceA = $ | |
663 | - | let accountBalanceB = $ | |
664 | - | let shareAssetSupply = $ | |
659 | + | let $t02590525995 = getPoolAssets(i.caller) | |
660 | + | let strAssetIdA = $t02590525995._1 | |
661 | + | let strAssetIdB = $t02590525995._2 | |
662 | + | let assetIdA = $t02590525995._3 | |
663 | + | let assetIdB = $t02590525995._4 | |
664 | + | let shareAssetId = $t02590525995._5 | |
665 | + | let $t02600426128 = getPoolBalances(i.caller, assetIdA, assetIdB) | |
666 | + | let balanceA = $t02600426128._1 | |
667 | + | let balanceB = $t02600426128._2 | |
668 | + | let accountBalanceA = $t02600426128._3 | |
669 | + | let accountBalanceB = $t02600426128._4 | |
670 | + | let shareAssetSupply = $t02600426128._5 | |
665 | 671 | if ((size(args) != 2)) | |
666 | 672 | then throw("Wrong args size") | |
667 | 673 | else if (if ((size(pAmounts) != 2)) | |
668 | 674 | then (size(pAmounts) != 3) | |
669 | 675 | else false) | |
670 | 676 | then throw("Two or three payments expected") | |
671 | 677 | else if (if ((pmtAssetIdA != assetIdA)) | |
672 | 678 | then true | |
673 | 679 | else (pmtAssetIdB != assetIdB)) | |
674 | 680 | then throw(((("Incorrect assets attached. Expected: " + strAssetIdA) + " and ") + strAssetIdB)) | |
675 | 681 | else if (if ((balanceA > accountBalanceA)) | |
676 | 682 | then true | |
677 | 683 | else (balanceB > accountBalanceB)) | |
678 | 684 | then $Tuple2(nil, ([ScriptTransfer(caller, pAmounts[0], pmtAssetIdA), ScriptTransfer(caller, pAmounts[1], pmtAssetIdB)] ++ (if ((size(pAmounts) == 3)) | |
679 | 685 | then [AttachedPayment(if ((pAssetIds[2] == base58'')) | |
680 | 686 | then unit | |
681 | 687 | else pAssetIds[2], pAmounts[2])] | |
682 | 688 | else (nil ++ suspendSuspicious(accountBalanceA, accountBalanceB, balanceA, balanceB, strAssetIdA, strAssetIdB))))) | |
683 | 689 | else { | |
684 | - | let $ | |
685 | - | let shareTokenToPayAmount = $ | |
686 | - | let change = $ | |
687 | - | let changeAssetId = $ | |
688 | - | let pmtAmountA = $ | |
689 | - | let pmtAmountB = $ | |
690 | + | let $t02706527263 = calcLPAmountReplensishTwoTokens(pAmounts[0], pAmounts[1], pmtAssetIdA, pmtAssetIdB, balanceA, balanceB, shareAssetSupply) | |
691 | + | let shareTokenToPayAmount = $t02706527263._1 | |
692 | + | let change = $t02706527263._2 | |
693 | + | let changeAssetId = $t02706527263._3 | |
694 | + | let pmtAmountA = $t02706527263._4 | |
695 | + | let pmtAmountB = $t02706527263._5 | |
690 | 696 | if ((shareTokenToPayAmount == 0)) | |
691 | 697 | then throw("Too small amount to replenish") | |
692 | 698 | else if ((0 > change)) | |
693 | 699 | then throw("Change < 0") | |
694 | 700 | else { | |
695 | 701 | let stake1 = if (contains(stakingAssets, strAssetIdA)) | |
696 | 702 | then invoke(i.caller, "stakeUnstake", [true, pmtAmountA, strAssetIdA], nil) | |
697 | 703 | else 0 | |
698 | 704 | if ((stake1 == stake1)) | |
699 | 705 | then { | |
700 | 706 | let stake2 = if (contains(stakingAssets, strAssetIdB)) | |
701 | 707 | then invoke(i.caller, "stakeUnstake", [true, pmtAmountB, strAssetIdB], nil) | |
702 | 708 | else 0 | |
703 | 709 | if ((stake2 == stake2)) | |
704 | 710 | then { | |
705 | 711 | let shareTokenST = if (stakeFarming) | |
706 | 712 | then { | |
707 | 713 | let stPayments = ([AttachedPayment(shareAssetId, shareTokenToPayAmount)] ++ (if ((size(pAmounts) == 3)) | |
708 | 714 | then [AttachedPayment(if ((pAssetIds[2] == base58'')) | |
709 | 715 | then unit | |
710 | 716 | else pAssetIds[2], pAmounts[2])] | |
711 | 717 | else nil)) | |
712 | 718 | let reissue = invoke(i.caller, "reissueShareToken", [shareTokenToPayAmount], nil) | |
713 | 719 | if ((reissue == reissue)) | |
714 | 720 | then { | |
715 | 721 | let stake3 = invoke(farmingAddress, "lockShareTokensFromPool", [callerBytes, toString(i.caller), lockType], stPayments) | |
716 | 722 | if ((stake3 == stake3)) | |
717 | 723 | then nil | |
718 | 724 | else throw("Strict value is not equal to itself.") | |
719 | 725 | } | |
720 | 726 | else throw("Strict value is not equal to itself.") | |
721 | 727 | } | |
722 | 728 | else [Reissue(shareAssetId, shareTokenToPayAmount, true), ScriptTransfer(caller, shareTokenToPayAmount, shareAssetId)] | |
723 | 729 | $Tuple2(nil, $Tuple2(([IntegerEntry(kBalanceA, (balanceA + pmtAmountA)), IntegerEntry(kBalanceB, (balanceB + pmtAmountB)), IntegerEntry(kShareAssetSupply, (shareAssetSupply + shareTokenToPayAmount)), ScriptTransfer(caller, change, changeAssetId)] ++ shareTokenST), nil)) | |
724 | 730 | } | |
725 | 731 | else throw("Strict value is not equal to itself.") | |
726 | 732 | } | |
727 | 733 | else throw("Strict value is not equal to itself.") | |
728 | 734 | } | |
729 | 735 | } | |
730 | 736 | }))) | |
731 | 737 | ||
732 | 738 | ||
733 | 739 | ||
734 | 740 | @Callable(i) | |
735 | 741 | func replenishWithOneToken (callerBytes,args,pAmounts,pAssetIds) = valueOrElse(isOraclePool(toString(i.caller)), valueOrElse(isDepricated(toString(i.caller)), valueOrElse(isActive(), { | |
736 | 742 | let caller = Address(callerBytes) | |
737 | 743 | let pmtAssetId = parsePaymentAsset(pAssetIds[0]) | |
738 | 744 | let pmtAmount = pAmounts[0] | |
739 | 745 | let virtGetMinAmount = parseIntValue(args[0]) | |
740 | 746 | let stakeFarming = (args[1] == "true") | |
741 | 747 | let lockType = parseIntValue(args[2]) | |
742 | - | let $ | |
743 | - | let strAssetIdA = $ | |
744 | - | let strAssetIdB = $ | |
745 | - | let assetIdA = $ | |
746 | - | let assetIdB = $ | |
747 | - | let shareAssetId = $ | |
748 | - | let $ | |
749 | - | let balanceA = $ | |
750 | - | let balanceB = $ | |
751 | - | let accountBalanceA = $ | |
752 | - | let accountBalanceB = $ | |
753 | - | let shareAssetSupply = $ | |
748 | + | let $t02952229612 = getPoolAssets(i.caller) | |
749 | + | let strAssetIdA = $t02952229612._1 | |
750 | + | let strAssetIdB = $t02952229612._2 | |
751 | + | let assetIdA = $t02952229612._3 | |
752 | + | let assetIdB = $t02952229612._4 | |
753 | + | let shareAssetId = $t02952229612._5 | |
754 | + | let $t02961729741 = getPoolBalances(i.caller, assetIdA, assetIdB) | |
755 | + | let balanceA = $t02961729741._1 | |
756 | + | let balanceB = $t02961729741._2 | |
757 | + | let accountBalanceA = $t02961729741._3 | |
758 | + | let accountBalanceB = $t02961729741._4 | |
759 | + | let shareAssetSupply = $t02961729741._5 | |
754 | 760 | let initial = ((balanceA + balanceB) == 0) | |
755 | 761 | if ((size(args) != 3)) | |
756 | 762 | then throw("Wrong args size") | |
757 | 763 | else if (if ((size(pAmounts) != 1)) | |
758 | 764 | then (size(pAmounts) != 2) | |
759 | 765 | else false) | |
760 | 766 | then throw("Two or one attached assets expected") | |
761 | 767 | else if (if ((pmtAssetId != assetIdA)) | |
762 | 768 | then (pmtAssetId != assetIdB) | |
763 | 769 | else false) | |
764 | 770 | then throw(((("Incorrect asset attached. Expected: " + strAssetIdA) + " or ") + strAssetIdB)) | |
765 | 771 | else if (initial) | |
766 | 772 | then throw("For initial exchanger you need to use two tokens") | |
767 | 773 | else if (if ((balanceA > accountBalanceA)) | |
768 | 774 | then true | |
769 | 775 | else (balanceB > accountBalanceB)) | |
770 | 776 | then $Tuple2(nil, ([ScriptTransfer(caller, pmtAmount, pmtAssetId)] ++ (if ((size(pAmounts) == 2)) | |
771 | 777 | then [AttachedPayment(if ((pAssetIds[2] == base58'')) | |
772 | 778 | then unit | |
773 | 779 | else pAssetIds[2], pAmounts[2])] | |
774 | 780 | else (nil ++ suspendSuspicious(accountBalanceA, accountBalanceB, balanceA, balanceB, strAssetIdA, strAssetIdB))))) | |
775 | 781 | else { | |
776 | - | let $ | |
777 | - | let fee = $ | |
778 | - | let govFee = $ | |
779 | - | let teamFee = $ | |
780 | - | let $ | |
781 | - | let pmtAssetIdStr = $ | |
782 | - | let pmtAssetIdName = $ | |
783 | - | let $ | |
784 | - | let shareTokenToPayAmount = $ | |
785 | - | let newBalanceA = $ | |
786 | - | let newBalanceB = $ | |
787 | - | let govReward = $ | |
788 | - | let teamReward = $ | |
789 | - | let govRewardAsset = $ | |
782 | + | let $t03065330720 = getFeeParams(i.caller, i.originCaller) | |
783 | + | let fee = $t03065330720._1 | |
784 | + | let govFee = $t03065330720._2 | |
785 | + | let teamFee = $t03065330720._3 | |
786 | + | let $t03072930791 = getAssetInfo(pmtAssetId) | |
787 | + | let pmtAssetIdStr = $t03072930791._1 | |
788 | + | let pmtAssetIdName = $t03072930791._2 | |
789 | + | let $t03080931055 = calcLPAmountReplansishOneToken(pmtAmount, pmtAssetId, assetIdA, assetIdB, balanceA, balanceB, shareAssetSupply, fee, govFee, teamFee, virtGetMinAmount) | |
790 | + | let shareTokenToPayAmount = $t03080931055._1 | |
791 | + | let newBalanceA = $t03080931055._2 | |
792 | + | let newBalanceB = $t03080931055._3 | |
793 | + | let govReward = $t03080931055._4 | |
794 | + | let teamReward = $t03080931055._5 | |
795 | + | let govRewardAsset = $t03080931055._6 | |
790 | 796 | let govRewardAssetStr = if ((govRewardAsset == assetIdA)) | |
791 | 797 | then strAssetIdA | |
792 | 798 | else strAssetIdB | |
793 | 799 | if ((shareTokenToPayAmount == 0)) | |
794 | 800 | then throw("Too small amount to replenish") | |
795 | 801 | else { | |
796 | 802 | let stake1 = if (contains(stakingAssets, pmtAssetIdStr)) | |
797 | 803 | then invoke(i.caller, "stakeUnstake", [true, pmtAmount, pmtAssetIdStr], nil) | |
798 | 804 | else 0 | |
799 | 805 | if ((stake1 == stake1)) | |
800 | 806 | then { | |
801 | 807 | let stake2 = if (contains(stakingAssets, govRewardAssetStr)) | |
802 | 808 | then invoke(i.caller, "stakeUnstake", [false, (govReward + teamReward), govRewardAssetStr], nil) | |
803 | 809 | else 0 | |
804 | 810 | if ((stake2 == stake2)) | |
805 | 811 | then { | |
806 | 812 | let shareTokenST = if (stakeFarming) | |
807 | 813 | then { | |
808 | 814 | let stPayments = ([AttachedPayment(shareAssetId, shareTokenToPayAmount)] ++ (if ((size(pAmounts) == 2)) | |
809 | 815 | then [AttachedPayment(if ((pAssetIds[1] == base58'')) | |
810 | 816 | then unit | |
811 | 817 | else pAssetIds[1], pAmounts[1])] | |
812 | 818 | else nil)) | |
813 | 819 | let reissue = invoke(i.caller, "reissueShareToken", [shareTokenToPayAmount], nil) | |
814 | 820 | if ((reissue == reissue)) | |
815 | 821 | then { | |
816 | 822 | let stake3 = invoke(farmingAddress, "lockShareTokensFromPool", [callerBytes, toString(i.caller), lockType], stPayments) | |
817 | 823 | if ((stake3 == stake3)) | |
818 | 824 | then nil | |
819 | 825 | else throw("Strict value is not equal to itself.") | |
820 | 826 | } | |
821 | 827 | else throw("Strict value is not equal to itself.") | |
822 | 828 | } | |
823 | 829 | else [Reissue(shareAssetId, shareTokenToPayAmount, true), ScriptTransfer(caller, shareTokenToPayAmount, shareAssetId)] | |
824 | 830 | $Tuple2(nil, $Tuple2(([IntegerEntry(kBalanceA, newBalanceA), IntegerEntry(kBalanceB, newBalanceB), IntegerEntry(kShareAssetSupply, (shareAssetSupply + shareTokenToPayAmount)), ScriptTransfer(moneyBoxAddress, govReward, govRewardAsset), ScriptTransfer(teamBoxAddress, teamReward, govRewardAsset)] ++ shareTokenST), nil)) | |
825 | 831 | } | |
826 | 832 | else throw("Strict value is not equal to itself.") | |
827 | 833 | } | |
828 | 834 | else throw("Strict value is not equal to itself.") | |
829 | 835 | } | |
830 | 836 | } | |
831 | 837 | }))) | |
832 | 838 | ||
833 | 839 | ||
834 | 840 | ||
835 | 841 | @Callable(i) | |
836 | 842 | func withdraw (callerBytes,args,pAmounts,pAssetIds) = valueOrElse(isOraclePool(toString(i.caller)), valueOrElse(isActive(), { | |
837 | 843 | let caller = Address(callerBytes) | |
838 | - | let $ | |
839 | - | let strAssetIdA = $ | |
840 | - | let strAssetIdB = $ | |
841 | - | let assetIdA = $ | |
842 | - | let assetIdB = $ | |
843 | - | let shareAssetId = $ | |
844 | - | let $ | |
845 | - | let balanceA = $ | |
846 | - | let balanceB = $ | |
847 | - | let accountBalanceA = $ | |
848 | - | let accountBalanceB = $ | |
849 | - | let shareAssetSupply = $ | |
850 | - | let $ | |
844 | + | let $t03312333213 = getPoolAssets(i.caller) | |
845 | + | let strAssetIdA = $t03312333213._1 | |
846 | + | let strAssetIdB = $t03312333213._2 | |
847 | + | let assetIdA = $t03312333213._3 | |
848 | + | let assetIdB = $t03312333213._4 | |
849 | + | let shareAssetId = $t03312333213._5 | |
850 | + | let $t03322233346 = getPoolBalances(i.caller, assetIdA, assetIdB) | |
851 | + | let balanceA = $t03322233346._1 | |
852 | + | let balanceB = $t03322233346._2 | |
853 | + | let accountBalanceA = $t03322233346._3 | |
854 | + | let accountBalanceB = $t03322233346._4 | |
855 | + | let shareAssetSupply = $t03322233346._5 | |
856 | + | let $t03335533735 = if ((size(pAmounts) == 1)) | |
851 | 857 | then { | |
852 | 858 | let pAsset = parsePaymentAsset(pAssetIds[0]) | |
853 | 859 | if ((pAsset != shareAssetId)) | |
854 | 860 | then throw(("Incorrect asset attached. Expected: " + toBase58String(shareAssetId))) | |
855 | 861 | else $Tuple2(pAmounts[0], pAsset) | |
856 | 862 | } | |
857 | 863 | else $Tuple2(0, shareAssetId) | |
858 | - | let pmtAmount = $ | |
859 | - | let pmtAssetId = $ | |
864 | + | let pmtAmount = $t03335533735._1 | |
865 | + | let pmtAssetId = $t03335533735._2 | |
860 | 866 | if ((size(args) != 1)) | |
861 | 867 | then throw("Wrong args size") | |
862 | 868 | else if ((size(pAmounts) > 1)) | |
863 | 869 | then throw("One attached payment expected") | |
864 | 870 | else if (if ((balanceA > accountBalanceA)) | |
865 | 871 | then true | |
866 | 872 | else (balanceB > accountBalanceB)) | |
867 | 873 | then $Tuple2(nil, ([ScriptTransfer(caller, pmtAmount, pmtAssetId)] ++ suspendSuspicious(accountBalanceA, accountBalanceB, balanceA, balanceB, strAssetIdA, strAssetIdB))) | |
868 | 874 | else { | |
869 | 875 | let unlockAmount = parseIntValue(valueOrElse(args[0], "0")) | |
870 | 876 | let unlock = if ((unlockAmount > 0)) | |
871 | 877 | then invoke(farmingAddress, "withdrawShareTokensFromPool", [callerBytes, toString(i.caller), unlockAmount], nil) | |
872 | 878 | else 0 | |
873 | 879 | if ((unlock == unlock)) | |
874 | 880 | then { | |
875 | 881 | let withdrawAmount = (pmtAmount + unlockAmount) | |
876 | 882 | let amountToPayA = fraction(withdrawAmount, balanceA, shareAssetSupply) | |
877 | 883 | let amountToPayB = fraction(withdrawAmount, balanceB, shareAssetSupply) | |
878 | 884 | let stake1 = if (contains(stakingAssets, strAssetIdA)) | |
879 | 885 | then invoke(i.caller, "stakeUnstake", [false, amountToPayA, strAssetIdA], nil) | |
880 | 886 | else 0 | |
881 | 887 | if ((stake1 == stake1)) | |
882 | 888 | then { | |
883 | 889 | let stake2 = if (contains(stakingAssets, strAssetIdB)) | |
884 | 890 | then invoke(i.caller, "stakeUnstake", [false, amountToPayB, strAssetIdB], nil) | |
885 | 891 | else 0 | |
886 | 892 | if ((stake2 == stake2)) | |
887 | 893 | then $Tuple2([ScriptTransfer(i.caller, unlockAmount, shareAssetId)], $Tuple2([IntegerEntry(kBalanceA, (balanceA - amountToPayA)), IntegerEntry(kBalanceB, (balanceB - amountToPayB)), IntegerEntry(kShareAssetSupply, (shareAssetSupply - withdrawAmount)), Burn(shareAssetId, withdrawAmount), ScriptTransfer(caller, amountToPayA, assetIdA), ScriptTransfer(caller, amountToPayB, assetIdB)], nil)) | |
888 | 894 | else throw("Strict value is not equal to itself.") | |
889 | 895 | } | |
890 | 896 | else throw("Strict value is not equal to itself.") | |
891 | 897 | } | |
892 | 898 | else throw("Strict value is not equal to itself.") | |
893 | 899 | } | |
894 | 900 | })) | |
895 | 901 | ||
896 | 902 | ||
897 | 903 | ||
898 | 904 | @Callable(i) | |
899 | 905 | func withdrawOneToken (callerBytes,args,pAmounts,pAssetIds) = valueOrElse(isOraclePool(toString(i.caller)), valueOrElse(isDepricated(toString(i.caller)), valueOrElse(isActive(), { | |
900 | 906 | let caller = Address(callerBytes) | |
901 | 907 | let withdrawAsset = if ((args[0] == "")) | |
902 | 908 | then unit | |
903 | 909 | else fromBase58String(args[0]) | |
904 | - | let $ | |
905 | - | let strAssetIdA = $ | |
906 | - | let strAssetIdB = $ | |
907 | - | let assetIdA = $ | |
908 | - | let assetIdB = $ | |
909 | - | let shareAssetId = $ | |
910 | - | let $ | |
911 | - | let balanceA = $ | |
912 | - | let balanceB = $ | |
913 | - | let accountBalanceA = $ | |
914 | - | let accountBalanceB = $ | |
915 | - | let shareAssetSupply = $ | |
916 | - | let $ | |
910 | + | let $t03595336043 = getPoolAssets(i.caller) | |
911 | + | let strAssetIdA = $t03595336043._1 | |
912 | + | let strAssetIdB = $t03595336043._2 | |
913 | + | let assetIdA = $t03595336043._3 | |
914 | + | let assetIdB = $t03595336043._4 | |
915 | + | let shareAssetId = $t03595336043._5 | |
916 | + | let $t03605236176 = getPoolBalances(i.caller, assetIdA, assetIdB) | |
917 | + | let balanceA = $t03605236176._1 | |
918 | + | let balanceB = $t03605236176._2 | |
919 | + | let accountBalanceA = $t03605236176._3 | |
920 | + | let accountBalanceB = $t03605236176._4 | |
921 | + | let shareAssetSupply = $t03605236176._5 | |
922 | + | let $t03618536537 = if ((size(pAmounts) == 1)) | |
917 | 923 | then { | |
918 | 924 | let pAsset = parsePaymentAsset(pAssetIds[0]) | |
919 | 925 | if ((pAsset != shareAssetId)) | |
920 | 926 | then throw(("Incorrect asset attached. Expected: " + toBase58String(shareAssetId))) | |
921 | 927 | else $Tuple2(pAmounts[0], pAsset) | |
922 | 928 | } | |
923 | 929 | else $Tuple2(0, shareAssetId) | |
924 | - | let pmtAmount = $ | |
925 | - | let pmtAssetId = $ | |
930 | + | let pmtAmount = $t03618536537._1 | |
931 | + | let pmtAssetId = $t03618536537._2 | |
926 | 932 | let virtMinToRecive = parseIntValue(args[1]) | |
927 | 933 | if ((size(args) != 3)) | |
928 | 934 | then throw("Wrong args size") | |
929 | 935 | else if ((size(pAmounts) > 1)) | |
930 | 936 | then throw("One attached payment expected") | |
931 | 937 | else if ((pmtAssetId != shareAssetId)) | |
932 | 938 | then throw(("Incorrect asset attached. Expected: " + toBase58String(shareAssetId))) | |
933 | 939 | else if (!(containsElement([assetIdA, assetIdB], withdrawAsset))) | |
934 | 940 | then throw("Incorrect withdraw asset.") | |
935 | 941 | else if (if ((balanceA > accountBalanceA)) | |
936 | 942 | then true | |
937 | 943 | else (balanceB > accountBalanceB)) | |
938 | 944 | then $Tuple2(nil, ([ScriptTransfer(caller, pmtAmount, pmtAssetId)] ++ suspendSuspicious(accountBalanceA, accountBalanceB, balanceA, balanceB, strAssetIdA, strAssetIdB))) | |
939 | 945 | else { | |
940 | 946 | let unlockAmount = parseIntValue(valueOrElse(args[2], "0")) | |
941 | 947 | let unlock = if ((unlockAmount > 0)) | |
942 | 948 | then invoke(farmingAddress, "withdrawShareTokensFromPool", [callerBytes, toString(i.caller), unlockAmount], nil) | |
943 | 949 | else 0 | |
944 | 950 | if ((unlock == unlock)) | |
945 | 951 | then { | |
946 | 952 | let withdrawAmount = (pmtAmount + unlockAmount) | |
947 | 953 | let amountToPayA = fraction(withdrawAmount, balanceA, shareAssetSupply) | |
948 | 954 | let amountToPayB = fraction(withdrawAmount, balanceB, shareAssetSupply) | |
949 | - | let $ | |
950 | - | let fee = $ | |
951 | - | let govFee = $ | |
952 | - | let teamFee = $ | |
953 | - | let $ | |
955 | + | let $t03780437871 = getFeeParams(i.caller, i.originCaller) | |
956 | + | let fee = $t03780437871._1 | |
957 | + | let govFee = $t03780437871._2 | |
958 | + | let teamFee = $t03780437871._3 | |
959 | + | let $t03788438298 = if ((withdrawAsset == assetIdA)) | |
954 | 960 | then calculateFees(amountToPayB, virtMinToRecive, (balanceB - amountToPayB), (balanceA - amountToPayA), fee, govFee, teamFee) | |
955 | 961 | else calculateFees(amountToPayA, virtMinToRecive, (balanceA - amountToPayA), (balanceB - amountToPayB), fee, govFee, teamFee) | |
956 | - | let amountWithoutFee = $ | |
957 | - | let amountWithFee = $ | |
958 | - | let governanceReward = $ | |
959 | - | let teamReward = $ | |
960 | - | let $ | |
962 | + | let amountWithoutFee = $t03788438298._1 | |
963 | + | let amountWithFee = $t03788438298._2 | |
964 | + | let governanceReward = $t03788438298._3 | |
965 | + | let teamReward = $t03788438298._4 | |
966 | + | let $t03831139621 = if ((withdrawAsset == assetIdA)) | |
961 | 967 | then { | |
962 | 968 | let unstake = if (contains(stakingAssets, strAssetIdA)) | |
963 | 969 | then invoke(i.caller, "stakeUnstake", [false, (((amountToPayA + amountWithFee) + governanceReward) + teamReward), strAssetIdA], nil) | |
964 | 970 | else 0 | |
965 | 971 | if ((unstake == unstake)) | |
966 | 972 | then $Tuple4(((((balanceA - amountToPayA) - amountWithFee) - governanceReward) - teamReward), balanceB, assetIdA, [ScriptTransfer(caller, (amountToPayA + amountWithFee), assetIdA)]) | |
967 | 973 | else throw("Strict value is not equal to itself.") | |
968 | 974 | } | |
969 | 975 | else { | |
970 | 976 | let unstake = if (contains(stakingAssets, strAssetIdB)) | |
971 | 977 | then invoke(i.caller, "stakeUnstake", [false, (((amountToPayB + amountWithFee) + governanceReward) + teamReward), strAssetIdB], nil) | |
972 | 978 | else 0 | |
973 | 979 | if ((unstake == unstake)) | |
974 | 980 | then $Tuple4(balanceA, ((((balanceB - amountToPayB) - amountWithFee) - governanceReward) - teamReward), assetIdB, [ScriptTransfer(caller, (amountToPayB + amountWithFee), assetIdB)]) | |
975 | 981 | else throw("Strict value is not equal to itself.") | |
976 | 982 | } | |
977 | - | let newBalanceA = $ | |
978 | - | let newBalanceB = $ | |
979 | - | let govRewardAssetId = $ | |
980 | - | let userTransfer = $ | |
983 | + | let newBalanceA = $t03831139621._1 | |
984 | + | let newBalanceB = $t03831139621._2 | |
985 | + | let govRewardAssetId = $t03831139621._3 | |
986 | + | let userTransfer = $t03831139621._4 | |
981 | 987 | $Tuple2([ScriptTransfer(i.caller, unlockAmount, shareAssetId)], $Tuple2(([IntegerEntry(kBalanceA, newBalanceA), IntegerEntry(kBalanceB, newBalanceB), IntegerEntry(kShareAssetSupply, (shareAssetSupply - withdrawAmount)), Burn(shareAssetId, withdrawAmount), ScriptTransfer(moneyBoxAddress, governanceReward, govRewardAssetId), ScriptTransfer(teamBoxAddress, teamReward, govRewardAssetId)] ++ userTransfer), nil)) | |
982 | 988 | } | |
983 | 989 | else throw("Strict value is not equal to itself.") | |
984 | 990 | } | |
985 | 991 | }))) | |
986 | 992 | ||
987 | 993 | ||
988 | 994 | ||
989 | 995 | @Callable(i) | |
990 | 996 | func takeIntoAccountExtraFunds (callerBytes,args,pAmounts,pAssetIds) = valueOrElse(isOraclePool(toString(i.caller)), valueOrElse(isActive(), { | |
991 | - | let $ | |
992 | - | let strAssetIdA = $ | |
993 | - | let strAssetIdB = $ | |
994 | - | let assetIdA = $ | |
995 | - | let assetIdB = $ | |
997 | + | let $t04038140457 = getPoolAssets(i.caller) | |
998 | + | let strAssetIdA = $t04038140457._1 | |
999 | + | let strAssetIdB = $t04038140457._2 | |
1000 | + | let assetIdA = $t04038140457._3 | |
1001 | + | let assetIdB = $t04038140457._4 | |
996 | 1002 | let claim = if (if ((assetIdA == USDN)) | |
997 | 1003 | then true | |
998 | 1004 | else (assetIdB == USDN)) | |
999 | 1005 | then invoke(i.caller, "claimNetrinoRewards", nil, nil) | |
1000 | 1006 | else 0 | |
1001 | 1007 | if ((claim == claim)) | |
1002 | 1008 | then { | |
1003 | - | let $ | |
1004 | - | let balanceA = $ | |
1005 | - | let balanceB = $ | |
1006 | - | let accountBalanceA = $ | |
1007 | - | let accountBalanceB = $ | |
1009 | + | let $t04061740723 = getPoolBalances(i.caller, assetIdA, assetIdB) | |
1010 | + | let balanceA = $t04061740723._1 | |
1011 | + | let balanceB = $t04061740723._2 | |
1012 | + | let accountBalanceA = $t04061740723._3 | |
1013 | + | let accountBalanceB = $t04061740723._4 | |
1008 | 1014 | let amountEnrollA = (accountBalanceA - balanceA) | |
1009 | 1015 | let amountEnrollB = (accountBalanceB - balanceB) | |
1010 | 1016 | if ((size(args) != 0)) | |
1011 | 1017 | then throw("Wrong args size") | |
1012 | 1018 | else if ((moneyBoxAddress != i.originCaller)) | |
1013 | 1019 | then throw("Only the wallet can call this function") | |
1014 | 1020 | else if (if ((0 > amountEnrollA)) | |
1015 | 1021 | then true | |
1016 | 1022 | else (0 > amountEnrollB)) | |
1017 | 1023 | then suspend("Enroll amount negative") | |
1018 | 1024 | else if (if ((amountEnrollA == 0)) | |
1019 | 1025 | then (amountEnrollB == 0) | |
1020 | 1026 | else false) | |
1021 | 1027 | then throw("No money to take") | |
1022 | 1028 | else { | |
1023 | 1029 | let stake1 = if (if (contains(stakingAssets, strAssetIdA)) | |
1024 | 1030 | then (amountEnrollA > 0) | |
1025 | 1031 | else false) | |
1026 | 1032 | then invoke(i.caller, "stakeUnstake", [true, amountEnrollA, strAssetIdA], nil) | |
1027 | 1033 | else 0 | |
1028 | 1034 | if ((stake1 == stake1)) | |
1029 | 1035 | then { | |
1030 | 1036 | let stake2 = if (if (contains(stakingAssets, strAssetIdB)) | |
1031 | 1037 | then (amountEnrollB > 0) | |
1032 | 1038 | else false) | |
1033 | 1039 | then invoke(i.caller, "stakeUnstake", [true, amountEnrollB, strAssetIdB], nil) | |
1034 | 1040 | else 0 | |
1035 | 1041 | if ((stake2 == stake2)) | |
1036 | 1042 | then $Tuple2(nil, $Tuple2([IntegerEntry(kBalanceA, (balanceA + amountEnrollA)), IntegerEntry(kBalanceB, (balanceB + amountEnrollB))], nil)) | |
1037 | 1043 | else throw("Strict value is not equal to itself.") | |
1038 | 1044 | } | |
1039 | 1045 | else throw("Strict value is not equal to itself.") | |
1040 | 1046 | } | |
1041 | 1047 | } | |
1042 | 1048 | else throw("Strict value is not equal to itself.") | |
1043 | 1049 | })) | |
1044 | 1050 | ||
1045 | 1051 | ||
1046 | 1052 | @Verifier(tx) | |
1047 | 1053 | func verify () = { | |
1048 | 1054 | let multiSignedByAdmins = { | |
1049 | 1055 | let adminPubKey1Signed = if (sigVerify(tx.bodyBytes, tx.proofs[0], adminPubKey1)) | |
1050 | 1056 | then 1 | |
1051 | 1057 | else 0 | |
1052 | 1058 | let adminPubKey2Signed = if (sigVerify(tx.bodyBytes, tx.proofs[1], adminPubKey2)) | |
1053 | 1059 | then 1 | |
1054 | 1060 | else 0 | |
1055 | 1061 | let adminPubKey3Signed = if (sigVerify(tx.bodyBytes, tx.proofs[2], adminPubKey3)) | |
1056 | 1062 | then 1 | |
1057 | 1063 | else 0 | |
1058 | 1064 | (((adminPubKey1Signed + adminPubKey2Signed) + adminPubKey3Signed) >= 2) | |
1059 | 1065 | } | |
1060 | 1066 | multiSignedByAdmins | |
1061 | 1067 | } | |
1062 | 1068 |
github/deemru/w8io/026f985 176.25 ms ◑