tx · C6UTAtzNVPR5uJnJyj1MchNwbnGPonUbF9UWjY9AcrJa

3N3KGW7Gbu5krHUEpi51GTFvTTEVyYvt1vM:  -0.10000000 Waves

2020.04.01 09:10 [934694] smart account 3N3KGW7Gbu5krHUEpi51GTFvTTEVyYvt1vM > SELF 0.00000000 Waves

{ "type": 13, "id": "C6UTAtzNVPR5uJnJyj1MchNwbnGPonUbF9UWjY9AcrJa", "fee": 10000000, "feeAssetId": null, "timestamp": 1585721508465, "version": 1, "sender": "3N3KGW7Gbu5krHUEpi51GTFvTTEVyYvt1vM", "senderPublicKey": "BSLyTW7cVFUAbFbgLdob7BDLUP4VSSnB3guBg4Gss9yM", "proofs": [ "3qr1CZewXVuVbASP72cr8JYHxG5VTkqjXqhBgr4SvXZaaotKYSvrYAsQCTQzSAbtJfiHpVds8zPwMMLYQV5XB32R" ], "script": "base64:AAIDAAAAAAAAAA8IARIECgIBCBIDCgEIEgAAAAA3AQAAAA5nZXROdW1iZXJCeUtleQAAAAEAAAADa2V5BAAAAAckbWF0Y2gwCQAEGgAAAAIFAAAABHRoaXMFAAAAA2tleQMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAADSW50BAAAAAFhBQAAAAckbWF0Y2gwBQAAAAFhAAAAAAAAAAAAAQAAAA5nZXRTdHJpbmdCeUtleQAAAAEAAAADa2V5BAAAAAckbWF0Y2gwCQAEHQAAAAIFAAAABHRoaXMFAAAAA2tleQMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAAGU3RyaW5nBAAAAAFhBQAAAAckbWF0Y2gwBQAAAAFhAgAAAAABAAAAFmdldEJvb2xCeUFkZHJlc3NBbmRLZXkAAAACAAAAB2FkZHJlc3MAAAADa2V5BAAAAAckbWF0Y2gwCQAEGwAAAAIFAAAAB2FkZHJlc3MFAAAAA2tleQMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAAHQm9vbGVhbgQAAAABYQUAAAAHJG1hdGNoMAUAAAABYQcBAAAAGGdldFN0cmluZ0J5Q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AAKZmlyc3RPcmRlcgkABEwAAAACCQEAAAAJRGF0YUVudHJ5AAAAAgUAAAANRmlyc3RPcmRlcktleQMJAAAAAAAAAgUAAAAJbmV3U3RhdHVzBQAAAAZGSUxMRUQFAAAACW5leHRPcmRlcgUAAAAKZmlyc3RPcmRlcgkABEwAAAACCQEAAAAJRGF0YUVudHJ5AAAAAgkBAAAAFmdldE9yZGVyRmlsbGVkVG90YWxLZXkAAAABBQAAAApmaXJzdE9yZGVyCQAAZAAAAAIFAAAAC2ZpbGxlZFRvdGFsBQAAABt0b3RhbE9yZGVyV2F2ZWxldGVzUmVxdWlyZWQJAARMAAAAAgkBAAAACURhdGFFbnRyeQAAAAIJAQAAABFnZXRPcmRlclN0YXR1c0tleQAAAAEFAAAACmZpcnN0T3JkZXIFAAAACW5ld1N0YXR1cwUAAAADbmlsCQEAAAALVHJhbnNmZXJTZXQAAAABCQAETAAAAAIJAQAAAA5TY3JpcHRUcmFuc2ZlcgAAAAMJAQAAABxAZXh0clVzZXIoYWRkcmVzc0Zyb21TdHJpbmcpAAAAAQkBAAAADWdldE9yZGVyT3duZXIAAAABBQAAAApmaXJzdE9yZGVyBQAAABNmaWxsYWJsZU9yZGVyQW1vdW50BQAAAAtib25kQXNzZXRJZAkABEwAAAACCQEAAAAOU2NyaXB0VHJhbnNmZXIAAAADBQAAABBuZXV0cmlub0NvbnRyYWN0BQAAABt0b3RhbE9yZGVyV2F2ZWxldGVzUmVxdWlyZWQFAAAABHVuaXQFAAAAA25pbAAAAADEo8U3", "chainId": 84, "height": 934694, "spentComplexity": 0 } View: original | compacted Prev: CJQyypAkXbbjcH5jVGjqRpjqdBitA8aZ193Jpwbn9frM Next: none Diff:
OldNewDifferences
4747
4848 let PERCENTACCURACY = 1000
4949
50-let MINORDERTOTAL = (10 * WAVELET)
50+let MINORDERTOTAL = (1 * WAVELET)
5151
5252 let MAXROI = 100
5353
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 3 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 func getNumberByKey (key) = match getInteger(this, key) {
55 case a: Int =>
66 a
77 case _ =>
88 0
99 }
1010
1111
1212 func getStringByKey (key) = match getString(this, key) {
1313 case a: String =>
1414 a
1515 case _ =>
1616 ""
1717 }
1818
1919
2020 func getBoolByAddressAndKey (address,key) = match getBoolean(address, key) {
2121 case a: Boolean =>
2222 a
2323 case _ =>
2424 false
2525 }
2626
2727
2828 func getStringByAddressAndKey (address,key) = match getString(address, key) {
2929 case a: String =>
3030 a
3131 case _ =>
3232 ""
3333 }
3434
3535
3636 func getNumberByAddressAndKey (address,key) = match getInteger(address, key) {
3737 case a: Int =>
3838 a
3939 case _ =>
4040 0
4141 }
4242
4343
4444 let WAVELET = 100000000
4545
4646 let PAULI = 1000000
4747
4848 let PERCENTACCURACY = 1000
4949
50-let MINORDERTOTAL = (10 * WAVELET)
50+let MINORDERTOTAL = (1 * WAVELET)
5151
5252 let MAXROI = 100
5353
5454 let CANCELED = "canceled"
5555
5656 let NEW = "new"
5757
5858 let FILLED = "filled"
5959
6060 let NeutrinoContractKey = "neutrino_contract"
6161
6262 let PriceKey = "price"
6363
6464 let BondAssetIdKey = "bond_asset_id"
6565
6666 let NeutrinoAssetIdKey = "neutrino_asset_id"
6767
6868 let ControlContractKey = "control_contract"
6969
7070 let BalanceLockedkKey = "balance_lock_"
7171
7272 let WavesLockedBalanceKey = (BalanceLockedkKey + "waves")
7373
7474 let NeutrinoLockedBalanceKey = (BalanceLockedkKey + "neutrino")
7575
7676 let LiquidationContractKey = "liquidation_contract"
7777
7878 let FirstOrderKey = "order_first"
7979
8080 func getRoiByOrderIdKey (orderId) = ("debug_order_roi_" + orderId)
8181
8282
8383 func getOrderPriceKey (orderId) = ("order_price_" + orderId)
8484
8585
8686 func getOrderTotalKey (orderId) = ("order_total_" + orderId)
8787
8888
8989 func getOrderOwnerKey (orderId) = ("order_owner_" + orderId)
9090
9191
9292 func getOrderHeightKey (orderId) = ("order_height_" + orderId)
9393
9494
9595 func getOrderStatusKey (orderId) = ("order_status_" + orderId)
9696
9797
9898 func getOrderFilledTotalKey (orderId) = ("order_filled_total_" + orderId)
9999
100100
101101 func getPrevOrderKey (orderId) = ("order_prev_" + orderId)
102102
103103
104104 func getNextOrderKey (orderId) = ("order_next_" + orderId)
105105
106106
107107 func convertNeutrinoToWaves (amount,price) = fraction(fraction(amount, 100, price), WAVELET, PAULI)
108108
109109
110110 func convertWavesToNeutrino (amount,price) = fraction(fraction(amount, price, 100), PAULI, WAVELET)
111111
112112
113113 func convertWavesToBond (amount,price) = convertWavesToNeutrino(amount, price)
114114
115115
116116 func convertBondToWaves (amount,price) = convertNeutrinoToWaves(amount, price)
117117
118118
119119 let neutrinoContract = addressFromStringValue("3MydqRdWHFcvU4ZogmgkGNHt8fqYiCRazbn")
120120
121121 let controlContract = addressFromStringValue("3MqY3tM5bgwds1ugNQGJziL8VJVvjTiNccH")
122122
123123 let liquidationContract = addressFromStringValue("3MyiJb9yZnpyXJADhdEoNk3MT3FHKmbYRJX")
124124
125125 let neutrinoAssetId = fromBase58String("4EUBRLwFstXZhMHWJPk9ZnyhHT4VVFCSZb6p6K5hySjd")
126126
127127 let bondAssetId = fromBase58String("Qh28HvUAcFboD1GsAcyURQjNW6mdpuGvXVgFS9e3CzC")
128128
129129 let isBlocked = getBoolByAddressAndKey(controlContract, "is_blocked")
130130
131131 let currentPrice = getNumberByAddressAndKey(controlContract, PriceKey)
132132
133133 let neutrinoLockedBalance = getNumberByAddressAndKey(neutrinoContract, NeutrinoLockedBalanceKey)
134134
135135 let reserve = (wavesBalance(neutrinoContract) - getNumberByAddressAndKey(neutrinoContract, WavesLockedBalanceKey))
136136
137137 let neutrinoSupply = (((neutrinoLockedBalance + extract(assetInfo(neutrinoAssetId)).quantity) - assetBalance(neutrinoContract, neutrinoAssetId)) - assetBalance(liquidationContract, neutrinoAssetId))
138138
139139 let deficit = (neutrinoSupply - convertWavesToNeutrino(reserve, currentPrice))
140140
141141 let firstOrder = getStringByKey(FirstOrderKey)
142142
143143 func getOrderPrice (id) = getNumberByKey(getOrderPriceKey(id))
144144
145145
146146 func getOrderTotal (id) = getNumberByKey(getOrderTotalKey(id))
147147
148148
149149 func getOrderOwner (id) = getStringByKey(getOrderOwnerKey(id))
150150
151151
152152 func getOrderStatus (id) = getStringByKey(getOrderStatusKey(id))
153153
154154
155155 func getOrderFilledTotal (id) = getNumberByKey(getOrderFilledTotalKey(id))
156156
157157
158158 func getPrevOrder (id) = getStringByKey(getPrevOrderKey(id))
159159
160160
161161 func getNextOrder (id) = getStringByKey(getNextOrderKey(id))
162162
163163
164164 @Callable(i)
165165 func addBuyBondOrder (price,prevOrder) = {
166166 let pmt = extract(i.payment)
167167 let orderId = toBase58String(keccak256(((((toBytes(price) + toBytes(pmt.amount)) + i.caller.bytes) + toBytes(height)) + i.transactionId)))
168168 let priceWavesByBondCents = fraction(100, 100, price)
169169 let roi = fraction((priceWavesByBondCents - currentPrice), 100, currentPrice)
170170 if (isBlocked)
171171 then throw("contract is blocked by EMERGENCY SHUTDOWN actions untill reactivation by emergency oracles")
172172 else if ((0 >= deficit))
173173 then throw("there is no ability to add order during proficit")
174174 else if ((MINORDERTOTAL > pmt.amount))
175175 then throw(("min order total equals " + toString(MINORDERTOTAL)))
176176 else if ((roi > MAXROI))
177177 then throw("max setOrder ROI is 100%")
178178 else if ((0 >= roi))
179179 then throw("min setOrder ROI is more than 0%")
180180 else if (isDefined(pmt.assetId))
181181 then throw("can use waves only")
182182 else if ((0 >= price))
183183 then throw("price less zero")
184184 else if ((getOrderOwner(orderId) != ""))
185185 then throw("order exists")
186186 else if (if ((prevOrder != ""))
187187 then (getOrderStatus(prevOrder) != NEW)
188188 else false)
189189 then throw("prev order status is not new")
190190 else {
191191 let owner = toString(i.caller)
192192 let nextOrder = if ((prevOrder == ""))
193193 then firstOrder
194194 else getNextOrder(prevOrder)
195195 let nextOrderRoi = getNumberByKey(getRoiByOrderIdKey(nextOrder))
196196 let isNextOrderError = if (if ((nextOrder != ""))
197197 then (roi >= nextOrderRoi)
198198 else false)
199199 then true
200200 else false
201201 let prevOrderRoi = getNumberByKey(getRoiByOrderIdKey(prevOrder))
202202 let isPrevOrderError = if (if ((prevOrder != ""))
203203 then (prevOrderRoi > roi)
204204 else false)
205205 then true
206206 else false
207207 if (if (isNextOrderError)
208208 then true
209209 else isPrevOrderError)
210210 then throw(((("invalid order isPrevOrderError:" + toString(isPrevOrderError)) + " isNextOrderError:") + toString(isNextOrderError)))
211211 else WriteSet([DataEntry(getPrevOrderKey(orderId), prevOrder), DataEntry(getNextOrderKey(orderId), nextOrder), DataEntry(getNextOrderKey(prevOrder), if ((prevOrder == ""))
212212 then ""
213213 else orderId), DataEntry(getPrevOrderKey(nextOrder), if ((nextOrder == ""))
214214 then ""
215215 else orderId), DataEntry(FirstOrderKey, if (if ((firstOrder == ""))
216216 then true
217217 else (firstOrder == nextOrder))
218218 then orderId
219219 else firstOrder), DataEntry(getOrderPriceKey(orderId), price), DataEntry(getOrderTotalKey(orderId), pmt.amount), DataEntry(getOrderOwnerKey(orderId), owner), DataEntry(getOrderHeightKey(orderId), height), DataEntry(getOrderStatusKey(orderId), NEW), DataEntry(("debug_order_currentPrice_" + orderId), currentPrice), DataEntry(getRoiByOrderIdKey(orderId), roi)])
220220 }
221221 }
222222
223223
224224
225225 @Callable(i)
226226 func cancelOrder (orderId) = {
227227 let owner = getOrderOwner(orderId)
228228 let amount = (getOrderTotal(orderId) - getOrderFilledTotal(orderId))
229229 let caller = toString(i.caller)
230230 let nextOrder = getNextOrder(orderId)
231231 let prevOrder = getPrevOrder(orderId)
232232 if (isBlocked)
233233 then throw("contract is blocked by EMERGENCY SHUTDOWN actions untill reactivation by emergency oracles")
234234 else if ((owner != caller))
235235 then throw("permission denied")
236236 else if ((getOrderStatus(orderId) != NEW))
237237 then throw("invalid order status")
238238 else ScriptResult(WriteSet([DataEntry(FirstOrderKey, if ((firstOrder == orderId))
239239 then nextOrder
240240 else firstOrder), DataEntry(getNextOrderKey(prevOrder), nextOrder), DataEntry(getPrevOrderKey(nextOrder), prevOrder), DataEntry(getOrderStatusKey(orderId), CANCELED)]), TransferSet([ScriptTransfer(i.caller, amount, unit)]))
241241 }
242242
243243
244244
245245 @Callable(i)
246246 func sellBond () = {
247247 let bondBalance = assetBalance(this, bondAssetId)
248248 let deficitPositive = if ((0 >= deficit))
249249 then 0
250250 else deficit
251251 let bondAmount = if ((deficitPositive >= bondBalance))
252252 then bondBalance
253253 else deficitPositive
254254 let returnAmount = if ((deficitPositive >= bondBalance))
255255 then 0
256256 else (bondBalance - deficitPositive)
257257 if (if ((deficitPositive == 0))
258258 then (bondBalance == 0)
259259 else false)
260260 then throw("without deficit")
261261 else if ((bondBalance == 0))
262262 then throw("without bonds to sell")
263263 else if ((returnAmount > 0))
264264 then TransferSet([ScriptTransfer(neutrinoContract, returnAmount, bondAssetId)])
265265 else if ((firstOrder == ""))
266266 then throw("empty orderbook")
267267 else {
268268 let nextOrder = getNextOrder(firstOrder)
269269 let filledTotal = getOrderFilledTotal(firstOrder)
270270 let orderPrice = getOrderPrice(firstOrder)
271271 let priceWavesByBondCents = fraction(100, 100, orderPrice)
272272 let roi = getNumberByKey(getRoiByOrderIdKey(firstOrder))
273273 let remainedTotal = (getOrderTotal(firstOrder) - filledTotal)
274274 let amountToExecuteOrder = convertWavesToBond(remainedTotal, priceWavesByBondCents)
275275 let fillOrderCondition = (bondAmount >= amountToExecuteOrder)
276276 let fillableOrderAmount = if (fillOrderCondition)
277277 then amountToExecuteOrder
278278 else bondAmount
279279 let totalOrderWaveletesRequired = convertBondToWaves(fillableOrderAmount, priceWavesByBondCents)
280280 if (if ((roi > fraction(deficit, 100, neutrinoSupply)))
281281 then true
282282 else (0 >= deficitPositive))
283283 then throw(("deficit should be higther or equal than roi: " + toString(roi)))
284284 else if ((amountToExecuteOrder == 0))
285285 then ScriptResult(WriteSet([DataEntry(FirstOrderKey, nextOrder), DataEntry(getPrevOrderKey(nextOrder), ""), DataEntry(FirstOrderKey, nextOrder), DataEntry(getOrderStatusKey(firstOrder), FILLED)]), TransferSet([ScriptTransfer(addressFromStringValue(getOrderOwner(firstOrder)), remainedTotal, unit)]))
286286 else if ((totalOrderWaveletesRequired == 0))
287287 then throw("cannot fill order at the moment")
288288 else {
289289 let newStatus = if (if (fillOrderCondition)
290290 then (remainedTotal == 0)
291291 else false)
292292 then FILLED
293293 else NEW
294294 ScriptResult(WriteSet([DataEntry(getPrevOrderKey(nextOrder), if ((newStatus == FILLED))
295295 then ""
296296 else firstOrder), DataEntry(FirstOrderKey, if ((newStatus == FILLED))
297297 then nextOrder
298298 else firstOrder), DataEntry(getOrderFilledTotalKey(firstOrder), (filledTotal + totalOrderWaveletesRequired)), DataEntry(getOrderStatusKey(firstOrder), newStatus)]), TransferSet([ScriptTransfer(addressFromStringValue(getOrderOwner(firstOrder)), fillableOrderAmount, bondAssetId), ScriptTransfer(neutrinoContract, totalOrderWaveletesRequired, unit)]))
299299 }
300300 }
301301 }
302302
303303

github/deemru/w8io/169f3d6 
55.03 ms