tx · 5UupBa4se4zefNdhZgDHVrsJUyqjjc5uti3D5oZYDm7q

3MwpUQwpSfHV1rFfHqCuuYL7A9K8ursTQWk:  -0.01400000 Waves

2018.12.16 00:59 [406479] smart account 3MwpUQwpSfHV1rFfHqCuuYL7A9K8ursTQWk > SELF 0.00000000 Waves

{ "type": 13, "id": "5UupBa4se4zefNdhZgDHVrsJUyqjjc5uti3D5oZYDm7q", "fee": 1400000, "feeAssetId": null, "timestamp": 1544911169974, "version": 1, "sender": "3MwpUQwpSfHV1rFfHqCuuYL7A9K8ursTQWk", "senderPublicKey": "5ydncg624xM6LmJKWJ26iZoy7XBdGx9JxcgqKMNhJPaz", "proofs": [ "462j8EC3yAx56V7VYWQEmDNShM8tQ6f1XxERUFr9mYiCsHrowwoXgmDzCk4UGdbz1QN8hv2nWGDfPVhJrXzXEQN9" ], "script": "base64:AQQAAAAMS1lDUHVibGljS2V5AQAAACARS0CLXNZT0G3c1uPZJqewcF43O//zeQixEn7S9ss3ewQAAAAHJG1hdGNoMAUAAAACdHgDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAAD0RhdGFUcmFuc2FjdGlvbgQAAAACdHgFAAAAByRtYXRjaDADCQAB9AAAAAMIBQAAAAJ0eAAAAAlib2R5Qnl0ZXMJAAGRAAAAAggFAAAAAnR4AAAABnByb29mcwAAAAAAAAAAAAUAAAAMS1lDUHVibGljS2V5BgkAAfQAAAADCAUAAAACdHgAAAAJYm9keUJ5dGVzCQABkQAAAAIIBQAAAAJ0eAAAAAZwcm9vZnMAAAAAAAAAAAAIBQAAAAJ0eAAAAA9zZW5kZXJQdWJsaWNLZXkJAAH0AAAAAwgFAAAAAnR4AAAACWJvZHlCeXRlcwkAAZEAAAACCAUAAAACdHgAAAAGcHJvb2ZzAAAAAAAAAAAACAUAAAACdHgAAAAPc2VuZGVyUHVibGljS2V5Kinyzw==", "chainId": 84, "height": 406479, "spentComplexity": 0 } View: original | compacted Prev: 81qQKoze3CsNWkaHSMk8tjhBoMjFWccJA3tHGhpVnqTk Next: none Full:
OldNewDifferences
11 {-# STDLIB_VERSION 1 #-}
22 {-# CONTENT_TYPE EXPRESSION #-}
3+let KYCPublicKey = base58'2AWV5vw8vBxYKQnE9VeWe1AWWCaCCv1SZn9fbkR7bLFt'
34 match tx {
4- case dt: DataTransaction =>
5- let gameNotStarted = match getInteger(dt.sender, "gameState") {
6- case i: Int =>
7- false
8- case _ =>
9- true
10- }
11- let oldGameState = extract(getInteger(dt.sender, "gameState"))
12- let newGameState = match getInteger(dt.data, "gameState") {
13- case k: Int =>
14- k
15- case _ =>
16- 7
17- }
18- let validStep = ((oldGameState + 1) == newGameState)
19- let gameInitialization = if (if (gameNotStarted)
20- then (extract(getInteger(dt.data, "command")) == 0)
21- else false)
22- then (extract(getInteger(dt.data, "gameState")) == 0)
23- else false
24- let playersRegistration = if (if (if (validStep)
25- then (extract(getInteger(dt.data, "command")) == 1)
26- else false)
27- then (extract(getString(dt.data, "player1")) == "")
28- else false)
29- then (extract(getString(dt.data, "player2")) == "")
30- else false
31- let player1Registration = if (if (validStep)
32- then (extract(getInteger(dt.data, "command")) == 2)
33- else false)
34- then sigVerify(dt.bodyBytes, dt.proofs[0], fromBase58String(extract(getString(dt.data, "player1"))))
35- else false
36- let player2Registration = if (if (validStep)
37- then (extract(getInteger(dt.data, "command")) == 3)
38- else false)
39- then sigVerify(dt.bodyBytes, dt.proofs[0], fromBase58String(extract(getString(dt.data, "player2"))))
40- else false
41- let gameBegin = if (validStep)
42- then (extract(getInteger(dt.data, "command")) == 4)
43- else false
44- let move1 = if (if (if (validStep)
45- then (extract(getInteger(dt.data, "command")) == 5)
46- else false)
47- then (2 >= extract(getInteger(dt.data, "move1")))
48- else false)
49- then sigVerify(dt.bodyBytes, dt.proofs[0], fromBase58String(extract(getString(dt.sender, "player1"))))
50- else false
51- let move2 = if (if (if (validStep)
52- then (extract(getInteger(dt.data, "command")) == 6)
53- else false)
54- then (2 >= extract(getInteger(dt.data, "move2")))
55- else false)
56- then sigVerify(dt.bodyBytes, dt.proofs[0], fromBase58String(extract(getString(dt.sender, "player2"))))
57- else false
58- let gameEnd = if (if ((extract(getInteger(dt.sender, "gameState")) == 6))
59- then (extract(getInteger(dt.data, "command")) == 7)
60- else false)
61- then (extract(getString(dt.data, "gameState")) == "ended")
62- else false
63- if (if (if (if (if (if (if (gameInitialization)
5+ case tx: DataTransaction =>
6+ if (sigVerify(tx.bodyBytes, tx.proofs[0], KYCPublicKey))
647 then true
65- else playersRegistration)
66- then true
67- else player1Registration)
68- then true
69- else player2Registration)
70- then true
71- else gameBegin)
72- then true
73- else move1)
74- then true
75- else move2)
76- then true
77- else gameEnd
8+ else sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey)
789 case _ =>
79- true
10+ sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey)
8011 }

github/deemru/w8io/169f3d6 
33.95 ms