tx · EPPHmiBgVkGk8DtzS6TRoPiVwCYY2vvwCYveGYX1wSne 3N7Gg64FJ3ESaqn41qu1ete7zmzbmoP1AAV: -0.01000000 Waves 2021.12.10 09:28 [1827776] smart account 3N7Gg64FJ3ESaqn41qu1ete7zmzbmoP1AAV > SELF 0.00000000 Waves
{ "type": 13, "id": "EPPHmiBgVkGk8DtzS6TRoPiVwCYY2vvwCYveGYX1wSne", "fee": 1000000, "feeAssetId": null, "timestamp": 1639117741869, "version": 2, "chainId": 84, "sender": "3N7Gg64FJ3ESaqn41qu1ete7zmzbmoP1AAV", "senderPublicKey": "5amLtMwixiEesBDKPy9dkFWntG2fNxhTs5n69JbQE9F7", "proofs": [ "2TavnQpFNQiRHyQA8V6pSqW5n64HcddCZzDREPaTroPZ2nPBw7uWby3gFDgMEVXv4xmdToTPk5p5ep6wQM9874QC" ], "script": "base64:AAIFAAAAAAAAAB4IAhIAEgASBwoFCAEBAQESAwoBCBIDCgEIEgMKAQgAAAABAAAAAAVzZXBhcgIAAAABfAAAAAYAAAABaQEAAAAFcmVzZXQAAAAACQAETAAAAAIJAQAAAAtTdHJpbmdFbnRyeQAAAAICAAAACmxhc3RnYW1laWQCAAAAATAJAARMAAAAAgkBAAAAC1N0cmluZ0VudHJ5AAAAAgIAAAAPbGFzdGNoYWxsZW5nZWlkAgAAAAEwBQAAAANuaWwAAAABaQEAAAAIc2V0cnVsZXMAAAAACQAETAAAAAIJAQAAAAtTdHJpbmdFbnRyeQAAAAICAAAABG1iZisCAAAACC0xLDF8MSwxCQAETAAAAAIJAQAAAAtTdHJpbmdFbnRyeQAAAAICAAAABG1iZi0CAAAAAAkABEwAAAACCQEAAAALU3RyaW5nRW50cnkAAAACAgAAAARtd2YrAgAAAAotMSwtMXwxLC0xCQAETAAAAAIJAQAAAAtTdHJpbmdFbnRyeQAAAAICAAAABG13Zi0CAAAAAAUAAAADbmlsAAAAAWkBAAAABG1vdmUAAAAFAAAABmdhbWVpZAAAAAVmcm9teAAAAAV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AAQUAAAAJY2hhbGxlbmdlAAAAAAAAAAAAAwkAAAAAAAACCQABkQAAAAIFAAAACWNoYWxsZW5nZQAAAAAAAAAAAAIAAAAIYXdhaXRpbmcJAARMAAAAAgkBAAAAC1N0cmluZ0VudHJ5AAAAAgkAASwAAAACAgAAAApjaGFsbGVuZ2UtBQAAAAxjaGFsbGVuZGdlaWQJAAS5AAAAAgkABEwAAAACAgAAAAV1bnNldAkABEwAAAACCQABkQAAAAIFAAAACWNoYWxsZW5nZQAAAAAAAAAAAQkABEwAAAACCQABkQAAAAIFAAAACWNoYWxsZW5nZQAAAAAAAAAAAgkABEwAAAACCQABkQAAAAIFAAAACWNoYWxsZW5nZQAAAAAAAAAAAwUAAAADbmlsBQAAAAVzZXBhcgUAAAADbmlsCQAAAgAAAAECAAAAFGNoYWxsZW5nZSBub3QgZXhpc3RzCQAAAgAAAAECAAAAFGNoYWxsZW5nZSBub3QgZXhpc3RzAAAAAOVvEnE=", "height": 1827776, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 3mfP2AJ25dTomLKMjrSVVhRQcEMTgUVi9yU4Ga4RgzyA Next: EG65mp5vrGEzN8hx2KWP1ASX3PrN8sX1UroTk9J82WhR Full:
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 5 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let a = "|" | |
5 | 5 | ||
6 | 6 | @Callable(b) | |
7 | 7 | func reset () = [StringEntry("lastgameid", "0"), StringEntry("lastchallengeid", "0")] | |
8 | 8 | ||
9 | 9 | ||
10 | 10 | ||
11 | 11 | @Callable(b) | |
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(b) | |
17 | 17 | func move (c,d,e,f,g) = { | |
18 | 18 | let h = { | |
19 | 19 | let i = getString(("game-" + c)) | |
20 | 20 | if ($isInstanceOf(i, "String")) | |
21 | 21 | then { | |
22 | 22 | let j = i | |
23 | 23 | split(getStringValue(("game-" + c)), a) | |
24 | 24 | } | |
25 | 25 | else throw("no game") | |
26 | 26 | } | |
27 | 27 | let k = if (if (if (if ((d > -1)) | |
28 | 28 | then (f > -1) | |
29 | 29 | else false) | |
30 | 30 | then (8 > e) | |
31 | 31 | else false) | |
32 | 32 | then (8 > g) | |
33 | 33 | else false) | |
34 | 34 | then true | |
35 | 35 | else throw("incorrect xy") | |
36 | 36 | let l = toBase58String(b.caller.bytes) | |
37 | 37 | let m = if ((h[0] == "ongoing")) | |
38 | 38 | then true | |
39 | 39 | else throw("not ongoing game") | |
40 | 40 | let n = if (if (m) | |
41 | 41 | then if ((h[1] == l)) | |
42 | 42 | then true | |
43 | 43 | else (h[2] == l) | |
44 | 44 | else false) | |
45 | 45 | then if ((h[1] == l)) | |
46 | 46 | then "w" | |
47 | 47 | else "b" | |
48 | 48 | else throw("not gamer") | |
49 | 49 | let o = if ((n == "w")) | |
50 | 50 | then "b" | |
51 | 51 | else "w" | |
52 | 52 | let p = if ((n == h[5])) | |
53 | 53 | then true | |
54 | 54 | else throw("not your turn") | |
55 | 55 | let q = split(h[8], "!") | |
56 | 56 | let r = [split(q[0], "-"), split(q[1], "-"), split(q[2], "-"), split(q[3], "-"), split(q[4], "-"), split(q[5], "-"), split(q[6], "-"), split(q[7], "-")] | |
57 | 57 | let s = if ((takeRight(r[e][d], 1) == "0")) | |
58 | 58 | then throw("empty cell") | |
59 | 59 | else takeRight(r[e][d], 1) | |
60 | 60 | let t = if ((take(r[g][f], 1) == "0")) | |
61 | 61 | then "m" | |
62 | 62 | else if ((take(r[g][f], 1) == o)) | |
63 | 63 | then "e" | |
64 | 64 | else throw("can not eat himself") | |
65 | 65 | let u = ((toString((d - f)) + ",") + toString((e - g))) | |
66 | 66 | let v = { | |
67 | 67 | let i = getString((((t + n) + s) + "+")) | |
68 | 68 | if ($isInstanceOf(i, "String")) | |
69 | 69 | then { | |
70 | 70 | let j = i | |
71 | 71 | split(getStringValue((((t + n) + s) + "+")), "|") | |
72 | 72 | } | |
73 | 73 | else throw((((("no rules for " + t) + n) + s) + "+")) | |
74 | 74 | } | |
75 | 75 | let w = { | |
76 | 76 | let i = getString((((t + n) + s) + "-")) | |
77 | 77 | if ($isInstanceOf(i, "String")) | |
78 | 78 | then { | |
79 | 79 | let j = i | |
80 | 80 | split(getStringValue((((t + n) + s) + "-")), "|") | |
81 | 81 | } | |
82 | 82 | else throw((((("no rules for " + t) + n) + s) + "-")) | |
83 | 83 | } | |
84 | 84 | let x = if (containsElement(v, u)) | |
85 | 85 | then true | |
86 | 86 | else throw(((((("incorrect movement+: fig=" + s) + " side=") + n) + " mtype=") + t)) | |
87 | 87 | let y = if (containsElement(w, u)) | |
88 | 88 | then throw(((((((("incorrect (" + u) + ")movement-: fig=") + s) + " side=") + n) + " mtype=") + t)) | |
89 | 89 | else true | |
90 | 90 | if (y) | |
91 | 91 | then { | |
92 | 92 | let z = h[8] | |
93 | 93 | let A = ((take(z, ((d * 3) + ((e * 8) * 3))) + "00") + takeRight(z, ((191 - ((d * 3) + ((e * 8) * 3))) - 2))) | |
94 | 94 | let B = (((take(A, ((f * 3) + ((g * 8) * 3))) + n) + s) + takeRight(A, ((191 - ((f * 3) + ((g * 8) * 3))) - 2))) | |
95 | 95 | $Tuple2([StringEntry(("game-" + c), makeString([h[0], h[1], h[2], h[3], toString((parseIntValue(h[4]) + 1)), o, h[6], h[7], B], a))], [StringEntry("_", "possible")]) | |
96 | 96 | } | |
97 | 97 | else throw(((((("impossible movement: fig=" + s) + " side=") + n) + " mtype=") + t)) | |
98 | 98 | } | |
99 | 99 | ||
100 | 100 | ||
101 | 101 | ||
102 | 102 | @Callable(b) | |
103 | 103 | func startgame (C) = { | |
104 | 104 | let D = if ((size(b.payments) == 1)) | |
105 | 105 | then b.payments[0] | |
106 | 106 | else throw("must stake some waves") | |
107 | 107 | if (isDefined(D.assetId)) | |
108 | 108 | then throw("works with waves only") | |
109 | 109 | else { | |
110 | 110 | let l = toBase58String(b.caller.bytes) | |
111 | 111 | let E = split(getStringValue(("challenge-" + C)), a) | |
112 | 112 | if ((size(E) > 0)) | |
113 | 113 | then if ((D.amount >= parseIntValue(E[3]))) | |
114 | 114 | then if ((E[0] == "awaiting")) | |
115 | 115 | then { | |
116 | 116 | let F = if ((E[2] == "b")) | |
117 | 117 | then E[1] | |
118 | 118 | else l | |
119 | 119 | let G = if ((E[2] == "w")) | |
120 | 120 | then E[1] | |
121 | 121 | else l | |
122 | 122 | let c = toString((parseIntValue(getStringValue("lastgameid")) + 1)) | |
123 | 123 | [StringEntry(("challenge-" + C), makeString([c, E[1], E[2], E[3], l], a)), { | |
124 | 124 | let q = "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" | |
125 | 125 | StringEntry(("game-" + c), makeString(["ongoing", G, F, E[3], "0", "w", "startblock", "laststepblock", q], a)) | |
126 | 126 | }, StringEntry("lastgameid", c), ScriptTransfer(b.caller, (D.amount - parseIntValue(E[3])), unit)] | |
127 | 127 | } | |
128 | 128 | else throw("no challenge awaiting") | |
129 | 129 | else throw("need more money") | |
130 | 130 | else throw("no challenge") | |
131 | 131 | } | |
132 | 132 | } | |
133 | 133 | ||
134 | 134 | ||
135 | 135 | ||
136 | 136 | @Callable(b) | |
137 | 137 | func setchallenge (n) = if (if ((n == "b")) | |
138 | 138 | then true | |
139 | 139 | else (n == "w")) | |
140 | 140 | then { | |
141 | 141 | let D = if ((size(b.payments) == 1)) | |
142 | 142 | then b.payments[0] | |
143 | 143 | else throw("must stake some waves") | |
144 | 144 | if (isDefined(D.assetId)) | |
145 | 145 | then throw("works with waves only") | |
146 | 146 | else { | |
147 | 147 | let l = toBase58String(b.caller.bytes) | |
148 | 148 | let C = toString((parseIntValue(getStringValue("lastchallengeid")) + 1)) | |
149 | 149 | [StringEntry(("challenge-" + C), makeString(["awaiting", l, n, toString(D.amount)], a)), StringEntry("lastchallengeid", C)] | |
150 | 150 | } | |
151 | 151 | } | |
152 | 152 | else throw("invalid side") | |
153 | 153 | ||
154 | 154 | ||
155 | 155 | ||
156 | 156 | @Callable(b) | |
157 | 157 | func unsetchallenge (H) = { | |
158 | 158 | let l = toBase58String(b.caller.bytes) | |
159 | 159 | func I (H) = { | |
160 | 160 | let i = getString(("challenge-" + H)) | |
161 | 161 | if ($isInstanceOf(i, "String")) | |
162 | 162 | then { | |
163 | 163 | let j = i | |
164 | 164 | getStringValue(("challenge-" + H)) | |
165 | 165 | } | |
166 | 166 | else "" | |
167 | 167 | } | |
168 | 168 | ||
169 | 169 | let J = split(I(H), a) | |
170 | 170 | if ((size(J) > 0)) | |
171 | 171 | then if ((J[0] == "awaiting")) | |
172 | 172 | then [StringEntry(("challenge-" + H), makeString(["unset", J[1], J[2], J[3]], a))] | |
173 | 173 | else throw("challenge not exists") | |
174 | 174 | else throw("challenge not exists") | |
175 | 175 | } | |
176 | 176 | ||
177 | 177 |
github/deemru/w8io/026f985 37.06 ms ◑