tx · 3mfP2AJ25dTomLKMjrSVVhRQcEMTgUVi9yU4Ga4RgzyA 3N7Gg64FJ3ESaqn41qu1ete7zmzbmoP1AAV: -0.01000000 Waves 2021.12.10 09:25 [1827772] smart account 3N7Gg64FJ3ESaqn41qu1ete7zmzbmoP1AAV > SELF 0.00000000 Waves
{ "type": 13, "id": "3mfP2AJ25dTomLKMjrSVVhRQcEMTgUVi9yU4Ga4RgzyA", "fee": 1000000, "feeAssetId": null, "timestamp": 1639117573334, "version": 2, "chainId": 84, "sender": "3N7Gg64FJ3ESaqn41qu1ete7zmzbmoP1AAV", "senderPublicKey": "5amLtMwixiEesBDKPy9dkFWntG2fNxhTs5n69JbQE9F7", "proofs": [ "2iz3N9yYHFWNYnLm8Uc5W3A9EfTZQMm8JLj7sSGqDRNFrWD58JV8RZTcwdfW1KUVHxF9DE6zMYyd9d4fqHs1jgYv" ], "script": "base64:AAIFAAAAAAAAAB4IAhIAEgASBwoFCAEBAQESAwoBCBIDCgEIEgMKAQgAAAABAAAAAAVzZXBhcgIAAAABfAAAAAYAAAABaQEAAAAFcmVzZXQAAAAACQAETAAAAAIJAQAAAAtTdHJpbmdFbnRyeQAAAAICAAAACmxhc3RnYW1laWQCAAAAATAJAARMAAAAAgkBAAAAC1N0cmluZ0VudHJ5AAAAAgIAAAAPbGFzdGNoYWxsZW5nZWlkAgAAAAEwBQAAAANuaWwAAAABaQEAAAAIc2V0cnVsZXMAAAAACQAETAAAAAIJAQAAAAtTdHJpbmdFbnRyeQAAAAICAAAABG1iZisCAAAACC0xLDF8MSwxCQAETAAAAAIJAQAAAAtTdHJpbmdFbnRyeQAAAAICAAAABG1iZi0CAAAAAAkABEwAAAACCQEAAAALU3RyaW5nRW50cnkAAAACAgAAAARtd2YrAgAAAAotMSwtMXwxLC0xCQAETAAAAAIJAQAAAAtTdHJpbmdFbnRyeQAAAAICAAAABG13Zi0CAAAAAAUAAAADbmlsAAAAAWkBAAAABG1vdmUAAAAFAAAABmdhbWVpZAAAA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AAAAIJAAGQAAAAAQUAAAAJY2hhbGxlbmdlAAAAAAAAAAAAAwkAAAAAAAACCQABkQAAAAIFAAAACWNoYWxsZW5nZQAAAAAAAAAAAAIAAAAIYXdhaXRpbmcJAARMAAAAAgkBAAAAC1N0cmluZ0VudHJ5AAAAAgkAASwAAAACAgAAAApjaGFsbGVuZ2UtBQAAAAxjaGFsbGVuZGdlaWQJAAS5AAAAAgkABEwAAAACAgAAAAV1bnNldAkABEwAAAACCQABkQAAAAIFAAAACWNoYWxsZW5nZQAAAAAAAAAAAQkABEwAAAACCQABkQAAAAIFAAAACWNoYWxsZW5nZQAAAAAAAAAAAgkABEwAAAACCQABkQAAAAIFAAAACWNoYWxsZW5nZQAAAAAAAAAAAwUAAAADbmlsBQAAAAVzZXBhcgUAAAADbmlsCQAAAgAAAAECAAAAFGNoYWxsZW5nZSBub3QgZXhpc3RzCQAAAgAAAAECAAAAFGNoYWxsZW5nZSBub3QgZXhpc3RzAAAAAOVvEnE=", "height": 1827772, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 3mM9e4vJ8cMVb4hSGSpued3yobJXJ6XRwkEAMoew72pr Next: EPPHmiBgVkGk8DtzS6TRoPiVwCYY2vvwCYveGYX1wSne Diff:
Old | New | Differences | |
---|---|---|---|
21 | 21 | case _ => | |
22 | 22 | throw("no game") | |
23 | 23 | } | |
24 | + | let correctxy = if (if (if (if ((fromx > -1)) | |
25 | + | then (tox > -1) | |
26 | + | else false) | |
27 | + | then (8 > fromy) | |
28 | + | else false) | |
29 | + | then (8 > toy) | |
30 | + | else false) | |
31 | + | then true | |
32 | + | else throw("incorrect xy") | |
24 | 33 | let callerAdress = toBase58String(i.caller.bytes) | |
25 | 34 | let isgame = if ((game[0] == "ongoing")) | |
26 | 35 | then true |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 5 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let separ = "|" | |
5 | 5 | ||
6 | 6 | @Callable(i) | |
7 | 7 | func reset () = [StringEntry("lastgameid", "0"), StringEntry("lastchallengeid", "0")] | |
8 | 8 | ||
9 | 9 | ||
10 | 10 | ||
11 | 11 | @Callable(i) | |
12 | 12 | func setrules () = [StringEntry("mbf+", "-1,1|1,1"), StringEntry("mbf-", ""), StringEntry("mwf+", "-1,-1|1,-1"), StringEntry("mwf-", "")] | |
13 | 13 | ||
14 | 14 | ||
15 | 15 | ||
16 | 16 | @Callable(i) | |
17 | 17 | func move (gameid,fromx,fromy,tox,toy) = { | |
18 | 18 | let game = match getString(("game-" + gameid)) { | |
19 | 19 | case a: String => | |
20 | 20 | split(getStringValue(("game-" + gameid)), separ) | |
21 | 21 | case _ => | |
22 | 22 | throw("no game") | |
23 | 23 | } | |
24 | + | let correctxy = if (if (if (if ((fromx > -1)) | |
25 | + | then (tox > -1) | |
26 | + | else false) | |
27 | + | then (8 > fromy) | |
28 | + | else false) | |
29 | + | then (8 > toy) | |
30 | + | else false) | |
31 | + | then true | |
32 | + | else throw("incorrect xy") | |
24 | 33 | let callerAdress = toBase58String(i.caller.bytes) | |
25 | 34 | let isgame = if ((game[0] == "ongoing")) | |
26 | 35 | then true | |
27 | 36 | else throw("not ongoing game") | |
28 | 37 | let side = if (if (isgame) | |
29 | 38 | then if ((game[1] == callerAdress)) | |
30 | 39 | then true | |
31 | 40 | else (game[2] == callerAdress) | |
32 | 41 | else false) | |
33 | 42 | then if ((game[1] == callerAdress)) | |
34 | 43 | then "w" | |
35 | 44 | else "b" | |
36 | 45 | else throw("not gamer") | |
37 | 46 | let otherside = if ((side == "w")) | |
38 | 47 | then "b" | |
39 | 48 | else "w" | |
40 | 49 | let turn = if ((side == game[5])) | |
41 | 50 | then true | |
42 | 51 | else throw("not your turn") | |
43 | 52 | let situation = split(game[8], "!") | |
44 | 53 | let cells = [split(situation[0], "-"), split(situation[1], "-"), split(situation[2], "-"), split(situation[3], "-"), split(situation[4], "-"), split(situation[5], "-"), split(situation[6], "-"), split(situation[7], "-")] | |
45 | 54 | let figure = if ((takeRight(cells[fromy][fromx], 1) == "0")) | |
46 | 55 | then throw("empty cell") | |
47 | 56 | else takeRight(cells[fromy][fromx], 1) | |
48 | 57 | let movetype = if ((take(cells[toy][tox], 1) == "0")) | |
49 | 58 | then "m" | |
50 | 59 | else if ((take(cells[toy][tox], 1) == otherside)) | |
51 | 60 | then "e" | |
52 | 61 | else throw("can not eat himself") | |
53 | 62 | let movement = ((toString((fromx - tox)) + ",") + toString((fromy - toy))) | |
54 | 63 | let possible = match getString((((movetype + side) + figure) + "+")) { | |
55 | 64 | case a: String => | |
56 | 65 | split(getStringValue((((movetype + side) + figure) + "+")), "|") | |
57 | 66 | case _ => | |
58 | 67 | throw((((("no rules for " + movetype) + side) + figure) + "+")) | |
59 | 68 | } | |
60 | 69 | let impossible = match getString((((movetype + side) + figure) + "-")) { | |
61 | 70 | case a: String => | |
62 | 71 | split(getStringValue((((movetype + side) + figure) + "-")), "|") | |
63 | 72 | case _ => | |
64 | 73 | throw((((("no rules for " + movetype) + side) + figure) + "-")) | |
65 | 74 | } | |
66 | 75 | let iscorrect1 = if (containsElement(possible, movement)) | |
67 | 76 | then true | |
68 | 77 | else throw(((((("incorrect movement+: fig=" + figure) + " side=") + side) + " mtype=") + movetype)) | |
69 | 78 | let iscorrect2 = if (containsElement(impossible, movement)) | |
70 | 79 | then throw(((((((("incorrect (" + movement) + ")movement-: fig=") + figure) + " side=") + side) + " mtype=") + movetype)) | |
71 | 80 | else true | |
72 | 81 | if (iscorrect2) | |
73 | 82 | then { | |
74 | 83 | let old = game[8] | |
75 | 84 | let new = ((take(old, ((fromx * 3) + ((fromy * 8) * 3))) + "00") + takeRight(old, ((191 - ((fromx * 3) + ((fromy * 8) * 3))) - 2))) | |
76 | 85 | let newsituation = (((take(new, ((tox * 3) + ((toy * 8) * 3))) + side) + figure) + takeRight(new, ((191 - ((tox * 3) + ((toy * 8) * 3))) - 2))) | |
77 | 86 | $Tuple2([StringEntry(("game-" + gameid), makeString([game[0], game[1], game[2], game[3], toString((parseIntValue(game[4]) + 1)), otherside, game[6], game[7], newsituation], separ))], [StringEntry("_", "possible")]) | |
78 | 87 | } | |
79 | 88 | else throw(((((("impossible movement: fig=" + figure) + " side=") + side) + " mtype=") + movetype)) | |
80 | 89 | } | |
81 | 90 | ||
82 | 91 | ||
83 | 92 | ||
84 | 93 | @Callable(i) | |
85 | 94 | func startgame (challengeid) = { | |
86 | 95 | let pmt = if ((size(i.payments) == 1)) | |
87 | 96 | then i.payments[0] | |
88 | 97 | else throw("must stake some waves") | |
89 | 98 | if (isDefined(pmt.assetId)) | |
90 | 99 | then throw("works with waves only") | |
91 | 100 | else { | |
92 | 101 | let callerAdress = toBase58String(i.caller.bytes) | |
93 | 102 | let conditions = split(getStringValue(("challenge-" + challengeid)), separ) | |
94 | 103 | if ((size(conditions) > 0)) | |
95 | 104 | then if ((pmt.amount >= parseIntValue(conditions[3]))) | |
96 | 105 | then if ((conditions[0] == "awaiting")) | |
97 | 106 | then { | |
98 | 107 | let black = if ((conditions[2] == "b")) | |
99 | 108 | then conditions[1] | |
100 | 109 | else callerAdress | |
101 | 110 | let white = if ((conditions[2] == "w")) | |
102 | 111 | then conditions[1] | |
103 | 112 | else callerAdress | |
104 | 113 | let gameid = toString((parseIntValue(getStringValue("lastgameid")) + 1)) | |
105 | 114 | [StringEntry(("challenge-" + challengeid), makeString([gameid, conditions[1], conditions[2], conditions[3], callerAdress], separ)), { | |
106 | 115 | let situation = "wf-00-wf-00-wf-00-wf-00!00-wf-00-wf-00-wf-00-wf!wf-00-wf-00-wf-00-wf-00!00-00-00-00-00-00-00-00!00-00-00-00-00-00-00-00!00-bf-00-bf-00-bf-00-bf!bf-00-bf-00-bf-00-bf-00!00-bf-00-bf-00-bf-00-bf" | |
107 | 116 | StringEntry(("game-" + gameid), makeString(["ongoing", white, black, conditions[3], "0", "w", "startblock", "laststepblock", situation], separ)) | |
108 | 117 | }, StringEntry("lastgameid", gameid), ScriptTransfer(i.caller, (pmt.amount - parseIntValue(conditions[3])), unit)] | |
109 | 118 | } | |
110 | 119 | else throw("no challenge awaiting") | |
111 | 120 | else throw("need more money") | |
112 | 121 | else throw("no challenge") | |
113 | 122 | } | |
114 | 123 | } | |
115 | 124 | ||
116 | 125 | ||
117 | 126 | ||
118 | 127 | @Callable(i) | |
119 | 128 | func setchallenge (side) = if (if ((side == "b")) | |
120 | 129 | then true | |
121 | 130 | else (side == "w")) | |
122 | 131 | then { | |
123 | 132 | let pmt = if ((size(i.payments) == 1)) | |
124 | 133 | then i.payments[0] | |
125 | 134 | else throw("must stake some waves") | |
126 | 135 | if (isDefined(pmt.assetId)) | |
127 | 136 | then throw("works with waves only") | |
128 | 137 | else { | |
129 | 138 | let callerAdress = toBase58String(i.caller.bytes) | |
130 | 139 | let challengeid = toString((parseIntValue(getStringValue("lastchallengeid")) + 1)) | |
131 | 140 | [StringEntry(("challenge-" + challengeid), makeString(["awaiting", callerAdress, side, toString(pmt.amount)], separ)), StringEntry("lastchallengeid", challengeid)] | |
132 | 141 | } | |
133 | 142 | } | |
134 | 143 | else throw("invalid side") | |
135 | 144 | ||
136 | 145 | ||
137 | 146 | ||
138 | 147 | @Callable(i) | |
139 | 148 | func unsetchallenge (challendgeid) = { | |
140 | 149 | let callerAdress = toBase58String(i.caller.bytes) | |
141 | 150 | func getchallenge (challendgeid) = match getString(("challenge-" + challendgeid)) { | |
142 | 151 | case a: String => | |
143 | 152 | getStringValue(("challenge-" + challendgeid)) | |
144 | 153 | case _ => | |
145 | 154 | "" | |
146 | 155 | } | |
147 | 156 | ||
148 | 157 | let challenge = split(getchallenge(challendgeid), separ) | |
149 | 158 | if ((size(challenge) > 0)) | |
150 | 159 | then if ((challenge[0] == "awaiting")) | |
151 | 160 | then [StringEntry(("challenge-" + challendgeid), makeString(["unset", challenge[1], challenge[2], challenge[3]], separ))] | |
152 | 161 | else throw("challenge not exists") | |
153 | 162 | else throw("challenge not exists") | |
154 | 163 | } | |
155 | 164 | ||
156 | 165 |
github/deemru/w8io/026f985 44.01 ms ◑