tx · 3r65bxJ59VApvRvedfJpznJSvtqaZahAc9NmgM5U4fvW 3N4Pj4MutKVgrmcuX7jgyVGWoBhDyKYFZBj: -0.01400000 Waves 2019.10.03 12:10 [703349] smart account 3N4Pj4MutKVgrmcuX7jgyVGWoBhDyKYFZBj > SELF 0.00000000 Waves
{ "type": 13, "id": "3r65bxJ59VApvRvedfJpznJSvtqaZahAc9NmgM5U4fvW", "fee": 1400000, "feeAssetId": null, "timestamp": 1570093855864, "version": 1, "sender": "3N4Pj4MutKVgrmcuX7jgyVGWoBhDyKYFZBj", "senderPublicKey": "7YuxEiQSearE3DvFS84DXzV5gad9qxsq4bTy633SAYBj", "proofs": [ "49RtmPCuHfbXnsA1yVugWXj28bsvB2ZKqg7nZSvAAZVMbdbSwQr5utVvLudhYj3613z9xBjEzeV1wsWLdhAaWrzA" ], "script": "base64:AAIDAAAAAAAAAAAAAABtAQAAAA5nZXROdW1iZXJCeUtleQAAAAEAAAADa2V5BAAAAAckbWF0Y2gwCQAEGgAAAAIFAAAABHRoaXMFAAAAA2tleQMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAADSW50BAAAAAFhBQAAAAckbWF0Y2gwBQAAAAFhAAAAAAAAAAAAAQAAAA5nZXRTdHJpbmdCeUtleQAAAAEAAAADa2V5BAAAAAckbWF0Y2gwCQAEHQAAAAIFAAAABHRoaXMFAAAAA2tleQMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAAGU3RyaW5nBAAAAAFhBQAAAAckbWF0Y2gwBQAAAAFhAgAAAAABAAAADGdldEJvb2xCeUtleQAAAAEAAAADa2V5BAAAAAckbWF0Y2gwCQAEGwAAAAIFAAAABHRoaXMFAAAAA2tleQMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAAHQm9vbGVhbgQAAAABYQUAAAAHJG1hdGNoMAUAAAABYQcBAAAAGGdldE51bWJlckJ5QWRkcmVzc0FuZEtleQAAAAIAAAAHYWRkcmVzcwAAAANrZXkEAAAAByRtYXRjaDAJA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AAQUAAAAKb3JkZXJPd25lcgkBAAAAFWNvbnZlcnRCb25kVG9OZXV0cmlubwAAAAEFAAAADm5ld0ZpbGxlZFRvdGFsBQAAAA9uZXV0cmlub0Fzc2V0SWQFAAAAA25pbAAAAAAJUGjE", "chainId": 84, "height": 703349, "spentComplexity": 0 } View: original | compacted Prev: Az8K416kiGhbimmShQENYaigC6GPtxwomu8wAisvqvyw Next: FMqUkQEZAieWa2bdnJLDM96AHHZbTBKTbrCRzdJVvFuy Full:
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 3 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | func getNumberByKey (key) = match getInteger(this, key) { | |
5 | 5 | case a: Int => | |
6 | 6 | a | |
7 | 7 | case _ => | |
8 | 8 | 0 | |
9 | 9 | } | |
10 | 10 | ||
11 | 11 | ||
12 | 12 | func getStringByKey (key) = match getString(this, key) { | |
13 | 13 | case a: String => | |
14 | 14 | a | |
15 | 15 | case _ => | |
16 | 16 | "" | |
17 | 17 | } | |
18 | 18 | ||
19 | 19 | ||
20 | 20 | func getBoolByKey (key) = match getBoolean(this, key) { | |
21 | 21 | case a: Boolean => | |
22 | 22 | a | |
23 | 23 | case _ => | |
24 | 24 | false | |
25 | 25 | } | |
26 | 26 | ||
27 | 27 | ||
28 | 28 | func getNumberByAddressAndKey (address,key) = match getInteger(addressFromStringValue(address), key) { | |
29 | 29 | case a: Int => | |
30 | 30 | a | |
31 | 31 | case _ => | |
32 | 32 | 0 | |
33 | 33 | } | |
34 | 34 | ||
35 | 35 | ||
36 | 36 | let LISTSPLITSYMBOL = "_" | |
37 | 37 | ||
38 | 38 | let LISTDATASYMBOL = "+" | |
39 | 39 | ||
40 | 40 | let WAVELET = 100000000 | |
41 | 41 | ||
42 | 42 | let CANCELED = "canceled" | |
43 | 43 | ||
44 | 44 | let NEW = "new" | |
45 | 45 | ||
46 | 46 | let FILLED = "filled" | |
47 | 47 | ||
48 | 48 | let NeutrinoAssetIdKey = "neutrino_asset_id" | |
49 | 49 | ||
50 | 50 | let BondAssetIdKey = "bond_asset_id" | |
51 | 51 | ||
52 | 52 | let AuctionContractKey = "auction_contract" | |
53 | 53 | ||
54 | 54 | let RPDContractKey = "rpd_contract" | |
55 | 55 | ||
56 | 56 | let BalanceLockIntervalKey = "balance_lock_interval" | |
57 | 57 | ||
58 | 58 | let VoteIntervalKey = "vote_interval" | |
59 | 59 | ||
60 | 60 | let MinSwapAmountKey = "min_swap_amount" | |
61 | 61 | ||
62 | 62 | let PriceOffsetKey = "price_offset" | |
63 | 63 | ||
64 | 64 | let ProvidingIntervalKey = "providing_interval" | |
65 | 65 | ||
66 | 66 | let PriceKey = "price" | |
67 | 67 | ||
68 | 68 | let NeutrinoBalanceKey = "neutrino_" | |
69 | 69 | ||
70 | 70 | let WavesBalanceKey = "waves_" | |
71 | 71 | ||
72 | 72 | let BalanceUnlockBlockKey = "balance_block_" | |
73 | 73 | ||
74 | 74 | let OrderbookKey = "orderbook" | |
75 | 75 | ||
76 | 76 | let OrderTotalKey = "order_total_" | |
77 | 77 | ||
78 | 78 | let OrderOwnerKey = "order_owner_" | |
79 | 79 | ||
80 | 80 | let OrderHeightKey = "order_height_" | |
81 | 81 | ||
82 | 82 | let OrderFilledTotalKey = "order_filled_total_" | |
83 | 83 | ||
84 | 84 | let OrderStatusKey = "order_status_" | |
85 | 85 | ||
86 | 86 | let RPDSyncIndexKey = "rpd_sync_index" | |
87 | 87 | ||
88 | 88 | let RPDProfitKey = "rpd_profit" | |
89 | 89 | ||
90 | 90 | let RPDBalanceKey = "rpd_balance" | |
91 | 91 | ||
92 | 92 | let IsBlockedKey = "is_blocked" | |
93 | 93 | ||
94 | 94 | let BlackSwarmPriceKey = "black_swarm_price" | |
95 | 95 | ||
96 | 96 | let AdminVoteKey = "admin_vote_" | |
97 | 97 | ||
98 | 98 | let AdminVotePriceKey = "admin_vote_price_" | |
99 | 99 | ||
100 | 100 | let BlockExpireVoteKey = "vote_expire_block" | |
101 | 101 | ||
102 | 102 | let AdminKey = "admin_" | |
103 | 103 | ||
104 | 104 | let IsPricePendingKey = "is_pending_price" | |
105 | 105 | ||
106 | 106 | let OracleKey = "oracle_" | |
107 | 107 | ||
108 | 108 | let OracleIsProvideKey = "oracle_is_provide_" | |
109 | 109 | ||
110 | 110 | let OracleProvidePriceKey = "oracle_price_provide_" | |
111 | 111 | ||
112 | 112 | let BlockExpireProvidingKey = "providing_expire_block" | |
113 | 113 | ||
114 | 114 | func getAdminKey (count) = (AdminKey + toString(count)) | |
115 | 115 | ||
116 | 116 | ||
117 | 117 | func getAdminVoteKey (owner) = (AdminVoteKey + owner) | |
118 | 118 | ||
119 | 119 | ||
120 | 120 | func getAdminVotePriceKey (owner) = (AdminVotePriceKey + owner) | |
121 | 121 | ||
122 | 122 | ||
123 | 123 | func getOracleKey (count) = (OracleKey + toString(count)) | |
124 | 124 | ||
125 | 125 | ||
126 | 126 | func getOracleIsProvideKey (owner) = (OracleIsProvideKey + owner) | |
127 | 127 | ||
128 | 128 | ||
129 | 129 | func getOracleProvidePriceKey (owner) = (OracleProvidePriceKey + owner) | |
130 | 130 | ||
131 | 131 | ||
132 | 132 | func getRPDSnapshotContractBalanceKey (count,assetId) = ((((RPDBalanceKey + "_") + toBase58String(assetId)) + "_") + toString(count)) | |
133 | 133 | ||
134 | 134 | ||
135 | 135 | func getRPDContractBalanceKey (assetId) = ((RPDBalanceKey + "_") + toBase58String(assetId)) | |
136 | 136 | ||
137 | 137 | ||
138 | 138 | func getRPDProfitKey (count) = ((RPDProfitKey + "_") + toString(count)) | |
139 | 139 | ||
140 | 140 | ||
141 | 141 | func getNeutrinoBalanceKey (owner) = (NeutrinoBalanceKey + owner) | |
142 | 142 | ||
143 | 143 | ||
144 | 144 | func getWavesBalanceKey (owner) = (WavesBalanceKey + owner) | |
145 | 145 | ||
146 | 146 | ||
147 | 147 | func getBalanceUnlockBlockKey (owner) = (BalanceUnlockBlockKey + owner) | |
148 | 148 | ||
149 | 149 | ||
150 | 150 | func getBlackSwarmPriceKey (block) = ((BlackSwarmPriceKey + "_") + toString(block)) | |
151 | 151 | ||
152 | 152 | ||
153 | 153 | func getPriceHistoryKey (block) = ((PriceKey + "_") + toString(block)) | |
154 | 154 | ||
155 | 155 | ||
156 | 156 | func getOrderTotalKey (orderId) = (OrderTotalKey + orderId) | |
157 | 157 | ||
158 | 158 | ||
159 | 159 | func getOrderOwnerKey (orderId) = (OrderOwnerKey + orderId) | |
160 | 160 | ||
161 | 161 | ||
162 | 162 | func getOrderHeightKey (orderId) = (OrderHeightKey + orderId) | |
163 | 163 | ||
164 | 164 | ||
165 | 165 | func getOrderStatusKey (orderId) = (OrderStatusKey + orderId) | |
166 | 166 | ||
167 | 167 | ||
168 | 168 | func getOrderFilledTotalKey (orderId) = (OrderFilledTotalKey + orderId) | |
169 | 169 | ||
170 | 170 | ||
171 | 171 | let price = getNumberByKey(PriceKey) | |
172 | 172 | ||
173 | 173 | func convertNeutrinoToWaves (amount) = ((amount * 100) / price) | |
174 | 174 | ||
175 | 175 | ||
176 | 176 | func convertWavesToNeutrino (amount) = ((amount * price) / 100) | |
177 | 177 | ||
178 | 178 | ||
179 | 179 | func convertNeutrinoToBond (amount) = (amount / WAVELET) | |
180 | 180 | ||
181 | 181 | ||
182 | 182 | func convertBondToNeutrino (amount) = (amount * WAVELET) | |
183 | 183 | ||
184 | 184 | ||
185 | 185 | func convertWavesToBond (amount) = convertNeutrinoToBond(convertWavesToNeutrino(amount)) | |
186 | 186 | ||
187 | 187 | ||
188 | 188 | let providingInterval = getNumberByKey(ProvidingIntervalKey) | |
189 | 189 | ||
190 | 190 | let blockExpireProviding = getNumberByKey(BlockExpireProvidingKey) | |
191 | 191 | ||
192 | 192 | let isPricePending = getBoolByKey(IsPricePendingKey) | |
193 | 193 | ||
194 | 194 | let percentPriceOffset = getNumberByKey(PriceOffsetKey) | |
195 | 195 | ||
196 | 196 | let rpdSyncIndex = getNumberByKey(RPDSyncIndexKey) | |
197 | 197 | ||
198 | 198 | let voteInterval = getNumberByKey(VoteIntervalKey) | |
199 | 199 | ||
200 | 200 | let blockExpireVote = getNumberByKey(BlockExpireVoteKey) | |
201 | 201 | ||
202 | 202 | let balanceLockInterval = getNumberByKey(BalanceLockIntervalKey) | |
203 | 203 | ||
204 | 204 | let isBlocked = getBoolByKey(IsBlockedKey) | |
205 | 205 | ||
206 | 206 | let minSwapAmount = getNumberByKey(MinSwapAmountKey) | |
207 | 207 | ||
208 | 208 | let neutrinoAssetId = fromBase58String(getStringByKey(NeutrinoAssetIdKey)) | |
209 | 209 | ||
210 | 210 | let auctionContract = getStringByKey(AuctionContractKey) | |
211 | 211 | ||
212 | 212 | let rpdContract = getStringByKey(RPDContractKey) | |
213 | 213 | ||
214 | 214 | let reserve = wavesBalance(this) | |
215 | 215 | ||
216 | 216 | let orderbook = getStringByKey(OrderbookKey) | |
217 | 217 | ||
218 | 218 | let bondAssetId = fromBase58String(getStringByKey(BondAssetIdKey)) | |
219 | 219 | ||
220 | 220 | let bondSupply = { | |
221 | 221 | let info = extract(assetInfo(bondAssetId)) | |
222 | 222 | (info.quantity - assetBalance(this, bondAssetId)) | |
223 | 223 | } | |
224 | 224 | ||
225 | 225 | let neutrinoSupply = { | |
226 | 226 | let info = extract(assetInfo(neutrinoAssetId)) | |
227 | 227 | (info.quantity - assetBalance(this, neutrinoAssetId)) | |
228 | 228 | } | |
229 | 229 | ||
230 | 230 | let surplus = (convertWavesToNeutrino(reserve) - neutrinoSupply) | |
231 | 231 | ||
232 | 232 | let oracleOne = getStringByKey(getOracleKey(0)) | |
233 | 233 | ||
234 | 234 | let oracleTwo = getStringByKey(getOracleKey(1)) | |
235 | 235 | ||
236 | 236 | let oracleThree = getStringByKey(getOracleKey(2)) | |
237 | 237 | ||
238 | 238 | let adminOne = getStringByKey(getAdminKey(0)) | |
239 | 239 | ||
240 | 240 | let adminTwo = getStringByKey(getAdminKey(1)) | |
241 | 241 | ||
242 | 242 | let adminThree = getStringByKey(getAdminKey(2)) | |
243 | 243 | ||
244 | 244 | func getRPDContractBalance (assetId) = getNumberByAddressAndKey(rpdContract, getRPDContractBalanceKey(assetId)) | |
245 | 245 | ||
246 | 246 | ||
247 | 247 | func getAdminVoteInt (owner) = if (getBoolByKey(getAdminVoteKey(owner))) | |
248 | 248 | then 1 | |
249 | 249 | else 0 | |
250 | 250 | ||
251 | 251 | ||
252 | 252 | func getAdminVotePrice (owner) = getNumberByKey(getAdminVotePriceKey(owner)) | |
253 | 253 | ||
254 | 254 | ||
255 | 255 | func isOracleProvide (owner) = getBoolByKey(getOracleIsProvideKey(owner)) | |
256 | 256 | ||
257 | 257 | ||
258 | 258 | func isOracleProvideInt (owner) = if (isOracleProvide(owner)) | |
259 | 259 | then 1 | |
260 | 260 | else 0 | |
261 | 261 | ||
262 | 262 | ||
263 | 263 | func getOracleProvidePrice (owner) = getNumberByKey(getOracleProvidePriceKey(owner)) | |
264 | 264 | ||
265 | 265 | ||
266 | 266 | func getWavesBalance (owner) = getNumberByKey(getWavesBalanceKey(owner)) | |
267 | 267 | ||
268 | 268 | ||
269 | 269 | func getNeutrinoBalance (owner) = getNumberByKey(getNeutrinoBalanceKey(owner)) | |
270 | 270 | ||
271 | 271 | ||
272 | 272 | func getUnlockBalanceBlock (owner) = getNumberByKey(getBalanceUnlockBlockKey(owner)) | |
273 | 273 | ||
274 | 274 | ||
275 | 275 | func getOrderTotal (id) = getNumberByKey(getOrderTotalKey(id)) | |
276 | 276 | ||
277 | 277 | ||
278 | 278 | func getOrderOwner (id) = getStringByKey(getOrderOwnerKey(id)) | |
279 | 279 | ||
280 | 280 | ||
281 | 281 | func getOrderFilledTotal (id) = getNumberByKey(getOrderFilledTotalKey(id)) | |
282 | 282 | ||
283 | 283 | ||
284 | 284 | func getRPDProfit (count) = getNumberByKey(getRPDProfitKey(count)) | |
285 | 285 | ||
286 | 286 | ||
287 | 287 | func getOrderElementById (id) = (id + LISTSPLITSYMBOL) | |
288 | 288 | ||
289 | 289 | ||
290 | 290 | func addOrder (orderId) = (orderbook + getOrderElementById(orderId)) | |
291 | 291 | ||
292 | 292 | ||
293 | 293 | func dropOrder (orderId) = { | |
294 | 294 | let parts = split(orderbook, getOrderElementById(orderId)) | |
295 | 295 | (parts[0] + parts[1]) | |
296 | 296 | } | |
297 | 297 | ||
298 | 298 | ||
299 | 299 | @Callable(i) | |
300 | 300 | func setCurrentPrice (newPrice) = { | |
301 | 301 | let account = toString(i.caller) | |
302 | 302 | let priceProvidingCount = (((isOracleProvideInt(oracleOne) + isOracleProvideInt(oracleTwo)) + isOracleProvideInt(oracleThree)) + 1) | |
303 | 303 | if (isBlocked) | |
304 | 304 | then throw("contract is blocked") | |
305 | 305 | else if (if (if ((account != oracleOne)) | |
306 | 306 | then (account != oracleTwo) | |
307 | 307 | else false) | |
308 | 308 | then (account != oracleThree) | |
309 | 309 | else false) | |
310 | 310 | then throw("permission denied") | |
311 | 311 | else if (if ((blockExpireProviding >= height)) | |
312 | 312 | then isOracleProvide(account) | |
313 | 313 | else false) | |
314 | 314 | then throw("price is already provided") | |
315 | 315 | else if (if ((height > blockExpireProviding)) | |
316 | 316 | then isPricePending | |
317 | 317 | else false) | |
318 | 318 | then throw("use finilizeCurrentPrice") | |
319 | 319 | else WriteSet([DataEntry(getOracleProvidePriceKey(account), newPrice), DataEntry(BlockExpireProvidingKey, if ((height > blockExpireProviding)) | |
320 | 320 | then (height + providingInterval) | |
321 | 321 | else blockExpireProviding), DataEntry(getOracleIsProvideKey(oracleOne), if ((height > blockExpireProviding)) | |
322 | 322 | then false | |
323 | 323 | else isOracleProvide(oracleOne)), DataEntry(getOracleIsProvideKey(oracleTwo), if ((height > blockExpireProviding)) | |
324 | 324 | then false | |
325 | 325 | else isOracleProvide(oracleTwo)), DataEntry(getOracleIsProvideKey(oracleThree), if ((height > blockExpireProviding)) | |
326 | 326 | then false | |
327 | 327 | else isOracleProvide(oracleThree)), DataEntry(getOracleIsProvideKey(account), true), DataEntry(IsPricePendingKey, if (if ((blockExpireProviding >= height)) | |
328 | 328 | then (priceProvidingCount >= 2) | |
329 | 329 | else false) | |
330 | 330 | then true | |
331 | 331 | else isPricePending)]) | |
332 | 332 | } | |
333 | 333 | ||
334 | 334 | ||
335 | 335 | ||
336 | 336 | @Callable(i) | |
337 | 337 | func finilizeCurrentPrice () = { | |
338 | 338 | let account = toString(i.caller) | |
339 | 339 | let priceProvidingCount = ((isOracleProvideInt(oracleOne) + isOracleProvideInt(oracleTwo)) + isOracleProvideInt(oracleThree)) | |
340 | 340 | let newPrice = ((((getOracleProvidePrice(oracleOne) * isOracleProvideInt(oracleOne)) + (getOracleProvidePrice(oracleTwo) * isOracleProvideInt(oracleTwo))) + (getOracleProvidePrice(oracleThree) * isOracleProvideInt(oracleThree))) / priceProvidingCount) | |
341 | 341 | if (isBlocked) | |
342 | 342 | then throw("contract is blocked") | |
343 | 343 | else if (if (if ((account != oracleOne)) | |
344 | 344 | then (account != oracleTwo) | |
345 | 345 | else false) | |
346 | 346 | then (account != oracleThree) | |
347 | 347 | else false) | |
348 | 348 | then throw("permission denied") | |
349 | 349 | else if (if (!(isPricePending)) | |
350 | 350 | then true | |
351 | 351 | else (blockExpireProviding >= height)) | |
352 | 352 | then throw("wait for the end of the price providing") | |
353 | 353 | else if ((2 > priceProvidingCount)) | |
354 | 354 | then throw("2/3 oracles need to set a price") | |
355 | 355 | else if (if ((newPrice >= (price + ((price * percentPriceOffset) / 100)))) | |
356 | 356 | then true | |
357 | 357 | else ((price - ((price * percentPriceOffset) / 100)) >= newPrice)) | |
358 | 358 | then WriteSet([DataEntry(IsBlockedKey, true), DataEntry(getBlackSwarmPriceKey(height), newPrice)]) | |
359 | 359 | else WriteSet([DataEntry(PriceKey, newPrice), DataEntry(getPriceHistoryKey(height), newPrice), DataEntry(IsPricePendingKey, false)]) | |
360 | 360 | } | |
361 | 361 | ||
362 | 362 | ||
363 | 363 | ||
364 | 364 | @Callable(i) | |
365 | 365 | func adminUnlock (newPrice) = { | |
366 | 366 | let account = toString(i.caller) | |
367 | 367 | let adminOneVote = if ((account != adminOne)) | |
368 | 368 | then getAdminVoteInt(adminOne) | |
369 | 369 | else 0 | |
370 | 370 | let adminTwoVote = if ((account != adminTwo)) | |
371 | 371 | then getAdminVoteInt(adminTwo) | |
372 | 372 | else 0 | |
373 | 373 | let adminThreeVote = if ((account != adminThree)) | |
374 | 374 | then getAdminVoteInt(adminThree) | |
375 | 375 | else 0 | |
376 | 376 | let adminOnePrice = if (((getAdminVotePrice(adminOne) * adminOneVote) == newPrice)) | |
377 | 377 | then 1 | |
378 | 378 | else 0 | |
379 | 379 | let adminTwoPrice = if (((getAdminVotePrice(adminTwo) * adminTwoVote) == newPrice)) | |
380 | 380 | then 1 | |
381 | 381 | else 0 | |
382 | 382 | let adminThreePrice = if (((getAdminVotePrice(adminThree) * adminThreeVote) == newPrice)) | |
383 | 383 | then 1 | |
384 | 384 | else 0 | |
385 | 385 | if (!(isBlocked)) | |
386 | 386 | then throw("Contract is not blocked") | |
387 | 387 | else if (if (((((adminOnePrice + adminTwoPrice) + adminThreePrice) + 1) >= 2)) | |
388 | 388 | then (blockExpireVote >= height) | |
389 | 389 | else false) | |
390 | 390 | then WriteSet([DataEntry(IsBlockedKey, false), DataEntry(PriceKey, newPrice), DataEntry(getPriceHistoryKey(height), newPrice), DataEntry(getAdminVoteKey(adminOne), false), DataEntry(getAdminVoteKey(adminTwo), false), DataEntry(getAdminVoteKey(adminThree), false), DataEntry(BlockExpireVoteKey, 0), DataEntry(BlockExpireProvidingKey, 0), DataEntry(IsPricePendingKey, false)]) | |
391 | 391 | else WriteSet([DataEntry(getAdminVotePriceKey(account), newPrice), DataEntry(BlockExpireVoteKey, if ((height > blockExpireVote)) | |
392 | 392 | then (height + voteInterval) | |
393 | 393 | else blockExpireVote), DataEntry(getAdminVoteKey(adminOne), if ((height > blockExpireVote)) | |
394 | 394 | then false | |
395 | 395 | else (adminOneVote == 1)), DataEntry(getAdminVoteKey(adminTwo), if ((height > blockExpireVote)) | |
396 | 396 | then false | |
397 | 397 | else (adminTwoVote == 1)), DataEntry(getAdminVoteKey(adminThree), if ((height > blockExpireVote)) | |
398 | 398 | then false | |
399 | 399 | else (adminThreeVote == 1)), DataEntry(getAdminVoteKey(account), true)]) | |
400 | 400 | } | |
401 | 401 | ||
402 | 402 | ||
403 | 403 | ||
404 | 404 | @Callable(i) | |
405 | 405 | func adminLock () = { | |
406 | 406 | let account = toString(i.caller) | |
407 | 407 | let adminOneVote = if ((account != adminOne)) | |
408 | 408 | then getAdminVoteInt(adminOne) | |
409 | 409 | else 1 | |
410 | 410 | let adminTwoVote = if ((account != adminTwo)) | |
411 | 411 | then getAdminVoteInt(adminTwo) | |
412 | 412 | else 1 | |
413 | 413 | let adminThreeVote = if ((account != adminThree)) | |
414 | 414 | then getAdminVoteInt(adminThree) | |
415 | 415 | else 1 | |
416 | 416 | if (isBlocked) | |
417 | 417 | then throw("Contract is blocked") | |
418 | 418 | else if ((((adminOneVote + adminTwoVote) + adminThreeVote) >= 2)) | |
419 | 419 | then WriteSet([DataEntry(IsBlockedKey, true), DataEntry(getAdminVoteKey(adminOne), false), DataEntry(getAdminVoteKey(adminTwo), false), DataEntry(getAdminVoteKey(adminThree), false), DataEntry(BlockExpireVoteKey, 0)]) | |
420 | 420 | else WriteSet([DataEntry(BlockExpireVoteKey, if ((height > blockExpireVote)) | |
421 | 421 | then (height + voteInterval) | |
422 | 422 | else blockExpireVote), DataEntry(getAdminVoteKey(adminOne), if ((height > blockExpireVote)) | |
423 | 423 | then false | |
424 | 424 | else (adminOneVote == 1)), DataEntry(getAdminVoteKey(adminTwo), if ((height > blockExpireVote)) | |
425 | 425 | then false | |
426 | 426 | else (adminTwoVote == 1)), DataEntry(getAdminVoteKey(adminThree), if ((height > blockExpireVote)) | |
427 | 427 | then false | |
428 | 428 | else (adminThreeVote == 1))]) | |
429 | 429 | } | |
430 | 430 | ||
431 | 431 | ||
432 | 432 | ||
433 | 433 | @Callable(i) | |
434 | 434 | func swapWavesToNeutrino () = { | |
435 | 435 | let pmt = extract(i.payment) | |
436 | 436 | if ((minSwapAmount > pmt.amount)) | |
437 | 437 | then throw("amount less min") | |
438 | 438 | else if (isDefined(pmt.assetId)) | |
439 | 439 | then throw("can use waves only") | |
440 | 440 | else if (isBlocked) | |
441 | 441 | then throw("contract is blocked") | |
442 | 442 | else { | |
443 | 443 | let amount = convertWavesToNeutrino(pmt.amount) | |
444 | 444 | TransferSet([ScriptTransfer(i.caller, amount, neutrinoAssetId)]) | |
445 | 445 | } | |
446 | 446 | } | |
447 | 447 | ||
448 | 448 | ||
449 | 449 | ||
450 | 450 | @Callable(i) | |
451 | 451 | func swapNeutrinoToWaves () = { | |
452 | 452 | let pmt = extract(i.payment) | |
453 | 453 | if ((minSwapAmount > pmt.amount)) | |
454 | 454 | then throw("amount less min") | |
455 | 455 | else if (isBlocked) | |
456 | 456 | then throw("contract is blocked") | |
457 | 457 | else if ((pmt.assetId != neutrinoAssetId)) | |
458 | 458 | then throw("can use neutrino only") | |
459 | 459 | else { | |
460 | 460 | let account = toBase58String(i.caller.bytes) | |
461 | 461 | let amount = convertNeutrinoToWaves(pmt.amount) | |
462 | 462 | WriteSet([DataEntry(getWavesBalanceKey(account), (getWavesBalance(account) + amount)), DataEntry(getBalanceUnlockBlockKey(account), (height + balanceLockInterval))]) | |
463 | 463 | } | |
464 | 464 | } | |
465 | 465 | ||
466 | 466 | ||
467 | 467 | ||
468 | 468 | @Callable(i) | |
469 | 469 | func withdraw (account) = if ((getUnlockBalanceBlock(account) > height)) | |
470 | 470 | then throw("wait a couple of blocks for withdraw") | |
471 | 471 | else ScriptResult(WriteSet([DataEntry(getWavesBalanceKey(account), 0), DataEntry(getNeutrinoBalanceKey(account), 0)]), TransferSet([ScriptTransfer(addressFromStringValue(account), getNeutrinoBalance(account), neutrinoAssetId), ScriptTransfer(addressFromStringValue(account), getWavesBalance(account), unit)])) | |
472 | 472 | ||
473 | 473 | ||
474 | 474 | ||
475 | 475 | @Callable(i) | |
476 | 476 | func generateBond () = { | |
477 | 477 | let deficit = (neutrinoSupply - convertWavesToNeutrino(reserve)) | |
478 | 478 | let balanceAuction = assetBalance(addressFromStringValue(auctionContract), bondAssetId) | |
479 | 479 | let amount = (convertNeutrinoToBond(deficit) - balanceAuction) | |
480 | 480 | if (isBlocked) | |
481 | 481 | then throw("contract is blocked") | |
482 | 482 | else if ((amount > 0)) | |
483 | 483 | then TransferSet([ScriptTransfer(addressFromStringValue(auctionContract), amount, bondAssetId)]) | |
484 | 484 | else throw("bond were generated or do not need it") | |
485 | 485 | } | |
486 | 486 | ||
487 | 487 | ||
488 | 488 | ||
489 | 489 | @Callable(i) | |
490 | 490 | func setOrder () = { | |
491 | 491 | let pmt = extract(i.payment) | |
492 | 492 | let newOrderId = toBase58String(keccak256(((toBytes(pmt.amount) + i.caller.bytes) + toBytes(height)))) | |
493 | 493 | if ((pmt.assetId != bondAssetId)) | |
494 | 494 | then throw("can use bond only") | |
495 | 495 | else if ((getOrderOwner(newOrderId) != "")) | |
496 | 496 | then throw("order exists") | |
497 | 497 | 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)]) | |
498 | 498 | } | |
499 | 499 | ||
500 | 500 | ||
501 | 501 | ||
502 | 502 | @Callable(i) | |
503 | 503 | func cancelOrder (orderId) = { | |
504 | 504 | let owner = getOrderOwner(orderId) | |
505 | 505 | let amount = (getOrderTotal(orderId) - getOrderFilledTotal(orderId)) | |
506 | 506 | if ((owner != toString(i.caller))) | |
507 | 507 | then throw("permission denied") | |
508 | 508 | else ScriptResult(WriteSet([DataEntry(OrderbookKey, dropOrder(orderId)), DataEntry(getOrderStatusKey(orderId), CANCELED)]), TransferSet([ScriptTransfer(i.caller, amount, bondAssetId)])) | |
509 | 509 | } | |
510 | 510 | ||
511 | 511 | ||
512 | 512 | ||
513 | 513 | @Callable(i) | |
514 | 514 | func executeOrder () = { | |
515 | 515 | let orderId = split(orderbook, LISTSPLITSYMBOL)[0] | |
516 | 516 | let orderTotal = getOrderTotal(orderId) | |
517 | 517 | let orderOwner = getOrderOwner(orderId) | |
518 | 518 | let filledTotal = getOrderFilledTotal(orderId) | |
519 | 519 | if (isBlocked) | |
520 | 520 | then throw("contract is blocked") | |
521 | 521 | else if ((0 >= surplus)) | |
522 | 522 | then throw("surplus is less than zero") | |
523 | 523 | else if ((orderOwner == "")) | |
524 | 524 | then { | |
525 | 525 | let newRpdSyncIndex = (rpdSyncIndex + 1) | |
526 | 526 | ScriptResult(WriteSet([DataEntry(RPDSyncIndexKey, newRpdSyncIndex), DataEntry(getRPDProfitKey(rpdSyncIndex), surplus), DataEntry(getRPDSnapshotContractBalanceKey(rpdSyncIndex, neutrinoAssetId), getRPDContractBalance(neutrinoAssetId)), DataEntry(getRPDSnapshotContractBalanceKey(rpdSyncIndex, bondAssetId), getRPDContractBalance(bondAssetId))]), TransferSet([ScriptTransfer(addressFromStringValue(rpdContract), surplus, neutrinoAssetId)])) | |
527 | 527 | } | |
528 | 528 | else { | |
529 | 529 | let amount = (orderTotal - filledTotal) | |
530 | 530 | let surplusBond = convertNeutrinoToBond(surplus) | |
531 | 531 | let status = if ((surplusBond >= amount)) | |
532 | 532 | then FILLED | |
533 | 533 | else NEW | |
534 | 534 | let newFilledTotal = if ((surplusBond >= amount)) | |
535 | 535 | then orderTotal | |
536 | 536 | else surplusBond | |
537 | 537 | ScriptResult(WriteSet([DataEntry(OrderbookKey, dropOrder(orderId)), DataEntry(getOrderFilledTotalKey(orderId), (filledTotal + newFilledTotal)), DataEntry(getOrderStatusKey(orderId), status)]), TransferSet([ScriptTransfer(addressFromStringValue(orderOwner), convertBondToNeutrino(newFilledTotal), neutrinoAssetId)])) | |
538 | 538 | } | |
539 | 539 | } | |
540 | 540 | ||
541 | 541 |
github/deemru/w8io/026f985 59.20 ms ◑