tx · 6xM5zWEpK4CCnv5qo7LurEudQ32HejhBGrRsi3QLTE7K

3MrtHeXquGPcRd3YjJQHfY1Ss6oSDpfxGuL:  -0.01400000 Waves

2019.09.17 20:45 [680559] smart account 3MrtHeXquGPcRd3YjJQHfY1Ss6oSDpfxGuL > SELF 0.00000000 Waves

{ "type": 13, "id": "6xM5zWEpK4CCnv5qo7LurEudQ32HejhBGrRsi3QLTE7K", "fee": 1400000, "feeAssetId": null, "timestamp": 1568742317634, "version": 1, "sender": "3MrtHeXquGPcRd3YjJQHfY1Ss6oSDpfxGuL", "senderPublicKey": "3nmDHSgwcZ79tNbGjppGBY9MbYm4qLZEJcZ32D2WmxkG", "proofs": [ "3611wtXrjGYD9d11QhKVEg6XRL63mVx311xUNYMcZBR9cApRzYrtHcK2UFMAh3wyKC1Rwim9Rw4nRfmDXDEKsRAE" ], "script": "base64:AAIDAAAAAAAAAAAAAABFAQAAAA5nZXROdW1iZXJCeUtleQAAAAEAAAADa2V5BAAAAAckbWF0Y2gwCQAEGgAAAAIFAAAABHRoaXMFAAAAA2tleQMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAADSW50BAAAAAFhBQAAAAckbWF0Y2gwBQAAAAFhAAAAAAAAAAAAAQAAAA5nZXRTdHJpbmdCeUtleQAAAAEAAAADa2V5BAAAAAckbWF0Y2gwCQAEHQAAAAIFAAAABHRoaXMFAAAAA2tleQMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAAGU3RyaW5nBAAAAAFhBQAAAAckbWF0Y2gwBQAAAAFhAgAAAAABAAAADGdldEJvb2xCeUtleQAAAAEAAAADa2V5BAAAAAckbWF0Y2gwCQAEGwAAAAIFAAAABHRoaXMFAAAAA2tleQMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAAHQm9vbGVhbgQAAAABYQUAAAAHJG1hdGNoMAUAAAABYQcBAAAAGGdldE51bWJlckJ5S2V5QW5kQWRkcmVzcwAAAAIAAAAHYWRkcmVzcwAAAANrZXkEAAAABy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QkAAGUAAAACBQAAAApvcmRlclRvdGFsCQEAAAAVY29udmVydE5ldXRyaW5vVG9Cb25kAAAAAQUAAAAHc3VycGx1cwkBAAAADFNjcmlwdFJlc3VsdAAAAAIJAQAAAAhXcml0ZVNldAAAAAEJAARMAAAAAgkBAAAACURhdGFFbnRyeQAAAAIFAAAAEU9yZGVyYm9va1RvdGFsS2V5CQAAZQAAAAIFAAAADm9yZGVyYm9va1RvdGFsAwkAAGcAAAACBQAAAAdzdXJwbHVzBQAAAApvcmRlclRvdGFsBQAAAApvcmRlclRvdGFsBQAAAAdzdXJwbHVzCQAETAAAAAIJAQAAAAlEYXRhRW50cnkAAAACBQAAAAxPcmRlcmJvb2tLZXkJAAGRAAAAAgkABLUAAAACBQAAAAlvcmRlcmJvb2sJAAEsAAAAAgUAAAAHb3JkZXJJZAUAAAAPTGlzdFNwbGl0U3ltYm9sAAAAAAAAAAABCQAETAAAAAIJAQAAAAlEYXRhRW50cnkAAAACCQABLAAAAAIFAAAADU9yZGVyVG90YWxLZXkFAAAAB29yZGVySWQDCQAAZwAAAAIAAAAAAAAAAAAFAAAABmFtb3VudAAAAAAAAAAAAAUAAAAGYW1vdW50BQAAAANuaWwJAQAAAAtUcmFuc2ZlclNldAAAAAEJAARMAAAAAgkBAAAADlNjcmlwdFRyYW5zZmVyAAAAAwgFAAAAAWkAAAAGY2FsbGVyAwkAAGcAAAACBQAAAAdzdXJwbHVzBQAAAApvcmRlclRvdGFsCQEAAAAVY29udmVydEJvbmRUb05ldXRyaW5vAAAAAQUAAAAKb3JkZXJUb3RhbAUAAAAHc3VycGx1cwUAAAAPbmV1dHJpbm9Bc3NldElkBQAAAANuaWwAAAAABJIh2Q==", "chainId": 84, "height": 680559, "spentComplexity": 0 } View: original | compacted Prev: HPmzcftg1528BsG3TJBPHXbhcsCSiC9cSMNcbrQ9oaSj Next: CtEnN2foodB2NsWbH7ynz619i4T9qUgsPJ4e6fJCJmrD Diff:
OldNewDifferences
232232 @Callable(i)
233233 func withdraw (account) = if (((getBalanceBlock(account) + BalanceLockBlock) > height))
234234 then throw("wait a couple of blocks for withdraw")
235- else ScriptResult(WriteSet([DataEntry((WavesBalanceKey + account), 0), DataEntry((NeutrinoBalanceKey + account), 0)]), TransferSet([ScriptTransfer(i.caller, getNeutrinoBalance(account), neutrinoAssetId), ScriptTransfer(i.caller, getWavesBalance(account), unit)]))
235+ else ScriptResult(WriteSet([DataEntry((WavesBalanceKey + account), 0), DataEntry((NeutrinoBalanceKey + account), 0)]), TransferSet([ScriptTransfer(addressFromStringValue(account), getNeutrinoBalance(account), neutrinoAssetId), ScriptTransfer(addressFromStringValue(account), getWavesBalance(account), unit)]))
236236
237237
238238
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 getBoolByKey (key) = match getBoolean(this, key) {
2121 case a: Boolean =>
2222 a
2323 case _ =>
2424 false
2525 }
2626
2727
2828 func getNumberByKeyAndAddress (address,key) = match getInteger(addressFromStringValue(address), key) {
2929 case a: Int =>
3030 a
3131 case _ =>
3232 0
3333 }
3434
3535
3636 func getStringByKeyAndAddress (address,key) = match getString(addressFromStringValue(address), key) {
3737 case a: String =>
3838 a
3939 case _ =>
4040 ""
4141 }
4242
4343
4444 func getBoolByKeyAndAddress (address,key) = match getBoolean(addressFromStringValue(address), key) {
4545 case a: Boolean =>
4646 a
4747 case _ =>
4848 false
4949 }
5050
5151
5252 let ListSplitSymbol = "_"
5353
5454 let SnapshotBlockExpire = 5
5555
5656 let BalanceLockBlock = 2
5757
5858 let ListDataSplitSymbol = "+"
5959
6060 let Wavelet = 100000000
6161
6262 let MinimalBondOrder = (10 * Wavelet)
6363
6464 let MinimalSurplus = (10 * Wavelet)
6565
6666 let ApplyBlockTimeout = 10
6767
6868 let LeaseContractKey = "lease_contract"
6969
7070 let NeutrinoAssetIdKey = "neutrino_asset_id"
7171
7272 let BondAssetIdKey = "bond_asset_id"
7373
7474 let AuctionContractKey = "auction_contract"
7575
7676 let PriceKey = "price"
7777
7878 let NeutrinoBalanceKey = "neutrino_"
7979
8080 let WavesBalanceKey = "waves_"
8181
8282 let BalanceBlockKey = "balance_block_"
8383
8484 let OrderbookKey = "orderbook"
8585
8686 let OrderTotalKey = "order_total_"
8787
8888 let OrderOwnerKey = "order_owner_"
8989
9090 let OrderHeightKey = "order_height_"
9191
9292 let OrderbookTotalKey = "orderbook_total"
9393
9494 let OrderbookTotalSnapshotKey = "orderbook_total_snapshot"
9595
9696 let SnapshotBlockKey = "snapshot_block"
9797
9898 let OrderbookSnapshotKey = "orderbook_snapshot"
9999
100100 let BondGeneratedBlockKey = "bond_generated_block"
101101
102102 let AccountSnapshotBlockKey = "account_snapshot_block_"
103103
104104 let AccountSnapshotOwnerKey = "account_snapshot_owner_"
105105
106106 let AccountSnapshotAmountKey = "account_snapshot_amount_"
107107
108108 let AccountSnapshotNodeKey = "account_snapshot_node_"
109109
110110 let SnapshotNodeBalanceKey = "snapshot_node_balance_"
111111
112112 let NodeBalanceKey = "node_balance_"
113113
114114 let IsSentNodeBalanceKey = "is_sent_node_balance_"
115115
116116 let NodeProviderStatus = "node_status"
117117
118118 let neutrinoAssetId = fromBase58String(getStringByKey(NeutrinoAssetIdKey))
119119
120120 let price = getNumberByKey(PriceKey)
121121
122122 let reserve = wavesBalance(this)
123123
124124 let neutrinoSupply = {
125125 let info = extract(assetInfo(neutrinoAssetId))
126126 (info.quantity - assetBalance(this, neutrinoAssetId))
127127 }
128128
129129 let orderbookTotal = getNumberByKey(OrderbookTotalKey)
130130
131131 let orderbook = getStringByKey(OrderbookKey)
132132
133133 let snapshotBlock = getNumberByKey(SnapshotBlockKey)
134134
135135 let lastBondGenerated = getNumberByKey(BondGeneratedBlockKey)
136136
137137 let orderbookSnapshot = getStringByKey(OrderbookSnapshotKey)
138138
139139 let orderbookTotalSnapshot = getNumberByKey(OrderbookTotalSnapshotKey)
140140
141141 let bondAssetId = fromBase58String(getStringByKey(BondAssetIdKey))
142142
143143 let auctionContract = getStringByKey(AuctionContractKey)
144144
145145 let leaseContract = getStringByKey(LeaseContractKey)
146146
147147 let bondSupply = {
148148 let info = extract(assetInfo(bondAssetId))
149149 (info.quantity - assetBalance(this, bondAssetId))
150150 }
151151
152152 func getWavesBalance (owner) = getNumberByKey((WavesBalanceKey + owner))
153153
154154
155155 func getNeutrinoBalance (owner) = getNumberByKey((NeutrinoBalanceKey + owner))
156156
157157
158158 func getBalanceBlock (owner) = getNumberByKey((BalanceBlockKey + owner))
159159
160160
161161 func getOrderTotal (id) = getNumberByKey((OrderTotalKey + id))
162162
163163
164164 func getOrderOwner (id) = getStringByKey((OrderOwnerKey + id))
165165
166166
167167 func getAccountSnapshotBlock (id) = getNumberByKey((AccountSnapshotBlockKey + id))
168168
169169
170170 func getAccountSnapshotOwner (id) = getStringByKey((AccountSnapshotOwnerKey + id))
171171
172172
173173 func getAccountSnapshotAmount (id) = getNumberByKey((AccountSnapshotAmountKey + id))
174174
175175
176176 func getNodeBalance (address,block) = getNumberByKeyAndAddress(leaseContract, (((NodeBalanceKey + address) + ListSplitSymbol) + toString(block)))
177177
178178
179179 func isSentNodeBalance (address,block) = getBoolByKey((((IsSentNodeBalanceKey + address) + ListSplitSymbol) + toString(block)))
180180
181181
182182 func convertNeutrinoToWaves (amount) = ((amount * 100) / price)
183183
184184
185185 func convertWavesToNeutrino (amount) = ((amount * price) / 100)
186186
187187
188188 func convertNeutrinoToBond (amount) = (amount / Wavelet)
189189
190190
191191 func convertBondToNeutrino (amount) = (amount * Wavelet)
192192
193193
194194 func convertWavesToBond (amount) = convertNeutrinoToBond(convertWavesToNeutrino(amount))
195195
196196
197197 let surplus = (convertWavesToNeutrino(reserve) - neutrinoSupply)
198198
199199 @Callable(i)
200200 func setCurrentPrice (price) = WriteSet([DataEntry(PriceKey, price), DataEntry(((PriceKey + ListSplitSymbol) + toString(height)), price)])
201201
202202
203203
204204 @Callable(i)
205205 func swapWavesToNeutrino () = {
206206 let pmt = extract(i.payment)
207207 if (isDefined(pmt.assetId))
208208 then throw("can use waves only")
209209 else {
210210 let account = toBase58String(i.caller.bytes)
211211 let amount = convertWavesToNeutrino(pmt.amount)
212212 WriteSet([DataEntry((NeutrinoBalanceKey + toString(i.caller)), (amount + getNeutrinoBalance(account))), DataEntry((BalanceBlockKey + toString(i.caller)), height)])
213213 }
214214 }
215215
216216
217217
218218 @Callable(i)
219219 func swapNeutrinoToWaves () = {
220220 let pmt = extract(i.payment)
221221 if ((pmt.assetId != neutrinoAssetId))
222222 then throw("can use neutrino only")
223223 else {
224224 let account = toBase58String(i.caller.bytes)
225225 let amount = convertNeutrinoToWaves(pmt.amount)
226226 WriteSet([DataEntry((WavesBalanceKey + toString(i.caller)), (amount + getWavesBalance(account))), DataEntry((BalanceBlockKey + toString(i.caller)), height)])
227227 }
228228 }
229229
230230
231231
232232 @Callable(i)
233233 func withdraw (account) = if (((getBalanceBlock(account) + BalanceLockBlock) > height))
234234 then throw("wait a couple of blocks for withdraw")
235- else ScriptResult(WriteSet([DataEntry((WavesBalanceKey + account), 0), DataEntry((NeutrinoBalanceKey + account), 0)]), TransferSet([ScriptTransfer(i.caller, getNeutrinoBalance(account), neutrinoAssetId), ScriptTransfer(i.caller, getWavesBalance(account), unit)]))
235+ else ScriptResult(WriteSet([DataEntry((WavesBalanceKey + account), 0), DataEntry((NeutrinoBalanceKey + account), 0)]), TransferSet([ScriptTransfer(addressFromStringValue(account), getNeutrinoBalance(account), neutrinoAssetId), ScriptTransfer(addressFromStringValue(account), getWavesBalance(account), unit)]))
236236
237237
238238
239239 @Callable(i)
240240 func generateBond () = {
241241 let deficit = (neutrinoSupply - convertWavesToNeutrino(reserve))
242242 let balanceAuction = assetBalance(addressFromStringValue(auctionContract), bondAssetId)
243243 let amount = (convertNeutrinoToBond(deficit) - balanceAuction)
244244 if ((amount > 0))
245245 then TransferSet([ScriptTransfer(addressFromStringValue(auctionContract), amount, bondAssetId)])
246246 else throw(("deficit did not reach the threshold. deficit =" + toString(deficit)))
247247 }
248248
249249
250250
251251 @Callable(i)
252252 func setOrder () = {
253253 let pmt = extract(i.payment)
254254 let newOrderId = toBase58String(keccak256(((toBytes(pmt.amount) + i.caller.bytes) + toBytes(height))))
255255 if ((pmt.assetId != bondAssetId))
256256 then throw("can use bond only")
257257 else if ((getOrderOwner(newOrderId) != ""))
258258 then throw("order exists")
259259 else WriteSet([DataEntry(OrderbookTotalKey, (orderbookTotal + pmt.amount)), DataEntry(OrderbookKey, ((orderbook + newOrderId) + ListSplitSymbol)), DataEntry((OrderTotalKey + newOrderId), pmt.amount), DataEntry((OrderOwnerKey + newOrderId), toString(i.caller)), DataEntry((OrderHeightKey + newOrderId), height)])
260260 }
261261
262262
263263
264264 @Callable(i)
265265 func cancelOrder (orderId) = {
266266 let owner = getOrderOwner(orderId)
267267 let total = getOrderTotal(orderId)
268268 if ((owner != toString(i.caller)))
269269 then throw("permission denied")
270270 else {
271271 let newOrderBookOnePart = split(orderbook, (orderId + ListSplitSymbol))[0]
272272 let newOrderBookTwoPart = split(orderbook, (orderId + ListSplitSymbol))[1]
273273 ScriptResult(WriteSet([DataEntry(OrderbookTotalKey, (orderbookTotal - total)), DataEntry(OrderbookKey, (newOrderBookOnePart + newOrderBookTwoPart)), DataEntry((OrderTotalKey + orderId), 0)]), TransferSet([ScriptTransfer(i.caller, total, unit)]))
274274 }
275275 }
276276
277277
278278
279279 @Callable(i)
280280 func executeOrder () = {
281281 let orderId = split(orderbook, ListSplitSymbol)[0]
282282 let orderTotal = getOrderTotal(orderId)
283283 if ((0 >= surplus))
284284 then throw("surplus is less than zero")
285285 else {
286286 let amount = convertBondToNeutrino((orderTotal - convertNeutrinoToBond(surplus)))
287287 ScriptResult(WriteSet([DataEntry(OrderbookTotalKey, (orderbookTotal - (if ((surplus >= orderTotal))
288288 then orderTotal
289289 else surplus))), DataEntry(OrderbookKey, split(orderbook, (orderId + ListSplitSymbol))[1]), DataEntry((OrderTotalKey + orderId), if ((0 >= amount))
290290 then 0
291291 else amount)]), TransferSet([ScriptTransfer(i.caller, if ((surplus >= orderTotal))
292292 then convertBondToNeutrino(orderTotal)
293293 else surplus, neutrinoAssetId)]))
294294 }
295295 }
296296
297297

github/deemru/w8io/169f3d6 
73.43 ms