tx · GXaN78MYtVBNcvVaGp5c2i1ruKTVhzXrjxbsv6qapyzX 3MsmMBWJKcm1Aqq9xWPBSHZeXbqXmPBke4v: -0.01500000 Waves 2021.03.11 15:45 [1433042] smart account 3MsmMBWJKcm1Aqq9xWPBSHZeXbqXmPBke4v > SELF 0.00000000 Waves
{ "type": 13, "id": "GXaN78MYtVBNcvVaGp5c2i1ruKTVhzXrjxbsv6qapyzX", "fee": 1500000, "feeAssetId": null, "timestamp": 1615466723812, "version": 2, "chainId": 84, "sender": "3MsmMBWJKcm1Aqq9xWPBSHZeXbqXmPBke4v", "senderPublicKey": "64PnpzfvryzwPQ5SCU1L6nGNPquJpTwrUjN2tn8GYXYo", "proofs": [ "5QYTtVKbMDztRtoZVXb23fdtMXn8feLLz3wcdaEVpRLJuqoffHaY68DQXq9uMivtCSVUwUFZuqz965VWrsFNvYu6" ], "script": "base64:AAIDAAAAAAAAAAYIARIAEgAAAAAVAAAAAApkQXBwQWRkcmVzAgAAACtGOURDR2lZZ1Q4eXZCcTFBUUZjU3BHRzRwOHNkek56OW1aY3pEdko0NUxMAAAAAAx0b2tlbkFzc2V0SWQCAAAALDVpaDlqZDRLVjlrU2V5NTV5dktNZ0xTSGN3c1lZa1E0cFJESnRSTm94VWh5AAAAAA11c2VHYXJsaWNDb2luBwAAAAANdG9rZW5zUGVyUGxheQAAAAAAAAAAZAAAAAANbG90dGVyeWFtb3VudAIAAAAHX2Ftb3VudAAAAAASbG90dGVyeXByb2JhYmlsaXR5AgAAAAxfcHJvYmFiaWxpdHkAAAAAGWxvdHRlcnlwcm9iYWJpbGl0eWRlY2ltYWwCAAAAFF9wcm9iYWJpbGl0eV9kZWNpbWFsAAAAABVsb3R0ZXJ5V2lubmluZ0FkZHJlc3MCAAAAEF93aW5uaW5nX2FkZHJlc3MAAAAADGxvdHRlcnlQcmljZQIAAAAGX3ByaWNlAAAAAA1sb3R0ZXJ5UHJpY2VzAgAAAA9fbG90dGVyeV9wcmljZXMAAAAADmxvdH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xhc3RIYXNoUmFuZG9tTnVtYmVyBQAAAApyYW5kTnVtYmVyBQAAAANuaWwEAAAAC3dpblRyYW5zZmVyCQEAAAALVHJhbnNmZXJTZXQAAAABBQAAAANuaWwJAQAAAAxTY3JpcHRSZXN1bHQAAAACBQAAAAl3cml0ZVNldHMJAQAAAAtUcmFuc2ZlclNldAAAAAEFAAAAA25pbAkAAAIAAAABCQABLAAAAAIJAAEsAAAAAgIAAAAJWW91IG5lZWQgBQAAAAx0b2tlbkFzc2V0SWQCAAAAEyB0byBwbGF5IHRoaXMgZ2FtZS4AAAABAAAAAnR4AQAAAAZ2ZXJpZnkAAAAABAAAAAckbWF0Y2gwBQAAAAJ0eAkAAfQAAAADCAUAAAACdHgAAAAJYm9keUJ5dGVzCQABkQAAAAIIBQAAAAJ0eAAAAAZwcm9vZnMAAAAAAAAAAAAIBQAAAAJ0eAAAAA9zZW5kZXJQdWJsaWNLZXl2v3ww", "height": 1433042, "applicationStatus": "succeeded", "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 | + | let dAppAddres = "F9DCGiYgT8yvBq1AQFcSpGG4p8sdzNz9mZczDvJ45LL" | |
5 | + | ||
6 | + | let tokenAssetId = "5ih9jd4KV9kSey55yvKMgLSHcwsYYkQ4pRDJtRNoxUhy" | |
7 | + | ||
8 | + | let useGarlicCoin = false | |
9 | + | ||
10 | + | let tokensPerPlay = 100 | |
11 | + | ||
12 | + | let lotteryamount = "_amount" | |
13 | + | ||
14 | + | let lotteryprobability = "_probability" | |
15 | + | ||
16 | + | let lotteryprobabilitydecimal = "_probability_decimal" | |
17 | + | ||
18 | + | let lotteryWinningAddress = "_winning_address" | |
19 | + | ||
20 | + | let lotteryPrice = "_price" | |
21 | + | ||
22 | + | let lotteryPrices = "_lottery_prices" | |
23 | + | ||
24 | + | let lotteryAssetId = "_lottery_asset_id" | |
25 | + | ||
26 | + | let countOfPrices = "_count_prices" | |
27 | + | ||
28 | + | let lastHashRandomNumber = "last_spin_random_hash" | |
29 | + | ||
30 | + | let allowSizeLottery = 2 | |
31 | + | ||
32 | + | let totalPricesInPool = "total_prizes_pool" | |
33 | + | ||
34 | + | let tokenAId = "f2MzwrmN5wiMn5DwbBL33247fdsf432FV9kSe" | |
35 | + | ||
36 | + | let tokenBId = "f1MzwrmN4wiMn4DwbBL43242fsdf434Ffsdfs" | |
37 | + | ||
38 | + | func randomizer (inv) = { | |
39 | + | let lastPlay = match getBinary(this, lastHashRandomNumber) { | |
40 | + | case s: ByteVector => | |
41 | + | s | |
42 | + | case _: Unit => | |
43 | + | base58'2ee4oFDYriWJ9EMeR' | |
44 | + | case _ => | |
45 | + | throw("Match error") | |
46 | + | } | |
47 | + | let rand = (((((lastPlay + inv.transactionId) + inv.callerPublicKey) + lastBlock.generationSignature) + toBytes(lastBlock.timestamp)) + toBytes(lastBlock.height)) | |
48 | + | sha256(rand) | |
49 | + | } | |
50 | + | ||
51 | + | ||
52 | + | func getPriceArray () = { | |
53 | + | let currentPrices = match getString(this, lotteryPrices) { | |
54 | + | case a: String => | |
55 | + | a | |
56 | + | case _: Unit => | |
57 | + | "" | |
58 | + | case _ => | |
59 | + | throw("Match error") | |
60 | + | } | |
61 | + | let sizePrices = size(currentPrices) | |
62 | + | if ((sizePrices == 0)) | |
63 | + | then nil | |
64 | + | else { | |
65 | + | let trimPrices = take(currentPrices, (size(currentPrices) - 1)) | |
66 | + | let newArray = split(trimPrices, ",") | |
67 | + | newArray | |
68 | + | } | |
69 | + | } | |
70 | + | ||
71 | + | ||
72 | + | func getCurrentBalance () = if ((useGarlicCoin == true)) | |
73 | + | then assetBalance(this, fromBase58String(tokenAssetId)) | |
74 | + | else wavesBalance(this) | |
75 | + | ||
76 | + | ||
77 | + | func procedLottery (win,token) = if (if (isDefined(token)) | |
78 | + | then true | |
79 | + | else (token != "")) | |
80 | + | then { | |
81 | + | let tokenProbability = getIntegerValue(this, (token + lotteryprobability)) | |
82 | + | let tokenProbabilityDecimal = getIntegerValue(this, (token + lotteryprobabilitydecimal)) | |
83 | + | let sizeOfWin = size(win) | |
84 | + | if ((sizeOfWin == 1)) | |
85 | + | then { | |
86 | + | let randomNumber = win[0] | |
87 | + | let convertedRandomNumber = fromBase64String(randomNumber) | |
88 | + | let convertedDecimalNumber = (tokenProbabilityDecimal * 1000) | |
89 | + | let comparisonNumber = (toInt(convertedRandomNumber) % convertedDecimalNumber) | |
90 | + | if ((tokenProbability > comparisonNumber)) | |
91 | + | then token :: win | |
92 | + | else win | |
93 | + | } | |
94 | + | else win | |
95 | + | } | |
96 | + | else win | |
97 | + | ||
98 | + | ||
99 | + | @Callable(i) | |
100 | + | func setGarlicCoinLottery () = { | |
101 | + | let balance = getCurrentBalance() | |
102 | + | if ((69 > balance)) | |
103 | + | then throw("Not enought Amount") | |
104 | + | else { | |
105 | + | let storedTokensValues = ((tokenAId + ",") + tokenBId) | |
106 | + | if (useGarlicCoin) | |
107 | + | then { | |
108 | + | let updateLotteryPool = WriteSet([DataEntry((tokenAId + lotteryprobability), 69), DataEntry((tokenAId + lotteryPrice), 69), DataEntry((tokenAId + lotteryprobabilitydecimal), 10000), DataEntry((tokenAId + lotteryAssetId), tokenAssetId), DataEntry((tokenBId + lotteryamount), 6900000000), DataEntry((tokenBId + lotteryprobability), 69), DataEntry((tokenBId + lotteryPrice), 6900000000), DataEntry((tokenBId + lotteryprobabilitydecimal), 1000), DataEntry((tokenBId + lotteryAssetId), tokenAssetId), DataEntry(lotteryPrices, storedTokensValues), DataEntry(countOfPrices, 2)]) | |
109 | + | ScriptResult(updateLotteryPool, TransferSet(nil)) | |
110 | + | } | |
111 | + | else { | |
112 | + | let updateLotteryPool = WriteSet([DataEntry((tokenAId + lotteryprobability), 69), DataEntry((tokenAId + lotteryPrice), 69), DataEntry((tokenAId + lotteryprobabilitydecimal), 10000), DataEntry((tokenAId + lotteryAssetId), ""), DataEntry((tokenBId + lotteryamount), 6900000000), DataEntry((tokenBId + lotteryprobability), 69), DataEntry((tokenBId + lotteryPrice), 6900000000), DataEntry((tokenBId + lotteryprobabilitydecimal), 1000), DataEntry((tokenBId + lotteryAssetId), ""), DataEntry(lotteryPrices, storedTokensValues), DataEntry(countOfPrices, 2)]) | |
113 | + | ScriptResult(updateLotteryPool, TransferSet(nil)) | |
114 | + | } | |
115 | + | } | |
116 | + | } | |
117 | + | ||
118 | + | ||
119 | + | ||
120 | + | @Callable(i) | |
121 | + | func startlotto () = { | |
122 | + | let paymentIsDefined = if (!(isDefined(i.payment))) | |
123 | + | then false | |
124 | + | else true | |
125 | + | if ((paymentIsDefined == true)) | |
126 | + | then { | |
127 | + | let pmt = extract(i.payment) | |
128 | + | if (if ((pmt.assetId != fromBase58String(tokenAssetId))) | |
129 | + | then true | |
130 | + | else (pmt.amount != tokensPerPlay)) | |
131 | + | then throw("Incorrect asset passed or incorrect quantity passed") | |
132 | + | else { | |
133 | + | let currentKey = toBase58String(i.caller.bytes) | |
134 | + | let randhash = randomizer(i) | |
135 | + | let countTokens = match getInteger(this, countOfPrices) { | |
136 | + | case a: Int => | |
137 | + | a | |
138 | + | case _: Unit => | |
139 | + | 0 | |
140 | + | case _ => | |
141 | + | throw("Match error") | |
142 | + | } | |
143 | + | let priceList = getPriceArray() | |
144 | + | let randNumber = toBase64String(randhash) | |
145 | + | let updNumber = fromBase64String(randNumber) | |
146 | + | let listWinningPrices = [randNumber] | |
147 | + | let winningToken = { | |
148 | + | let $list60436095 = priceList | |
149 | + | let $size60436095 = size($list60436095) | |
150 | + | let $acc060436095 = listWinningPrices | |
151 | + | if (($size60436095 == 0)) | |
152 | + | then $acc060436095 | |
153 | + | else { | |
154 | + | let $acc160436095 = procedLottery($acc060436095, $list60436095[0]) | |
155 | + | if (($size60436095 == 1)) | |
156 | + | then $acc160436095 | |
157 | + | else { | |
158 | + | let $acc260436095 = procedLottery($acc160436095, $list60436095[1]) | |
159 | + | if (($size60436095 == 2)) | |
160 | + | then $acc260436095 | |
161 | + | else { | |
162 | + | let $acc360436095 = procedLottery($acc260436095, $list60436095[2]) | |
163 | + | if (($size60436095 == 3)) | |
164 | + | then $acc360436095 | |
165 | + | else { | |
166 | + | let $acc460436095 = procedLottery($acc360436095, $list60436095[3]) | |
167 | + | if (($size60436095 == 4)) | |
168 | + | then $acc460436095 | |
169 | + | else { | |
170 | + | let $acc560436095 = procedLottery($acc460436095, $list60436095[4]) | |
171 | + | throw("List size exceed 4") | |
172 | + | } | |
173 | + | } | |
174 | + | } | |
175 | + | } | |
176 | + | } | |
177 | + | } | |
178 | + | let sizeOfWinPrices = size(winningToken) | |
179 | + | if ((sizeOfWinPrices == 1)) | |
180 | + | then { | |
181 | + | let writeSets = WriteSet([DataEntry("message", "<h1>Better luck next time!</h1><br><p>Invite more friends to keep playing!<p>"), DataEntry(lastHashRandomNumber, randNumber)]) | |
182 | + | ScriptResult(writeSets, TransferSet(nil)) | |
183 | + | } | |
184 | + | else { | |
185 | + | let token = winningToken[0] | |
186 | + | let callerAddress = toBase58String(i.caller.bytes) | |
187 | + | let addressBalance = getCurrentBalance() | |
188 | + | if ((addressBalance == 0)) | |
189 | + | then throw("Not Enough Garlic Coin") | |
190 | + | else if ((token == tokenAId)) | |
191 | + | then { | |
192 | + | let lotteryPriceTokenA = match getInteger(this, (tokenAId + lotteryPrice)) { | |
193 | + | case t: Int => | |
194 | + | t | |
195 | + | case _: Unit => | |
196 | + | 0 | |
197 | + | case _ => | |
198 | + | throw("Match error") | |
199 | + | } | |
200 | + | let winningAmount = (lotteryPriceTokenA * addressBalance) | |
201 | + | let writeSets = WriteSet([DataEntry((token + lotteryamount), winningAmount), DataEntry((token + lotteryWinningAddress), callerAddress), DataEntry(lastHashRandomNumber, randNumber), DataEntry("message", (((("<h1>Congratulations you won!</h1><br><p>You have won " + toString(winningAmount)) + " ") + token) + "!<p>"))]) | |
202 | + | if (useGarlicCoin) | |
203 | + | then { | |
204 | + | let winTransfer = TransferSet([ScriptTransfer(i.caller, winningAmount, fromBase58String(tokenAssetId))]) | |
205 | + | ScriptResult(writeSets, winTransfer) | |
206 | + | } | |
207 | + | else { | |
208 | + | let winTransfer = TransferSet([ScriptTransfer(i.caller, winningAmount, unit)]) | |
209 | + | ScriptResult(writeSets, winTransfer) | |
210 | + | } | |
211 | + | } | |
212 | + | else if ((token == tokenBId)) | |
213 | + | then { | |
214 | + | let lotteryPriceTokenB = match getInteger(this, (tokenBId + lotteryprobability)) { | |
215 | + | case t: Int => | |
216 | + | t | |
217 | + | case _: Unit => | |
218 | + | 0 | |
219 | + | case _ => | |
220 | + | throw("Match error") | |
221 | + | } | |
222 | + | let writeSets = WriteSet([DataEntry((token + lotteryamount), lotteryPriceTokenB), DataEntry(lastHashRandomNumber, randNumber), DataEntry((token + lotteryWinningAddress), callerAddress), DataEntry("message", (((("<h1>Congratulations you won!</h1><br><p>You have won " + toString(lotteryPriceTokenB)) + " ") + token) + "!<p>"))]) | |
223 | + | if (useGarlicCoin) | |
224 | + | then { | |
225 | + | let winTransfer = TransferSet([ScriptTransfer(i.caller, lotteryPriceTokenB, fromBase58String(tokenAssetId))]) | |
226 | + | ScriptResult(writeSets, winTransfer) | |
227 | + | } | |
228 | + | else { | |
229 | + | let winTransfer = TransferSet([ScriptTransfer(i.caller, lotteryPriceTokenB, unit)]) | |
230 | + | ScriptResult(writeSets, winTransfer) | |
231 | + | } | |
232 | + | } | |
233 | + | else { | |
234 | + | let writeSets = WriteSet([DataEntry("message", "<h1>Better luck next time!</h1><br><p>Invite more friends to keep playing!<p>"), DataEntry(lastHashRandomNumber, randNumber)]) | |
235 | + | let winTransfer = TransferSet(nil) | |
236 | + | ScriptResult(writeSets, TransferSet(nil)) | |
237 | + | } | |
238 | + | } | |
239 | + | } | |
240 | + | } | |
241 | + | else throw((("You need " + tokenAssetId) + " to play this game.")) | |
242 | + | } | |
243 | + | ||
244 | + | ||
245 | + | @Verifier(tx) | |
246 | + | func verify () = match tx { | |
247 | + | case _ => | |
248 | + | sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey) | |
249 | + | } | |
250 | + |
github/deemru/w8io/169f3d6 23.53 ms ◑