tx · GaedtkZapNA8aLnexQAAgCMab2Jm9QXZQrkQNWzJG6c 3N1x2A7NumZqydu5zGntLZSMe26rcpdyoss: -0.04000000 Waves 2020.08.26 14:48 [1149634] smart account 3N1x2A7NumZqydu5zGntLZSMe26rcpdyoss > SELF 0.00000000 Waves
{ "type": 13, "id": "GaedtkZapNA8aLnexQAAgCMab2Jm9QXZQrkQNWzJG6c", "fee": 4000000, "feeAssetId": null, "timestamp": 1598442494093, "version": 1, "sender": "3N1x2A7NumZqydu5zGntLZSMe26rcpdyoss", "senderPublicKey": "7EaUr5Z6zmEQJXz7jVWXjW7xbJLakPjxFPTZFogi8wzr", "proofs": [ "429zLqkKDaaz7wuBwfcobbSjU8yUoFJ3Z1zgtciA4GjpmmzqKsSKsfT5RxDamdkVu3vKXV5qTZPppXj84CetqPDm" ], "script": "base64:AAIDAAAAAAAAABEIARIECgIBARIFCgMBAQESAAAAAA0BAAAACXNldENvb3JkcwAAAAMAAAADa2V5AAAACGxhdGl0dWRlAAAACWxvbmdpdHVkZQkABEwAAAACCQEAAAAJRGF0YUVudHJ5AAAAAgkAASwAAAACAgAAAAxwb3NpdGlvbkxhdF8FAAAAA2tleQUAAAAIbGF0aXR1ZGUJAARMAAAAAgkBAAAACURhdGFFbnRyeQAAAAIJAAEsAAAAAgIAAAAMcG9zaXRpb25Mb25fBQAAAANrZXkFAAAACWxvbmdpdHVkZQUAAAADbmlsAQAAAAtzZXRHYW1lRGF0YQAAAAIAAAAJcGxheWVyS2V5AAAAC29wcG9uZW50S2V5BAAAAAZnYW1lSWQJAAEsAAAAAgkAASwAAAACBQAAAAlwbGF5ZXJLZXkCAAAAAV8FAAAAC29wcG9uZW50S2V5CQAETAAAAAIJAQAAAAlEYXRhRW50cnkAAAACCQABLAAAAAICAAAAB2dhbWVJZF8FAAAACXBsYXllcktleQUAAAAGZ2FtZUlkCQAETAAAAAIJAQAAAAlEYXRhRW50cnkAAAACCQABLAAAAAICAAAACW9wcG9uZW50XwUAAAAJcGx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AEJQAAAAEIBQAAAAFpAAAABmNhbGxlcgQAAAAHYmFsYW5jZQkAA+sAAAACCAUAAAABaQAAAAZjYWxsZXIFAAAABWFzc2V0AwkAAGYAAAACAAAAAAAAAABkBQAAAAdiYWxhbmNlCQEAAAALVHJhbnNmZXJTZXQAAAABCQAETAAAAAIJAQAAAA5TY3JpcHRUcmFuc2ZlcgAAAAMIBQAAAAFpAAAABmNhbGxlcgAAAAAAAAAAZAUAAAAFYXNzZXQFAAAAA25pbAkBAAAAC1RyYW5zZmVyU2V0AAAAAQUAAAADbmlsAAAAAEJIOlA=", "chainId": 84, "height": 1149634, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 9VwT1sHye3HmkEdWMXKWACQQ7APx6UZ7mnfU7BW4MAmD Next: 5tPGSMbmBTC8mGdJAMqYynkEb2iPUxeGuaXrCyvjNZVK Diff:
Old | New | Differences | |
---|---|---|---|
81 | 81 | func r (k) = j((157079 - k)) | |
82 | 82 | ||
83 | 83 | ||
84 | - | func s (t) = if ((-100000 >= t)) | |
85 | - | then -157080 | |
86 | - | else if ((t >= 100000)) | |
87 | - | then 157080 | |
88 | - | else if ((0 > t)) | |
89 | - | then { | |
90 | - | let u = (-1 * t) | |
91 | - | let v = (((-1873 * u) / 100000) + 7426) | |
92 | - | let w = (((v * u) / 100000) - 21211) | |
93 | - | let x = (((w * u) / 100000) + 157072) | |
94 | - | let y = pow((100000 - u), 5, 5, 1, 5, HALFEVEN) | |
95 | - | -((157080 - ((y * x) / 100000))) | |
96 | - | } | |
97 | - | else { | |
98 | - | let v = (((-1873 * t) / 100000) + 7426) | |
99 | - | let w = (((v * t) / 100000) - 21211) | |
100 | - | let x = (((w * t) / 100000) + 157072) | |
101 | - | let y = pow((100000 - t), 5, 5, 1, 5, HALFEVEN) | |
102 | - | (157080 - ((y * x) / 100000)) | |
103 | - | } | |
84 | + | func s (t) = if (if ((-100000 > t)) | |
85 | + | then true | |
86 | + | else (t > 100000)) | |
87 | + | then throw("The asin implementation is defined for x [-1,1]!") | |
88 | + | else if ((0 > t)) | |
89 | + | then { | |
90 | + | let u = (-1 * t) | |
91 | + | let v = ((((((-1873 * u) / 100000) + 7426) * u) / 100000) - 21211) | |
92 | + | let w = (((v * u) / 100000) + 157072) | |
93 | + | let x = pow((100000 - u), 5, 5, 1, 5, HALFEVEN) | |
94 | + | -((157080 - ((x * w) / 100000))) | |
95 | + | } | |
96 | + | else { | |
97 | + | let y = (((-1873 * t) / 100000) + 7426) | |
98 | + | let v = (((y * t) / 100000) - 21211) | |
99 | + | let w = (((v * t) / 100000) + 157072) | |
100 | + | let x = pow((100000 - t), 5, 5, 1, 5, HALFEVEN) | |
101 | + | (157080 - ((x * w) / 100000)) | |
102 | + | } | |
104 | 103 | ||
105 | 104 | ||
106 | 105 | func z (t) = { | |
114 | 113 | ||
115 | 114 | ||
116 | 115 | func B (C,t) = if ((t > 0)) | |
117 | - | then z((C / t)) | |
116 | + | then z(((C * 100000) / t)) | |
118 | 117 | else if (if ((0 > t)) | |
119 | 118 | then (C >= 0) | |
120 | 119 | else false) | |
121 | - | then (z((C / t)) + 314159) | |
120 | + | then (z(((C * 100000) / t)) + 314159) | |
122 | 121 | else if (if ((0 > t)) | |
123 | 122 | then (0 > C) | |
124 | 123 | else false) | |
125 | - | then (z((C / t)) - 314159) | |
124 | + | then (z(((C * 100000) / t)) - 314159) | |
126 | 125 | else if (if ((t == 0)) | |
127 | 126 | then (C > 0) | |
128 | 127 | else false) | |
144 | 143 | let O = j((M / 2)) | |
145 | 144 | let P = ((N * N) + (((r(H) * r(J)) / 100000) * ((O * O) / 100000))) | |
146 | 145 | let Q = (2 * s(pow((P / 1000), 7, 5, 1, 5, HALFEVEN))) | |
147 | - | ( | |
146 | + | ((637100000000 * Q) / 100000) | |
148 | 147 | } | |
149 | 148 | ||
150 | 149 | ||
155 | 154 | let Z = j(W) | |
156 | 155 | let aa = r(W) | |
157 | 156 | let ab = s((((X * aa) / 100000) + (((Y * Z) * r(V)) / 10000000000))) | |
158 | - | let ac = (T + B((((j(V) * Z) * Y) / | |
157 | + | let ac = (T + B((((j(V) * Z) * Y) / 10000000000), (aa - ((X * X) / 100000)))) | |
159 | 158 | [ab, ac] | |
160 | 159 | } | |
161 | 160 | ||
174 | 173 | } | |
175 | 174 | ||
176 | 175 | ||
177 | - | @Callable(ao) | |
176 | + | func ao (H,I,J,K) = { | |
177 | + | let M = (K - I) | |
178 | + | let C = ((j(M) * r(J)) / 100000) | |
179 | + | let t = (((r(H) * j(J)) - (((j(H) * r(J)) * r(M)) / 100000)) / 100000) | |
180 | + | ((B(C, t) + 628318) % 628318) | |
181 | + | } | |
182 | + | ||
183 | + | ||
184 | + | @Callable(ap) | |
178 | 185 | func startGame (c,d) = { | |
179 | - | let ap = base58'' | |
180 | - | let aq = value(ao.payment) | |
181 | - | let ar = toString(ao.caller) | |
182 | - | let as = a(ar, ((c * 1745) / 100000), ((d * 1745) / 100000)) | |
183 | - | let at = getString(this, "openGame") | |
184 | - | if (if ((aq.assetId == ap)) | |
185 | - | then (aq.amount >= 1) | |
186 | + | let aq = base58'' | |
187 | + | let ar = value(ap.payment) | |
188 | + | let as = toString(ap.caller) | |
189 | + | let ah = ((c * 1745) / 100000) | |
190 | + | let ai = ((d * 1745) / 100000) | |
191 | + | let at = a(as, ah, ai) | |
192 | + | let au = getString(this, "openGame") | |
193 | + | if (if ((ar.assetId == aq)) | |
194 | + | then (ar.amount >= 1) | |
186 | 195 | else false) | |
187 | 196 | then { | |
188 | - | let h = getString(this, ("gameId_" + | |
197 | + | let h = getString(this, ("gameId_" + as)) | |
189 | 198 | if (if ((h != "")) | |
190 | 199 | then (h != unit) | |
191 | 200 | else false) | |
192 | 201 | then throw("Please finish your current game, before starting another one") | |
193 | - | else if (!(isDefined( | |
194 | - | then WriteSet(DataEntry("openGame", | |
195 | - | else if (if (( | |
202 | + | else if (!(isDefined(au))) | |
203 | + | then WriteSet(DataEntry("openGame", as) :: at) | |
204 | + | else if (if ((au == "")) | |
196 | 205 | then true | |
197 | - | else (at == ar)) | |
198 | - | then WriteSet(DataEntry("openGame", ar) :: as) | |
199 | - | else WriteSet([DataEntry("openGame", ""), as[0], as[1], e(value(at), ar)]) | |
206 | + | else (au == as)) | |
207 | + | then WriteSet(DataEntry("openGame", as) :: at) | |
208 | + | else { | |
209 | + | let af = getIntegerValue(this, ("positionLat_" + value(au))) | |
210 | + | let ag = getIntegerValue(this, ("positionLon_" + value(au))) | |
211 | + | let aj = G(af, ag, ah, ai) | |
212 | + | let av = sha256(toBytes(aj)) | |
213 | + | let aw = toInt(av) | |
214 | + | let ax = ((aw % (628318 / 4)) - (628318 / 8)) | |
215 | + | let ay = ao(af, ag, ah, ai) | |
216 | + | let az = (ay + ax) | |
217 | + | let aA = ((ay + 314159) % 628318) | |
218 | + | let aB = (aA + ax) | |
219 | + | WriteSet([DataEntry("openGame", ""), at[0], at[1], DataEntry(("opponentOffsetYaw_" + as), az), DataEntry(("opponentOffsetYaw_" + value(au)), aB), e(value(au), as)]) | |
220 | + | } | |
200 | 221 | } | |
201 | 222 | else throw("Please pay the token") | |
202 | 223 | } | |
203 | 224 | ||
204 | 225 | ||
205 | 226 | ||
206 | - | @Callable( | |
227 | + | @Callable(ap) | |
207 | 228 | func executeShot (F,V,ae) = { | |
208 | - | let | |
209 | - | let | |
210 | - | let | |
211 | - | let h = i( | |
212 | - | if ((getStringValue(this, ("gameTurn_" + h)) != | |
229 | + | let aq = base58'' | |
230 | + | let as = toString(ap.caller) | |
231 | + | let aC = getStringValue(this, ("opponent_" + as)) | |
232 | + | let h = i(as) | |
233 | + | if ((getStringValue(this, ("gameTurn_" + h)) != as)) | |
213 | 234 | then throw("Please wait for your turn.") | |
214 | 235 | else { | |
215 | - | let | |
216 | - | if ( | |
217 | - | then ScriptResult(WriteSet([DataEntry(("game_" + h), false), DataEntry(("gameWinner_" + h), | |
218 | - | else WriteSet([DataEntry(("gameTurn_" + h), | |
236 | + | let aD = ad(F, V, ae, as, aC) | |
237 | + | if ((1000 > aD[0])) | |
238 | + | then ScriptResult(WriteSet([DataEntry(("game_" + h), false), DataEntry(("gameWinner_" + h), as), DataEntry(("lastShotDistance_" + h), aD[0]), DataEntry(("lastShotLat_" + h), aD[1]), DataEntry(("lastShotLon_" + h), aD[2])]), TransferSet([ScriptTransfer(ap.caller, 2, aq)])) | |
239 | + | else WriteSet([DataEntry(("gameTurn_" + h), aC), DataEntry(("lastShotDistance_" + h), aD[0]), DataEntry(("lastShotLat_" + h), aD[1]), DataEntry(("lastShotLon_" + h), aD[2])]) | |
219 | 240 | } | |
220 | 241 | } | |
221 | 242 | ||
222 | 243 | ||
223 | 244 | ||
224 | - | @Callable( | |
245 | + | @Callable(ap) | |
225 | 246 | func faucet () = { | |
226 | - | let | |
227 | - | let | |
228 | - | let | |
229 | - | if ((100 > | |
230 | - | then TransferSet([ScriptTransfer( | |
247 | + | let aq = base58'' | |
248 | + | let as = toString(ap.caller) | |
249 | + | let aE = assetBalance(ap.caller, aq) | |
250 | + | if ((100 > aE)) | |
251 | + | then TransferSet([ScriptTransfer(ap.caller, 100, aq)]) | |
231 | 252 | else TransferSet(nil) | |
232 | 253 | } | |
233 | 254 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 3 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | func a (b,c,d) = [DataEntry(("positionLat_" + b), c), DataEntry(("positionLon_" + b), d)] | |
5 | 5 | ||
6 | 6 | ||
7 | 7 | func e (f,g) = { | |
8 | 8 | let h = ((f + "_") + g) | |
9 | 9 | [DataEntry(("gameId_" + f), h), DataEntry(("opponent_" + f), g), DataEntry(("gameId_" + g), h), DataEntry(("opponent_" + g), f), DataEntry(("game_" + h), true), DataEntry(("gameTurn_" + h), f), DataEntry(("gameWinner_" + h), "")] | |
10 | 10 | } | |
11 | 11 | ||
12 | 12 | ||
13 | 13 | func i (b) = getStringValue(this, ("gameId_" + b)) | |
14 | 14 | ||
15 | 15 | ||
16 | 16 | func j (k) = { | |
17 | 17 | let l = (k / 628318) | |
18 | 18 | if ((0 > k)) | |
19 | 19 | then { | |
20 | 20 | let m = -(k) | |
21 | 21 | if ((m > 628318)) | |
22 | 22 | then { | |
23 | 23 | let n = (m + (l * 628318)) | |
24 | 24 | if ((n > 314159)) | |
25 | 25 | then { | |
26 | 26 | let o = (n - 314159) | |
27 | 27 | let p = ((16 * o) * (314159 - o)) | |
28 | 28 | let q = (493480220050 - (p / 4)) | |
29 | 29 | ((p * 100000) / q) | |
30 | 30 | } | |
31 | 31 | else { | |
32 | 32 | let p = ((16 * n) * (314159 - n)) | |
33 | 33 | let q = (493480220050 - (p / 4)) | |
34 | 34 | ((-(p) * 100000) / q) | |
35 | 35 | } | |
36 | 36 | } | |
37 | 37 | else if ((m > 314159)) | |
38 | 38 | then { | |
39 | 39 | let n = (m - 314159) | |
40 | 40 | let p = ((16 * n) * (314159 - n)) | |
41 | 41 | let q = (493480220050 - (p / 4)) | |
42 | 42 | ((p * 100000) / q) | |
43 | 43 | } | |
44 | 44 | else { | |
45 | 45 | let p = ((16 * m) * (314159 - m)) | |
46 | 46 | let q = (493480220050 - (p / 4)) | |
47 | 47 | ((-(p) * 100000) / q) | |
48 | 48 | } | |
49 | 49 | } | |
50 | 50 | else if ((k > 628318)) | |
51 | 51 | then { | |
52 | 52 | let n = (k - (l * 628318)) | |
53 | 53 | if ((n > 314159)) | |
54 | 54 | then { | |
55 | 55 | let o = (n - 314159) | |
56 | 56 | let p = ((16 * o) * (314159 - o)) | |
57 | 57 | let q = (493480220050 - (p / 4)) | |
58 | 58 | ((-(p) * 100000) / q) | |
59 | 59 | } | |
60 | 60 | else { | |
61 | 61 | let p = ((16 * n) * (314159 - n)) | |
62 | 62 | let q = (493480220050 - (p / 4)) | |
63 | 63 | ((p * 100000) / q) | |
64 | 64 | } | |
65 | 65 | } | |
66 | 66 | else if ((k > 314159)) | |
67 | 67 | then { | |
68 | 68 | let n = (k - 314159) | |
69 | 69 | let p = ((16 * n) * (314159 - n)) | |
70 | 70 | let q = (493480220050 - (p / 4)) | |
71 | 71 | ((-(p) * 100000) / q) | |
72 | 72 | } | |
73 | 73 | else { | |
74 | 74 | let p = ((16 * k) * (314159 - k)) | |
75 | 75 | let q = (493480220050 - (p / 4)) | |
76 | 76 | ((p * 100000) / q) | |
77 | 77 | } | |
78 | 78 | } | |
79 | 79 | ||
80 | 80 | ||
81 | 81 | func r (k) = j((157079 - k)) | |
82 | 82 | ||
83 | 83 | ||
84 | - | func s (t) = if ((-100000 >= t)) | |
85 | - | then -157080 | |
86 | - | else if ((t >= 100000)) | |
87 | - | then 157080 | |
88 | - | else if ((0 > t)) | |
89 | - | then { | |
90 | - | let u = (-1 * t) | |
91 | - | let v = (((-1873 * u) / 100000) + 7426) | |
92 | - | let w = (((v * u) / 100000) - 21211) | |
93 | - | let x = (((w * u) / 100000) + 157072) | |
94 | - | let y = pow((100000 - u), 5, 5, 1, 5, HALFEVEN) | |
95 | - | -((157080 - ((y * x) / 100000))) | |
96 | - | } | |
97 | - | else { | |
98 | - | let v = (((-1873 * t) / 100000) + 7426) | |
99 | - | let w = (((v * t) / 100000) - 21211) | |
100 | - | let x = (((w * t) / 100000) + 157072) | |
101 | - | let y = pow((100000 - t), 5, 5, 1, 5, HALFEVEN) | |
102 | - | (157080 - ((y * x) / 100000)) | |
103 | - | } | |
84 | + | func s (t) = if (if ((-100000 > t)) | |
85 | + | then true | |
86 | + | else (t > 100000)) | |
87 | + | then throw("The asin implementation is defined for x [-1,1]!") | |
88 | + | else if ((0 > t)) | |
89 | + | then { | |
90 | + | let u = (-1 * t) | |
91 | + | let v = ((((((-1873 * u) / 100000) + 7426) * u) / 100000) - 21211) | |
92 | + | let w = (((v * u) / 100000) + 157072) | |
93 | + | let x = pow((100000 - u), 5, 5, 1, 5, HALFEVEN) | |
94 | + | -((157080 - ((x * w) / 100000))) | |
95 | + | } | |
96 | + | else { | |
97 | + | let y = (((-1873 * t) / 100000) + 7426) | |
98 | + | let v = (((y * t) / 100000) - 21211) | |
99 | + | let w = (((v * t) / 100000) + 157072) | |
100 | + | let x = pow((100000 - t), 5, 5, 1, 5, HALFEVEN) | |
101 | + | (157080 - ((x * w) / 100000)) | |
102 | + | } | |
104 | 103 | ||
105 | 104 | ||
106 | 105 | func z (t) = { | |
107 | 106 | let A = ((t * t) / 100000) | |
108 | 107 | if ((-100000 > t)) | |
109 | 108 | then (-157079 - ((t * 100000) / (A + 28000))) | |
110 | 109 | else if ((t > 100000)) | |
111 | 110 | then (157079 - ((t * 100000) / (A + 28000))) | |
112 | 111 | else ((t * 100000) / (100000 + ((28000 * A) / 100000))) | |
113 | 112 | } | |
114 | 113 | ||
115 | 114 | ||
116 | 115 | func B (C,t) = if ((t > 0)) | |
117 | - | then z((C / t)) | |
116 | + | then z(((C * 100000) / t)) | |
118 | 117 | else if (if ((0 > t)) | |
119 | 118 | then (C >= 0) | |
120 | 119 | else false) | |
121 | - | then (z((C / t)) + 314159) | |
120 | + | then (z(((C * 100000) / t)) + 314159) | |
122 | 121 | else if (if ((0 > t)) | |
123 | 122 | then (0 > C) | |
124 | 123 | else false) | |
125 | - | then (z((C / t)) - 314159) | |
124 | + | then (z(((C * 100000) / t)) - 314159) | |
126 | 125 | else if (if ((t == 0)) | |
127 | 126 | then (C > 0) | |
128 | 127 | else false) | |
129 | 128 | then 157080 | |
130 | 129 | else if (if ((t == 0)) | |
131 | 130 | then (0 > C) | |
132 | 131 | else false) | |
133 | 132 | then -157080 | |
134 | 133 | else 0 | |
135 | 134 | ||
136 | 135 | ||
137 | 136 | func D (E,F) = (((2 * E) * ((r(F) * j(F)) / 100000)) / 980665) | |
138 | 137 | ||
139 | 138 | ||
140 | 139 | func G (H,I,J,K) = { | |
141 | 140 | let L = (H - J) | |
142 | 141 | let M = (I - K) | |
143 | 142 | let N = j((L / 2)) | |
144 | 143 | let O = j((M / 2)) | |
145 | 144 | let P = ((N * N) + (((r(H) * r(J)) / 100000) * ((O * O) / 100000))) | |
146 | 145 | let Q = (2 * s(pow((P / 1000), 7, 5, 1, 5, HALFEVEN))) | |
147 | - | ( | |
146 | + | ((637100000000 * Q) / 100000) | |
148 | 147 | } | |
149 | 148 | ||
150 | 149 | ||
151 | 150 | func R (S,T,U,V) = { | |
152 | 151 | let W = (U / 6371000) | |
153 | 152 | let X = j(S) | |
154 | 153 | let Y = r(S) | |
155 | 154 | let Z = j(W) | |
156 | 155 | let aa = r(W) | |
157 | 156 | let ab = s((((X * aa) / 100000) + (((Y * Z) * r(V)) / 10000000000))) | |
158 | - | let ac = (T + B((((j(V) * Z) * Y) / | |
157 | + | let ac = (T + B((((j(V) * Z) * Y) / 10000000000), (aa - ((X * X) / 100000)))) | |
159 | 158 | [ab, ac] | |
160 | 159 | } | |
161 | 160 | ||
162 | 161 | ||
163 | 162 | func ad (F,V,ae,f,g) = { | |
164 | 163 | let af = getIntegerValue(this, ("positionLat_" + f)) | |
165 | 164 | let ag = getIntegerValue(this, ("positionLon_" + f)) | |
166 | 165 | let ah = getIntegerValue(this, ("positionLat_" + g)) | |
167 | 166 | let ai = getIntegerValue(this, ("positionLon_" + g)) | |
168 | 167 | let aj = G(af, ag, ah, ai) | |
169 | 168 | let ak = ((aj * 980665) / 100000) | |
170 | 169 | let al = D(((ak * ae) / 100000), F) | |
171 | 170 | let am = R(af, ag, al, V) | |
172 | 171 | let an = G(am[0], am[1], ah, ai) | |
173 | 172 | an :: am | |
174 | 173 | } | |
175 | 174 | ||
176 | 175 | ||
177 | - | @Callable(ao) | |
176 | + | func ao (H,I,J,K) = { | |
177 | + | let M = (K - I) | |
178 | + | let C = ((j(M) * r(J)) / 100000) | |
179 | + | let t = (((r(H) * j(J)) - (((j(H) * r(J)) * r(M)) / 100000)) / 100000) | |
180 | + | ((B(C, t) + 628318) % 628318) | |
181 | + | } | |
182 | + | ||
183 | + | ||
184 | + | @Callable(ap) | |
178 | 185 | func startGame (c,d) = { | |
179 | - | let ap = base58'' | |
180 | - | let aq = value(ao.payment) | |
181 | - | let ar = toString(ao.caller) | |
182 | - | let as = a(ar, ((c * 1745) / 100000), ((d * 1745) / 100000)) | |
183 | - | let at = getString(this, "openGame") | |
184 | - | if (if ((aq.assetId == ap)) | |
185 | - | then (aq.amount >= 1) | |
186 | + | let aq = base58'' | |
187 | + | let ar = value(ap.payment) | |
188 | + | let as = toString(ap.caller) | |
189 | + | let ah = ((c * 1745) / 100000) | |
190 | + | let ai = ((d * 1745) / 100000) | |
191 | + | let at = a(as, ah, ai) | |
192 | + | let au = getString(this, "openGame") | |
193 | + | if (if ((ar.assetId == aq)) | |
194 | + | then (ar.amount >= 1) | |
186 | 195 | else false) | |
187 | 196 | then { | |
188 | - | let h = getString(this, ("gameId_" + | |
197 | + | let h = getString(this, ("gameId_" + as)) | |
189 | 198 | if (if ((h != "")) | |
190 | 199 | then (h != unit) | |
191 | 200 | else false) | |
192 | 201 | then throw("Please finish your current game, before starting another one") | |
193 | - | else if (!(isDefined( | |
194 | - | then WriteSet(DataEntry("openGame", | |
195 | - | else if (if (( | |
202 | + | else if (!(isDefined(au))) | |
203 | + | then WriteSet(DataEntry("openGame", as) :: at) | |
204 | + | else if (if ((au == "")) | |
196 | 205 | then true | |
197 | - | else (at == ar)) | |
198 | - | then WriteSet(DataEntry("openGame", ar) :: as) | |
199 | - | else WriteSet([DataEntry("openGame", ""), as[0], as[1], e(value(at), ar)]) | |
206 | + | else (au == as)) | |
207 | + | then WriteSet(DataEntry("openGame", as) :: at) | |
208 | + | else { | |
209 | + | let af = getIntegerValue(this, ("positionLat_" + value(au))) | |
210 | + | let ag = getIntegerValue(this, ("positionLon_" + value(au))) | |
211 | + | let aj = G(af, ag, ah, ai) | |
212 | + | let av = sha256(toBytes(aj)) | |
213 | + | let aw = toInt(av) | |
214 | + | let ax = ((aw % (628318 / 4)) - (628318 / 8)) | |
215 | + | let ay = ao(af, ag, ah, ai) | |
216 | + | let az = (ay + ax) | |
217 | + | let aA = ((ay + 314159) % 628318) | |
218 | + | let aB = (aA + ax) | |
219 | + | WriteSet([DataEntry("openGame", ""), at[0], at[1], DataEntry(("opponentOffsetYaw_" + as), az), DataEntry(("opponentOffsetYaw_" + value(au)), aB), e(value(au), as)]) | |
220 | + | } | |
200 | 221 | } | |
201 | 222 | else throw("Please pay the token") | |
202 | 223 | } | |
203 | 224 | ||
204 | 225 | ||
205 | 226 | ||
206 | - | @Callable( | |
227 | + | @Callable(ap) | |
207 | 228 | func executeShot (F,V,ae) = { | |
208 | - | let | |
209 | - | let | |
210 | - | let | |
211 | - | let h = i( | |
212 | - | if ((getStringValue(this, ("gameTurn_" + h)) != | |
229 | + | let aq = base58'' | |
230 | + | let as = toString(ap.caller) | |
231 | + | let aC = getStringValue(this, ("opponent_" + as)) | |
232 | + | let h = i(as) | |
233 | + | if ((getStringValue(this, ("gameTurn_" + h)) != as)) | |
213 | 234 | then throw("Please wait for your turn.") | |
214 | 235 | else { | |
215 | - | let | |
216 | - | if ( | |
217 | - | then ScriptResult(WriteSet([DataEntry(("game_" + h), false), DataEntry(("gameWinner_" + h), | |
218 | - | else WriteSet([DataEntry(("gameTurn_" + h), | |
236 | + | let aD = ad(F, V, ae, as, aC) | |
237 | + | if ((1000 > aD[0])) | |
238 | + | then ScriptResult(WriteSet([DataEntry(("game_" + h), false), DataEntry(("gameWinner_" + h), as), DataEntry(("lastShotDistance_" + h), aD[0]), DataEntry(("lastShotLat_" + h), aD[1]), DataEntry(("lastShotLon_" + h), aD[2])]), TransferSet([ScriptTransfer(ap.caller, 2, aq)])) | |
239 | + | else WriteSet([DataEntry(("gameTurn_" + h), aC), DataEntry(("lastShotDistance_" + h), aD[0]), DataEntry(("lastShotLat_" + h), aD[1]), DataEntry(("lastShotLon_" + h), aD[2])]) | |
219 | 240 | } | |
220 | 241 | } | |
221 | 242 | ||
222 | 243 | ||
223 | 244 | ||
224 | - | @Callable( | |
245 | + | @Callable(ap) | |
225 | 246 | func faucet () = { | |
226 | - | let | |
227 | - | let | |
228 | - | let | |
229 | - | if ((100 > | |
230 | - | then TransferSet([ScriptTransfer( | |
247 | + | let aq = base58'' | |
248 | + | let as = toString(ap.caller) | |
249 | + | let aE = assetBalance(ap.caller, aq) | |
250 | + | if ((100 > aE)) | |
251 | + | then TransferSet([ScriptTransfer(ap.caller, 100, aq)]) | |
231 | 252 | else TransferSet(nil) | |
232 | 253 | } | |
233 | 254 | ||
234 | 255 |
github/deemru/w8io/026f985 53.24 ms ◑