tx · 3vg2DMZDQ2qio3TDfMBZzpRrjubkMLsLvNUFZaqqjPap

3N7Wiiso7vo69pqWfLtpzT3tbzMUGahqpgo:  -0.01400000 Waves

2019.08.19 16:27 [638088] smart account 3N7Wiiso7vo69pqWfLtpzT3tbzMUGahqpgo > SELF 0.00000000 Waves

{ "type": 13, "id": "3vg2DMZDQ2qio3TDfMBZzpRrjubkMLsLvNUFZaqqjPap", "fee": 1400000, "feeAssetId": null, "timestamp": 1566221264138, "version": 1, "sender": "3N7Wiiso7vo69pqWfLtpzT3tbzMUGahqpgo", "senderPublicKey": "5GQSFwNMkJFTT3FeLT3KENqoSr42yiJP3Av5qAYq1F7f", "proofs": [ "3TDXDnDLkUWfcbJ8BQ6kruyiRaJ3ERxVLThLKAxH6oB8xTSMvuprHbDMHPPe4XJTxiR8ur6gQ95NximYVeFbuvZE" ], "script": "base64:AAIDAAAAAAAAAAAAAAAQAAAAAAdSVU5OSU5HAgAAAAdSVU5OSU5HAAAAAAZDTE9TRUQCAAAABkNMT1NFRAAAAAAIQ0FOQ0VMRUQCAAAACENBTkNFTEVEAAAAAAlEQVBQT1dORVICAAAAIzNON1dpaXNvN3ZvNjlwcVdmTHRwelQzdGJ6TVVHYWhxcGdvAAAAAAxPUkFDTEVXQUxMRVQCAAAAIzNOQWNvZVdkVVRXbjhjc1hKUEc0N3YxRmp0amNmcXhiNXR1AAAAAA1XTFRCVVJOV0FMTEVUAgAAACMzTXBDYkREamtTcmZTMVhrUHBtNzFpWmo1RFExUnBCUlJodAAAAAAOV0FWRVNLSVRXQUxMRVQCAAAAIzNNcVBwYldQUnNaRm9UOVg3NHFXb2NVNEJweXBHRVBoaUNuAAAAAAVXQVZFUwIAAAAFV0FWRVMAAAAABE5PTkUCAAAABE5PTkUAAAAAA0ZFRQAAAAAAAA27oAAAAAADV0xUAQAAACBdzVgyIDG1TTrr2IC+hZgKEiTPyt49R9i8wN0ZNQ6rqgEAAAALZ2V0TnVtQnlLZXkAAAABAAAAA2tleQQ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CQEAAAAJRGF0YUVudHJ5AAAAAgkAASwAAAACCQABLAAAAAICAAAACGNvbnRlc3RfCQABpAAAAAEFAAAAEWNvbnRlc3RDdXJyTnVtYmVyAgAAAA1fY3VycmVuY3lyYXRlBQAAAAxjdXJyZW5jeVJhdGUJAARMAAAAAgkBAAAACURhdGFFbnRyeQAAAAIJAAEsAAAAAgkAASwAAAACAgAAAAhjb250ZXN0XwkAAaQAAAABBQAAABFjb250ZXN0Q3Vyck51bWJlcgIAAAAHX2hlaWdodAUAAAAGaGVpZ2h0BQAAAANuaWwAAAABAAAAAnR4AQAAAAZ2ZXJpZnkAAAAABAAAAAckbWF0Y2gwBQAAAAJ0eAMDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAAFFNldFNjcmlwdFRyYW5zYWN0aW9uBgkAAAEAAAACBQAAAAckbWF0Y2gwAgAAAA9EYXRhVHJhbnNhY3Rpb24JAAH0AAAAAwgFAAAAAnR4AAAACWJvZHlCeXRlcwkAAZEAAAACCAUAAAACdHgAAAAGcHJvb2ZzAAAAAAAAAAAACAUAAAACdHgAAAAPc2VuZGVyUHVibGljS2V5AwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAABdJbnZva2VTY3JpcHRUcmFuc2FjdGlvbgYGPTwQuw==", "chainId": 84, "height": 638088, "spentComplexity": 0 } View: original | compacted Prev: FiuE8vuQG88rJKD28mPPhkbjtk2aZ2a2yPLz36wNemKu Next: GWW7kVuNsCmzmXZQ5x4mGJg99TcomAc8z2Rh8M8veVr4 Diff:
OldNewDifferences
55
66 let b = "CLOSED"
77
8-let c = "3N7Wiiso7vo69pqWfLtpzT3tbzMUGahqpgo"
8+let c = "CANCELED"
99
10-let d = "3NAcoeWdUTWn8csXJPG47v1Fjtjcfqxb5tu"
10+let d = "3N7Wiiso7vo69pqWfLtpzT3tbzMUGahqpgo"
1111
12-let e = "3MpCbDDjkSrfS1XkPpm71iZj5DQ1RpBRRht"
12+let e = "3NAcoeWdUTWn8csXJPG47v1Fjtjcfqxb5tu"
1313
14-let f = "3MqPpbWPRsZFoT9X74qWocU4BpypGEPhiCn"
14+let f = "3MpCbDDjkSrfS1XkPpm71iZj5DQ1RpBRRht"
1515
16-let g = "WAVES"
16+let g = "3MqPpbWPRsZFoT9X74qWocU4BpypGEPhiCn"
1717
18-let h = "NONE"
18+let h = "WAVES"
1919
20-let i = 900000
20+let i = "NONE"
2121
22-let j = base58'7KAXNTswj6947a6cVpGhVrh1utWpLcjwf8AFpWCtuMT7'
22+let j = 900000
2323
24-func k (l) = {
25- let m = {
26- let n = getInteger(this, l)
27- if ($isInstanceOf(n, "Int"))
24+let k = base58'7KAXNTswj6947a6cVpGhVrh1utWpLcjwf8AFpWCtuMT7'
25+
26+func l (m) = {
27+ let n = {
28+ let o = getInteger(this, m)
29+ if ($isInstanceOf(o, "Int"))
2830 then {
29- let o = n
30- o
31+ let p = o
32+ p
3133 }
3234 else 0
3335 }
34- m
36+ n
3537 }
3638
3739
38-func p (l) = {
39- let q = {
40- let n = getString(this, l)
41- if ($isInstanceOf(n, "String"))
40+func q (m) = {
41+ let r = {
42+ let o = getString(this, m)
43+ if ($isInstanceOf(o, "String"))
4244 then {
43- let o = n
44- o
45+ let p = o
46+ p
4547 }
46- else h
48+ else i
4749 }
48- q
50+ r
4951 }
5052
5153
52-func r () = {
53- let s = k("contest_currentnumber")
54- p((("contest_" + toString(s)) + "_status"))
54+func s () = {
55+ let t = l("contest_currentnumber")
56+ q((("contest_" + toString(t)) + "_status"))
5557 }
5658
5759
58-func t (u) = {
59- let s = k("contest_currentnumber")
60- p((((("bet_" + toString(s)) + "_") + toString(u)) + "_owner"))
60+func u (v) = {
61+ let t = l("contest_currentnumber")
62+ q((((("bet_" + toString(t)) + "_") + toString(v)) + "_owner"))
6163 }
6264
6365
64-func v () = {
65- let w = extract(addressFromString(d))
66- let x = {
67- let n = getInteger(w, "waves_usd_2")
68- if ($isInstanceOf(n, "Int"))
66+func w () = {
67+ let x = extract(addressFromString(e))
68+ let y = {
69+ let o = getInteger(x, "waves_usd_2")
70+ if ($isInstanceOf(o, "Int"))
6971 then {
70- let o = n
71- o
72+ let p = o
73+ p
7274 }
7375 else 0
7476 }
75- x
77+ y
7678 }
7779
7880
79-@Callable(y)
80-func setContestStatus (z,A) = {
81- let B = toBase58String(y.caller.bytes)
82- if ((B != c))
81+@Callable(z)
82+func setContestStatus (A,B) = {
83+ let C = toBase58String(z.caller.bytes)
84+ if ((C != d))
8385 then throw("Only dAPP Owner can set Contest Status.")
84- else if (if ((A != a))
85- then (A != b)
86+ else if (if ((B != c))
87+ then (B != b)
8688 else false)
87- then throw(("Invalid status: " + A))
88- else WriteSet([DataEntry((("contest_" + toString(z)) + "_status"), A)])
89+ then throw(("Invalid status: " + B))
90+ else WriteSet([DataEntry((("contest_" + toString(A)) + "_status"), B)])
8991 }
9092
9193
9294
93-@Callable(y)
95+@Callable(z)
9496 func setContestConfiguration () = {
95- let B = toBase58String(y.caller.bytes)
96- let s = k("contest_currentnumber")
97- let C = p((("contest_" + toString(s)) + "_status"))
98- let D = (s + 1)
99- let E = (((wavesBalance(this) * 99) / 100) / 25)
100- if ((B != c))
101- then throw(((("Only dAPP Owner can Configure Contest. Caller account: " + B) + " dapp owner: ") + c))
102- else if ((C == a))
103- then throw(("You cannot configure a new Contest while old Contest status is: " + C))
97+ let C = toBase58String(z.caller.bytes)
98+ let t = l("contest_currentnumber")
99+ let D = q((("contest_" + toString(t)) + "_status"))
100+ let E = (t + 1)
101+ let F = (wavesBalance(this) / 50)
102+ if ((C != d))
103+ then throw(((("Only dAPP Owner can Configure Contest. Caller account: " + C) + " dapp owner: ") + d))
104+ else if ((D == a))
105+ then throw(("You cannot configure a new Contest while old Contest status is: " + D))
104106 else {
105- let F = (height + (7 * 1440))
106- WriteSet([DataEntry("contest_currentnumber", D), DataEntry((("contest_" + toString(D)) + "_finishheight"), F), DataEntry((("contest_" + toString(D)) + "_status"), a), DataEntry((("contest_" + toString(D)) + "_betcounter"), 0), DataEntry((("contest_" + toString(D)) + "_betcost"), 0)])
107+ let G = (height + (7 * 1440))
108+ WriteSet([DataEntry("contest_currentnumber", E), DataEntry((("contest_" + toString(E)) + "_finishheight"), G), DataEntry((("contest_" + toString(E)) + "_status"), a), DataEntry((("contest_" + toString(E)) + "_betcounter"), 0), DataEntry((("contest_" + toString(E)) + "_betcost"), 0)])
107109 }
108110 }
109111
110112
111113
112-@Callable(y)
113-func bet (G) = {
114- let B = toBase58String(y.caller.bytes)
115- let H = extract(y.payment)
116- let s = k("contest_currentnumber")
117- let I = k((("contest_" + toString(s)) + "_startheight"))
118- let F = k((("contest_" + toString(s)) + "_finishheight"))
119- let J = k((("contest_" + toString(s)) + "_betcounter"))
120- let C = p((("contest_" + toString(s)) + "_status"))
121- let K = (J + 1)
122- let A = p((("contest_" + toString(s)) + "_status"))
123- let L = k(((("bet_" + toString(s)) + "_") + toString(G)))
124- let M = t(L)
125- if ((height > (F - (2 * 1440))))
114+@Callable(z)
115+func bet (H) = {
116+ let C = toBase58String(z.caller.bytes)
117+ let I = extract(z.payment)
118+ let t = l("contest_currentnumber")
119+ let J = l((("contest_" + toString(t)) + "_startheight"))
120+ let G = l((("contest_" + toString(t)) + "_finishheight"))
121+ let K = l((("contest_" + toString(t)) + "_betcounter"))
122+ let D = q((("contest_" + toString(t)) + "_status"))
123+ let L = l((("contest_" + toString(t)) + "_betcost"))
124+ let M = (K + 1)
125+ let B = q((("contest_" + toString(t)) + "_status"))
126+ let N = l(((("bet_" + toString(t)) + "_") + toString(H)))
127+ let O = u(N)
128+ if ((height > (G - (2 * 1440))))
126129 then throw("You cannot bet anymore at this height.")
127- else if ((C != a))
128- then throw(("Invalid status: you cannot bet now, contest status is: " + C))
129- else if (if ((H.assetId != j))
130+ else if ((D != a))
131+ then throw(("Invalid status: you cannot bet now, contest status is: " + D))
132+ else if (if ((I.assetId != k))
130133 then true
131- else (H.amount != 500000))
132- then throw(("You must pay 5 WLT to bet. You paid: " + toString(H.amount)))
133- else if (if ((M != h))
134- then (M != B)
134+ else (I.amount != 500000))
135+ then throw(("You must pay 5 WLT to bet. You paid: " + toString(I.amount)))
136+ else if (if ((O != i))
137+ then (O != C)
135138 else false)
136- then throw(((((("Another user: " + M) + " did bet already on rate: ") + toString(G)) + " betID:") + toString(L)))
137- else WriteSet([DataEntry((((("bet_" + toString(s)) + "_") + toString(K)) + "_owner"), B), DataEntry(((("bet_" + toString(s)) + "_") + toString(G)), K), DataEntry((("contest_" + toString(s)) + "_betcounter"), K)])
139+ then throw(((((("Another user: " + O) + " did bet already on rate: ") + toString(H)) + " betID:") + toString(N)))
140+ else WriteSet([DataEntry((((("bet_" + toString(t)) + "_") + toString(M)) + "_owner"), C), DataEntry(((("bet_" + toString(t)) + "_") + toString(H)), M), DataEntry((("contest_" + toString(t)) + "_betcounter"), M)])
138141 }
139142
140143
141144
142-@Callable(y)
145+@Callable(z)
143146 func closecontest () = {
144- let N = v()
145- let s = k("contest_currentnumber")
146- let O = k(((("bet_" + toString(s)) + "_") + toString(N)))
147- let P = t(O)
148- let F = k((("contest_" + toString(s)) + "_finishheight"))
149- let B = toBase58String(y.caller.bytes)
150- let Q = wavesBalance(this)
151- let C = p((("contest_" + toString(s)) + "_status"))
152- let R = WriteSet([DataEntry((("contest_" + toString(s)) + "_status"), b), DataEntry((("contest_" + toString(s)) + "_winner"), P), DataEntry((("contest_" + toString(s)) + "_currencyrate"), N), DataEntry((("contest_" + toString(s)) + "_height"), height)])
153- if (if ((F > height))
154- then (B != c)
147+ let P = w()
148+ let t = l("contest_currentnumber")
149+ let Q = l(((("bet_" + toString(t)) + "_") + toString(P)))
150+ let R = u(Q)
151+ let G = l((("contest_" + toString(t)) + "_finishheight"))
152+ let C = toBase58String(z.caller.bytes)
153+ let S = wavesBalance(this)
154+ let D = q((("contest_" + toString(t)) + "_status"))
155+ let T = WriteSet([DataEntry((("contest_" + toString(t)) + "_status"), b), DataEntry((("contest_" + toString(t)) + "_winner"), R), DataEntry((("contest_" + toString(t)) + "_currencyrate"), P), DataEntry((("contest_" + toString(t)) + "_height"), height)])
156+ if (if ((G > height))
157+ then (C != d)
155158 else false)
156- then throw(((("account: " + B) + ": Cannot close the contest before height:") + toString(F)))
157- else if ((C != a))
158- then throw(("Cannot close a contest in status: " + C))
159- else if ((P != h))
159+ then throw(((("account: " + C) + ": Cannot close the contest before height:") + toString(G)))
160+ else if ((D != a))
161+ then throw(("Cannot close a contest in status: " + D))
162+ else if ((R != i))
160163 then {
161- let S = ((assetBalance(this, j) * 5) / 100)
162- let T = ((assetBalance(this, j) * 90) / 100)
163- let U = TransferSet([ScriptTransfer(extract(addressFromString(P)), (((wavesBalance(this) * 99) / 100) - i), unit), ScriptTransfer(extract(addressFromString(d)), S, j), ScriptTransfer(extract(addressFromString(f)), S, j), ScriptTransfer(extract(addressFromString(e)), T, j)])
164- ScriptResult(WriteSet([DataEntry((("contest_" + toString(s)) + "_status"), b), DataEntry((("contest_" + toString(s)) + "_winner"), P), DataEntry((("contest_" + toString(s)) + "_currencyrate"), N), DataEntry((("contest_" + toString(s)) + "_height"), height)]), U)
164+ let U = ((assetBalance(this, k) * 5) / 100)
165+ let V = ((assetBalance(this, k) * 90) / 100)
166+ let W = TransferSet([ScriptTransfer(extract(addressFromString(R)), (((wavesBalance(this) * 99) / 100) - j), unit), ScriptTransfer(extract(addressFromString(e)), U, k), ScriptTransfer(extract(addressFromString(g)), U, k), ScriptTransfer(extract(addressFromString(f)), V, k)])
167+ ScriptResult(WriteSet([DataEntry((("contest_" + toString(t)) + "_status"), b), DataEntry((("contest_" + toString(t)) + "_winner"), R), DataEntry((("contest_" + toString(t)) + "_currencyrate"), P), DataEntry((("contest_" + toString(t)) + "_height"), height)]), W)
165168 }
166- else WriteSet([DataEntry((("contest_" + toString(s)) + "_status"), b), DataEntry((("contest_" + toString(s)) + "_winner"), P), DataEntry((("contest_" + toString(s)) + "_currencyrate"), N), DataEntry((("contest_" + toString(s)) + "_height"), height)])
169+ else WriteSet([DataEntry((("contest_" + toString(t)) + "_status"), b), DataEntry((("contest_" + toString(t)) + "_winner"), R), DataEntry((("contest_" + toString(t)) + "_currencyrate"), P), DataEntry((("contest_" + toString(t)) + "_height"), height)])
167170 }
168171
169172
170-@Verifier(V)
171-func W () = {
172- let n = V
173- if (if ($isInstanceOf(n, "SetScriptTransaction"))
173+@Verifier(X)
174+func Y () = {
175+ let o = X
176+ if (if ($isInstanceOf(o, "SetScriptTransaction"))
174177 then true
175- else $isInstanceOf(n, "DataTransaction"))
176- then sigVerify(V.bodyBytes, V.proofs[0], V.senderPublicKey)
177- else if ($isInstanceOf(n, "InvokeScriptTransaction"))
178+ else $isInstanceOf(o, "DataTransaction"))
179+ then sigVerify(X.bodyBytes, X.proofs[0], X.senderPublicKey)
180+ else if ($isInstanceOf(o, "InvokeScriptTransaction"))
178181 then true
179182 else true
180183 }
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 3 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let a = "RUNNING"
55
66 let b = "CLOSED"
77
8-let c = "3N7Wiiso7vo69pqWfLtpzT3tbzMUGahqpgo"
8+let c = "CANCELED"
99
10-let d = "3NAcoeWdUTWn8csXJPG47v1Fjtjcfqxb5tu"
10+let d = "3N7Wiiso7vo69pqWfLtpzT3tbzMUGahqpgo"
1111
12-let e = "3MpCbDDjkSrfS1XkPpm71iZj5DQ1RpBRRht"
12+let e = "3NAcoeWdUTWn8csXJPG47v1Fjtjcfqxb5tu"
1313
14-let f = "3MqPpbWPRsZFoT9X74qWocU4BpypGEPhiCn"
14+let f = "3MpCbDDjkSrfS1XkPpm71iZj5DQ1RpBRRht"
1515
16-let g = "WAVES"
16+let g = "3MqPpbWPRsZFoT9X74qWocU4BpypGEPhiCn"
1717
18-let h = "NONE"
18+let h = "WAVES"
1919
20-let i = 900000
20+let i = "NONE"
2121
22-let j = base58'7KAXNTswj6947a6cVpGhVrh1utWpLcjwf8AFpWCtuMT7'
22+let j = 900000
2323
24-func k (l) = {
25- let m = {
26- let n = getInteger(this, l)
27- if ($isInstanceOf(n, "Int"))
24+let k = base58'7KAXNTswj6947a6cVpGhVrh1utWpLcjwf8AFpWCtuMT7'
25+
26+func l (m) = {
27+ let n = {
28+ let o = getInteger(this, m)
29+ if ($isInstanceOf(o, "Int"))
2830 then {
29- let o = n
30- o
31+ let p = o
32+ p
3133 }
3234 else 0
3335 }
34- m
36+ n
3537 }
3638
3739
38-func p (l) = {
39- let q = {
40- let n = getString(this, l)
41- if ($isInstanceOf(n, "String"))
40+func q (m) = {
41+ let r = {
42+ let o = getString(this, m)
43+ if ($isInstanceOf(o, "String"))
4244 then {
43- let o = n
44- o
45+ let p = o
46+ p
4547 }
46- else h
48+ else i
4749 }
48- q
50+ r
4951 }
5052
5153
52-func r () = {
53- let s = k("contest_currentnumber")
54- p((("contest_" + toString(s)) + "_status"))
54+func s () = {
55+ let t = l("contest_currentnumber")
56+ q((("contest_" + toString(t)) + "_status"))
5557 }
5658
5759
58-func t (u) = {
59- let s = k("contest_currentnumber")
60- p((((("bet_" + toString(s)) + "_") + toString(u)) + "_owner"))
60+func u (v) = {
61+ let t = l("contest_currentnumber")
62+ q((((("bet_" + toString(t)) + "_") + toString(v)) + "_owner"))
6163 }
6264
6365
64-func v () = {
65- let w = extract(addressFromString(d))
66- let x = {
67- let n = getInteger(w, "waves_usd_2")
68- if ($isInstanceOf(n, "Int"))
66+func w () = {
67+ let x = extract(addressFromString(e))
68+ let y = {
69+ let o = getInteger(x, "waves_usd_2")
70+ if ($isInstanceOf(o, "Int"))
6971 then {
70- let o = n
71- o
72+ let p = o
73+ p
7274 }
7375 else 0
7476 }
75- x
77+ y
7678 }
7779
7880
79-@Callable(y)
80-func setContestStatus (z,A) = {
81- let B = toBase58String(y.caller.bytes)
82- if ((B != c))
81+@Callable(z)
82+func setContestStatus (A,B) = {
83+ let C = toBase58String(z.caller.bytes)
84+ if ((C != d))
8385 then throw("Only dAPP Owner can set Contest Status.")
84- else if (if ((A != a))
85- then (A != b)
86+ else if (if ((B != c))
87+ then (B != b)
8688 else false)
87- then throw(("Invalid status: " + A))
88- else WriteSet([DataEntry((("contest_" + toString(z)) + "_status"), A)])
89+ then throw(("Invalid status: " + B))
90+ else WriteSet([DataEntry((("contest_" + toString(A)) + "_status"), B)])
8991 }
9092
9193
9294
93-@Callable(y)
95+@Callable(z)
9496 func setContestConfiguration () = {
95- let B = toBase58String(y.caller.bytes)
96- let s = k("contest_currentnumber")
97- let C = p((("contest_" + toString(s)) + "_status"))
98- let D = (s + 1)
99- let E = (((wavesBalance(this) * 99) / 100) / 25)
100- if ((B != c))
101- then throw(((("Only dAPP Owner can Configure Contest. Caller account: " + B) + " dapp owner: ") + c))
102- else if ((C == a))
103- then throw(("You cannot configure a new Contest while old Contest status is: " + C))
97+ let C = toBase58String(z.caller.bytes)
98+ let t = l("contest_currentnumber")
99+ let D = q((("contest_" + toString(t)) + "_status"))
100+ let E = (t + 1)
101+ let F = (wavesBalance(this) / 50)
102+ if ((C != d))
103+ then throw(((("Only dAPP Owner can Configure Contest. Caller account: " + C) + " dapp owner: ") + d))
104+ else if ((D == a))
105+ then throw(("You cannot configure a new Contest while old Contest status is: " + D))
104106 else {
105- let F = (height + (7 * 1440))
106- WriteSet([DataEntry("contest_currentnumber", D), DataEntry((("contest_" + toString(D)) + "_finishheight"), F), DataEntry((("contest_" + toString(D)) + "_status"), a), DataEntry((("contest_" + toString(D)) + "_betcounter"), 0), DataEntry((("contest_" + toString(D)) + "_betcost"), 0)])
107+ let G = (height + (7 * 1440))
108+ WriteSet([DataEntry("contest_currentnumber", E), DataEntry((("contest_" + toString(E)) + "_finishheight"), G), DataEntry((("contest_" + toString(E)) + "_status"), a), DataEntry((("contest_" + toString(E)) + "_betcounter"), 0), DataEntry((("contest_" + toString(E)) + "_betcost"), 0)])
107109 }
108110 }
109111
110112
111113
112-@Callable(y)
113-func bet (G) = {
114- let B = toBase58String(y.caller.bytes)
115- let H = extract(y.payment)
116- let s = k("contest_currentnumber")
117- let I = k((("contest_" + toString(s)) + "_startheight"))
118- let F = k((("contest_" + toString(s)) + "_finishheight"))
119- let J = k((("contest_" + toString(s)) + "_betcounter"))
120- let C = p((("contest_" + toString(s)) + "_status"))
121- let K = (J + 1)
122- let A = p((("contest_" + toString(s)) + "_status"))
123- let L = k(((("bet_" + toString(s)) + "_") + toString(G)))
124- let M = t(L)
125- if ((height > (F - (2 * 1440))))
114+@Callable(z)
115+func bet (H) = {
116+ let C = toBase58String(z.caller.bytes)
117+ let I = extract(z.payment)
118+ let t = l("contest_currentnumber")
119+ let J = l((("contest_" + toString(t)) + "_startheight"))
120+ let G = l((("contest_" + toString(t)) + "_finishheight"))
121+ let K = l((("contest_" + toString(t)) + "_betcounter"))
122+ let D = q((("contest_" + toString(t)) + "_status"))
123+ let L = l((("contest_" + toString(t)) + "_betcost"))
124+ let M = (K + 1)
125+ let B = q((("contest_" + toString(t)) + "_status"))
126+ let N = l(((("bet_" + toString(t)) + "_") + toString(H)))
127+ let O = u(N)
128+ if ((height > (G - (2 * 1440))))
126129 then throw("You cannot bet anymore at this height.")
127- else if ((C != a))
128- then throw(("Invalid status: you cannot bet now, contest status is: " + C))
129- else if (if ((H.assetId != j))
130+ else if ((D != a))
131+ then throw(("Invalid status: you cannot bet now, contest status is: " + D))
132+ else if (if ((I.assetId != k))
130133 then true
131- else (H.amount != 500000))
132- then throw(("You must pay 5 WLT to bet. You paid: " + toString(H.amount)))
133- else if (if ((M != h))
134- then (M != B)
134+ else (I.amount != 500000))
135+ then throw(("You must pay 5 WLT to bet. You paid: " + toString(I.amount)))
136+ else if (if ((O != i))
137+ then (O != C)
135138 else false)
136- then throw(((((("Another user: " + M) + " did bet already on rate: ") + toString(G)) + " betID:") + toString(L)))
137- else WriteSet([DataEntry((((("bet_" + toString(s)) + "_") + toString(K)) + "_owner"), B), DataEntry(((("bet_" + toString(s)) + "_") + toString(G)), K), DataEntry((("contest_" + toString(s)) + "_betcounter"), K)])
139+ then throw(((((("Another user: " + O) + " did bet already on rate: ") + toString(H)) + " betID:") + toString(N)))
140+ else WriteSet([DataEntry((((("bet_" + toString(t)) + "_") + toString(M)) + "_owner"), C), DataEntry(((("bet_" + toString(t)) + "_") + toString(H)), M), DataEntry((("contest_" + toString(t)) + "_betcounter"), M)])
138141 }
139142
140143
141144
142-@Callable(y)
145+@Callable(z)
143146 func closecontest () = {
144- let N = v()
145- let s = k("contest_currentnumber")
146- let O = k(((("bet_" + toString(s)) + "_") + toString(N)))
147- let P = t(O)
148- let F = k((("contest_" + toString(s)) + "_finishheight"))
149- let B = toBase58String(y.caller.bytes)
150- let Q = wavesBalance(this)
151- let C = p((("contest_" + toString(s)) + "_status"))
152- let R = WriteSet([DataEntry((("contest_" + toString(s)) + "_status"), b), DataEntry((("contest_" + toString(s)) + "_winner"), P), DataEntry((("contest_" + toString(s)) + "_currencyrate"), N), DataEntry((("contest_" + toString(s)) + "_height"), height)])
153- if (if ((F > height))
154- then (B != c)
147+ let P = w()
148+ let t = l("contest_currentnumber")
149+ let Q = l(((("bet_" + toString(t)) + "_") + toString(P)))
150+ let R = u(Q)
151+ let G = l((("contest_" + toString(t)) + "_finishheight"))
152+ let C = toBase58String(z.caller.bytes)
153+ let S = wavesBalance(this)
154+ let D = q((("contest_" + toString(t)) + "_status"))
155+ let T = WriteSet([DataEntry((("contest_" + toString(t)) + "_status"), b), DataEntry((("contest_" + toString(t)) + "_winner"), R), DataEntry((("contest_" + toString(t)) + "_currencyrate"), P), DataEntry((("contest_" + toString(t)) + "_height"), height)])
156+ if (if ((G > height))
157+ then (C != d)
155158 else false)
156- then throw(((("account: " + B) + ": Cannot close the contest before height:") + toString(F)))
157- else if ((C != a))
158- then throw(("Cannot close a contest in status: " + C))
159- else if ((P != h))
159+ then throw(((("account: " + C) + ": Cannot close the contest before height:") + toString(G)))
160+ else if ((D != a))
161+ then throw(("Cannot close a contest in status: " + D))
162+ else if ((R != i))
160163 then {
161- let S = ((assetBalance(this, j) * 5) / 100)
162- let T = ((assetBalance(this, j) * 90) / 100)
163- let U = TransferSet([ScriptTransfer(extract(addressFromString(P)), (((wavesBalance(this) * 99) / 100) - i), unit), ScriptTransfer(extract(addressFromString(d)), S, j), ScriptTransfer(extract(addressFromString(f)), S, j), ScriptTransfer(extract(addressFromString(e)), T, j)])
164- ScriptResult(WriteSet([DataEntry((("contest_" + toString(s)) + "_status"), b), DataEntry((("contest_" + toString(s)) + "_winner"), P), DataEntry((("contest_" + toString(s)) + "_currencyrate"), N), DataEntry((("contest_" + toString(s)) + "_height"), height)]), U)
164+ let U = ((assetBalance(this, k) * 5) / 100)
165+ let V = ((assetBalance(this, k) * 90) / 100)
166+ let W = TransferSet([ScriptTransfer(extract(addressFromString(R)), (((wavesBalance(this) * 99) / 100) - j), unit), ScriptTransfer(extract(addressFromString(e)), U, k), ScriptTransfer(extract(addressFromString(g)), U, k), ScriptTransfer(extract(addressFromString(f)), V, k)])
167+ ScriptResult(WriteSet([DataEntry((("contest_" + toString(t)) + "_status"), b), DataEntry((("contest_" + toString(t)) + "_winner"), R), DataEntry((("contest_" + toString(t)) + "_currencyrate"), P), DataEntry((("contest_" + toString(t)) + "_height"), height)]), W)
165168 }
166- else WriteSet([DataEntry((("contest_" + toString(s)) + "_status"), b), DataEntry((("contest_" + toString(s)) + "_winner"), P), DataEntry((("contest_" + toString(s)) + "_currencyrate"), N), DataEntry((("contest_" + toString(s)) + "_height"), height)])
169+ else WriteSet([DataEntry((("contest_" + toString(t)) + "_status"), b), DataEntry((("contest_" + toString(t)) + "_winner"), R), DataEntry((("contest_" + toString(t)) + "_currencyrate"), P), DataEntry((("contest_" + toString(t)) + "_height"), height)])
167170 }
168171
169172
170-@Verifier(V)
171-func W () = {
172- let n = V
173- if (if ($isInstanceOf(n, "SetScriptTransaction"))
173+@Verifier(X)
174+func Y () = {
175+ let o = X
176+ if (if ($isInstanceOf(o, "SetScriptTransaction"))
174177 then true
175- else $isInstanceOf(n, "DataTransaction"))
176- then sigVerify(V.bodyBytes, V.proofs[0], V.senderPublicKey)
177- else if ($isInstanceOf(n, "InvokeScriptTransaction"))
178+ else $isInstanceOf(o, "DataTransaction"))
179+ then sigVerify(X.bodyBytes, X.proofs[0], X.senderPublicKey)
180+ else if ($isInstanceOf(o, "InvokeScriptTransaction"))
178181 then true
179182 else true
180183 }
181184

github/deemru/w8io/169f3d6 
92.88 ms