tx · HSsEQsvThjfWCbMyPd74wr6yY4XGYvWRNv2v2URssNVC 3MqBZQSfaCVFG3HXjE7Jaeq6Z4ztMU2miPz: -0.00400000 Waves 2022.08.02 13:23 [2166746] smart account 3MqBZQSfaCVFG3HXjE7Jaeq6Z4ztMU2miPz > SELF 0.00000000 Waves
{ "type": 13, "id": "HSsEQsvThjfWCbMyPd74wr6yY4XGYvWRNv2v2URssNVC", "fee": 400000, "feeAssetId": null, "timestamp": 1659435834618, "version": 2, "chainId": 84, "sender": "3MqBZQSfaCVFG3HXjE7Jaeq6Z4ztMU2miPz", "senderPublicKey": "HfEpHsKBiv2JxCkN63ubUCnTfKx6PqsjC6pYWHMwHXYp", "proofs": [ "2DygPqmT7KoPPCsv24BTXJGKBFGifQ9aTNNSxJcUJNqyeSt7fX87jjfY86nQA17kkjb8YYEBBGngaZMDyzXFSFm" ], "script": "base64:AAIFAAAAAAAAAA0IAhIDCgEEEgQKAggIAAAAEQAAAAANUEFZTUVOVF9BU1NFVAEAAAAgrZ1IFoWReWfvw0p6hpnR3VDpBUk85P5AREeM4YPEwvQAAAAADFJFV0FSRF9BU1NFVAEAAAAgLTcTgdMkN12f4W9209EPk+8sLPTdia1cSlbofMkBchsAAAAADlBBWU1FTlRfQU1PVU5UAAAAAAAAD0JAAAAAAAZwaXhlbHMFAAAADFJFV0FSRF9BU1NFVAAAAAAEeE1JTgAAAAAAAAAAAAAAAAAEeE1BWAAAAAAAAAAEsQAAAAAEeU1JTgAAAAAAAAAAAAAAAAAEeU1BWAAAAAAAAAACWQAAAAANUkVXQVJEX0FNT1VOVAAAAAAABfXhAAAAAAAMU1RBUlRfSEVJR0hUAAAAAAAAINEjAAAAAApFTkRfSEVJR0hUCQAAZAAAAAIFAAAADFNUQVJUX0hFSUdIVAkAAGgAAAACAAAAAAAAAAWgAAAAAAAAAAAOAAAAAAdNQVhFQUNIAAAAAAAAAAPoAAAAAAdNQVhJTVVNAAAAAgvec2QAAAAAAA5BQ1RJVkVfU0VT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5UBQAAAAZwaXhlbHMFAAAAA25pbAkAAAIAAAABAgAAAB13cm9uZyBwYXltZW50IGFtb3VudCBvciBhc3NldAkAAAIAAAABAgAAAA5vdXQgb2YgY29udGV4dAkAAAIAAAABCQABLAAAAAIJAAEsAAAAAgIAAAAEbWF4IAkAAaQAAAABBQAAAAdNQVhFQUNIAgAAABggcGl4ZWxzIGZvciBlYWNoIHdhbGxldCEJAAACAAAAAQIAAAAPYWxsIHNvbGQuIHRoYW54CQAAAgAAAAECAAAAC3dyb25nIGNvbG9yCQAAAgAAAAECAAAAHGdhbWUgaXMgbm90IGFjdGl2ZSByaWdodCBub3cAAAAAV1XhuQ==", "height": 2166746, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 3of6iNHtWsukBtDHy6pU5bBydRw1zWbDwfUVTS81bQYQ Next: HEQyjUJVPPFWRXLLX7MVE3pTRJXBveH5ff7eXcMpX9wR Diff:
Old | New | Differences | |
---|---|---|---|
5 | 5 | ||
6 | 6 | let b = base58'43W4FcqA1rEpSmUGHoGiXvpSLfhadws9LS5j3SJsKxxS' | |
7 | 7 | ||
8 | - | let c = | |
8 | + | let c = 1000000 | |
9 | 9 | ||
10 | - | let d = | |
10 | + | let d = b | |
11 | 11 | ||
12 | - | let e = | |
12 | + | let e = 0 | |
13 | 13 | ||
14 | - | let f = | |
14 | + | let f = 1201 | |
15 | 15 | ||
16 | - | let g = | |
16 | + | let g = 0 | |
17 | 17 | ||
18 | - | let h = | |
18 | + | let h = 601 | |
19 | 19 | ||
20 | - | let i = | |
20 | + | let i = 100000000 | |
21 | 21 | ||
22 | - | let j = | |
22 | + | let j = 2150691 | |
23 | 23 | ||
24 | - | let k = | |
24 | + | let k = (j + (1440 * 14)) | |
25 | 25 | ||
26 | - | let l = | |
26 | + | let l = 1000 | |
27 | 27 | ||
28 | - | let m = | |
28 | + | let m = 2250000000000 | |
29 | 29 | ||
30 | - | let n = | |
30 | + | let n = 1 | |
31 | 31 | ||
32 | - | let o = | |
32 | + | let o = base58'CMa9TJH8JthRv8Uq8pZc4FSpgZ9bvpk6XRsZktUm2ivx' | |
33 | 33 | ||
34 | - | func p (q) = { | |
35 | - | let r = a | |
36 | - | if ((size(q.payments) == 0)) | |
34 | + | let p = ["000", "fff", "000000", "ffffff", "FF0200", "800080", "FF00FF", "008001", "FEFF00", "020080", "0800FF", "183937", "09FEFF", "7076E9", "C0C0C0", "C3103B", "ff0200", "ff00ff", "feff00", "0800ff", "09feff", "7076e9", "c0c0c0", "c3103b"] | |
35 | + | ||
36 | + | func q (r) = { | |
37 | + | let s = a | |
38 | + | if ((size(r.payments) == 0)) | |
37 | 39 | then throw("Payment not attached") | |
38 | 40 | else { | |
39 | - | let | |
40 | - | let | |
41 | - | if ($isInstanceOf( | |
41 | + | let t = r.payments[0] | |
42 | + | let u = t.assetId | |
43 | + | if ($isInstanceOf(u, "ByteVector")) | |
42 | 44 | then { | |
43 | - | let | |
44 | - | if (( | |
45 | - | then ( | |
45 | + | let v = u | |
46 | + | if ((v == s)) | |
47 | + | then (t.amount == 1000000) | |
46 | 48 | else false | |
47 | 49 | } | |
48 | 50 | else throw("Wrong payment asset") | |
50 | 52 | } | |
51 | 53 | ||
52 | 54 | ||
53 | - | @Callable(q) | |
54 | - | func coordinates (v,w) = if (if ((height > k)) | |
55 | - | then (l > height) | |
55 | + | @Callable(r) | |
56 | + | func shutdown (w) = if ((o != r.callerPublicKey)) | |
57 | + | then throw("you can not") | |
58 | + | else [BooleanEntry("isOpen", w)] | |
59 | + | ||
60 | + | ||
61 | + | ||
62 | + | @Callable(r) | |
63 | + | func coordinates (x,y) = if (if ((height > j)) | |
64 | + | then (k > height) | |
56 | 65 | else false) | |
57 | 66 | then { | |
58 | - | let | |
59 | - | if ( | |
67 | + | let z = containsElement(p, x) | |
68 | + | if (z) | |
60 | 69 | then { | |
61 | - | let | |
62 | - | let | |
63 | - | let | |
64 | - | let | |
65 | - | if (if ((( | |
70 | + | let A = toBase58String(r.caller.bytes) | |
71 | + | let B = split(y, "_") | |
72 | + | let C = valueOrElse(parseInt(B[0]), 0) | |
73 | + | let D = valueOrElse(parseInt(B[1]), 0) | |
74 | + | if (if (((C % 8) != 0)) | |
66 | 75 | then true | |
67 | - | else (( | |
76 | + | else ((D % 8) != 0)) | |
68 | 77 | then throw("not cool.") | |
69 | 78 | else { | |
70 | - | let | |
71 | - | let | |
72 | - | let | |
73 | - | let | |
74 | - | let | |
75 | - | let | |
76 | - | if (( | |
77 | - | then if (( | |
78 | - | then if (if (if (if (( | |
79 | - | then ( | |
79 | + | let E = ((toString(C) + "_") + toString(D)) | |
80 | + | let F = (((A + "_") + E) + "_c") | |
81 | + | let G = (A + "_count") | |
82 | + | let H = "pixels_count" | |
83 | + | let I = valueOrElse(getInteger(this, G), 0) | |
84 | + | let J = valueOrElse(getInteger(this, H), 0) | |
85 | + | if ((m >= J)) | |
86 | + | then if ((l >= I)) | |
87 | + | then if (if (if (if ((C >= e)) | |
88 | + | then (f > C) | |
80 | 89 | else false) | |
81 | - | then ( | |
90 | + | then (D >= g) | |
82 | 91 | else false) | |
83 | - | then ( | |
92 | + | then (h > D) | |
84 | 93 | else false) | |
85 | - | then if ( | |
86 | - | then [IntegerEntry( | |
87 | - | else throw(" | |
94 | + | then if (q(r)) | |
95 | + | then [IntegerEntry(G, (I + 1)), IntegerEntry(H, (J + 1)), StringEntry(F, x), ScriptTransfer(r.caller, i, d)] | |
96 | + | else throw("wrong payment amount or asset") | |
88 | 97 | else throw("out of context") | |
89 | - | else throw("max | |
98 | + | else throw((("max " + toString(l)) + " pixels for each wallet!")) | |
90 | 99 | else throw("all sold. thanx") | |
91 | 100 | } | |
92 | 101 | } |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 5 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let a = base58'CgidgEMbCKXXErgJXVyZCFRaK8SBNA73Jg8mNXALtVKh' | |
5 | 5 | ||
6 | 6 | let b = base58'43W4FcqA1rEpSmUGHoGiXvpSLfhadws9LS5j3SJsKxxS' | |
7 | 7 | ||
8 | - | let c = | |
8 | + | let c = 1000000 | |
9 | 9 | ||
10 | - | let d = | |
10 | + | let d = b | |
11 | 11 | ||
12 | - | let e = | |
12 | + | let e = 0 | |
13 | 13 | ||
14 | - | let f = | |
14 | + | let f = 1201 | |
15 | 15 | ||
16 | - | let g = | |
16 | + | let g = 0 | |
17 | 17 | ||
18 | - | let h = | |
18 | + | let h = 601 | |
19 | 19 | ||
20 | - | let i = | |
20 | + | let i = 100000000 | |
21 | 21 | ||
22 | - | let j = | |
22 | + | let j = 2150691 | |
23 | 23 | ||
24 | - | let k = | |
24 | + | let k = (j + (1440 * 14)) | |
25 | 25 | ||
26 | - | let l = | |
26 | + | let l = 1000 | |
27 | 27 | ||
28 | - | let m = | |
28 | + | let m = 2250000000000 | |
29 | 29 | ||
30 | - | let n = | |
30 | + | let n = 1 | |
31 | 31 | ||
32 | - | let o = | |
32 | + | let o = base58'CMa9TJH8JthRv8Uq8pZc4FSpgZ9bvpk6XRsZktUm2ivx' | |
33 | 33 | ||
34 | - | func p (q) = { | |
35 | - | let r = a | |
36 | - | if ((size(q.payments) == 0)) | |
34 | + | let p = ["000", "fff", "000000", "ffffff", "FF0200", "800080", "FF00FF", "008001", "FEFF00", "020080", "0800FF", "183937", "09FEFF", "7076E9", "C0C0C0", "C3103B", "ff0200", "ff00ff", "feff00", "0800ff", "09feff", "7076e9", "c0c0c0", "c3103b"] | |
35 | + | ||
36 | + | func q (r) = { | |
37 | + | let s = a | |
38 | + | if ((size(r.payments) == 0)) | |
37 | 39 | then throw("Payment not attached") | |
38 | 40 | else { | |
39 | - | let | |
40 | - | let | |
41 | - | if ($isInstanceOf( | |
41 | + | let t = r.payments[0] | |
42 | + | let u = t.assetId | |
43 | + | if ($isInstanceOf(u, "ByteVector")) | |
42 | 44 | then { | |
43 | - | let | |
44 | - | if (( | |
45 | - | then ( | |
45 | + | let v = u | |
46 | + | if ((v == s)) | |
47 | + | then (t.amount == 1000000) | |
46 | 48 | else false | |
47 | 49 | } | |
48 | 50 | else throw("Wrong payment asset") | |
49 | 51 | } | |
50 | 52 | } | |
51 | 53 | ||
52 | 54 | ||
53 | - | @Callable(q) | |
54 | - | func coordinates (v,w) = if (if ((height > k)) | |
55 | - | then (l > height) | |
55 | + | @Callable(r) | |
56 | + | func shutdown (w) = if ((o != r.callerPublicKey)) | |
57 | + | then throw("you can not") | |
58 | + | else [BooleanEntry("isOpen", w)] | |
59 | + | ||
60 | + | ||
61 | + | ||
62 | + | @Callable(r) | |
63 | + | func coordinates (x,y) = if (if ((height > j)) | |
64 | + | then (k > height) | |
56 | 65 | else false) | |
57 | 66 | then { | |
58 | - | let | |
59 | - | if ( | |
67 | + | let z = containsElement(p, x) | |
68 | + | if (z) | |
60 | 69 | then { | |
61 | - | let | |
62 | - | let | |
63 | - | let | |
64 | - | let | |
65 | - | if (if ((( | |
70 | + | let A = toBase58String(r.caller.bytes) | |
71 | + | let B = split(y, "_") | |
72 | + | let C = valueOrElse(parseInt(B[0]), 0) | |
73 | + | let D = valueOrElse(parseInt(B[1]), 0) | |
74 | + | if (if (((C % 8) != 0)) | |
66 | 75 | then true | |
67 | - | else (( | |
76 | + | else ((D % 8) != 0)) | |
68 | 77 | then throw("not cool.") | |
69 | 78 | else { | |
70 | - | let | |
71 | - | let | |
72 | - | let | |
73 | - | let | |
74 | - | let | |
75 | - | let | |
76 | - | if (( | |
77 | - | then if (( | |
78 | - | then if (if (if (if (( | |
79 | - | then ( | |
79 | + | let E = ((toString(C) + "_") + toString(D)) | |
80 | + | let F = (((A + "_") + E) + "_c") | |
81 | + | let G = (A + "_count") | |
82 | + | let H = "pixels_count" | |
83 | + | let I = valueOrElse(getInteger(this, G), 0) | |
84 | + | let J = valueOrElse(getInteger(this, H), 0) | |
85 | + | if ((m >= J)) | |
86 | + | then if ((l >= I)) | |
87 | + | then if (if (if (if ((C >= e)) | |
88 | + | then (f > C) | |
80 | 89 | else false) | |
81 | - | then ( | |
90 | + | then (D >= g) | |
82 | 91 | else false) | |
83 | - | then ( | |
92 | + | then (h > D) | |
84 | 93 | else false) | |
85 | - | then if ( | |
86 | - | then [IntegerEntry( | |
87 | - | else throw(" | |
94 | + | then if (q(r)) | |
95 | + | then [IntegerEntry(G, (I + 1)), IntegerEntry(H, (J + 1)), StringEntry(F, x), ScriptTransfer(r.caller, i, d)] | |
96 | + | else throw("wrong payment amount or asset") | |
88 | 97 | else throw("out of context") | |
89 | - | else throw("max | |
98 | + | else throw((("max " + toString(l)) + " pixels for each wallet!")) | |
90 | 99 | else throw("all sold. thanx") | |
91 | 100 | } | |
92 | 101 | } | |
93 | 102 | else throw("wrong color") | |
94 | 103 | } | |
95 | 104 | else throw("game is not active right now") | |
96 | 105 | ||
97 | 106 |
github/deemru/w8io/169f3d6 66.44 ms ◑