tx · 5kKpi5KFb2ywKL2ajeWhRUbrGABP875UznwWfPJGif5b 3Mth4mJpNbm6N6PQsgnP5KzcHBfC2Luiyfs: -0.01400000 Waves 2019.07.31 15:08 [610247] smart account 3Mth4mJpNbm6N6PQsgnP5KzcHBfC2Luiyfs > SELF 0.00000000 Waves
{ "type": 13, "id": "5kKpi5KFb2ywKL2ajeWhRUbrGABP875UznwWfPJGif5b", "fee": 1400000, "feeAssetId": null, "timestamp": 1564574957739, "version": 1, "sender": "3Mth4mJpNbm6N6PQsgnP5KzcHBfC2Luiyfs", "senderPublicKey": "GL5QvqgydTUCg1sj1s7juR6hVfxLHjZ37Kr5sAX4D4an", "proofs": [ "5RwBkkQTLUDLtuj1N6CzVcxqcaH6SzpehLrKoHtXCn7hagxqXvCpMvBbFgM1jtf9jQ3GXNGdhUXqf1ip5TuruyTP" ], "script": "base64:AAIDAAAAAAAAAAAAAAAIAQAAAAlmaXZlQ2hhcnMAAAABAAAAAWMJAAEsAAAAAgkAASwAAAACCQABLAAAAAIJAAEsAAAAAgUAAAABYwUAAAABYwUAAAABYwUAAAABYwUAAAABYwEAAAAEY2VsbAAAAAMAAAAFY2VsbHMAAAADcm93AAAAA2NvbAkBAAAACXRha2VSaWdodAAAAAIJAAEvAAAAAgUAAAAFY2VsbHMJAABkAAAAAgkAAGQAAAACCQAAaAAAAAIFAAAAA3JvdwAAAAAAAAAADwUAAAADY29sAAAAAAAAAAABAAAAAAAAAAABAQAAAAdzZXRDZWxsAAAABAAAAAVjZWxscwAAAANyb3cAAAADY29sAAAAA3ZhbAkAASwAAAACCQABLAAAAAIJAAEvAAAAAgUAAAAFY2VsbHMJAABkAAAAAgkAAGgAAAACBQAAAANyb3cAAAAAAAAAAA8FAAAAA2NvbAUAAAADdmFsCQEAAAAJdGFrZVJpZ2h0AAAAAgUAAAAFY2VsbHMJAABlAAAAAgkAATEAAAABBQAAAAVjZWxscwkAAGQAAAACCQAAZAAAAAIJAABoAAAAAgUAAAADcm93AAAAAA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AAAWkBAAAAC3Rlc3RTZXRDZWxsAAAABAAAAARnYW1lAAAAA3JvdwAAAANjb2wAAAADdmFsBAAAAAVjZWxscwkBAAAAB2V4dHJhY3QAAAABCQAEHQAAAAIFAAAABHRoaXMJAAEsAAAAAgkAASwAAAACAgAAAAVnYW1lOgkAAaQAAAABBQAAAARnYW1lAgAAAAZfY2VsbHMEAAAACG5ld0NlbGxzCQEAAAAHc2V0Q2VsbAAAAAQFAAAABWNlbGxzBQAAAANyb3cFAAAAA2NvbAUAAAADdmFsCQEAAAAIV3JpdGVTZXQAAAABCQAETAAAAAIJAQAAAAlEYXRhRW50cnkAAAACCQABLAAAAAIJAAEsAAAAAgIAAAAFZ2FtZToJAAGkAAAAAQUAAAAEZ2FtZQIAAAAGX2NlbGxzBQAAAAhuZXdDZWxscwUAAAADbmlsAAAAAQAAAAJ0eAEAAAAGdmVyaWZ5AAAAAAbQtHJt", "chainId": 84, "height": 610247, "spentComplexity": 0 } View: original | compacted Prev: EDqrMca5rAySMJjE8azrGFXS73Gx7VyjR6L7ExoccpBq Next: Ak3tnHVv23gpDBkCXy8WDUkaeTHuUa88eBr1A8jMBmoY Diff:
Old | New | Differences | |
---|---|---|---|
7 | 7 | func c (d,e,f) = takeRight(take(d, (((e * 15) + f) + 1)), 1) | |
8 | 8 | ||
9 | 9 | ||
10 | - | func g (d,e,f,h) = ((take(d, ((e * 15) + f)) + h) + | |
10 | + | func g (d,e,f,h) = ((take(d, ((e * 15) + f)) + h) + takeRight(d, (size(d) - (((e * 15) + f) + 1)))) | |
11 | 11 | ||
12 | 12 | ||
13 | 13 | func e (d,e) = ((((((((((((((c(d, e, 0) + c(d, e, 1)) + c(d, e, 2)) + c(d, e, 3)) + c(d, e, 4)) + c(d, e, 5)) + c(d, e, 6)) + c(d, e, 7)) + c(d, e, 8)) + c(d, e, 9)) + c(d, e, 10)) + c(d, e, 11)) + c(d, e, 12)) + c(d, e, 13)) + c(d, e, 14)) |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 3 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | func a (b) = ((((b + b) + b) + b) + b) | |
5 | 5 | ||
6 | 6 | ||
7 | 7 | func c (d,e,f) = takeRight(take(d, (((e * 15) + f) + 1)), 1) | |
8 | 8 | ||
9 | 9 | ||
10 | - | func g (d,e,f,h) = ((take(d, ((e * 15) + f)) + h) + | |
10 | + | func g (d,e,f,h) = ((take(d, ((e * 15) + f)) + h) + takeRight(d, (size(d) - (((e * 15) + f) + 1)))) | |
11 | 11 | ||
12 | 12 | ||
13 | 13 | func e (d,e) = ((((((((((((((c(d, e, 0) + c(d, e, 1)) + c(d, e, 2)) + c(d, e, 3)) + c(d, e, 4)) + c(d, e, 5)) + c(d, e, 6)) + c(d, e, 7)) + c(d, e, 8)) + c(d, e, 9)) + c(d, e, 10)) + c(d, e, 11)) + c(d, e, 12)) + c(d, e, 13)) + c(d, e, 14)) | |
14 | 14 | ||
15 | 15 | ||
16 | 16 | func i (d,f) = ((((((((((((((c(d, 0, f) + c(d, 1, f)) + c(d, 2, f)) + c(d, 3, f)) + c(d, 4, f)) + c(d, 5, f)) + c(d, 6, f)) + c(d, 7, f)) + c(d, 8, f)) + c(d, 9, f)) + c(d, 10, f)) + c(d, 11, f)) + c(d, 12, f)) + c(d, 13, f)) + c(d, 14, f)) | |
17 | 17 | ||
18 | 18 | ||
19 | 19 | func j (d,k,l,m) = if ((l == "R")) | |
20 | 20 | then if (if ((k >= m)) | |
21 | 21 | then ((14 + m) >= k) | |
22 | 22 | else false) | |
23 | 23 | then c(d, m, (k - m)) | |
24 | 24 | else "" | |
25 | 25 | else if ((l == "L")) | |
26 | 26 | then if (if ((k >= m)) | |
27 | 27 | then ((14 + m) >= k) | |
28 | 28 | else false) | |
29 | 29 | then c(d, (k - m), (14 - m)) | |
30 | 30 | else "" | |
31 | 31 | else throw("invalid dir in diagHelper function") | |
32 | 32 | ||
33 | 33 | ||
34 | 34 | func n (d,k,l) = ((((((((((((((j(d, k, l, 14) + j(d, k, l, 13)) + j(d, k, l, 12)) + j(d, k, l, 11)) + j(d, k, l, 10)) + j(d, k, l, 9)) + j(d, k, l, 8)) + j(d, k, l, 7)) + j(d, k, l, 6)) + j(d, k, l, 5)) + j(d, k, l, 4)) + j(d, k, l, 3)) + j(d, k, l, 2)) + j(d, k, l, 1)) + j(d, k, l, 0)) | |
35 | 35 | ||
36 | 36 | ||
37 | 37 | func o (p,b) = if (if ((b != "b")) | |
38 | 38 | then (b != "w") | |
39 | 39 | else false) | |
40 | 40 | then throw("invalid color in check function") | |
41 | 41 | else { | |
42 | 42 | let q = indexOf(p, a(b)) | |
43 | 43 | if ($isInstanceOf(q, "Int")) | |
44 | 44 | then true | |
45 | 45 | else false | |
46 | 46 | } | |
47 | 47 | ||
48 | 48 | ||
49 | 49 | @Callable(m) | |
50 | 50 | func test (r,k,l) = { | |
51 | 51 | let d = extract(getString(this, (("game:" + toString(r)) + "_cells"))) | |
52 | 52 | throw(n(d, k, l)) | |
53 | 53 | } | |
54 | 54 | ||
55 | 55 | ||
56 | 56 | ||
57 | 57 | @Callable(m) | |
58 | 58 | func testSetCell (r,e,f,h) = { | |
59 | 59 | let d = extract(getString(this, (("game:" + toString(r)) + "_cells"))) | |
60 | 60 | let s = g(d, e, f, h) | |
61 | 61 | WriteSet([DataEntry((("game:" + toString(r)) + "_cells"), s)]) | |
62 | 62 | } | |
63 | 63 | ||
64 | 64 | ||
65 | 65 | @Verifier(t) | |
66 | 66 | func u () = true | |
67 | 67 |
github/deemru/w8io/169f3d6 163.53 ms ◑