tx · 9ooVtddK9eVYn2VJz2SSEcyeBpKApkXzmNb1JpFu5rT8 3Msi5oqcsWCbxBx3fiNLJ1Wjf4bp6pZ2gZK: -0.07500000 Waves 2022.12.13 16:01 [2358575] smart account 3Msi5oqcsWCbxBx3fiNLJ1Wjf4bp6pZ2gZK > SELF 0.00000000 Waves
{ "type": 13, "id": "9ooVtddK9eVYn2VJz2SSEcyeBpKApkXzmNb1JpFu5rT8", "fee": 7500000, "feeAssetId": null, "timestamp": 1670936492858, "version": 2, "chainId": 84, "sender": "3Msi5oqcsWCbxBx3fiNLJ1Wjf4bp6pZ2gZK", "senderPublicKey": "5QxdquaDR6y7rkWHRNwqPg46Jm4w7LZEwq6ks4dTfjFy", "proofs": [ "4F5mjtqnLe7tWWAhFwKMEqo4ASDZFCdauQ56y53MwZP9gWjAYmuPyzuMDUcPuTwxBZzjitUUrNGyo9voAVDLzv5L" ], "script": "base64:BgJ6CAISABIAEgASABIDCgEBEgMKAQESDgoMAQEBAQEBAQEBAQEBEhQKEgEBAQEBAQEICAgIAQEBAQEBARIFCgMBAQESBgoEAQEBCBIAEgMKAQESBAoCAQESAwoBCBIAEgASAwoBCBIDCgEBEgASABIDCgEIEgASBAoCCAjAAQAJa19vcmFfa2V5AglrX29yYV9rZXkAD2tfb3JhX2Jsb2NrX2tleQIPa19vcmFfYmxvY2tfa2V5AAVrX29yYQIFa19vcmEACWtfYmFsYW5jZQIJa19iYWxhbmNlAAprX3NlcXVlbmNlAgprX3NlcXVlbmNlAA5rX3Bvc2l0aW9uU2l6ZQIOa19wb3NpdGlvblNpemUAEGtfcG9zaXRpb25NYXJnaW4CEGtfcG9zaXRpb25NYXJnaW4AFmtfcG9zaXRpb25PcGVuTm90aW9uYWwCFmtfcG9zaXRpb25PcGVuTm90aW9uYWwALmtfcG9zaXRpb25MYXN0VXBkYXRlZEN1bXVsYXRpdmVQcmVtaXVtRnJhY3Rpb24CEmtfcG9zaXRpb25GcmFjdGlvbgASa19wb3NpdGlvblNlc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JAQxnZXRTcG90UHJpY2UACQCUCgIFA25pbAUGcmVzdWx0AWkBH2NvbXB1dGVGZWVGb3JUcmFkZXJXaXRoQXJ0aWZhY3QCB190cmFkZXILX2FydGlmYWN0SWQEBnJlc3VsdAkBGGdldEZvclRyYWRlcldpdGhBcnRpZmFjdAIFB190cmFkZXIFC19hcnRpZmFjdElkCQCUCgIFA25pbAUGcmVzdWx0AQJ0eAEGdmVyaWZ5AAkA9AMDCAUCdHgJYm9keUJ5dGVzCQCRAwIIBQJ0eAZwcm9vZnMAAAkBDmFkbWluUHVibGljS2V5AJ90m7k=", "height": 2358575, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: HpM8eqKbUW2j6sdzQnpG4m9Bw2xQeyGd3ZY9P3TiRm9w Next: Fq21Dc1UWRuRmNLFV31UG2f1UgySFJT7XNLqdAPusrYS Diff:
Old | New | Differences | |
---|---|---|---|
1916 | 1916 | ||
1917 | 1917 | @Callable(i) | |
1918 | 1918 | func payFunding () = { | |
1919 | - | let fundingBlockTimestamp = nextFundingBlockTimestamp() | |
1920 | - | if (if (if ((fundingBlockTimestamp > lastBlock.timestamp)) | |
1921 | - | then true | |
1922 | - | else !(initialized())) | |
1923 | - | then true | |
1924 | - | else paused()) | |
1925 | - | then throw(((("Invalid funding block timestamp: " + toString(lastBlock.timestamp)) + " < ") + toString(fundingBlockTimestamp))) | |
1926 | - | else { | |
1927 | - | let underlyingPrice = getOracleTwapPrice() | |
1928 | - | let $t08116581227 = getFunding() | |
1929 | - | let shortPremiumFraction = $t08116581227._1 | |
1930 | - | let longPremiumFraction = $t08116581227._2 | |
1931 | - | updateFunding((fundingBlockTimestamp + fundingPeriodSeconds()), (latestLongCumulativePremiumFraction() + longPremiumFraction), (latestShortCumulativePremiumFraction() + shortPremiumFraction), divd(longPremiumFraction, underlyingPrice), divd(shortPremiumFraction, underlyingPrice)) | |
1932 | - | } | |
1919 | + | let sync = invoke(this, "syncTerminalPriceToOracle", nil, nil) | |
1920 | + | if ((sync == sync)) | |
1921 | + | then { | |
1922 | + | let fundingBlockTimestamp = nextFundingBlockTimestamp() | |
1923 | + | if (if (if ((fundingBlockTimestamp > lastBlock.timestamp)) | |
1924 | + | then true | |
1925 | + | else !(initialized())) | |
1926 | + | then true | |
1927 | + | else paused()) | |
1928 | + | then throw(((("Invalid funding block timestamp: " + toString(lastBlock.timestamp)) + " < ") + toString(fundingBlockTimestamp))) | |
1929 | + | else { | |
1930 | + | let underlyingPrice = getOracleTwapPrice() | |
1931 | + | let $t08123481296 = getFunding() | |
1932 | + | let shortPremiumFraction = $t08123481296._1 | |
1933 | + | let longPremiumFraction = $t08123481296._2 | |
1934 | + | updateFunding((fundingBlockTimestamp + fundingPeriodSeconds()), (latestLongCumulativePremiumFraction() + longPremiumFraction), (latestShortCumulativePremiumFraction() + shortPremiumFraction), divd(longPremiumFraction, underlyingPrice), divd(shortPremiumFraction, underlyingPrice)) | |
1935 | + | } | |
1936 | + | } | |
1937 | + | else throw("Strict value is not equal to itself.") | |
1933 | 1938 | } | |
1934 | 1939 | ||
1935 | 1940 | ||
1936 | 1941 | ||
1937 | 1942 | @Callable(i) | |
1938 | 1943 | func syncTerminalPriceToOracle () = { | |
1939 | - | let $ | |
1940 | - | let newQuoteAssetWeight = $ | |
1941 | - | let newBaseAssetWeight = $ | |
1942 | - | let marginToVault = $ | |
1944 | + | let $t08167881799 = getSyncTerminalPrice(getOracleTwapPrice()) | |
1945 | + | let newQuoteAssetWeight = $t08167881799._1 | |
1946 | + | let newBaseAssetWeight = $t08167881799._2 | |
1947 | + | let marginToVault = $t08167881799._3 | |
1943 | 1948 | let doExchangePnL = if ((marginToVault != 0)) | |
1944 | 1949 | then { | |
1945 | 1950 | let doExchangePnL = invoke(vaultAddress(), "exchangeFreeAndLocked", [marginToVault], nil) | |
1949 | 1954 | } | |
1950 | 1955 | else nil | |
1951 | 1956 | if ((doExchangePnL == doExchangePnL)) | |
1952 | - | then updateAmmWeights(newQuoteAssetWeight, newBaseAssetWeight) | |
1957 | + | then { | |
1958 | + | let _qtAstR = qtAstR() | |
1959 | + | let _bsAstR = bsAstR() | |
1960 | + | (updateAmmWeights(newQuoteAssetWeight, newBaseAssetWeight) ++ appendTwap(divd(muld(_qtAstR, newQuoteAssetWeight), muld(_bsAstR, newBaseAssetWeight)))) | |
1961 | + | } | |
1953 | 1962 | else throw("Strict value is not equal to itself.") | |
1954 | 1963 | } | |
1955 | 1964 | ||
1960 | 1969 | let sync = invoke(this, "syncTerminalPriceToOracle", nil, nil) | |
1961 | 1970 | if ((sync == sync)) | |
1962 | 1971 | then { | |
1963 | - | let $ | |
1964 | - | let positionSize = $ | |
1965 | - | let positionMargin = $ | |
1966 | - | let pon = $ | |
1967 | - | let positionLstUpdCPF = $ | |
1968 | - | let $ | |
1969 | - | let positionNotional = $ | |
1970 | - | let unrealizedPnl = $ | |
1971 | - | let $ | |
1972 | - | let remainMargin = $ | |
1973 | - | let badDebt = $ | |
1974 | - | let fundingPayment = $ | |
1972 | + | let $t08241982520 = getPosition(_trader) | |
1973 | + | let positionSize = $t08241982520._1 | |
1974 | + | let positionMargin = $t08241982520._2 | |
1975 | + | let pon = $t08241982520._3 | |
1976 | + | let positionLstUpdCPF = $t08241982520._4 | |
1977 | + | let $t08252382624 = getPositionNotionalAndUnrealizedPnl(_trader, PNL_OPTION_SPOT) | |
1978 | + | let positionNotional = $t08252382624._1 | |
1979 | + | let unrealizedPnl = $t08252382624._2 | |
1980 | + | let $t08262782799 = calcRemainMarginWithFundingPayment(positionSize, positionMargin, positionLstUpdCPF, unrealizedPnl) | |
1981 | + | let remainMargin = $t08262782799._1 | |
1982 | + | let badDebt = $t08262782799._2 | |
1983 | + | let fundingPayment = $t08262782799._3 | |
1975 | 1984 | throw((((((s(remainMargin) + s(fundingPayment)) + s(getMarginRatio(_trader))) + s(unrealizedPnl)) + s(badDebt)) + s(positionNotional))) | |
1976 | 1985 | } | |
1977 | 1986 | else throw("Strict value is not equal to itself.") | |
1989 | 1998 | ||
1990 | 1999 | @Callable(i) | |
1991 | 2000 | func view_getTerminalAmmPrice () = { | |
1992 | - | let $ | |
1993 | - | let terminalQuoteAssetReserve = $ | |
1994 | - | let terminalBaseAssetReserve = $ | |
2001 | + | let $t08314683227 = getTerminalAmmState() | |
2002 | + | let terminalQuoteAssetReserve = $t08314683227._1 | |
2003 | + | let terminalBaseAssetReserve = $t08314683227._2 | |
1995 | 2004 | let price = divd(muld(terminalQuoteAssetReserve, qtAstW()), muld(terminalBaseAssetReserve, bsAstW())) | |
1996 | 2005 | throw(toString(price)) | |
1997 | 2006 | } | |
2001 | 2010 | @Callable(i) | |
2002 | 2011 | func view_getFunding () = { | |
2003 | 2012 | let underlyingPrice = getOracleTwapPrice() | |
2004 | - | let $ | |
2005 | - | let shortPremiumFraction = $ | |
2006 | - | let longPremiumFraction = $ | |
2013 | + | let $t08344683508 = getFunding() | |
2014 | + | let shortPremiumFraction = $t08344683508._1 | |
2015 | + | let longPremiumFraction = $t08344683508._2 | |
2007 | 2016 | let longFunding = divd(longPremiumFraction, underlyingPrice) | |
2008 | 2017 | let shortFunding = divd(shortPremiumFraction, underlyingPrice) | |
2009 | 2018 | throw((((s(longFunding) + s(shortFunding)) + s(getTwapSpotPrice())) + s(getOracleTwapPrice()))) | |
2013 | 2022 | ||
2014 | 2023 | @Callable(i) | |
2015 | 2024 | func view_getBorrowedByTrader (_trader) = { | |
2016 | - | let $ | |
2017 | - | let borrowed = $ | |
2018 | - | let assetId = $ | |
2025 | + | let $t08379883852 = getBorrowedByTrader(_trader) | |
2026 | + | let borrowed = $t08379883852._1 | |
2027 | + | let assetId = $t08379883852._2 | |
2019 | 2028 | throw((s(borrowed) + assetId)) | |
2020 | 2029 | } | |
2021 | 2030 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
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_sequence = "k_sequence" | |
13 | 13 | ||
14 | 14 | let k_positionSize = "k_positionSize" | |
15 | 15 | ||
16 | 16 | let k_positionMargin = "k_positionMargin" | |
17 | 17 | ||
18 | 18 | let k_positionOpenNotional = "k_positionOpenNotional" | |
19 | 19 | ||
20 | 20 | let k_positionLastUpdatedCumulativePremiumFraction = "k_positionFraction" | |
21 | 21 | ||
22 | 22 | let k_positionSequence = "k_positionSequence" | |
23 | 23 | ||
24 | 24 | let k_positionAsset = "k_positionAsset" | |
25 | 25 | ||
26 | 26 | let k_initialized = "k_initialized" | |
27 | 27 | ||
28 | 28 | let k_paused = "k_paused" | |
29 | 29 | ||
30 | 30 | let k_closeOnly = "k_closeOnly" | |
31 | 31 | ||
32 | 32 | let k_fee = "k_fee" | |
33 | 33 | ||
34 | 34 | let k_fundingPeriod = "k_fundingPeriod" | |
35 | 35 | ||
36 | 36 | let k_initMarginRatio = "k_initMarginRatio" | |
37 | 37 | ||
38 | 38 | let k_maintenanceMarginRatio = "k_mmr" | |
39 | 39 | ||
40 | 40 | let k_liquidationFeeRatio = "k_liquidationFeeRatio" | |
41 | 41 | ||
42 | 42 | let k_partialLiquidationRatio = "k_partLiquidationRatio" | |
43 | 43 | ||
44 | 44 | let k_spreadLimit = "k_spreadLimit" | |
45 | 45 | ||
46 | 46 | let k_maxPriceImpact = "k_maxPriceImpact" | |
47 | 47 | ||
48 | 48 | let k_maxPriceSpread = "k_maxPriceSpread" | |
49 | 49 | ||
50 | 50 | let k_maxOpenNotional = "k_maxOpenNotional" | |
51 | 51 | ||
52 | 52 | let k_feeToStakersPercent = "k_feeToStakersPercent" | |
53 | 53 | ||
54 | 54 | let k_maxOracleDelay = "k_maxOracleDelay" | |
55 | 55 | ||
56 | 56 | let k_lastDataStr = "k_lastDataStr" | |
57 | 57 | ||
58 | 58 | let k_lastMinuteId = "k_lastMinuteId" | |
59 | 59 | ||
60 | 60 | let k_twapDataLastCumulativePrice = "k_twapDataLastCumulativePrice" | |
61 | 61 | ||
62 | 62 | let k_twapDataLastPrice = "k_twapDataLastPrice" | |
63 | 63 | ||
64 | 64 | let k_twapDataPreviousMinuteId = "k_twapDataPreviousMinuteId" | |
65 | 65 | ||
66 | 66 | let k_latestLongCumulativePremiumFraction = "k_latestLongPremiumFraction" | |
67 | 67 | ||
68 | 68 | let k_latestShortCumulativePremiumFraction = "k_latestShortPremiumFraction" | |
69 | 69 | ||
70 | 70 | let k_nextFundingBlock = "k_nextFundingBlockMinTimestamp" | |
71 | 71 | ||
72 | 72 | let k_longFundingRate = "k_longFundingRate" | |
73 | 73 | ||
74 | 74 | let k_shortFundingRate = "k_shortFundingRate" | |
75 | 75 | ||
76 | 76 | let k_quoteAssetReserve = "k_qtAstR" | |
77 | 77 | ||
78 | 78 | let k_baseAssetReserve = "k_bsAstR" | |
79 | 79 | ||
80 | 80 | let k_quoteAssetWeight = "k_qtAstW" | |
81 | 81 | ||
82 | 82 | let k_baseAssetWeight = "k_bsAstW" | |
83 | 83 | ||
84 | 84 | let k_totalPositionSize = "k_totalPositionSize" | |
85 | 85 | ||
86 | 86 | let k_totalLongPositionSize = "k_totalLongPositionSize" | |
87 | 87 | ||
88 | 88 | let k_totalShortPositionSize = "k_totalShortPositionSize" | |
89 | 89 | ||
90 | 90 | let k_openInterestNotional = "k_openInterestNotional" | |
91 | 91 | ||
92 | 92 | let k_openInterestShort = "k_openInterestShort" | |
93 | 93 | ||
94 | 94 | let k_openInterestLong = "k_openInterestLong" | |
95 | 95 | ||
96 | 96 | let k_coordinatorAddress = "k_coordinatorAddress" | |
97 | 97 | ||
98 | 98 | let k_vault_address = "k_vault_address" | |
99 | 99 | ||
100 | 100 | let k_admin_address = "k_admin_address" | |
101 | 101 | ||
102 | 102 | let k_admin_public_key = "k_admin_public_key" | |
103 | 103 | ||
104 | 104 | let k_quote_asset = "k_quote_asset" | |
105 | 105 | ||
106 | 106 | let k_quote_staking = "k_quote_staking" | |
107 | 107 | ||
108 | 108 | let k_staking_address = "k_staking_address" | |
109 | 109 | ||
110 | 110 | let k_miner_address = "k_miner_address" | |
111 | 111 | ||
112 | 112 | let k_orders_address = "k_orders_address" | |
113 | 113 | ||
114 | 114 | let k_referral_address = "k_referral_address" | |
115 | 115 | ||
116 | 116 | let k_collateral_address = "k_collateral_address" | |
117 | 117 | ||
118 | 118 | let k_exchange_address = "k_exchange_address" | |
119 | 119 | ||
120 | 120 | let k_nft_manager_address = "k_nft_manager_address" | |
121 | 121 | ||
122 | 122 | let k_trader_market_asset_collateral = "k_trader_market_asset_collateral" | |
123 | 123 | ||
124 | 124 | func toCompositeKey (_key,_address) = ((_key + "_") + _address) | |
125 | 125 | ||
126 | 126 | ||
127 | 127 | func coordinator () = valueOrErrorMessage(addressFromString(getStringValue(this, k_coordinatorAddress)), "Coordinator not set") | |
128 | 128 | ||
129 | 129 | ||
130 | 130 | func adminAddress () = addressFromString(getStringValue(coordinator(), k_admin_address)) | |
131 | 131 | ||
132 | 132 | ||
133 | 133 | func adminPublicKey () = fromBase58String(getStringValue(coordinator(), k_admin_public_key)) | |
134 | 134 | ||
135 | 135 | ||
136 | 136 | func quoteAsset () = fromBase58String(getStringValue(coordinator(), k_quote_asset)) | |
137 | 137 | ||
138 | 138 | ||
139 | 139 | func quoteAssetStaking () = valueOrErrorMessage(addressFromString(getStringValue(coordinator(), k_quote_staking)), "Quote asset staking not set") | |
140 | 140 | ||
141 | 141 | ||
142 | 142 | func stakingAddress () = valueOrErrorMessage(addressFromString(getStringValue(coordinator(), k_staking_address)), "Staking not set") | |
143 | 143 | ||
144 | 144 | ||
145 | 145 | func vaultAddress () = valueOrErrorMessage(addressFromString(getStringValue(coordinator(), k_vault_address)), "Vault not set") | |
146 | 146 | ||
147 | 147 | ||
148 | 148 | func minerAddress () = valueOrErrorMessage(addressFromString(getStringValue(coordinator(), k_miner_address)), "Miner not set") | |
149 | 149 | ||
150 | 150 | ||
151 | 151 | func ordersAddress () = valueOrErrorMessage(addressFromString(getStringValue(coordinator(), k_orders_address)), "Orders not set") | |
152 | 152 | ||
153 | 153 | ||
154 | 154 | func referralAddress () = valueOrErrorMessage(addressFromString(getStringValue(coordinator(), k_referral_address)), "Referral not set") | |
155 | 155 | ||
156 | 156 | ||
157 | 157 | func nftManagerAddress () = valueOrErrorMessage(addressFromString(getStringValue(coordinator(), k_nft_manager_address)), "NFT Manager not set") | |
158 | 158 | ||
159 | 159 | ||
160 | 160 | func collateralAddress () = valueOrErrorMessage(addressFromString(getStringValue(coordinator(), k_collateral_address)), "Collateral Manager not set") | |
161 | 161 | ||
162 | 162 | ||
163 | 163 | func swapAddress () = valueOrErrorMessage(addressFromString(valueOrErrorMessage(getString(coordinator(), k_exchange_address), "No swap address")), "Invalid swap address") | |
164 | 164 | ||
165 | 165 | ||
166 | 166 | let k_whitelist_asset = "k_whitelist_asset" | |
167 | 167 | ||
168 | 168 | func isWhitelistAsset (_assetId) = valueOrElse(getBoolean(collateralAddress(), toCompositeKey(k_whitelist_asset, _assetId)), false) | |
169 | 169 | ||
170 | 170 | ||
171 | 171 | let k_token_param = "k_token_param" | |
172 | 172 | ||
173 | 173 | let k_token_type = "k_token_type" | |
174 | 174 | ||
175 | 175 | let FEE_REDUCTION_TOKEN_TYPE = "fee_reduction" | |
176 | 176 | ||
177 | 177 | let DIR_LONG = 1 | |
178 | 178 | ||
179 | 179 | let DIR_SHORT = 2 | |
180 | 180 | ||
181 | 181 | let TWAP_INTERVAL = 15 | |
182 | 182 | ||
183 | 183 | let ORACLE_INTERVAL = 15 | |
184 | 184 | ||
185 | 185 | let SECONDS = 1000 | |
186 | 186 | ||
187 | 187 | let DECIMAL_NUMBERS = 6 | |
188 | 188 | ||
189 | 189 | let DECIMAL_UNIT = (1 * (((((10 * 10) * 10) * 10) * 10) * 10)) | |
190 | 190 | ||
191 | 191 | let ONE_DAY = (86400 * DECIMAL_UNIT) | |
192 | 192 | ||
193 | 193 | let ALL_FEES = 100 | |
194 | 194 | ||
195 | 195 | let PNL_OPTION_SPOT = 1 | |
196 | 196 | ||
197 | 197 | let PNL_OPTION_ORACLE = 2 | |
198 | 198 | ||
199 | 199 | func s (_x) = (toString(_x) + ",") | |
200 | 200 | ||
201 | 201 | ||
202 | 202 | func divd (_x,_y) = fraction(_x, DECIMAL_UNIT, _y, HALFEVEN) | |
203 | 203 | ||
204 | 204 | ||
205 | 205 | func muld (_x,_y) = fraction(_x, _y, DECIMAL_UNIT, HALFEVEN) | |
206 | 206 | ||
207 | 207 | ||
208 | 208 | func sqrtd (_x) = sqrt(_x, DECIMAL_NUMBERS, DECIMAL_NUMBERS, HALFEVEN) | |
209 | 209 | ||
210 | 210 | ||
211 | 211 | func powd (_x,_y) = pow(_x, DECIMAL_NUMBERS, _y, DECIMAL_NUMBERS, DECIMAL_NUMBERS, HALFEVEN) | |
212 | 212 | ||
213 | 213 | ||
214 | 214 | func bdivd (_x,_y) = fraction(_x, toBigInt(DECIMAL_UNIT), _y, HALFEVEN) | |
215 | 215 | ||
216 | 216 | ||
217 | 217 | func bmuld (_x,_y) = fraction(_x, _y, toBigInt(DECIMAL_UNIT), HALFEVEN) | |
218 | 218 | ||
219 | 219 | ||
220 | 220 | func bsqrtd (_x) = sqrtBigInt(_x, DECIMAL_NUMBERS, DECIMAL_NUMBERS, HALFEVEN) | |
221 | 221 | ||
222 | 222 | ||
223 | 223 | func bpowd (_x,_y) = pow(_x, DECIMAL_NUMBERS, _y, DECIMAL_NUMBERS, DECIMAL_NUMBERS, HALFEVEN) | |
224 | 224 | ||
225 | 225 | ||
226 | 226 | func abs (_x) = if ((_x > 0)) | |
227 | 227 | then _x | |
228 | 228 | else -(_x) | |
229 | 229 | ||
230 | 230 | ||
231 | 231 | func vmax (_x,_y) = if ((_x >= _y)) | |
232 | 232 | then _x | |
233 | 233 | else _y | |
234 | 234 | ||
235 | 235 | ||
236 | 236 | func listToStr (_list) = { | |
237 | 237 | func _join (accumulator,val) = ((accumulator + val) + ",") | |
238 | 238 | ||
239 | 239 | let newListStr = { | |
240 | 240 | let $l = _list | |
241 | 241 | let $s = size($l) | |
242 | 242 | let $acc0 = "" | |
243 | 243 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
244 | 244 | then $a | |
245 | 245 | else _join($a, $l[$i]) | |
246 | 246 | ||
247 | 247 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
248 | 248 | then $a | |
249 | 249 | else throw("List size exceeds 20") | |
250 | 250 | ||
251 | 251 | $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) | |
252 | 252 | } | |
253 | 253 | let newListStrU = dropRight(newListStr, 1) | |
254 | 254 | let newListStrR = if ((take(newListStrU, 1) == ",")) | |
255 | 255 | then drop(newListStrU, 1) | |
256 | 256 | else newListStrU | |
257 | 257 | newListStrR | |
258 | 258 | } | |
259 | 259 | ||
260 | 260 | ||
261 | 261 | func strToList (_str) = split(_str, ",") | |
262 | 262 | ||
263 | 263 | ||
264 | 264 | func pushToQueue (_list,_maxSize,_value) = if ((size(_list) > _maxSize)) | |
265 | 265 | then (removeByIndex(_list, 0) :+ _value) | |
266 | 266 | else (_list :+ _value) | |
267 | 267 | ||
268 | 268 | ||
269 | 269 | func int (k) = valueOrErrorMessage(getInteger(this, k), ("no value for " + k)) | |
270 | 270 | ||
271 | 271 | ||
272 | 272 | func intOr (k,def) = valueOrElse(getInteger(this, k), def) | |
273 | 273 | ||
274 | 274 | ||
275 | 275 | func strA (_address,_key) = { | |
276 | 276 | let val = valueOrErrorMessage(getString(_address, _key), ("No value for key " + _key)) | |
277 | 277 | val | |
278 | 278 | } | |
279 | 279 | ||
280 | 280 | ||
281 | 281 | func intA (_address,_key) = { | |
282 | 282 | let val = valueOrErrorMessage(getInteger(_address, _key), ("No value for key " + _key)) | |
283 | 283 | val | |
284 | 284 | } | |
285 | 285 | ||
286 | 286 | ||
287 | 287 | func cbalance () = int(k_balance) | |
288 | 288 | ||
289 | 289 | ||
290 | 290 | func fee () = int(k_fee) | |
291 | 291 | ||
292 | 292 | ||
293 | 293 | func initMarginRatio () = int(k_initMarginRatio) | |
294 | 294 | ||
295 | 295 | ||
296 | 296 | func qtAstR () = int(k_quoteAssetReserve) | |
297 | 297 | ||
298 | 298 | ||
299 | 299 | func bsAstR () = int(k_baseAssetReserve) | |
300 | 300 | ||
301 | 301 | ||
302 | 302 | func qtAstW () = intOr(k_quoteAssetWeight, DECIMAL_UNIT) | |
303 | 303 | ||
304 | 304 | ||
305 | 305 | func bsAstW () = intOr(k_baseAssetWeight, DECIMAL_UNIT) | |
306 | 306 | ||
307 | 307 | ||
308 | 308 | func totalPositionSize () = int(k_totalPositionSize) | |
309 | 309 | ||
310 | 310 | ||
311 | 311 | func openInterestNotional () = int(k_openInterestNotional) | |
312 | 312 | ||
313 | 313 | ||
314 | 314 | func openInterestShort () = int(k_openInterestShort) | |
315 | 315 | ||
316 | 316 | ||
317 | 317 | func openInterestLong () = int(k_openInterestLong) | |
318 | 318 | ||
319 | 319 | ||
320 | 320 | func nextFundingBlockTimestamp () = int(k_nextFundingBlock) | |
321 | 321 | ||
322 | 322 | ||
323 | 323 | func fundingPeriodRaw () = int(k_fundingPeriod) | |
324 | 324 | ||
325 | 325 | ||
326 | 326 | func fundingPeriodDecimal () = (fundingPeriodRaw() * DECIMAL_UNIT) | |
327 | 327 | ||
328 | 328 | ||
329 | 329 | func fundingPeriodSeconds () = (fundingPeriodRaw() * SECONDS) | |
330 | 330 | ||
331 | 331 | ||
332 | 332 | func maintenanceMarginRatio () = int(k_maintenanceMarginRatio) | |
333 | 333 | ||
334 | 334 | ||
335 | 335 | func liquidationFeeRatio () = int(k_liquidationFeeRatio) | |
336 | 336 | ||
337 | 337 | ||
338 | 338 | func partialLiquidationRatio () = int(k_partialLiquidationRatio) | |
339 | 339 | ||
340 | 340 | ||
341 | 341 | func spreadLimit () = int(k_spreadLimit) | |
342 | 342 | ||
343 | 343 | ||
344 | 344 | func maxPriceImpact () = int(k_maxPriceImpact) | |
345 | 345 | ||
346 | 346 | ||
347 | 347 | func maxPriceSpread () = int(k_maxPriceSpread) | |
348 | 348 | ||
349 | 349 | ||
350 | 350 | func maxOpenNotional () = int(k_maxOpenNotional) | |
351 | 351 | ||
352 | 352 | ||
353 | 353 | func latestLongCumulativePremiumFraction () = int(k_latestLongCumulativePremiumFraction) | |
354 | 354 | ||
355 | 355 | ||
356 | 356 | func latestShortCumulativePremiumFraction () = int(k_latestShortCumulativePremiumFraction) | |
357 | 357 | ||
358 | 358 | ||
359 | 359 | func totalShortPositionSize () = int(k_totalShortPositionSize) | |
360 | 360 | ||
361 | 361 | ||
362 | 362 | func totalLongPositionSize () = int(k_totalLongPositionSize) | |
363 | 363 | ||
364 | 364 | ||
365 | 365 | func lastSequence () = intOr(k_sequence, 0) | |
366 | 366 | ||
367 | 367 | ||
368 | 368 | func feeToStakersPercent () = int(k_feeToStakersPercent) | |
369 | 369 | ||
370 | 370 | ||
371 | 371 | func maxOracleDelay () = int(k_maxOracleDelay) | |
372 | 372 | ||
373 | 373 | ||
374 | 374 | func getActualCaller (i) = valueOrElse(getString(ordersAddress(), "k_sender"), toString(i.caller)) | |
375 | 375 | ||
376 | 376 | ||
377 | 377 | func requireMoreMarginRatio (_marginRatio,_baseMarginRatio,_largerThanOrEqualTo) = { | |
378 | 378 | let remainingMarginRatio = (_marginRatio - _baseMarginRatio) | |
379 | 379 | if (if (_largerThanOrEqualTo) | |
380 | 380 | then (0 > remainingMarginRatio) | |
381 | 381 | else false) | |
382 | 382 | then throw("Invalid margin") | |
383 | 383 | else if (if (!(_largerThanOrEqualTo)) | |
384 | 384 | then (remainingMarginRatio >= 0) | |
385 | 385 | else false) | |
386 | 386 | then throw("Invalid margin") | |
387 | 387 | else true | |
388 | 388 | } | |
389 | 389 | ||
390 | 390 | ||
391 | 391 | func latestCumulativePremiumFraction (_positionSize) = if ((_positionSize == 0)) | |
392 | 392 | then throw("Should not be called with _positionSize == 0") | |
393 | 393 | else if ((_positionSize > 0)) | |
394 | 394 | then latestLongCumulativePremiumFraction() | |
395 | 395 | else latestShortCumulativePremiumFraction() | |
396 | 396 | ||
397 | 397 | ||
398 | 398 | func getPosition (_trader) = { | |
399 | 399 | let positionSizeOpt = getInteger(this, toCompositeKey(k_positionSize, _trader)) | |
400 | 400 | match positionSizeOpt { | |
401 | 401 | case positionSize: Int => | |
402 | 402 | $Tuple4(positionSize, getIntegerValue(this, toCompositeKey(k_positionMargin, _trader)), getIntegerValue(this, toCompositeKey(k_positionOpenNotional, _trader)), getIntegerValue(this, toCompositeKey(k_positionLastUpdatedCumulativePremiumFraction, _trader))) | |
403 | 403 | case _ => | |
404 | 404 | $Tuple4(0, 0, 0, 0) | |
405 | 405 | } | |
406 | 406 | } | |
407 | 407 | ||
408 | 408 | ||
409 | 409 | func getPositionAsset (_trader) = { | |
410 | 410 | let positionAssetOpt = getString(this, toCompositeKey(k_positionAsset, _trader)) | |
411 | 411 | match positionAssetOpt { | |
412 | 412 | case positionAsset: String => | |
413 | 413 | positionAsset | |
414 | 414 | case _ => | |
415 | 415 | toBase58String(quoteAsset()) | |
416 | 416 | } | |
417 | 417 | } | |
418 | 418 | ||
419 | 419 | ||
420 | 420 | func requireOpenPosition (_trader) = if ((getPosition(_trader)._1 == 0)) | |
421 | 421 | then throw("No open position") | |
422 | 422 | else true | |
423 | 423 | ||
424 | 424 | ||
425 | 425 | func initialized () = valueOrElse(getBoolean(this, k_initialized), false) | |
426 | 426 | ||
427 | 427 | ||
428 | 428 | func paused () = valueOrElse(getBoolean(this, k_paused), false) | |
429 | 429 | ||
430 | 430 | ||
431 | 431 | func closeOnly () = valueOrElse(getBoolean(this, k_closeOnly), false) | |
432 | 432 | ||
433 | 433 | ||
434 | 434 | func updateReserve (_isAdd,_quoteAssetAmount,_baseAssetAmount) = if (_isAdd) | |
435 | 435 | then { | |
436 | 436 | let newBase = (bsAstR() - _baseAssetAmount) | |
437 | 437 | if ((0 >= newBase)) | |
438 | 438 | then throw("Tx lead to base asset reserve <= 0, revert") | |
439 | 439 | else $Tuple3((qtAstR() + _quoteAssetAmount), newBase, (totalPositionSize() + _baseAssetAmount)) | |
440 | 440 | } | |
441 | 441 | else { | |
442 | 442 | let newQuote = (qtAstR() - _quoteAssetAmount) | |
443 | 443 | if ((0 >= newQuote)) | |
444 | 444 | then throw("Tx lead to base quote reserve <= 0, revert") | |
445 | 445 | else $Tuple3(newQuote, (bsAstR() + _baseAssetAmount), (totalPositionSize() - _baseAssetAmount)) | |
446 | 446 | } | |
447 | 447 | ||
448 | 448 | ||
449 | 449 | func calcInvariant (_qtAstR,_qtAstW,_bsAstR,_bsAstW) = { | |
450 | 450 | let bqtAstR = toBigInt(_qtAstR) | |
451 | 451 | let bqtAstW = toBigInt(_qtAstW) | |
452 | 452 | let bbsAstR = toBigInt(_bsAstR) | |
453 | 453 | let bbsAstW = toBigInt(_bsAstW) | |
454 | 454 | bmuld(bmuld(bqtAstR, bqtAstW), bmuld(bbsAstR, bbsAstW)) | |
455 | 455 | } | |
456 | 456 | ||
457 | 457 | ||
458 | 458 | func swapInput (_isAdd,_quoteAssetAmount) = { | |
459 | 459 | let _qtAstR = qtAstR() | |
460 | 460 | let _bsAstR = bsAstR() | |
461 | 461 | let _qtAstW = qtAstW() | |
462 | 462 | let _bsAstW = bsAstW() | |
463 | 463 | let k = calcInvariant(_qtAstR, _qtAstW, _bsAstR, _bsAstW) | |
464 | 464 | let quoteAssetReserveAfter = if (_isAdd) | |
465 | 465 | then (_qtAstR + _quoteAssetAmount) | |
466 | 466 | else (_qtAstR - _quoteAssetAmount) | |
467 | 467 | let baseAssetReserveAfter = toInt(bdivd(k, toBigInt(muld(quoteAssetReserveAfter, _qtAstW)))) | |
468 | 468 | let amountBaseAssetBoughtAbs = divd(abs((baseAssetReserveAfter - _bsAstR)), _qtAstW) | |
469 | 469 | let amountBaseAssetBought = if (_isAdd) | |
470 | 470 | then amountBaseAssetBoughtAbs | |
471 | 471 | else -(amountBaseAssetBoughtAbs) | |
472 | 472 | let $t01694617109 = updateReserve(_isAdd, _quoteAssetAmount, amountBaseAssetBoughtAbs) | |
473 | 473 | let quoteAssetReserveAfter1 = $t01694617109._1 | |
474 | 474 | let baseAssetReserveAfter1 = $t01694617109._2 | |
475 | 475 | let totalPositionSizeAfter1 = $t01694617109._3 | |
476 | 476 | let priceBefore = divd(muld(_qtAstR, _qtAstW), muld(_bsAstR, _bsAstW)) | |
477 | 477 | let marketPrice = divd(_quoteAssetAmount, amountBaseAssetBoughtAbs) | |
478 | 478 | let priceDiff = abs((priceBefore - marketPrice)) | |
479 | 479 | let priceImpact = (DECIMAL_UNIT - divd(priceBefore, (priceBefore + priceDiff))) | |
480 | 480 | let maxPriceImpactValue = maxPriceImpact() | |
481 | 481 | if ((priceImpact > maxPriceImpactValue)) | |
482 | 482 | then throw(((((((((((((("Price impact " + toString(priceImpact)) + " > max price impact ") + toString(maxPriceImpactValue)) + " before quote asset: ") + toString(_qtAstR)) + " before base asset: ") + toString(_bsAstR)) + " quote asset amount to exchange: ") + toString(_quoteAssetAmount)) + " price before: ") + toString(priceBefore)) + " marketPrice: ") + toString(marketPrice))) | |
483 | 483 | else $Tuple4(amountBaseAssetBought, quoteAssetReserveAfter1, baseAssetReserveAfter1, totalPositionSizeAfter1) | |
484 | 484 | } | |
485 | 485 | ||
486 | 486 | ||
487 | 487 | func calcRemainMarginWithFundingPayment (_oldPositionSize,_oldPositionMargin,_oldPositionCumulativePremiumFraction,_marginDelta) = { | |
488 | 488 | let fundingPayment = if ((_oldPositionSize != 0)) | |
489 | 489 | then { | |
490 | 490 | let _latestCumulativePremiumFraction = latestCumulativePremiumFraction(_oldPositionSize) | |
491 | 491 | muld((_latestCumulativePremiumFraction - _oldPositionCumulativePremiumFraction), _oldPositionSize) | |
492 | 492 | } | |
493 | 493 | else 0 | |
494 | 494 | let signedMargin = ((_marginDelta - fundingPayment) + _oldPositionMargin) | |
495 | 495 | let $t01859618723 = if ((0 > signedMargin)) | |
496 | 496 | then $Tuple2(0, abs(signedMargin)) | |
497 | 497 | else $Tuple2(abs(signedMargin), 0) | |
498 | 498 | let remainMargin = $t01859618723._1 | |
499 | 499 | let badDebt = $t01859618723._2 | |
500 | 500 | $Tuple3(remainMargin, badDebt, fundingPayment) | |
501 | 501 | } | |
502 | 502 | ||
503 | 503 | ||
504 | 504 | func swapOutputWithReserves (_isAdd,_baseAssetAmount,_checkMaxPriceImpact,_quoteAssetReserve,_quoteAssetWeight,_baseAssetReserve,_baseAssetWeight) = { | |
505 | 505 | let priceBefore = divd(muld(_quoteAssetReserve, _quoteAssetWeight), muld(_baseAssetReserve, _baseAssetWeight)) | |
506 | 506 | if ((_baseAssetAmount == 0)) | |
507 | 507 | then throw("Invalid base asset amount") | |
508 | 508 | else { | |
509 | 509 | let k = calcInvariant(_quoteAssetReserve, _quoteAssetWeight, _baseAssetReserve, _baseAssetWeight) | |
510 | 510 | let baseAssetPoolAmountAfter = if (_isAdd) | |
511 | 511 | then (_baseAssetReserve + _baseAssetAmount) | |
512 | 512 | else (_baseAssetReserve - _baseAssetAmount) | |
513 | 513 | let quoteAssetAfter = toInt(bdivd(k, toBigInt(muld(baseAssetPoolAmountAfter, _baseAssetWeight)))) | |
514 | 514 | let quoteAssetSold = abs((quoteAssetAfter - muld(_quoteAssetReserve, _quoteAssetWeight))) | |
515 | 515 | let maxPriceImpactValue = maxPriceImpact() | |
516 | 516 | let $t01991120072 = updateReserve(!(_isAdd), quoteAssetSold, _baseAssetAmount) | |
517 | 517 | let quoteAssetReserveAfter1 = $t01991120072._1 | |
518 | 518 | let baseAssetReserveAfter1 = $t01991120072._2 | |
519 | 519 | let totalPositionSizeAfter1 = $t01991120072._3 | |
520 | 520 | let marketPrice = divd(quoteAssetSold, _baseAssetAmount) | |
521 | 521 | let priceDiff = abs((priceBefore - marketPrice)) | |
522 | 522 | let priceImpact = (DECIMAL_UNIT - divd(priceBefore, (priceBefore + priceDiff))) | |
523 | 523 | if (if ((priceImpact > maxPriceImpactValue)) | |
524 | 524 | then _checkMaxPriceImpact | |
525 | 525 | else false) | |
526 | 526 | then throw(((((((((((((("Price impact " + toString(priceImpact)) + " > max price impact ") + toString(maxPriceImpactValue)) + " before quote asset: ") + toString(_quoteAssetReserve)) + " before base asset: ") + toString(_baseAssetReserve)) + " base asset amount to exchange: ") + toString(_baseAssetAmount)) + " price before: ") + toString(priceBefore)) + " market price: ") + toString(marketPrice))) | |
527 | 527 | else $Tuple7(quoteAssetSold, quoteAssetReserveAfter1, baseAssetReserveAfter1, totalPositionSizeAfter1, (totalLongPositionSize() - (if (_isAdd) | |
528 | 528 | then abs(_baseAssetAmount) | |
529 | 529 | else 0)), (totalShortPositionSize() - (if (!(_isAdd)) | |
530 | 530 | then abs(_baseAssetAmount) | |
531 | 531 | else 0)), priceImpact) | |
532 | 532 | } | |
533 | 533 | } | |
534 | 534 | ||
535 | 535 | ||
536 | 536 | func swapOutput (_isAdd,_baseAssetAmount,_checkMaxPriceImpact) = swapOutputWithReserves(_isAdd, _baseAssetAmount, _checkMaxPriceImpact, qtAstR(), qtAstW(), bsAstR(), bsAstW()) | |
537 | 537 | ||
538 | 538 | ||
539 | 539 | func getOracleTwapPrice () = { | |
540 | 540 | let oracle = valueOrErrorMessage(addressFromString(getStringValue(this, k_ora)), "") | |
541 | 541 | let priceKey = getStringValue(this, k_ora_key) | |
542 | 542 | let lastValue = valueOrErrorMessage(getInteger(oracle, priceKey), ((("Can not get oracle price. Oracle: " + toString(oracle)) + " key: ") + priceKey)) | |
543 | 543 | let blockKey = valueOrElse(getString(this, k_ora_block_key), "") | |
544 | 544 | if ((blockKey != "")) | |
545 | 545 | then { | |
546 | 546 | let currentBlock = lastBlock.height | |
547 | 547 | let lastOracleBlock = valueOrErrorMessage(getInteger(oracle, blockKey), ((("Can not get oracle block. Oracle: " + toString(oracle)) + " key: ") + blockKey)) | |
548 | 548 | if (((currentBlock - lastOracleBlock) > maxOracleDelay())) | |
549 | 549 | then throw(((("Oracle stale data. Last oracle block: " + toString(lastOracleBlock)) + " current block: ") + toString(currentBlock))) | |
550 | 550 | else lastValue | |
551 | 551 | } | |
552 | 552 | else lastValue | |
553 | 553 | } | |
554 | 554 | ||
555 | 555 | ||
556 | 556 | func requireNotOverSpreadLimit (_quoteAssetReserve,_baseAssetReserve) = { | |
557 | 557 | let oraclePrice = getOracleTwapPrice() | |
558 | 558 | let _qtAstW = qtAstW() | |
559 | 559 | let _bsAstW = bsAstW() | |
560 | 560 | let priceAfter = divd(muld(_quoteAssetReserve, _qtAstW), muld(_baseAssetReserve, _bsAstW)) | |
561 | 561 | let averagePrice = divd((oraclePrice + priceAfter), (2 * DECIMAL_UNIT)) | |
562 | 562 | let absPriceDiff = divd(abs((oraclePrice - priceAfter)), averagePrice) | |
563 | 563 | if ((absPriceDiff > maxPriceSpread())) | |
564 | 564 | then throw(((("Price spread " + toString(absPriceDiff)) + " > max price spread ") + toString(maxPriceSpread()))) | |
565 | 565 | else true | |
566 | 566 | } | |
567 | 567 | ||
568 | 568 | ||
569 | 569 | func requireNotOverMaxOpenNotional (_longOpenNotional,_shortOpenNotional) = { | |
570 | 570 | let _maxOpenNotional = maxOpenNotional() | |
571 | 571 | if ((_longOpenNotional > _maxOpenNotional)) | |
572 | 572 | then throw(((("Long open notional " + toString(_longOpenNotional)) + " > max open notional ") + toString(_maxOpenNotional))) | |
573 | 573 | else if ((_shortOpenNotional > _maxOpenNotional)) | |
574 | 574 | then throw(((("Short open notional " + toString(_shortOpenNotional)) + " > max open notional ") + toString(_maxOpenNotional))) | |
575 | 575 | else true | |
576 | 576 | } | |
577 | 577 | ||
578 | 578 | ||
579 | 579 | func getSpotPrice () = { | |
580 | 580 | let _quoteAssetReserve = qtAstR() | |
581 | 581 | let _baseAssetReserve = bsAstR() | |
582 | 582 | let _qtAstW = qtAstW() | |
583 | 583 | let _bsAstW = bsAstW() | |
584 | 584 | divd(muld(_quoteAssetReserve, _qtAstW), muld(_baseAssetReserve, _bsAstW)) | |
585 | 585 | } | |
586 | 586 | ||
587 | 587 | ||
588 | 588 | func isOverFluctuationLimit () = { | |
589 | 589 | let oraclePrice = getOracleTwapPrice() | |
590 | 590 | let currentPrice = getSpotPrice() | |
591 | 591 | (divd(abs((oraclePrice - currentPrice)), oraclePrice) > spreadLimit()) | |
592 | 592 | } | |
593 | 593 | ||
594 | 594 | ||
595 | 595 | func getPositionAdjustedOpenNotional (_positionSize,_option,_quoteAssetReserve,_quoteAssetWeight,_baseAssetReserve,_baseAssetWeight) = { | |
596 | 596 | let positionSizeAbs = abs(_positionSize) | |
597 | 597 | let isShort = (0 > _positionSize) | |
598 | 598 | let positionNotional = if ((_option == PNL_OPTION_SPOT)) | |
599 | 599 | then { | |
600 | 600 | let $t02423124451 = swapOutputWithReserves(!(isShort), positionSizeAbs, false, _quoteAssetReserve, _quoteAssetWeight, _baseAssetReserve, _baseAssetWeight) | |
601 | 601 | let outPositionNotional = $t02423124451._1 | |
602 | 602 | let x1 = $t02423124451._2 | |
603 | 603 | let x2 = $t02423124451._3 | |
604 | 604 | let x3 = $t02423124451._4 | |
605 | 605 | outPositionNotional | |
606 | 606 | } | |
607 | 607 | else muld(positionSizeAbs, getOracleTwapPrice()) | |
608 | 608 | positionNotional | |
609 | 609 | } | |
610 | 610 | ||
611 | 611 | ||
612 | 612 | func getPositionNotionalAndUnrealizedPnlByValues (_positionSize,_positionOpenNotional,_quoteAssetReserve,_quoteAssetWeight,_baseAssetReserve,_baseAssetWeight,_option) = if ((_positionSize == 0)) | |
613 | 613 | then throw("Invalid position size") | |
614 | 614 | else { | |
615 | 615 | let isShort = (0 > _positionSize) | |
616 | 616 | let positionNotional = getPositionAdjustedOpenNotional(_positionSize, _option, _quoteAssetReserve, _quoteAssetWeight, _baseAssetReserve, _baseAssetWeight) | |
617 | 617 | let unrealizedPnl = if (isShort) | |
618 | 618 | then (_positionOpenNotional - positionNotional) | |
619 | 619 | else (positionNotional - _positionOpenNotional) | |
620 | 620 | $Tuple2(positionNotional, unrealizedPnl) | |
621 | 621 | } | |
622 | 622 | ||
623 | 623 | ||
624 | 624 | func getPositionNotionalAndUnrealizedPnl (_trader,_option) = { | |
625 | 625 | let $t02587626004 = getPosition(_trader) | |
626 | 626 | let positionSize = $t02587626004._1 | |
627 | 627 | let positionMargin = $t02587626004._2 | |
628 | 628 | let positionOpenNotional = $t02587626004._3 | |
629 | 629 | let positionLstUpdCPF = $t02587626004._4 | |
630 | 630 | getPositionNotionalAndUnrealizedPnlByValues(positionSize, positionOpenNotional, qtAstR(), qtAstW(), bsAstR(), bsAstW(), _option) | |
631 | 631 | } | |
632 | 632 | ||
633 | 633 | ||
634 | 634 | func calcMarginRatio (_remainMargin,_badDebt,_positionNotional) = divd((_remainMargin - _badDebt), _positionNotional) | |
635 | 635 | ||
636 | 636 | ||
637 | 637 | func getMarginRatioByOption (_trader,_option) = { | |
638 | 638 | let $t02651726628 = getPosition(_trader) | |
639 | 639 | let positionSize = $t02651726628._1 | |
640 | 640 | let positionMargin = $t02651726628._2 | |
641 | 641 | let pon = $t02651726628._3 | |
642 | 642 | let positionLstUpdCPF = $t02651726628._4 | |
643 | 643 | let $t02663426727 = getPositionNotionalAndUnrealizedPnl(_trader, _option) | |
644 | 644 | let positionNotional = $t02663426727._1 | |
645 | 645 | let unrealizedPnl = $t02663426727._2 | |
646 | 646 | let $t02673226898 = calcRemainMarginWithFundingPayment(positionSize, positionMargin, positionLstUpdCPF, unrealizedPnl) | |
647 | 647 | let remainMargin = $t02673226898._1 | |
648 | 648 | let badDebt = $t02673226898._2 | |
649 | 649 | calcMarginRatio(remainMargin, badDebt, positionNotional) | |
650 | 650 | } | |
651 | 651 | ||
652 | 652 | ||
653 | 653 | func getMarginRatio (_trader) = getMarginRatioByOption(_trader, PNL_OPTION_SPOT) | |
654 | 654 | ||
655 | 655 | ||
656 | 656 | func getPartialLiquidationAmount (_trader,_positionSize) = { | |
657 | 657 | let maximumRatio = vmax(partialLiquidationRatio(), (DECIMAL_UNIT - divd(getMarginRatio(_trader), maintenanceMarginRatio()))) | |
658 | 658 | let maxExchangedPositionSize = muld(abs(_positionSize), maximumRatio) | |
659 | 659 | let swapResult = swapOutput((_positionSize > 0), maxExchangedPositionSize, false) | |
660 | 660 | let maxExchangedQuoteAssetAmount = swapResult._1 | |
661 | 661 | let priceImpact = swapResult._7 | |
662 | 662 | if ((maxPriceImpact() > priceImpact)) | |
663 | 663 | then maxExchangedQuoteAssetAmount | |
664 | 664 | else { | |
665 | 665 | let exchangedPositionSize = muld(abs(_positionSize), partialLiquidationRatio()) | |
666 | 666 | let exchangedQuoteAssetAmount = swapOutput((_positionSize > 0), exchangedPositionSize, false)._1 | |
667 | 667 | exchangedQuoteAssetAmount | |
668 | 668 | } | |
669 | 669 | } | |
670 | 670 | ||
671 | 671 | ||
672 | 672 | func internalClosePosition (_trader,_checkMaxPriceImpact) = { | |
673 | 673 | let $t02813828266 = getPosition(_trader) | |
674 | 674 | let positionSize = $t02813828266._1 | |
675 | 675 | let positionMargin = $t02813828266._2 | |
676 | 676 | let positionOpenNotional = $t02813828266._3 | |
677 | 677 | let positionLstUpdCPF = $t02813828266._4 | |
678 | 678 | let unrealizedPnl = getPositionNotionalAndUnrealizedPnl(_trader, PNL_OPTION_SPOT)._2 | |
679 | 679 | let $t02836128529 = calcRemainMarginWithFundingPayment(positionSize, positionMargin, positionLstUpdCPF, unrealizedPnl) | |
680 | 680 | let remainMargin = $t02836128529._1 | |
681 | 681 | let badDebt = $t02836128529._2 | |
682 | 682 | let exchangedPositionSize = -(positionSize) | |
683 | 683 | let realizedPnl = unrealizedPnl | |
684 | 684 | let marginToVault = -(remainMargin) | |
685 | 685 | let $t02865628930 = swapOutput((positionSize > 0), abs(positionSize), _checkMaxPriceImpact) | |
686 | 686 | let exchangedQuoteAssetAmount = $t02865628930._1 | |
687 | 687 | let quoteAssetReserveAfter = $t02865628930._2 | |
688 | 688 | let baseAssetReserveAfter = $t02865628930._3 | |
689 | 689 | let totalPositionSizeAfter = $t02865628930._4 | |
690 | 690 | let totalLongAfter = $t02865628930._5 | |
691 | 691 | let totalShortAfter = $t02865628930._6 | |
692 | 692 | let openInterestNotionalAfter = (openInterestNotional() - positionOpenNotional) | |
693 | 693 | $Tuple13(exchangedPositionSize, badDebt, realizedPnl, marginToVault, quoteAssetReserveAfter, baseAssetReserveAfter, totalPositionSizeAfter, openInterestNotionalAfter, exchangedQuoteAssetAmount, totalLongAfter, totalShortAfter, (openInterestLong() - (if ((positionSize > 0)) | |
694 | 694 | then positionOpenNotional | |
695 | 695 | else 0)), (openInterestShort() - (if ((0 > positionSize)) | |
696 | 696 | then positionOpenNotional | |
697 | 697 | else 0))) | |
698 | 698 | } | |
699 | 699 | ||
700 | 700 | ||
701 | 701 | func getTwapSpotPrice () = { | |
702 | 702 | let minuteId = ((lastBlock.timestamp / 1000) / 60) | |
703 | 703 | let startMinuteId = (minuteId - TWAP_INTERVAL) | |
704 | 704 | let listStr = valueOrElse(getString(this, k_lastDataStr), "") | |
705 | 705 | let list = split(listStr, ",") | |
706 | 706 | func filterFn (accumulator,next) = if ((startMinuteId >= parseIntValue(next))) | |
707 | 707 | then (accumulator :+ parseIntValue(next)) | |
708 | 708 | else accumulator | |
709 | 709 | ||
710 | 710 | let listF = { | |
711 | 711 | let $l = list | |
712 | 712 | let $s = size($l) | |
713 | 713 | let $acc0 = nil | |
714 | 714 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
715 | 715 | then $a | |
716 | 716 | else filterFn($a, $l[$i]) | |
717 | 717 | ||
718 | 718 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
719 | 719 | then $a | |
720 | 720 | else throw("List size exceeds 20") | |
721 | 721 | ||
722 | 722 | $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) | |
723 | 723 | } | |
724 | 724 | let maxIndex = if ((size(listF) > 0)) | |
725 | 725 | then max(listF) | |
726 | 726 | else parseIntValue(list[0]) | |
727 | 727 | let lastMinuteId = valueOrElse(getInteger(this, k_lastMinuteId), 0) | |
728 | 728 | let endLastCumulativePrice = valueOrElse(getInteger(this, ((k_twapDataLastCumulativePrice + "_") + toString(lastMinuteId))), 0) | |
729 | 729 | let endLastPrice = valueOrElse(getInteger(this, ((k_twapDataLastPrice + "_") + toString(lastMinuteId))), 0) | |
730 | 730 | let nowCumulativePrice = (endLastCumulativePrice + ((minuteId - lastMinuteId) * endLastPrice)) | |
731 | 731 | let startLastCumulativePrice = valueOrElse(getInteger(this, ((k_twapDataLastCumulativePrice + "_") + toString(maxIndex))), 0) | |
732 | 732 | let startLastPrice = valueOrElse(getInteger(this, ((k_twapDataLastPrice + "_") + toString(maxIndex))), 0) | |
733 | 733 | let startCumulativePrice = (startLastCumulativePrice + ((startMinuteId - maxIndex) * startLastPrice)) | |
734 | 734 | ((nowCumulativePrice - startCumulativePrice) / TWAP_INTERVAL) | |
735 | 735 | } | |
736 | 736 | ||
737 | 737 | ||
738 | 738 | func getTerminalAmmState () = { | |
739 | 739 | let _positionSize = totalPositionSize() | |
740 | 740 | if ((_positionSize == 0)) | |
741 | 741 | then $Tuple2(qtAstR(), bsAstR()) | |
742 | 742 | else { | |
743 | 743 | let direction = (_positionSize > 0) | |
744 | 744 | let $t03105331232 = swapOutput(direction, abs(_positionSize), false) | |
745 | 745 | let currentNetMarketValue = $t03105331232._1 | |
746 | 746 | let terminalQuoteAssetReserve = $t03105331232._2 | |
747 | 747 | let terminalBaseAssetReserve = $t03105331232._3 | |
748 | 748 | $Tuple2(terminalQuoteAssetReserve, terminalBaseAssetReserve) | |
749 | 749 | } | |
750 | 750 | } | |
751 | 751 | ||
752 | 752 | ||
753 | 753 | func getQuoteAssetWeight (baseAssetReserve,totalPositionSize,quoteAssetReserve,targetPrice) = { | |
754 | 754 | let b = toBigInt(baseAssetReserve) | |
755 | 755 | let sz = toBigInt(totalPositionSize) | |
756 | 756 | let q = toBigInt(quoteAssetReserve) | |
757 | 757 | let p = toBigInt(targetPrice) | |
758 | 758 | let bs2 = bpowd((b + sz), toBigInt((2 * DECIMAL_UNIT))) | |
759 | 759 | let qbs2 = bmuld(q, bs2) | |
760 | 760 | let ps4 = (toBigInt(4) * bmuld(p, sz)) | |
761 | 761 | let sqr = bsqrtd(bmuld(qbs2, (q - ps4))) | |
762 | 762 | let bq = bmuld(b, q) | |
763 | 763 | let qs = bmuld(q, sz) | |
764 | 764 | let top = ((-(sqr) + bq) + qs) | |
765 | 765 | let bot = (toBigInt(2) * bmuld(q, sz)) | |
766 | 766 | let result = bdivd(top, bot) | |
767 | 767 | toInt(result) | |
768 | 768 | } | |
769 | 769 | ||
770 | 770 | ||
771 | 771 | func getSyncTerminalPrice (_terminalPrice) = { | |
772 | 772 | let _positionSize = totalPositionSize() | |
773 | 773 | if ((_positionSize == 0)) | |
774 | 774 | then { | |
775 | 775 | let _qtAstR = qtAstR() | |
776 | 776 | let _bsAstR = bsAstR() | |
777 | 777 | let newQtAstW = divd(muld(_terminalPrice, _bsAstR), _qtAstR) | |
778 | 778 | $Tuple3(newQtAstW, DECIMAL_UNIT, 0) | |
779 | 779 | } | |
780 | 780 | else { | |
781 | 781 | let direction = (_positionSize > 0) | |
782 | 782 | let currentNetMarketValue = swapOutput(direction, abs(_positionSize), false)._1 | |
783 | 783 | let _qtAstR = qtAstR() | |
784 | 784 | let _bsAstR = bsAstR() | |
785 | 785 | let newQtAstW = getQuoteAssetWeight(_bsAstR, _positionSize, _qtAstR, _terminalPrice) | |
786 | 786 | let newBsAstW = DECIMAL_UNIT | |
787 | 787 | let marginToVault = getPositionNotionalAndUnrealizedPnlByValues(_positionSize, currentNetMarketValue, _qtAstR, newQtAstW, _bsAstR, newBsAstW, PNL_OPTION_SPOT)._2 | |
788 | 788 | $Tuple3(newQtAstW, newBsAstW, marginToVault) | |
789 | 789 | } | |
790 | 790 | } | |
791 | 791 | ||
792 | 792 | ||
793 | 793 | func getFunding () = { | |
794 | 794 | let underlyingPrice = getOracleTwapPrice() | |
795 | 795 | let spotTwapPrice = getTwapSpotPrice() | |
796 | 796 | let premium = (spotTwapPrice - underlyingPrice) | |
797 | 797 | if (if ((totalShortPositionSize() == 0)) | |
798 | 798 | then true | |
799 | 799 | else (totalLongPositionSize() == 0)) | |
800 | 800 | then $Tuple2(0, 0) | |
801 | 801 | else if ((0 > premium)) | |
802 | 802 | then { | |
803 | 803 | let shortPremiumFraction = divd(muld(premium, fundingPeriodDecimal()), ONE_DAY) | |
804 | 804 | let longPremiumFraction = divd(muld(shortPremiumFraction, totalShortPositionSize()), totalLongPositionSize()) | |
805 | 805 | $Tuple2(shortPremiumFraction, longPremiumFraction) | |
806 | 806 | } | |
807 | 807 | else { | |
808 | 808 | let longPremiumFraction = divd(muld(premium, fundingPeriodDecimal()), ONE_DAY) | |
809 | 809 | let shortPremiumFraction = divd(muld(longPremiumFraction, totalLongPositionSize()), totalShortPositionSize()) | |
810 | 810 | $Tuple2(shortPremiumFraction, longPremiumFraction) | |
811 | 811 | } | |
812 | 812 | } | |
813 | 813 | ||
814 | 814 | ||
815 | 815 | func getAdjustedFee (_artifactId,_baseFeeDiscount) = { | |
816 | 816 | let baseFeeRaw = fee() | |
817 | 817 | let baseFee = muld(baseFeeRaw, _baseFeeDiscount) | |
818 | 818 | let $t03433134826 = if ((_artifactId != "")) | |
819 | 819 | then { | |
820 | 820 | let artifactKind = strA(nftManagerAddress(), toCompositeKey(k_token_type, _artifactId)) | |
821 | 821 | if ((artifactKind == FEE_REDUCTION_TOKEN_TYPE)) | |
822 | 822 | then { | |
823 | 823 | let reduction = intA(nftManagerAddress(), toCompositeKey(k_token_param, _artifactId)) | |
824 | 824 | let adjustedFee = muld(baseFee, reduction) | |
825 | 825 | $Tuple2(adjustedFee, true) | |
826 | 826 | } | |
827 | 827 | else throw("Invalid attached artifact") | |
828 | 828 | } | |
829 | 829 | else $Tuple2(baseFee, false) | |
830 | 830 | let adjustedFee = $t03433134826._1 | |
831 | 831 | let burnArtifact = $t03433134826._2 | |
832 | 832 | $Tuple2(adjustedFee, burnArtifact) | |
833 | 833 | } | |
834 | 834 | ||
835 | 835 | ||
836 | 836 | func isSameAssetOrNoPosition (_trader,_assetId) = { | |
837 | 837 | let oldPositionSize = getPosition(_trader)._1 | |
838 | 838 | if ((oldPositionSize == 0)) | |
839 | 839 | then true | |
840 | 840 | else (getPositionAsset(_trader) == _assetId) | |
841 | 841 | } | |
842 | 842 | ||
843 | 843 | ||
844 | 844 | func isSameAsset (_trader,_assetId) = (getPositionAsset(_trader) == _assetId) | |
845 | 845 | ||
846 | 846 | ||
847 | 847 | func getBorrowedByTraderInMarketKey (_amm,_assetId,_trader) = ((((((k_trader_market_asset_collateral + "_") + _amm) + "_") + _assetId) + "_") + _trader) | |
848 | 848 | ||
849 | 849 | ||
850 | 850 | func getBorrowedByTrader (_trader) = { | |
851 | 851 | let positionAsset = getPositionAsset(_trader) | |
852 | 852 | if ((positionAsset == toBase58String(quoteAsset()))) | |
853 | 853 | then $Tuple2(0, positionAsset) | |
854 | 854 | else { | |
855 | 855 | let key = getBorrowedByTraderInMarketKey(toString(this), positionAsset, _trader) | |
856 | 856 | let borrow = valueOrElse(getInteger(collateralAddress(), key), 0) | |
857 | 857 | $Tuple2(borrow, positionAsset) | |
858 | 858 | } | |
859 | 859 | } | |
860 | 860 | ||
861 | 861 | ||
862 | 862 | func getForTraderWithArtifact (_trader,_artifactId) = { | |
863 | 863 | let doGetFeeDiscount = invoke(minerAddress(), "computeFeeDiscount", [_trader], nil) | |
864 | 864 | if ((doGetFeeDiscount == doGetFeeDiscount)) | |
865 | 865 | then { | |
866 | 866 | let feeDiscount = match doGetFeeDiscount { | |
867 | 867 | case x: Int => | |
868 | 868 | x | |
869 | 869 | case _ => | |
870 | 870 | throw("Invalid computeFeeDiscount result") | |
871 | 871 | } | |
872 | 872 | let $t03605736131 = getAdjustedFee(_artifactId, feeDiscount) | |
873 | 873 | let adjustedFee = $t03605736131._1 | |
874 | 874 | let burnArtifact = $t03605736131._2 | |
875 | 875 | $Tuple2(adjustedFee, burnArtifact) | |
876 | 876 | } | |
877 | 877 | else throw("Strict value is not equal to itself.") | |
878 | 878 | } | |
879 | 879 | ||
880 | 880 | ||
881 | 881 | func getArtifactId (i) = { | |
882 | 882 | let artifactId = if ((size(i.payments) > 1)) | |
883 | 883 | then toBase58String(valueOrErrorMessage(i.payments[1].assetId, "Invalid artifactId")) | |
884 | 884 | else "" | |
885 | 885 | artifactId | |
886 | 886 | } | |
887 | 887 | ||
888 | 888 | ||
889 | 889 | func distributeFee (_feeAmount) = { | |
890 | 890 | let feeToStakers = muld(_feeAmount, feeToStakersPercent()) | |
891 | 891 | let feeToVault = (_feeAmount - feeToStakers) | |
892 | 892 | $Tuple2(feeToStakers, feeToVault) | |
893 | 893 | } | |
894 | 894 | ||
895 | 895 | ||
896 | 896 | func updateSettings (_initMarginRatio,_mmr,_liquidationFeeRatio,_fundingPeriod,_fee,_spreadLimit,_maxPriceImpact,_partialLiquidationRatio,_maxPriceSpread,_maxOpenNotional,_feeToStakersPercent,_maxOracleDelay) = [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), IntegerEntry(k_partialLiquidationRatio, _partialLiquidationRatio), IntegerEntry(k_maxPriceSpread, _maxPriceSpread), IntegerEntry(k_maxOpenNotional, _maxOpenNotional), IntegerEntry(k_feeToStakersPercent, _feeToStakersPercent), IntegerEntry(k_maxOracleDelay, _feeToStakersPercent)] | |
897 | 897 | ||
898 | 898 | ||
899 | 899 | 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)] | |
900 | 900 | ||
901 | 901 | ||
902 | 902 | func updatePositionAsset (_address,_assetId) = [StringEntry(toCompositeKey(k_positionAsset, _address), _assetId)] | |
903 | 903 | ||
904 | 904 | ||
905 | 905 | func incrementPositionSequenceNumber (isNewPosition,_address) = if (isNewPosition) | |
906 | 906 | then { | |
907 | 907 | let currentSequence = lastSequence() | |
908 | 908 | [IntegerEntry(toCompositeKey(k_positionSequence, _address), (currentSequence + 1)), IntegerEntry(k_sequence, (currentSequence + 1))] | |
909 | 909 | } | |
910 | 910 | else nil | |
911 | 911 | ||
912 | 912 | ||
913 | 913 | 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)] | |
914 | 914 | ||
915 | 915 | ||
916 | 916 | func appendTwap (_price) = { | |
917 | 917 | let minuteId = ((lastBlock.timestamp / 1000) / 60) | |
918 | 918 | let previousMinuteId = valueOrElse(getInteger(this, k_lastMinuteId), 0) | |
919 | 919 | if ((previousMinuteId > minuteId)) | |
920 | 920 | then throw("TWAP out-of-order") | |
921 | 921 | else { | |
922 | 922 | let lastMinuteId = if ((previousMinuteId == 0)) | |
923 | 923 | then minuteId | |
924 | 924 | else previousMinuteId | |
925 | 925 | if ((minuteId > previousMinuteId)) | |
926 | 926 | then { | |
927 | 927 | let prevCumulativePrice = valueOrElse(getInteger(this, ((k_twapDataLastCumulativePrice + "_") + toString(previousMinuteId))), 0) | |
928 | 928 | let prevPrice = valueOrElse(getInteger(this, ((k_twapDataLastPrice + "_") + toString(previousMinuteId))), _price) | |
929 | 929 | let lastCumulativePrice = (prevCumulativePrice + ((minuteId - lastMinuteId) * prevPrice)) | |
930 | 930 | let list = pushToQueue(strToList(valueOrElse(getString(this, k_lastDataStr), "")), TWAP_INTERVAL, toString(minuteId)) | |
931 | 931 | [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))] | |
932 | 932 | } | |
933 | 933 | else { | |
934 | 934 | let twapDataPreviousMinuteId = valueOrElse(getInteger(this, toCompositeKey(k_twapDataPreviousMinuteId, toString(minuteId))), 0) | |
935 | 935 | let prevCumulativePrice = valueOrElse(getInteger(this, toCompositeKey(k_twapDataLastCumulativePrice, toString(twapDataPreviousMinuteId))), 0) | |
936 | 936 | let prevPrice = valueOrElse(getInteger(this, toCompositeKey(k_twapDataLastPrice, toString(twapDataPreviousMinuteId))), _price) | |
937 | 937 | let lastCumulativePrice = (prevCumulativePrice + ((minuteId - twapDataPreviousMinuteId) * prevPrice)) | |
938 | 938 | [IntegerEntry(toCompositeKey(k_twapDataLastCumulativePrice, toString(minuteId)), lastCumulativePrice), IntegerEntry(toCompositeKey(k_twapDataLastPrice, toString(minuteId)), _price)] | |
939 | 939 | } | |
940 | 940 | } | |
941 | 941 | } | |
942 | 942 | ||
943 | 943 | ||
944 | 944 | func updateAmmReserves (_qtAstR,_bsAstR) = [IntegerEntry(k_quoteAssetReserve, _qtAstR), IntegerEntry(k_baseAssetReserve, _bsAstR)] | |
945 | 945 | ||
946 | 946 | ||
947 | 947 | func updateAmmWeights (_qtAstW,_bsAstW) = [IntegerEntry(k_quoteAssetWeight, _qtAstW), IntegerEntry(k_baseAssetWeight, _bsAstW)] | |
948 | 948 | ||
949 | 949 | ||
950 | 950 | func updateAmm (_qtAstR,_bsAstR,_totalPositionSizeAfter,_openInterestNotional,_totalLongPositionSize,_totalShortPositionSize,_totalLongOpenNotional,_totalShortOpenNotional) = { | |
951 | 951 | let _qtAstW = qtAstW() | |
952 | 952 | let _bsAstW = bsAstW() | |
953 | 953 | if (((_totalLongPositionSize - _totalShortPositionSize) != _totalPositionSizeAfter)) | |
954 | 954 | then throw(((((("Invalid AMM state data: " + toString(_totalLongPositionSize)) + " + ") + toString(_totalShortPositionSize)) + " != ") + toString(_totalPositionSizeAfter))) | |
955 | 955 | else ((updateAmmReserves(_qtAstR, _bsAstR) ++ [IntegerEntry(k_totalPositionSize, _totalPositionSizeAfter), IntegerEntry(k_openInterestNotional, _openInterestNotional), IntegerEntry(k_totalLongPositionSize, _totalLongPositionSize), IntegerEntry(k_totalShortPositionSize, _totalShortPositionSize), IntegerEntry(k_openInterestLong, _totalLongOpenNotional), IntegerEntry(k_openInterestShort, _totalShortOpenNotional)]) ++ appendTwap(divd(muld(_qtAstR, _qtAstW), muld(_bsAstR, _bsAstW)))) | |
956 | 956 | } | |
957 | 957 | ||
958 | 958 | ||
959 | 959 | func deletePosition (_address) = [DeleteEntry(toCompositeKey(k_positionSize, _address)), DeleteEntry(toCompositeKey(k_positionMargin, _address)), DeleteEntry(toCompositeKey(k_positionOpenNotional, _address)), DeleteEntry(toCompositeKey(k_positionLastUpdatedCumulativePremiumFraction, _address)), DeleteEntry(toCompositeKey(k_positionAsset, _address))] | |
960 | 960 | ||
961 | 961 | ||
962 | 962 | func withdraw (_address,_amount) = { | |
963 | 963 | let balance = assetBalance(this, quoteAsset()) | |
964 | 964 | if ((_amount > balance)) | |
965 | 965 | then throw(((("Unable to withdraw " + toString(_amount)) + " from contract balance ") + toString(balance))) | |
966 | 966 | else [ScriptTransfer(_address, _amount, quoteAsset())] | |
967 | 967 | } | |
968 | 968 | ||
969 | 969 | ||
970 | 970 | func updateBalance (i) = if ((0 > i)) | |
971 | 971 | then throw("Balance") | |
972 | 972 | else [IntegerEntry(k_balance, i)] | |
973 | 973 | ||
974 | 974 | ||
975 | 975 | func transferFee (i) = [ScriptTransfer(stakingAddress(), i, quoteAsset())] | |
976 | 976 | ||
977 | 977 | ||
978 | 978 | func doBurnArtifact (_burnArtifact,i) = if (_burnArtifact) | |
979 | 979 | then [Burn(valueOrErrorMessage(i.payments[1].assetId, "Invalid artifact"), 1)] | |
980 | 980 | else nil | |
981 | 981 | ||
982 | 982 | ||
983 | 983 | @Callable(i) | |
984 | 984 | func pause () = if ((i.caller != adminAddress())) | |
985 | 985 | then throw("Invalid pause params") | |
986 | 986 | else [BooleanEntry(k_paused, true)] | |
987 | 987 | ||
988 | 988 | ||
989 | 989 | ||
990 | 990 | @Callable(i) | |
991 | 991 | func unpause () = if ((i.caller != adminAddress())) | |
992 | 992 | then throw("Invalid unpause params") | |
993 | 993 | else [BooleanEntry(k_paused, false)] | |
994 | 994 | ||
995 | 995 | ||
996 | 996 | ||
997 | 997 | @Callable(i) | |
998 | 998 | func setCloseOnly () = if ((i.caller != adminAddress())) | |
999 | 999 | then throw("Invalid setCloseOnly params") | |
1000 | 1000 | else [BooleanEntry(k_closeOnly, true)] | |
1001 | 1001 | ||
1002 | 1002 | ||
1003 | 1003 | ||
1004 | 1004 | @Callable(i) | |
1005 | 1005 | func unsetCloseOnly () = if ((i.caller != adminAddress())) | |
1006 | 1006 | then throw("Invalid unsetCloseOnly params") | |
1007 | 1007 | else [BooleanEntry(k_closeOnly, false)] | |
1008 | 1008 | ||
1009 | 1009 | ||
1010 | 1010 | ||
1011 | 1011 | @Callable(i) | |
1012 | 1012 | func addLiquidity (_quoteAssetAmount) = if (if ((i.caller != adminAddress())) | |
1013 | 1013 | then true | |
1014 | 1014 | else (0 >= _quoteAssetAmount)) | |
1015 | 1015 | then throw("Invalid addLiquidity params") | |
1016 | 1016 | else { | |
1017 | 1017 | let _qtAstR = qtAstR() | |
1018 | 1018 | let _bsAstR = bsAstR() | |
1019 | 1019 | let _qtAstW = qtAstW() | |
1020 | 1020 | let _bsAstW = bsAstW() | |
1021 | 1021 | let price = divd(muld(_qtAstR, _qtAstW), muld(_bsAstR, _bsAstW)) | |
1022 | 1022 | let baseAssetAmountToAdd = divd(_quoteAssetAmount, price) | |
1023 | 1023 | let qtAstRAfter = (_qtAstR + _quoteAssetAmount) | |
1024 | 1024 | let bsAstRAfter = (_bsAstR + baseAssetAmountToAdd) | |
1025 | 1025 | updateAmmReserves(qtAstRAfter, bsAstRAfter) | |
1026 | 1026 | } | |
1027 | 1027 | ||
1028 | 1028 | ||
1029 | 1029 | ||
1030 | 1030 | @Callable(i) | |
1031 | 1031 | func removeLiquidity (_quoteAssetAmount) = if (if ((i.caller != adminAddress())) | |
1032 | 1032 | then true | |
1033 | 1033 | else (0 >= _quoteAssetAmount)) | |
1034 | 1034 | then throw("Invalid removeLiquidity params") | |
1035 | 1035 | else { | |
1036 | 1036 | let _qtAstR = qtAstR() | |
1037 | 1037 | let _bsAstR = bsAstR() | |
1038 | 1038 | let _qtAstW = qtAstW() | |
1039 | 1039 | let _bsAstW = bsAstW() | |
1040 | 1040 | let price = divd(muld(_qtAstR, _qtAstW), muld(_bsAstR, _bsAstW)) | |
1041 | 1041 | let baseAssetAmountToRemove = divd(_quoteAssetAmount, price) | |
1042 | 1042 | let qtAstRAfter = (_qtAstR - _quoteAssetAmount) | |
1043 | 1043 | let bsAstRAfter = (_bsAstR - baseAssetAmountToRemove) | |
1044 | 1044 | updateAmmReserves(qtAstRAfter, bsAstRAfter) | |
1045 | 1045 | } | |
1046 | 1046 | ||
1047 | 1047 | ||
1048 | 1048 | ||
1049 | 1049 | @Callable(i) | |
1050 | 1050 | func changeSettings (_initMarginRatio,_mmr,_liquidationFeeRatio,_fundingPeriod,_fee,_spreadLimit,_maxPriceImpact,_partialLiquidationRatio,_maxPriceSpread,_maxOpenNotional,_feeToStakersPercent,_maxOracleDelay) = if ((i.caller != adminAddress())) | |
1051 | 1051 | then throw("Invalid changeSettings params") | |
1052 | 1052 | else updateSettings(_initMarginRatio, _mmr, _liquidationFeeRatio, _fundingPeriod, _fee, _spreadLimit, _maxPriceImpact, _partialLiquidationRatio, _maxPriceSpread, _maxOpenNotional, _feeToStakersPercent, _maxOracleDelay) | |
1053 | 1053 | ||
1054 | 1054 | ||
1055 | 1055 | ||
1056 | 1056 | @Callable(i) | |
1057 | 1057 | func initialize (_qtAstR,_bsAstR,_fundingPeriod,_initMarginRatio,_mmr,_liquidationFeeRatio,_fee,_oracle,_oracleKey,_oracleBlockKey,_coordinator,_spreadLimit,_maxPriceImpact,_partialLiquidationRatio,_maxPriceSpread,_maxOpenNotional,_feeToStakersPercent,_maxOracleDelay) = if (if (if (if (if (if (if (if (if (if (if (if (if (if (if (if ((0 >= _qtAstR)) | |
1058 | 1058 | then true | |
1059 | 1059 | else (0 >= _bsAstR)) | |
1060 | 1060 | then true | |
1061 | 1061 | else (0 >= _fundingPeriod)) | |
1062 | 1062 | then true | |
1063 | 1063 | else (0 >= _initMarginRatio)) | |
1064 | 1064 | then true | |
1065 | 1065 | else (0 >= _mmr)) | |
1066 | 1066 | then true | |
1067 | 1067 | else (0 >= _liquidationFeeRatio)) | |
1068 | 1068 | then true | |
1069 | 1069 | else (0 >= _fee)) | |
1070 | 1070 | then true | |
1071 | 1071 | else (0 >= _spreadLimit)) | |
1072 | 1072 | then true | |
1073 | 1073 | else (0 >= _maxPriceImpact)) | |
1074 | 1074 | then true | |
1075 | 1075 | else (0 >= _partialLiquidationRatio)) | |
1076 | 1076 | then true | |
1077 | 1077 | else (0 >= _maxPriceSpread)) | |
1078 | 1078 | then true | |
1079 | 1079 | else (0 >= _maxOpenNotional)) | |
1080 | 1080 | then true | |
1081 | 1081 | else (0 >= _feeToStakersPercent)) | |
1082 | 1082 | then true | |
1083 | 1083 | else (_feeToStakersPercent > DECIMAL_UNIT)) | |
1084 | 1084 | then true | |
1085 | 1085 | else (0 >= _maxOracleDelay)) | |
1086 | 1086 | then true | |
1087 | 1087 | else initialized()) | |
1088 | 1088 | then throw("Invalid initialize parameters") | |
1089 | 1089 | else ((((updateAmm(_qtAstR, _bsAstR, 0, 0, 0, 0, 0, 0) ++ updateSettings(_initMarginRatio, _mmr, _liquidationFeeRatio, _fundingPeriod, _fee, _spreadLimit, _maxPriceImpact, _partialLiquidationRatio, _maxPriceSpread, _maxOpenNotional, _feeToStakersPercent, _maxOracleDelay)) ++ 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_ora_block_key, _oracleBlockKey), StringEntry(k_coordinatorAddress, _coordinator)]) | |
1090 | 1090 | ||
1091 | 1091 | ||
1092 | 1092 | ||
1093 | 1093 | @Callable(i) | |
1094 | 1094 | func decreasePosition (_amount,_leverage,_minBaseAssetAmount) = { | |
1095 | 1095 | let sync = invoke(this, "syncTerminalPriceToOracle", nil, nil) | |
1096 | 1096 | if ((sync == sync)) | |
1097 | 1097 | then { | |
1098 | 1098 | let _trader = getActualCaller(i) | |
1099 | 1099 | if (if (if (if (if ((0 >= _amount)) | |
1100 | 1100 | then true | |
1101 | 1101 | else !(initialized())) | |
1102 | 1102 | then true | |
1103 | 1103 | else !(requireMoreMarginRatio(divd(DECIMAL_UNIT, _leverage), initMarginRatio(), true))) | |
1104 | 1104 | then true | |
1105 | 1105 | else !(requireOpenPosition(_trader))) | |
1106 | 1106 | then true | |
1107 | 1107 | else paused()) | |
1108 | 1108 | then throw("Invalid decreasePosition parameters") | |
1109 | 1109 | else { | |
1110 | 1110 | let $t04867048810 = getPosition(_trader) | |
1111 | 1111 | let oldPositionSize = $t04867048810._1 | |
1112 | 1112 | let oldPositionMargin = $t04867048810._2 | |
1113 | 1113 | let oldPositionOpenNotional = $t04867048810._3 | |
1114 | 1114 | let oldPositionLstUpdCPF = $t04867048810._4 | |
1115 | 1115 | let _direction = if ((oldPositionSize > 0)) | |
1116 | 1116 | then DIR_SHORT | |
1117 | 1117 | else DIR_LONG | |
1118 | 1118 | let isAdd = (_direction == DIR_LONG) | |
1119 | 1119 | let openNotional = muld(_amount, _leverage) | |
1120 | 1120 | let $t04898349087 = getPositionNotionalAndUnrealizedPnl(_trader, PNL_OPTION_SPOT) | |
1121 | 1121 | let oldPositionNotional = $t04898349087._1 | |
1122 | 1122 | let unrealizedPnl = $t04898349087._2 | |
1123 | 1123 | let $t04909351751 = if ((oldPositionNotional > openNotional)) | |
1124 | 1124 | then { | |
1125 | 1125 | let $t04950849692 = swapInput(isAdd, openNotional) | |
1126 | 1126 | let exchangedPositionSize = $t04950849692._1 | |
1127 | 1127 | let quoteAssetReserveAfter = $t04950849692._2 | |
1128 | 1128 | let baseAssetReserveAfter = $t04950849692._3 | |
1129 | 1129 | let totalPositionSizeAfter = $t04950849692._4 | |
1130 | 1130 | let exchangedPositionSizeAbs = abs(exchangedPositionSize) | |
1131 | 1131 | if (if ((_minBaseAssetAmount != 0)) | |
1132 | 1132 | then (_minBaseAssetAmount > exchangedPositionSizeAbs) | |
1133 | 1133 | else false) | |
1134 | 1134 | then throw(((("Too little base asset exchanged, got " + toString(exchangedPositionSizeAbs)) + " expected ") + toString(_minBaseAssetAmount))) | |
1135 | 1135 | else { | |
1136 | 1136 | let realizedPnl = divd(muld(unrealizedPnl, exchangedPositionSizeAbs), abs(oldPositionSize)) | |
1137 | 1137 | let $t05012950374 = calcRemainMarginWithFundingPayment(oldPositionSize, oldPositionMargin, oldPositionLstUpdCPF, realizedPnl) | |
1138 | 1138 | let remainMargin = $t05012950374._1 | |
1139 | 1139 | let badDebt = $t05012950374._2 | |
1140 | 1140 | let fundingPayment = $t05012950374._3 | |
1141 | 1141 | let exchangedQuoteAssetAmount = openNotional | |
1142 | 1142 | let unrealizedPnlAfter = (unrealizedPnl - realizedPnl) | |
1143 | 1143 | let remainOpenNotional = if ((oldPositionSize > 0)) | |
1144 | 1144 | then ((oldPositionNotional - exchangedQuoteAssetAmount) - unrealizedPnlAfter) | |
1145 | 1145 | else ((unrealizedPnlAfter + oldPositionNotional) - exchangedQuoteAssetAmount) | |
1146 | 1146 | let newPositionSize = (oldPositionSize + exchangedPositionSize) | |
1147 | 1147 | $Tuple12(newPositionSize, remainMargin, abs(remainOpenNotional), latestCumulativePremiumFraction(newPositionSize), baseAssetReserveAfter, quoteAssetReserveAfter, totalPositionSizeAfter, (openInterestNotional() - openNotional), (totalLongPositionSize() - (if ((newPositionSize > 0)) | |
1148 | 1148 | then abs(exchangedPositionSize) | |
1149 | 1149 | else 0)), (totalShortPositionSize() - (if ((0 > newPositionSize)) | |
1150 | 1150 | then abs(exchangedPositionSize) | |
1151 | 1151 | else 0)), (openInterestLong() - (if ((newPositionSize > 0)) | |
1152 | 1152 | then openNotional | |
1153 | 1153 | else 0)), (openInterestShort() - (if ((0 > newPositionSize)) | |
1154 | 1154 | then openNotional | |
1155 | 1155 | else 0))) | |
1156 | 1156 | } | |
1157 | 1157 | } | |
1158 | 1158 | else throw("Close position first") | |
1159 | 1159 | let newPositionSize = $t04909351751._1 | |
1160 | 1160 | let newPositionRemainMargin = $t04909351751._2 | |
1161 | 1161 | let newPositionOpenNotional = $t04909351751._3 | |
1162 | 1162 | let newPositionLatestCPF = $t04909351751._4 | |
1163 | 1163 | let baseAssetReserveAfter = $t04909351751._5 | |
1164 | 1164 | let quoteAssetReserveAfter = $t04909351751._6 | |
1165 | 1165 | let totalPositionSizeAfter = $t04909351751._7 | |
1166 | 1166 | let openInterestNotionalAfter = $t04909351751._8 | |
1167 | 1167 | let totalLongAfter = $t04909351751._9 | |
1168 | 1168 | let totalShortAfter = $t04909351751._10 | |
1169 | 1169 | let totalLongOpenInterestAfter = $t04909351751._11 | |
1170 | 1170 | let totalShortOpenInterestAfter = $t04909351751._12 | |
1171 | 1171 | let notifyNotional = invoke(minerAddress(), "notifyNotional", [_trader, newPositionOpenNotional], nil) | |
1172 | 1172 | if ((notifyNotional == notifyNotional)) | |
1173 | 1173 | then (updatePosition(_trader, newPositionSize, newPositionRemainMargin, newPositionOpenNotional, newPositionLatestCPF) ++ updateAmm(quoteAssetReserveAfter, baseAssetReserveAfter, totalPositionSizeAfter, openInterestNotionalAfter, totalLongAfter, totalShortAfter, totalLongOpenInterestAfter, totalShortOpenInterestAfter)) | |
1174 | 1174 | else throw("Strict value is not equal to itself.") | |
1175 | 1175 | } | |
1176 | 1176 | } | |
1177 | 1177 | else throw("Strict value is not equal to itself.") | |
1178 | 1178 | } | |
1179 | 1179 | ||
1180 | 1180 | ||
1181 | 1181 | ||
1182 | 1182 | @Callable(i) | |
1183 | 1183 | func increasePosition (_direction,_leverage,_minBaseAssetAmount,_refLink) = { | |
1184 | 1184 | let sync = invoke(this, "syncTerminalPriceToOracle", nil, nil) | |
1185 | 1185 | if ((sync == sync)) | |
1186 | 1186 | then { | |
1187 | 1187 | let _trader = getActualCaller(i) | |
1188 | 1188 | let _rawAmount = i.payments[0].amount | |
1189 | 1189 | let _assetId = i.payments[0].assetId | |
1190 | 1190 | let _assetIdStr = toBase58String(value(_assetId)) | |
1191 | 1191 | let isQuoteAsset = (_assetId == quoteAsset()) | |
1192 | 1192 | let isCollateralAsset = isWhitelistAsset(_assetIdStr) | |
1193 | 1193 | if (if (if (if (if (if (if (if (if ((_direction != DIR_LONG)) | |
1194 | 1194 | then (_direction != DIR_SHORT) | |
1195 | 1195 | else false) | |
1196 | 1196 | then true | |
1197 | 1197 | else (0 >= _rawAmount)) | |
1198 | 1198 | then true | |
1199 | 1199 | else !(initialized())) | |
1200 | 1200 | then true | |
1201 | 1201 | else if (!(isQuoteAsset)) | |
1202 | 1202 | then !(isCollateralAsset) | |
1203 | 1203 | else false) | |
1204 | 1204 | then true | |
1205 | 1205 | else !(isSameAssetOrNoPosition(_trader, _assetIdStr))) | |
1206 | 1206 | then true | |
1207 | 1207 | else !(requireMoreMarginRatio(divd(DECIMAL_UNIT, _leverage), initMarginRatio(), true))) | |
1208 | 1208 | then true | |
1209 | 1209 | else paused()) | |
1210 | 1210 | then true | |
1211 | 1211 | else closeOnly()) | |
1212 | 1212 | then throw("Invalid increasePosition parameters") | |
1213 | 1213 | else { | |
1214 | 1214 | let $t05318953274 = getForTraderWithArtifact(_trader, getArtifactId(i)) | |
1215 | 1215 | let adjustedFee = $t05318953274._1 | |
1216 | 1216 | let burnArtifact = $t05318953274._2 | |
1217 | 1217 | let rawFeeAmount = muld(_rawAmount, adjustedFee) | |
1218 | 1218 | let _amount = (_rawAmount - rawFeeAmount) | |
1219 | 1219 | let distributeFeeAmount = if (isCollateralAsset) | |
1220 | 1220 | then { | |
1221 | 1221 | let doBorrow = invoke(collateralAddress(), "borrow", [_trader], [AttachedPayment(_assetId, _amount)]) | |
1222 | 1222 | if ((doBorrow == doBorrow)) | |
1223 | 1223 | then { | |
1224 | 1224 | let balanceBefore = assetBalance(this, quoteAsset()) | |
1225 | 1225 | if ((balanceBefore == balanceBefore)) | |
1226 | 1226 | then { | |
1227 | 1227 | let doSwap = invoke(swapAddress(), "swap", [toBase58String(quoteAsset()), 0], [AttachedPayment(_assetId, rawFeeAmount)]) | |
1228 | 1228 | if ((doSwap == doSwap)) | |
1229 | 1229 | then { | |
1230 | 1230 | let balanceAfter = assetBalance(this, quoteAsset()) | |
1231 | 1231 | if ((balanceAfter == balanceAfter)) | |
1232 | 1232 | then { | |
1233 | 1233 | let exchangedAmount = (balanceAfter - balanceBefore) | |
1234 | 1234 | if ((exchangedAmount == exchangedAmount)) | |
1235 | 1235 | then exchangedAmount | |
1236 | 1236 | else throw("Strict value is not equal to itself.") | |
1237 | 1237 | } | |
1238 | 1238 | else throw("Strict value is not equal to itself.") | |
1239 | 1239 | } | |
1240 | 1240 | else throw("Strict value is not equal to itself.") | |
1241 | 1241 | } | |
1242 | 1242 | else throw("Strict value is not equal to itself.") | |
1243 | 1243 | } | |
1244 | 1244 | else throw("Strict value is not equal to itself.") | |
1245 | 1245 | } | |
1246 | 1246 | else rawFeeAmount | |
1247 | 1247 | if ((distributeFeeAmount == distributeFeeAmount)) | |
1248 | 1248 | then { | |
1249 | 1249 | let referrerFeeAny = invoke(referralAddress(), "acceptPaymentWithLink", [_trader, _refLink], [AttachedPayment(quoteAsset(), distributeFeeAmount)]) | |
1250 | 1250 | if ((referrerFeeAny == referrerFeeAny)) | |
1251 | 1251 | then { | |
1252 | 1252 | let referrerFee = match referrerFeeAny { | |
1253 | 1253 | case x: Int => | |
1254 | 1254 | x | |
1255 | 1255 | case _ => | |
1256 | 1256 | throw("Invalid referrerFee") | |
1257 | 1257 | } | |
1258 | 1258 | let feeAmount = (distributeFeeAmount - referrerFee) | |
1259 | 1259 | let $t05459054730 = getPosition(_trader) | |
1260 | 1260 | let oldPositionSize = $t05459054730._1 | |
1261 | 1261 | let oldPositionMargin = $t05459054730._2 | |
1262 | 1262 | let oldPositionOpenNotional = $t05459054730._3 | |
1263 | 1263 | let oldPositionLstUpdCPF = $t05459054730._4 | |
1264 | 1264 | let isNewPosition = (oldPositionSize == 0) | |
1265 | 1265 | let isSameDirection = if ((oldPositionSize > 0)) | |
1266 | 1266 | then (_direction == DIR_LONG) | |
1267 | 1267 | else (_direction == DIR_SHORT) | |
1268 | 1268 | let expandExisting = if (!(isNewPosition)) | |
1269 | 1269 | then isSameDirection | |
1270 | 1270 | else false | |
1271 | 1271 | let isAdd = (_direction == DIR_LONG) | |
1272 | 1272 | let $t05501958060 = if (if (isNewPosition) | |
1273 | 1273 | then true | |
1274 | 1274 | else expandExisting) | |
1275 | 1275 | then { | |
1276 | 1276 | let openNotional = muld(_amount, _leverage) | |
1277 | 1277 | let $t05548155654 = swapInput(isAdd, openNotional) | |
1278 | 1278 | let amountBaseAssetBought = $t05548155654._1 | |
1279 | 1279 | let quoteAssetReserveAfter = $t05548155654._2 | |
1280 | 1280 | let baseAssetReserveAfter = $t05548155654._3 | |
1281 | 1281 | let totalPositionSizeAfter = $t05548155654._4 | |
1282 | 1282 | if (if ((_minBaseAssetAmount != 0)) | |
1283 | 1283 | then (_minBaseAssetAmount > abs(amountBaseAssetBought)) | |
1284 | 1284 | else false) | |
1285 | 1285 | then throw(((("Limit error: " + toString(abs(amountBaseAssetBought))) + " < ") + toString(_minBaseAssetAmount))) | |
1286 | 1286 | else { | |
1287 | 1287 | let newPositionSize = (oldPositionSize + amountBaseAssetBought) | |
1288 | 1288 | let totalLongOpenInterestAfter = (openInterestLong() + (if ((newPositionSize > 0)) | |
1289 | 1289 | then openNotional | |
1290 | 1290 | else 0)) | |
1291 | 1291 | let totalShortOpenInterestAfter = (openInterestShort() + (if ((0 > newPositionSize)) | |
1292 | 1292 | then openNotional | |
1293 | 1293 | else 0)) | |
1294 | 1294 | let increaseMarginRequirement = divd(openNotional, _leverage) | |
1295 | 1295 | let $t05626256501 = calcRemainMarginWithFundingPayment(oldPositionSize, oldPositionMargin, oldPositionLstUpdCPF, increaseMarginRequirement) | |
1296 | 1296 | let remainMargin = $t05626256501._1 | |
1297 | 1297 | let x1 = $t05626256501._2 | |
1298 | 1298 | let x2 = $t05626256501._3 | |
1299 | 1299 | if (!(requireNotOverSpreadLimit(quoteAssetReserveAfter, baseAssetReserveAfter))) | |
1300 | 1300 | then throw("Over max spread limit") | |
1301 | 1301 | else if (!(requireNotOverMaxOpenNotional(totalLongOpenInterestAfter, totalShortOpenInterestAfter))) | |
1302 | 1302 | then throw("Over max open notional") | |
1303 | 1303 | else $Tuple12(newPositionSize, remainMargin, (oldPositionOpenNotional + openNotional), latestCumulativePremiumFraction(newPositionSize), baseAssetReserveAfter, quoteAssetReserveAfter, totalPositionSizeAfter, (openInterestNotional() + openNotional), (totalLongPositionSize() + (if ((newPositionSize > 0)) | |
1304 | 1304 | then abs(amountBaseAssetBought) | |
1305 | 1305 | else 0)), (totalShortPositionSize() + (if ((0 > newPositionSize)) | |
1306 | 1306 | then abs(amountBaseAssetBought) | |
1307 | 1307 | else 0)), totalLongOpenInterestAfter, totalShortOpenInterestAfter) | |
1308 | 1308 | } | |
1309 | 1309 | } | |
1310 | 1310 | else { | |
1311 | 1311 | let openNotional = muld(_amount, _leverage) | |
1312 | 1312 | let $t05776057876 = getPositionNotionalAndUnrealizedPnl(toString(i.caller), PNL_OPTION_SPOT) | |
1313 | 1313 | let oldPositionNotional = $t05776057876._1 | |
1314 | 1314 | let unrealizedPnl = $t05776057876._2 | |
1315 | 1315 | if ((oldPositionNotional > openNotional)) | |
1316 | 1316 | then throw("Use decreasePosition to decrease position size") | |
1317 | 1317 | else throw("Close position first") | |
1318 | 1318 | } | |
1319 | 1319 | let newPositionSize = $t05501958060._1 | |
1320 | 1320 | let newPositionRemainMargin = $t05501958060._2 | |
1321 | 1321 | let newPositionOpenNotional = $t05501958060._3 | |
1322 | 1322 | let newPositionLatestCPF = $t05501958060._4 | |
1323 | 1323 | let baseAssetReserveAfter = $t05501958060._5 | |
1324 | 1324 | let quoteAssetReserveAfter = $t05501958060._6 | |
1325 | 1325 | let totalPositionSizeAfter = $t05501958060._7 | |
1326 | 1326 | let openInterestNotionalAfter = $t05501958060._8 | |
1327 | 1327 | let totalLongAfter = $t05501958060._9 | |
1328 | 1328 | let totalShortAfter = $t05501958060._10 | |
1329 | 1329 | let totalLongOpenInterestAfter = $t05501958060._11 | |
1330 | 1330 | let totalShortOpenInterestAfter = $t05501958060._12 | |
1331 | 1331 | let $t05806658123 = distributeFee(feeAmount) | |
1332 | 1332 | let feeToStakers = $t05806658123._1 | |
1333 | 1333 | let feeToVault = $t05806658123._2 | |
1334 | 1334 | let stake = if (isQuoteAsset) | |
1335 | 1335 | then { | |
1336 | 1336 | let stake = invoke(vaultAddress(), "addLocked", [false], [AttachedPayment(quoteAsset(), _amount)]) | |
1337 | 1337 | if ((stake == stake)) | |
1338 | 1338 | then nil | |
1339 | 1339 | else throw("Strict value is not equal to itself.") | |
1340 | 1340 | } | |
1341 | 1341 | else nil | |
1342 | 1342 | if ((stake == stake)) | |
1343 | 1343 | then { | |
1344 | 1344 | let depositInsurance = invoke(vaultAddress(), "addFree", nil, [AttachedPayment(quoteAsset(), feeToVault)]) | |
1345 | 1345 | if ((depositInsurance == depositInsurance)) | |
1346 | 1346 | then { | |
1347 | 1347 | let notifyFee = invoke(minerAddress(), "notifyFees", [_trader, feeAmount], nil) | |
1348 | 1348 | if ((notifyFee == notifyFee)) | |
1349 | 1349 | then { | |
1350 | 1350 | let notifyNotional = invoke(minerAddress(), "notifyNotional", [_trader, newPositionOpenNotional], nil) | |
1351 | 1351 | if ((notifyNotional == notifyNotional)) | |
1352 | 1352 | then ((((((updatePosition(_trader, newPositionSize, newPositionRemainMargin, newPositionOpenNotional, newPositionLatestCPF) ++ incrementPositionSequenceNumber(isNewPosition, _trader)) ++ updatePositionAsset(_trader, _assetIdStr)) ++ updateAmm(quoteAssetReserveAfter, baseAssetReserveAfter, totalPositionSizeAfter, openInterestNotionalAfter, totalLongAfter, totalShortAfter, totalLongOpenInterestAfter, totalShortOpenInterestAfter)) ++ transferFee(feeToStakers)) ++ updateBalance((cbalance() + _amount))) ++ doBurnArtifact(burnArtifact, i)) | |
1353 | 1353 | else throw("Strict value is not equal to itself.") | |
1354 | 1354 | } | |
1355 | 1355 | else throw("Strict value is not equal to itself.") | |
1356 | 1356 | } | |
1357 | 1357 | else throw("Strict value is not equal to itself.") | |
1358 | 1358 | } | |
1359 | 1359 | else throw("Strict value is not equal to itself.") | |
1360 | 1360 | } | |
1361 | 1361 | else throw("Strict value is not equal to itself.") | |
1362 | 1362 | } | |
1363 | 1363 | else throw("Strict value is not equal to itself.") | |
1364 | 1364 | } | |
1365 | 1365 | } | |
1366 | 1366 | else throw("Strict value is not equal to itself.") | |
1367 | 1367 | } | |
1368 | 1368 | ||
1369 | 1369 | ||
1370 | 1370 | ||
1371 | 1371 | @Callable(i) | |
1372 | 1372 | func addMargin () = { | |
1373 | 1373 | let sync = invoke(this, "syncTerminalPriceToOracle", nil, nil) | |
1374 | 1374 | if ((sync == sync)) | |
1375 | 1375 | then { | |
1376 | 1376 | let _trader = toString(i.caller) | |
1377 | 1377 | let _rawAmount = i.payments[0].amount | |
1378 | 1378 | let _assetId = i.payments[0].assetId | |
1379 | 1379 | let _assetIdStr = toBase58String(value(_assetId)) | |
1380 | 1380 | let isQuoteAsset = (_assetId == quoteAsset()) | |
1381 | 1381 | let isCollateralAsset = isWhitelistAsset(_assetIdStr) | |
1382 | 1382 | if (if (if (if (if (if (if (!(isQuoteAsset)) | |
1383 | 1383 | then !(isCollateralAsset) | |
1384 | 1384 | else false) | |
1385 | 1385 | then true | |
1386 | 1386 | else !(requireOpenPosition(toString(i.caller)))) | |
1387 | 1387 | then true | |
1388 | 1388 | else !(isSameAsset(_trader, _assetIdStr))) | |
1389 | 1389 | then true | |
1390 | 1390 | else !(initialized())) | |
1391 | 1391 | then true | |
1392 | 1392 | else paused()) | |
1393 | 1393 | then true | |
1394 | 1394 | else closeOnly()) | |
1395 | 1395 | then throw("Invalid addMargin parameters") | |
1396 | 1396 | else { | |
1397 | 1397 | let $t06007160156 = getForTraderWithArtifact(_trader, getArtifactId(i)) | |
1398 | 1398 | let adjustedFee = $t06007160156._1 | |
1399 | 1399 | let burnArtifact = $t06007160156._2 | |
1400 | 1400 | let rawFeeAmount = muld(_rawAmount, adjustedFee) | |
1401 | 1401 | let _amount = (_rawAmount - rawFeeAmount) | |
1402 | 1402 | let distributeFeeAmount = if (isCollateralAsset) | |
1403 | 1403 | then { | |
1404 | 1404 | let doBorrow = invoke(collateralAddress(), "borrow", [_trader], [AttachedPayment(_assetId, _amount)]) | |
1405 | 1405 | if ((doBorrow == doBorrow)) | |
1406 | 1406 | then { | |
1407 | 1407 | let balanceBefore = assetBalance(this, quoteAsset()) | |
1408 | 1408 | if ((balanceBefore == balanceBefore)) | |
1409 | 1409 | then { | |
1410 | 1410 | let doSwap = invoke(swapAddress(), "swap", [toBase58String(quoteAsset()), 0], [AttachedPayment(_assetId, rawFeeAmount)]) | |
1411 | 1411 | if ((doSwap == doSwap)) | |
1412 | 1412 | then { | |
1413 | 1413 | let balanceAfter = assetBalance(this, quoteAsset()) | |
1414 | 1414 | if ((balanceAfter == balanceAfter)) | |
1415 | 1415 | then { | |
1416 | 1416 | let exchangedAmount = (balanceAfter - balanceBefore) | |
1417 | 1417 | if ((exchangedAmount == exchangedAmount)) | |
1418 | 1418 | then exchangedAmount | |
1419 | 1419 | else throw("Strict value is not equal to itself.") | |
1420 | 1420 | } | |
1421 | 1421 | else throw("Strict value is not equal to itself.") | |
1422 | 1422 | } | |
1423 | 1423 | else throw("Strict value is not equal to itself.") | |
1424 | 1424 | } | |
1425 | 1425 | else throw("Strict value is not equal to itself.") | |
1426 | 1426 | } | |
1427 | 1427 | else throw("Strict value is not equal to itself.") | |
1428 | 1428 | } | |
1429 | 1429 | else rawFeeAmount | |
1430 | 1430 | if ((distributeFeeAmount == distributeFeeAmount)) | |
1431 | 1431 | then { | |
1432 | 1432 | let referrerFeeAny = invoke(referralAddress(), "acceptPayment", [_trader], [AttachedPayment(quoteAsset(), distributeFeeAmount)]) | |
1433 | 1433 | if ((referrerFeeAny == referrerFeeAny)) | |
1434 | 1434 | then { | |
1435 | 1435 | let referrerFee = match referrerFeeAny { | |
1436 | 1436 | case x: Int => | |
1437 | 1437 | x | |
1438 | 1438 | case _ => | |
1439 | 1439 | throw("Invalid referrerFee") | |
1440 | 1440 | } | |
1441 | 1441 | let feeAmount = (distributeFeeAmount - referrerFee) | |
1442 | 1442 | let $t06145561595 = getPosition(_trader) | |
1443 | 1443 | let oldPositionSize = $t06145561595._1 | |
1444 | 1444 | let oldPositionMargin = $t06145561595._2 | |
1445 | 1445 | let oldPositionOpenNotional = $t06145561595._3 | |
1446 | 1446 | let oldPositionLstUpdCPF = $t06145561595._4 | |
1447 | 1447 | let $t06160161658 = distributeFee(feeAmount) | |
1448 | 1448 | let feeToStakers = $t06160161658._1 | |
1449 | 1449 | let feeToVault = $t06160161658._2 | |
1450 | 1450 | let stake = if (isQuoteAsset) | |
1451 | 1451 | then { | |
1452 | 1452 | let stake = invoke(vaultAddress(), "addLocked", [false], [AttachedPayment(quoteAsset(), _amount)]) | |
1453 | 1453 | if ((stake == stake)) | |
1454 | 1454 | then nil | |
1455 | 1455 | else throw("Strict value is not equal to itself.") | |
1456 | 1456 | } | |
1457 | 1457 | else nil | |
1458 | 1458 | if ((stake == stake)) | |
1459 | 1459 | then { | |
1460 | 1460 | let depositInsurance = invoke(vaultAddress(), "addFree", nil, [AttachedPayment(quoteAsset(), feeToVault)]) | |
1461 | 1461 | if ((depositInsurance == depositInsurance)) | |
1462 | 1462 | then { | |
1463 | 1463 | let notifyFee = invoke(minerAddress(), "notifyFees", [_trader, feeAmount], nil) | |
1464 | 1464 | if ((notifyFee == notifyFee)) | |
1465 | 1465 | then (((updatePosition(_trader, oldPositionSize, (oldPositionMargin + _amount), oldPositionOpenNotional, oldPositionLstUpdCPF) ++ transferFee(feeToStakers)) ++ updateBalance((cbalance() + _amount))) ++ doBurnArtifact(burnArtifact, i)) | |
1466 | 1466 | else throw("Strict value is not equal to itself.") | |
1467 | 1467 | } | |
1468 | 1468 | else throw("Strict value is not equal to itself.") | |
1469 | 1469 | } | |
1470 | 1470 | else throw("Strict value is not equal to itself.") | |
1471 | 1471 | } | |
1472 | 1472 | else throw("Strict value is not equal to itself.") | |
1473 | 1473 | } | |
1474 | 1474 | else throw("Strict value is not equal to itself.") | |
1475 | 1475 | } | |
1476 | 1476 | } | |
1477 | 1477 | else throw("Strict value is not equal to itself.") | |
1478 | 1478 | } | |
1479 | 1479 | ||
1480 | 1480 | ||
1481 | 1481 | ||
1482 | 1482 | @Callable(i) | |
1483 | 1483 | func removeMargin (_amount) = { | |
1484 | 1484 | let sync = invoke(this, "syncTerminalPriceToOracle", nil, nil) | |
1485 | 1485 | if ((sync == sync)) | |
1486 | 1486 | then { | |
1487 | 1487 | let _trader = toString(i.caller) | |
1488 | 1488 | if (if (if (if ((0 >= _amount)) | |
1489 | 1489 | then true | |
1490 | 1490 | else !(requireOpenPosition(_trader))) | |
1491 | 1491 | then true | |
1492 | 1492 | else !(initialized())) | |
1493 | 1493 | then true | |
1494 | 1494 | else paused()) | |
1495 | 1495 | then throw("Invalid removeMargin parameters") | |
1496 | 1496 | else { | |
1497 | 1497 | let $t06277062910 = getPosition(_trader) | |
1498 | 1498 | let oldPositionSize = $t06277062910._1 | |
1499 | 1499 | let oldPositionMargin = $t06277062910._2 | |
1500 | 1500 | let oldPositionOpenNotional = $t06277062910._3 | |
1501 | 1501 | let oldPositionLstUpdCPF = $t06277062910._4 | |
1502 | 1502 | let marginDelta = -(_amount) | |
1503 | 1503 | let $t06294763126 = calcRemainMarginWithFundingPayment(oldPositionSize, oldPositionMargin, oldPositionLstUpdCPF, marginDelta) | |
1504 | 1504 | let remainMargin = $t06294763126._1 | |
1505 | 1505 | let badDebt = $t06294763126._2 | |
1506 | 1506 | if ((badDebt != 0)) | |
1507 | 1507 | then throw("Invalid removed margin amount") | |
1508 | 1508 | else { | |
1509 | 1509 | let marginRatio = calcMarginRatio(remainMargin, badDebt, oldPositionOpenNotional) | |
1510 | 1510 | if (!(requireMoreMarginRatio(marginRatio, initMarginRatio(), true))) | |
1511 | 1511 | then throw(((("Too much margin removed: " + toString(marginRatio)) + " < ") + toString(initMarginRatio()))) | |
1512 | 1512 | else { | |
1513 | 1513 | let quoteAssetStr = toBase58String(quoteAsset()) | |
1514 | 1514 | let $t06357063624 = getBorrowedByTrader(_trader) | |
1515 | 1515 | let borrowed = $t06357063624._1 | |
1516 | 1516 | let assetId = $t06357063624._2 | |
1517 | 1517 | let toRepay = if ((_amount > borrowed)) | |
1518 | 1518 | then borrowed | |
1519 | 1519 | else _amount | |
1520 | 1520 | let toWithdraw = if ((borrowed > _amount)) | |
1521 | 1521 | then 0 | |
1522 | 1522 | else (_amount - borrowed) | |
1523 | 1523 | let finalBorrow = (borrowed - toRepay) | |
1524 | 1524 | let switchPositionToQuote = if ((finalBorrow > 0)) | |
1525 | 1525 | then nil | |
1526 | 1526 | else updatePositionAsset(_trader, quoteAssetStr) | |
1527 | 1527 | let doSanityCheck = if (((toRepay + toWithdraw) != _amount)) | |
1528 | 1528 | then throw(((((("toRepay=" + toString(toRepay)) + " + toWithdraw=") + toString(toWithdraw)) + " != ") + toString(_amount))) | |
1529 | 1529 | else nil | |
1530 | 1530 | if ((doSanityCheck == doSanityCheck)) | |
1531 | 1531 | then { | |
1532 | 1532 | let doUnstake = if ((toWithdraw > 0)) | |
1533 | 1533 | then { | |
1534 | 1534 | let doUnstake = invoke(vaultAddress(), "withdrawLocked", [toWithdraw], nil) | |
1535 | 1535 | if ((doUnstake == doUnstake)) | |
1536 | 1536 | then nil | |
1537 | 1537 | else throw("Strict value is not equal to itself.") | |
1538 | 1538 | } | |
1539 | 1539 | else nil | |
1540 | 1540 | if ((doUnstake == doUnstake)) | |
1541 | 1541 | then { | |
1542 | 1542 | let returnCollateralAction = if ((toRepay > 0)) | |
1543 | 1543 | then { | |
1544 | 1544 | let doRepay = invoke(collateralAddress(), "repay", [_trader, toRepay, assetId], nil) | |
1545 | 1545 | if ((doRepay == doRepay)) | |
1546 | 1546 | then [ScriptTransfer(i.caller, toRepay, fromBase58String(assetId))] | |
1547 | 1547 | else throw("Strict value is not equal to itself.") | |
1548 | 1548 | } | |
1549 | 1549 | else nil | |
1550 | 1550 | if ((returnCollateralAction == returnCollateralAction)) | |
1551 | 1551 | then ((((updatePosition(_trader, oldPositionSize, remainMargin, oldPositionOpenNotional, latestCumulativePremiumFraction(oldPositionSize)) ++ (if ((toWithdraw > 0)) | |
1552 | 1552 | then withdraw(i.caller, toWithdraw) | |
1553 | 1553 | else nil)) ++ updateBalance((cbalance() - _amount))) ++ switchPositionToQuote) ++ returnCollateralAction) | |
1554 | 1554 | else throw("Strict value is not equal to itself.") | |
1555 | 1555 | } | |
1556 | 1556 | else throw("Strict value is not equal to itself.") | |
1557 | 1557 | } | |
1558 | 1558 | else throw("Strict value is not equal to itself.") | |
1559 | 1559 | } | |
1560 | 1560 | } | |
1561 | 1561 | } | |
1562 | 1562 | } | |
1563 | 1563 | else throw("Strict value is not equal to itself.") | |
1564 | 1564 | } | |
1565 | 1565 | ||
1566 | 1566 | ||
1567 | 1567 | ||
1568 | 1568 | @Callable(i) | |
1569 | 1569 | func closePosition (_size,_minQuoteAssetAmount) = { | |
1570 | 1570 | let sync = invoke(this, "syncTerminalPriceToOracle", nil, nil) | |
1571 | 1571 | if ((sync == sync)) | |
1572 | 1572 | then { | |
1573 | 1573 | let _trader = getActualCaller(i) | |
1574 | 1574 | let _traderAddress = valueOrErrorMessage(addressFromString(_trader), "Invalid caller") | |
1575 | 1575 | if (if (if (if (if (!(requireOpenPosition(_trader))) | |
1576 | 1576 | then true | |
1577 | 1577 | else !(initialized())) | |
1578 | 1578 | then true | |
1579 | 1579 | else paused()) | |
1580 | 1580 | then true | |
1581 | 1581 | else (0 >= _size)) | |
1582 | 1582 | then true | |
1583 | 1583 | else (0 > _minQuoteAssetAmount)) | |
1584 | 1584 | then throw("Invalid closePosition parameters") | |
1585 | 1585 | else { | |
1586 | 1586 | let $t06578265922 = getPosition(_trader) | |
1587 | 1587 | let oldPositionSize = $t06578265922._1 | |
1588 | 1588 | let oldPositionMargin = $t06578265922._2 | |
1589 | 1589 | let oldPositionOpenNotional = $t06578265922._3 | |
1590 | 1590 | let oldPositionLstUpdCPF = $t06578265922._4 | |
1591 | 1591 | let $t06592870365 = if ((abs(oldPositionSize) > _size)) | |
1592 | 1592 | then { | |
1593 | 1593 | let _direction = if ((oldPositionSize > 0)) | |
1594 | 1594 | then DIR_SHORT | |
1595 | 1595 | else DIR_LONG | |
1596 | 1596 | let isAdd = (_direction == DIR_LONG) | |
1597 | 1597 | let $t06651966741 = swapOutput((oldPositionSize > 0), _size, true) | |
1598 | 1598 | let exchangedQuoteAssetAmount = $t06651966741._1 | |
1599 | 1599 | let quoteAssetReserveAfter = $t06651966741._2 | |
1600 | 1600 | let baseAssetReserveAfter = $t06651966741._3 | |
1601 | 1601 | let totalPositionSizeAfter = $t06651966741._4 | |
1602 | 1602 | let exchangedPositionSize = if ((oldPositionSize > 0)) | |
1603 | 1603 | then -(_size) | |
1604 | 1604 | else _size | |
1605 | 1605 | let $t06683266986 = getPositionNotionalAndUnrealizedPnl(_trader, PNL_OPTION_SPOT) | |
1606 | 1606 | let oldPositionNotional = $t06683266986._1 | |
1607 | 1607 | let unrealizedPnl = $t06683266986._2 | |
1608 | 1608 | let mr = getMarginRatioByOption(_trader, PNL_OPTION_SPOT) | |
1609 | 1609 | let realizedRatio = divd(abs(exchangedPositionSize), abs(oldPositionSize)) | |
1610 | 1610 | let realizedPnl = muld(unrealizedPnl, realizedRatio) | |
1611 | 1611 | let $t06726567503 = calcRemainMarginWithFundingPayment(oldPositionSize, oldPositionMargin, oldPositionLstUpdCPF, realizedPnl) | |
1612 | 1612 | let remainMargin = $t06726567503._1 | |
1613 | 1613 | let positionBadDebt = $t06726567503._2 | |
1614 | 1614 | let fundingPayment = $t06726567503._3 | |
1615 | 1615 | let unrealizedPnlAfter = (unrealizedPnl - realizedPnl) | |
1616 | 1616 | let remainOpenNotional = if ((oldPositionSize > 0)) | |
1617 | 1617 | then ((oldPositionNotional - exchangedQuoteAssetAmount) - unrealizedPnlAfter) | |
1618 | 1618 | else ((unrealizedPnlAfter + oldPositionNotional) - exchangedQuoteAssetAmount) | |
1619 | 1619 | let newPositionOpenNotional = abs(remainOpenNotional) | |
1620 | 1620 | let newPositionMargin = muld(newPositionOpenNotional, mr) | |
1621 | 1621 | let newPositionSize = (oldPositionSize + exchangedPositionSize) | |
1622 | 1622 | let newPositionLstUpdCPF = latestCumulativePremiumFraction(newPositionSize) | |
1623 | 1623 | let openInterestNotionalAfter = (openInterestNotional() - exchangedQuoteAssetAmount) | |
1624 | 1624 | if (if ((_minQuoteAssetAmount != 0)) | |
1625 | 1625 | then (_minQuoteAssetAmount > exchangedQuoteAssetAmount) | |
1626 | 1626 | else false) | |
1627 | 1627 | then throw(((("Limit error: " + toString(exchangedQuoteAssetAmount)) + " < ") + toString(_minQuoteAssetAmount))) | |
1628 | 1628 | else $Tuple15(newPositionSize, newPositionMargin, newPositionOpenNotional, newPositionLstUpdCPF, positionBadDebt, realizedPnl, (abs((remainMargin - newPositionMargin)) + realizedPnl), quoteAssetReserveAfter, baseAssetReserveAfter, totalPositionSizeAfter, openInterestNotionalAfter, (totalLongPositionSize() - (if ((newPositionSize > 0)) | |
1629 | 1629 | then abs(exchangedPositionSize) | |
1630 | 1630 | else 0)), (totalShortPositionSize() - (if ((0 > newPositionSize)) | |
1631 | 1631 | then abs(exchangedPositionSize) | |
1632 | 1632 | else 0)), (openInterestLong() - (if ((newPositionSize > 0)) | |
1633 | 1633 | then exchangedQuoteAssetAmount | |
1634 | 1634 | else 0)), (openInterestShort() - (if ((0 > newPositionSize)) | |
1635 | 1635 | then exchangedQuoteAssetAmount | |
1636 | 1636 | else 0))) | |
1637 | 1637 | } | |
1638 | 1638 | else if ((_size > abs(oldPositionSize))) | |
1639 | 1639 | then throw("Invalid closePosition parameters") | |
1640 | 1640 | else { | |
1641 | 1641 | let $t06930669725 = internalClosePosition(_trader, true) | |
1642 | 1642 | let exchangedQuoteAssetAmount = $t06930669725._1 | |
1643 | 1643 | let positionBadDebt = $t06930669725._2 | |
1644 | 1644 | let realizedPnl = $t06930669725._3 | |
1645 | 1645 | let marginToVault = $t06930669725._4 | |
1646 | 1646 | let quoteAssetReserveAfter = $t06930669725._5 | |
1647 | 1647 | let baseAssetReserveAfter = $t06930669725._6 | |
1648 | 1648 | let totalPositionSizeAfter = $t06930669725._7 | |
1649 | 1649 | let openInterestNotionalAfter = $t06930669725._8 | |
1650 | 1650 | let x2 = $t06930669725._9 | |
1651 | 1651 | let totalLongAfter = $t06930669725._10 | |
1652 | 1652 | let totalShortAfter = $t06930669725._11 | |
1653 | 1653 | let totalLongOpenInterestAfter = $t06930669725._12 | |
1654 | 1654 | let totalShortOpenInterestAfter = $t06930669725._13 | |
1655 | 1655 | if (if ((_minQuoteAssetAmount != 0)) | |
1656 | 1656 | then (_minQuoteAssetAmount > exchangedQuoteAssetAmount) | |
1657 | 1657 | else false) | |
1658 | 1658 | then throw(((("Limit error: " + toString(exchangedQuoteAssetAmount)) + " < ") + toString(_minQuoteAssetAmount))) | |
1659 | 1659 | else $Tuple15(0, 0, 0, 0, positionBadDebt, realizedPnl, marginToVault, quoteAssetReserveAfter, baseAssetReserveAfter, totalPositionSizeAfter, openInterestNotionalAfter, totalLongAfter, totalShortAfter, totalLongOpenInterestAfter, totalShortOpenInterestAfter) | |
1660 | 1660 | } | |
1661 | 1661 | let newPositionSize = $t06592870365._1 | |
1662 | 1662 | let newPositionMargin = $t06592870365._2 | |
1663 | 1663 | let newPositionOpenNotional = $t06592870365._3 | |
1664 | 1664 | let newPositionLstUpdCPF = $t06592870365._4 | |
1665 | 1665 | let positionBadDebt = $t06592870365._5 | |
1666 | 1666 | let realizedPnl = $t06592870365._6 | |
1667 | 1667 | let marginToVault = $t06592870365._7 | |
1668 | 1668 | let quoteAssetReserveAfter = $t06592870365._8 | |
1669 | 1669 | let baseAssetReserveAfter = $t06592870365._9 | |
1670 | 1670 | let totalPositionSizeAfter = $t06592870365._10 | |
1671 | 1671 | let openInterestNotionalAfter = $t06592870365._11 | |
1672 | 1672 | let totalLongAfter = $t06592870365._12 | |
1673 | 1673 | let totalShortAfter = $t06592870365._13 | |
1674 | 1674 | let totalLongOpenInterestAfter = $t06592870365._14 | |
1675 | 1675 | let totalShortOpenInterestAfter = $t06592870365._15 | |
1676 | 1676 | if ((positionBadDebt > 0)) | |
1677 | 1677 | then throw("Unable to close position with bad debt") | |
1678 | 1678 | else { | |
1679 | 1679 | let withdrawAmount = abs(marginToVault) | |
1680 | 1680 | let ammBalance = (cbalance() - withdrawAmount) | |
1681 | 1681 | let $t07057470781 = if ((0 > ammBalance)) | |
1682 | 1682 | then $Tuple2(0, abs(ammBalance)) | |
1683 | 1683 | else $Tuple2(ammBalance, 0) | |
1684 | 1684 | let ammNewBalance = $t07057470781._1 | |
1685 | 1685 | let x11 = $t07057470781._2 | |
1686 | 1686 | let $t07078870842 = getBorrowedByTrader(_trader) | |
1687 | 1687 | let borrowed = $t07078870842._1 | |
1688 | 1688 | let assetId = $t07078870842._2 | |
1689 | 1689 | let $t07085771716 = if ((borrowed > 0)) | |
1690 | 1690 | then if ((withdrawAmount >= borrowed)) | |
1691 | 1691 | then { | |
1692 | 1692 | let doRepay = invoke(collateralAddress(), "repay", [_trader, borrowed, assetId], nil) | |
1693 | 1693 | if ((doRepay == doRepay)) | |
1694 | 1694 | then $Tuple2([ScriptTransfer(_traderAddress, borrowed, fromBase58String(assetId))], (withdrawAmount - borrowed)) | |
1695 | 1695 | else throw("Strict value is not equal to itself.") | |
1696 | 1696 | } | |
1697 | 1697 | else { | |
1698 | 1698 | let realizeAndClose = invoke(collateralAddress(), "realizePartiallyAndClose", [_trader, withdrawAmount, assetId], nil) | |
1699 | 1699 | if ((realizeAndClose == realizeAndClose)) | |
1700 | 1700 | then $Tuple2([ScriptTransfer(_traderAddress, withdrawAmount, fromBase58String(assetId))], 0) | |
1701 | 1701 | else throw("Strict value is not equal to itself.") | |
1702 | 1702 | } | |
1703 | 1703 | else $Tuple2(nil, withdrawAmount) | |
1704 | 1704 | if (($t07085771716 == $t07085771716)) | |
1705 | 1705 | then { | |
1706 | 1706 | let quoteWithdrawAmount = $t07085771716._2 | |
1707 | 1707 | let sendCollateralAction = $t07085771716._1 | |
1708 | 1708 | let unstake = if ((quoteWithdrawAmount > 0)) | |
1709 | 1709 | then { | |
1710 | 1710 | let unstake = invoke(vaultAddress(), "withdrawLocked", [quoteWithdrawAmount], nil) | |
1711 | 1711 | if ((unstake == unstake)) | |
1712 | 1712 | then nil | |
1713 | 1713 | else throw("Strict value is not equal to itself.") | |
1714 | 1714 | } | |
1715 | 1715 | else nil | |
1716 | 1716 | if ((unstake == unstake)) | |
1717 | 1717 | then { | |
1718 | 1718 | let notifyNotional = invoke(minerAddress(), "notifyNotional", [_trader, 0], nil) | |
1719 | 1719 | if ((notifyNotional == notifyNotional)) | |
1720 | 1720 | then (((((if ((newPositionSize == 0)) | |
1721 | 1721 | then deletePosition(_trader) | |
1722 | 1722 | else updatePosition(_trader, newPositionSize, newPositionMargin, newPositionOpenNotional, newPositionLstUpdCPF)) ++ updateAmm(quoteAssetReserveAfter, baseAssetReserveAfter, totalPositionSizeAfter, openInterestNotionalAfter, totalLongAfter, totalShortAfter, totalLongOpenInterestAfter, totalShortOpenInterestAfter)) ++ (if ((quoteWithdrawAmount > 0)) | |
1723 | 1723 | then withdraw(_traderAddress, quoteWithdrawAmount) | |
1724 | 1724 | else nil)) ++ updateBalance(ammNewBalance)) ++ sendCollateralAction) | |
1725 | 1725 | else throw("Strict value is not equal to itself.") | |
1726 | 1726 | } | |
1727 | 1727 | else throw("Strict value is not equal to itself.") | |
1728 | 1728 | } | |
1729 | 1729 | else throw("Strict value is not equal to itself.") | |
1730 | 1730 | } | |
1731 | 1731 | } | |
1732 | 1732 | } | |
1733 | 1733 | else throw("Strict value is not equal to itself.") | |
1734 | 1734 | } | |
1735 | 1735 | ||
1736 | 1736 | ||
1737 | 1737 | ||
1738 | 1738 | @Callable(i) | |
1739 | 1739 | func liquidate (_trader) = { | |
1740 | 1740 | let sync = invoke(this, "syncTerminalPriceToOracle", nil, nil) | |
1741 | 1741 | if ((sync == sync)) | |
1742 | 1742 | then { | |
1743 | 1743 | let spotMarginRatio = getMarginRatioByOption(_trader, PNL_OPTION_SPOT) | |
1744 | 1744 | let marginRatio = if (isOverFluctuationLimit()) | |
1745 | 1745 | then { | |
1746 | 1746 | let oracleMarginRatio = getMarginRatioByOption(_trader, PNL_OPTION_ORACLE) | |
1747 | 1747 | vmax(spotMarginRatio, oracleMarginRatio) | |
1748 | 1748 | } | |
1749 | 1749 | else spotMarginRatio | |
1750 | 1750 | if (if (if (if (!(requireMoreMarginRatio(marginRatio, maintenanceMarginRatio(), false))) | |
1751 | 1751 | then true | |
1752 | 1752 | else !(requireOpenPosition(_trader))) | |
1753 | 1753 | then true | |
1754 | 1754 | else !(initialized())) | |
1755 | 1755 | then true | |
1756 | 1756 | else paused()) | |
1757 | 1757 | then throw("Unable to liquidate") | |
1758 | 1758 | else if (if (if ((spotMarginRatio > liquidationFeeRatio())) | |
1759 | 1759 | then (partialLiquidationRatio() > 0) | |
1760 | 1760 | else false) | |
1761 | 1761 | then (DECIMAL_UNIT > partialLiquidationRatio()) | |
1762 | 1762 | else false) | |
1763 | 1763 | then { | |
1764 | 1764 | let $t07401374163 = getPosition(_trader) | |
1765 | 1765 | let oldPositionSize = $t07401374163._1 | |
1766 | 1766 | let oldPositionMargin = $t07401374163._2 | |
1767 | 1767 | let oldPositionOpenNotional = $t07401374163._3 | |
1768 | 1768 | let oldPositionLstUpdCPF = $t07401374163._4 | |
1769 | 1769 | let _direction = if ((oldPositionSize > 0)) | |
1770 | 1770 | then DIR_SHORT | |
1771 | 1771 | else DIR_LONG | |
1772 | 1772 | let isAdd = (_direction == DIR_LONG) | |
1773 | 1773 | let exchangedQuoteAssetAmount = getPartialLiquidationAmount(_trader, oldPositionSize) | |
1774 | 1774 | let $t07438874492 = getPositionNotionalAndUnrealizedPnl(_trader, PNL_OPTION_SPOT) | |
1775 | 1775 | let oldPositionNotional = $t07438874492._1 | |
1776 | 1776 | let unrealizedPnl = $t07438874492._2 | |
1777 | 1777 | let $t07450074687 = swapInput(isAdd, exchangedQuoteAssetAmount) | |
1778 | 1778 | let exchangedPositionSize = $t07450074687._1 | |
1779 | 1779 | let quoteAssetReserveAfter = $t07450074687._2 | |
1780 | 1780 | let baseAssetReserveAfter = $t07450074687._3 | |
1781 | 1781 | let totalPositionSizeAfter = $t07450074687._4 | |
1782 | 1782 | let liquidationRatio = divd(abs(exchangedPositionSize), abs(oldPositionSize)) | |
1783 | 1783 | let realizedPnl = muld(unrealizedPnl, liquidationRatio) | |
1784 | 1784 | let $t07497675209 = calcRemainMarginWithFundingPayment(oldPositionSize, oldPositionMargin, oldPositionLstUpdCPF, realizedPnl) | |
1785 | 1785 | let remainMargin = $t07497675209._1 | |
1786 | 1786 | let badDebt = $t07497675209._2 | |
1787 | 1787 | let fundingPayment = $t07497675209._3 | |
1788 | 1788 | let unrealizedPnlAfter = (unrealizedPnl - realizedPnl) | |
1789 | 1789 | let remainOpenNotional = if ((oldPositionSize > 0)) | |
1790 | 1790 | then ((oldPositionNotional - exchangedQuoteAssetAmount) - unrealizedPnlAfter) | |
1791 | 1791 | else ((unrealizedPnlAfter + oldPositionNotional) - exchangedQuoteAssetAmount) | |
1792 | 1792 | let liquidationPenalty = muld(exchangedQuoteAssetAmount, liquidationFeeRatio()) | |
1793 | 1793 | let feeToLiquidator = (liquidationPenalty / 2) | |
1794 | 1794 | let feeToVault = (liquidationPenalty - feeToLiquidator) | |
1795 | 1795 | let newPositionMargin = (remainMargin - liquidationPenalty) | |
1796 | 1796 | let newPositionSize = (oldPositionSize + exchangedPositionSize) | |
1797 | 1797 | let newPositionOpenNotional = abs(remainOpenNotional) | |
1798 | 1798 | let newPositionLstUpdCPF = latestCumulativePremiumFraction(newPositionSize) | |
1799 | 1799 | let openInterestNotionalAfter = (openInterestNotional() - exchangedQuoteAssetAmount) | |
1800 | 1800 | let ammBalance = (cbalance() - liquidationPenalty) | |
1801 | 1801 | let $t07637876507 = if ((0 > ammBalance)) | |
1802 | 1802 | then $Tuple2(0, abs(ammBalance)) | |
1803 | 1803 | else $Tuple2(ammBalance, 0) | |
1804 | 1804 | let newAmmBalance = $t07637876507._1 | |
1805 | 1805 | let x11 = $t07637876507._2 | |
1806 | 1806 | let $t07651576569 = getBorrowedByTrader(_trader) | |
1807 | 1807 | let borrowed = $t07651576569._1 | |
1808 | 1808 | let assetId = $t07651576569._2 | |
1809 | 1809 | let doLiquidateCollateral = if ((borrowed > 0)) | |
1810 | 1810 | then { | |
1811 | 1811 | let collateralToSell = muld(borrowed, liquidationRatio) | |
1812 | 1812 | let realizeAndClose = invoke(collateralAddress(), "realizePartially", [_trader, assetId, collateralToSell], nil) | |
1813 | 1813 | if ((realizeAndClose == realizeAndClose)) | |
1814 | 1814 | then nil | |
1815 | 1815 | else throw("Strict value is not equal to itself.") | |
1816 | 1816 | } | |
1817 | 1817 | else nil | |
1818 | 1818 | if ((doLiquidateCollateral == doLiquidateCollateral)) | |
1819 | 1819 | then { | |
1820 | 1820 | let unstake = invoke(vaultAddress(), "withdrawLocked", [liquidationPenalty], nil) | |
1821 | 1821 | if ((unstake == unstake)) | |
1822 | 1822 | then { | |
1823 | 1823 | let depositInsurance = invoke(vaultAddress(), "addFree", nil, [AttachedPayment(quoteAsset(), feeToVault)]) | |
1824 | 1824 | if ((depositInsurance == depositInsurance)) | |
1825 | 1825 | then { | |
1826 | 1826 | let notifyNotional = invoke(minerAddress(), "notifyNotional", [_trader, newPositionOpenNotional], nil) | |
1827 | 1827 | if ((notifyNotional == notifyNotional)) | |
1828 | 1828 | then (((updatePosition(_trader, newPositionSize, newPositionMargin, newPositionOpenNotional, newPositionLstUpdCPF) ++ updateAmm(quoteAssetReserveAfter, baseAssetReserveAfter, totalPositionSizeAfter, openInterestNotionalAfter, (totalLongPositionSize() - (if ((newPositionSize > 0)) | |
1829 | 1829 | then abs(exchangedPositionSize) | |
1830 | 1830 | else 0)), (totalShortPositionSize() - (if ((0 > newPositionSize)) | |
1831 | 1831 | then abs(exchangedPositionSize) | |
1832 | 1832 | else 0)), (openInterestLong() - (if ((newPositionSize > 0)) | |
1833 | 1833 | then exchangedQuoteAssetAmount | |
1834 | 1834 | else 0)), (openInterestShort() - (if ((0 > newPositionSize)) | |
1835 | 1835 | then exchangedQuoteAssetAmount | |
1836 | 1836 | else 0)))) ++ withdraw(i.caller, feeToLiquidator)) ++ updateBalance(newAmmBalance)) | |
1837 | 1837 | else throw("Strict value is not equal to itself.") | |
1838 | 1838 | } | |
1839 | 1839 | else throw("Strict value is not equal to itself.") | |
1840 | 1840 | } | |
1841 | 1841 | else throw("Strict value is not equal to itself.") | |
1842 | 1842 | } | |
1843 | 1843 | else throw("Strict value is not equal to itself.") | |
1844 | 1844 | } | |
1845 | 1845 | else { | |
1846 | 1846 | let $t07826478759 = internalClosePosition(_trader, false) | |
1847 | 1847 | let x1 = $t07826478759._1 | |
1848 | 1848 | let badDebt = $t07826478759._2 | |
1849 | 1849 | let x2 = $t07826478759._3 | |
1850 | 1850 | let x3 = $t07826478759._4 | |
1851 | 1851 | let quoteAssetReserveAfter = $t07826478759._5 | |
1852 | 1852 | let baseAssetReserveAfter = $t07826478759._6 | |
1853 | 1853 | let totalPositionSizeAfter = $t07826478759._7 | |
1854 | 1854 | let openInterestNotionalAfter = $t07826478759._8 | |
1855 | 1855 | let exchangedQuoteAssetAmount = $t07826478759._9 | |
1856 | 1856 | let totalLongAfter = $t07826478759._10 | |
1857 | 1857 | let totalShortAfter = $t07826478759._11 | |
1858 | 1858 | let totalLongOpenInterestAfter = $t07826478759._12 | |
1859 | 1859 | let totalShortOpenInterestAfter = $t07826478759._13 | |
1860 | 1860 | let liquidationPenalty = muld(exchangedQuoteAssetAmount, liquidationFeeRatio()) | |
1861 | 1861 | let feeToLiquidator = (liquidationPenalty / 2) | |
1862 | 1862 | let feeToVault = (liquidationPenalty - feeToLiquidator) | |
1863 | 1863 | let ammBalance = (cbalance() - liquidationPenalty) | |
1864 | 1864 | let $t07916779296 = if ((0 > ammBalance)) | |
1865 | 1865 | then $Tuple2(0, abs(ammBalance)) | |
1866 | 1866 | else $Tuple2(ammBalance, 0) | |
1867 | 1867 | let newAmmBalance = $t07916779296._1 | |
1868 | 1868 | let x11 = $t07916779296._2 | |
1869 | 1869 | let $t07930479358 = getBorrowedByTrader(_trader) | |
1870 | 1870 | let borrowed = $t07930479358._1 | |
1871 | 1871 | let assetId = $t07930479358._2 | |
1872 | 1872 | let doLiquidateCollateral = if ((borrowed > 0)) | |
1873 | 1873 | then { | |
1874 | 1874 | let realizeAndClose = invoke(collateralAddress(), "realizePartiallyAndClose", [_trader, 0, assetId], nil) | |
1875 | 1875 | if ((realizeAndClose == realizeAndClose)) | |
1876 | 1876 | then nil | |
1877 | 1877 | else throw("Strict value is not equal to itself.") | |
1878 | 1878 | } | |
1879 | 1879 | else nil | |
1880 | 1880 | if ((doLiquidateCollateral == doLiquidateCollateral)) | |
1881 | 1881 | then { | |
1882 | 1882 | let x = if ((badDebt > 0)) | |
1883 | 1883 | then { | |
1884 | 1884 | let lockBadDebt = invoke(vaultAddress(), "exchangeFreeAndLocked", [badDebt], nil) | |
1885 | 1885 | if ((lockBadDebt == lockBadDebt)) | |
1886 | 1886 | then nil | |
1887 | 1887 | else throw("Strict value is not equal to itself.") | |
1888 | 1888 | } | |
1889 | 1889 | else nil | |
1890 | 1890 | if ((x == x)) | |
1891 | 1891 | then { | |
1892 | 1892 | let unstake = invoke(vaultAddress(), "withdrawLocked", [liquidationPenalty], nil) | |
1893 | 1893 | if ((unstake == unstake)) | |
1894 | 1894 | then { | |
1895 | 1895 | let depositInsurance = invoke(vaultAddress(), "addFree", nil, [AttachedPayment(quoteAsset(), feeToVault)]) | |
1896 | 1896 | if ((depositInsurance == depositInsurance)) | |
1897 | 1897 | then { | |
1898 | 1898 | let notifyNotional = invoke(minerAddress(), "notifyNotional", [_trader, 0], nil) | |
1899 | 1899 | if ((notifyNotional == notifyNotional)) | |
1900 | 1900 | then (((deletePosition(_trader) ++ updateAmm(quoteAssetReserveAfter, baseAssetReserveAfter, totalPositionSizeAfter, openInterestNotionalAfter, totalLongAfter, totalShortAfter, totalLongOpenInterestAfter, totalShortOpenInterestAfter)) ++ withdraw(i.caller, feeToLiquidator)) ++ updateBalance(newAmmBalance)) | |
1901 | 1901 | else throw("Strict value is not equal to itself.") | |
1902 | 1902 | } | |
1903 | 1903 | else throw("Strict value is not equal to itself.") | |
1904 | 1904 | } | |
1905 | 1905 | else throw("Strict value is not equal to itself.") | |
1906 | 1906 | } | |
1907 | 1907 | else throw("Strict value is not equal to itself.") | |
1908 | 1908 | } | |
1909 | 1909 | else throw("Strict value is not equal to itself.") | |
1910 | 1910 | } | |
1911 | 1911 | } | |
1912 | 1912 | else throw("Strict value is not equal to itself.") | |
1913 | 1913 | } | |
1914 | 1914 | ||
1915 | 1915 | ||
1916 | 1916 | ||
1917 | 1917 | @Callable(i) | |
1918 | 1918 | func payFunding () = { | |
1919 | - | let fundingBlockTimestamp = nextFundingBlockTimestamp() | |
1920 | - | if (if (if ((fundingBlockTimestamp > lastBlock.timestamp)) | |
1921 | - | then true | |
1922 | - | else !(initialized())) | |
1923 | - | then true | |
1924 | - | else paused()) | |
1925 | - | then throw(((("Invalid funding block timestamp: " + toString(lastBlock.timestamp)) + " < ") + toString(fundingBlockTimestamp))) | |
1926 | - | else { | |
1927 | - | let underlyingPrice = getOracleTwapPrice() | |
1928 | - | let $t08116581227 = getFunding() | |
1929 | - | let shortPremiumFraction = $t08116581227._1 | |
1930 | - | let longPremiumFraction = $t08116581227._2 | |
1931 | - | updateFunding((fundingBlockTimestamp + fundingPeriodSeconds()), (latestLongCumulativePremiumFraction() + longPremiumFraction), (latestShortCumulativePremiumFraction() + shortPremiumFraction), divd(longPremiumFraction, underlyingPrice), divd(shortPremiumFraction, underlyingPrice)) | |
1932 | - | } | |
1919 | + | let sync = invoke(this, "syncTerminalPriceToOracle", nil, nil) | |
1920 | + | if ((sync == sync)) | |
1921 | + | then { | |
1922 | + | let fundingBlockTimestamp = nextFundingBlockTimestamp() | |
1923 | + | if (if (if ((fundingBlockTimestamp > lastBlock.timestamp)) | |
1924 | + | then true | |
1925 | + | else !(initialized())) | |
1926 | + | then true | |
1927 | + | else paused()) | |
1928 | + | then throw(((("Invalid funding block timestamp: " + toString(lastBlock.timestamp)) + " < ") + toString(fundingBlockTimestamp))) | |
1929 | + | else { | |
1930 | + | let underlyingPrice = getOracleTwapPrice() | |
1931 | + | let $t08123481296 = getFunding() | |
1932 | + | let shortPremiumFraction = $t08123481296._1 | |
1933 | + | let longPremiumFraction = $t08123481296._2 | |
1934 | + | updateFunding((fundingBlockTimestamp + fundingPeriodSeconds()), (latestLongCumulativePremiumFraction() + longPremiumFraction), (latestShortCumulativePremiumFraction() + shortPremiumFraction), divd(longPremiumFraction, underlyingPrice), divd(shortPremiumFraction, underlyingPrice)) | |
1935 | + | } | |
1936 | + | } | |
1937 | + | else throw("Strict value is not equal to itself.") | |
1933 | 1938 | } | |
1934 | 1939 | ||
1935 | 1940 | ||
1936 | 1941 | ||
1937 | 1942 | @Callable(i) | |
1938 | 1943 | func syncTerminalPriceToOracle () = { | |
1939 | - | let $ | |
1940 | - | let newQuoteAssetWeight = $ | |
1941 | - | let newBaseAssetWeight = $ | |
1942 | - | let marginToVault = $ | |
1944 | + | let $t08167881799 = getSyncTerminalPrice(getOracleTwapPrice()) | |
1945 | + | let newQuoteAssetWeight = $t08167881799._1 | |
1946 | + | let newBaseAssetWeight = $t08167881799._2 | |
1947 | + | let marginToVault = $t08167881799._3 | |
1943 | 1948 | let doExchangePnL = if ((marginToVault != 0)) | |
1944 | 1949 | then { | |
1945 | 1950 | let doExchangePnL = invoke(vaultAddress(), "exchangeFreeAndLocked", [marginToVault], nil) | |
1946 | 1951 | if ((doExchangePnL == doExchangePnL)) | |
1947 | 1952 | then nil | |
1948 | 1953 | else throw("Strict value is not equal to itself.") | |
1949 | 1954 | } | |
1950 | 1955 | else nil | |
1951 | 1956 | if ((doExchangePnL == doExchangePnL)) | |
1952 | - | then updateAmmWeights(newQuoteAssetWeight, newBaseAssetWeight) | |
1957 | + | then { | |
1958 | + | let _qtAstR = qtAstR() | |
1959 | + | let _bsAstR = bsAstR() | |
1960 | + | (updateAmmWeights(newQuoteAssetWeight, newBaseAssetWeight) ++ appendTwap(divd(muld(_qtAstR, newQuoteAssetWeight), muld(_bsAstR, newBaseAssetWeight)))) | |
1961 | + | } | |
1953 | 1962 | else throw("Strict value is not equal to itself.") | |
1954 | 1963 | } | |
1955 | 1964 | ||
1956 | 1965 | ||
1957 | 1966 | ||
1958 | 1967 | @Callable(i) | |
1959 | 1968 | func view_calcRemainMarginWithFundingPayment (_trader) = { | |
1960 | 1969 | let sync = invoke(this, "syncTerminalPriceToOracle", nil, nil) | |
1961 | 1970 | if ((sync == sync)) | |
1962 | 1971 | then { | |
1963 | - | let $ | |
1964 | - | let positionSize = $ | |
1965 | - | let positionMargin = $ | |
1966 | - | let pon = $ | |
1967 | - | let positionLstUpdCPF = $ | |
1968 | - | let $ | |
1969 | - | let positionNotional = $ | |
1970 | - | let unrealizedPnl = $ | |
1971 | - | let $ | |
1972 | - | let remainMargin = $ | |
1973 | - | let badDebt = $ | |
1974 | - | let fundingPayment = $ | |
1972 | + | let $t08241982520 = getPosition(_trader) | |
1973 | + | let positionSize = $t08241982520._1 | |
1974 | + | let positionMargin = $t08241982520._2 | |
1975 | + | let pon = $t08241982520._3 | |
1976 | + | let positionLstUpdCPF = $t08241982520._4 | |
1977 | + | let $t08252382624 = getPositionNotionalAndUnrealizedPnl(_trader, PNL_OPTION_SPOT) | |
1978 | + | let positionNotional = $t08252382624._1 | |
1979 | + | let unrealizedPnl = $t08252382624._2 | |
1980 | + | let $t08262782799 = calcRemainMarginWithFundingPayment(positionSize, positionMargin, positionLstUpdCPF, unrealizedPnl) | |
1981 | + | let remainMargin = $t08262782799._1 | |
1982 | + | let badDebt = $t08262782799._2 | |
1983 | + | let fundingPayment = $t08262782799._3 | |
1975 | 1984 | throw((((((s(remainMargin) + s(fundingPayment)) + s(getMarginRatio(_trader))) + s(unrealizedPnl)) + s(badDebt)) + s(positionNotional))) | |
1976 | 1985 | } | |
1977 | 1986 | else throw("Strict value is not equal to itself.") | |
1978 | 1987 | } | |
1979 | 1988 | ||
1980 | 1989 | ||
1981 | 1990 | ||
1982 | 1991 | @Callable(i) | |
1983 | 1992 | func view_getPegAdjustCost (_price) = { | |
1984 | 1993 | let result = getSyncTerminalPrice(_price) | |
1985 | 1994 | throw(toString(result._3)) | |
1986 | 1995 | } | |
1987 | 1996 | ||
1988 | 1997 | ||
1989 | 1998 | ||
1990 | 1999 | @Callable(i) | |
1991 | 2000 | func view_getTerminalAmmPrice () = { | |
1992 | - | let $ | |
1993 | - | let terminalQuoteAssetReserve = $ | |
1994 | - | let terminalBaseAssetReserve = $ | |
2001 | + | let $t08314683227 = getTerminalAmmState() | |
2002 | + | let terminalQuoteAssetReserve = $t08314683227._1 | |
2003 | + | let terminalBaseAssetReserve = $t08314683227._2 | |
1995 | 2004 | let price = divd(muld(terminalQuoteAssetReserve, qtAstW()), muld(terminalBaseAssetReserve, bsAstW())) | |
1996 | 2005 | throw(toString(price)) | |
1997 | 2006 | } | |
1998 | 2007 | ||
1999 | 2008 | ||
2000 | 2009 | ||
2001 | 2010 | @Callable(i) | |
2002 | 2011 | func view_getFunding () = { | |
2003 | 2012 | let underlyingPrice = getOracleTwapPrice() | |
2004 | - | let $ | |
2005 | - | let shortPremiumFraction = $ | |
2006 | - | let longPremiumFraction = $ | |
2013 | + | let $t08344683508 = getFunding() | |
2014 | + | let shortPremiumFraction = $t08344683508._1 | |
2015 | + | let longPremiumFraction = $t08344683508._2 | |
2007 | 2016 | let longFunding = divd(longPremiumFraction, underlyingPrice) | |
2008 | 2017 | let shortFunding = divd(shortPremiumFraction, underlyingPrice) | |
2009 | 2018 | throw((((s(longFunding) + s(shortFunding)) + s(getTwapSpotPrice())) + s(getOracleTwapPrice()))) | |
2010 | 2019 | } | |
2011 | 2020 | ||
2012 | 2021 | ||
2013 | 2022 | ||
2014 | 2023 | @Callable(i) | |
2015 | 2024 | func view_getBorrowedByTrader (_trader) = { | |
2016 | - | let $ | |
2017 | - | let borrowed = $ | |
2018 | - | let assetId = $ | |
2025 | + | let $t08379883852 = getBorrowedByTrader(_trader) | |
2026 | + | let borrowed = $t08379883852._1 | |
2027 | + | let assetId = $t08379883852._2 | |
2019 | 2028 | throw((s(borrowed) + assetId)) | |
2020 | 2029 | } | |
2021 | 2030 | ||
2022 | 2031 | ||
2023 | 2032 | ||
2024 | 2033 | @Callable(i) | |
2025 | 2034 | func computeSpotPrice () = { | |
2026 | 2035 | let result = getSpotPrice() | |
2027 | 2036 | $Tuple2(nil, result) | |
2028 | 2037 | } | |
2029 | 2038 | ||
2030 | 2039 | ||
2031 | 2040 | ||
2032 | 2041 | @Callable(i) | |
2033 | 2042 | func computeFeeForTraderWithArtifact (_trader,_artifactId) = { | |
2034 | 2043 | let result = getForTraderWithArtifact(_trader, _artifactId) | |
2035 | 2044 | $Tuple2(nil, result) | |
2036 | 2045 | } | |
2037 | 2046 | ||
2038 | 2047 | ||
2039 | 2048 | @Verifier(tx) | |
2040 | 2049 | func verify () = sigVerify(tx.bodyBytes, tx.proofs[0], adminPublicKey()) | |
2041 | 2050 |
github/deemru/w8io/026f985 176.67 ms ◑