tx · 7ssiTR4NurxWa4U69Jg7h3mz69Ncpito5BQvuCGZKKmU 3MrRa3KaEgRyyjQdMLuU78m5GkJLvP5DZLj: -0.05100000 Waves 2022.07.14 00:20 [2138489] smart account 3MrRa3KaEgRyyjQdMLuU78m5GkJLvP5DZLj > SELF 0.00000000 Waves
{ "type": 13, "id": "7ssiTR4NurxWa4U69Jg7h3mz69Ncpito5BQvuCGZKKmU", "fee": 5100000, "feeAssetId": null, "timestamp": 1657747247626, "version": 2, "chainId": 84, "sender": "3MrRa3KaEgRyyjQdMLuU78m5GkJLvP5DZLj", "senderPublicKey": "AJNTN7EtP9dsAmPzcKRp9bRMvzZL4uwkmVxQuFuar3Qr", "proofs": [ "3GfxTtMt9GDCmz1RiA4Lyc2bjtnKrrYLEjsLwLD3ojzc3ADLFLVRqiBgmbJL7DCtmM5WTSTAJmPAjsWfhhHQMxhh" ], "script": "base64:AAIFAAAAAAAAAEkIAhIAEgASCQoHAQEBAQEBARIOCgwBAQEBAQEBCAgIAQESBQoDAQEBEgUKAwEBARIAEgMKAQESABIDCgEIEgASAwoBCBIDCgEIAAAAdgAAAAAJa19vcmFfa2V5AgAAAAlrX29yYV9rZXkAAAAAD2tfb3JhX2Jsb2NrX2tleQIAAAAPa19vcmFfYmxvY2tfa2V5AAAAAAVrX29yYQIAAAAFa19vcmEAAAAACWtfYmFsYW5jZQIAAAAJa19iYWxhbmNlAAAAAA5rX3Bvc2l0aW9uU2l6ZQIAAAAOa19wb3NpdGlvblNpemUAAAAAEGtfcG9zaXRpb25NYXJnaW4CAAAAEGtfcG9zaXRpb25NYXJnaW4AAAAAFmtfcG9zaXRpb25PcGVuTm90aW9uYWwCAAAAFmtfcG9zaXRpb25PcGVuTm90aW9uYWwAAAAALmtfcG9zaXRpb25MYXN0VXBkYXRlZEN1bXVsYXRpdmVQcmVtaXVtRnJhY3Rpb24CAAAAEmtfcG9zaXRpb25GcmFjdGlvbgAAAAANa19pbml0aWFsaXplZAIAAAANa19pbml0aWFs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AAAAAQkBAAAADmdldE1hcmdpblJhdGlvAAAAAQUAAAAHX3RyYWRlcgAAAAEAAAACdHgBAAAABnZlcmlmeQAAAAAJAAH0AAAAAwgFAAAAAnR4AAAACWJvZHlCeXRlcwkAAZEAAAACCAUAAAACdHgAAAAGcHJvb2ZzAAAAAAAAAAAACQEAAAAOYWRtaW5QdWJsaWNLZXkAAAAAOhcWyw==", "height": 2138489, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: EwkKLvesxf2iTzKt3f7atNik39dfeMEUHefF4MsoCYEe Next: D9cjd63FWQLDogszsMaRrYC1c14PdYWRW1mZeNUjfwT3 Diff:
Old | New | Differences | |
---|---|---|---|
140 | 140 | func abs (_x) = if ((_x > 0)) | |
141 | 141 | then _x | |
142 | 142 | else -(_x) | |
143 | + | ||
144 | + | ||
145 | + | func vmax (_x,_y) = if ((_x >= _y)) | |
146 | + | then _x | |
147 | + | else _y | |
143 | 148 | ||
144 | 149 | ||
145 | 150 | func toCompositeKey (_key,_address) = ((_key + "_") + _address) | |
318 | 323 | if ((priceImpact > maxPriceImpactValue)) | |
319 | 324 | then throw(((("Price impact " + toString(priceImpact)) + " > max price impact ") + toString(maxPriceImpactValue))) | |
320 | 325 | else { | |
321 | - | let $ | |
322 | - | let quoteAssetReserveAfter1 = $ | |
323 | - | let baseAssetReserveAfter1 = $ | |
324 | - | let totalPositionSizeAfter1 = $ | |
325 | - | let cumulativeNotionalAfter1 = $ | |
326 | + | let $t01215412357 = updateReserve(_isAdd, _quoteAssetAmount, amountBaseAssetBoughtAbs) | |
327 | + | let quoteAssetReserveAfter1 = $t01215412357._1 | |
328 | + | let baseAssetReserveAfter1 = $t01215412357._2 | |
329 | + | let totalPositionSizeAfter1 = $t01215412357._3 | |
330 | + | let cumulativeNotionalAfter1 = $t01215412357._4 | |
326 | 331 | $Tuple5(amountBaseAssetBought, quoteAssetReserveAfter1, baseAssetReserveAfter1, totalPositionSizeAfter1, cumulativeNotionalAfter1) | |
327 | 332 | } | |
328 | 333 | } | |
336 | 341 | } | |
337 | 342 | else 0 | |
338 | 343 | let signedMargin = ((_marginDelta - fundingPayment) + _oldPositionMargin) | |
339 | - | let $ | |
344 | + | let $t01310413231 = if ((0 > signedMargin)) | |
340 | 345 | then $Tuple2(0, abs(signedMargin)) | |
341 | 346 | else $Tuple2(abs(signedMargin), 0) | |
342 | - | let remainMargin = $ | |
343 | - | let badDebt = $ | |
347 | + | let remainMargin = $t01310413231._1 | |
348 | + | let badDebt = $t01310413231._2 | |
344 | 349 | $Tuple3(remainMargin, badDebt, fundingPayment) | |
345 | 350 | } | |
346 | 351 | ||
357 | 362 | else (_baseAssetReserve - _baseAssetAmount) | |
358 | 363 | let quoteAssetAfter = divd(k, baseAssetPoolAmountAfter) | |
359 | 364 | let quoteAssetSold = abs((quoteAssetAfter - _quoteAssetReserve)) | |
360 | - | let $ | |
361 | - | let quoteAssetReserveAfter1 = $ | |
362 | - | let baseAssetReserveAfter1 = $ | |
363 | - | let totalPositionSizeAfter1 = $ | |
364 | - | let cumulativeNotionalAfter1 = $ | |
365 | + | let $t01406914262 = updateReserve(!(_isAdd), quoteAssetSold, _baseAssetAmount) | |
366 | + | let quoteAssetReserveAfter1 = $t01406914262._1 | |
367 | + | let baseAssetReserveAfter1 = $t01406914262._2 | |
368 | + | let totalPositionSizeAfter1 = $t01406914262._3 | |
369 | + | let cumulativeNotionalAfter1 = $t01406914262._4 | |
365 | 370 | $Tuple7(quoteAssetSold, quoteAssetReserveAfter1, baseAssetReserveAfter1, totalPositionSizeAfter1, cumulativeNotionalAfter1, (totalLongPositionSize() - (if (_isAdd) | |
366 | 371 | then abs(_baseAssetAmount) | |
367 | 372 | else 0)), (totalShortPositionSize() - (if (!(_isAdd)) | |
395 | 400 | ||
396 | 401 | ||
397 | 402 | func getPositionNotionalAndUnrealizedPnl (_trader,_option) = { | |
398 | - | let $ | |
399 | - | let positionSize = $ | |
400 | - | let positionMargin = $ | |
401 | - | let positionOpenNotional = $ | |
402 | - | let positionLstUpdCPF = $ | |
403 | + | let $t01589416022 = getPosition(_trader) | |
404 | + | let positionSize = $t01589416022._1 | |
405 | + | let positionMargin = $t01589416022._2 | |
406 | + | let positionOpenNotional = $t01589416022._3 | |
407 | + | let positionLstUpdCPF = $t01589416022._4 | |
403 | 408 | let positionSizeAbs = abs(positionSize) | |
404 | 409 | if ((positionSizeAbs == 0)) | |
405 | 410 | then throw("Invalid position size") | |
407 | 412 | let isShort = (0 > positionSize) | |
408 | 413 | let positionNotional = if ((_option == PNL_OPTION_SPOT)) | |
409 | 414 | then { | |
410 | - | let $ | |
411 | - | let outPositionNotional = $ | |
412 | - | let x1 = $ | |
413 | - | let x2 = $ | |
414 | - | let x3 = $ | |
415 | + | let $t01626916376 = swapOutput(!(isShort), positionSizeAbs) | |
416 | + | let outPositionNotional = $t01626916376._1 | |
417 | + | let x1 = $t01626916376._2 | |
418 | + | let x2 = $t01626916376._3 | |
419 | + | let x3 = $t01626916376._4 | |
415 | 420 | outPositionNotional | |
416 | 421 | } | |
417 | 422 | else (positionSizeAbs * getOracleTwapPrice()) | |
427 | 432 | ||
428 | 433 | ||
429 | 434 | func getMarginRatioByOption (_trader,_option) = { | |
430 | - | let $ | |
431 | - | let positionSize = $ | |
432 | - | let positionMargin = $ | |
433 | - | let pon = $ | |
434 | - | let positionLstUpdCPF = $ | |
435 | - | let $ | |
436 | - | let positionNotional = $ | |
437 | - | let unrealizedPnl = $ | |
438 | - | let $ | |
439 | - | let remainMargin = $ | |
440 | - | let badDebt = $ | |
435 | + | let $t01704117152 = getPosition(_trader) | |
436 | + | let positionSize = $t01704117152._1 | |
437 | + | let positionMargin = $t01704117152._2 | |
438 | + | let pon = $t01704117152._3 | |
439 | + | let positionLstUpdCPF = $t01704117152._4 | |
440 | + | let $t01715817251 = getPositionNotionalAndUnrealizedPnl(_trader, _option) | |
441 | + | let positionNotional = $t01715817251._1 | |
442 | + | let unrealizedPnl = $t01715817251._2 | |
443 | + | let $t01725617422 = calcRemainMarginWithFundingPayment(positionSize, positionMargin, positionLstUpdCPF, unrealizedPnl) | |
444 | + | let remainMargin = $t01725617422._1 | |
445 | + | let badDebt = $t01725617422._2 | |
441 | 446 | calcMarginRatio(remainMargin, badDebt, positionNotional) | |
442 | 447 | } | |
443 | 448 | ||
446 | 451 | ||
447 | 452 | ||
448 | 453 | func internalClosePosition (_trader) = { | |
449 | - | let $ | |
450 | - | let positionSize = $ | |
451 | - | let positionMargin = $ | |
452 | - | let | |
453 | - | let positionLstUpdCPF = $ | |
454 | - | let $ | |
455 | - | let x1 = $ | |
456 | - | let unrealizedPnl = $ | |
457 | - | let $ | |
458 | - | let remainMargin = $ | |
459 | - | let badDebt = $ | |
454 | + | let $t01773817866 = getPosition(_trader) | |
455 | + | let positionSize = $t01773817866._1 | |
456 | + | let positionMargin = $t01773817866._2 | |
457 | + | let positionOpenNotional = $t01773817866._3 | |
458 | + | let positionLstUpdCPF = $t01773817866._4 | |
459 | + | let $t01787217959 = getPositionNotionalAndUnrealizedPnl(_trader, PNL_OPTION_SPOT) | |
460 | + | let x1 = $t01787217959._1 | |
461 | + | let unrealizedPnl = $t01787217959._2 | |
462 | + | let $t01796418132 = calcRemainMarginWithFundingPayment(positionSize, positionMargin, positionLstUpdCPF, unrealizedPnl) | |
463 | + | let remainMargin = $t01796418132._1 | |
464 | + | let badDebt = $t01796418132._2 | |
460 | 465 | let exchangedPositionSize = -(positionSize) | |
461 | 466 | let realizedPnl = unrealizedPnl | |
462 | 467 | let marginToVault = -(remainMargin) | |
463 | - | let $ | |
464 | - | let exchangedQuoteAssetAmount = $ | |
465 | - | let quoteAssetReserveAfter = $ | |
466 | - | let baseAssetReserveAfter = $ | |
467 | - | let totalPositionSizeAfter = $ | |
468 | - | let cumulativeNotionalAfter = $ | |
469 | - | let totalLongAfter = $ | |
470 | - | let totalShortAfter = $ | |
471 | - | let openInterestNotionalAfter = (openInterestNotional() - | |
468 | + | let $t01825918540 = swapOutput((positionSize > 0), abs(positionSize)) | |
469 | + | let exchangedQuoteAssetAmount = $t01825918540._1 | |
470 | + | let quoteAssetReserveAfter = $t01825918540._2 | |
471 | + | let baseAssetReserveAfter = $t01825918540._3 | |
472 | + | let totalPositionSizeAfter = $t01825918540._4 | |
473 | + | let cumulativeNotionalAfter = $t01825918540._5 | |
474 | + | let totalLongAfter = $t01825918540._6 | |
475 | + | let totalShortAfter = $t01825918540._7 | |
476 | + | let openInterestNotionalAfter = (openInterestNotional() - positionOpenNotional) | |
472 | 477 | $Tuple12(exchangedPositionSize, badDebt, realizedPnl, marginToVault, quoteAssetReserveAfter, baseAssetReserveAfter, totalPositionSizeAfter, cumulativeNotionalAfter, openInterestNotionalAfter, exchangedQuoteAssetAmount, totalLongAfter, totalShortAfter) | |
473 | 478 | } | |
474 | 479 | ||
633 | 638 | else paused()) | |
634 | 639 | then throw("Invalid decreasePosition parameters") | |
635 | 640 | else { | |
636 | - | let $ | |
637 | - | let oldPositionSize = $ | |
638 | - | let oldPositionMargin = $ | |
639 | - | let oldPositionOpenNotional = $ | |
640 | - | let oldPositionLstUpdCPF = $ | |
641 | + | let $t02838128533 = getPosition(toString(i.caller)) | |
642 | + | let oldPositionSize = $t02838128533._1 | |
643 | + | let oldPositionMargin = $t02838128533._2 | |
644 | + | let oldPositionOpenNotional = $t02838128533._3 | |
645 | + | let oldPositionLstUpdCPF = $t02838128533._4 | |
641 | 646 | let _direction = if ((oldPositionSize > 0)) | |
642 | 647 | then DIR_SHORT | |
643 | 648 | else DIR_LONG | |
644 | 649 | let isAdd = (_direction == DIR_LONG) | |
645 | 650 | let openNotional = muld(_amount, _leverage) | |
646 | - | let $ | |
647 | - | let oldPositionNotional = $ | |
648 | - | let unrealizedPnl = $ | |
649 | - | let $ | |
651 | + | let $t02870628822 = getPositionNotionalAndUnrealizedPnl(toString(i.caller), PNL_OPTION_SPOT) | |
652 | + | let oldPositionNotional = $t02870628822._1 | |
653 | + | let unrealizedPnl = $t02870628822._2 | |
654 | + | let $t02882831377 = if ((oldPositionNotional > openNotional)) | |
650 | 655 | then { | |
651 | - | let $ | |
652 | - | let exchangedPositionSize = $ | |
653 | - | let quoteAssetReserveAfter = $ | |
654 | - | let baseAssetReserveAfter = $ | |
655 | - | let totalPositionSizeAfter = $ | |
656 | - | let cumulativeNotionalAfter = $ | |
656 | + | let $t02920529424 = swapInput(isAdd, openNotional) | |
657 | + | let exchangedPositionSize = $t02920529424._1 | |
658 | + | let quoteAssetReserveAfter = $t02920529424._2 | |
659 | + | let baseAssetReserveAfter = $t02920529424._3 | |
660 | + | let totalPositionSizeAfter = $t02920529424._4 | |
661 | + | let cumulativeNotionalAfter = $t02920529424._5 | |
657 | 662 | let exchangedPositionSizeAbs = abs(exchangedPositionSize) | |
658 | 663 | if (if ((_minBaseAssetAmount != 0)) | |
659 | 664 | then (_minBaseAssetAmount > exchangedPositionSizeAbs) | |
661 | 666 | then throw(((("Too little base asset exchanged, got " + toString(exchangedPositionSizeAbs)) + " expected ") + toString(_minBaseAssetAmount))) | |
662 | 667 | else { | |
663 | 668 | let realizedPnl = divd(muld(unrealizedPnl, exchangedPositionSizeAbs), abs(oldPositionSize)) | |
664 | - | let $ | |
665 | - | let remainMargin = $ | |
666 | - | let badDebt = $ | |
667 | - | let fundingPayment = $ | |
669 | + | let $t02986130106 = calcRemainMarginWithFundingPayment(oldPositionSize, oldPositionMargin, oldPositionLstUpdCPF, realizedPnl) | |
670 | + | let remainMargin = $t02986130106._1 | |
671 | + | let badDebt = $t02986130106._2 | |
672 | + | let fundingPayment = $t02986130106._3 | |
668 | 673 | let exchangedQuoteAssetAmount = openNotional | |
669 | 674 | let unrealizedPnlAfter = (unrealizedPnl - realizedPnl) | |
670 | 675 | let remainOpenNotional = if ((oldPositionSize > 0)) | |
679 | 684 | } | |
680 | 685 | } | |
681 | 686 | else throw("Close position first") | |
682 | - | let newPositionSize = $ | |
683 | - | let newPositionRemainMargin = $ | |
684 | - | let newPositionOpenNotional = $ | |
685 | - | let newPositionLatestCPF = $ | |
686 | - | let baseAssetReserveAfter = $ | |
687 | - | let quoteAssetReserveAfter = $ | |
688 | - | let totalPositionSizeAfter = $ | |
689 | - | let cumulativeNotionalAfter = $ | |
690 | - | let openInterestNotionalAfter = $ | |
691 | - | let totalLongAfter = $ | |
692 | - | let totalShortAfter = $ | |
687 | + | let newPositionSize = $t02882831377._1 | |
688 | + | let newPositionRemainMargin = $t02882831377._2 | |
689 | + | let newPositionOpenNotional = $t02882831377._3 | |
690 | + | let newPositionLatestCPF = $t02882831377._4 | |
691 | + | let baseAssetReserveAfter = $t02882831377._5 | |
692 | + | let quoteAssetReserveAfter = $t02882831377._6 | |
693 | + | let totalPositionSizeAfter = $t02882831377._7 | |
694 | + | let cumulativeNotionalAfter = $t02882831377._8 | |
695 | + | let openInterestNotionalAfter = $t02882831377._9 | |
696 | + | let totalLongAfter = $t02882831377._10 | |
697 | + | let totalShortAfter = $t02882831377._11 | |
693 | 698 | (updatePosition(toString(i.caller), newPositionSize, newPositionRemainMargin, newPositionOpenNotional, newPositionLatestCPF) ++ updateAmm(quoteAssetReserveAfter, baseAssetReserveAfter, totalPositionSizeAfter, cumulativeNotionalAfter, openInterestNotionalAfter, totalLongAfter, totalShortAfter)) | |
694 | 699 | } | |
695 | 700 | ||
719 | 724 | else { | |
720 | 725 | let feeAmount = muld(_rawAmount, fee()) | |
721 | 726 | let _amount = (_rawAmount - feeAmount) | |
722 | - | let $ | |
723 | - | let oldPositionSize = $ | |
724 | - | let oldPositionMargin = $ | |
725 | - | let oldPositionOpenNotional = $ | |
726 | - | let oldPositionLstUpdCPF = $ | |
727 | + | let $t03241332565 = getPosition(toString(i.caller)) | |
728 | + | let oldPositionSize = $t03241332565._1 | |
729 | + | let oldPositionMargin = $t03241332565._2 | |
730 | + | let oldPositionOpenNotional = $t03241332565._3 | |
731 | + | let oldPositionLstUpdCPF = $t03241332565._4 | |
727 | 732 | let isNewPosition = (oldPositionSize == 0) | |
728 | 733 | let isSameDirection = if ((oldPositionSize > 0)) | |
729 | 734 | then (_direction == DIR_LONG) | |
732 | 737 | then isSameDirection | |
733 | 738 | else false | |
734 | 739 | let isAdd = (_direction == DIR_LONG) | |
735 | - | let $ | |
740 | + | let $t03285435243 = if (if (isNewPosition) | |
736 | 741 | then true | |
737 | 742 | else expandExisting) | |
738 | 743 | then { | |
739 | 744 | let openNotional = muld(_amount, _leverage) | |
740 | - | let $ | |
741 | - | let amountBaseAssetBought = $ | |
742 | - | let quoteAssetReserveAfter = $ | |
743 | - | let baseAssetReserveAfter = $ | |
744 | - | let totalPositionSizeAfter = $ | |
745 | - | let cumulativeNotionalAfter = $ | |
745 | + | let $t03327833484 = swapInput(isAdd, openNotional) | |
746 | + | let amountBaseAssetBought = $t03327833484._1 | |
747 | + | let quoteAssetReserveAfter = $t03327833484._2 | |
748 | + | let baseAssetReserveAfter = $t03327833484._3 | |
749 | + | let totalPositionSizeAfter = $t03327833484._4 | |
750 | + | let cumulativeNotionalAfter = $t03327833484._5 | |
746 | 751 | if (if ((_minBaseAssetAmount != 0)) | |
747 | 752 | then (_minBaseAssetAmount > abs(amountBaseAssetBought)) | |
748 | 753 | else false) | |
750 | 755 | else { | |
751 | 756 | let newPositionSize = (oldPositionSize + amountBaseAssetBought) | |
752 | 757 | let increaseMarginRequirement = divd(openNotional, _leverage) | |
753 | - | let $ | |
754 | - | let remainMargin = $ | |
755 | - | let x1 = $ | |
756 | - | let x2 = $ | |
758 | + | let $t03386534104 = calcRemainMarginWithFundingPayment(oldPositionSize, oldPositionMargin, oldPositionLstUpdCPF, increaseMarginRequirement) | |
759 | + | let remainMargin = $t03386534104._1 | |
760 | + | let x1 = $t03386534104._2 | |
761 | + | let x2 = $t03386534104._3 | |
757 | 762 | $Tuple11(newPositionSize, remainMargin, (oldPositionOpenNotional + openNotional), latestCumulativePremiumFraction(newPositionSize), baseAssetReserveAfter, quoteAssetReserveAfter, totalPositionSizeAfter, cumulativeNotionalAfter, (openInterestNotional() + openNotional), (totalLongPositionSize() + (if ((newPositionSize > 0)) | |
758 | 763 | then abs(amountBaseAssetBought) | |
759 | 764 | else 0)), (totalShortPositionSize() + (if ((0 > newPositionSize)) | |
763 | 768 | } | |
764 | 769 | else { | |
765 | 770 | let openNotional = muld(_amount, _leverage) | |
766 | - | let $ | |
767 | - | let oldPositionNotional = $ | |
768 | - | let unrealizedPnl = $ | |
771 | + | let $t03493635052 = getPositionNotionalAndUnrealizedPnl(toString(i.caller), PNL_OPTION_SPOT) | |
772 | + | let oldPositionNotional = $t03493635052._1 | |
773 | + | let unrealizedPnl = $t03493635052._2 | |
769 | 774 | if ((oldPositionNotional > openNotional)) | |
770 | 775 | then throw("Use decreasePosition to decrease position size") | |
771 | 776 | else throw("Close position first") | |
772 | 777 | } | |
773 | - | let newPositionSize = $ | |
774 | - | let newPositionRemainMargin = $ | |
775 | - | let newPositionOpenNotional = $ | |
776 | - | let newPositionLatestCPF = $ | |
777 | - | let baseAssetReserveAfter = $ | |
778 | - | let quoteAssetReserveAfter = $ | |
779 | - | let totalPositionSizeAfter = $ | |
780 | - | let cumulativeNotionalAfter = $ | |
781 | - | let openInterestNotionalAfter = $ | |
782 | - | let totalLongAfter = $ | |
783 | - | let totalShortAfter = $ | |
778 | + | let newPositionSize = $t03285435243._1 | |
779 | + | let newPositionRemainMargin = $t03285435243._2 | |
780 | + | let newPositionOpenNotional = $t03285435243._3 | |
781 | + | let newPositionLatestCPF = $t03285435243._4 | |
782 | + | let baseAssetReserveAfter = $t03285435243._5 | |
783 | + | let quoteAssetReserveAfter = $t03285435243._6 | |
784 | + | let totalPositionSizeAfter = $t03285435243._7 | |
785 | + | let cumulativeNotionalAfter = $t03285435243._8 | |
786 | + | let openInterestNotionalAfter = $t03285435243._9 | |
787 | + | let totalLongAfter = $t03285435243._10 | |
788 | + | let totalShortAfter = $t03285435243._11 | |
784 | 789 | let feeToStakers = (feeAmount / 2) | |
785 | 790 | let feeToInsurance = (feeAmount - feeToStakers) | |
786 | 791 | let stake = invoke(quoteAssetStaking(), "lockNeutrinoSP", [toString(stakingAddress()), ALL_FEES], [AttachedPayment(quoteAsset(), _amount)]) | |
811 | 816 | else { | |
812 | 817 | let feeAmount = muld(_rawAmount, fee()) | |
813 | 818 | let _amount = (_rawAmount - feeAmount) | |
814 | - | let $ | |
815 | - | let oldPositionSize = $ | |
816 | - | let oldPositionMargin = $ | |
817 | - | let oldPositionOpenNotional = $ | |
818 | - | let oldPositionLstUpdCPF = $ | |
819 | + | let $t03651936671 = getPosition(toString(i.caller)) | |
820 | + | let oldPositionSize = $t03651936671._1 | |
821 | + | let oldPositionMargin = $t03651936671._2 | |
822 | + | let oldPositionOpenNotional = $t03651936671._3 | |
823 | + | let oldPositionLstUpdCPF = $t03651936671._4 | |
819 | 824 | let feeToStakers = (feeAmount / 2) | |
820 | 825 | let feeToInsurance = (feeAmount - feeToStakers) | |
821 | 826 | let stake = invoke(quoteAssetStaking(), "lockNeutrinoSP", [toString(stakingAddress()), ALL_FEES], [AttachedPayment(quoteAsset(), _amount)]) | |
842 | 847 | else paused()) | |
843 | 848 | then throw("Invalid removeMargin parameters") | |
844 | 849 | else { | |
845 | - | let $ | |
846 | - | let oldPositionSize = $ | |
847 | - | let oldPositionMargin = $ | |
848 | - | let oldPositionOpenNotional = $ | |
849 | - | let oldPositionLstUpdCPF = $ | |
850 | + | let $t03759137743 = getPosition(toString(i.caller)) | |
851 | + | let oldPositionSize = $t03759137743._1 | |
852 | + | let oldPositionMargin = $t03759137743._2 | |
853 | + | let oldPositionOpenNotional = $t03759137743._3 | |
854 | + | let oldPositionLstUpdCPF = $t03759137743._4 | |
850 | 855 | let marginDelta = -(_amount) | |
851 | - | let $ | |
852 | - | let remainMargin = $ | |
853 | - | let badDebt = $ | |
856 | + | let $t03778037959 = calcRemainMarginWithFundingPayment(oldPositionSize, oldPositionMargin, oldPositionLstUpdCPF, marginDelta) | |
857 | + | let remainMargin = $t03778037959._1 | |
858 | + | let badDebt = $t03778037959._2 | |
854 | 859 | if ((badDebt != 0)) | |
855 | 860 | then throw("Invalid removed margin amount") | |
856 | 861 | else { | |
876 | 881 | else paused()) | |
877 | 882 | then throw("Invalid closePosition parameters") | |
878 | 883 | else { | |
879 | - | let $ | |
880 | - | let x1 = $ | |
881 | - | let positionBadDebt = $ | |
882 | - | let realizedPnl = $ | |
883 | - | let marginToVault = $ | |
884 | - | let quoteAssetReserveAfter = $ | |
885 | - | let baseAssetReserveAfter = $ | |
886 | - | let totalPositionSizeAfter = $ | |
887 | - | let cumulativeNotionalAfter = $ | |
888 | - | let openInterestNotionalAfter = $ | |
889 | - | let x2 = $ | |
890 | - | let totalLongAfter = $ | |
891 | - | let totalShortAfter = $ | |
884 | + | let $t03905539439 = internalClosePosition(toString(i.caller)) | |
885 | + | let x1 = $t03905539439._1 | |
886 | + | let positionBadDebt = $t03905539439._2 | |
887 | + | let realizedPnl = $t03905539439._3 | |
888 | + | let marginToVault = $t03905539439._4 | |
889 | + | let quoteAssetReserveAfter = $t03905539439._5 | |
890 | + | let baseAssetReserveAfter = $t03905539439._6 | |
891 | + | let totalPositionSizeAfter = $t03905539439._7 | |
892 | + | let cumulativeNotionalAfter = $t03905539439._8 | |
893 | + | let openInterestNotionalAfter = $t03905539439._9 | |
894 | + | let x2 = $t03905539439._10 | |
895 | + | let totalLongAfter = $t03905539439._11 | |
896 | + | let totalShortAfter = $t03905539439._12 | |
892 | 897 | if ((positionBadDebt > 0)) | |
893 | 898 | then throw("Unable to close position with bad debt") | |
894 | 899 | else { | |
895 | 900 | let withdrawAmount = abs(marginToVault) | |
896 | 901 | let ammBalance = (cbalance() - withdrawAmount) | |
897 | - | let $ | |
902 | + | let $t03964839790 = if ((0 > ammBalance)) | |
898 | 903 | then $Tuple2(0, abs(ammBalance)) | |
899 | 904 | else $Tuple2(ammBalance, 0) | |
900 | - | let ammNewBalance = $ | |
901 | - | let getFromInsurance = $ | |
905 | + | let ammNewBalance = $t03964839790._1 | |
906 | + | let getFromInsurance = $t03964839790._2 | |
902 | 907 | let x = if ((getFromInsurance > 0)) | |
903 | 908 | then { | |
904 | 909 | let withdrawInsurance = invoke(insuranceAddress(), "withdraw", [getFromInsurance], nil) | |
922 | 927 | ||
923 | 928 | @Callable(i) | |
924 | 929 | func liquidate (_trader) = { | |
930 | + | let spotMarginRatio = getMarginRatioByOption(_trader, PNL_OPTION_SPOT) | |
925 | 931 | let marginRatio = if (isOverFluctuationLimit()) | |
926 | - | then getMarginRatioByOption(_trader, PNL_OPTION_ORACLE) | |
927 | - | else getMarginRatioByOption(_trader, PNL_OPTION_SPOT) | |
932 | + | then { | |
933 | + | let oracleMarginRatio = getMarginRatioByOption(_trader, PNL_OPTION_ORACLE) | |
934 | + | vmax(spotMarginRatio, oracleMarginRatio) | |
935 | + | } | |
936 | + | else spotMarginRatio | |
928 | 937 | if (if (if (if (!(requireMoreMarginRatio(marginRatio, maintenanceMarginRatio(), false))) | |
929 | 938 | then true | |
930 | 939 | else !(requireOpenPosition(_trader))) | |
934 | 943 | else paused()) | |
935 | 944 | then throw("Unable to liquidate") | |
936 | 945 | else { | |
937 | - | let $ | |
938 | - | let x1 = $ | |
939 | - | let badDebt = $ | |
940 | - | let x2 = $ | |
941 | - | let | |
942 | - | let quoteAssetReserveAfter = $ | |
943 | - | let baseAssetReserveAfter = $ | |
944 | - | let totalPositionSizeAfter = $ | |
945 | - | let cumulativeNotionalAfter = $ | |
946 | - | let openInterestNotionalAfter = $ | |
947 | - | let exchangedQuoteAssetAmount = $ | |
948 | - | let totalLongAfter = $ | |
949 | - | let totalShortAfter = $ | |
946 | + | let $t04133841754 = internalClosePosition(_trader) | |
947 | + | let x1 = $t04133841754._1 | |
948 | + | let badDebt = $t04133841754._2 | |
949 | + | let x2 = $t04133841754._3 | |
950 | + | let x3 = $t04133841754._4 | |
951 | + | let quoteAssetReserveAfter = $t04133841754._5 | |
952 | + | let baseAssetReserveAfter = $t04133841754._6 | |
953 | + | let totalPositionSizeAfter = $t04133841754._7 | |
954 | + | let cumulativeNotionalAfter = $t04133841754._8 | |
955 | + | let openInterestNotionalAfter = $t04133841754._9 | |
956 | + | let exchangedQuoteAssetAmount = $t04133841754._10 | |
957 | + | let totalLongAfter = $t04133841754._11 | |
958 | + | let totalShortAfter = $t04133841754._12 | |
950 | 959 | let liquidationPenalty = muld(exchangedQuoteAssetAmount, liquidationFeeRatio()) | |
951 | 960 | let feeToLiquidator = (liquidationPenalty / 2) | |
952 | 961 | let feeToInsurance = (liquidationPenalty - feeToLiquidator) | |
953 | 962 | let ammBalance = (cbalance() - liquidationPenalty) | |
954 | - | let $ | |
963 | + | let $t04215242287 = if ((0 > ammBalance)) | |
955 | 964 | then $Tuple2(0, abs(ammBalance)) | |
956 | 965 | else $Tuple2(ammBalance, 0) | |
957 | - | let newAmmBalance = $ | |
958 | - | let takeFromInsurance = $ | |
966 | + | let newAmmBalance = $t04215242287._1 | |
967 | + | let takeFromInsurance = $t04215242287._2 | |
959 | 968 | let x = if ((takeFromInsurance > 0)) | |
960 | 969 | then { | |
961 | 970 | let withdrawInsurance = invoke(insuranceAddress(), "withdraw", [takeFromInsurance], nil) | |
995 | 1004 | let underlyingPrice = getOracleTwapPrice() | |
996 | 1005 | let spotTwapPrice = getTwapSpotPrice() | |
997 | 1006 | let premium = (spotTwapPrice - underlyingPrice) | |
998 | - | let $ | |
1007 | + | let $t04366344998 = if (if ((totalShortPositionSize() == 0)) | |
999 | 1008 | then true | |
1000 | 1009 | else (totalLongPositionSize() == 0)) | |
1001 | 1010 | then $Tuple2(0, 0) | |
1010 | 1019 | let shortPremiumFraction = divd(muld(longPremiumFraction, totalLongPositionSize()), totalShortPositionSize()) | |
1011 | 1020 | $Tuple2(shortPremiumFraction, longPremiumFraction) | |
1012 | 1021 | } | |
1013 | - | let shortPremiumFraction = $ | |
1014 | - | let longPremiumFraction = $ | |
1022 | + | let shortPremiumFraction = $t04366344998._1 | |
1023 | + | let longPremiumFraction = $t04366344998._2 | |
1015 | 1024 | updateFunding((fundingBlockTimestamp + fundingPeriodSeconds()), (latestLongCumulativePremiumFraction() + longPremiumFraction), (latestShortCumulativePremiumFraction() + shortPremiumFraction), divd(longPremiumFraction, underlyingPrice), divd(shortPremiumFraction, underlyingPrice)) | |
1016 | 1025 | } | |
1017 | 1026 | } | |
1020 | 1029 | ||
1021 | 1030 | @Callable(i) | |
1022 | 1031 | func v_get (_trader) = { | |
1023 | - | let $ | |
1024 | - | let x1 = $ | |
1025 | - | let x2 = $ | |
1026 | - | let x3 = $ | |
1027 | - | let x4 = $ | |
1032 | + | let $t04537345426 = internalClosePosition(_trader) | |
1033 | + | let x1 = $t04537345426._1 | |
1034 | + | let x2 = $t04537345426._2 | |
1035 | + | let x3 = $t04537345426._3 | |
1036 | + | let x4 = $t04537345426._4 | |
1028 | 1037 | throw((((s(x2) + s(x3)) + s(x4)) + s(getMarginRatio(_trader)))) | |
1029 | 1038 | } | |
1030 | 1039 | ||
1032 | 1041 | ||
1033 | 1042 | @Callable(i) | |
1034 | 1043 | func view_calcRemainMarginWithFundingPayment (_trader) = { | |
1035 | - | let $ | |
1036 | - | let positionSize = $ | |
1037 | - | let positionMargin = $ | |
1038 | - | let pon = $ | |
1039 | - | let positionLstUpdCPF = $ | |
1040 | - | let $ | |
1041 | - | let positionNotional = $ | |
1042 | - | let unrealizedPnl = $ | |
1043 | - | let $ | |
1044 | - | let remainMargin = $ | |
1045 | - | let badDebt = $ | |
1046 | - | let fundingPayment = $ | |
1044 | + | let $t04557345684 = getPosition(_trader) | |
1045 | + | let positionSize = $t04557345684._1 | |
1046 | + | let positionMargin = $t04557345684._2 | |
1047 | + | let pon = $t04557345684._3 | |
1048 | + | let positionLstUpdCPF = $t04557345684._4 | |
1049 | + | let $t04568945790 = getPositionNotionalAndUnrealizedPnl(_trader, PNL_OPTION_SPOT) | |
1050 | + | let positionNotional = $t04568945790._1 | |
1051 | + | let unrealizedPnl = $t04568945790._2 | |
1052 | + | let $t04579545977 = calcRemainMarginWithFundingPayment(positionSize, positionMargin, positionLstUpdCPF, unrealizedPnl) | |
1053 | + | let remainMargin = $t04579545977._1 | |
1054 | + | let badDebt = $t04579545977._2 | |
1055 | + | let fundingPayment = $t04579545977._3 | |
1047 | 1056 | throw(((s(remainMargin) + s(fundingPayment)) + s(getMarginRatio(_trader)))) | |
1048 | 1057 | } | |
1049 | 1058 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 5 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let k_ora_key = "k_ora_key" | |
5 | 5 | ||
6 | 6 | let k_ora_block_key = "k_ora_block_key" | |
7 | 7 | ||
8 | 8 | let k_ora = "k_ora" | |
9 | 9 | ||
10 | 10 | let k_balance = "k_balance" | |
11 | 11 | ||
12 | 12 | let k_positionSize = "k_positionSize" | |
13 | 13 | ||
14 | 14 | let k_positionMargin = "k_positionMargin" | |
15 | 15 | ||
16 | 16 | let k_positionOpenNotional = "k_positionOpenNotional" | |
17 | 17 | ||
18 | 18 | let k_positionLastUpdatedCumulativePremiumFraction = "k_positionFraction" | |
19 | 19 | ||
20 | 20 | let k_initialized = "k_initialized" | |
21 | 21 | ||
22 | 22 | let k_paused = "k_paused" | |
23 | 23 | ||
24 | 24 | let k_fee = "k_fee" | |
25 | 25 | ||
26 | 26 | let k_fundingPeriod = "k_fundingPeriod" | |
27 | 27 | ||
28 | 28 | let k_initMarginRatio = "k_initMarginRatio" | |
29 | 29 | ||
30 | 30 | let k_maintenanceMarginRatio = "k_mmr" | |
31 | 31 | ||
32 | 32 | let k_liquidationFeeRatio = "k_liquidationFeeRatio" | |
33 | 33 | ||
34 | 34 | let k_spreadLimit = "k_spreadLimit" | |
35 | 35 | ||
36 | 36 | let k_maxPriceImpact = "k_maxPriceImpact" | |
37 | 37 | ||
38 | 38 | let k_lastDataStr = "k_lastDataStr" | |
39 | 39 | ||
40 | 40 | let k_lastMinuteId = "k_lastMinuteId" | |
41 | 41 | ||
42 | 42 | let k_twapDataLastCumulativePrice = "k_twapDataLastCumulativePrice" | |
43 | 43 | ||
44 | 44 | let k_twapDataLastPrice = "k_twapDataLastPrice" | |
45 | 45 | ||
46 | 46 | let k_twapDataPreviousMinuteId = "k_twapDataPreviousMinuteId" | |
47 | 47 | ||
48 | 48 | let k_latestLongCumulativePremiumFraction = "k_latestLongPremiumFraction" | |
49 | 49 | ||
50 | 50 | let k_latestShortCumulativePremiumFraction = "k_latestShortPremiumFraction" | |
51 | 51 | ||
52 | 52 | let k_nextFundingBlock = "k_nextFundingBlockMinTimestamp" | |
53 | 53 | ||
54 | 54 | let k_longFundingRate = "k_longFundingRate" | |
55 | 55 | ||
56 | 56 | let k_shortFundingRate = "k_shortFundingRate" | |
57 | 57 | ||
58 | 58 | let k_quoteAssetReserve = "k_qtAstR" | |
59 | 59 | ||
60 | 60 | let k_baseAssetReserve = "k_bsAstR" | |
61 | 61 | ||
62 | 62 | let k_totalPositionSize = "k_totalPositionSize" | |
63 | 63 | ||
64 | 64 | let k_totalLongPositionSize = "k_totalLongPositionSize" | |
65 | 65 | ||
66 | 66 | let k_totalShortPositionSize = "k_totalShortPositionSize" | |
67 | 67 | ||
68 | 68 | let k_cumulativeNotional = "k_cumulativeNotional" | |
69 | 69 | ||
70 | 70 | let k_openInterestNotional = "k_openInterestNotional" | |
71 | 71 | ||
72 | 72 | let k_coordinatorAddress = "k_coordinatorAddress" | |
73 | 73 | ||
74 | 74 | let k_insurance_address = "k_insurance_address" | |
75 | 75 | ||
76 | 76 | let k_admin_address = "k_admin_address" | |
77 | 77 | ||
78 | 78 | let k_admin_public_key = "k_admin_public_key" | |
79 | 79 | ||
80 | 80 | let k_quote_asset = "k_quote_asset" | |
81 | 81 | ||
82 | 82 | let k_quote_staking = "k_quote_staking" | |
83 | 83 | ||
84 | 84 | let k_staking_address = "k_staking_address" | |
85 | 85 | ||
86 | 86 | func coordinator () = valueOrErrorMessage(addressFromString(getStringValue(this, k_coordinatorAddress)), "Coordinator not set") | |
87 | 87 | ||
88 | 88 | ||
89 | 89 | func adminAddress () = addressFromString(getStringValue(coordinator(), k_admin_address)) | |
90 | 90 | ||
91 | 91 | ||
92 | 92 | func adminPublicKey () = fromBase58String(getStringValue(coordinator(), k_admin_public_key)) | |
93 | 93 | ||
94 | 94 | ||
95 | 95 | func quoteAsset () = fromBase58String(getStringValue(coordinator(), k_quote_asset)) | |
96 | 96 | ||
97 | 97 | ||
98 | 98 | func quoteAssetStaking () = valueOrErrorMessage(addressFromString(getStringValue(coordinator(), k_quote_staking)), "Quote asset staking not set") | |
99 | 99 | ||
100 | 100 | ||
101 | 101 | func stakingAddress () = valueOrErrorMessage(addressFromString(getStringValue(coordinator(), k_staking_address)), "Insurance not set") | |
102 | 102 | ||
103 | 103 | ||
104 | 104 | func insuranceAddress () = valueOrErrorMessage(addressFromString(getStringValue(coordinator(), k_insurance_address)), "Insurance not set") | |
105 | 105 | ||
106 | 106 | ||
107 | 107 | let DIR_LONG = 1 | |
108 | 108 | ||
109 | 109 | let DIR_SHORT = 2 | |
110 | 110 | ||
111 | 111 | let FUNDING_BLOCK_INTERVAL = 60 | |
112 | 112 | ||
113 | 113 | let TWAP_INTERVAL = 15 | |
114 | 114 | ||
115 | 115 | let ORACLE_INTERVAL = 15 | |
116 | 116 | ||
117 | 117 | let SECONDS = 1000 | |
118 | 118 | ||
119 | 119 | let DECIMAL_UNIT = (1 * (((((10 * 10) * 10) * 10) * 10) * 10)) | |
120 | 120 | ||
121 | 121 | let HUNDRED_PERCENT = (100 * DECIMAL_UNIT) | |
122 | 122 | ||
123 | 123 | let ONE_DAY = (86400 * DECIMAL_UNIT) | |
124 | 124 | ||
125 | 125 | let ALL_FEES = 100 | |
126 | 126 | ||
127 | 127 | let PNL_OPTION_SPOT = 1 | |
128 | 128 | ||
129 | 129 | let PNL_OPTION_ORACLE = 2 | |
130 | 130 | ||
131 | 131 | func s (_x) = (toString(_x) + ",") | |
132 | 132 | ||
133 | 133 | ||
134 | 134 | func divd (_x,_y) = fraction(_x, DECIMAL_UNIT, _y, HALFEVEN) | |
135 | 135 | ||
136 | 136 | ||
137 | 137 | func muld (_x,_y) = fraction(_x, _y, DECIMAL_UNIT, HALFEVEN) | |
138 | 138 | ||
139 | 139 | ||
140 | 140 | func abs (_x) = if ((_x > 0)) | |
141 | 141 | then _x | |
142 | 142 | else -(_x) | |
143 | + | ||
144 | + | ||
145 | + | func vmax (_x,_y) = if ((_x >= _y)) | |
146 | + | then _x | |
147 | + | else _y | |
143 | 148 | ||
144 | 149 | ||
145 | 150 | func toCompositeKey (_key,_address) = ((_key + "_") + _address) | |
146 | 151 | ||
147 | 152 | ||
148 | 153 | func listToStr (_list) = { | |
149 | 154 | func _join (accumulator,val) = ((accumulator + val) + ",") | |
150 | 155 | ||
151 | 156 | let newListStr = { | |
152 | 157 | let $l = _list | |
153 | 158 | let $s = size($l) | |
154 | 159 | let $acc0 = "" | |
155 | 160 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
156 | 161 | then $a | |
157 | 162 | else _join($a, $l[$i]) | |
158 | 163 | ||
159 | 164 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
160 | 165 | then $a | |
161 | 166 | else throw("List size exceeds 20") | |
162 | 167 | ||
163 | 168 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20) | |
164 | 169 | } | |
165 | 170 | let newListStrU = dropRight(newListStr, 1) | |
166 | 171 | let newListStrR = if ((take(newListStrU, 1) == ",")) | |
167 | 172 | then drop(newListStrU, 1) | |
168 | 173 | else newListStrU | |
169 | 174 | newListStrR | |
170 | 175 | } | |
171 | 176 | ||
172 | 177 | ||
173 | 178 | func strToList (_str) = split(_str, ",") | |
174 | 179 | ||
175 | 180 | ||
176 | 181 | func pushToQueue (_list,_maxSize,_value) = if ((size(_list) > _maxSize)) | |
177 | 182 | then (removeByIndex(_list, 0) :+ _value) | |
178 | 183 | else (_list :+ _value) | |
179 | 184 | ||
180 | 185 | ||
181 | 186 | func int (k) = valueOrErrorMessage(getInteger(this, k), ("no value for " + k)) | |
182 | 187 | ||
183 | 188 | ||
184 | 189 | func cbalance () = int(k_balance) | |
185 | 190 | ||
186 | 191 | ||
187 | 192 | func fee () = int(k_fee) | |
188 | 193 | ||
189 | 194 | ||
190 | 195 | func initMarginRatio () = int(k_initMarginRatio) | |
191 | 196 | ||
192 | 197 | ||
193 | 198 | func qtAstR () = int(k_quoteAssetReserve) | |
194 | 199 | ||
195 | 200 | ||
196 | 201 | func bsAstR () = int(k_baseAssetReserve) | |
197 | 202 | ||
198 | 203 | ||
199 | 204 | func totalPositionSize () = int(k_totalPositionSize) | |
200 | 205 | ||
201 | 206 | ||
202 | 207 | func cumulativeNotional () = int(k_cumulativeNotional) | |
203 | 208 | ||
204 | 209 | ||
205 | 210 | func openInterestNotional () = int(k_openInterestNotional) | |
206 | 211 | ||
207 | 212 | ||
208 | 213 | func nextFundingBlockTimestamp () = int(k_nextFundingBlock) | |
209 | 214 | ||
210 | 215 | ||
211 | 216 | func fundingPeriodRaw () = int(k_fundingPeriod) | |
212 | 217 | ||
213 | 218 | ||
214 | 219 | func fundingPeriodDecimal () = (fundingPeriodRaw() * DECIMAL_UNIT) | |
215 | 220 | ||
216 | 221 | ||
217 | 222 | func fundingPeriodSeconds () = (fundingPeriodRaw() * SECONDS) | |
218 | 223 | ||
219 | 224 | ||
220 | 225 | func maintenanceMarginRatio () = int(k_maintenanceMarginRatio) | |
221 | 226 | ||
222 | 227 | ||
223 | 228 | func liquidationFeeRatio () = int(k_liquidationFeeRatio) | |
224 | 229 | ||
225 | 230 | ||
226 | 231 | func spreadLimit () = int(k_spreadLimit) | |
227 | 232 | ||
228 | 233 | ||
229 | 234 | func maxPriceImpact () = int(k_maxPriceImpact) | |
230 | 235 | ||
231 | 236 | ||
232 | 237 | func latestLongCumulativePremiumFraction () = int(k_latestLongCumulativePremiumFraction) | |
233 | 238 | ||
234 | 239 | ||
235 | 240 | func latestShortCumulativePremiumFraction () = int(k_latestShortCumulativePremiumFraction) | |
236 | 241 | ||
237 | 242 | ||
238 | 243 | func totalShortPositionSize () = int(k_totalShortPositionSize) | |
239 | 244 | ||
240 | 245 | ||
241 | 246 | func totalLongPositionSize () = int(k_totalLongPositionSize) | |
242 | 247 | ||
243 | 248 | ||
244 | 249 | func requireMoreMarginRatio (_marginRatio,_baseMarginRatio,_largerThanOrEqualTo) = { | |
245 | 250 | let remainingMarginRatio = (_marginRatio - _baseMarginRatio) | |
246 | 251 | if (if (_largerThanOrEqualTo) | |
247 | 252 | then (0 > remainingMarginRatio) | |
248 | 253 | else false) | |
249 | 254 | then throw("Invalid margin") | |
250 | 255 | else if (if (!(_largerThanOrEqualTo)) | |
251 | 256 | then (remainingMarginRatio >= 0) | |
252 | 257 | else false) | |
253 | 258 | then throw("Invalid margin") | |
254 | 259 | else true | |
255 | 260 | } | |
256 | 261 | ||
257 | 262 | ||
258 | 263 | func latestCumulativePremiumFraction (_positionSize) = if ((_positionSize == 0)) | |
259 | 264 | then throw("Should not be called with _positionSize == 0") | |
260 | 265 | else if ((_positionSize > 0)) | |
261 | 266 | then latestLongCumulativePremiumFraction() | |
262 | 267 | else latestShortCumulativePremiumFraction() | |
263 | 268 | ||
264 | 269 | ||
265 | 270 | func getPosition (_trader) = { | |
266 | 271 | let positionSizeOpt = getInteger(this, toCompositeKey(k_positionSize, _trader)) | |
267 | 272 | match positionSizeOpt { | |
268 | 273 | case positionSize: Int => | |
269 | 274 | $Tuple4(positionSize, getIntegerValue(this, toCompositeKey(k_positionMargin, _trader)), getIntegerValue(this, toCompositeKey(k_positionOpenNotional, _trader)), getIntegerValue(this, toCompositeKey(k_positionLastUpdatedCumulativePremiumFraction, _trader))) | |
270 | 275 | case _ => | |
271 | 276 | $Tuple4(0, 0, 0, 0) | |
272 | 277 | } | |
273 | 278 | } | |
274 | 279 | ||
275 | 280 | ||
276 | 281 | func requireOpenPosition (_trader) = if ((getPosition(_trader)._1 == 0)) | |
277 | 282 | then throw("No open position") | |
278 | 283 | else true | |
279 | 284 | ||
280 | 285 | ||
281 | 286 | func initialized () = valueOrElse(getBoolean(this, k_initialized), false) | |
282 | 287 | ||
283 | 288 | ||
284 | 289 | func paused () = valueOrElse(getBoolean(this, k_paused), false) | |
285 | 290 | ||
286 | 291 | ||
287 | 292 | func updateReserve (_isAdd,_quoteAssetAmount,_baseAssetAmount) = if (_isAdd) | |
288 | 293 | then { | |
289 | 294 | let newBase = (bsAstR() - _baseAssetAmount) | |
290 | 295 | if ((0 >= newBase)) | |
291 | 296 | then throw("Tx lead to base asset reserve <= 0, revert") | |
292 | 297 | else $Tuple4((qtAstR() + _quoteAssetAmount), newBase, (totalPositionSize() + _baseAssetAmount), (cumulativeNotional() + _quoteAssetAmount)) | |
293 | 298 | } | |
294 | 299 | else { | |
295 | 300 | let newQuote = (qtAstR() - _quoteAssetAmount) | |
296 | 301 | if ((0 >= newQuote)) | |
297 | 302 | then throw("Tx lead to base quote reserve <= 0, revert") | |
298 | 303 | else $Tuple4(newQuote, (bsAstR() + _baseAssetAmount), (totalPositionSize() - _baseAssetAmount), (cumulativeNotional() - _quoteAssetAmount)) | |
299 | 304 | } | |
300 | 305 | ||
301 | 306 | ||
302 | 307 | func swapInput (_isAdd,_quoteAssetAmount) = { | |
303 | 308 | let _qtAstR = qtAstR() | |
304 | 309 | let _bsAstR = bsAstR() | |
305 | 310 | let priceBefore = divd(_qtAstR, _bsAstR) | |
306 | 311 | let amountBaseAssetBoughtWithoutPriceImpact = muld(_quoteAssetAmount, priceBefore) | |
307 | 312 | let k = muld(_qtAstR, _bsAstR) | |
308 | 313 | let quoteAssetReserveAfter = if (_isAdd) | |
309 | 314 | then (_qtAstR + _quoteAssetAmount) | |
310 | 315 | else (_qtAstR - _quoteAssetAmount) | |
311 | 316 | let baseAssetReserveAfter = divd(k, quoteAssetReserveAfter) | |
312 | 317 | let amountBaseAssetBoughtAbs = abs((baseAssetReserveAfter - _bsAstR)) | |
313 | 318 | let amountBaseAssetBought = if (_isAdd) | |
314 | 319 | then amountBaseAssetBoughtAbs | |
315 | 320 | else -(amountBaseAssetBoughtAbs) | |
316 | 321 | let priceImpact = ((amountBaseAssetBoughtWithoutPriceImpact - amountBaseAssetBoughtAbs) / amountBaseAssetBoughtWithoutPriceImpact) | |
317 | 322 | let maxPriceImpactValue = maxPriceImpact() | |
318 | 323 | if ((priceImpact > maxPriceImpactValue)) | |
319 | 324 | then throw(((("Price impact " + toString(priceImpact)) + " > max price impact ") + toString(maxPriceImpactValue))) | |
320 | 325 | else { | |
321 | - | let $ | |
322 | - | let quoteAssetReserveAfter1 = $ | |
323 | - | let baseAssetReserveAfter1 = $ | |
324 | - | let totalPositionSizeAfter1 = $ | |
325 | - | let cumulativeNotionalAfter1 = $ | |
326 | + | let $t01215412357 = updateReserve(_isAdd, _quoteAssetAmount, amountBaseAssetBoughtAbs) | |
327 | + | let quoteAssetReserveAfter1 = $t01215412357._1 | |
328 | + | let baseAssetReserveAfter1 = $t01215412357._2 | |
329 | + | let totalPositionSizeAfter1 = $t01215412357._3 | |
330 | + | let cumulativeNotionalAfter1 = $t01215412357._4 | |
326 | 331 | $Tuple5(amountBaseAssetBought, quoteAssetReserveAfter1, baseAssetReserveAfter1, totalPositionSizeAfter1, cumulativeNotionalAfter1) | |
327 | 332 | } | |
328 | 333 | } | |
329 | 334 | ||
330 | 335 | ||
331 | 336 | func calcRemainMarginWithFundingPayment (_oldPositionSize,_oldPositionMargin,_oldPositionCumulativePremiumFraction,_marginDelta) = { | |
332 | 337 | let fundingPayment = if ((_oldPositionSize != 0)) | |
333 | 338 | then { | |
334 | 339 | let _latestCumulativePremiumFraction = latestCumulativePremiumFraction(_oldPositionSize) | |
335 | 340 | muld((_latestCumulativePremiumFraction - _oldPositionCumulativePremiumFraction), _oldPositionSize) | |
336 | 341 | } | |
337 | 342 | else 0 | |
338 | 343 | let signedMargin = ((_marginDelta - fundingPayment) + _oldPositionMargin) | |
339 | - | let $ | |
344 | + | let $t01310413231 = if ((0 > signedMargin)) | |
340 | 345 | then $Tuple2(0, abs(signedMargin)) | |
341 | 346 | else $Tuple2(abs(signedMargin), 0) | |
342 | - | let remainMargin = $ | |
343 | - | let badDebt = $ | |
347 | + | let remainMargin = $t01310413231._1 | |
348 | + | let badDebt = $t01310413231._2 | |
344 | 349 | $Tuple3(remainMargin, badDebt, fundingPayment) | |
345 | 350 | } | |
346 | 351 | ||
347 | 352 | ||
348 | 353 | func swapOutput (_isAdd,_baseAssetAmount) = { | |
349 | 354 | let _quoteAssetReserve = qtAstR() | |
350 | 355 | let _baseAssetReserve = bsAstR() | |
351 | 356 | if ((_baseAssetAmount == 0)) | |
352 | 357 | then throw("Invalid base asset amount") | |
353 | 358 | else { | |
354 | 359 | let k = muld(_quoteAssetReserve, _baseAssetReserve) | |
355 | 360 | let baseAssetPoolAmountAfter = if (_isAdd) | |
356 | 361 | then (_baseAssetReserve + _baseAssetAmount) | |
357 | 362 | else (_baseAssetReserve - _baseAssetAmount) | |
358 | 363 | let quoteAssetAfter = divd(k, baseAssetPoolAmountAfter) | |
359 | 364 | let quoteAssetSold = abs((quoteAssetAfter - _quoteAssetReserve)) | |
360 | - | let $ | |
361 | - | let quoteAssetReserveAfter1 = $ | |
362 | - | let baseAssetReserveAfter1 = $ | |
363 | - | let totalPositionSizeAfter1 = $ | |
364 | - | let cumulativeNotionalAfter1 = $ | |
365 | + | let $t01406914262 = updateReserve(!(_isAdd), quoteAssetSold, _baseAssetAmount) | |
366 | + | let quoteAssetReserveAfter1 = $t01406914262._1 | |
367 | + | let baseAssetReserveAfter1 = $t01406914262._2 | |
368 | + | let totalPositionSizeAfter1 = $t01406914262._3 | |
369 | + | let cumulativeNotionalAfter1 = $t01406914262._4 | |
365 | 370 | $Tuple7(quoteAssetSold, quoteAssetReserveAfter1, baseAssetReserveAfter1, totalPositionSizeAfter1, cumulativeNotionalAfter1, (totalLongPositionSize() - (if (_isAdd) | |
366 | 371 | then abs(_baseAssetAmount) | |
367 | 372 | else 0)), (totalShortPositionSize() - (if (!(_isAdd)) | |
368 | 373 | then abs(_baseAssetAmount) | |
369 | 374 | else 0))) | |
370 | 375 | } | |
371 | 376 | } | |
372 | 377 | ||
373 | 378 | ||
374 | 379 | func getOracleTwapPrice () = { | |
375 | 380 | let oracle = valueOrErrorMessage(addressFromString(getStringValue(this, k_ora)), "") | |
376 | 381 | let priceKey = getStringValue(this, k_ora_key) | |
377 | 382 | let blockKey = getStringValue(this, k_ora_block_key) | |
378 | 383 | let lastValue = getIntegerValue(oracle, priceKey) | |
379 | 384 | lastValue | |
380 | 385 | } | |
381 | 386 | ||
382 | 387 | ||
383 | 388 | func getSpotPrice () = { | |
384 | 389 | let _quoteAssetReserve = qtAstR() | |
385 | 390 | let _baseAssetReserve = bsAstR() | |
386 | 391 | divd(_quoteAssetReserve, _baseAssetReserve) | |
387 | 392 | } | |
388 | 393 | ||
389 | 394 | ||
390 | 395 | func isOverFluctuationLimit () = { | |
391 | 396 | let oraclePrice = getOracleTwapPrice() | |
392 | 397 | let currentPrice = getSpotPrice() | |
393 | 398 | (divd(abs((oraclePrice - currentPrice)), oraclePrice) > spreadLimit()) | |
394 | 399 | } | |
395 | 400 | ||
396 | 401 | ||
397 | 402 | func getPositionNotionalAndUnrealizedPnl (_trader,_option) = { | |
398 | - | let $ | |
399 | - | let positionSize = $ | |
400 | - | let positionMargin = $ | |
401 | - | let positionOpenNotional = $ | |
402 | - | let positionLstUpdCPF = $ | |
403 | + | let $t01589416022 = getPosition(_trader) | |
404 | + | let positionSize = $t01589416022._1 | |
405 | + | let positionMargin = $t01589416022._2 | |
406 | + | let positionOpenNotional = $t01589416022._3 | |
407 | + | let positionLstUpdCPF = $t01589416022._4 | |
403 | 408 | let positionSizeAbs = abs(positionSize) | |
404 | 409 | if ((positionSizeAbs == 0)) | |
405 | 410 | then throw("Invalid position size") | |
406 | 411 | else { | |
407 | 412 | let isShort = (0 > positionSize) | |
408 | 413 | let positionNotional = if ((_option == PNL_OPTION_SPOT)) | |
409 | 414 | then { | |
410 | - | let $ | |
411 | - | let outPositionNotional = $ | |
412 | - | let x1 = $ | |
413 | - | let x2 = $ | |
414 | - | let x3 = $ | |
415 | + | let $t01626916376 = swapOutput(!(isShort), positionSizeAbs) | |
416 | + | let outPositionNotional = $t01626916376._1 | |
417 | + | let x1 = $t01626916376._2 | |
418 | + | let x2 = $t01626916376._3 | |
419 | + | let x3 = $t01626916376._4 | |
415 | 420 | outPositionNotional | |
416 | 421 | } | |
417 | 422 | else (positionSizeAbs * getOracleTwapPrice()) | |
418 | 423 | let unrealizedPnl = if (isShort) | |
419 | 424 | then (positionOpenNotional - positionNotional) | |
420 | 425 | else (positionNotional - positionOpenNotional) | |
421 | 426 | $Tuple2(positionNotional, unrealizedPnl) | |
422 | 427 | } | |
423 | 428 | } | |
424 | 429 | ||
425 | 430 | ||
426 | 431 | func calcMarginRatio (_remainMargin,_badDebt,_positionNotional) = divd((_remainMargin - _badDebt), _positionNotional) | |
427 | 432 | ||
428 | 433 | ||
429 | 434 | func getMarginRatioByOption (_trader,_option) = { | |
430 | - | let $ | |
431 | - | let positionSize = $ | |
432 | - | let positionMargin = $ | |
433 | - | let pon = $ | |
434 | - | let positionLstUpdCPF = $ | |
435 | - | let $ | |
436 | - | let positionNotional = $ | |
437 | - | let unrealizedPnl = $ | |
438 | - | let $ | |
439 | - | let remainMargin = $ | |
440 | - | let badDebt = $ | |
435 | + | let $t01704117152 = getPosition(_trader) | |
436 | + | let positionSize = $t01704117152._1 | |
437 | + | let positionMargin = $t01704117152._2 | |
438 | + | let pon = $t01704117152._3 | |
439 | + | let positionLstUpdCPF = $t01704117152._4 | |
440 | + | let $t01715817251 = getPositionNotionalAndUnrealizedPnl(_trader, _option) | |
441 | + | let positionNotional = $t01715817251._1 | |
442 | + | let unrealizedPnl = $t01715817251._2 | |
443 | + | let $t01725617422 = calcRemainMarginWithFundingPayment(positionSize, positionMargin, positionLstUpdCPF, unrealizedPnl) | |
444 | + | let remainMargin = $t01725617422._1 | |
445 | + | let badDebt = $t01725617422._2 | |
441 | 446 | calcMarginRatio(remainMargin, badDebt, positionNotional) | |
442 | 447 | } | |
443 | 448 | ||
444 | 449 | ||
445 | 450 | func getMarginRatio (_trader) = getMarginRatioByOption(_trader, PNL_OPTION_SPOT) | |
446 | 451 | ||
447 | 452 | ||
448 | 453 | func internalClosePosition (_trader) = { | |
449 | - | let $ | |
450 | - | let positionSize = $ | |
451 | - | let positionMargin = $ | |
452 | - | let | |
453 | - | let positionLstUpdCPF = $ | |
454 | - | let $ | |
455 | - | let x1 = $ | |
456 | - | let unrealizedPnl = $ | |
457 | - | let $ | |
458 | - | let remainMargin = $ | |
459 | - | let badDebt = $ | |
454 | + | let $t01773817866 = getPosition(_trader) | |
455 | + | let positionSize = $t01773817866._1 | |
456 | + | let positionMargin = $t01773817866._2 | |
457 | + | let positionOpenNotional = $t01773817866._3 | |
458 | + | let positionLstUpdCPF = $t01773817866._4 | |
459 | + | let $t01787217959 = getPositionNotionalAndUnrealizedPnl(_trader, PNL_OPTION_SPOT) | |
460 | + | let x1 = $t01787217959._1 | |
461 | + | let unrealizedPnl = $t01787217959._2 | |
462 | + | let $t01796418132 = calcRemainMarginWithFundingPayment(positionSize, positionMargin, positionLstUpdCPF, unrealizedPnl) | |
463 | + | let remainMargin = $t01796418132._1 | |
464 | + | let badDebt = $t01796418132._2 | |
460 | 465 | let exchangedPositionSize = -(positionSize) | |
461 | 466 | let realizedPnl = unrealizedPnl | |
462 | 467 | let marginToVault = -(remainMargin) | |
463 | - | let $ | |
464 | - | let exchangedQuoteAssetAmount = $ | |
465 | - | let quoteAssetReserveAfter = $ | |
466 | - | let baseAssetReserveAfter = $ | |
467 | - | let totalPositionSizeAfter = $ | |
468 | - | let cumulativeNotionalAfter = $ | |
469 | - | let totalLongAfter = $ | |
470 | - | let totalShortAfter = $ | |
471 | - | let openInterestNotionalAfter = (openInterestNotional() - | |
468 | + | let $t01825918540 = swapOutput((positionSize > 0), abs(positionSize)) | |
469 | + | let exchangedQuoteAssetAmount = $t01825918540._1 | |
470 | + | let quoteAssetReserveAfter = $t01825918540._2 | |
471 | + | let baseAssetReserveAfter = $t01825918540._3 | |
472 | + | let totalPositionSizeAfter = $t01825918540._4 | |
473 | + | let cumulativeNotionalAfter = $t01825918540._5 | |
474 | + | let totalLongAfter = $t01825918540._6 | |
475 | + | let totalShortAfter = $t01825918540._7 | |
476 | + | let openInterestNotionalAfter = (openInterestNotional() - positionOpenNotional) | |
472 | 477 | $Tuple12(exchangedPositionSize, badDebt, realizedPnl, marginToVault, quoteAssetReserveAfter, baseAssetReserveAfter, totalPositionSizeAfter, cumulativeNotionalAfter, openInterestNotionalAfter, exchangedQuoteAssetAmount, totalLongAfter, totalShortAfter) | |
473 | 478 | } | |
474 | 479 | ||
475 | 480 | ||
476 | 481 | func getTwapSpotPrice () = { | |
477 | 482 | let minuteId = ((lastBlock.timestamp / 1000) / 60) | |
478 | 483 | let startMinuteId = (minuteId - TWAP_INTERVAL) | |
479 | 484 | let listStr = valueOrElse(getString(this, k_lastDataStr), "") | |
480 | 485 | let list = split(listStr, ",") | |
481 | 486 | func filterFn (accumulator,next) = if ((startMinuteId >= parseIntValue(next))) | |
482 | 487 | then (accumulator :+ parseIntValue(next)) | |
483 | 488 | else accumulator | |
484 | 489 | ||
485 | 490 | let listF = { | |
486 | 491 | let $l = list | |
487 | 492 | let $s = size($l) | |
488 | 493 | let $acc0 = nil | |
489 | 494 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
490 | 495 | then $a | |
491 | 496 | else filterFn($a, $l[$i]) | |
492 | 497 | ||
493 | 498 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
494 | 499 | then $a | |
495 | 500 | else throw("List size exceeds 20") | |
496 | 501 | ||
497 | 502 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20) | |
498 | 503 | } | |
499 | 504 | let maxIndex = if ((size(listF) > 0)) | |
500 | 505 | then max(listF) | |
501 | 506 | else parseIntValue(list[0]) | |
502 | 507 | let lastMinuteId = valueOrElse(getInteger(this, k_lastMinuteId), 0) | |
503 | 508 | let endLastCumulativePrice = valueOrElse(getInteger(this, ((k_twapDataLastCumulativePrice + "_") + toString(lastMinuteId))), 0) | |
504 | 509 | let endLastPrice = valueOrElse(getInteger(this, ((k_twapDataLastPrice + "_") + toString(lastMinuteId))), 0) | |
505 | 510 | let nowCumulativePrice = (endLastCumulativePrice + ((minuteId - lastMinuteId) * endLastPrice)) | |
506 | 511 | let startLastCumulativePrice = valueOrElse(getInteger(this, ((k_twapDataLastCumulativePrice + "_") + toString(maxIndex))), 0) | |
507 | 512 | let startLastPrice = valueOrElse(getInteger(this, ((k_twapDataLastPrice + "_") + toString(maxIndex))), 0) | |
508 | 513 | let startCumulativePrice = (startLastCumulativePrice + ((startMinuteId - maxIndex) * startLastPrice)) | |
509 | 514 | ((nowCumulativePrice - startCumulativePrice) / TWAP_INTERVAL) | |
510 | 515 | } | |
511 | 516 | ||
512 | 517 | ||
513 | 518 | func updateSettings (_initMarginRatio,_mmr,_liquidationFeeRatio,_fundingPeriod,_fee,_spreadLimit,_maxPriceImpact) = [IntegerEntry(k_initMarginRatio, _initMarginRatio), IntegerEntry(k_maintenanceMarginRatio, _mmr), IntegerEntry(k_liquidationFeeRatio, _liquidationFeeRatio), IntegerEntry(k_fundingPeriod, _fundingPeriod), IntegerEntry(k_fee, _fee), IntegerEntry(k_spreadLimit, _spreadLimit), IntegerEntry(k_maxPriceImpact, _maxPriceImpact)] | |
514 | 519 | ||
515 | 520 | ||
516 | 521 | func updateFunding (_nextFundingBlock,_latestLongCumulativePremiumFraction,_latestShortCumulativePremiumFraction,_longFundingRate,_shortFundingRate) = [IntegerEntry(k_nextFundingBlock, _nextFundingBlock), IntegerEntry(k_latestLongCumulativePremiumFraction, _latestLongCumulativePremiumFraction), IntegerEntry(k_latestShortCumulativePremiumFraction, _latestShortCumulativePremiumFraction), IntegerEntry(k_longFundingRate, _longFundingRate), IntegerEntry(k_shortFundingRate, _shortFundingRate)] | |
517 | 522 | ||
518 | 523 | ||
519 | 524 | func updatePosition (_address,_size,_margin,_openNotional,_latestCumulativePremiumFraction) = [IntegerEntry(toCompositeKey(k_positionSize, _address), _size), IntegerEntry(toCompositeKey(k_positionMargin, _address), _margin), IntegerEntry(toCompositeKey(k_positionOpenNotional, _address), _openNotional), IntegerEntry(toCompositeKey(k_positionLastUpdatedCumulativePremiumFraction, _address), _latestCumulativePremiumFraction)] | |
520 | 525 | ||
521 | 526 | ||
522 | 527 | func appendTwap (price) = { | |
523 | 528 | let minuteId = ((lastBlock.timestamp / 1000) / 60) | |
524 | 529 | let previousMinuteId = valueOrElse(getInteger(this, k_lastMinuteId), 0) | |
525 | 530 | if ((previousMinuteId > minuteId)) | |
526 | 531 | then throw("TWAP out-of-order") | |
527 | 532 | else { | |
528 | 533 | let lastMinuteId = if ((previousMinuteId == 0)) | |
529 | 534 | then minuteId | |
530 | 535 | else previousMinuteId | |
531 | 536 | if ((minuteId > previousMinuteId)) | |
532 | 537 | then { | |
533 | 538 | let prevCumulativePrice = valueOrElse(getInteger(this, ((k_twapDataLastCumulativePrice + "_") + toString(previousMinuteId))), 0) | |
534 | 539 | let prevPrice = valueOrElse(getInteger(this, ((k_twapDataLastPrice + "_") + toString(previousMinuteId))), price) | |
535 | 540 | let lastCumulativePrice = (prevCumulativePrice + ((minuteId - lastMinuteId) * prevPrice)) | |
536 | 541 | let list = pushToQueue(strToList(valueOrElse(getString(this, k_lastDataStr), "")), TWAP_INTERVAL, toString(minuteId)) | |
537 | 542 | [IntegerEntry(toCompositeKey(k_twapDataLastCumulativePrice, toString(minuteId)), lastCumulativePrice), IntegerEntry(toCompositeKey(k_twapDataLastPrice, toString(minuteId)), price), IntegerEntry(toCompositeKey(k_twapDataPreviousMinuteId, toString(minuteId)), previousMinuteId), IntegerEntry(k_lastMinuteId, minuteId), StringEntry(k_lastDataStr, listToStr(list))] | |
538 | 543 | } | |
539 | 544 | else { | |
540 | 545 | let twapDataPreviousMinuteId = valueOrElse(getInteger(this, toCompositeKey(k_twapDataPreviousMinuteId, toString(minuteId))), 0) | |
541 | 546 | let prevCumulativePrice = valueOrElse(getInteger(this, toCompositeKey(k_twapDataLastCumulativePrice, toString(twapDataPreviousMinuteId))), 0) | |
542 | 547 | let prevPrice = valueOrElse(getInteger(this, toCompositeKey(k_twapDataLastPrice, toString(twapDataPreviousMinuteId))), price) | |
543 | 548 | let lastCumulativePrice = (prevCumulativePrice + ((minuteId - twapDataPreviousMinuteId) * prevPrice)) | |
544 | 549 | [IntegerEntry(toCompositeKey(k_twapDataLastCumulativePrice, toString(minuteId)), lastCumulativePrice), IntegerEntry(toCompositeKey(k_twapDataLastPrice, toString(minuteId)), price)] | |
545 | 550 | } | |
546 | 551 | } | |
547 | 552 | } | |
548 | 553 | ||
549 | 554 | ||
550 | 555 | func updateAmm (_qtAstR,_bsAstR,_totalPositionSizeAfter,_cumulativeNotionalAfter,_openInterestNotional,_totalLongPositionSize,_totalShortPositionSize) = if (((_totalLongPositionSize - _totalShortPositionSize) != _totalPositionSizeAfter)) | |
551 | 556 | then throw(((((("Invalid AMM state data: " + toString(_totalLongPositionSize)) + " + ") + toString(_totalShortPositionSize)) + " != ") + toString(_totalPositionSizeAfter))) | |
552 | 557 | else ([IntegerEntry(k_quoteAssetReserve, _qtAstR), IntegerEntry(k_baseAssetReserve, _bsAstR), IntegerEntry(k_totalPositionSize, _totalPositionSizeAfter), IntegerEntry(k_cumulativeNotional, _cumulativeNotionalAfter), IntegerEntry(k_openInterestNotional, _openInterestNotional), IntegerEntry(k_totalLongPositionSize, _totalLongPositionSize), IntegerEntry(k_totalShortPositionSize, _totalShortPositionSize)] ++ appendTwap(divd(_qtAstR, _bsAstR))) | |
553 | 558 | ||
554 | 559 | ||
555 | 560 | func deletePosition (_address) = [DeleteEntry(toCompositeKey(k_positionSize, _address)), DeleteEntry(toCompositeKey(k_positionMargin, _address)), DeleteEntry(toCompositeKey(k_positionOpenNotional, _address)), DeleteEntry(toCompositeKey(k_positionLastUpdatedCumulativePremiumFraction, _address))] | |
556 | 561 | ||
557 | 562 | ||
558 | 563 | func withdraw (_address,_amount) = { | |
559 | 564 | let balance = assetBalance(this, quoteAsset()) | |
560 | 565 | if ((_amount > balance)) | |
561 | 566 | then throw(((("Unable to withdraw " + toString(_amount)) + " from contract balance ") + toString(balance))) | |
562 | 567 | else [ScriptTransfer(_address, _amount, quoteAsset())] | |
563 | 568 | } | |
564 | 569 | ||
565 | 570 | ||
566 | 571 | func updateBalance (i) = if ((0 > i)) | |
567 | 572 | then throw("Balance") | |
568 | 573 | else [IntegerEntry(k_balance, i)] | |
569 | 574 | ||
570 | 575 | ||
571 | 576 | func transferFee (i) = [ScriptTransfer(stakingAddress(), i, quoteAsset())] | |
572 | 577 | ||
573 | 578 | ||
574 | 579 | @Callable(i) | |
575 | 580 | func pause () = if ((i.caller != adminAddress())) | |
576 | 581 | then throw("Invalid togglePause params") | |
577 | 582 | else [BooleanEntry(k_paused, true)] | |
578 | 583 | ||
579 | 584 | ||
580 | 585 | ||
581 | 586 | @Callable(i) | |
582 | 587 | func unpause () = if ((i.caller != adminAddress())) | |
583 | 588 | then throw("Invalid togglePause params") | |
584 | 589 | else [BooleanEntry(k_paused, false)] | |
585 | 590 | ||
586 | 591 | ||
587 | 592 | ||
588 | 593 | @Callable(i) | |
589 | 594 | func changeSettings (_initMarginRatio,_mmr,_liquidationFeeRatio,_fundingPeriod,_fee,_spreadLimit,_maxPriceImpact) = if ((i.caller != adminAddress())) | |
590 | 595 | then throw("Invalid changeSettings params") | |
591 | 596 | else updateSettings(_initMarginRatio, _mmr, _liquidationFeeRatio, _fundingPeriod, _fee, _spreadLimit, _maxPriceImpact) | |
592 | 597 | ||
593 | 598 | ||
594 | 599 | ||
595 | 600 | @Callable(i) | |
596 | 601 | func initialize (_qtAstR,_bsAstR,_fundingPeriod,_initMarginRatio,_mmr,_liquidationFeeRatio,_fee,_oracle,_oracleKey,_coordinator,_spreadLimit,_maxPriceImpact) = if (if (if (if (if (if (if (if (if (if ((0 >= _qtAstR)) | |
597 | 602 | then true | |
598 | 603 | else (0 >= _bsAstR)) | |
599 | 604 | then true | |
600 | 605 | else (0 >= _fundingPeriod)) | |
601 | 606 | then true | |
602 | 607 | else (0 >= _initMarginRatio)) | |
603 | 608 | then true | |
604 | 609 | else (0 >= _mmr)) | |
605 | 610 | then true | |
606 | 611 | else (0 >= _liquidationFeeRatio)) | |
607 | 612 | then true | |
608 | 613 | else (0 >= _fee)) | |
609 | 614 | then true | |
610 | 615 | else (0 >= _spreadLimit)) | |
611 | 616 | then true | |
612 | 617 | else (0 >= _maxPriceImpact)) | |
613 | 618 | then true | |
614 | 619 | else initialized()) | |
615 | 620 | then throw("Invalid initialize parameters") | |
616 | 621 | else ((((updateAmm(_qtAstR, _bsAstR, 0, 0, 0, 0, 0) ++ updateSettings(_initMarginRatio, _mmr, _liquidationFeeRatio, _fundingPeriod, _fee, _spreadLimit, _maxPriceImpact)) ++ updateFunding((lastBlock.timestamp + _fundingPeriod), 0, 0, 0, 0)) ++ updateBalance(0)) ++ [BooleanEntry(k_initialized, true), StringEntry(k_ora, _oracle), StringEntry(k_ora_key, _oracleKey), StringEntry(k_coordinatorAddress, _coordinator)]) | |
617 | 622 | ||
618 | 623 | ||
619 | 624 | ||
620 | 625 | @Callable(i) | |
621 | 626 | func decreasePosition (_amount,_leverage,_minBaseAssetAmount) = if (if (if (if (if (if ((0 >= _amount)) | |
622 | 627 | then true | |
623 | 628 | else if (((1 * DECIMAL_UNIT) > _leverage)) | |
624 | 629 | then true | |
625 | 630 | else (_leverage > (3 * DECIMAL_UNIT))) | |
626 | 631 | then true | |
627 | 632 | else !(initialized())) | |
628 | 633 | then true | |
629 | 634 | else !(requireMoreMarginRatio(divd(DECIMAL_UNIT, _leverage), initMarginRatio(), true))) | |
630 | 635 | then true | |
631 | 636 | else !(requireOpenPosition(toString(i.caller)))) | |
632 | 637 | then true | |
633 | 638 | else paused()) | |
634 | 639 | then throw("Invalid decreasePosition parameters") | |
635 | 640 | else { | |
636 | - | let $ | |
637 | - | let oldPositionSize = $ | |
638 | - | let oldPositionMargin = $ | |
639 | - | let oldPositionOpenNotional = $ | |
640 | - | let oldPositionLstUpdCPF = $ | |
641 | + | let $t02838128533 = getPosition(toString(i.caller)) | |
642 | + | let oldPositionSize = $t02838128533._1 | |
643 | + | let oldPositionMargin = $t02838128533._2 | |
644 | + | let oldPositionOpenNotional = $t02838128533._3 | |
645 | + | let oldPositionLstUpdCPF = $t02838128533._4 | |
641 | 646 | let _direction = if ((oldPositionSize > 0)) | |
642 | 647 | then DIR_SHORT | |
643 | 648 | else DIR_LONG | |
644 | 649 | let isAdd = (_direction == DIR_LONG) | |
645 | 650 | let openNotional = muld(_amount, _leverage) | |
646 | - | let $ | |
647 | - | let oldPositionNotional = $ | |
648 | - | let unrealizedPnl = $ | |
649 | - | let $ | |
651 | + | let $t02870628822 = getPositionNotionalAndUnrealizedPnl(toString(i.caller), PNL_OPTION_SPOT) | |
652 | + | let oldPositionNotional = $t02870628822._1 | |
653 | + | let unrealizedPnl = $t02870628822._2 | |
654 | + | let $t02882831377 = if ((oldPositionNotional > openNotional)) | |
650 | 655 | then { | |
651 | - | let $ | |
652 | - | let exchangedPositionSize = $ | |
653 | - | let quoteAssetReserveAfter = $ | |
654 | - | let baseAssetReserveAfter = $ | |
655 | - | let totalPositionSizeAfter = $ | |
656 | - | let cumulativeNotionalAfter = $ | |
656 | + | let $t02920529424 = swapInput(isAdd, openNotional) | |
657 | + | let exchangedPositionSize = $t02920529424._1 | |
658 | + | let quoteAssetReserveAfter = $t02920529424._2 | |
659 | + | let baseAssetReserveAfter = $t02920529424._3 | |
660 | + | let totalPositionSizeAfter = $t02920529424._4 | |
661 | + | let cumulativeNotionalAfter = $t02920529424._5 | |
657 | 662 | let exchangedPositionSizeAbs = abs(exchangedPositionSize) | |
658 | 663 | if (if ((_minBaseAssetAmount != 0)) | |
659 | 664 | then (_minBaseAssetAmount > exchangedPositionSizeAbs) | |
660 | 665 | else false) | |
661 | 666 | then throw(((("Too little base asset exchanged, got " + toString(exchangedPositionSizeAbs)) + " expected ") + toString(_minBaseAssetAmount))) | |
662 | 667 | else { | |
663 | 668 | let realizedPnl = divd(muld(unrealizedPnl, exchangedPositionSizeAbs), abs(oldPositionSize)) | |
664 | - | let $ | |
665 | - | let remainMargin = $ | |
666 | - | let badDebt = $ | |
667 | - | let fundingPayment = $ | |
669 | + | let $t02986130106 = calcRemainMarginWithFundingPayment(oldPositionSize, oldPositionMargin, oldPositionLstUpdCPF, realizedPnl) | |
670 | + | let remainMargin = $t02986130106._1 | |
671 | + | let badDebt = $t02986130106._2 | |
672 | + | let fundingPayment = $t02986130106._3 | |
668 | 673 | let exchangedQuoteAssetAmount = openNotional | |
669 | 674 | let unrealizedPnlAfter = (unrealizedPnl - realizedPnl) | |
670 | 675 | let remainOpenNotional = if ((oldPositionSize > 0)) | |
671 | 676 | then ((oldPositionNotional - exchangedQuoteAssetAmount) - unrealizedPnlAfter) | |
672 | 677 | else ((unrealizedPnlAfter + oldPositionNotional) - exchangedQuoteAssetAmount) | |
673 | 678 | let newPositionSize = (oldPositionSize + exchangedPositionSize) | |
674 | 679 | $Tuple11(newPositionSize, remainMargin, abs(remainOpenNotional), latestCumulativePremiumFraction(newPositionSize), baseAssetReserveAfter, quoteAssetReserveAfter, totalPositionSizeAfter, cumulativeNotionalAfter, (openInterestNotional() - openNotional), (totalLongPositionSize() - (if ((newPositionSize > 0)) | |
675 | 680 | then abs(exchangedPositionSize) | |
676 | 681 | else 0)), (totalShortPositionSize() - (if ((0 > newPositionSize)) | |
677 | 682 | then abs(exchangedPositionSize) | |
678 | 683 | else 0))) | |
679 | 684 | } | |
680 | 685 | } | |
681 | 686 | else throw("Close position first") | |
682 | - | let newPositionSize = $ | |
683 | - | let newPositionRemainMargin = $ | |
684 | - | let newPositionOpenNotional = $ | |
685 | - | let newPositionLatestCPF = $ | |
686 | - | let baseAssetReserveAfter = $ | |
687 | - | let quoteAssetReserveAfter = $ | |
688 | - | let totalPositionSizeAfter = $ | |
689 | - | let cumulativeNotionalAfter = $ | |
690 | - | let openInterestNotionalAfter = $ | |
691 | - | let totalLongAfter = $ | |
692 | - | let totalShortAfter = $ | |
687 | + | let newPositionSize = $t02882831377._1 | |
688 | + | let newPositionRemainMargin = $t02882831377._2 | |
689 | + | let newPositionOpenNotional = $t02882831377._3 | |
690 | + | let newPositionLatestCPF = $t02882831377._4 | |
691 | + | let baseAssetReserveAfter = $t02882831377._5 | |
692 | + | let quoteAssetReserveAfter = $t02882831377._6 | |
693 | + | let totalPositionSizeAfter = $t02882831377._7 | |
694 | + | let cumulativeNotionalAfter = $t02882831377._8 | |
695 | + | let openInterestNotionalAfter = $t02882831377._9 | |
696 | + | let totalLongAfter = $t02882831377._10 | |
697 | + | let totalShortAfter = $t02882831377._11 | |
693 | 698 | (updatePosition(toString(i.caller), newPositionSize, newPositionRemainMargin, newPositionOpenNotional, newPositionLatestCPF) ++ updateAmm(quoteAssetReserveAfter, baseAssetReserveAfter, totalPositionSizeAfter, cumulativeNotionalAfter, openInterestNotionalAfter, totalLongAfter, totalShortAfter)) | |
694 | 699 | } | |
695 | 700 | ||
696 | 701 | ||
697 | 702 | ||
698 | 703 | @Callable(i) | |
699 | 704 | func increasePosition (_direction,_leverage,_minBaseAssetAmount) = { | |
700 | 705 | let _rawAmount = i.payments[0].amount | |
701 | 706 | if (if (if (if (if (if (if (if ((_direction != DIR_LONG)) | |
702 | 707 | then (_direction != DIR_SHORT) | |
703 | 708 | else false) | |
704 | 709 | then true | |
705 | 710 | else (0 >= _rawAmount)) | |
706 | 711 | then true | |
707 | 712 | else if (((1 * DECIMAL_UNIT) > _leverage)) | |
708 | 713 | then true | |
709 | 714 | else (_leverage > (3 * DECIMAL_UNIT))) | |
710 | 715 | then true | |
711 | 716 | else !(initialized())) | |
712 | 717 | then true | |
713 | 718 | else (i.payments[0].assetId != quoteAsset())) | |
714 | 719 | then true | |
715 | 720 | else !(requireMoreMarginRatio(divd(DECIMAL_UNIT, _leverage), initMarginRatio(), true))) | |
716 | 721 | then true | |
717 | 722 | else paused()) | |
718 | 723 | then throw("Invalid increasePosition parameters") | |
719 | 724 | else { | |
720 | 725 | let feeAmount = muld(_rawAmount, fee()) | |
721 | 726 | let _amount = (_rawAmount - feeAmount) | |
722 | - | let $ | |
723 | - | let oldPositionSize = $ | |
724 | - | let oldPositionMargin = $ | |
725 | - | let oldPositionOpenNotional = $ | |
726 | - | let oldPositionLstUpdCPF = $ | |
727 | + | let $t03241332565 = getPosition(toString(i.caller)) | |
728 | + | let oldPositionSize = $t03241332565._1 | |
729 | + | let oldPositionMargin = $t03241332565._2 | |
730 | + | let oldPositionOpenNotional = $t03241332565._3 | |
731 | + | let oldPositionLstUpdCPF = $t03241332565._4 | |
727 | 732 | let isNewPosition = (oldPositionSize == 0) | |
728 | 733 | let isSameDirection = if ((oldPositionSize > 0)) | |
729 | 734 | then (_direction == DIR_LONG) | |
730 | 735 | else (_direction == DIR_SHORT) | |
731 | 736 | let expandExisting = if (!(isNewPosition)) | |
732 | 737 | then isSameDirection | |
733 | 738 | else false | |
734 | 739 | let isAdd = (_direction == DIR_LONG) | |
735 | - | let $ | |
740 | + | let $t03285435243 = if (if (isNewPosition) | |
736 | 741 | then true | |
737 | 742 | else expandExisting) | |
738 | 743 | then { | |
739 | 744 | let openNotional = muld(_amount, _leverage) | |
740 | - | let $ | |
741 | - | let amountBaseAssetBought = $ | |
742 | - | let quoteAssetReserveAfter = $ | |
743 | - | let baseAssetReserveAfter = $ | |
744 | - | let totalPositionSizeAfter = $ | |
745 | - | let cumulativeNotionalAfter = $ | |
745 | + | let $t03327833484 = swapInput(isAdd, openNotional) | |
746 | + | let amountBaseAssetBought = $t03327833484._1 | |
747 | + | let quoteAssetReserveAfter = $t03327833484._2 | |
748 | + | let baseAssetReserveAfter = $t03327833484._3 | |
749 | + | let totalPositionSizeAfter = $t03327833484._4 | |
750 | + | let cumulativeNotionalAfter = $t03327833484._5 | |
746 | 751 | if (if ((_minBaseAssetAmount != 0)) | |
747 | 752 | then (_minBaseAssetAmount > abs(amountBaseAssetBought)) | |
748 | 753 | else false) | |
749 | 754 | then throw(((("Limit error: " + toString(abs(amountBaseAssetBought))) + " < ") + toString(_minBaseAssetAmount))) | |
750 | 755 | else { | |
751 | 756 | let newPositionSize = (oldPositionSize + amountBaseAssetBought) | |
752 | 757 | let increaseMarginRequirement = divd(openNotional, _leverage) | |
753 | - | let $ | |
754 | - | let remainMargin = $ | |
755 | - | let x1 = $ | |
756 | - | let x2 = $ | |
758 | + | let $t03386534104 = calcRemainMarginWithFundingPayment(oldPositionSize, oldPositionMargin, oldPositionLstUpdCPF, increaseMarginRequirement) | |
759 | + | let remainMargin = $t03386534104._1 | |
760 | + | let x1 = $t03386534104._2 | |
761 | + | let x2 = $t03386534104._3 | |
757 | 762 | $Tuple11(newPositionSize, remainMargin, (oldPositionOpenNotional + openNotional), latestCumulativePremiumFraction(newPositionSize), baseAssetReserveAfter, quoteAssetReserveAfter, totalPositionSizeAfter, cumulativeNotionalAfter, (openInterestNotional() + openNotional), (totalLongPositionSize() + (if ((newPositionSize > 0)) | |
758 | 763 | then abs(amountBaseAssetBought) | |
759 | 764 | else 0)), (totalShortPositionSize() + (if ((0 > newPositionSize)) | |
760 | 765 | then abs(amountBaseAssetBought) | |
761 | 766 | else 0))) | |
762 | 767 | } | |
763 | 768 | } | |
764 | 769 | else { | |
765 | 770 | let openNotional = muld(_amount, _leverage) | |
766 | - | let $ | |
767 | - | let oldPositionNotional = $ | |
768 | - | let unrealizedPnl = $ | |
771 | + | let $t03493635052 = getPositionNotionalAndUnrealizedPnl(toString(i.caller), PNL_OPTION_SPOT) | |
772 | + | let oldPositionNotional = $t03493635052._1 | |
773 | + | let unrealizedPnl = $t03493635052._2 | |
769 | 774 | if ((oldPositionNotional > openNotional)) | |
770 | 775 | then throw("Use decreasePosition to decrease position size") | |
771 | 776 | else throw("Close position first") | |
772 | 777 | } | |
773 | - | let newPositionSize = $ | |
774 | - | let newPositionRemainMargin = $ | |
775 | - | let newPositionOpenNotional = $ | |
776 | - | let newPositionLatestCPF = $ | |
777 | - | let baseAssetReserveAfter = $ | |
778 | - | let quoteAssetReserveAfter = $ | |
779 | - | let totalPositionSizeAfter = $ | |
780 | - | let cumulativeNotionalAfter = $ | |
781 | - | let openInterestNotionalAfter = $ | |
782 | - | let totalLongAfter = $ | |
783 | - | let totalShortAfter = $ | |
778 | + | let newPositionSize = $t03285435243._1 | |
779 | + | let newPositionRemainMargin = $t03285435243._2 | |
780 | + | let newPositionOpenNotional = $t03285435243._3 | |
781 | + | let newPositionLatestCPF = $t03285435243._4 | |
782 | + | let baseAssetReserveAfter = $t03285435243._5 | |
783 | + | let quoteAssetReserveAfter = $t03285435243._6 | |
784 | + | let totalPositionSizeAfter = $t03285435243._7 | |
785 | + | let cumulativeNotionalAfter = $t03285435243._8 | |
786 | + | let openInterestNotionalAfter = $t03285435243._9 | |
787 | + | let totalLongAfter = $t03285435243._10 | |
788 | + | let totalShortAfter = $t03285435243._11 | |
784 | 789 | let feeToStakers = (feeAmount / 2) | |
785 | 790 | let feeToInsurance = (feeAmount - feeToStakers) | |
786 | 791 | let stake = invoke(quoteAssetStaking(), "lockNeutrinoSP", [toString(stakingAddress()), ALL_FEES], [AttachedPayment(quoteAsset(), _amount)]) | |
787 | 792 | if ((stake == stake)) | |
788 | 793 | then { | |
789 | 794 | let depositInsurance = invoke(insuranceAddress(), "deposit", nil, [AttachedPayment(quoteAsset(), feeToInsurance)]) | |
790 | 795 | if ((depositInsurance == depositInsurance)) | |
791 | 796 | then (((updatePosition(toString(i.caller), newPositionSize, newPositionRemainMargin, newPositionOpenNotional, newPositionLatestCPF) ++ updateAmm(quoteAssetReserveAfter, baseAssetReserveAfter, totalPositionSizeAfter, cumulativeNotionalAfter, openInterestNotionalAfter, totalLongAfter, totalShortAfter)) ++ transferFee(feeToStakers)) ++ updateBalance((cbalance() + _amount))) | |
792 | 797 | else throw("Strict value is not equal to itself.") | |
793 | 798 | } | |
794 | 799 | else throw("Strict value is not equal to itself.") | |
795 | 800 | } | |
796 | 801 | } | |
797 | 802 | ||
798 | 803 | ||
799 | 804 | ||
800 | 805 | @Callable(i) | |
801 | 806 | func addMargin () = { | |
802 | 807 | let _rawAmount = i.payments[0].amount | |
803 | 808 | if (if (if (if ((i.payments[0].assetId != quoteAsset())) | |
804 | 809 | then true | |
805 | 810 | else !(requireOpenPosition(toString(i.caller)))) | |
806 | 811 | then true | |
807 | 812 | else !(initialized())) | |
808 | 813 | then true | |
809 | 814 | else paused()) | |
810 | 815 | then throw("Invalid addMargin parameters") | |
811 | 816 | else { | |
812 | 817 | let feeAmount = muld(_rawAmount, fee()) | |
813 | 818 | let _amount = (_rawAmount - feeAmount) | |
814 | - | let $ | |
815 | - | let oldPositionSize = $ | |
816 | - | let oldPositionMargin = $ | |
817 | - | let oldPositionOpenNotional = $ | |
818 | - | let oldPositionLstUpdCPF = $ | |
819 | + | let $t03651936671 = getPosition(toString(i.caller)) | |
820 | + | let oldPositionSize = $t03651936671._1 | |
821 | + | let oldPositionMargin = $t03651936671._2 | |
822 | + | let oldPositionOpenNotional = $t03651936671._3 | |
823 | + | let oldPositionLstUpdCPF = $t03651936671._4 | |
819 | 824 | let feeToStakers = (feeAmount / 2) | |
820 | 825 | let feeToInsurance = (feeAmount - feeToStakers) | |
821 | 826 | let stake = invoke(quoteAssetStaking(), "lockNeutrinoSP", [toString(stakingAddress()), ALL_FEES], [AttachedPayment(quoteAsset(), _amount)]) | |
822 | 827 | if ((stake == stake)) | |
823 | 828 | then { | |
824 | 829 | let depositInsurance = invoke(insuranceAddress(), "deposit", nil, [AttachedPayment(quoteAsset(), feeToInsurance)]) | |
825 | 830 | if ((depositInsurance == depositInsurance)) | |
826 | 831 | then ((updatePosition(toString(i.caller), oldPositionSize, (oldPositionMargin + _amount), oldPositionOpenNotional, oldPositionLstUpdCPF) ++ transferFee(feeToStakers)) ++ updateBalance((cbalance() + _amount))) | |
827 | 832 | else throw("Strict value is not equal to itself.") | |
828 | 833 | } | |
829 | 834 | else throw("Strict value is not equal to itself.") | |
830 | 835 | } | |
831 | 836 | } | |
832 | 837 | ||
833 | 838 | ||
834 | 839 | ||
835 | 840 | @Callable(i) | |
836 | 841 | func removeMargin (_amount) = if (if (if (if ((0 >= _amount)) | |
837 | 842 | then true | |
838 | 843 | else !(requireOpenPosition(toString(i.caller)))) | |
839 | 844 | then true | |
840 | 845 | else !(initialized())) | |
841 | 846 | then true | |
842 | 847 | else paused()) | |
843 | 848 | then throw("Invalid removeMargin parameters") | |
844 | 849 | else { | |
845 | - | let $ | |
846 | - | let oldPositionSize = $ | |
847 | - | let oldPositionMargin = $ | |
848 | - | let oldPositionOpenNotional = $ | |
849 | - | let oldPositionLstUpdCPF = $ | |
850 | + | let $t03759137743 = getPosition(toString(i.caller)) | |
851 | + | let oldPositionSize = $t03759137743._1 | |
852 | + | let oldPositionMargin = $t03759137743._2 | |
853 | + | let oldPositionOpenNotional = $t03759137743._3 | |
854 | + | let oldPositionLstUpdCPF = $t03759137743._4 | |
850 | 855 | let marginDelta = -(_amount) | |
851 | - | let $ | |
852 | - | let remainMargin = $ | |
853 | - | let badDebt = $ | |
856 | + | let $t03778037959 = calcRemainMarginWithFundingPayment(oldPositionSize, oldPositionMargin, oldPositionLstUpdCPF, marginDelta) | |
857 | + | let remainMargin = $t03778037959._1 | |
858 | + | let badDebt = $t03778037959._2 | |
854 | 859 | if ((badDebt != 0)) | |
855 | 860 | then throw("Invalid removed margin amount") | |
856 | 861 | else { | |
857 | 862 | let marginRatio = calcMarginRatio(remainMargin, badDebt, oldPositionOpenNotional) | |
858 | 863 | if (!(requireMoreMarginRatio(marginRatio, initMarginRatio(), true))) | |
859 | 864 | then throw(((("Too much margin removed: " + toString(marginRatio)) + " < ") + toString(initMarginRatio()))) | |
860 | 865 | else { | |
861 | 866 | let unstake = invoke(quoteAssetStaking(), "unlockNeutrino", [_amount, toBase58String(quoteAsset())], nil) | |
862 | 867 | if ((unstake == unstake)) | |
863 | 868 | then ((updatePosition(toString(i.caller), oldPositionSize, remainMargin, oldPositionOpenNotional, latestCumulativePremiumFraction(oldPositionSize)) ++ withdraw(i.caller, _amount)) ++ updateBalance((cbalance() - _amount))) | |
864 | 869 | else throw("Strict value is not equal to itself.") | |
865 | 870 | } | |
866 | 871 | } | |
867 | 872 | } | |
868 | 873 | ||
869 | 874 | ||
870 | 875 | ||
871 | 876 | @Callable(i) | |
872 | 877 | func closePosition () = if (if (if (!(requireOpenPosition(toString(i.caller)))) | |
873 | 878 | then true | |
874 | 879 | else !(initialized())) | |
875 | 880 | then true | |
876 | 881 | else paused()) | |
877 | 882 | then throw("Invalid closePosition parameters") | |
878 | 883 | else { | |
879 | - | let $ | |
880 | - | let x1 = $ | |
881 | - | let positionBadDebt = $ | |
882 | - | let realizedPnl = $ | |
883 | - | let marginToVault = $ | |
884 | - | let quoteAssetReserveAfter = $ | |
885 | - | let baseAssetReserveAfter = $ | |
886 | - | let totalPositionSizeAfter = $ | |
887 | - | let cumulativeNotionalAfter = $ | |
888 | - | let openInterestNotionalAfter = $ | |
889 | - | let x2 = $ | |
890 | - | let totalLongAfter = $ | |
891 | - | let totalShortAfter = $ | |
884 | + | let $t03905539439 = internalClosePosition(toString(i.caller)) | |
885 | + | let x1 = $t03905539439._1 | |
886 | + | let positionBadDebt = $t03905539439._2 | |
887 | + | let realizedPnl = $t03905539439._3 | |
888 | + | let marginToVault = $t03905539439._4 | |
889 | + | let quoteAssetReserveAfter = $t03905539439._5 | |
890 | + | let baseAssetReserveAfter = $t03905539439._6 | |
891 | + | let totalPositionSizeAfter = $t03905539439._7 | |
892 | + | let cumulativeNotionalAfter = $t03905539439._8 | |
893 | + | let openInterestNotionalAfter = $t03905539439._9 | |
894 | + | let x2 = $t03905539439._10 | |
895 | + | let totalLongAfter = $t03905539439._11 | |
896 | + | let totalShortAfter = $t03905539439._12 | |
892 | 897 | if ((positionBadDebt > 0)) | |
893 | 898 | then throw("Unable to close position with bad debt") | |
894 | 899 | else { | |
895 | 900 | let withdrawAmount = abs(marginToVault) | |
896 | 901 | let ammBalance = (cbalance() - withdrawAmount) | |
897 | - | let $ | |
902 | + | let $t03964839790 = if ((0 > ammBalance)) | |
898 | 903 | then $Tuple2(0, abs(ammBalance)) | |
899 | 904 | else $Tuple2(ammBalance, 0) | |
900 | - | let ammNewBalance = $ | |
901 | - | let getFromInsurance = $ | |
905 | + | let ammNewBalance = $t03964839790._1 | |
906 | + | let getFromInsurance = $t03964839790._2 | |
902 | 907 | let x = if ((getFromInsurance > 0)) | |
903 | 908 | then { | |
904 | 909 | let withdrawInsurance = invoke(insuranceAddress(), "withdraw", [getFromInsurance], nil) | |
905 | 910 | if ((withdrawInsurance == withdrawInsurance)) | |
906 | 911 | then nil | |
907 | 912 | else throw("Strict value is not equal to itself.") | |
908 | 913 | } | |
909 | 914 | else nil | |
910 | 915 | if ((x == x)) | |
911 | 916 | then { | |
912 | 917 | let unstake = invoke(quoteAssetStaking(), "unlockNeutrino", [(withdrawAmount - getFromInsurance), toBase58String(quoteAsset())], nil) | |
913 | 918 | if ((unstake == unstake)) | |
914 | 919 | then (((deletePosition(toString(i.caller)) ++ updateAmm(quoteAssetReserveAfter, baseAssetReserveAfter, totalPositionSizeAfter, cumulativeNotionalAfter, openInterestNotionalAfter, totalLongAfter, totalShortAfter)) ++ withdraw(i.caller, withdrawAmount)) ++ updateBalance(ammNewBalance)) | |
915 | 920 | else throw("Strict value is not equal to itself.") | |
916 | 921 | } | |
917 | 922 | else throw("Strict value is not equal to itself.") | |
918 | 923 | } | |
919 | 924 | } | |
920 | 925 | ||
921 | 926 | ||
922 | 927 | ||
923 | 928 | @Callable(i) | |
924 | 929 | func liquidate (_trader) = { | |
930 | + | let spotMarginRatio = getMarginRatioByOption(_trader, PNL_OPTION_SPOT) | |
925 | 931 | let marginRatio = if (isOverFluctuationLimit()) | |
926 | - | then getMarginRatioByOption(_trader, PNL_OPTION_ORACLE) | |
927 | - | else getMarginRatioByOption(_trader, PNL_OPTION_SPOT) | |
932 | + | then { | |
933 | + | let oracleMarginRatio = getMarginRatioByOption(_trader, PNL_OPTION_ORACLE) | |
934 | + | vmax(spotMarginRatio, oracleMarginRatio) | |
935 | + | } | |
936 | + | else spotMarginRatio | |
928 | 937 | if (if (if (if (!(requireMoreMarginRatio(marginRatio, maintenanceMarginRatio(), false))) | |
929 | 938 | then true | |
930 | 939 | else !(requireOpenPosition(_trader))) | |
931 | 940 | then true | |
932 | 941 | else !(initialized())) | |
933 | 942 | then true | |
934 | 943 | else paused()) | |
935 | 944 | then throw("Unable to liquidate") | |
936 | 945 | else { | |
937 | - | let $ | |
938 | - | let x1 = $ | |
939 | - | let badDebt = $ | |
940 | - | let x2 = $ | |
941 | - | let | |
942 | - | let quoteAssetReserveAfter = $ | |
943 | - | let baseAssetReserveAfter = $ | |
944 | - | let totalPositionSizeAfter = $ | |
945 | - | let cumulativeNotionalAfter = $ | |
946 | - | let openInterestNotionalAfter = $ | |
947 | - | let exchangedQuoteAssetAmount = $ | |
948 | - | let totalLongAfter = $ | |
949 | - | let totalShortAfter = $ | |
946 | + | let $t04133841754 = internalClosePosition(_trader) | |
947 | + | let x1 = $t04133841754._1 | |
948 | + | let badDebt = $t04133841754._2 | |
949 | + | let x2 = $t04133841754._3 | |
950 | + | let x3 = $t04133841754._4 | |
951 | + | let quoteAssetReserveAfter = $t04133841754._5 | |
952 | + | let baseAssetReserveAfter = $t04133841754._6 | |
953 | + | let totalPositionSizeAfter = $t04133841754._7 | |
954 | + | let cumulativeNotionalAfter = $t04133841754._8 | |
955 | + | let openInterestNotionalAfter = $t04133841754._9 | |
956 | + | let exchangedQuoteAssetAmount = $t04133841754._10 | |
957 | + | let totalLongAfter = $t04133841754._11 | |
958 | + | let totalShortAfter = $t04133841754._12 | |
950 | 959 | let liquidationPenalty = muld(exchangedQuoteAssetAmount, liquidationFeeRatio()) | |
951 | 960 | let feeToLiquidator = (liquidationPenalty / 2) | |
952 | 961 | let feeToInsurance = (liquidationPenalty - feeToLiquidator) | |
953 | 962 | let ammBalance = (cbalance() - liquidationPenalty) | |
954 | - | let $ | |
963 | + | let $t04215242287 = if ((0 > ammBalance)) | |
955 | 964 | then $Tuple2(0, abs(ammBalance)) | |
956 | 965 | else $Tuple2(ammBalance, 0) | |
957 | - | let newAmmBalance = $ | |
958 | - | let takeFromInsurance = $ | |
966 | + | let newAmmBalance = $t04215242287._1 | |
967 | + | let takeFromInsurance = $t04215242287._2 | |
959 | 968 | let x = if ((takeFromInsurance > 0)) | |
960 | 969 | then { | |
961 | 970 | let withdrawInsurance = invoke(insuranceAddress(), "withdraw", [takeFromInsurance], nil) | |
962 | 971 | if ((withdrawInsurance == withdrawInsurance)) | |
963 | 972 | then nil | |
964 | 973 | else throw("Strict value is not equal to itself.") | |
965 | 974 | } | |
966 | 975 | else nil | |
967 | 976 | if ((x == x)) | |
968 | 977 | then { | |
969 | 978 | let unstake = invoke(quoteAssetStaking(), "unlockNeutrino", [(liquidationPenalty - takeFromInsurance), toBase58String(quoteAsset())], nil) | |
970 | 979 | if ((unstake == unstake)) | |
971 | 980 | then { | |
972 | 981 | let depositInsurance = invoke(insuranceAddress(), "deposit", nil, [AttachedPayment(quoteAsset(), feeToInsurance)]) | |
973 | 982 | if ((depositInsurance == depositInsurance)) | |
974 | 983 | then (((deletePosition(_trader) ++ updateAmm(quoteAssetReserveAfter, baseAssetReserveAfter, totalPositionSizeAfter, cumulativeNotionalAfter, openInterestNotionalAfter, totalLongAfter, totalShortAfter)) ++ withdraw(i.caller, feeToLiquidator)) ++ updateBalance(newAmmBalance)) | |
975 | 984 | else throw("Strict value is not equal to itself.") | |
976 | 985 | } | |
977 | 986 | else throw("Strict value is not equal to itself.") | |
978 | 987 | } | |
979 | 988 | else throw("Strict value is not equal to itself.") | |
980 | 989 | } | |
981 | 990 | } | |
982 | 991 | ||
983 | 992 | ||
984 | 993 | ||
985 | 994 | @Callable(i) | |
986 | 995 | func payFunding () = { | |
987 | 996 | let fundingBlockTimestamp = nextFundingBlockTimestamp() | |
988 | 997 | if (if (if ((fundingBlockTimestamp > lastBlock.timestamp)) | |
989 | 998 | then true | |
990 | 999 | else !(initialized())) | |
991 | 1000 | then true | |
992 | 1001 | else paused()) | |
993 | 1002 | then throw(((("Invalid funding block timestamp: " + toString(lastBlock.timestamp)) + " < ") + toString(fundingBlockTimestamp))) | |
994 | 1003 | else { | |
995 | 1004 | let underlyingPrice = getOracleTwapPrice() | |
996 | 1005 | let spotTwapPrice = getTwapSpotPrice() | |
997 | 1006 | let premium = (spotTwapPrice - underlyingPrice) | |
998 | - | let $ | |
1007 | + | let $t04366344998 = if (if ((totalShortPositionSize() == 0)) | |
999 | 1008 | then true | |
1000 | 1009 | else (totalLongPositionSize() == 0)) | |
1001 | 1010 | then $Tuple2(0, 0) | |
1002 | 1011 | else if ((0 > premium)) | |
1003 | 1012 | then { | |
1004 | 1013 | let shortPremiumFraction = divd(muld(premium, fundingPeriodDecimal()), ONE_DAY) | |
1005 | 1014 | let longPremiumFraction = divd(muld(shortPremiumFraction, totalShortPositionSize()), totalLongPositionSize()) | |
1006 | 1015 | $Tuple2(shortPremiumFraction, longPremiumFraction) | |
1007 | 1016 | } | |
1008 | 1017 | else { | |
1009 | 1018 | let longPremiumFraction = divd(muld(premium, fundingPeriodDecimal()), ONE_DAY) | |
1010 | 1019 | let shortPremiumFraction = divd(muld(longPremiumFraction, totalLongPositionSize()), totalShortPositionSize()) | |
1011 | 1020 | $Tuple2(shortPremiumFraction, longPremiumFraction) | |
1012 | 1021 | } | |
1013 | - | let shortPremiumFraction = $ | |
1014 | - | let longPremiumFraction = $ | |
1022 | + | let shortPremiumFraction = $t04366344998._1 | |
1023 | + | let longPremiumFraction = $t04366344998._2 | |
1015 | 1024 | updateFunding((fundingBlockTimestamp + fundingPeriodSeconds()), (latestLongCumulativePremiumFraction() + longPremiumFraction), (latestShortCumulativePremiumFraction() + shortPremiumFraction), divd(longPremiumFraction, underlyingPrice), divd(shortPremiumFraction, underlyingPrice)) | |
1016 | 1025 | } | |
1017 | 1026 | } | |
1018 | 1027 | ||
1019 | 1028 | ||
1020 | 1029 | ||
1021 | 1030 | @Callable(i) | |
1022 | 1031 | func v_get (_trader) = { | |
1023 | - | let $ | |
1024 | - | let x1 = $ | |
1025 | - | let x2 = $ | |
1026 | - | let x3 = $ | |
1027 | - | let x4 = $ | |
1032 | + | let $t04537345426 = internalClosePosition(_trader) | |
1033 | + | let x1 = $t04537345426._1 | |
1034 | + | let x2 = $t04537345426._2 | |
1035 | + | let x3 = $t04537345426._3 | |
1036 | + | let x4 = $t04537345426._4 | |
1028 | 1037 | throw((((s(x2) + s(x3)) + s(x4)) + s(getMarginRatio(_trader)))) | |
1029 | 1038 | } | |
1030 | 1039 | ||
1031 | 1040 | ||
1032 | 1041 | ||
1033 | 1042 | @Callable(i) | |
1034 | 1043 | func view_calcRemainMarginWithFundingPayment (_trader) = { | |
1035 | - | let $ | |
1036 | - | let positionSize = $ | |
1037 | - | let positionMargin = $ | |
1038 | - | let pon = $ | |
1039 | - | let positionLstUpdCPF = $ | |
1040 | - | let $ | |
1041 | - | let positionNotional = $ | |
1042 | - | let unrealizedPnl = $ | |
1043 | - | let $ | |
1044 | - | let remainMargin = $ | |
1045 | - | let badDebt = $ | |
1046 | - | let fundingPayment = $ | |
1044 | + | let $t04557345684 = getPosition(_trader) | |
1045 | + | let positionSize = $t04557345684._1 | |
1046 | + | let positionMargin = $t04557345684._2 | |
1047 | + | let pon = $t04557345684._3 | |
1048 | + | let positionLstUpdCPF = $t04557345684._4 | |
1049 | + | let $t04568945790 = getPositionNotionalAndUnrealizedPnl(_trader, PNL_OPTION_SPOT) | |
1050 | + | let positionNotional = $t04568945790._1 | |
1051 | + | let unrealizedPnl = $t04568945790._2 | |
1052 | + | let $t04579545977 = calcRemainMarginWithFundingPayment(positionSize, positionMargin, positionLstUpdCPF, unrealizedPnl) | |
1053 | + | let remainMargin = $t04579545977._1 | |
1054 | + | let badDebt = $t04579545977._2 | |
1055 | + | let fundingPayment = $t04579545977._3 | |
1047 | 1056 | throw(((s(remainMargin) + s(fundingPayment)) + s(getMarginRatio(_trader)))) | |
1048 | 1057 | } | |
1049 | 1058 | ||
1050 | 1059 | ||
1051 | 1060 | @Verifier(tx) | |
1052 | 1061 | func verify () = sigVerify(tx.bodyBytes, tx.proofs[0], adminPublicKey()) | |
1053 | 1062 |
github/deemru/w8io/026f985 162.44 ms ◑