tx · F2HVPdw1QQEz2xHdBboLG8Ew8uYRh8ephisaKa6nZe2c

3N651uAzJgHyoDMmYL4pNk5ixG7ZEDGWK1W:  -0.01000000 Waves

2021.02.19 12:31 [1404857] smart account 3N651uAzJgHyoDMmYL4pNk5ixG7ZEDGWK1W > SELF 0.00000000 Waves

{ "type": 13, "id": "F2HVPdw1QQEz2xHdBboLG8Ew8uYRh8ephisaKa6nZe2c", "fee": 1000000, "feeAssetId": null, "timestamp": 1613727054927, "version": 2, "chainId": 84, "sender": "3N651uAzJgHyoDMmYL4pNk5ixG7ZEDGWK1W", "senderPublicKey": "52DjTNxoyesAdLkKp9UJ7rN1X2NP5nnNvkHwKL29wbnZ", "proofs": [ "v8rYJiaLU9oS985Gvv8QtUa8tQDC9h8mBUgHY9eqNoxJ4XJZJr7SfcDf173hYzaBU54QMojykvrryrxCfwrUSoN" ], "script": "base64:AAIDAAAAAAAAAA4IARIAEgASBgoECAICAgAAACQAAAAADXJzYVB1YmxpY0tleTEJAAJbAAAAAQIAAACATUZ3d0RRWUpLb1pJaHZjTkFRRUJCUUFEU3dBd1NBSkJBT2tpdXovQlY0RWpveEdoVG1OQ2J0MlRna2JTUEgvdzY5YjNGMXJLbUQ2MUppUFh2dkY4TDJwSTl4T1ljVzRGbW9FWlZIbFJRdEFsYUp5a2wzK3JzckVDQXdFQUFRPT0AAAAADXJzYVB1YmxpY0tleTIJAAJbAAAAAQIAAACATUZ3d0RRWUpLb1pJaHZjTkFRRUJCUUFEU3dBd1NBSkJBSm5YemJNL1Yyc0RWMVVMYlBTT2xIa2xkT1RXUnJIaTVmeElrQm11ZXZyQ2xNUFZIN3JxY2N3aXJETmNNZElkd1hISTlBZGhqOUZXandHSXdmVS9LNk1DQXdFQUFRPT0AAAAADXJzYVB1YmxpY0tleTMJAAJbAAAAAQIAAACATUZ3d0RRWUpLb1pJaHZjTkFRRUJCUUFEU3dBd1NBSkJBT1JEZXZ5MHI0a3pMcU95U2xvQjYzSHV2MmU0emVIS0h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AAAABMgkABEwAAAACAgAAAAEzCQAETAAAAAICAAAAATUJAARMAAAAAgIAAAABMQkABEwAAAACAgAAAAE2CQAETAAAAAICAAAAATQJAARMAAAAAgIAAAABMgkABEwAAAACAgAAAAExCQAETAAAAAICAAAAATEJAARMAAAAAgIAAAABNAkABEwAAAACAgAAAAEyCQAETAAAAAICAAAAATEJAARMAAAAAgIAAAABNgkABEwAAAACAgAAAAEzCQAETAAAAAICAAAAATQJAARMAAAAAgIAAAABMQkABEwAAAACAgAAAAEyCQAETAAAAAICAAAAATUJAARMAAAAAgIAAAABNAkABEwAAAACAgAAAAExCQAETAAAAAICAAAAATUJAARMAAAAAgIAAAABMwkABEwAAAACAgAAAAEyCQAETAAAAAICAAAAATcJAARMAAAAAgIAAAABNQkABEwAAAACAgAAAAExCQAETAAAAAICAAAAATMFAAAAA25pbAAAAAAFZHJ1bTMJAARMAAAAAgIAAAABMwkABEwAAAACAgAAAAEyCQAETAAAAAICAAAAATUJAARMAAAAAgIAAAABMgkABEwAAAACAgAAAAE3CQAETAAAAAICAAAAATQJAARMAAAAAgIAAAABMQkABEwAAAACAgAAAAEzCQAETAAAAAICAAAAATYJAARMAAAAAgIAAAABNAkABEwAAAACAgAAAAEyCQAETAAAAAICAAAAATMJAARMAAAAAgIAAAABMQkABEwAAAACAgAAAAE2CQAETAAAAAICAAAAATQJAARMAAAAAgIAAAABMgkABEwAAAACAgAAAAExCQAETAAAAAICAAAAATUJAARMAAAAAgIAAAABMgkABEwAAAACAgAAAAE1CQAETAAAAAICAAAAATEJAARMAAAAAgIAAAABMwkABEwAAAACAgAAAAE3CQAETAAAAAICAAAAATEJAARMAAAAAgIAAAABMgkABEwAAAACAgAAAAE2CQAETAAAAAICAAAAATQJAARMAAAAAgIAAAABMQkABEwAAAACAgAAAAEzCQAETAAAAAICAAAAATEFAAAAA25pbAAAAAAIc3RhdGVBY2MCAAAACEFDQ0VQVEVEAAAAAAZiZXRXaW4CAAAAA1dPTgAAAAAHYmV0TG9z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gkAASwAAAACCQABLAAAAAIJAAEsAAAAAgkAASwAAAACCQABLAAAAAIJAAEsAAAAAgUAAAAHYmV0TG9zZQIAAAABXwkAAZEAAAACBQAAAAhkYXRhTGlzdAAAAAAAAAAAAQIAAAABXwkAAZEAAAACBQAAAAhkYXRhTGlzdAAAAAAAAAAAAgIAAAABXwkAAZEAAAACBQAAAAhkYXRhTGlzdAAAAAAAAAAAAwIAAAABXwkAAaQAAAABBQAAAAZoZWlnaHQCAAAAAV8JAAGkAAAAAQUAAAAJYW1vdW50V29uAgAAAAFfBQAAAAt0aHJlZUluQVJvdwIAAAABXwUAAAAPZWxlbWVudFRvU3RyaW5nBQAAAANuaWwJAAACAAAAAQIAAAAKQkVUX1BMQUNFRAkAAAIAAAABAgAAAApJTklUX0VSUk9SAAAAAQAAAAJ0eAEAAAAGdmVyaWZ5AAAAAAMJAAH0AAAAAwgFAAAAAnR4AAAACWJvZHlCeXRlcwkAAZEAAAACCAUAAAACdHgAAAAGcHJvb2ZzAAAAAAAAAAAABQAAAA1nYW1lUHVibGljS2V5BAAAAAckbWF0Y2gwBQAAAAJ0eAMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAAUU2V0U2NyaXB0VHJhbnNhY3Rpb24EAAAAAnR4BQAAAAckbWF0Y2gwBgcH5OVqDw==", "height": 1404857, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: none Next: none Full:
OldNewDifferences
1-# no script
1+{-# STDLIB_VERSION 3 #-}
2+{-# SCRIPT_TYPE ACCOUNT #-}
3+{-# CONTENT_TYPE DAPP #-}
4+let rsaPublicKey1 = fromBase64String("MFwwDQYJKoZIhvcNAQEBBQADSwAwSAJBAOkiuz/BV4EjoxGhTmNCbt2TgkbSPH/w69b3F1rKmD61JiPXvvF8L2pI9xOYcW4FmoEZVHlRQtAlaJykl3+rsrECAwEAAQ==")
5+
6+let rsaPublicKey2 = fromBase64String("MFwwDQYJKoZIhvcNAQEBBQADSwAwSAJBAJnXzbM/V2sDV1ULbPSOlHkldOTWRrHi5fxIkBmuevrClMPVH7rqccwirDNcMdIdwXHI9Adhj9FWjwGIwfU/K6MCAwEAAQ==")
7+
8+let rsaPublicKey3 = fromBase64String("MFwwDQYJKoZIhvcNAQEBBQADSwAwSAJBAORDevy0r4kzLqOySloB63Huv2e4zeHKHjCsy5vtFKmWZbXJa8gZYt4+EklFIo1K9oqu5BAPVfJ3FOzs2U1A+g0CAwEAAQ==")
9+
10+let gamePublicKey = fromBase58String("BjjwtwUgZ4s8p9HJuFwyRMR3egd3zMAHGDV2HoZ1J7ho")
11+
12+let gameAddress = addressFromPublicKey(gamePublicKey)
13+
14+let adminPublicKey = fromBase58String("52DjTNxoyesAdLkKp9UJ7rN1X2NP5nnNvkHwKL29wbnZ")
15+
16+let adminAddress = addressFromPublicKey(adminPublicKey)
17+
18+let drum1 = ["6", "1", "5", "4", "3", "2", "1", "3", "5", "2", "4", "1", "7", "3", "2", "3", "1", "4", "1", "3", "5", "2", "1", "4", "2", "6", "5", "2", "1", "4"]
19+
20+let drum2 = ["1", "3", "4", "2", "3", "5", "1", "6", "4", "2", "1", "1", "4", "2", "1", "6", "3", "4", "1", "2", "5", "4", "1", "5", "3", "2", "7", "5", "1", "3"]
21+
22+let drum3 = ["3", "2", "5", "2", "7", "4", "1", "3", "6", "4", "2", "3", "1", "6", "4", "2", "1", "5", "2", "5", "1", "3", "7", "1", "2", "6", "4", "1", "3", "1"]
23+
24+let stateAcc = "ACCEPTED"
25+
26+let betWin = "WON"
27+
28+let betLose = "LOST"
29+
30+let wavesId = unit
31+
32+let wavesMinAmt = 20000000
33+
34+let wavesMaxAmt = (wavesMinAmt * 10)
35+
36+let gamesLabelCounter = "X_GAMESCOUNTER"
37+
38+func gamesGetCounter () = getInteger(this, gamesLabelCounter)
39+
40+
41+func gameLabelStatus (STATUS) = (("G_" + STATUS) + "_STATUS")
42+
43+
44+func gameGetStatus (STATUS) = getString(this, gameLabelStatus(STATUS))
45+
46+
47+func gamesLabelId (gameId) = (gameId + "_GAMEID")
48+
49+
50+func gamesGetId (gameId) = getString(this, gamesLabelId(gameId))
51+
52+
53+func gamesLabelBet (gameBet) = (gameBet + "_BETDATA")
54+
55+
56+func gamesGetBet (gameBet) = getString(this, gamesLabelId(gameBet))
57+
58+
59+let gameLabelBetStatus = "BET_STATUS"
60+
61+func gameGetBetStatus () = getString(this, gameLabelBetStatus)
62+
63+
64+func addressLabelAmount (addr) = (("A_" + addr) + "_AMOUNT")
65+
66+
67+func addressGetAmount (addr) = getInteger(this, addressLabelAmount(addr))
68+
69+
70+func gameGetData (gameId) = {
71+ let gameData = gamesGetId(gameId)
72+ let a = match gameData {
73+ case a: String =>
74+ a
75+ case _ =>
76+ throw("Game Id was not found")
77+ }
78+ split(a, "_")
79+ }
80+
81+
82+func gameGetBetData (playersAddr) = {
83+ let gameBetData = gamesGetBet(playersAddr)
84+ let a = match gameBetData {
85+ case a: String =>
86+ a
87+ case _ =>
88+ throw("Player's Address was not found")
89+ }
90+ split(a, "_")
91+ }
92+
93+
94+func pmtAmtCheck (betAmount) = if (if ((betAmount >= wavesMinAmt))
95+ then (wavesMaxAmt >= betAmount)
96+ else false)
97+ then true
98+ else throw("Bet amount is not in range")
99+
100+
101+func rsaToInt (gameId,rsaSign,rsaPublicKey) = {
102+ let rsaCheck = rsaVerify(SHA256, toBytes(gameId), rsaSign, rsaPublicKey)
103+ if (rsaCheck)
104+ then (toInt(sha256(rsaSign)) % 29)
105+ else throw("Invalid RSA Signature")
106+ }
107+
108+
109+func drumIntToString (drumInt) = if ((10 > drumInt))
110+ then ("0" + toString(drumInt))
111+ else toString(drumInt)
112+
113+
114+func payout (pay) = {
115+ let reverse = wavesBalance(addressFromPublicKey(gamePublicKey))
116+ if ((reverse >= 0))
117+ then ((pay / 100) * reverse)
118+ else 0
119+ }
120+
121+
122+func defineMultiplier (threeInARow) = if ((threeInARow == "777"))
123+ then payout(100)
124+ else if ((threeInARow == "666"))
125+ then payout(20)
126+ else if ((threeInARow == "555"))
127+ then payout(14)
128+ else if ((threeInARow == "333"))
129+ then payout(10)
130+ else if ((threeInARow == "222"))
131+ then payout(5)
132+ else if ((threeInARow == "111"))
133+ then payout(2)
134+ else 0
135+
136+
137+func checkCallerIsAdmin (callerPublicKey) = (callerPublicKey == adminPublicKey)
138+
139+
140+@Callable(i)
141+func initGame () = if (checkCallerIsAdmin(i.callerPublicKey))
142+ then match gamesGetCounter() {
143+ case GAMESCOUNTER: Int =>
144+ throw("INIT_ALREADY_DONE")
145+ case _ =>
146+ WriteSet([DataEntry(gamesLabelCounter, 0), DataEntry(gameLabelStatus(toString(gameAddress)), "ACTIVE")])
147+ }
148+ else throw("initGame_FORBBIDEN")
149+
150+
151+
152+@Callable(i)
153+func makeBet () = {
154+ let gameId = toBase58String(i.transactionId)
155+ let playerAddress = extract(i.caller)
156+ let pmt = extract(i.payment)
157+ let betAmount = pmt.amount
158+ let pmtAmtCorrect = pmtAmtCheck(betAmount)
159+ match gameGetStatus(toString(gameAddress)) {
160+ case state: String =>
161+ if ((state == "ACTIVE"))
162+ then match gameGetBetStatus() {
163+ case betStatus: String =>
164+ if ((betStatus == "PLAYED"))
165+ then if (pmtAmtCorrect)
166+ then {
167+ let dataString = ((((((stateAcc + "_") + toString(playerAddress)) + "_") + toString(betAmount)) + "_WAVES_") + toString(height))
168+ WriteSet([DataEntry(gameLabelBetStatus, "BET"), DataEntry(gamesLabelId(gameId), dataString), DataEntry(addressLabelAmount(toString(playerAddress)), betAmount)])
169+ }
170+ else throw("WRONG_AMOUNT")
171+ else throw("COMPLETE_ PREVIOUS_GAME")
172+ case _ =>
173+ throw("NO_BET_PLACED_")
174+ }
175+ else throw("SLOT_GAME_NOT_INITIALIZED")
176+ case _ =>
177+ throw("INIT_ERROR")
178+ }
179+ }
180+
181+
182+
183+@Callable(i)
184+func playGame (gameId,rsaSign1,rsaSign2,rsaSign3) = {
185+ let dataList = gameGetData(gameId)
186+ let gameState = dataList[0]
187+ let playerAddress = dataList[1]
188+ let betAmt = parseIntValue(dataList[2])
189+ let drum1Int = rsaToInt(gameId, rsaSign1, rsaPublicKey1)
190+ let drum2Int = rsaToInt(gameId, rsaSign2, rsaPublicKey2)
191+ let drum3Int = rsaToInt(gameId, rsaSign3, rsaPublicKey3)
192+ let threeInARow = ((drum1[drum1Int] + drum2[drum2Int]) + drum3[drum3Int])
193+ let elementToString = ((drumIntToString(drum1Int) + drumIntToString(drum2Int)) + drumIntToString(drum3Int))
194+ let amountWon = defineMultiplier(threeInARow)
195+ let betDataList = gameGetBetData(playerAddress)
196+ let betState = betDataList[0]
197+ let totalIn200wins = parseIntValue(betDataList[1])
198+ let straight5Wins = parseIntValue(betDataList[2])
199+ let straight5Loses = parseIntValue(betDataList[3])
200+ match gameGetStatus(toString(gameAddress)) {
201+ case state: String =>
202+ if ((state != "ACTIVE"))
203+ then throw("SLOT_GAME_NOT_ACTIVE")
204+ else match gameGetBetStatus() {
205+ case gameBetStatus: String =>
206+ if ((gameBetStatus != "BET"))
207+ then throw("PLACE_A_BET_BEFORE_YOU_CAN_PLAY")
208+ else if ((threeInARow == "444"))
209+ then WriteSet([DataEntry(gamesLabelBet(playerAddress), (((((((((("TRIPLE_BAR" + "_") + dataList[1]) + "_") + dataList[2]) + "_") + dataList[3]) + "_") + toString(height)) + "_") + threeInARow))])
210+ else if ((gameState != stateAcc))
211+ then throw("GAME_STATE_IS_NOT_ACCEPTED")
212+ else if ((i.caller != addressFromStringValue(playerAddress)))
213+ then throw("NOT_CURRENT_PLAYER")
214+ else if ((amountWon != 0))
215+ then if ((totalIn200wins == 200))
216+ then ScriptResult(WriteSet([DataEntry(gamesLabelBet(playerAddress), ((((((((((((betWin + "_") + "0") + "_") + dataList[2]) + "_") + dataList[3]) + "_") + toString(height)) + "_") + toString(amountWon)) + "_") + threeInARow)), DataEntry(gamesLabelId(gameId), ((((((((((((((betWin + "_") + dataList[1]) + "_") + dataList[2]) + "_") + dataList[3]) + "_") + toString(height)) + "_") + toString(amountWon)) + "_") + threeInARow) + "_") + elementToString))]), TransferSet([ScriptTransfer(addressFromStringValue(playerAddress), amountWon, unit)]))
217+ else if ((straight5Wins == 5))
218+ then ScriptResult(WriteSet([DataEntry(gamesLabelBet(playerAddress), ((((((((((((betWin + "_") + dataList[1]) + "_") + "0") + "_") + dataList[3]) + "_") + toString(height)) + "_") + toString(amountWon)) + "_") + threeInARow)), DataEntry(gamesLabelId(gameId), ((((((((((((((betWin + "_") + dataList[1]) + "_") + dataList[2]) + "_") + dataList[3]) + "_") + toString(height)) + "_") + toString(amountWon)) + "_") + threeInARow) + "_") + elementToString))]), TransferSet([ScriptTransfer(addressFromStringValue(playerAddress), amountWon, unit)]))
219+ else if ((straight5Loses == 5))
220+ then ScriptResult(WriteSet([DataEntry(gamesLabelBet(playerAddress), ((((((((((((((betWin + "_") + "0") + "_") + dataList[1]) + "_") + dataList[2]) + "_") + "0") + "_") + toString(height)) + "_") + toString(amountWon)) + "_") + threeInARow)), DataEntry(gamesLabelId(gameId), ((((((((((((((betWin + "_") + dataList[1]) + "_") + dataList[2]) + "_") + dataList[3]) + "_") + toString(height)) + "_") + toString(amountWon)) + "_") + threeInARow) + "_") + elementToString))]), TransferSet([ScriptTransfer(addressFromStringValue(playerAddress), amountWon, unit)]))
221+ else ScriptResult(WriteSet([DataEntry(gamesLabelBet(playerAddress), ((((((((((((betWin + "_") + dataList[1]) + "_") + dataList[2]) + "_") + dataList[3]) + "_") + toString(height)) + "_") + toString(amountWon)) + "_") + threeInARow)), DataEntry(gamesLabelId(gameId), ((((((((((((((betWin + "_") + dataList[1]) + "_") + dataList[2]) + "_") + dataList[3]) + "_") + toString(height)) + "_") + toString(amountWon)) + "_") + threeInARow) + "_") + elementToString))]), TransferSet([ScriptTransfer(addressFromStringValue(playerAddress), amountWon, unit)]))
222+ else WriteSet([DataEntry(gamesLabelBet(playerAddress), (((((((((((((betLose + "_") + "_") + dataList[1]) + "_") + dataList[2]) + "_") + dataList[3]) + "_") + toString(height)) + "_") + toString(amountWon)) + "_") + threeInARow)), DataEntry(gamesLabelId(gameId), ((((((((((((((betLose + "_") + dataList[1]) + "_") + dataList[2]) + "_") + dataList[3]) + "_") + toString(height)) + "_") + toString(amountWon)) + "_") + threeInARow) + "_") + elementToString))])
223+ case _ =>
224+ throw("BET_PLACED")
225+ }
226+ case _ =>
227+ throw("INIT_ERROR")
228+ }
229+ }
230+
231+
232+@Verifier(tx)
233+func verify () = if (sigVerify(tx.bodyBytes, tx.proofs[0], gamePublicKey))
234+ then match tx {
235+ case tx: SetScriptTransaction =>
236+ true
237+ case _ =>
238+ false
239+ }
240+ else false
241+

github/deemru/w8io/026f985 
27.57 ms