tx · 72tibMuPv7PH8YBbp4rWxGoe72fxbvA97E3QfB73CAqh 3MrdV3AP4zfU77ifesNStoDZmL1Cfx13eDc: -0.05000000 Waves 2019.12.19 06:21 [815234] smart account 3MrdV3AP4zfU77ifesNStoDZmL1Cfx13eDc > SELF 0.00000000 Waves
{ "type": 13, "id": "72tibMuPv7PH8YBbp4rWxGoe72fxbvA97E3QfB73CAqh", "fee": 5000000, "feeAssetId": null, "timestamp": 1576725714188, "version": 1, "sender": "3MrdV3AP4zfU77ifesNStoDZmL1Cfx13eDc", "senderPublicKey": "5M79Anear5ntQk2bbDdFA2goiPXkv7Xy2UpV4n5RKRv", "proofs": [ "3Kgp6V4RBuKj25qE3tyEMoG2shLYkMCupw5bgQDLE3Eq81DFwU92GkbDnc7nS4n6wQbq5dw4WCApPYqXw8PK1V9i" ], "script": "base64:AAIDAAAAAAAAAA4IARIAEgMKAQgSAwoBCAAAAA4AAAAAEldCRVRSRVNFUlZBVElPTktFWQIAAAAVJFdCRVRfUkVTRVJWRURfQU1PVU5UAAAAABNST1lBTFJFU0VSVkFUSU9OS0VZAgAAABYkUk9ZQUxfUkVTRVJWRURfQU1PVU5UAAAAAARXQkVUAQAAACCGtDaoeNMOzNjwF61LLiwEHwefusq5FqlK128lrZvQdgAAAAAFUk9ZQUwBAAAAIEPpioLCJdl0nJV8IFJJxqOakLK2lV9iYl7KOImJDGkcAAAAAApXQkVUTE9DS0VEAAAAAAAAAAAAAAAAAAtST1lBTExPQ0tFRAAAAAAAAAAAAQAAAAAMV0JFVFdJVEhEUkFXAAAAAAAAAAACAAAAAA1ST1lBTFdJVEhEUkFXAAAAAAAAAAADAAAAAA1XQVZFU1dJVEhEUkFXAAAAAAAAAAAEAQAAABZFeHRyYWN0V0JFVFJlc2VydmVkQW10AAAAAAQAAAAHJG1hdGNoMAkABBoAAAACBQAAAAR0aGlzBQAAABJXQkVUUkVTRVJWQVRJT05LRVkDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAAA0ludAQA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RhRW50cnkAAAACBQAAAAZ3YWxsZXQJAQAAABNGb3JtYXRQbGF5ZXJCYWxhbmNlAAAABQkAAZEAAAACBQAAAAdiYWxhbmNlBQAAAApXQkVUTE9DS0VEAAAAAAAAAAAACQABkQAAAAIFAAAAB2JhbGFuY2UFAAAADFdCRVRXSVRIRFJBVwkAAZEAAAACBQAAAAdiYWxhbmNlBQAAAA1ST1lBTFdJVEhEUkFXCQABkQAAAAIFAAAAB2JhbGFuY2UFAAAADVdBVkVTV0lUSERSQVcFAAAAA25pbAkBAAAAC1RyYW5zZmVyU2V0AAAAAQkABEwAAAACCQEAAAAOU2NyaXB0VHJhbnNmZXIAAAADCAUAAAABaQAAAAZjYWxsZXIJAAGRAAAAAgUAAAAHYmFsYW5jZQUAAAALUk9ZQUxMT0NLRUQFAAAABVJPWUFMBQAAAANuaWwJAAACAAAAAQIAAAANaW52YWxpdCBhc3NldAAAAAFpAQAAAAlmaXhwbGF5ZXIAAAABAAAABWFzc2V0BAAAAAZ3YWxsZXQJAAQlAAAAAQgFAAAAAWkAAAAGY2FsbGVyCQEAAAAMU2NyaXB0UmVzdWx0AAAAAgkBAAAACFdyaXRlU2V0AAAAAQkABEwAAAACCQEAAAAJRGF0YUVudHJ5AAAAAgUAAAAGd2FsbGV0CQEAAAATRm9ybWF0UGxheWVyQmFsYW5jZQAAAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAA25pbAkBAAAAC1RyYW5zZmVyU2V0AAAAAQUAAAADbmlsAAAAAM+A0i4=", "chainId": 84, "height": 815234, "spentComplexity": 0 } View: original | compacted Prev: Ch6CQt9NWcCVBwMqVrJAEKX6NR85ofHEvm3cwbjDBUvK Next: GMt9ggCQi3mCQMuv5oSLVVqoKYs8NEmCu58bzpZQEpWY Diff:
Old | New | Differences | |
---|---|---|---|
107 | 107 | } | |
108 | 108 | ||
109 | 109 | ||
110 | + | ||
111 | + | @Callable(i) | |
112 | + | func fixplayer (asset) = { | |
113 | + | let wallet = toString(i.caller) | |
114 | + | ScriptResult(WriteSet([DataEntry(wallet, FormatPlayerBalance(0, 0, 0, 0, 0))]), TransferSet(nil)) | |
115 | + | } | |
116 | + | ||
117 | + |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 3 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let WBETRESERVATIONKEY = "$WBET_RESERVED_AMOUNT" | |
5 | 5 | ||
6 | 6 | let ROYALRESERVATIONKEY = "$ROYAL_RESERVED_AMOUNT" | |
7 | 7 | ||
8 | 8 | let WBET = base58'A4q1mYKo11yuH9gmvDodeJoksagcyQzeFE9JtphMWddw' | |
9 | 9 | ||
10 | 10 | let ROYAL = base58'5a6rvDEiVwvhTvTH6ce2qFwqdCt3VKaHKXEpwLXXVvyy' | |
11 | 11 | ||
12 | 12 | let WBETLOCKED = 0 | |
13 | 13 | ||
14 | 14 | let ROYALLOCKED = 1 | |
15 | 15 | ||
16 | 16 | let WBETWITHDRAW = 2 | |
17 | 17 | ||
18 | 18 | let ROYALWITHDRAW = 3 | |
19 | 19 | ||
20 | 20 | let WAVESWITHDRAW = 4 | |
21 | 21 | ||
22 | 22 | func ExtractWBETReservedAmt () = match getInteger(this, WBETRESERVATIONKEY) { | |
23 | 23 | case a: Int => | |
24 | 24 | a | |
25 | 25 | case _ => | |
26 | 26 | 0 | |
27 | 27 | } | |
28 | 28 | ||
29 | 29 | ||
30 | 30 | func ExtractROYALReservedAmt () = match getInteger(this, ROYALRESERVATIONKEY) { | |
31 | 31 | case a: Int => | |
32 | 32 | a | |
33 | 33 | case _ => | |
34 | 34 | 0 | |
35 | 35 | } | |
36 | 36 | ||
37 | 37 | ||
38 | 38 | func ExtractPlayerAmt (wallet) = match getString(this, wallet) { | |
39 | 39 | case str: String => | |
40 | 40 | str | |
41 | 41 | case _ => | |
42 | 42 | "0_0_0_0_0" | |
43 | 43 | } | |
44 | 44 | ||
45 | 45 | ||
46 | 46 | func FormatPlayerBalance (wbet,royal,wbetWithdraw,royalWithdraw,wavesWithdraw) = ((((((((toString(wbet) + "_") + toString(royal)) + "_") + toString(wbetWithdraw)) + "_") + toString(royalWithdraw)) + "_") + toString(wavesWithdraw)) | |
47 | 47 | ||
48 | 48 | ||
49 | 49 | func ParsePlayerBalance (wallet) = { | |
50 | 50 | let amounts = split(ExtractPlayerAmt(wallet), "_") | |
51 | 51 | let wbetAmount = parseIntValue(amounts[WBETLOCKED]) | |
52 | 52 | let royalAmount = parseIntValue(amounts[ROYALLOCKED]) | |
53 | 53 | let wbetWithdraw = parseIntValue(amounts[WBETWITHDRAW]) | |
54 | 54 | let royalWithdraw = parseIntValue(amounts[ROYALWITHDRAW]) | |
55 | 55 | let wavesWithdraw = parseIntValue(amounts[WAVESWITHDRAW]) | |
56 | 56 | [wbetAmount, royalAmount, wbetWithdraw, royalWithdraw, wavesWithdraw] | |
57 | 57 | } | |
58 | 58 | ||
59 | 59 | ||
60 | 60 | @Callable(i) | |
61 | 61 | func lock () = { | |
62 | 62 | let payment = extract(i.payment) | |
63 | 63 | if (if ((payment.assetId != WBET)) | |
64 | 64 | then (payment.assetId != ROYAL) | |
65 | 65 | else false) | |
66 | 66 | then throw("The token should be in WBET or ROYAL.") | |
67 | 67 | else { | |
68 | 68 | let wallet = toString(i.caller) | |
69 | 69 | let balance = ParsePlayerBalance(wallet) | |
70 | 70 | if ((payment.assetId == WBET)) | |
71 | 71 | then { | |
72 | 72 | let newWBETReservedAmount = (ExtractWBETReservedAmt() + payment.amount) | |
73 | 73 | let newPlayerWBETAmount = (balance[WBETLOCKED] + payment.amount) | |
74 | 74 | ScriptResult(WriteSet([DataEntry(WBETRESERVATIONKEY, newWBETReservedAmount), DataEntry(wallet, FormatPlayerBalance(newPlayerWBETAmount, balance[ROYALLOCKED], balance[WBETWITHDRAW], balance[ROYALWITHDRAW], balance[WAVESWITHDRAW]))]), TransferSet(nil)) | |
75 | 75 | } | |
76 | 76 | else if ((payment.assetId == ROYAL)) | |
77 | 77 | then { | |
78 | 78 | let newROYALReservedAmount = (ExtractROYALReservedAmt() + payment.amount) | |
79 | 79 | let newPlayerRoyalAmount = (balance[ROYALLOCKED] + payment.amount) | |
80 | 80 | ScriptResult(WriteSet([DataEntry(ROYALRESERVATIONKEY, newROYALReservedAmount), DataEntry(wallet, FormatPlayerBalance(balance[WBETLOCKED], newPlayerRoyalAmount, balance[WBETWITHDRAW], balance[ROYALWITHDRAW], balance[WAVESWITHDRAW]))]), TransferSet(nil)) | |
81 | 81 | } | |
82 | 82 | else throw("error") | |
83 | 83 | } | |
84 | 84 | } | |
85 | 85 | ||
86 | 86 | ||
87 | 87 | ||
88 | 88 | @Callable(i) | |
89 | 89 | func unlock (asset) = { | |
90 | 90 | let wallet = toString(i.caller) | |
91 | 91 | let balance = ParsePlayerBalance(wallet) | |
92 | 92 | if ((asset == "WBET")) | |
93 | 93 | then if ((0 >= balance[WBETLOCKED])) | |
94 | 94 | then throw("You dont have enough balance to withdraw the amount requested.") | |
95 | 95 | else { | |
96 | 96 | let newWBETReservedAmount = (ExtractWBETReservedAmt() - balance[WBETLOCKED]) | |
97 | 97 | ScriptResult(WriteSet([DataEntry(WBETRESERVATIONKEY, newWBETReservedAmount), DataEntry(wallet, FormatPlayerBalance(0, balance[ROYALLOCKED], balance[WBETWITHDRAW], balance[ROYALWITHDRAW], balance[WAVESWITHDRAW]))]), TransferSet([ScriptTransfer(i.caller, balance[WBETLOCKED], WBET)])) | |
98 | 98 | } | |
99 | 99 | else if ((asset == "ROYAL")) | |
100 | 100 | then if ((0 >= balance[ROYALLOCKED])) | |
101 | 101 | then throw("You dont have enough balance to withdraw the amount requested.") | |
102 | 102 | else { | |
103 | 103 | let newROYALReservedAmount = (ExtractROYALReservedAmt() - balance[ROYALLOCKED]) | |
104 | 104 | ScriptResult(WriteSet([DataEntry(ROYALRESERVATIONKEY, newROYALReservedAmount), DataEntry(wallet, FormatPlayerBalance(balance[WBETLOCKED], 0, balance[WBETWITHDRAW], balance[ROYALWITHDRAW], balance[WAVESWITHDRAW]))]), TransferSet([ScriptTransfer(i.caller, balance[ROYALLOCKED], ROYAL)])) | |
105 | 105 | } | |
106 | 106 | else throw("invalit asset") | |
107 | 107 | } | |
108 | 108 | ||
109 | 109 | ||
110 | + | ||
111 | + | @Callable(i) | |
112 | + | func fixplayer (asset) = { | |
113 | + | let wallet = toString(i.caller) | |
114 | + | ScriptResult(WriteSet([DataEntry(wallet, FormatPlayerBalance(0, 0, 0, 0, 0))]), TransferSet(nil)) | |
115 | + | } | |
116 | + | ||
117 | + |
github/deemru/w8io/026f985 33.79 ms ◑