tx · EE7PXrFsMfWyzVxxAYQLvprac5ymjXm1hYZAn9xCB2wJ 3Mq394ZzPDWJnd6gunucMYbCCxo2eQ3iCab: -0.01500000 Waves 2019.07.11 14:10 [580952] smart account 3Mq394ZzPDWJnd6gunucMYbCCxo2eQ3iCab > SELF 0.00000000 Waves
{ "type": 13, "id": "EE7PXrFsMfWyzVxxAYQLvprac5ymjXm1hYZAn9xCB2wJ", "fee": 1500000, "feeAssetId": null, "timestamp": 1562843471362, "version": 1, "sender": "3Mq394ZzPDWJnd6gunucMYbCCxo2eQ3iCab", "senderPublicKey": "Fds2CCSW5vEnSQb5rkTxtuLmxawFWC4vt8gRruq9QZdJ", "proofs": [ "2mjywf8QgyNzsQD1xqnBPKV75bA2Pp8aYZh8WD3YgsdLgju3U7saaHo9GidwR51gdaeEZbz5Trj7ZyyEpCxUugxf" ], "script": "base64:AAIDAAAAAAAAAAAAAAAvAAAAAAdXQVZFTEVUCQAAaAAAAAIJAABoAAAAAgAAAAAAAAAAZAAAAAAAAAAD6AAAAAAAAAAD6AAAAAAKQ09NTUlTU0lPTgkAAGkAAAACCQAAaAAAAAIAAAAAAAAAAAUFAAAAB1dBVkVMRVQAAAAAAAAAA+gAAAAACVJTQVBVQkxJQwkAAlsAAAABAgAAAY9iYXNlNjQ6TUlJQklqQU5CZ2txaGtpRzl3MEJBUUVGQUFPQ0FROEFNSUlCQ2dLQ0FRRUFxbEFpQU5TbUJwREhZS1A5c0tnZU4vbDFiQWIyOGcvdEdsZ0Rrd1Q1RmlNTjRYM3B3ZHZkeEU3bXZTUjgvNDFkVTlyeDRqRys2dFpwYjFVTFZEUHM0MzF0UjJJUmFUWHc1Q2orQWMydmhMKzVKYW1DZXJHRDFVVytiaC9FR1F0eG84VzNZTERyb2ZYQjVRSEp4NFBrejJLZ2Yrb1MvQzhoSHVCL1U0a3JPNzZVMDUwN0dUalpQUDlrUlEwdUxTTWVxUVh0OHdYUytuTXA1d2FqcXhQcERMTWFTUkVnc0t3di9BRWt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bXQAAAAAAwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAABRTZXRTY3JpcHRUcmFuc2FjdGlvbgQAAAADc3R4BQAAAAckbWF0Y2gwAwkAAAAAAAACCQEAAAAISXNEQXBwVXAAAAAABwkAAAAAAAACCQEAAAASRXh0cmFjdFJlc2VydmVkQW10AAAAAAAAAAAAAAAAAAcHB4StD/Q=", "chainId": 84, "height": 580952, "spentComplexity": 0 } View: original | compacted Prev: none Next: none Full:
Old | New | Differences | |
---|---|---|---|
1 | - | # no script | |
1 | + | {-# STDLIB_VERSION 3 #-} | |
2 | + | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | + | {-# CONTENT_TYPE DAPP #-} | |
4 | + | let a = ((100 * 1000) * 1000) | |
5 | + | ||
6 | + | let b = ((5 * a) / 1000) | |
7 | + | ||
8 | + | let c = fromBase64String("base64:MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAqlAiANSmBpDHYKP9sKgeN/l1bAb28g/tGlgDkwT5FiMN4X3pwdvdxE7mvSR8/41dU9rx4jG+6tZpb1ULVDPs431tR2IRaTXw5Cj+Ac2vhL+5JamCerGD1UW+bh/EGQtxo8W3YLDrofXB5QHJx4Pkz2Kgf+oS/C8hHuB/U4krO76U0507GTjZPP9kRQ0uLSMeqQXt8wXS+nMp5wajqxPpDLMaSREgsKwv/AEkP4dzpTYbikLBYl4qtdJsD84HLFSkiwd3BhcOrPjoIYmLxQuBD5TIMKTKD3sdZgaY9rsyqx3A00innyxD6zp3b4gFpUOX8JxKZdEC2myEqleNgg7GzwIDAQAB") | |
9 | + | ||
10 | + | let d = addressFromStringValue("3MsT1dUWZ8fevrxs9PwAFLLMv6bbBQPyoTy") | |
11 | + | ||
12 | + | let e = 2880 | |
13 | + | ||
14 | + | let f = (70 * a) | |
15 | + | ||
16 | + | let g = (1 * a) | |
17 | + | ||
18 | + | let h = (2 * a) | |
19 | + | ||
20 | + | let i = (4 * a) | |
21 | + | ||
22 | + | let j = (8 * a) | |
23 | + | ||
24 | + | let k = (14 * a) | |
25 | + | ||
26 | + | let l = 10000 | |
27 | + | ||
28 | + | let m = 39655 | |
29 | + | ||
30 | + | let n = 24600 | |
31 | + | ||
32 | + | let o = 19000 | |
33 | + | ||
34 | + | let p = 14200 | |
35 | + | ||
36 | + | let q = 11400 | |
37 | + | ||
38 | + | let r = 0 | |
39 | + | ||
40 | + | let s = 1 | |
41 | + | ||
42 | + | let t = 2 | |
43 | + | ||
44 | + | let u = 3 | |
45 | + | ||
46 | + | let v = 4 | |
47 | + | ||
48 | + | let w = 5 | |
49 | + | ||
50 | + | let x = "$RESERVED_AMOUNT" | |
51 | + | ||
52 | + | let y = "$GAME_NUM" | |
53 | + | ||
54 | + | let z = "$DAPP_UP" | |
55 | + | ||
56 | + | let A = "$MAX_BALANCE" | |
57 | + | ||
58 | + | let B = "SUBMITTED" | |
59 | + | ||
60 | + | let C = "WON" | |
61 | + | ||
62 | + | let D = "LOST" | |
63 | + | ||
64 | + | func E () = { | |
65 | + | let F = { | |
66 | + | let G = getInteger(this, y) | |
67 | + | if ($isInstanceOf(G, "Int")) | |
68 | + | then { | |
69 | + | let H = G | |
70 | + | H | |
71 | + | } | |
72 | + | else 0 | |
73 | + | } | |
74 | + | (F + 1) | |
75 | + | } | |
76 | + | ||
77 | + | ||
78 | + | func I () = { | |
79 | + | let G = getInteger(this, x) | |
80 | + | if ($isInstanceOf(G, "Int")) | |
81 | + | then { | |
82 | + | let J = G | |
83 | + | J | |
84 | + | } | |
85 | + | else 0 | |
86 | + | } | |
87 | + | ||
88 | + | ||
89 | + | func K (L) = { | |
90 | + | let M = (I() + L) | |
91 | + | let N = wavesBalance(this) | |
92 | + | if ((M > N)) | |
93 | + | then throw("Insufficient funds on Dice Roller account. Transaction was rejected for your safety.") | |
94 | + | else M | |
95 | + | } | |
96 | + | ||
97 | + | ||
98 | + | func O (P,L) = { | |
99 | + | let M = (I() - L) | |
100 | + | if ((0 > M)) | |
101 | + | then throw("Invalid Dice Roller account state - reserved amount is less than 0") | |
102 | + | else DataEntry(x, M) | |
103 | + | } | |
104 | + | ||
105 | + | ||
106 | + | func Q (R,S) = { | |
107 | + | let T = if (if (if (if ((R == (g + b))) | |
108 | + | then true | |
109 | + | else (R == (h + b))) | |
110 | + | then true | |
111 | + | else (R == (i + b))) | |
112 | + | then true | |
113 | + | else (R == (j + b))) | |
114 | + | then true | |
115 | + | else (R == (k + b)) | |
116 | + | if (T) | |
117 | + | then { | |
118 | + | let U = size(S) | |
119 | + | let V = (R - b) | |
120 | + | if ((U == 1)) | |
121 | + | then ((V * m) / l) | |
122 | + | else if ((U == 2)) | |
123 | + | then ((V * n) / l) | |
124 | + | else if ((U == 3)) | |
125 | + | then ((V * o) / l) | |
126 | + | else if ((U == 4)) | |
127 | + | then ((V * p) / l) | |
128 | + | else if ((U == 5)) | |
129 | + | then ((V * q) / l) | |
130 | + | else throw("Invalid dices count in player's choice") | |
131 | + | } | |
132 | + | else throw("Bet amount is not in range") | |
133 | + | } | |
134 | + | ||
135 | + | ||
136 | + | func W (X) = if ((X == 0)) | |
137 | + | then "1" | |
138 | + | else if ((X == 1)) | |
139 | + | then "2" | |
140 | + | else if ((X == 2)) | |
141 | + | then "3" | |
142 | + | else if ((X == 3)) | |
143 | + | then "4" | |
144 | + | else if ((X == 4)) | |
145 | + | then "5" | |
146 | + | else if ((X == 5)) | |
147 | + | then "6" | |
148 | + | else throw(("Unsupported r parameter passed: expected=[0,...,5] actual=" + toString(X))) | |
149 | + | ||
150 | + | ||
151 | + | func Y (P,Z) = { | |
152 | + | let aa = rsaVerify(SHA256, toBytes(P), Z, c) | |
153 | + | if (aa) | |
154 | + | then { | |
155 | + | let ab = (toInt(sha256(Z)) % 6) | |
156 | + | if ((0 > ab)) | |
157 | + | then (-1 * ab) | |
158 | + | else ab | |
159 | + | } | |
160 | + | else throw("Invalid RSA signature") | |
161 | + | } | |
162 | + | ||
163 | + | ||
164 | + | func ac (S,ad) = { | |
165 | + | let ae = size(S) | |
166 | + | if (if (if (if (if ((ae >= 1)) | |
167 | + | then (take(drop(S, 0), 1) == ad) | |
168 | + | else false) | |
169 | + | then true | |
170 | + | else if ((ae >= 2)) | |
171 | + | then (take(drop(S, 1), 1) == ad) | |
172 | + | else false) | |
173 | + | then true | |
174 | + | else if ((ae >= 3)) | |
175 | + | then (take(drop(S, 2), 1) == ad) | |
176 | + | else false) | |
177 | + | then true | |
178 | + | else if ((ae >= 4)) | |
179 | + | then (take(drop(S, 3), 1) == ad) | |
180 | + | else false) | |
181 | + | then true | |
182 | + | else if ((ae == 5)) | |
183 | + | then (take(drop(S, 4), 1) == ad) | |
184 | + | else false | |
185 | + | } | |
186 | + | ||
187 | + | ||
188 | + | func af (ag) = { | |
189 | + | let ae = size(ag) | |
190 | + | if ((ae == 0)) | |
191 | + | then throw("Parameter size must be greater then 0") | |
192 | + | else if ((ae > 99)) | |
193 | + | then throw("Parameter size must be less then 100") | |
194 | + | else if ((10 > ae)) | |
195 | + | then (("0" + toString(ae)) + ag) | |
196 | + | else (toString(ae) + ag) | |
197 | + | } | |
198 | + | ||
199 | + | ||
200 | + | func ah (ai,S,aj,ak,L,al) = { | |
201 | + | let am = ((((((((af(ai) + "_") + af(S)) + "_") + af(aj)) + "_") + af(toString(ak))) + "_") + af(toString(L))) | |
202 | + | if ((al == "")) | |
203 | + | then am | |
204 | + | else ((am + "_") + af(al)) | |
205 | + | } | |
206 | + | ||
207 | + | ||
208 | + | func an (ao) = if ((size(ao) > 0)) | |
209 | + | then drop(ao, 1) | |
210 | + | else ao | |
211 | + | ||
212 | + | ||
213 | + | func ap (ao) = { | |
214 | + | let ae = size(ao) | |
215 | + | if ((ae > 0)) | |
216 | + | then { | |
217 | + | let aq = parseIntValue(take(ao, 2)) | |
218 | + | let ar = take(drop(ao, 2), aq) | |
219 | + | let as = drop(ao, (aq + 2)) | |
220 | + | let at = an(as) | |
221 | + | [ar, at] | |
222 | + | } | |
223 | + | else throw("Empty string was passed into parseNextAttribute func") | |
224 | + | } | |
225 | + | ||
226 | + | ||
227 | + | func au (av) = { | |
228 | + | let ai = ap(av) | |
229 | + | let S = ap(ai[1]) | |
230 | + | let aj = ap(S[1]) | |
231 | + | let ak = ap(aj[1]) | |
232 | + | let L = ap(ak[1]) | |
233 | + | [ai[0], S[0], aj[0], ak[0], L[0]] | |
234 | + | } | |
235 | + | ||
236 | + | ||
237 | + | func aw (P) = { | |
238 | + | let ax = { | |
239 | + | let G = getString(this, P) | |
240 | + | if ($isInstanceOf(G, "String")) | |
241 | + | then { | |
242 | + | let ay = G | |
243 | + | ay | |
244 | + | } | |
245 | + | else throw(("Couldn't find game by " + P)) | |
246 | + | } | |
247 | + | au(ax) | |
248 | + | } | |
249 | + | ||
250 | + | ||
251 | + | func az (P,aA,L,aB,aC,aD) = { | |
252 | + | let aE = [aD] | |
253 | + | let aF = [ScriptTransfer(aA, L, unit)] | |
254 | + | if (aC) | |
255 | + | then { | |
256 | + | let aG = ((aB + "_") + af("TIMEOUT")) | |
257 | + | let aH = DataEntry(P, aG) | |
258 | + | ScriptResult(WriteSet(aH :: aE), TransferSet(aF)) | |
259 | + | } | |
260 | + | else { | |
261 | + | let aH = DataEntry(P, aB) | |
262 | + | ScriptResult(WriteSet(aH :: aE), TransferSet(aF)) | |
263 | + | } | |
264 | + | } | |
265 | + | ||
266 | + | ||
267 | + | func aI () = { | |
268 | + | let aJ = getBoolean(this, z) | |
269 | + | if (isDefined(aJ)) | |
270 | + | then extract(aJ) | |
271 | + | else false | |
272 | + | } | |
273 | + | ||
274 | + | ||
275 | + | func aK () = { | |
276 | + | let aL = getInteger(this, A) | |
277 | + | let aM = if (isDefined(aL)) | |
278 | + | then extract(aL) | |
279 | + | else 0 | |
280 | + | let aN = wavesBalance(this) | |
281 | + | if ((aN > aM)) | |
282 | + | then aN | |
283 | + | else { | |
284 | + | let aO = (aM - aN) | |
285 | + | if ((aO > f)) | |
286 | + | then throw("dApp is temporary disabled") | |
287 | + | else aM | |
288 | + | } | |
289 | + | } | |
290 | + | ||
291 | + | ||
292 | + | @Callable(aP) | |
293 | + | func dAppUp (aQ) = if ((aP.caller != d)) | |
294 | + | then throw("Only Server can manage dAppUp attribute") | |
295 | + | else if ((aI() == aQ)) | |
296 | + | then throw("dAppUp must be different with actual value") | |
297 | + | else WriteSet([DataEntry(z, aQ)]) | |
298 | + | ||
299 | + | ||
300 | + | ||
301 | + | @Callable(aP) | |
302 | + | func bet (S) = { | |
303 | + | let aR = E() | |
304 | + | let P = toBase58String(aP.transactionId) | |
305 | + | let aS = extract(aP.payment) | |
306 | + | let aT = isDefined(aS.assetId) | |
307 | + | let L = Q(aS.amount, S) | |
308 | + | let aU = isDefined(getString(this, P)) | |
309 | + | if (!(aI())) | |
310 | + | then throw("DApp is under maintenance") | |
311 | + | else if (aT) | |
312 | + | then throw("Bet amount must be in Waves") | |
313 | + | else if (aU) | |
314 | + | then throw("Passed txId had been used before. Game aborted.") | |
315 | + | else { | |
316 | + | let aj = toBase58String(aP.callerPublicKey) | |
317 | + | let aV = ah(B, S, aj, height, L, "") | |
318 | + | ScriptResult(WriteSet([DataEntry(x, K(L)), DataEntry(y, aR), DataEntry(A, aK()), DataEntry(P, aV)]), TransferSet([ScriptTransfer(d, b, unit)])) | |
319 | + | } | |
320 | + | } | |
321 | + | ||
322 | + | ||
323 | + | ||
324 | + | @Callable(aP) | |
325 | + | func withdraw (P,Z) = { | |
326 | + | let aW = aw(P) | |
327 | + | let ai = aW[r] | |
328 | + | let S = aW[s] | |
329 | + | let ak = parseIntValue(aW[u]) | |
330 | + | let L = parseIntValue(aW[v]) | |
331 | + | let aj = aW[t] | |
332 | + | let aA = addressFromPublicKey(fromBase58String(aj)) | |
333 | + | let aC = ((height - ak) > e) | |
334 | + | let aD = O(P, L) | |
335 | + | if ((ai != B)) | |
336 | + | then throw("Invalid game state for passed gameId") | |
337 | + | else if (aC) | |
338 | + | then { | |
339 | + | let ad = take(S, 1) | |
340 | + | let aB = ah(C, S, aj, ak, L, ad) | |
341 | + | az(P, aA, L, aB, aC, aD) | |
342 | + | } | |
343 | + | else { | |
344 | + | let ad = W(Y(P, Z)) | |
345 | + | if ((aP.caller != d)) | |
346 | + | then throw("Regular withdraw can be done by server only") | |
347 | + | else if (ac(S, ad)) | |
348 | + | then { | |
349 | + | let aB = ah(C, S, aj, ak, L, ad) | |
350 | + | az(P, aA, L, aB, aC, aD) | |
351 | + | } | |
352 | + | else { | |
353 | + | let aB = ah(D, S, aj, ak, L, ad) | |
354 | + | WriteSet([DataEntry(P, aB), aD]) | |
355 | + | } | |
356 | + | } | |
357 | + | } | |
358 | + | ||
359 | + | ||
360 | + | @Verifier(aX) | |
361 | + | func aY () = if (sigVerify(aX.bodyBytes, aX.proofs[0], aX.senderPublicKey)) | |
362 | + | then { | |
363 | + | let G = aX | |
364 | + | if ($isInstanceOf(G, "TransferTransaction")) | |
365 | + | then { | |
366 | + | let aZ = G | |
367 | + | ((wavesBalance(this) - aZ.amount) >= I()) | |
368 | + | } | |
369 | + | else if ($isInstanceOf(G, "SetScriptTransaction")) | |
370 | + | then { | |
371 | + | let ba = G | |
372 | + | if ((aI() == false)) | |
373 | + | then (I() == 0) | |
374 | + | else false | |
375 | + | } | |
376 | + | else false | |
377 | + | } | |
378 | + | else false | |
379 | + |
github/deemru/w8io/169f3d6 30.85 ms ◑