tx · 68be7LZWxU1pWvSfa3o7AQUoZqthi9aMPtmPc1abokAm 3N6Grmu8pZHV5Azabv7Vrz9i5jwoujw1Wi9: -0.01000000 Waves 2019.11.16 17:40 [767797] smart account 3N6Grmu8pZHV5Azabv7Vrz9i5jwoujw1Wi9 > SELF 0.00000000 Waves
{ "type": 13, "id": "68be7LZWxU1pWvSfa3o7AQUoZqthi9aMPtmPc1abokAm", "fee": 1000000, "feeAssetId": null, "timestamp": 1573915243952, "version": 1, "sender": "3N6Grmu8pZHV5Azabv7Vrz9i5jwoujw1Wi9", "senderPublicKey": "EU8XJTqdDYpBRYp42CAE42focQhM8UwCpmg4XZ8dxyEp", "proofs": [ "4QzEa9cGdgLMB4dzSFVkdy8WdcaWeaqTuZR718ECFLK4ag2qGCrwKjntkZUY4CLPZusWuTrVDJYDgzC9DnVFr1ri" ], "script": "base64:AAIDAAAAAAAAADQIARIAEgASBAoCCAESABIAEgMKAQgSABIDCgEIEgASBgoECAEBCBIDCgEIEgcKBQgIAQEIAAAAfQEAAAAOZ2V0TnVtYmVyQnlLZXkAAAABAAAAA2tleQQAAAAHJG1hdGNoMAkABBoAAAACBQAAAAR0aGlzBQAAAANrZXkDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAAA0ludAQAAAABYQUAAAAHJG1hdGNoMAUAAAABYQAAAAAAAAAAAAEAAAAOZ2V0U3RyaW5nQnlLZXkAAAABAAAAA2tleQQAAAAHJG1hdGNoMAkABB0AAAACBQAAAAR0aGlzBQAAAANrZXkDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAABlN0cmluZwQAAAABYQUAAAAHJG1hdGNoMAUAAAABYQIAAAAAAQAAAAxnZXRCb29sQnlLZXkAAAABAAAAA2tleQQAAAAHJG1hdGNoMAkABBsAAAACBQAAAAR0aGlzBQAAAANrZXkDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAAB0Jvb2xlYW4EAAAAAWEFAAAAByRtYXRjaDAFAAAAAWEHAQAAABhnZXROdW1iZXJ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hc2VUeEV4cGlyZVNlbmRCbG9jawAAAAEFAAAAAmlkBQAAAAZoZWlnaHQHCQAAAAAAAAIJAQAAABBnZXRMZWFzZVR4U3RhdHVzAAAAAQUAAAACaWQFAAAAA05FVwcDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAAFkxlYXNlQ2FuY2VsVHJhbnNhY3Rpb24EAAAACXVubGVhc2VUeAUAAAAHJG1hdGNoMAQAAAAHbGVhc2VJZAkAAlgAAAABCAUAAAAJdW5sZWFzZVR4AAAAB2xlYXNlSWQDAwMJAABmAAAAAgUAAAAGaGVpZ2h0BQAAABJsZWFzaW5nRXhwaXJlQmxvY2sGBQAAAAtpc1JlYmFsYW5jZQkAAAAAAAACCAUAAAAJdW5sZWFzZVR4AAAAA2ZlZQkBAAAAGmdldENhbmNlbExlYXNlVHhSZXNlcnZlRmVlAAAAAQUAAAAHbGVhc2VJZAcJAAAAAAAAAgkBAAAAEGdldExlYXNlVHhTdGF0dXMAAAABBQAAAAdsZWFzZUlkBQAAAANORVcHCQAB9AAAAAMIBQAAAAJ0eAAAAAlib2R5Qnl0ZXMJAAGRAAAAAggFAAAAAnR4AAAABnByb29mcwAAAAAAAAAAAAgFAAAAAnR4AAAAD3NlbmRlclB1YmxpY0tleYmj3Y8=", "chainId": 84, "height": 767797, "spentComplexity": 0 } View: original | compacted Prev: none Next: none Full:
Old | New | Differences | |
---|---|---|---|
1 | - | # no script | |
1 | + | {-# STDLIB_VERSION 3 #-} | |
2 | + | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | + | {-# CONTENT_TYPE DAPP #-} | |
4 | + | func getNumberByKey (key) = match getInteger(this, key) { | |
5 | + | case a: Int => | |
6 | + | a | |
7 | + | case _ => | |
8 | + | 0 | |
9 | + | } | |
10 | + | ||
11 | + | ||
12 | + | func getStringByKey (key) = match getString(this, key) { | |
13 | + | case a: String => | |
14 | + | a | |
15 | + | case _ => | |
16 | + | "" | |
17 | + | } | |
18 | + | ||
19 | + | ||
20 | + | func getBoolByKey (key) = match getBoolean(this, key) { | |
21 | + | case a: Boolean => | |
22 | + | a | |
23 | + | case _ => | |
24 | + | false | |
25 | + | } | |
26 | + | ||
27 | + | ||
28 | + | func getNumberByAddressAndKey (address,key) = match getInteger(addressFromStringValue(address), key) { | |
29 | + | case a: Int => | |
30 | + | a | |
31 | + | case _ => | |
32 | + | 0 | |
33 | + | } | |
34 | + | ||
35 | + | ||
36 | + | func getStringByAddressAndKey (address,key) = match getString(addressFromStringValue(address), key) { | |
37 | + | case a: String => | |
38 | + | a | |
39 | + | case _ => | |
40 | + | "" | |
41 | + | } | |
42 | + | ||
43 | + | ||
44 | + | func getBoolByAddressAndKey (address,key) = match getBoolean(addressFromStringValue(address), key) { | |
45 | + | case a: Boolean => | |
46 | + | a | |
47 | + | case _ => | |
48 | + | false | |
49 | + | } | |
50 | + | ||
51 | + | ||
52 | + | let SENDTXEXPIRE = 30 | |
53 | + | ||
54 | + | let LISTSPLITSYMBOL = "_" | |
55 | + | ||
56 | + | let LISTDATASYMBOL = "+" | |
57 | + | ||
58 | + | let WAVELET = 100000000 | |
59 | + | ||
60 | + | let PAULI = 100 | |
61 | + | ||
62 | + | let CRITICALSHARE = 20 | |
63 | + | ||
64 | + | let LEASINGSHARE = 90 | |
65 | + | ||
66 | + | let LEASINGTXCOUNT = 10 | |
67 | + | ||
68 | + | let CANCELED = "canceled" | |
69 | + | ||
70 | + | let NEW = "new" | |
71 | + | ||
72 | + | let FILLED = "filled" | |
73 | + | ||
74 | + | let DEFICITOFFSET = 10 | |
75 | + | ||
76 | + | let NeutrinoAssetIdKey = "neutrino_asset_id" | |
77 | + | ||
78 | + | let BondAssetIdKey = "bond_asset_id" | |
79 | + | ||
80 | + | let ReserveContractKey = "reserve_contract" | |
81 | + | ||
82 | + | let AuctionContractKey = "auction_contract" | |
83 | + | ||
84 | + | let RPDContractKey = "rpd_contract" | |
85 | + | ||
86 | + | let ControlContractKey = "control_contract" | |
87 | + | ||
88 | + | let BalanceLockIntervalKey = "balance_lock_interval" | |
89 | + | ||
90 | + | let MinWavesSwapAmountKey = "min_waves_swap_amount" | |
91 | + | ||
92 | + | let MinNeutrinoSwapAmountKey = "min_neutrino_swap_amount" | |
93 | + | ||
94 | + | let NodeAddressKey = "node_address" | |
95 | + | ||
96 | + | let NodeOracleProviderKey = "oracle_node_provider" | |
97 | + | ||
98 | + | let LeasingIntervalKey = "leasing_interval" | |
99 | + | ||
100 | + | let PriceKey = "price" | |
101 | + | ||
102 | + | let PriceIndexKey = "price_index" | |
103 | + | ||
104 | + | let ScriptUpdateIntervalKey = "script_update_interval" | |
105 | + | ||
106 | + | let NeutrinoBalanceKey = "neutrino_" | |
107 | + | ||
108 | + | let BalanceUnlockBlockKey = "balance_block_" | |
109 | + | ||
110 | + | let OrderbookKey = "orderbook" | |
111 | + | ||
112 | + | let OrderTotalKey = "order_total_" | |
113 | + | ||
114 | + | let OrderOwnerKey = "order_owner_" | |
115 | + | ||
116 | + | let OrderHeightKey = "order_height_" | |
117 | + | ||
118 | + | let OrderFilledTotalKey = "order_filled_total_" | |
119 | + | ||
120 | + | let OrderStatusKey = "order_status_" | |
121 | + | ||
122 | + | let RPDSyncIndexKey = "rpd_sync_index" | |
123 | + | ||
124 | + | let RPDProfitKey = "rpd_profit" | |
125 | + | ||
126 | + | let RPDBalanceKey = "rpd_balance" | |
127 | + | ||
128 | + | let IsBlockedKey = "is_blocked" | |
129 | + | ||
130 | + | let IsLeasingProfitTxExistKey = "is_leasing_profit" | |
131 | + | ||
132 | + | let ScriptUpdateBlockKey = "script_update_block" | |
133 | + | ||
134 | + | let LeaseTxKey = "lease_tx" | |
135 | + | ||
136 | + | let LeaseTxStatusKey = "lease_tx_status" | |
137 | + | ||
138 | + | let LeasingAmountKey = "leasing_amount" | |
139 | + | ||
140 | + | let LeaseTxExpireSendBlockKey = "leasing_expire_send" | |
141 | + | ||
142 | + | let LeasingExpireBlockKey = "leasing_expire_block" | |
143 | + | ||
144 | + | let IsRebalanceKey = "is_rebalance" | |
145 | + | ||
146 | + | let SwapNeutrinoLockedBalanceKey = "swap_neutrino_locked_balance" | |
147 | + | ||
148 | + | let LeasingTxCountKey = "leasing_index" | |
149 | + | ||
150 | + | let CancelLeaseTxReserveFeeKey = "cancel_lease_tx_reserve_fee" | |
151 | + | ||
152 | + | func getRPDSnapshotContractBalanceKey (count,assetId) = ((((RPDBalanceKey + "_") + toBase58String(assetId)) + "_") + toString(count)) | |
153 | + | ||
154 | + | ||
155 | + | func getRPDContractBalanceKey (assetId) = ((RPDBalanceKey + "_") + toBase58String(assetId)) | |
156 | + | ||
157 | + | ||
158 | + | func getRPDProfitKey (count) = ((RPDProfitKey + "_") + toString(count)) | |
159 | + | ||
160 | + | ||
161 | + | func getNeutrinoBalanceKey (owner) = (NeutrinoBalanceKey + owner) | |
162 | + | ||
163 | + | ||
164 | + | func getBalanceUnlockBlockKey (owner) = (BalanceUnlockBlockKey + owner) | |
165 | + | ||
166 | + | ||
167 | + | func getOrderTotalKey (orderId) = (OrderTotalKey + orderId) | |
168 | + | ||
169 | + | ||
170 | + | func getOrderOwnerKey (orderId) = (OrderOwnerKey + orderId) | |
171 | + | ||
172 | + | ||
173 | + | func getOrderHeightKey (orderId) = (OrderHeightKey + orderId) | |
174 | + | ||
175 | + | ||
176 | + | func getOrderStatusKey (orderId) = (OrderStatusKey + orderId) | |
177 | + | ||
178 | + | ||
179 | + | func getOrderFilledTotalKey (orderId) = (OrderFilledTotalKey + orderId) | |
180 | + | ||
181 | + | ||
182 | + | func getPriceHistoryKey (block) = ((PriceKey + "_") + toString(block)) | |
183 | + | ||
184 | + | ||
185 | + | func getHeightPriceByIndexKey (index) = ((PriceIndexKey + "_") + toString(index)) | |
186 | + | ||
187 | + | ||
188 | + | func getLeaseTxStatusKey (hash) = ((LeaseTxStatusKey + "_") + hash) | |
189 | + | ||
190 | + | ||
191 | + | func getLeaseTxAmountByHashKey (hash) = ((LeasingAmountKey + "_") + hash) | |
192 | + | ||
193 | + | ||
194 | + | func getLeaseTxBytesByHashKey (hash) = ((LeaseTxKey + "_") + hash) | |
195 | + | ||
196 | + | ||
197 | + | func getLeaseTxExpireSendBlockKey (hash) = ((LeaseTxExpireSendBlockKey + "_") + hash) | |
198 | + | ||
199 | + | ||
200 | + | func getCancelLeaseTxReserveFeeKey (hash) = ((CancelLeaseTxReserveFeeKey + "_") + hash) | |
201 | + | ||
202 | + | ||
203 | + | let neutrinoAssetId = fromBase58String(getStringByKey(NeutrinoAssetIdKey)) | |
204 | + | ||
205 | + | let reserveContract = getStringByKey(ReserveContractKey) | |
206 | + | ||
207 | + | let auctionContract = getStringByKey(AuctionContractKey) | |
208 | + | ||
209 | + | let rpdContract = getStringByKey(RPDContractKey) | |
210 | + | ||
211 | + | let controlContract = getStringByKey(ControlContractKey) | |
212 | + | ||
213 | + | let price = getNumberByAddressAndKey(controlContract, PriceKey) | |
214 | + | ||
215 | + | let priceIndex = getNumberByAddressAndKey(controlContract, PriceIndexKey) | |
216 | + | ||
217 | + | func convertNeutrinoToWavesByPrice (amount,convertPrice) = ((((amount * 100) / convertPrice) * WAVELET) / PAULI) | |
218 | + | ||
219 | + | ||
220 | + | func convertNeutrinoToWaves (amount) = ((((amount * 100) / price) * WAVELET) / PAULI) | |
221 | + | ||
222 | + | ||
223 | + | func convertWavesToNeutrino (amount) = ((((amount * price) / 100) * PAULI) / WAVELET) | |
224 | + | ||
225 | + | ||
226 | + | func convertNeutrinoToBond (amount) = (amount / PAULI) | |
227 | + | ||
228 | + | ||
229 | + | func convertBondToNeutrino (amount) = (amount * PAULI) | |
230 | + | ||
231 | + | ||
232 | + | func convertWavesToBond (amount) = convertNeutrinoToBond(convertWavesToNeutrino(amount)) | |
233 | + | ||
234 | + | ||
235 | + | let isBlocked = getBoolByAddressAndKey(controlContract, IsBlockedKey) | |
236 | + | ||
237 | + | let leasingTxCount = getNumberByKey(LeasingTxCountKey) | |
238 | + | ||
239 | + | let isRebalance = getBoolByKey(IsRebalanceKey) | |
240 | + | ||
241 | + | let leasingInterval = getNumberByKey(LeasingIntervalKey) | |
242 | + | ||
243 | + | let leasingExpireBlock = getNumberByKey(LeasingExpireBlockKey) | |
244 | + | ||
245 | + | let leasingAmount = getNumberByKey(LeasingAmountKey) | |
246 | + | ||
247 | + | let swapNeutrinoLockedBalance = getNumberByKey(SwapNeutrinoLockedBalanceKey) | |
248 | + | ||
249 | + | let nodeAddress = getStringByKey(NodeAddressKey) | |
250 | + | ||
251 | + | let nodeOracleProviderKey = getStringByKey(NodeOracleProviderKey) | |
252 | + | ||
253 | + | let rpdSyncIndex = getNumberByKey(RPDSyncIndexKey) | |
254 | + | ||
255 | + | let balanceLockInterval = getNumberByKey(BalanceLockIntervalKey) | |
256 | + | ||
257 | + | let minWavesSwapAmount = getNumberByKey(MinWavesSwapAmountKey) | |
258 | + | ||
259 | + | let minNeutrinoSwapAmount = getNumberByKey(MinNeutrinoSwapAmountKey) | |
260 | + | ||
261 | + | let reserve = wavesBalance(this) | |
262 | + | ||
263 | + | let reserveWithoutLeasing = (reserve - leasingAmount) | |
264 | + | ||
265 | + | let orderbook = getStringByKey(OrderbookKey) | |
266 | + | ||
267 | + | let bondAssetId = fromBase58String(getStringByKey(BondAssetIdKey)) | |
268 | + | ||
269 | + | let bondSupply = { | |
270 | + | let info = extract(assetInfo(bondAssetId)) | |
271 | + | (info.quantity - assetBalance(this, bondAssetId)) | |
272 | + | } | |
273 | + | ||
274 | + | let neutrinoSupply = { | |
275 | + | let info = extract(assetInfo(neutrinoAssetId)) | |
276 | + | ((info.quantity - assetBalance(this, neutrinoAssetId)) + swapNeutrinoLockedBalance) | |
277 | + | } | |
278 | + | ||
279 | + | let surplus = (convertWavesToNeutrino(reserve) - neutrinoSupply) | |
280 | + | ||
281 | + | let deficit = (neutrinoSupply - convertWavesToNeutrino(reserve)) | |
282 | + | ||
283 | + | func getRPDContractBalance (assetId) = getNumberByAddressAndKey(rpdContract, getRPDContractBalanceKey(assetId)) | |
284 | + | ||
285 | + | ||
286 | + | func getPriceHistory (block) = getNumberByAddressAndKey(controlContract, getPriceHistoryKey(block)) | |
287 | + | ||
288 | + | ||
289 | + | func getHeightPriceByIndex (index) = getNumberByAddressAndKey(controlContract, getHeightPriceByIndexKey(index)) | |
290 | + | ||
291 | + | ||
292 | + | func getCancelLeaseTxReserveFee (hash) = getNumberByKey(getCancelLeaseTxReserveFeeKey(hash)) | |
293 | + | ||
294 | + | ||
295 | + | func getNeutrinoBalance (owner) = getNumberByKey(getNeutrinoBalanceKey(owner)) | |
296 | + | ||
297 | + | ||
298 | + | func getUnlockBalanceBlock (owner) = getNumberByKey(getBalanceUnlockBlockKey(owner)) | |
299 | + | ||
300 | + | ||
301 | + | func getOrderTotal (id) = getNumberByKey(getOrderTotalKey(id)) | |
302 | + | ||
303 | + | ||
304 | + | func getOrderOwner (id) = getStringByKey(getOrderOwnerKey(id)) | |
305 | + | ||
306 | + | ||
307 | + | func getOrderStatus (id) = getStringByKey(getOrderStatusKey(id)) | |
308 | + | ||
309 | + | ||
310 | + | func getOrderFilledTotal (id) = getNumberByKey(getOrderFilledTotalKey(id)) | |
311 | + | ||
312 | + | ||
313 | + | func getRPDProfit (count) = getNumberByKey(getRPDProfitKey(count)) | |
314 | + | ||
315 | + | ||
316 | + | func getLeaseTxStatus (hash) = getStringByKey(getLeaseTxStatusKey(hash)) | |
317 | + | ||
318 | + | ||
319 | + | func getLeaseTxAmountByHash (hash) = getNumberByKey(getLeaseTxAmountByHashKey(hash)) | |
320 | + | ||
321 | + | ||
322 | + | func getLeaseTxBytesByHash (hash) = getStringByKey(getLeaseTxBytesByHashKey(hash)) | |
323 | + | ||
324 | + | ||
325 | + | func getLeaseTxExpireSendBlock (hash) = getNumberByKey(getLeaseTxExpireSendBlockKey(hash)) | |
326 | + | ||
327 | + | ||
328 | + | func getOrderElementById (id) = (id + LISTSPLITSYMBOL) | |
329 | + | ||
330 | + | ||
331 | + | func addOrder (orderId) = (orderbook + getOrderElementById(orderId)) | |
332 | + | ||
333 | + | ||
334 | + | func dropOrder (orderId) = { | |
335 | + | let parts = split(orderbook, getOrderElementById(orderId)) | |
336 | + | (parts[0] + parts[1]) | |
337 | + | } | |
338 | + | ||
339 | + | ||
340 | + | @Callable(i) | |
341 | + | func swapWavesToNeutrino () = { | |
342 | + | let pmt = extract(i.payment) | |
343 | + | if ((minWavesSwapAmount > pmt.amount)) | |
344 | + | then throw((("The specified Waves amount is less than the required minimum of " + toString(minWavesSwapAmount)) + " wavelets.")) | |
345 | + | else if (isDefined(pmt.assetId)) | |
346 | + | then throw("Only Waves token is allowed for swapping.") | |
347 | + | else if (isBlocked) | |
348 | + | then throw("The contract is blocked by EMERGENCY SHUTDOWN. Please wait for reactivation by emergency oracles.") | |
349 | + | else { | |
350 | + | let amount = convertWavesToNeutrino(pmt.amount) | |
351 | + | TransferSet([ScriptTransfer(i.caller, amount, neutrinoAssetId)]) | |
352 | + | } | |
353 | + | } | |
354 | + | ||
355 | + | ||
356 | + | ||
357 | + | @Callable(i) | |
358 | + | func swapNeutrinoToWaves () = { | |
359 | + | let pmt = extract(i.payment) | |
360 | + | let account = toString(i.caller) | |
361 | + | if ((minNeutrinoSwapAmount > pmt.amount)) | |
362 | + | then throw((("The specified Neutrino amount is less than the required minimum of " + toString(minNeutrinoSwapAmount)) + " Neutrino cents.")) | |
363 | + | else if (isBlocked) | |
364 | + | then throw("The contract is blocked by EMERGENCY SHUTDOWN. Please wait for reactivation by emergency oracles.") | |
365 | + | else if ((pmt.assetId != neutrinoAssetId)) | |
366 | + | then throw("Only appropriate Neutrino tokens are allowed for swapping.") | |
367 | + | else if ((getUnlockBalanceBlock(account) > height)) | |
368 | + | then throw((("Please wait for " + toString((getUnlockBalanceBlock(account) - height))) + " blocks to complete.")) | |
369 | + | else if ((getNeutrinoBalance(account) != 0)) | |
370 | + | then throw("Please withdraw locked Neutrinos first.") | |
371 | + | else { | |
372 | + | let neutrinoAmount = pmt.amount | |
373 | + | let newSwapNeutrinoLockedBalance = (swapNeutrinoLockedBalance + neutrinoAmount) | |
374 | + | WriteSet([DataEntry(getNeutrinoBalanceKey(account), (getNeutrinoBalance(account) + neutrinoAmount)), DataEntry(getBalanceUnlockBlockKey(account), (height + balanceLockInterval)), DataEntry(SwapNeutrinoLockedBalanceKey, newSwapNeutrinoLockedBalance), DataEntry(IsRebalanceKey, if ((reserveWithoutLeasing >= convertNeutrinoToWaves(newSwapNeutrinoLockedBalance))) | |
375 | + | then false | |
376 | + | else true)]) | |
377 | + | } | |
378 | + | } | |
379 | + | ||
380 | + | ||
381 | + | ||
382 | + | @Callable(i) | |
383 | + | func withdraw (account,index) = { | |
384 | + | let unlockHeight = getUnlockBalanceBlock(account) | |
385 | + | let neutrinoAmount = getNeutrinoBalance(account) | |
386 | + | let indexHeight = getHeightPriceByIndex(index) | |
387 | + | let nextIndexHeight = getHeightPriceByIndex((index + 1)) | |
388 | + | let indexPrice = getPriceHistory(indexHeight) | |
389 | + | let amount = convertNeutrinoToWavesByPrice(neutrinoAmount, indexPrice) | |
390 | + | if (isBlocked) | |
391 | + | then throw("The contract is blocked by EMERGENCY SHUTDOWN. Please wait for reactivation by emergency oracles.") | |
392 | + | else if ((0 >= amount)) | |
393 | + | then throw("No funds are available for withdrawal.") | |
394 | + | else if ((unlockHeight > height)) | |
395 | + | then throw((("Please wait for the " + toString(unlockHeight)) + " block height to complete withdrawal.")) | |
396 | + | else if (if (if ((index > priceIndex)) | |
397 | + | then true | |
398 | + | else (indexHeight > unlockHeight)) | |
399 | + | then true | |
400 | + | else if ((nextIndexHeight != 0)) | |
401 | + | then (unlockHeight >= nextIndexHeight) | |
402 | + | else false) | |
403 | + | then throw("Invalid price history index.") | |
404 | + | else ScriptResult(WriteSet([DataEntry(getNeutrinoBalanceKey(account), (getNeutrinoBalance(account) - neutrinoAmount)), DataEntry(SwapNeutrinoLockedBalanceKey, (swapNeutrinoLockedBalance - neutrinoAmount))]), TransferSet([ScriptTransfer(addressFromStringValue(account), amount, unit)])) | |
405 | + | } | |
406 | + | ||
407 | + | ||
408 | + | ||
409 | + | @Callable(i) | |
410 | + | func generateBond () = { | |
411 | + | let balanceAuction = assetBalance(addressFromStringValue(auctionContract), bondAssetId) | |
412 | + | let amount = (convertNeutrinoToBond(deficit) - balanceAuction) | |
413 | + | if (isBlocked) | |
414 | + | then throw("The contract is blocked by EMERGENCY SHUTDOWN. Please wait for reactivation by emergency oracles.") | |
415 | + | else if ((amount >= ((neutrinoSupply * DEFICITOFFSET) / 100))) | |
416 | + | then TransferSet([ScriptTransfer(addressFromStringValue(auctionContract), amount, bondAssetId)]) | |
417 | + | else throw("Bonds were already generated or there is not enough deficit.") | |
418 | + | } | |
419 | + | ||
420 | + | ||
421 | + | ||
422 | + | @Callable(i) | |
423 | + | func setOrder () = { | |
424 | + | let pmt = extract(i.payment) | |
425 | + | let newOrderId = toBase58String(keccak256(((toBytes(pmt.amount) + i.caller.bytes) + toBytes(height)))) | |
426 | + | if ((pmt.assetId != bondAssetId)) | |
427 | + | then throw("Can use appropriate Neutrino Bond tokens only.") | |
428 | + | else if ((getOrderOwner(newOrderId) != "")) | |
429 | + | then throw("This order already exists.") | |
430 | + | else WriteSet([DataEntry(OrderbookKey, addOrder(newOrderId)), DataEntry(getOrderTotalKey(newOrderId), pmt.amount), DataEntry(getOrderOwnerKey(newOrderId), toString(i.caller)), DataEntry(getOrderHeightKey(newOrderId), height), DataEntry(getOrderStatusKey(newOrderId), NEW)]) | |
431 | + | } | |
432 | + | ||
433 | + | ||
434 | + | ||
435 | + | @Callable(i) | |
436 | + | func cancelOrder (orderId) = { | |
437 | + | let owner = getOrderOwner(orderId) | |
438 | + | let amount = (getOrderTotal(orderId) - getOrderFilledTotal(orderId)) | |
439 | + | if ((owner != toString(i.caller))) | |
440 | + | then throw("Only the owner of bond liquidation request can cancel it.") | |
441 | + | else if ((getOrderStatus(orderId) != NEW)) | |
442 | + | then throw("Invalid liquidation request status.") | |
443 | + | else ScriptResult(WriteSet([DataEntry(OrderbookKey, dropOrder(orderId)), DataEntry(getOrderStatusKey(orderId), CANCELED)]), TransferSet([ScriptTransfer(i.caller, amount, bondAssetId)])) | |
444 | + | } | |
445 | + | ||
446 | + | ||
447 | + | ||
448 | + | @Callable(i) | |
449 | + | func executeOrder () = { | |
450 | + | let orderId = split(orderbook, LISTSPLITSYMBOL)[0] | |
451 | + | let orderTotal = getOrderTotal(orderId) | |
452 | + | let orderOwner = getOrderOwner(orderId) | |
453 | + | let filledTotal = getOrderFilledTotal(orderId) | |
454 | + | let surplusBond = convertNeutrinoToBond(surplus) | |
455 | + | if (isBlocked) | |
456 | + | then throw("The contract is blocked by EMERGENCY SHUTDOWN. Please wait for reactivation by emergency oracles.") | |
457 | + | else if ((0 >= surplusBond)) | |
458 | + | then throw("There is no surplus on the smart contract at the moment.") | |
459 | + | else if ((orderbook == "")) | |
460 | + | then throw("The orderbook is empty.") | |
461 | + | else { | |
462 | + | let amount = (orderTotal - filledTotal) | |
463 | + | let status = if ((surplusBond >= amount)) | |
464 | + | then FILLED | |
465 | + | else NEW | |
466 | + | let newFilledTotal = if ((surplusBond >= amount)) | |
467 | + | then amount | |
468 | + | else surplusBond | |
469 | + | ScriptResult(WriteSet([DataEntry(OrderbookKey, if ((surplusBond >= amount)) | |
470 | + | then dropOrder(orderId) | |
471 | + | else orderbook), DataEntry(getOrderFilledTotalKey(orderId), (filledTotal + newFilledTotal)), DataEntry(getOrderStatusKey(orderId), status)]), TransferSet([ScriptTransfer(addressFromStringValue(orderOwner), convertBondToNeutrino(newFilledTotal), neutrinoAssetId)])) | |
472 | + | } | |
473 | + | } | |
474 | + | ||
475 | + | ||
476 | + | ||
477 | + | @Callable(i) | |
478 | + | func transfer (account) = { | |
479 | + | let pmt = extract(i.payment) | |
480 | + | TransferSet([ScriptTransfer(addressFromStringValue(account), pmt.amount, pmt.assetId)]) | |
481 | + | } | |
482 | + | ||
483 | + | ||
484 | + | ||
485 | + | @Callable(i) | |
486 | + | func nodeReward () = { | |
487 | + | let pmt = value(i.payment) | |
488 | + | if ((i.caller != addressFromStringValue(nodeAddress))) | |
489 | + | then throw("Only a node account is able to transfer staking rewards.") | |
490 | + | else if (isDefined(pmt.assetId)) | |
491 | + | then throw("Only Waves tokens are allowed.") | |
492 | + | else { | |
493 | + | let amount = convertWavesToNeutrino(pmt.amount) | |
494 | + | let newRpdSyncIndex = (rpdSyncIndex + 1) | |
495 | + | ScriptResult(WriteSet([DataEntry(RPDSyncIndexKey, newRpdSyncIndex), DataEntry(getRPDProfitKey(rpdSyncIndex), amount), DataEntry(getRPDSnapshotContractBalanceKey(rpdSyncIndex, neutrinoAssetId), getRPDContractBalance(neutrinoAssetId))]), TransferSet([ScriptTransfer(addressFromStringValue(rpdContract), amount, neutrinoAssetId)])) | |
496 | + | } | |
497 | + | } | |
498 | + | ||
499 | + | ||
500 | + | ||
501 | + | @Callable(i) | |
502 | + | func registrationLeaseTx (senderPublicKey,fee,timestamp,leaseTxHash) = { | |
503 | + | let totalFreeReserve = (((reserve * LEASINGSHARE) / 100) - convertNeutrinoToWaves(swapNeutrinoLockedBalance)) | |
504 | + | let amount = (totalFreeReserve / LEASINGTXCOUNT) | |
505 | + | let txBytes = (((((base58'3h1H' + fromBase58String(senderPublicKey)) + fromBase58String(nodeAddress)) + toBytes(amount)) + toBytes(fee)) + toBytes(timestamp)) | |
506 | + | let txHashBytes = blake2b256(txBytes) | |
507 | + | let txHash = toBase58String(txHashBytes) | |
508 | + | let pmt = extract(i.payment) | |
509 | + | if ((toString(i.caller) == nodeOracleProviderKey)) | |
510 | + | then throw("invalid caller") | |
511 | + | else if (isDefined(pmt.assetId)) | |
512 | + | then throw("invalid payment asset") | |
513 | + | else if ((leaseTxHash != txHash)) | |
514 | + | then throw((("invalid tx hash (amount: " + toString(amount)) + ")")) | |
515 | + | else if ((leasingTxCount >= LEASINGTXCOUNT)) | |
516 | + | then throw("the number of leasing transactions exceeds the limit") | |
517 | + | else if ((this != addressFromPublicKey(fromBase58String(senderPublicKey)))) | |
518 | + | then throw("invalid public key") | |
519 | + | else if (if ((lastBlock.timestamp > timestamp)) | |
520 | + | then true | |
521 | + | else (timestamp > (lastBlock.timestamp + 5400000))) | |
522 | + | then throw((("invalid timestamp (lastBlock: " + toString(lastBlock.timestamp)) + ")")) | |
523 | + | else if ((getLeaseTxStatus(txHash) != "")) | |
524 | + | then throw("This tx already exists.") | |
525 | + | else if ((pmt.amount != (fee * 2))) | |
526 | + | then throw("invalid payment amount") | |
527 | + | else if (if ((fee > 1000000)) | |
528 | + | then true | |
529 | + | else (500000 > fee)) | |
530 | + | then throw("invalid fee") | |
531 | + | else if (((totalFreeReserve - (leasingAmount + amount)) > reserveWithoutLeasing)) | |
532 | + | then throw((("invalid amount(result:" + toString(((totalFreeReserve - (leasingAmount + amount)) > reserveWithoutLeasing))) + ")")) | |
533 | + | else WriteSet([DataEntry(getCancelLeaseTxReserveFeeKey(txHash), fee), DataEntry(LeasingTxCountKey, if ((getLeaseTxStatus(txHash) == "")) | |
534 | + | then (leasingTxCount + 1) | |
535 | + | else leasingTxCount), DataEntry(LeasingAmountKey, (leasingAmount + amount)), DataEntry(LeasingExpireBlockKey, if ((height > leasingExpireBlock)) | |
536 | + | then (height + leasingInterval) | |
537 | + | else leasingExpireBlock), DataEntry(getLeaseTxStatusKey(txHash), NEW), DataEntry(getLeaseTxExpireSendBlockKey(txHash), (height + SENDTXEXPIRE)), DataEntry(getLeaseTxAmountByHashKey(txHash), amount), DataEntry(getLeaseTxBytesByHashKey(txHash), toBase64String(txBytes))]) | |
538 | + | } | |
539 | + | ||
540 | + | ||
541 | + | ||
542 | + | @Callable(i) | |
543 | + | func cancelStuckLeaseTx (txHash) = if (if (if ((getLeaseTxStatus(txHash) == NEW)) | |
544 | + | then !(isDefined(transactionHeightById(fromBase58String(txHash)))) | |
545 | + | else false) | |
546 | + | then (height > getLeaseTxExpireSendBlock(txHash)) | |
547 | + | else false) | |
548 | + | then { | |
549 | + | let amount = getLeaseTxAmountByHash(txHash) | |
550 | + | WriteSet([DataEntry(LeasingTxCountKey, (leasingTxCount - 1)), DataEntry(LeasingAmountKey, (leasingAmount - amount)), DataEntry(getLeaseTxStatusKey(txHash), CANCELED), DataEntry(IsRebalanceKey, if (((reserveWithoutLeasing - amount) >= convertNeutrinoToWaves(swapNeutrinoLockedBalance))) | |
551 | + | then false | |
552 | + | else true)]) | |
553 | + | } | |
554 | + | else throw("invalid tx hash") | |
555 | + | ||
556 | + | ||
557 | + | ||
558 | + | @Callable(i) | |
559 | + | func registrationUnleaseTx (chainIdString,senderPublicKey,fee,timestamp,leaseTxHash) = { | |
560 | + | let txBytes = (((((base58'gm' + toBytes(chainIdString)) + fromBase58String(senderPublicKey)) + toBytes(fee)) + toBytes(timestamp)) + fromBase58String(leaseTxHash)) | |
561 | + | let txHash = blake2b256(txBytes) | |
562 | + | if ((getLeaseTxStatus(leaseTxHash) != NEW)) | |
563 | + | then throw("invalid tx status") | |
564 | + | else if ((this != addressFromPublicKey(fromBase58String(senderPublicKey)))) | |
565 | + | then throw("invalid pubKey") | |
566 | + | else if (!(isDefined(transactionHeightById(txHash)))) | |
567 | + | then throw("blockchain does not contain this transaction") | |
568 | + | else { | |
569 | + | let amount = getLeaseTxAmountByHash(leaseTxHash) | |
570 | + | WriteSet([DataEntry(LeasingTxCountKey, (leasingTxCount - 1)), DataEntry(LeasingAmountKey, (leasingAmount - amount)), DataEntry(getLeaseTxStatusKey(leaseTxHash), CANCELED), DataEntry(IsRebalanceKey, if (((reserveWithoutLeasing - amount) >= convertNeutrinoToWaves(swapNeutrinoLockedBalance))) | |
571 | + | then false | |
572 | + | else true)]) | |
573 | + | } | |
574 | + | } | |
575 | + | ||
576 | + | ||
577 | + | @Verifier(tx) | |
578 | + | func verify () = { | |
579 | + | let id = toBase58String(tx.id) | |
580 | + | match tx { | |
581 | + | case leaseTx: LeaseTransaction => | |
582 | + | if (if ((leasingExpireBlock >= height)) | |
583 | + | then (getLeaseTxExpireSendBlock(id) >= height) | |
584 | + | else false) | |
585 | + | then (getLeaseTxStatus(id) == NEW) | |
586 | + | else false | |
587 | + | case unleaseTx: LeaseCancelTransaction => | |
588 | + | let leaseId = toBase58String(unleaseTx.leaseId) | |
589 | + | if (if (if ((height > leasingExpireBlock)) | |
590 | + | then true | |
591 | + | else isRebalance) | |
592 | + | then (unleaseTx.fee == getCancelLeaseTxReserveFee(leaseId)) | |
593 | + | else false) | |
594 | + | then (getLeaseTxStatus(leaseId) == NEW) | |
595 | + | else false | |
596 | + | case _ => | |
597 | + | sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey) | |
598 | + | } | |
599 | + | } | |
600 | + |
github/deemru/w8io/169f3d6 39.92 ms ◑