tx · 4UF2aAB8sUf8ueTmvxf7LGSBmdhBWR9G6W2JyaDU684m

3N6yFJ5Z8NUUQvfGGMLp5efmevRRtTgQuun:  -0.01400000 Waves

2019.09.17 22:53 [680688] smart account 3N6yFJ5Z8NUUQvfGGMLp5efmevRRtTgQuun > SELF 0.00000000 Waves

{ "type": 13, "id": "4UF2aAB8sUf8ueTmvxf7LGSBmdhBWR9G6W2JyaDU684m", "fee": 1400000, "feeAssetId": null, "timestamp": 1568750000075, "version": 1, "sender": "3N6yFJ5Z8NUUQvfGGMLp5efmevRRtTgQuun", "senderPublicKey": "7uRSDXQUkUS7719CDA4wXghhzsWrF22gb18FGDPZyA6P", "proofs": [ "5mFggKXgGUHG5wvWPyHaserQcqxN6583tYww7LvmE1Wf8icgWcw7EYDV3rLUEq4od1zLBCiK1vJvzCVb12SYtz8c" ], "script": "base64:AAIDAAAAAAAAAAAAAAASAAAAAAlXaW5TZXJ2ZXIJAQAAABxAZXh0clVzZXIoYWRkcmVzc0Zyb21TdHJpbmcpAAAAAQIAAAAjM045WG55UHBXeFlvaEtIN3o1ZEV1cThycG5vYnB5elByekUAAAAAB1dBVkVMRVQJAABoAAAAAgkAAGgAAAACAAAAAAAAAABkAAAAAAAAAAPoAAAAAAAAAAPoAAAAAApDT01NSVNTSU9OCQAAaQAAAAIJAABoAAAAAgAAAAAAAAAABQUAAAAHV0FWRUxFVAAAAAAAAAAD6AAAAAAOVGlja2V0c1BlcldhdmUAAAAAAAAAAGQAAAAAC0NVUlJFTlRHQU1FAgAAAA0kQ1VSUkVOVF9HQU1FAAAAAA9HQU1FU0NPVU5URVJLRVkCAAAACSRHQU1FX05VTQAAAAAKTEFTVFRJQ0tFVAIAAAAMJExBU1RfVElDS0VUAAAAAARCQU5LAgAAAAokR0FNRV9CQU5LAQAAAA5nZXRQbGF5ZXJzTGlzdAAAAAIAAAAGZ2FtZUlkAAAADWN1cnJlbnRQbGF5ZXIEAAAAEHBsYXllcnNQcmVzZW50ZWQJAQAAAA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ld0JhbmtCYWxhbmNlBQAAAANuaWwEAAAAC3RvV2luU2VydmVyCQAETAAAAAIJAQAAAA5TY3JpcHRUcmFuc2ZlcgAAAAMFAAAACVdpblNlcnZlcgUAAAAKcGF5bWVudEFtdAUAAAAEdW5pdAUAAAADbmlsCQEAAAAMU2NyaXB0UmVzdWx0AAAAAgkBAAAACFdyaXRlU2V0AAAAAQUAAAAHYmV0RGF0YQkBAAAAC1RyYW5zZmVyU2V0AAAAAQUAAAALdG9XaW5TZXJ2ZXIAAAAANxOLlw==", "chainId": 84, "height": 680688, "spentComplexity": 0 } View: original | compacted Prev: 71bAeZXJKHVw8VATmnqsfXWPbpJ8FsWr6j6swtPXvfHP Next: none Diff:
OldNewDifferences
145145
146146
147147 @Callable(R)
148+func setAvatar (S) = {
149+ let T = toBase58String(R.callerPublicKey)
150+ let U = addressFromPublicKey(fromBase58String(T))
151+ let p = toString(U)
152+ let V = [DataEntry((p + "_avatar"), S)]
153+ WriteSet(V)
154+ }
155+
156+
157+
158+@Callable(R)
148159 func resetGameData (j) = {
149- let S = [DataEntry(e, ""), DataEntry(g, 0)]
150- WriteSet(S)
160+ let W = [DataEntry(e, ""), DataEntry(g, 0)]
161+ WriteSet(W)
151162 }
152163
153164
157168 let H = toBase58String(R.transactionId)
158169 let j = L(H)
159170 let I = G(j, H)
160- let T = extract(R.payment)
161- let u = (T.amount - c)
162- let U = isDefined(T.assetId)
163- let V = isDefined(T.assetId)
164- let W = toBase58String(R.callerPublicKey)
165- let X = addressFromPublicKey(fromBase58String(W))
166- if (U)
171+ let X = extract(R.payment)
172+ let u = (X.amount - c)
173+ let Y = isDefined(X.assetId)
174+ let Z = isDefined(X.assetId)
175+ let T = toBase58String(R.callerPublicKey)
176+ let U = addressFromPublicKey(fromBase58String(T))
177+ if (Y)
167178 then throw("Bet amount must be in Waves")
168- else if (V)
179+ else if (Z)
169180 then throw("Transaction's fee must be in Waves")
170181 else {
171- let p = toString(X)
172- let Y = N(j, u)
173- let Z = P(j, p, u)
174- let aa = [DataEntry(e, j), DataEntry(f, I), DataEntry(g, F(u)), DataEntry((((j + "_") + p) + "_tickets"), t(j, p, u)), DataEntry((((j + "_") + p) + "_betsCount"), (o(j, p) + 1)), DataEntry((((j + "_") + p) + "_totalBetsAmt"), Z), DataEntry((j + "_players"), i(j, p)), DataEntry(((j + "_") + h), Y)]
175- let ab = [ScriptTransfer(a, u, unit)]
176- ScriptResult(WriteSet(aa), TransferSet(ab))
182+ let p = toString(U)
183+ let aa = N(j, u)
184+ let ab = P(j, p, u)
185+ let ac = [DataEntry(e, j), DataEntry(f, I), DataEntry(g, F(u)), DataEntry((((j + "_") + p) + "_tickets"), t(j, p, u)), DataEntry((((j + "_") + p) + "_betsCount"), (o(j, p) + 1)), DataEntry((((j + "_") + p) + "_totalBetsAmt"), ab), DataEntry((j + "_players"), i(j, p)), DataEntry(((j + "_") + h), aa)]
186+ let ad = [ScriptTransfer(a, u, unit)]
187+ ScriptResult(WriteSet(ac), TransferSet(ad))
177188 }
178189 }
179190
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 3 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let a = addressFromStringValue("3N9XnyPpWxYohKH7z5dEuq8rpnobpyzPrzE")
55
66 let b = ((100 * 1000) * 1000)
77
88 let c = ((5 * b) / 1000)
99
1010 let d = 100
1111
1212 let e = "$CURRENT_GAME"
1313
1414 let f = "$GAME_NUM"
1515
1616 let g = "$LAST_TICKET"
1717
1818 let h = "$GAME_BANK"
1919
2020 func i (j,k) = {
2121 let l = isDefined(getString(this, (j + "_players")))
2222 if (!(l))
2323 then k
2424 else if (isDefined(getString(this, (((j + "_") + k) + "_tickets"))))
2525 then getStringValue(this, (j + "_players"))
2626 else ((getStringValue(this, (j + "_players")) + "_") + k)
2727 }
2828
2929
3030 func m () = {
3131 let n = isDefined(getInteger(this, g))
3232 if (!(n))
3333 then 0
3434 else getIntegerValue(this, g)
3535 }
3636
3737
3838 func o (j,p) = {
3939 let q = {
4040 let r = getInteger(this, (((j + "_") + p) + "_betsCount"))
4141 if ($isInstanceOf(r, "Int"))
4242 then {
4343 let s = r
4444 s
4545 }
4646 else 0
4747 }
4848 q
4949 }
5050
5151
5252 func t (j,p,u) = {
5353 let v = m()
5454 let w = (u / b)
5555 let x = (v + 1)
5656 let y = ((x + (w * d)) - 1)
5757 let z = toString(x)
5858 let A = toString(y)
5959 let B = isDefined(getString(this, (((j + "_") + p) + "_tickets")))
6060 if (B)
6161 then {
6262 let C = getStringValue(this, (((j + "_") + p) + "_tickets"))
6363 let D = o(j, p)
6464 let E = split(C, "_")
6565 if ((D == 1))
6666 then (((((((E[0] + "_") + E[1]) + "_") + z) + "_") + A) + "_0_0_0_0")
6767 else if ((D == 2))
6868 then (((((((((((E[0] + "_") + E[1]) + "_") + E[2]) + "_") + E[3]) + "_") + z) + "_") + A) + "_0_0")
6969 else if ((D == 3))
7070 then ((((((((((((((E[0] + "_") + E[1]) + "_") + E[2]) + "_") + E[3]) + "_") + E[4]) + "_") + E[5]) + "_") + z) + "_") + A)
7171 else throw("Error, bid limit exceeded")
7272 }
7373 else (((z + "_") + A) + "_0_0_0_0_0_0")
7474 }
7575
7676
7777 func F (u) = {
7878 let v = m()
7979 let w = (u / b)
8080 (v + (w * d))
8181 }
8282
8383
8484 func G (j,H) = {
8585 let I = {
8686 let r = getInteger(this, f)
8787 if ($isInstanceOf(r, "Int"))
8888 then {
8989 let s = r
9090 s
9191 }
9292 else 0
9393 }
9494 if ((j == H))
9595 then (I + 1)
9696 else I
9797 }
9898
9999
100100 func J (H) = {
101101 let K = isDefined(getString(this, e))
102102 if (!(K))
103103 then H
104104 else if ((getStringValue(this, e) == ""))
105105 then H
106106 else getStringValue(this, e)
107107 }
108108
109109
110110 func L (H) = {
111111 let j = J(H)
112112 let M = isDefined(getString(this, (j + "_result")))
113113 if (M)
114114 then H
115115 else j
116116 }
117117
118118
119119 func N (j,u) = {
120120 let O = {
121121 let r = getInteger(this, ((j + "_") + h))
122122 if ($isInstanceOf(r, "Int"))
123123 then {
124124 let s = r
125125 s
126126 }
127127 else 0
128128 }
129129 (O + u)
130130 }
131131
132132
133133 func P (j,p,u) = {
134134 let Q = {
135135 let r = getInteger(this, (((j + "_") + p) + "_totalBetsAmt"))
136136 if ($isInstanceOf(r, "Int"))
137137 then {
138138 let s = r
139139 s
140140 }
141141 else 0
142142 }
143143 (Q + u)
144144 }
145145
146146
147147 @Callable(R)
148+func setAvatar (S) = {
149+ let T = toBase58String(R.callerPublicKey)
150+ let U = addressFromPublicKey(fromBase58String(T))
151+ let p = toString(U)
152+ let V = [DataEntry((p + "_avatar"), S)]
153+ WriteSet(V)
154+ }
155+
156+
157+
158+@Callable(R)
148159 func resetGameData (j) = {
149- let S = [DataEntry(e, ""), DataEntry(g, 0)]
150- WriteSet(S)
160+ let W = [DataEntry(e, ""), DataEntry(g, 0)]
161+ WriteSet(W)
151162 }
152163
153164
154165
155166 @Callable(R)
156167 func bet () = {
157168 let H = toBase58String(R.transactionId)
158169 let j = L(H)
159170 let I = G(j, H)
160- let T = extract(R.payment)
161- let u = (T.amount - c)
162- let U = isDefined(T.assetId)
163- let V = isDefined(T.assetId)
164- let W = toBase58String(R.callerPublicKey)
165- let X = addressFromPublicKey(fromBase58String(W))
166- if (U)
171+ let X = extract(R.payment)
172+ let u = (X.amount - c)
173+ let Y = isDefined(X.assetId)
174+ let Z = isDefined(X.assetId)
175+ let T = toBase58String(R.callerPublicKey)
176+ let U = addressFromPublicKey(fromBase58String(T))
177+ if (Y)
167178 then throw("Bet amount must be in Waves")
168- else if (V)
179+ else if (Z)
169180 then throw("Transaction's fee must be in Waves")
170181 else {
171- let p = toString(X)
172- let Y = N(j, u)
173- let Z = P(j, p, u)
174- let aa = [DataEntry(e, j), DataEntry(f, I), DataEntry(g, F(u)), DataEntry((((j + "_") + p) + "_tickets"), t(j, p, u)), DataEntry((((j + "_") + p) + "_betsCount"), (o(j, p) + 1)), DataEntry((((j + "_") + p) + "_totalBetsAmt"), Z), DataEntry((j + "_players"), i(j, p)), DataEntry(((j + "_") + h), Y)]
175- let ab = [ScriptTransfer(a, u, unit)]
176- ScriptResult(WriteSet(aa), TransferSet(ab))
182+ let p = toString(U)
183+ let aa = N(j, u)
184+ let ab = P(j, p, u)
185+ let ac = [DataEntry(e, j), DataEntry(f, I), DataEntry(g, F(u)), DataEntry((((j + "_") + p) + "_tickets"), t(j, p, u)), DataEntry((((j + "_") + p) + "_betsCount"), (o(j, p) + 1)), DataEntry((((j + "_") + p) + "_totalBetsAmt"), ab), DataEntry((j + "_players"), i(j, p)), DataEntry(((j + "_") + h), aa)]
186+ let ad = [ScriptTransfer(a, u, unit)]
187+ ScriptResult(WriteSet(ac), TransferSet(ad))
177188 }
178189 }
179190
180191

github/deemru/w8io/026f985 
48.24 ms