tx · 92rS1K9D8PFPHGBwYBtD5rQc5bWvTCckzSREn3grWZUu

3MuKEDU6qPggcs65swNH6JcUbS7hB6jVzrA:  -0.01000000 Waves

2023.09.19 17:28 [2762384] smart account 3MuKEDU6qPggcs65swNH6JcUbS7hB6jVzrA > SELF 0.00000000 Waves

{ "type": 13, "id": "92rS1K9D8PFPHGBwYBtD5rQc5bWvTCckzSREn3grWZUu", "fee": 1000000, "feeAssetId": null, "timestamp": 1695133743051, "version": 2, "chainId": 84, "sender": "3MuKEDU6qPggcs65swNH6JcUbS7hB6jVzrA", "senderPublicKey": "GkZtgtQPEtE9JoxK1tzKc1t7uw12vz6aqKhDcBi136yV", "proofs": [ "3fmCkWSuSYb6vr252kcqfhTNh5BY4fbymN4Ykx1fkCBK5oiHj7pyGD4CKCNp44EXziukcuh6qBz3NVsS68mwwqrX" ], "script": "base64:BgIVCAISABIDCgEBEgQKAgICEgQKAgEEEQADU0VQAgJfXwAPcmVwdXRhdGlvbkFzc2V0ASBxggycON8pyCFInplKujKGtzqQhMOf+vAbfdt6zmK1aAAMcHJvcG9zYWxUaW1lCQBoAgkAaAIJAGgCCQBoAgDoBwA8ADwAGAADARFjb3VudFByb3Bvc2Fsc0tleQACAmNwAQtwcm9wb3NhbEtleQEKcHJvcG9zYWxJZAkAuQkCCQDMCAICAXAJAMwIAgkApAMBBQpwcm9wb3NhbElkBQNuaWwFA1NFUAESdW5sb2NrVGltZXN0YW1wS2V5AQR1c2VyCQC5CQIJAMwIAgICdXQJAMwIAgkA2AQBCAUEdXNlcgVieXRlcwUDbmlsBQNTRVABEHVzZXJEZXBvc2l0ZWRLZXkBBHVzZXIJALkJAgkAzAgCAgJ1ZAkAzAgCCQDYBAEIBQR1c2VyBWJ5dGVzBQNuaWwFA1NFUAETdXNlclByb3Bvc2FsVm90ZUtleQIKcHJvcG9zYWxJZAR1c2VyCQC5CQIJAMwIAgICdXAJAMwIAgkApAMBBQpwcm9wb3NhbElkCQDMCAIJANgEAQgFBHVzZ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Ym9keUJ5dGVzCQCRAwIIBQJ0eAZwcm9vZnMAAAgFAnR4D3NlbmRlclB1YmxpY0tledwpBLE=", "height": 2762384, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: ErFjhyvLFTXt87jxA11UEXFmp3H866ksP12rZSc9Dmzc Next: 4pjT18sgChf2DJkc191M5De7FN2JCyC39avJ3EJUUyPg Full:
OldNewDifferences
11 {-# STDLIB_VERSION 6 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let a = "__"
55
66 let b = base58'8e65zYSAcGfmQnVX462UEMWf6PmHgtckyGcrEMXKZZaF'
77
88 let c = ((((1000 * 60) * 60) * 24) * 3)
99
1010 func d () = "cp"
1111
1212
1313 func e (f) = makeString(["p", toString(f)], a)
1414
1515
1616 func g (h) = makeString(["ut", toBase58String(h.bytes)], a)
1717
1818
1919 func i (h) = makeString(["ud", toBase58String(h.bytes)], a)
2020
2121
2222 func j (f,h) = makeString(["up", toString(f), toBase58String(h.bytes)], a)
2323
2424
2525 func k (f,h,l) = IntegerEntry(j(f, h), l)
2626
2727
2828 func m (f,h) = {
2929 let n = getInteger(j(f, h))
3030 if ($isInstanceOf(n, "Int"))
3131 then {
3232 let o = n
3333 o
3434 }
3535 else 0
3636 }
3737
3838
3939 func p (q,r,s,t,u,v,w) = StringEntry(e(q), makeString_11C([toBase16String(r.bytes), s, t, toString(u), toString(v), toString(w)], a))
4040
4141
4242 func x (q) = {
4343 let y = split({
4444 let n = getString(this, e(q))
4545 if ($isInstanceOf(n, "String"))
4646 then {
4747 let z = n
4848 z
4949 }
5050 else throw("proposal not found")
5151 }, a)
5252 $Tuple6(Address(fromBase16String(y[0])), y[1], y[2], parseIntValue(y[3]), parseIntValue(y[4]), parseIntValue(y[5]))
5353 }
5454
5555
5656 func A (o) = if ((size(o.payments) == 1))
5757 then if ((o.payments[0].assetId == b))
5858 then true
5959 else throw("only reputation assets")
6060 else throw("only 1 payment")
6161
6262
6363 func B (h) = {
6464 let n = getInteger(this, g(h))
6565 if ($isInstanceOf(n, "Int"))
6666 then {
6767 let C = n
6868 C
6969 }
7070 else 0
7171 }
7272
7373
7474 func D () = {
7575 let n = getInteger(this, d())
7676 if ($isInstanceOf(n, "Int"))
7777 then {
7878 let C = n
7979 C
8080 }
8181 else 0
8282 }
8383
8484
8585 func E (h) = {
8686 let n = getInteger(this, i(h))
8787 if ($isInstanceOf(n, "Int"))
8888 then {
8989 let C = n
9090 C
9191 }
9292 else 0
9393 }
9494
9595
9696 func F (q) = if (if ((D() > q))
9797 then ((x(q)._4 + c) > lastBlock.timestamp)
9898 else false)
9999 then true
100100 else throw("proposal not alive")
101101
102102
103103 @Callable(o)
104104 func deposit () = {
105105 let G = [A(o)]
106106 if ((G == G))
107107 then {
108108 let H = E(o.caller)
109109 let I = (H + o.payments[0].amount)
110110 [IntegerEntry(i(o.caller), I)]
111111 }
112112 else throw("onlyReputationAsset")
113113 }
114114
115115
116116
117117 @Callable(o)
118118 func withdraw (J) = {
119119 let K = toBase58String(o.caller.bytes)
120120 let H = {
121121 let n = getInteger(this, K)
122122 if ($isInstanceOf(n, "Int"))
123123 then {
124124 let C = n
125125 C
126126 }
127127 else 0
128128 }
129129 let I = (H - J)
130130 if ((0 > J))
131131 then throw("Can't withdraw negative amount")
132132 else if ((B(o.caller) > lastBlock.timestamp))
133133 then throw("Locked")
134134 else if ((0 > I))
135135 then throw("Not enough balance")
136136 else [IntegerEntry(K, I), ScriptTransfer(o.caller, J, b)]
137137 }
138138
139139
140140
141141 @Callable(o)
142142 func createProposal (s,t) = {
143143 let L = D()
144144 [p(L, o.caller, toBase16String(s), toBase16String(t), lastBlock.timestamp, 0, 0), IntegerEntry(d(), (L + 1))]
145145 }
146146
147147
148148
149149 @Callable(o)
150150 func vote (f,M) = if (!(F(f)))
151151 then throw("proposalNotAlive")
152152 else {
153153 let N = x(f)
154154 let O = max([(N._4 + c), B(o.caller)])
155155 let P = m(f, o.caller)
156156 let l = E(o.caller)
157157 let Q = if ((P > 0))
158158 then P
159159 else 0
160160 let R = if ((0 > P))
161161 then -(P)
162162 else 0
163163 let S = if ((M == true))
164164 then l
165165 else 0
166166 let T = if ((M == false))
167167 then l
168168 else 0
169169 [p(f, N._1, N._2, N._3, N._4, ((N._5 - Q) + S), ((N._6 - R) + T)), k(f, o.caller, if (M)
170170 then l
171171 else -(l))]
172172 }
173173
174174
175175 @Verifier(U)
176176 func V () = sigVerify(U.bodyBytes, U.proofs[0], U.senderPublicKey)
177177

github/deemru/w8io/169f3d6 
55.60 ms