tx · GKCEuH6PJmQ5pPg5nPMfzPLaE7chqSnP8GqdCaPfMrE5 3MuAPY3jP4q2AoNYX27B5BU9EoLU77mr7pS: -0.01400000 Waves 2021.01.21 20:25 [1363511] smart account 3MuAPY3jP4q2AoNYX27B5BU9EoLU77mr7pS > SELF 0.00000000 Waves
{ "type": 13, "id": "GKCEuH6PJmQ5pPg5nPMfzPLaE7chqSnP8GqdCaPfMrE5", "fee": 1400000, "feeAssetId": null, "timestamp": 1611249979455, "version": 1, "sender": "3MuAPY3jP4q2AoNYX27B5BU9EoLU77mr7pS", "senderPublicKey": "rqCnkHfz5ix6HNKiVvYE3URUtLs6f2nWzt4hpdGGQdm", "proofs": [ "35BtUe67qENWEWXruPvmK51LpL4Uu7D95EBBVVajnJGX4g8r28eGJCDeZ2mGreZN9TLLRAU3wCJNcdJxgp8LAvkc" ], "script": "base64:AAIEAAAAAAAAAAYIAhIAEgAAAABTAAAAABBuZXV0cmlub0NvbnRyYWN0CQEAAAARQGV4dHJOYXRpdmUoMTA2MikAAAABAgAAACMzTXpieDM0RXg1clJibjM5dlVIeDlraXdoM25uZUY4UzV3ZQEAAAAOZ2V0TnVtYmVyQnlLZXkAAAABAAAAA2tleQkBAAAAC3ZhbHVlT3JFbHNlAAAAAgkABBoAAAACBQAAABBuZXV0cmlub0NvbnRyYWN0BQAAAANrZXkAAAAAAAAAAAABAAAADmdldFN0cmluZ0J5S2V5AAAAAQAAAANrZXkJAQAAAAt2YWx1ZU9yRWxzZQAAAAIJAAQdAAAAAgUAAAAQbmV1dHJpbm9Db250cmFjdAUAAAADa2V5AgAAAAABAAAADGdldEJvb2xCeUtleQAAAAEAAAADa2V5CQEAAAALdmFsdWVPckVsc2UAAAACCQAEGwAAAAIFAAAAEG5ldXRyaW5vQ29udHJhY3QFAAAAA2tleQcBAAAAGGdldE51bWJlckJ5QWRkcmVzc0FuZEtleQAAAAIAAAAHYWRkcmVzcwAAAANrZXkJAQAAAAt2YWx1ZU9yRWxzZQAAAAIJ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AAAABXZhbHVlBAAAAAhyZXN0RGF0YQkABLkAAAACCQAETAAAAAICAAAAEnN0YXJ0TnNidFByaWNlUkVTVAkABEwAAAACCQABpAAAAAEFAAAADm5zYnQydXNkblByaWNlCQAETAAAAAIJAAGkAAAAAQUAAAAPbnNidDJ3YXZlc1ByaWNlCQAETAAAAAICAAAAEGVuZE5zYnRQcmljZVJFU1QFAAAAA25pbAIAAAACX18JAAACAAAAAQUAAAAIcmVzdERhdGEAAAAAKkueDA==", "chainId": 84, "height": 1363511, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: none Next: Ef3ndKwh9MKx9MCmb8UJYKX8FBebvEzFsKhvDqZHVNRY Full:
Old | New | Differences | |
---|---|---|---|
1 | - | # no script | |
1 | + | {-# STDLIB_VERSION 4 #-} | |
2 | + | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | + | {-# CONTENT_TYPE DAPP #-} | |
4 | + | let neutrinoContract = addressFromStringValue("3Mzbx34Ex5rRbn39vUHx9kiwh3nneF8S5we") | |
5 | + | ||
6 | + | func getNumberByKey (key) = valueOrElse(getInteger(neutrinoContract, key), 0) | |
7 | + | ||
8 | + | ||
9 | + | func getStringByKey (key) = valueOrElse(getString(neutrinoContract, key), "") | |
10 | + | ||
11 | + | ||
12 | + | func getBoolByKey (key) = valueOrElse(getBoolean(neutrinoContract, key), false) | |
13 | + | ||
14 | + | ||
15 | + | func getNumberByAddressAndKey (address,key) = valueOrElse(getInteger(addressFromStringValue(address), key), 0) | |
16 | + | ||
17 | + | ||
18 | + | func getStringByAddressAndKey (address,key) = valueOrElse(getString(addressFromStringValue(address), key), "") | |
19 | + | ||
20 | + | ||
21 | + | func getBoolByAddressAndKey (address,key) = valueOrElse(getBoolean(addressFromStringValue(address), key), false) | |
22 | + | ||
23 | + | ||
24 | + | let SENDTXEXPIRE = 30 | |
25 | + | ||
26 | + | let LISTSPLITSYMBOL = "_" | |
27 | + | ||
28 | + | let LISTDATASYMBOL = "+" | |
29 | + | ||
30 | + | let WAVELET = 100000000 | |
31 | + | ||
32 | + | let PAULI = 1000000 | |
33 | + | ||
34 | + | let PRICELET = 1000000 | |
35 | + | ||
36 | + | let MULT = 100000000 | |
37 | + | ||
38 | + | let MULTSCALE = 8 | |
39 | + | ||
40 | + | let NeutrinoAssetIdKey = "neutrino_asset_id" | |
41 | + | ||
42 | + | let BondAssetIdKey = "bond_asset_id" | |
43 | + | ||
44 | + | let AuctionContractKey = "auction_contract" | |
45 | + | ||
46 | + | let LiquidationContractKey = "liquidation_contract" | |
47 | + | ||
48 | + | let RPDContractKey = "rpd_contract" | |
49 | + | ||
50 | + | let ContolContractKey = "control_contract" | |
51 | + | ||
52 | + | let BalanceWavesLockIntervalKey = "balance_waves_lock_interval" | |
53 | + | ||
54 | + | let BalanceNeutrinoLockIntervalKey = "balance_neutrino_lock_interval" | |
55 | + | ||
56 | + | let MinWavesSwapAmountKey = "min_waves_swap_amount" | |
57 | + | ||
58 | + | let MinNeutrinoSwapAmountKey = "min_neutrino_swap_amount" | |
59 | + | ||
60 | + | let NodeOracleProviderPubKeyKey = "node_oracle_provider" | |
61 | + | ||
62 | + | let RPDBalanceKey = "rpd_balance" | |
63 | + | ||
64 | + | func getRPDContractBalanceKey (assetId) = ((RPDBalanceKey + "_") + toBase58String(assetId)) | |
65 | + | ||
66 | + | ||
67 | + | let PriceKey = "price" | |
68 | + | ||
69 | + | let PriceIndexKey = "price_index" | |
70 | + | ||
71 | + | let IsBlockedKey = "is_blocked" | |
72 | + | ||
73 | + | func getPriceHistoryKey (block) = ((PriceKey + "_") + toString(block)) | |
74 | + | ||
75 | + | ||
76 | + | func getHeightPriceByIndexKey (index) = ((PriceIndexKey + "_") + toString(index)) | |
77 | + | ||
78 | + | ||
79 | + | let BalanceLockedkKey = "balance_lock_" | |
80 | + | ||
81 | + | let WavesLockedBalanceKey = (BalanceLockedkKey + "waves") | |
82 | + | ||
83 | + | let NeutrinoLockedBalanceKey = (BalanceLockedkKey + "neutrino") | |
84 | + | ||
85 | + | func getRPDSnapshotContractBalanceKey (count,assetId) = ((((RPDBalanceKey + "_") + toBase58String(assetId)) + "_") + toString(count)) | |
86 | + | ||
87 | + | ||
88 | + | func getCancelLeaseTxReserveFeeKey (hash) = (("cancel_lease_tx_reserve_fee" + "_") + hash) | |
89 | + | ||
90 | + | ||
91 | + | func getWavesLockedBalanceKey (owner) = ((WavesLockedBalanceKey + "_") + owner) | |
92 | + | ||
93 | + | ||
94 | + | func getNeutrinoLockedBalanceKey (owner) = ((NeutrinoLockedBalanceKey + "_") + owner) | |
95 | + | ||
96 | + | ||
97 | + | func getBalanceUnlockBlockKey (owner) = ("balance_unlock_block_" + owner) | |
98 | + | ||
99 | + | ||
100 | + | func getRPDProfitKey (count) = (("rpd_profit" + "_") + toString(count)) | |
101 | + | ||
102 | + | ||
103 | + | func convertNeutrinoToWaves (amount,price) = fraction(fraction(amount, PRICELET, price), WAVELET, PAULI) | |
104 | + | ||
105 | + | ||
106 | + | func convertWavesToNeutrino (amount,price) = fraction(fraction(amount, price, PRICELET), PAULI, WAVELET) | |
107 | + | ||
108 | + | ||
109 | + | func convertWavesToBond (amount,price) = convertWavesToNeutrino(amount, price) | |
110 | + | ||
111 | + | ||
112 | + | func convertJsonArrayToList (jsonArray) = split(jsonArray, ",") | |
113 | + | ||
114 | + | ||
115 | + | let liquidationContract = getStringByKey(LiquidationContractKey) | |
116 | + | ||
117 | + | let neutrinoAssetIdString = getStringByKey(NeutrinoAssetIdKey) | |
118 | + | ||
119 | + | let neutrinoAssetId = fromBase58String(neutrinoAssetIdString) | |
120 | + | ||
121 | + | let auctionContract = getStringByKey(AuctionContractKey) | |
122 | + | ||
123 | + | let rpdContract = getStringByKey(RPDContractKey) | |
124 | + | ||
125 | + | let controlContract = getStringByKey(ContolContractKey) | |
126 | + | ||
127 | + | let priceIndex = getNumberByAddressAndKey(controlContract, PriceIndexKey) | |
128 | + | ||
129 | + | let isBlocked = getBoolByAddressAndKey(controlContract, IsBlockedKey) | |
130 | + | ||
131 | + | let nodeOracleProviderPubKey = fromBase58String(getStringByKey(NodeOracleProviderPubKeyKey)) | |
132 | + | ||
133 | + | let balanceWavesLockInterval = getNumberByKey(BalanceWavesLockIntervalKey) | |
134 | + | ||
135 | + | let balanceNeutrinoLockInterval = getNumberByKey(BalanceNeutrinoLockIntervalKey) | |
136 | + | ||
137 | + | let minWavesSwapAmount = getNumberByKey(MinWavesSwapAmountKey) | |
138 | + | ||
139 | + | let minNeutrinoSwapAmount = getNumberByKey(MinNeutrinoSwapAmountKey) | |
140 | + | ||
141 | + | let nsbtAssetIdStr = getStringValue(neutrinoContract, BondAssetIdKey) | |
142 | + | ||
143 | + | let nsbtAssetId = fromBase58String(nsbtAssetIdStr) | |
144 | + | ||
145 | + | let deprecatedBondAssetId = fromBase58String("975akZBfnMj513U7MZaHKzQrmsEx5aE3wdWKTrHBhbjF") | |
146 | + | ||
147 | + | let currentPrice = getNumberByAddressAndKey(controlContract, PriceKey) | |
148 | + | ||
149 | + | let neutrinoLockedBalance = getNumberByKey(NeutrinoLockedBalanceKey) | |
150 | + | ||
151 | + | let wavesLockedBalance = getNumberByKey(WavesLockedBalanceKey) | |
152 | + | ||
153 | + | let reservesInWaves = (wavesBalance(neutrinoContract).regular - wavesLockedBalance) | |
154 | + | ||
155 | + | let reservesInUsdn = convertWavesToNeutrino(reservesInWaves, currentPrice) | |
156 | + | ||
157 | + | let neutrinoSupply = (((neutrinoLockedBalance + value(assetInfo(neutrinoAssetId)).quantity) - assetBalance(neutrinoContract, neutrinoAssetId)) - assetBalance(addressFromStringValue(liquidationContract), neutrinoAssetId)) | |
158 | + | ||
159 | + | let surplus = (reservesInUsdn - neutrinoSupply) | |
160 | + | ||
161 | + | let surplusPercent = (fraction(surplus, PAULI, neutrinoSupply) * 100) | |
162 | + | ||
163 | + | let BR = fraction(reservesInUsdn, PAULI, neutrinoSupply) | |
164 | + | ||
165 | + | let auctionAddress = addressFromStringValue(auctionContract) | |
166 | + | ||
167 | + | let nsbtSupplyMAX = value(assetInfo(nsbtAssetId)).quantity | |
168 | + | ||
169 | + | let nsbtSupply = (nsbtSupplyMAX - assetBalance(auctionAddress, nsbtAssetId)) | |
170 | + | ||
171 | + | let IdxA = 0 | |
172 | + | ||
173 | + | let IdxPaulB = 1 | |
174 | + | ||
175 | + | let IdxWResAsUsdn = 2 | |
176 | + | ||
177 | + | let IdxMultBR = 3 | |
178 | + | ||
179 | + | let IdxMultPower = 4 | |
180 | + | ||
181 | + | let IdxMultExpInPower = 5 | |
182 | + | ||
183 | + | let IdxMultK = 6 | |
184 | + | ||
185 | + | func calculateK (wRaw,uRaw,price,mRaw,sRaw) = { | |
186 | + | let EXP = 271828100 | |
187 | + | let a = valueOrElse(getInteger(this, "nsbtCurveParam_a"), 3) | |
188 | + | let paulB = valueOrElse(getInteger(this, "nsbtCurveParam_b"), ((3 * PAULI) / 10)) | |
189 | + | let wReservesInUsdn = convertWavesToNeutrino(wRaw, price) | |
190 | + | let multBR = fraction(wReservesInUsdn, MULT, uRaw) | |
191 | + | let multPower = (a * (multBR - (1 * MULT))) | |
192 | + | let multExpInPower = pow(EXP, MULTSCALE, multPower, MULTSCALE, MULTSCALE, DOWN) | |
193 | + | let multK = fraction(paulB, multExpInPower, PAULI) | |
194 | + | [a, paulB, wReservesInUsdn, multBR, multPower, multExpInPower, multK] | |
195 | + | } | |
196 | + | ||
197 | + | ||
198 | + | func privateNsbtPriceREST () = { | |
199 | + | let kCalcArray = calculateK(reservesInWaves, neutrinoSupply, currentPrice, nsbtSupplyMAX, nsbtSupply) | |
200 | + | let multK = kCalcArray[IdxMultK] | |
201 | + | let multStep1 = fraction(nsbtSupplyMAX, MULT, (nsbtSupplyMAX - nsbtSupply)) | |
202 | + | let multStep2 = fraction(multStep1, multStep1, MULT) | |
203 | + | let multNsbt2usdnPrice = fraction(multK, multStep2, MULT) | |
204 | + | let nsbt2usdnPrice = fraction(multNsbt2usdnPrice, PAULI, MULT) | |
205 | + | let nsbt2wavesPrice = fraction(nsbt2usdnPrice, PAULI, currentPrice) | |
206 | + | $Tuple2(IntegerEntry("nsbt2usdnPrice", nsbt2usdnPrice), IntegerEntry("nsbt2wavesPrice", nsbt2wavesPrice)) | |
207 | + | } | |
208 | + | ||
209 | + | ||
210 | + | @Callable(i) | |
211 | + | func neutrinoStateREST () = throw(makeString(["resultNeutrinoStateREST", toString(currentPrice), toString(neutrinoLockedBalance), toString(wavesLockedBalance), toString(reservesInWaves), toString(reservesInUsdn), toString(neutrinoSupply), toString(surplus), toString(surplusPercent), toString(BR), toString(nsbtSupply)], "__")) | |
212 | + | ||
213 | + | ||
214 | + | ||
215 | + | @Callable(i) | |
216 | + | func nsbtPriceREST () = { | |
217 | + | let nsbtPriceTuple = privateNsbtPriceREST() | |
218 | + | let nsbt2usdnPrice = nsbtPriceTuple._1.value | |
219 | + | let nsbt2wavesPrice = nsbtPriceTuple._2.value | |
220 | + | let restData = makeString(["startNsbtPriceREST", toString(nsbt2usdnPrice), toString(nsbt2wavesPrice), "endNsbtPriceREST"], "__") | |
221 | + | throw(restData) | |
222 | + | } | |
223 | + | ||
224 | + |
github/deemru/w8io/026f985 17.86 ms ◑