tx · FNwy9JfPJ3PBDbvLbhjFTLNwL9HmVeBDSdKpq1YyVswv

3Mth4mJpNbm6N6PQsgnP5KzcHBfC2Luiyfs:  -0.01400000 Waves

2019.07.31 19:53 [610534] smart account 3Mth4mJpNbm6N6PQsgnP5KzcHBfC2Luiyfs > SELF 0.00000000 Waves

{ "type": 13, "id": "FNwy9JfPJ3PBDbvLbhjFTLNwL9HmVeBDSdKpq1YyVswv", "fee": 1400000, "feeAssetId": null, "timestamp": 1564592043540, "version": 1, "sender": "3Mth4mJpNbm6N6PQsgnP5KzcHBfC2Luiyfs", "senderPublicKey": "GL5QvqgydTUCg1sj1s7juR6hVfxLHjZ37Kr5sAX4D4an", "proofs": [ "4MF3nFCVz5P8CZhVRdHyJQXTr6yxRNxuTuhN7F2UeB8w4XT9itL8VZgCntG2KnETp2Wo2S6fZN9EeQC1st81RFPo" ], "script": "base64:AAIDAAAAAAAAAAAAAAALAQAAAAlmaXZlQ2hhcnMAAAABAAAAAWMJAAEsAAAAAgkAASwAAAACCQABLAAAAAIJAAEsAAAAAgUAAAABYwUAAAABYwUAAAABYwUAAAABYwUAAAABYwEAAAAEY2VsbAAAAAMAAAAFY2VsbHMAAAADcm93AAAAA2NvbAkBAAAACXRha2VSaWdodAAAAAIJAAEvAAAAAgUAAAAFY2VsbHMJAABkAAAAAgkAAGQAAAACCQAAaAAAAAIFAAAAA3JvdwAAAAAAAAAADwUAAAADY29sAAAAAAAAAAABAAAAAAAAAAABAQAAAAdzZXRDZWxsAAAABAAAAAVjZWxscwAAAANyb3cAAAADY29sAAAAA3ZhbAkAASwAAAACCQABLAAAAAIJAAEvAAAAAgUAAAAFY2VsbHMJAABkAAAAAgkAAGgAAAACBQAAAANyb3cAAAAAAAAAAA8FAAAAA2NvbAUAAAADdmFsCQEAAAAJdGFrZVJpZ2h0AAAAAgUAAAAFY2VsbHMJAABlAAAAAgkAATEAAAABBQAAAAVjZWxscwkAAGQAAAACCQAAZAAAAAIJAABoAAAAAgUAAAADcm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RoaXMJAAEsAAAAAgkAASwAAAACAgAAAAVnYW1lOgkAAaQAAAABBQAAAARnYW1lAgAAAAZfY2VsbHMJAAACAAAAAQkAASwAAAACCQABLAAAAAIJAAGlAAAAAQkBAAAAC2NoZWNrRmllbGRCAAAAAwUAAAAFY2VsbHMFAAAAA3JvdwUAAAADY29sAgAAAAIsIAkAAaUAAAABCQEAAAALY2hlY2tGaWVsZFcAAAADBQAAAAVjZWxscwUAAAADcm93BQAAAANjb2wAAAABaQEAAAALdGVzdFNldENlbGwAAAAEAAAABGdhbWUAAAADcm93AAAAA2NvbAAAAAN2YWwEAAAABWNlbGxzCQEAAAAHZXh0cmFjdAAAAAEJAAQdAAAAAgUAAAAEdGhpcwkAASwAAAACCQABLAAAAAICAAAABWdhbWU6CQABpAAAAAEFAAAABGdhbWUCAAAABl9jZWxscwQAAAAIbmV3Q2VsbHMJAQAAAAdzZXRDZWxsAAAABAUAAAAFY2VsbHMFAAAAA3JvdwUAAAADY29sBQAAAAN2YWwJAQAAAAhXcml0ZVNldAAAAAEJAARMAAAAAgkBAAAACURhdGFFbnRyeQAAAAIJAAEsAAAAAgkAASwAAAACAgAAAAVnYW1lOgkAAaQAAAABBQAAAARnYW1lAgAAAAZfY2VsbHMFAAAACG5ld0NlbGxzBQAAAANuaWwAAAABAAAAAnR4AQAAAAZ2ZXJpZnkAAAAABmKvTEo=", "chainId": 84, "height": 610534, "spentComplexity": 0 } View: original | compacted Prev: 2URw7ejtraUMULn9edyFDf6czJZNQUW6kntN4xKVjojP Next: J8sHgZ4Aonex6kfgjhnRAsb3Zo7DmBZqvm9Jcor1W8zq Diff:
OldNewDifferences
9595 else ""))))))))))))))
9696
9797
98-func getLDiag (cells,row,col) = if (if ((row >= 4))
99- then (col >= 4)
100- else false)
101- then cell(cells, (row - 4), (col - 4))
102- else ("" + (if (if ((row >= 3))
103- then (col >= 3)
98+func getLDiag (cells,row,col) = {
99+ let d = if (if ((row >= 4))
100+ then (col >= 4)
104101 else false)
105- then cell(cells, (row - 3), (col - 3))
106- else ("" + (if (if ((row >= 2))
107- then (col >= 2)
102+ then cell(cells, (row - 4), (col - 4))
103+ else ("" + (if (if ((row >= 3))
104+ then (col >= 3)
108105 else false)
109- then cell(cells, (row - 2), (col - 2))
110- else ("" + (if (if ((row >= 1))
111- then (col >= 1)
106+ then cell(cells, (row - 3), (col - 3))
107+ else ("" + (if (if ((row >= 2))
108+ then (col >= 2)
112109 else false)
113- then cell(cells, (row - 1), (col - 1))
114- else (("" + cell(cells, row, col)) + (if (if ((13 >= row))
115- then (13 >= col)
110+ then cell(cells, (row - 2), (col - 2))
111+ else ("" + (if (if ((row >= 1))
112+ then (col >= 1)
116113 else false)
117- then cell(cells, (row + 1), (col + 1))
118- else ("" + (if (if ((12 >= row))
119- then (12 >= col)
114+ then cell(cells, (row - 1), (col - 1))
115+ else (("" + cell(cells, row, col)) + (if (if ((13 >= row))
116+ then (13 >= col)
120117 else false)
121- then cell(cells, (row + 2), (col + 2))
122- else ("" + (if (if ((11 >= row))
123- then (11 >= col)
118+ then cell(cells, (row + 1), (col + 1))
119+ else ("" + (if (if ((12 >= row))
120+ then (12 >= col)
124121 else false)
125- then cell(cells, (row + 3), (col + 3))
126- else ("" + (if (if ((10 >= row))
127- then (10 >= col)
122+ then cell(cells, (row + 2), (col + 2))
123+ else ("" + (if (if ((11 >= row))
124+ then (11 >= col)
128125 else false)
129- then cell(cells, (row + 4), (col + 4))
130- else ""))))))))))))))
126+ then cell(cells, (row + 3), (col + 3))
127+ else ("" + (if (if ((10 >= row))
128+ then (10 >= col)
129+ else false)
130+ then cell(cells, (row + 4), (col + 4))
131+ else ""))))))))))))))
132+ throw(d)
133+ }
131134
132135
133136 func checkField (cells,c,row,col) = {
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 3 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 func fiveChars (c) = ((((c + c) + c) + c) + c)
55
66
77 func cell (cells,row,col) = takeRight(take(cells, (((row * 15) + col) + 1)), 1)
88
99
1010 func setCell (cells,row,col,val) = ((take(cells, ((row * 15) + col)) + val) + takeRight(cells, (size(cells) - (((row * 15) + col) + 1))))
1111
1212
1313 func check (line,c) = if (if ((c != "b"))
1414 then (c != "w")
1515 else false)
1616 then throw("invalid color in check function")
1717 else match indexOf(line, fiveChars(c)) {
1818 case _: Int =>
1919 true
2020 case _ =>
2121 false
2222 }
2323
2424
2525 func getRow (cells,row,col) = if ((col >= 4))
2626 then cell(cells, row, (col - 4))
2727 else ("" + (if ((col >= 3))
2828 then cell(cells, row, (col - 3))
2929 else ("" + (if ((col >= 2))
3030 then cell(cells, row, (col - 2))
3131 else ("" + (if ((col >= 1))
3232 then cell(cells, row, (col - 1))
3333 else (("" + cell(cells, row, col)) + (if ((13 >= col))
3434 then cell(cells, row, (col + 1))
3535 else ("" + (if ((12 >= col))
3636 then cell(cells, row, (col + 2))
3737 else ("" + (if ((11 >= col))
3838 then cell(cells, row, (col + 3))
3939 else ("" + (if ((10 >= col))
4040 then cell(cells, row, (col + 4))
4141 else ""))))))))))))))
4242
4343
4444 func getColumn (cells,row,col) = if ((row >= 4))
4545 then cell(cells, (row - 4), col)
4646 else ("" + (if ((row >= 3))
4747 then cell(cells, (row - 3), col)
4848 else ("" + (if ((row >= 2))
4949 then cell(cells, (row - 2), col)
5050 else ("" + (if ((row >= 1))
5151 then cell(cells, (row - 1), col)
5252 else (("" + cell(cells, row, col)) + (if ((13 >= row))
5353 then cell(cells, (row + 1), col)
5454 else ("" + (if ((12 >= row))
5555 then cell(cells, (row + 2), col)
5656 else ("" + (if ((11 >= row))
5757 then cell(cells, (row + 3), col)
5858 else ("" + (if ((10 >= row))
5959 then cell(cells, (row + 4), col)
6060 else ""))))))))))))))
6161
6262
6363 func getRDiag (cells,row,col) = if (if ((row >= 4))
6464 then (10 >= col)
6565 else false)
6666 then cell(cells, (row - 4), (col + 4))
6767 else ("" + (if (if ((row >= 3))
6868 then (11 >= col)
6969 else false)
7070 then cell(cells, (row - 3), (col + 3))
7171 else ("" + (if (if ((row >= 2))
7272 then (12 >= col)
7373 else false)
7474 then cell(cells, (row - 2), (col + 2))
7575 else ("" + (if (if ((row >= 1))
7676 then (13 >= col)
7777 else false)
7878 then cell(cells, (row - 1), (col + 1))
7979 else (("" + cell(cells, row, col)) + (if (if ((13 >= row))
8080 then (col >= 1)
8181 else false)
8282 then cell(cells, (row + 1), (col - 1))
8383 else ("" + (if (if ((12 >= row))
8484 then (col >= 2)
8585 else false)
8686 then cell(cells, (row + 2), (col - 2))
8787 else ("" + (if (if ((11 >= row))
8888 then (col >= 3)
8989 else false)
9090 then cell(cells, (row + 3), (col - 3))
9191 else ("" + (if (if ((10 >= row))
9292 then (col >= 4)
9393 else false)
9494 then cell(cells, (row + 4), (col - 4))
9595 else ""))))))))))))))
9696
9797
98-func getLDiag (cells,row,col) = if (if ((row >= 4))
99- then (col >= 4)
100- else false)
101- then cell(cells, (row - 4), (col - 4))
102- else ("" + (if (if ((row >= 3))
103- then (col >= 3)
98+func getLDiag (cells,row,col) = {
99+ let d = if (if ((row >= 4))
100+ then (col >= 4)
104101 else false)
105- then cell(cells, (row - 3), (col - 3))
106- else ("" + (if (if ((row >= 2))
107- then (col >= 2)
102+ then cell(cells, (row - 4), (col - 4))
103+ else ("" + (if (if ((row >= 3))
104+ then (col >= 3)
108105 else false)
109- then cell(cells, (row - 2), (col - 2))
110- else ("" + (if (if ((row >= 1))
111- then (col >= 1)
106+ then cell(cells, (row - 3), (col - 3))
107+ else ("" + (if (if ((row >= 2))
108+ then (col >= 2)
112109 else false)
113- then cell(cells, (row - 1), (col - 1))
114- else (("" + cell(cells, row, col)) + (if (if ((13 >= row))
115- then (13 >= col)
110+ then cell(cells, (row - 2), (col - 2))
111+ else ("" + (if (if ((row >= 1))
112+ then (col >= 1)
116113 else false)
117- then cell(cells, (row + 1), (col + 1))
118- else ("" + (if (if ((12 >= row))
119- then (12 >= col)
114+ then cell(cells, (row - 1), (col - 1))
115+ else (("" + cell(cells, row, col)) + (if (if ((13 >= row))
116+ then (13 >= col)
120117 else false)
121- then cell(cells, (row + 2), (col + 2))
122- else ("" + (if (if ((11 >= row))
123- then (11 >= col)
118+ then cell(cells, (row + 1), (col + 1))
119+ else ("" + (if (if ((12 >= row))
120+ then (12 >= col)
124121 else false)
125- then cell(cells, (row + 3), (col + 3))
126- else ("" + (if (if ((10 >= row))
127- then (10 >= col)
122+ then cell(cells, (row + 2), (col + 2))
123+ else ("" + (if (if ((11 >= row))
124+ then (11 >= col)
128125 else false)
129- then cell(cells, (row + 4), (col + 4))
130- else ""))))))))))))))
126+ then cell(cells, (row + 3), (col + 3))
127+ else ("" + (if (if ((10 >= row))
128+ then (10 >= col)
129+ else false)
130+ then cell(cells, (row + 4), (col + 4))
131+ else ""))))))))))))))
132+ throw(d)
133+ }
131134
132135
133136 func checkField (cells,c,row,col) = {
134137 let targetLines = ((((((getRow(cells, row, col) + "|") + getColumn(cells, row, col)) + "|") + getRDiag(cells, row, col)) + "|") + getLDiag(cells, row, col))
135138 check(targetLines, c)
136139 }
137140
138141
139142 func checkFieldB (cells,row,col) = checkField(cells, "b", row, col)
140143
141144
142145 func checkFieldW (cells,row,col) = checkField(cells, "w", row, col)
143146
144147
145148 @Callable(i)
146149 func test (game,row,col) = {
147150 let cells = extract(getString(this, (("game:" + toString(game)) + "_cells")))
148151 throw(((toString(checkFieldB(cells, row, col)) + ", ") + toString(checkFieldW(cells, row, col))))
149152 }
150153
151154
152155
153156 @Callable(i)
154157 func testSetCell (game,row,col,val) = {
155158 let cells = extract(getString(this, (("game:" + toString(game)) + "_cells")))
156159 let newCells = setCell(cells, row, col, val)
157160 WriteSet([DataEntry((("game:" + toString(game)) + "_cells"), newCells)])
158161 }
159162
160163
161164 @Verifier(tx)
162165 func verify () = true
163166

github/deemru/w8io/026f985 
55.66 ms