tx · HbfCJWkRSAks6wBa9j5ynht573hYxVJ1uJV27ewALPPo 3N9eE86dXUm7rfc2WWCMLHkaEM4Y8yoNj7u: -0.01880000 Waves 2020.12.26 23:29 [1326162] smart account 3N9eE86dXUm7rfc2WWCMLHkaEM4Y8yoNj7u > SELF 0.00000000 Waves
{ "type": 13, "id": "HbfCJWkRSAks6wBa9j5ynht573hYxVJ1uJV27ewALPPo", "fee": 1880000, "feeAssetId": null, "timestamp": 1609014637002, "version": 2, "chainId": 84, "sender": "3N9eE86dXUm7rfc2WWCMLHkaEM4Y8yoNj7u", "senderPublicKey": "FFDorDp8bC9dyUK2w8hYPWPVEcbbk9zYkpHn3gcq9svn", "proofs": [ "3CHv2j8sVVwarCqVaKKJdyLodqKJthN7WYwRxEmrywXWyp4uXMSrbWJwk1VviptW57F3Yh3XLqDpR86btS5jZToP" ], "script": "base64:AAIDAAAAAAAAABYIARIAEgASABIAEgMKAQESAwoBARIAAAAAAAAAAAcAAAABaQEAAAAMUmVhZFBvb2xEYXRhAAAAAAQAAAAOR292ZXJuVG9rZW5LZXkCAAAAFUdvdmVyblRva2VuTWF4RGVwb3NpdAQAAAAaTWF4R292ZXJuVG9rZW5EZXBvc2l0ZXJLZXkCAAAAGk1heEdvdmVyblRva2VuRGVwb3NpdGVyS2V5BAAAAAtTdGFrZWRUb2tlbgEAAAAg4kCrtAPNiHBMRPYvMCXeThBq6KlRf6cxe4yUvVS2aoUEAAAAC0dvdmVyblRva2VuAQAAACASiWf4V0Rs4Spwpaqhn2bfVjnt1mPO6pt7R8ZSZ6gxXgQAAAASVXNlclN0YWtlZFRva2VuS2V5CQABLAAAAAIJAAEsAAAAAgkAAlgAAAABCAgFAAAAAWkAAAAGY2FsbGVyAAAABWJ5dGVzAgAAAAFfCQACWAAAAAEFAAAAC1N0YWtlZFRva2VuBAAAABJVc2VyR292ZXJuVG9rZW5LZXkJAAEsAAAAAgkAASwAAAACCQACWAAAAAEICAUAAAABaQAAAAZjYWxsZXIAAAAF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IHRvIGRlcG9zaXQgMTAwIEdvdmVyblRva2VuIHRvIGNsYWltIFJld2FyZCAKIFlvdXIgQmFsYW5jZSBpczogCQABpAAAAAEFAAAAFVVzZXJHb3Zlcm5Ub2tlbkFtb3VudAIAAAATCiBEZXBvc2l0IGRvbmUgYXQ6IAkAAaQAAAABBQAAAAtQcml6ZUhlaWdodAIAAAALICBBbmQgd2FpdDoJAAGkAAAAAQkAAGkAAAACBQAAAAZoZWlnaHQAAAAAAAAAADwAAAAAgtRn2w==", "height": 1326162, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 6RkBmX6gBwS8X7spMH3QX48xmChfPH9GL2xGELaJSwuB Next: 6wrtoVQxMSvALmV9VUkdr4cuFTEpKbNAo9mnw3DWN3EE Diff:
Old | New | Differences | |
---|---|---|---|
273 | 273 | let k = j | |
274 | 274 | k | |
275 | 275 | } | |
276 | - | else | |
276 | + | else 0 | |
277 | 277 | } | |
278 | 278 | let i = { | |
279 | 279 | let j = getInteger(this, b) |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 3 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | ||
5 | 5 | ||
6 | 6 | @Callable(a) | |
7 | 7 | func ReadPoolData () = { | |
8 | 8 | let b = "GovernTokenMaxDeposit" | |
9 | 9 | let c = "MaxGovernTokenDepositerKey" | |
10 | 10 | let d = base58'GECLRH2fx2Xxix5gmrGV92AMt1A9LPohRpqwqRE16mwr' | |
11 | 11 | let e = base58'2FMrxDLdQhauSY7d1uDUyKP1MpxkM7BeWA2UMnk3cG3P' | |
12 | 12 | let f = ((toBase58String(a.caller.bytes) + "_") + toBase58String(d)) | |
13 | 13 | let g = ((toBase58String(a.caller.bytes) + "_") + toBase58String(e)) | |
14 | 14 | let h = getStringValue(this, c) | |
15 | 15 | let i = { | |
16 | 16 | let j = getInteger(this, b) | |
17 | 17 | if ($isInstanceOf(j, "Int")) | |
18 | 18 | then { | |
19 | 19 | let k = j | |
20 | 20 | k | |
21 | 21 | } | |
22 | 22 | else 0 | |
23 | 23 | } | |
24 | 24 | let l = getStringValue(this, g) | |
25 | 25 | let m = { | |
26 | 26 | let j = getInteger(this, g) | |
27 | 27 | if ($isInstanceOf(j, "Int")) | |
28 | 28 | then { | |
29 | 29 | let k = j | |
30 | 30 | k | |
31 | 31 | } | |
32 | 32 | else 0 | |
33 | 33 | } | |
34 | 34 | let n = getStringValue(this, f) | |
35 | 35 | let o = { | |
36 | 36 | let j = getInteger(this, f) | |
37 | 37 | if ($isInstanceOf(j, "Int")) | |
38 | 38 | then { | |
39 | 39 | let k = j | |
40 | 40 | k | |
41 | 41 | } | |
42 | 42 | else 0 | |
43 | 43 | } | |
44 | 44 | throw(((((((("Winner is.....: " + h) + " Balance is: ") + toString(i)) + " | |
45 | 45 | Staked Token in your Balance is.....: ") + toString(o)) + " | |
46 | 46 | Govern Token in your Balance is.....: ") + toString(m))) | |
47 | 47 | } | |
48 | 48 | ||
49 | 49 | ||
50 | 50 | ||
51 | 51 | @Callable(a) | |
52 | 52 | func ResetAccount () = { | |
53 | 53 | let d = base58'GECLRH2fx2Xxix5gmrGV92AMt1A9LPohRpqwqRE16mwr' | |
54 | 54 | let e = base58'2FMrxDLdQhauSY7d1uDUyKP1MpxkM7BeWA2UMnk3cG3P' | |
55 | 55 | let f = ((toBase58String(a.caller.bytes) + "_") + toBase58String(d)) | |
56 | 56 | let g = ((toBase58String(a.caller.bytes) + "_") + toBase58String(e)) | |
57 | 57 | let p = (toBase58String(a.caller.bytes) + "_StakedTransactions") | |
58 | 58 | WriteSet([DataEntry(g, 0), DataEntry(f, 0), DataEntry(p, 0)]) | |
59 | 59 | } | |
60 | 60 | ||
61 | 61 | ||
62 | 62 | ||
63 | 63 | @Callable(a) | |
64 | 64 | func Stake () = { | |
65 | 65 | let q = "3MsH5Hr1qQYUnwq4HTpiaGpXQi6cGPUsa5n" | |
66 | 66 | let d = base58'GECLRH2fx2Xxix5gmrGV92AMt1A9LPohRpqwqRE16mwr' | |
67 | 67 | let e = base58'2FMrxDLdQhauSY7d1uDUyKP1MpxkM7BeWA2UMnk3cG3P' | |
68 | 68 | let r = assetBalance(this, e) | |
69 | 69 | let s = assetBalance(this, d) | |
70 | 70 | let t = extract(a.payment) | |
71 | 71 | if (if ((t.amount > 0)) | |
72 | 72 | then (t.assetId == d) | |
73 | 73 | else false) | |
74 | 74 | then { | |
75 | 75 | let f = ((toBase58String(a.caller.bytes) + "_") + toBase58String(d)) | |
76 | 76 | let g = ((toBase58String(a.caller.bytes) + "_") + toBase58String(e)) | |
77 | 77 | let p = (toBase58String(a.caller.bytes) + "_StakedTransactions") | |
78 | 78 | let u = (toBase58String(a.caller.bytes) + "_PrizeHeight") | |
79 | 79 | let v = { | |
80 | 80 | let j = getInteger(this, p) | |
81 | 81 | if ($isInstanceOf(j, "Int")) | |
82 | 82 | then { | |
83 | 83 | let k = j | |
84 | 84 | k | |
85 | 85 | } | |
86 | 86 | else 0 | |
87 | 87 | } | |
88 | 88 | let w = (v + 1) | |
89 | 89 | let x = { | |
90 | 90 | let j = getInteger(this, f) | |
91 | 91 | if ($isInstanceOf(j, "Int")) | |
92 | 92 | then { | |
93 | 93 | let k = j | |
94 | 94 | k | |
95 | 95 | } | |
96 | 96 | else 0 | |
97 | 97 | } | |
98 | 98 | let y = (x + t.amount) | |
99 | 99 | let z = { | |
100 | 100 | let j = getInteger(this, g) | |
101 | 101 | if ($isInstanceOf(j, "Int")) | |
102 | 102 | then { | |
103 | 103 | let k = j | |
104 | 104 | k | |
105 | 105 | } | |
106 | 106 | else 0 | |
107 | 107 | } | |
108 | 108 | if ((1 > r)) | |
109 | 109 | then throw("No enough GovernToken In Contract, Please deposit GovernTokens") | |
110 | 110 | else if ((s == 0)) | |
111 | 111 | then { | |
112 | 112 | let A = (z + 10) | |
113 | 113 | ScriptResult(WriteSet([DataEntry(g, A), DataEntry(f, y), DataEntry(p, w), DataEntry(u, height)]), TransferSet([ScriptTransfer(a.caller, 10, e)])) | |
114 | 114 | } | |
115 | 115 | else if ((w > 50)) | |
116 | 116 | then { | |
117 | 117 | let B = ((10 * w) * (y / s)) | |
118 | 118 | let A = (z + B) | |
119 | 119 | ScriptResult(WriteSet([DataEntry(g, B), DataEntry(f, y), DataEntry(p, w), DataEntry(u, height)]), TransferSet([ScriptTransfer(a.caller, B, e)])) | |
120 | 120 | } | |
121 | 121 | else { | |
122 | 122 | let B = (10 * (y / s)) | |
123 | 123 | let A = (z + B) | |
124 | 124 | ScriptResult(WriteSet([DataEntry(g, B), DataEntry(f, y), DataEntry(p, w), DataEntry(u, height)]), TransferSet([ScriptTransfer(a.caller, B, e)])) | |
125 | 125 | } | |
126 | 126 | } | |
127 | 127 | else throw("Can deposit only StakeToken") | |
128 | 128 | } | |
129 | 129 | ||
130 | 130 | ||
131 | 131 | ||
132 | 132 | @Callable(a) | |
133 | 133 | func DepositGovernToken () = { | |
134 | 134 | let e = base58'2FMrxDLdQhauSY7d1uDUyKP1MpxkM7BeWA2UMnk3cG3P' | |
135 | 135 | let C = toBase58String(e) | |
136 | 136 | let t = extract(a.payment) | |
137 | 137 | if (if (isDefined(t.assetId)) | |
138 | 138 | then (extract(t.assetId) == e) | |
139 | 139 | else false) | |
140 | 140 | then { | |
141 | 141 | let D = ((toBase58String(a.caller.bytes) + "_") + toBase58String(e)) | |
142 | 142 | let E = { | |
143 | 143 | let j = getInteger(this, D) | |
144 | 144 | if ($isInstanceOf(j, "Int")) | |
145 | 145 | then { | |
146 | 146 | let k = j | |
147 | 147 | k | |
148 | 148 | } | |
149 | 149 | else 0 | |
150 | 150 | } | |
151 | 151 | let F = (E + t.amount) | |
152 | 152 | let b = "GovernTokenMaxDeposit" | |
153 | 153 | let c = "MaxGovernTokenDepositerKey" | |
154 | 154 | let i = { | |
155 | 155 | let j = getInteger(this, b) | |
156 | 156 | if ($isInstanceOf(j, "Int")) | |
157 | 157 | then { | |
158 | 158 | let k = j | |
159 | 159 | k | |
160 | 160 | } | |
161 | 161 | else 0 | |
162 | 162 | } | |
163 | 163 | if ((F > i)) | |
164 | 164 | then WriteSet([DataEntry(D, F), DataEntry(b, F), DataEntry(c, D)]) | |
165 | 165 | else WriteSet([DataEntry(D, F)]) | |
166 | 166 | } | |
167 | 167 | else throw("Can deposit only Govern Token") | |
168 | 168 | } | |
169 | 169 | ||
170 | 170 | ||
171 | 171 | ||
172 | 172 | @Callable(a) | |
173 | 173 | func WithdrawStakedFunds (G) = { | |
174 | 174 | let d = base58'GECLRH2fx2Xxix5gmrGV92AMt1A9LPohRpqwqRE16mwr' | |
175 | 175 | let e = base58'2FMrxDLdQhauSY7d1uDUyKP1MpxkM7BeWA2UMnk3cG3P' | |
176 | 176 | let f = ((toBase58String(a.caller.bytes) + "_") + toBase58String(d)) | |
177 | 177 | let g = ((toBase58String(a.caller.bytes) + "_") + toBase58String(e)) | |
178 | 178 | let D = toBase58String(a.caller.bytes) | |
179 | 179 | let E = { | |
180 | 180 | let j = getInteger(this, f) | |
181 | 181 | if ($isInstanceOf(j, "Int")) | |
182 | 182 | then { | |
183 | 183 | let k = j | |
184 | 184 | k | |
185 | 185 | } | |
186 | 186 | else 0 | |
187 | 187 | } | |
188 | 188 | let H = (E - G) | |
189 | 189 | if ((0 > G)) | |
190 | 190 | then throw("Can't withdraw negative amount") | |
191 | 191 | else if ((0 > H)) | |
192 | 192 | then throw(("User cannot withdraw more than deposited funds, Your deposit is: " + toString(E))) | |
193 | 193 | else { | |
194 | 194 | let I = assetBalance(this, e) | |
195 | 195 | if ((1 > I)) | |
196 | 196 | then throw("No enough GovernToken In Contract") | |
197 | 197 | else ScriptResult(WriteSet([DataEntry(g, 1), DataEntry(f, H)]), TransferSet([ScriptTransfer(a.caller, 1, e), ScriptTransfer(a.caller, G, d)])) | |
198 | 198 | } | |
199 | 199 | } | |
200 | 200 | ||
201 | 201 | ||
202 | 202 | ||
203 | 203 | @Callable(a) | |
204 | 204 | func HarvestGovernToiken (G) = { | |
205 | 205 | let e = base58'2FMrxDLdQhauSY7d1uDUyKP1MpxkM7BeWA2UMnk3cG3P' | |
206 | 206 | let g = ((toBase58String(a.caller.bytes) + "_") + toBase58String(e)) | |
207 | 207 | let D = toBase58String(a.caller.bytes) | |
208 | 208 | let E = { | |
209 | 209 | let j = getInteger(this, g) | |
210 | 210 | if ($isInstanceOf(j, "Int")) | |
211 | 211 | then { | |
212 | 212 | let k = j | |
213 | 213 | k | |
214 | 214 | } | |
215 | 215 | else 0 | |
216 | 216 | } | |
217 | 217 | let H = (E - G) | |
218 | 218 | if ((0 > G)) | |
219 | 219 | then throw("Can't withdraw negative amount") | |
220 | 220 | else if ((0 > H)) | |
221 | 221 | then throw(("User cannot withdraw more than deposited funds, Your deposit is: " + toString(E))) | |
222 | 222 | else { | |
223 | 223 | let I = assetBalance(this, e) | |
224 | 224 | ScriptResult(WriteSet([DataEntry(g, H)]), TransferSet([ScriptTransfer(a.caller, G, e)])) | |
225 | 225 | } | |
226 | 226 | } | |
227 | 227 | ||
228 | 228 | ||
229 | 229 | ||
230 | 230 | @Callable(a) | |
231 | 231 | func ClaimPrize () = { | |
232 | 232 | let d = base58'GECLRH2fx2Xxix5gmrGV92AMt1A9LPohRpqwqRE16mwr' | |
233 | 233 | let e = base58'2FMrxDLdQhauSY7d1uDUyKP1MpxkM7BeWA2UMnk3cG3P' | |
234 | 234 | let q = base58'3MsH5Hr1qQYUnwq4HTpiaGpXQi6cGPUsa5n' | |
235 | 235 | let f = ((toBase58String(a.caller.bytes) + "_") + toBase58String(d)) | |
236 | 236 | let g = ((toBase58String(a.caller.bytes) + "_") + toBase58String(e)) | |
237 | 237 | let J = ((toBase58String(q) + "_") + toBase58String(d)) | |
238 | 238 | let I = assetBalance(this, e) | |
239 | 239 | let K = { | |
240 | 240 | let j = getInteger(this, g) | |
241 | 241 | if ($isInstanceOf(j, "Int")) | |
242 | 242 | then { | |
243 | 243 | let k = j | |
244 | 244 | k | |
245 | 245 | } | |
246 | 246 | else 0 | |
247 | 247 | } | |
248 | 248 | let L = { | |
249 | 249 | let j = getInteger(this, f) | |
250 | 250 | if ($isInstanceOf(j, "Int")) | |
251 | 251 | then { | |
252 | 252 | let k = j | |
253 | 253 | k | |
254 | 254 | } | |
255 | 255 | else 0 | |
256 | 256 | } | |
257 | 257 | let M = { | |
258 | 258 | let j = getInteger(this, J) | |
259 | 259 | if ($isInstanceOf(j, "Int")) | |
260 | 260 | then { | |
261 | 261 | let k = j | |
262 | 262 | k | |
263 | 263 | } | |
264 | 264 | else 0 | |
265 | 265 | } | |
266 | 266 | let b = "GovernTokenMaxDeposit" | |
267 | 267 | let c = "MaxGovernTokenDepositerKey" | |
268 | 268 | let N = getStringValue(this, c) | |
269 | 269 | let O = { | |
270 | 270 | let j = getInteger(this, b) | |
271 | 271 | if ($isInstanceOf(j, "Int")) | |
272 | 272 | then { | |
273 | 273 | let k = j | |
274 | 274 | k | |
275 | 275 | } | |
276 | - | else | |
276 | + | else 0 | |
277 | 277 | } | |
278 | 278 | let i = { | |
279 | 279 | let j = getInteger(this, b) | |
280 | 280 | if ($isInstanceOf(j, "Int")) | |
281 | 281 | then { | |
282 | 282 | let k = j | |
283 | 283 | k | |
284 | 284 | } | |
285 | 285 | else 0 | |
286 | 286 | } | |
287 | 287 | if (if ((M == 0)) | |
288 | 288 | then true | |
289 | 289 | else (100 > I)) | |
290 | 290 | then throw("No prize to Claim or No enough Govern Token en Contract") | |
291 | 291 | else if ((g != N)) | |
292 | 292 | then throw("You are not the winner hence cannot claim the reward ") | |
293 | 293 | else if ((1 > L)) | |
294 | 294 | then throw(("You have to Stake StakedToken to claim reward | |
295 | 295 | Your Balance of Staked Tokens is: " + toString(L))) | |
296 | 296 | else if (if ((K >= 100)) | |
297 | 297 | then (height >= (O + (1440 * 30))) | |
298 | 298 | else false) | |
299 | 299 | then if ((K >= i)) | |
300 | 300 | then ScriptResult(WriteSet([DataEntry(N, M), DataEntry(J, 0), DataEntry(b, 0), DataEntry(g, 0), DataEntry(c, "")]), TransferSet([ScriptTransfer(a.caller, M, d), ScriptTransfer(a.caller, 100, e)])) | |
301 | 301 | else throw((("You should deposit at least " + toString(i)) + " to be able to claim reward")) | |
302 | 302 | else throw(((((("You have to deposit 100 GovernToken to claim Reward | |
303 | 303 | Your Balance is: " + toString(K)) + " | |
304 | 304 | Deposit done at: ") + toString(O)) + " And wait:") + toString((height / 60)))) | |
305 | 305 | } | |
306 | 306 | ||
307 | 307 |
github/deemru/w8io/169f3d6 64.54 ms ◑