tx · 2LouZuo7GwERSnjGuJxuD3Dff1jw6HpgvLUTSqs6EJ5G

3N6hQF6HBBQ5JCKB8Xs17Q61wkG3VrLvbGd:  -0.10100000 Waves

2021.12.03 05:24 [1817493] smart account 3N6hQF6HBBQ5JCKB8Xs17Q61wkG3VrLvbGd > SELF 0.00000000 Waves

{ "type": 13, "id": "2LouZuo7GwERSnjGuJxuD3Dff1jw6HpgvLUTSqs6EJ5G", "fee": 10100000, "feeAssetId": null, "timestamp": 1638498262470, "version": 2, "chainId": 84, "sender": "3N6hQF6HBBQ5JCKB8Xs17Q61wkG3VrLvbGd", "senderPublicKey": "7Hi4o6vBstRs79NMVMjEove52dmP87RAcvNDAXN8C4Wi", "proofs": [ "5sg5bMt1vCpaQiyvWKGPbh8GFEhjkqENcedvdAE72owJHHjxnYqfD6uxKxJNTpXErkniH38QeaKgrWjk43efeicF" ], "script": "base64:AAIFAAAAAAAAAA4IAhIAEgMKAQESAwoBAQAAAAwAAAAACXNlcGFyYXRvcgIAAAABLAEAAAAKZ2V0TmV3RGVjawAAAAAJAARMAAAAAgIAAAADMDFDCQAETAAAAAICAAAAAzAyQwkABEwAAAACAgAAAAMwM0MJAARMAAAAAgIAAAADMDRDCQAETAAAAAICAAAAAzA1QwkABEwAAAACAgAAAAMwNkMJAARMAAAAAgIAAAADMDdDCQAETAAAAAICAAAAAzA4QwkABEwAAAACAgAAAAMwOUMJAARMAAAAAgIAAAADMTBDCQAETAAAAAICAAAAAzExQwkABEwAAAACAgAAAAMxMkMJAARMAAAAAgIAAAADMTNDCQAETAAAAAICAAAAAzAxRAkABEwAAAACAgAAAAMwMkQJAARMAAAAAgIAAAADMDNECQAETAAAAAICAAAAAzA0RAkABEwAAAACAgAAAAMwNUQJAARMAAAAAgIAAAADMDZECQAETAAAAAICAAAAAzA3RAkABEwAAAACAgAAAAMwOEQJAARMAAAAAgIAAAADMDlECQAETAAAAAICAAAAAzEwRAkABEwAAAACAgAAAAMxMUQJAARMAAAAAgIAAAADMT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GVzCQABkQAAAAIIBQAAAAJ0eAAAAAZwcm9vZnMAAAAAAAAAAAAIBQAAAAJ0eAAAAA9zZW5kZXJQdWJsaWNLZXkwgZys", "height": 1817493, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 3PUdTEN6Vzg4KtYyUqpLu7DJDXZsY5a545Q3F1hbj34o Next: BfYdezzdzLy4uDFu2pHoJB9EDmGqM81MWcEyxhEEbPXg Diff:
OldNewDifferences
103103 @Callable(i)
104104 func bet () = {
105105 let callerAddress = toBase58String(i.caller.bytes)
106- let $t032983324 = getPayments(i)
107- let p = $t032983324._1
108- let t = $t032983324._2
106+ let $t031983224 = getPayments(i)
107+ let p = $t031983224._1
108+ let t = $t031983224._2
109109 let currentRound = match getInteger(this, (callerAddress + "_round")) {
110110 case a: Int =>
111111 (a + 1)
120120 else {
121121 let availableProp = (round + "_deck")
122122 let avDeck = getAvailableDeck(this, availableProp)
123- let $t038043911 = getPlayerCardAndPositionAndUpdateDeck(round, round, avDeck)
124- let cardPlayer = $t038043911._1
125- let cardPositionPlayer = $t038043911._2
126- let avDeck1 = $t038043911._3
127- let $t039164035 = getPlayerCardAndPositionAndUpdateDeck((round + cardPlayer), round, avDeck1)
128- let cardCasino = $t039164035._1
129- let cardPositionCasino = $t039164035._2
130- let avDeck2 = $t039164035._3
123+ let $t037043811 = getPlayerCardAndPositionAndUpdateDeck(round, round, avDeck)
124+ let cardPlayer = $t037043811._1
125+ let cardPositionPlayer = $t037043811._2
126+ let avDeck1 = $t037043811._3
127+ let $t038163935 = getPlayerCardAndPositionAndUpdateDeck((round + cardPlayer), round, avDeck1)
128+ let cardCasino = $t038163935._1
129+ let cardPositionCasino = $t038163935._2
130+ let avDeck2 = $t038163935._3
131131 if ((getCardValue(cardPlayer) == getCardValue(cardCasino)))
132132 then {
133133 let currentDraws = 1
185185 case _ =>
186186 throw("Unable to find original bet amount")
187187 }
188- let $t086108636 = getPayments(i)
189- let p = $t086108636._1
190- let t = $t086108636._2
188+ let $t085108536 = getPayments(i)
189+ let p = $t085108536._1
190+ let t = $t085108536._2
191191 if ((p != betAmount))
192192 then throw((((("original bet amount (" + toString(betAmount)) + ") different to the current payment (") + toString(p)) + ")"))
193193 else {
194194 let availableProp = (round + "_deck")
195195 let avDeck = getAvailableDeck(this, availableProp)
196- let $t089269026 = getPlayerCardAndPositionAndUpdateDeck(round, round, avDeck)
197- let burned1 = $t089269026._1
198- let burnedPos1 = $t089269026._2
199- let burnedDeck1 = $t089269026._3
200- let $t090399152 = getPlayerCardAndPositionAndUpdateDeck((round + burned1), round, burnedDeck1)
201- let burned2 = $t090399152._1
202- let burnedPos2 = $t090399152._2
203- let burnedDeck2 = $t090399152._3
204- let $t091659278 = getPlayerCardAndPositionAndUpdateDeck((round + burned2), round, burnedDeck2)
205- let burned3 = $t091659278._1
206- let burnedPos3 = $t091659278._2
207- let burnedDeck3 = $t091659278._3
208- let $t092919411 = getPlayerCardAndPositionAndUpdateDeck((round + burned3), round, burnedDeck3)
209- let cardPlayer = $t092919411._1
210- let cardPositionPlayer = $t092919411._2
211- let avDeck1 = $t092919411._3
212- let $t094249543 = getPlayerCardAndPositionAndUpdateDeck((round + cardPlayer), round, avDeck1)
213- let cardCasino = $t094249543._1
214- let cardPositionCasino = $t094249543._2
215- let avDeck2 = $t094249543._3
196+ let $t088268926 = getPlayerCardAndPositionAndUpdateDeck(round, round, avDeck)
197+ let burned1 = $t088268926._1
198+ let burnedPos1 = $t088268926._2
199+ let burnedDeck1 = $t088268926._3
200+ let $t089399052 = getPlayerCardAndPositionAndUpdateDeck((round + burned1), round, burnedDeck1)
201+ let burned2 = $t089399052._1
202+ let burnedPos2 = $t089399052._2
203+ let burnedDeck2 = $t089399052._3
204+ let $t090659178 = getPlayerCardAndPositionAndUpdateDeck((round + burned2), round, burnedDeck2)
205+ let burned3 = $t090659178._1
206+ let burnedPos3 = $t090659178._2
207+ let burnedDeck3 = $t090659178._3
208+ let $t091919311 = getPlayerCardAndPositionAndUpdateDeck((round + burned3), round, burnedDeck3)
209+ let cardPlayer = $t091919311._1
210+ let cardPositionPlayer = $t091919311._2
211+ let avDeck1 = $t091919311._3
212+ let $t093249443 = getPlayerCardAndPositionAndUpdateDeck((round + cardPlayer), round, avDeck1)
213+ let cardCasino = $t093249443._1
214+ let cardPositionCasino = $t093249443._2
215+ let avDeck2 = $t093249443._3
216216 if ((getCardValue(cardPlayer) == getCardValue(cardCasino)))
217217 then {
218218 let currentDraws = match getInteger(this, (round + "_drawSequence")) {
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let separator = ","
55
66 func getNewDeck () = ["01C", "02C", "03C", "04C", "05C", "06C", "07C", "08C", "09C", "10C", "11C", "12C", "13C", "01D", "02D", "03D", "04D", "05D", "06D", "07D", "08D", "09D", "10D", "11D", "12D", "13D", "01H", "02H", "03H", "04H", "05H", "06H", "07H", "08H", "09H", "10H", "11H", "12H", "13H", "01S", "02S", "03S", "04S", "05S", "06S", "07S", "08S", "09S", "10S", "11S", "12S", "13S"]
77
88
99 func getSixNewDecks () = (((((getNewDeck() ++ getNewDeck()) ++ getNewDeck()) ++ getNewDeck()) ++ getNewDeck()) ++ getNewDeck())
1010
1111
1212 func getDeck (deck) = if ((0 >= size(deck)))
1313 then getSixNewDecks()
1414 else deck
1515
1616
1717 func getRandomNumber (salt1,salt2,answersCount) = {
1818 let hash = sha256(toBytes((salt1 + salt2)))
1919 let index = toInt(hash)
2020 let rand = (index % answersCount)
2121 if ((0 > rand))
2222 then ((-1 * rand) + 1)
2323 else (rand + 1)
2424 }
2525
2626
2727 func getPreviousRandomNumber (address) = match getInteger(this, (address + "_LastRandonNumber")) {
2828 case n: Int =>
2929 toString(n)
3030 case _ =>
3131 address
3232 }
3333
3434
3535 func getPayments (i) = if ((size(i.payments) == 0))
3636 then throw("Payment must be attached")
3737 else if ((size(i.payments) == 1))
3838 then {
3939 let pmt = i.payments[0]
4040 if (isDefined(pmt.assetId))
4141 then throw("This function accepts WAVES tokens only (0)")
4242 else $Tuple2(pmt.amount, 0)
4343 }
4444 else {
4545 let pmt = i.payments[0]
4646 if (isDefined(pmt.assetId))
4747 then throw("This function accepts WAVES tokens only (10)")
4848 else {
4949 let pmt2 = i.payments[1]
5050 if (isDefined(pmt2.assetId))
5151 then throw("This function accepts WAVES tokens only (11)")
5252 else $Tuple2(pmt.amount, pmt2.amount)
5353 }
5454 }
5555
5656
5757 func getCardValue (stringCard) = {
5858 let p = parseIntValue(take(stringCard, 2))
5959 if ((p == 1))
6060 then 20
6161 else p
6262 }
6363
6464
6565 func isPlayerWinner (cardPlayer,cardCasino) = {
6666 let p = getCardValue(cardPlayer)
6767 let o = getCardValue(cardCasino)
6868 (p > o)
6969 }
7070
7171
7272 func getAvailableDeck (this,availableProp) = if (isDefined(getString(this, availableProp)))
7373 then {
7474 let stringDeck = getStringValue(this, availableProp)
7575 let deck = split(stringDeck, separator)
7676 getDeck(deck)
7777 }
7878 else getSixNewDecks()
7979
8080
8181 func getPlayerCardAndPositionAndUpdateDeck (meKey,callerAddress,deck) = {
8282 let avDeck2 = getDeck(deck)
8383 let cardPosition = getRandomNumber(((meKey + makeString(avDeck2, separator)) + callerAddress), getPreviousRandomNumber(callerAddress), size(avDeck2))
8484 let card = avDeck2[(cardPosition % size(avDeck2))]
8585 let avDeck3 = removeByIndex(avDeck2, (cardPosition % size(avDeck2)))
8686 $Tuple3(card, cardPosition, avDeck3)
8787 }
8888
8989
9090 func getCurrentRound (customRound,callerAddress) = if ((customRound == 0))
9191 then {
9292 let currentRound = match getInteger(this, (callerAddress + "_round")) {
9393 case a: Int =>
9494 a
9595 case _ =>
9696 throw("Unable to find the round")
9797 }
9898 currentRound
9999 }
100100 else customRound
101101
102102
103103 @Callable(i)
104104 func bet () = {
105105 let callerAddress = toBase58String(i.caller.bytes)
106- let $t032983324 = getPayments(i)
107- let p = $t032983324._1
108- let t = $t032983324._2
106+ let $t031983224 = getPayments(i)
107+ let p = $t031983224._1
108+ let t = $t031983224._2
109109 let currentRound = match getInteger(this, (callerAddress + "_round")) {
110110 case a: Int =>
111111 (a + 1)
112112 case _ =>
113113 1
114114 }
115115 let round = ((callerAddress + "_") + toString(currentRound))
116116 if (isDefined(getBoolean(this, (round + "_stop"))))
117117 then throw("This round is already played")
118118 else if (isDefined(getString(this, round)))
119119 then throw("You cannot bet on this game")
120120 else {
121121 let availableProp = (round + "_deck")
122122 let avDeck = getAvailableDeck(this, availableProp)
123- let $t038043911 = getPlayerCardAndPositionAndUpdateDeck(round, round, avDeck)
124- let cardPlayer = $t038043911._1
125- let cardPositionPlayer = $t038043911._2
126- let avDeck1 = $t038043911._3
127- let $t039164035 = getPlayerCardAndPositionAndUpdateDeck((round + cardPlayer), round, avDeck1)
128- let cardCasino = $t039164035._1
129- let cardPositionCasino = $t039164035._2
130- let avDeck2 = $t039164035._3
123+ let $t037043811 = getPlayerCardAndPositionAndUpdateDeck(round, round, avDeck)
124+ let cardPlayer = $t037043811._1
125+ let cardPositionPlayer = $t037043811._2
126+ let avDeck1 = $t037043811._3
127+ let $t038163935 = getPlayerCardAndPositionAndUpdateDeck((round + cardPlayer), round, avDeck1)
128+ let cardCasino = $t038163935._1
129+ let cardPositionCasino = $t038163935._2
130+ let avDeck2 = $t038163935._3
131131 if ((getCardValue(cardPlayer) == getCardValue(cardCasino)))
132132 then {
133133 let currentDraws = 1
134134 if ((t != 0))
135135 then [StringEntry(availableProp, makeString(avDeck2, separator)), IntegerEntry((callerAddress + "_round"), currentRound), BooleanEntry(round, true), IntegerEntry((round + "_LastRandonNumber"), cardPositionCasino), StringEntry((round + "_playerCard"), cardPlayer), StringEntry((round + "_casinoCard"), cardCasino), IntegerEntry((round + "_drawSequence"), currentDraws), IntegerEntry((round + "_betAmount"), p), ScriptTransfer(i.caller, ((t * 10) + t), unit)]
136136 else [StringEntry(availableProp, makeString(avDeck2, separator)), IntegerEntry((callerAddress + "_round"), currentRound), BooleanEntry(round, true), IntegerEntry((round + "_LastRandonNumber"), cardPositionCasino), StringEntry((round + "_playerCard"), cardPlayer), StringEntry((round + "_casinoCard"), cardCasino), IntegerEntry((round + "_drawSequence"), currentDraws), IntegerEntry((round + "_betAmount"), p)]
137137 }
138138 else if (isPlayerWinner(cardPlayer, cardCasino))
139139 then [StringEntry(availableProp, makeString(avDeck2, separator)), BooleanEntry(round, true), IntegerEntry((callerAddress + "_round"), currentRound), IntegerEntry((round + "_LastRandonNumber"), cardPositionCasino), StringEntry((round + "_playerCard"), cardPlayer), StringEntry((round + "_casinoCard"), cardCasino), IntegerEntry((round + "_betAmount"), p), ScriptTransfer(i.caller, p, unit), BooleanEntry((round + "_stop"), true)]
140140 else [StringEntry(availableProp, makeString(avDeck2, separator)), BooleanEntry(round, true), IntegerEntry((callerAddress + "_round"), currentRound), IntegerEntry((round + "_LastRandonNumber"), cardPositionCasino), StringEntry((round + "_playerCard"), cardPlayer), StringEntry((round + "_casinoCard"), cardCasino), IntegerEntry((round + "_betAmount"), p), BooleanEntry((round + "_stop"), true)]
141141 }
142142 }
143143
144144
145145
146146 @Callable(i)
147147 func surrender (customRound) = {
148148 let callerAddress = toBase58String(i.caller.bytes)
149149 let roundToUse = getCurrentRound(customRound, callerAddress)
150150 let round = ((callerAddress + "_") + toString(roundToUse))
151151 if (!(isDefined(getBoolean(this, round))))
152152 then throw("This round is not played")
153153 else if (isDefined(getBoolean(this, (round + "_stop"))))
154154 then throw("This round is already played")
155155 else if (!(isDefined(getInteger(this, (round + "_drawSequence")))))
156156 then throw("This game is not on war")
157157 else {
158158 let betAmount = match getInteger(this, (round + "_betAmount")) {
159159 case a: Int =>
160160 a
161161 case _ =>
162162 throw("Unable to find original bet amount")
163163 }
164164 [ScriptTransfer(i.caller, (betAmount / 2), unit), BooleanEntry((round + "_stop"), true)]
165165 }
166166 }
167167
168168
169169
170170 @Callable(i)
171171 func goToWar (customRound) = {
172172 let callerAddress = toBase58String(i.caller.bytes)
173173 let roundToUse = getCurrentRound(customRound, callerAddress)
174174 let round = ((callerAddress + "_") + toString(roundToUse))
175175 if (!(isDefined(getBoolean(this, round))))
176176 then throw("This round is not played")
177177 else if (isDefined(getBoolean(this, (round + "_stop"))))
178178 then throw("This round is already played")
179179 else if (!(isDefined(getInteger(this, (round + "_drawSequence")))))
180180 then throw("This game is not on war")
181181 else {
182182 let betAmount = match getInteger(this, (round + "_betAmount")) {
183183 case a: Int =>
184184 a
185185 case _ =>
186186 throw("Unable to find original bet amount")
187187 }
188- let $t086108636 = getPayments(i)
189- let p = $t086108636._1
190- let t = $t086108636._2
188+ let $t085108536 = getPayments(i)
189+ let p = $t085108536._1
190+ let t = $t085108536._2
191191 if ((p != betAmount))
192192 then throw((((("original bet amount (" + toString(betAmount)) + ") different to the current payment (") + toString(p)) + ")"))
193193 else {
194194 let availableProp = (round + "_deck")
195195 let avDeck = getAvailableDeck(this, availableProp)
196- let $t089269026 = getPlayerCardAndPositionAndUpdateDeck(round, round, avDeck)
197- let burned1 = $t089269026._1
198- let burnedPos1 = $t089269026._2
199- let burnedDeck1 = $t089269026._3
200- let $t090399152 = getPlayerCardAndPositionAndUpdateDeck((round + burned1), round, burnedDeck1)
201- let burned2 = $t090399152._1
202- let burnedPos2 = $t090399152._2
203- let burnedDeck2 = $t090399152._3
204- let $t091659278 = getPlayerCardAndPositionAndUpdateDeck((round + burned2), round, burnedDeck2)
205- let burned3 = $t091659278._1
206- let burnedPos3 = $t091659278._2
207- let burnedDeck3 = $t091659278._3
208- let $t092919411 = getPlayerCardAndPositionAndUpdateDeck((round + burned3), round, burnedDeck3)
209- let cardPlayer = $t092919411._1
210- let cardPositionPlayer = $t092919411._2
211- let avDeck1 = $t092919411._3
212- let $t094249543 = getPlayerCardAndPositionAndUpdateDeck((round + cardPlayer), round, avDeck1)
213- let cardCasino = $t094249543._1
214- let cardPositionCasino = $t094249543._2
215- let avDeck2 = $t094249543._3
196+ let $t088268926 = getPlayerCardAndPositionAndUpdateDeck(round, round, avDeck)
197+ let burned1 = $t088268926._1
198+ let burnedPos1 = $t088268926._2
199+ let burnedDeck1 = $t088268926._3
200+ let $t089399052 = getPlayerCardAndPositionAndUpdateDeck((round + burned1), round, burnedDeck1)
201+ let burned2 = $t089399052._1
202+ let burnedPos2 = $t089399052._2
203+ let burnedDeck2 = $t089399052._3
204+ let $t090659178 = getPlayerCardAndPositionAndUpdateDeck((round + burned2), round, burnedDeck2)
205+ let burned3 = $t090659178._1
206+ let burnedPos3 = $t090659178._2
207+ let burnedDeck3 = $t090659178._3
208+ let $t091919311 = getPlayerCardAndPositionAndUpdateDeck((round + burned3), round, burnedDeck3)
209+ let cardPlayer = $t091919311._1
210+ let cardPositionPlayer = $t091919311._2
211+ let avDeck1 = $t091919311._3
212+ let $t093249443 = getPlayerCardAndPositionAndUpdateDeck((round + cardPlayer), round, avDeck1)
213+ let cardCasino = $t093249443._1
214+ let cardPositionCasino = $t093249443._2
215+ let avDeck2 = $t093249443._3
216216 if ((getCardValue(cardPlayer) == getCardValue(cardCasino)))
217217 then {
218218 let currentDraws = match getInteger(this, (round + "_drawSequence")) {
219219 case a: Int =>
220220 (a + 1)
221221 case _ =>
222222 0
223223 }
224224 [StringEntry(availableProp, makeString(avDeck2, separator)), IntegerEntry((round + "_LastRandonNumber"), cardPositionCasino), StringEntry((round + "_playerCard"), cardPlayer), StringEntry((round + "_casinoCard"), cardCasino), IntegerEntry((round + "_drawSequence"), currentDraws), IntegerEntry((round + "_betAmount"), p)]
225225 }
226226 else if (isPlayerWinner(cardPlayer, cardCasino))
227227 then [StringEntry(availableProp, makeString(avDeck2, separator)), IntegerEntry((round + "_LastRandonNumber"), cardPositionCasino), StringEntry((round + "_playerCard"), cardPlayer), StringEntry((round + "_casinoCard"), cardCasino), IntegerEntry((round + "_betAmount"), p), ScriptTransfer(i.caller, p, unit), BooleanEntry((round + "_stop"), true)]
228228 else [StringEntry(availableProp, makeString(avDeck2, separator)), StringEntry((round + "_round"), round), IntegerEntry((round + "_LastRandonNumber"), cardPositionCasino), StringEntry((round + "_playerCard"), cardPlayer), StringEntry((round + "_casinoCard"), cardCasino), IntegerEntry((round + "_betAmount"), p), BooleanEntry((round + "_stop"), true)]
229229 }
230230 }
231231 }
232232
233233
234234 @Verifier(tx)
235235 func verify () = sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey)
236236

github/deemru/w8io/169f3d6 
105.57 ms