tx · 2a3MPP5RgimxsNpXpzSALWYkEaVDcP9VFKtPEM73sMoQ 3MxFYk97QYdeHRMTu51rVyHqvFEVB4UtmBX: -0.10700000 Waves 2022.09.14 17:25 [2228890] smart account 3MxFYk97QYdeHRMTu51rVyHqvFEVB4UtmBX > SELF 0.00000000 Waves
{ "type": 13, "id": "2a3MPP5RgimxsNpXpzSALWYkEaVDcP9VFKtPEM73sMoQ", "fee": 10700000, "feeAssetId": null, "timestamp": 1663165521769, "version": 2, "chainId": 84, "sender": "3MxFYk97QYdeHRMTu51rVyHqvFEVB4UtmBX", "senderPublicKey": "2panvMtE3s1p1oCdVqRGMuBYaZJV3AZ6zpdmZ6vHkDaL", "proofs": [ "4qwF4qM2MwEsJzy2S5v2tuf1Yr4RBnjU1nEmdWcMRHaAiKsAHoBwGxnX2gW8LQVvQtWmxwTnVSerkAHvENk3RFM", "1EdpqUPhhTZgqnBBoDV48zN1N5xmxQDCXPvFxXpVACRBHiGss3BPGhSoG9L7TJnedHspducAb44akPdcpsnspZD" ], "script": "base64:BgISCAISABIDCgEBEgMKAQgSABIAIAAHa0FjdGl2ZQIGYWN0aXZlAAZrQ2F1c2UCDnNodXRkb3duX2NhdXNlABZrTGFzdFBvb2xUb2tlbkludGVyZXN0AhNfcG9vbF9sYXN0X2ludGVyZXN0ABFrVXNlckxhc3RJbnRlcmVzdAITX3VzZXJfbGFzdF9pbnRlcmVzdAATa1VzZXJDbGFpbUF2YWlsYWJsZQIYX3VzZXJfYXZhaWxhYmxlX3RvX2NsYWltABZrVXNlclNoYXJlVG9rZW5zTG9ja2VkAhRfc2hhcmVfdG9rZW5zX2xvY2tlZAASa1NoYXJlVG9rZW5zTG9ja2VkAhpfdG90YWxfc2hhcmVfdG9rZW5zX2xvY2tlZAALa09yYWNsZVBvb2wCBXBvb2xfAA1rUG9vbEFzc2V0SWRzAglhc3NldF9pZHMADWtBZG1pblB1YktleTECC2FkbWluX3B1Yl8xAA1rQWRtaW5QdWJLZXkyAgthZG1p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QCBRJhZG1pblB1YktleTFTaWduZWQFEmFkbWluUHViS2V5MlNpZ25lZAUSYWRtaW5QdWJLZXkzU2lnbmVkAAL9H5uL", "height": 2228890, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: CMYnog9aWtWcQVuzUcdv2bfLZtxMV7iMrpRDeBayYoXM Next: 6Bo6MLwMtWFm37WkH8bvkDWv8i4Sw9btSRSQHUrce8Hx Full:
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let a = "active" | |
5 | 5 | ||
6 | 6 | let b = "shutdown_cause" | |
7 | 7 | ||
8 | 8 | let c = "_pool_last_interest" | |
9 | 9 | ||
10 | 10 | let d = "_user_last_interest" | |
11 | 11 | ||
12 | 12 | let e = "_user_available_to_claim" | |
13 | 13 | ||
14 | 14 | let f = "_share_tokens_locked" | |
15 | 15 | ||
16 | 16 | let g = "_total_share_tokens_locked" | |
17 | 17 | ||
18 | 18 | let h = "pool_" | |
19 | 19 | ||
20 | 20 | let i = "asset_ids" | |
21 | 21 | ||
22 | 22 | let j = "admin_pub_1" | |
23 | 23 | ||
24 | 24 | let k = "admin_pub_2" | |
25 | 25 | ||
26 | 26 | let l = "admin_pub_3" | |
27 | 27 | ||
28 | 28 | let m = "farming_address" | |
29 | 29 | ||
30 | 30 | let n = 100000000 | |
31 | 31 | ||
32 | 32 | let o = Address(base58'3NBBWfzZtZtszaXbitTKnrB2xXwv26Bn7H9') | |
33 | 33 | ||
34 | 34 | func p (q) = { | |
35 | 35 | let r = getString(o, q) | |
36 | 36 | if ($isInstanceOf(r, "String")) | |
37 | 37 | then { | |
38 | 38 | let s = r | |
39 | 39 | fromBase58String(s) | |
40 | 40 | } | |
41 | 41 | else { | |
42 | 42 | let t = r | |
43 | 43 | throw((q + "is empty")) | |
44 | 44 | } | |
45 | 45 | } | |
46 | 46 | ||
47 | 47 | ||
48 | 48 | let u = p(j) | |
49 | 49 | ||
50 | 50 | let v = p(k) | |
51 | 51 | ||
52 | 52 | let w = p(l) | |
53 | 53 | ||
54 | 54 | let x = Address(p(m)) | |
55 | 55 | ||
56 | 56 | let y = valueOrElse(getBooleanValue(this, a), true) | |
57 | 57 | ||
58 | 58 | func z () = if (y) | |
59 | 59 | then unit | |
60 | 60 | else throw("DApp is inactive at this moment") | |
61 | 61 | ||
62 | 62 | ||
63 | 63 | func A (B) = if (isDefined(getString(o, (h + toString(B))))) | |
64 | 64 | then unit | |
65 | 65 | else throw("Only pool can call this function") | |
66 | 66 | ||
67 | 67 | ||
68 | 68 | func C (D) = [BooleanEntry(a, false), StringEntry(b, D)] | |
69 | 69 | ||
70 | 70 | ||
71 | 71 | func E (F,G) = valueOrElse(getInteger(x, (((F + "_") + G) + f)), 0) | |
72 | 72 | ||
73 | 73 | ||
74 | 74 | func H (F) = valueOrElse(getInteger(x, (F + g)), 0) | |
75 | 75 | ||
76 | 76 | ||
77 | 77 | func I (J,F,K) = valueOrElse(getInteger(this, (((((J + "_") + F) + "_") + K) + d)), 0) | |
78 | 78 | ||
79 | 79 | ||
80 | 80 | func L (F,K) = valueOrElse(getInteger(this, (((F + "_") + K) + c)), 0) | |
81 | 81 | ||
82 | 82 | ||
83 | 83 | func M (J,F,K) = valueOrElse(getInteger(this, (((((J + "_") + F) + "_") + K) + e)), 0) | |
84 | 84 | ||
85 | 85 | ||
86 | 86 | func N (K) = { | |
87 | 87 | let r = K | |
88 | 88 | if ($isInstanceOf(r, "ByteVector")) | |
89 | 89 | then { | |
90 | 90 | let O = r | |
91 | 91 | toBase58String(O) | |
92 | 92 | } | |
93 | 93 | else if ($isInstanceOf(r, "Unit")) | |
94 | 94 | then { | |
95 | 95 | let P = r | |
96 | 96 | "WAVES" | |
97 | 97 | } | |
98 | 98 | else throw("Match error") | |
99 | 99 | } | |
100 | 100 | ||
101 | 101 | ||
102 | 102 | func Q (F,K,J) = { | |
103 | 103 | let R = L(F, K) | |
104 | 104 | let S = I(J, F, K) | |
105 | 105 | let T = E(F, J) | |
106 | 106 | let U = M(J, F, K) | |
107 | 107 | let V = fraction(T, (R - S), n) | |
108 | 108 | $Tuple2((U + V), R) | |
109 | 109 | } | |
110 | 110 | ||
111 | 111 | ||
112 | 112 | func W (F,J) = { | |
113 | 113 | let X = Address(fromBase58String(F)) | |
114 | 114 | let Y = split(valueOrErrorMessage(getString(X, i), "Can't find pool assets"), ",") | |
115 | 115 | func Z (aa,K) = { | |
116 | 116 | let ab = Q(F, K, J) | |
117 | 117 | let ac = ab._1 | |
118 | 118 | let R = ab._2 | |
119 | 119 | (aa :+ [ac]) | |
120 | 120 | } | |
121 | 121 | ||
122 | 122 | let ad = { | |
123 | 123 | let ae = Y | |
124 | 124 | let af = size(ae) | |
125 | 125 | let ag = nil | |
126 | 126 | func ah (ai,aj) = if ((aj >= af)) | |
127 | 127 | then ai | |
128 | 128 | else Z(ai, ae[aj]) | |
129 | 129 | ||
130 | 130 | func ak (ai,aj) = if ((aj >= af)) | |
131 | 131 | then ai | |
132 | 132 | else throw("List size exceeds 15") | |
133 | 133 | ||
134 | 134 | ak(ah(ah(ah(ah(ah(ah(ah(ah(ah(ah(ah(ah(ah(ah(ah(ag, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15) | |
135 | 135 | } | |
136 | 136 | $Tuple2(Y, ad) | |
137 | 137 | } | |
138 | 138 | ||
139 | 139 | ||
140 | 140 | @Callable(al) | |
141 | 141 | func airDrop () = valueOrElse(z(), valueOrElse(A(al.caller), { | |
142 | 142 | let am = $Tuple2(al.payments[0].amount, al.payments[0].assetId) | |
143 | 143 | let an = am._1 | |
144 | 144 | let ao = am._2 | |
145 | 145 | let F = toString(al.caller) | |
146 | 146 | let ap = H(F) | |
147 | 147 | let R = L(F, N(ao)) | |
148 | 148 | let aq = (R + fraction(an, n, ap)) | |
149 | 149 | [IntegerEntry(c, aq)] | |
150 | 150 | })) | |
151 | 151 | ||
152 | 152 | ||
153 | 153 | ||
154 | 154 | @Callable(al) | |
155 | 155 | func updateUserInterest (ar) = valueOrElse(z(), valueOrElse(A(al.caller), { | |
156 | 156 | let X = al.caller | |
157 | 157 | let J = toString(al.originCaller) | |
158 | 158 | let F = toString(X) | |
159 | 159 | let Y = split(valueOrErrorMessage(getString(X, i), "Can't find pool assets"), ",") | |
160 | 160 | func as (aa,K) = { | |
161 | 161 | let at = Q(F, K, J) | |
162 | 162 | let ac = at._1 | |
163 | 163 | let R = at._2 | |
164 | 164 | (aa :+ [IntegerEntry((((((J + "_") + F) + "_") + K) + e), ac), IntegerEntry((((((J + "_") + F) + "_") + K) + d), R)]) | |
165 | 165 | } | |
166 | 166 | ||
167 | 167 | let ae = Y | |
168 | 168 | let af = size(ae) | |
169 | 169 | let ag = nil | |
170 | 170 | func ah (ai,aj) = if ((aj >= af)) | |
171 | 171 | then ai | |
172 | 172 | else as(ai, ae[aj]) | |
173 | 173 | ||
174 | 174 | func ak (ai,aj) = if ((aj >= af)) | |
175 | 175 | then ai | |
176 | 176 | else throw("List size exceeds 15") | |
177 | 177 | ||
178 | 178 | ak(ah(ah(ah(ah(ah(ah(ah(ah(ah(ah(ah(ah(ah(ah(ah(ag, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15) | |
179 | 179 | })) | |
180 | 180 | ||
181 | 181 | ||
182 | 182 | ||
183 | 183 | @Callable(al) | |
184 | 184 | func claim (F) = valueOrElse(z(), { | |
185 | 185 | let X = Address(fromBase58String(F)) | |
186 | 186 | let J = toString(al.caller) | |
187 | 187 | let Y = split(valueOrErrorMessage(getString(X, i), "Can't find pool assets"), ",") | |
188 | 188 | func au (aa,K) = { | |
189 | 189 | let av = aa | |
190 | 190 | let aw = av._1 | |
191 | 191 | let ax = av._2 | |
192 | 192 | let ay = Q(F, K, J) | |
193 | 193 | let ac = ay._1 | |
194 | 194 | let R = ay._2 | |
195 | 195 | $Tuple2((aw :+ [ScriptTransfer(al.caller, ac, fromBase58String(K)), IntegerEntry((((((J + "_") + F) + "_") + K) + e), 0), IntegerEntry((((((J + "_") + F) + "_") + K) + d), R)]), ac) | |
196 | 196 | } | |
197 | 197 | ||
198 | 198 | let az = { | |
199 | 199 | let ae = Y | |
200 | 200 | let af = size(ae) | |
201 | 201 | let ag = $Tuple2(nil, 0) | |
202 | 202 | func ah (ai,aj) = if ((aj >= af)) | |
203 | 203 | then ai | |
204 | 204 | else au(ai, ae[aj]) | |
205 | 205 | ||
206 | 206 | func ak (ai,aj) = if ((aj >= af)) | |
207 | 207 | then ai | |
208 | 208 | else throw("List size exceeds 15") | |
209 | 209 | ||
210 | 210 | ak(ah(ah(ah(ah(ah(ah(ah(ah(ah(ah(ah(ah(ah(ah(ah(ag, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15) | |
211 | 211 | } | |
212 | 212 | let aA = az._1 | |
213 | 213 | let aB = az._2 | |
214 | 214 | if ((aB == 0)) | |
215 | 215 | then throw("You have no tokens for claim") | |
216 | 216 | else aA | |
217 | 217 | }) | |
218 | 218 | ||
219 | 219 | ||
220 | 220 | ||
221 | 221 | @Callable(al) | |
222 | 222 | func shutdown () = if (!(y)) | |
223 | 223 | then throw(("DApp is already suspended. Cause: " + valueOrElse(getString(this, b), "the cause wasn't specified"))) | |
224 | 224 | else if (!(containsElement([u, v, w], al.callerPublicKey))) | |
225 | 225 | then throw("Only admin can call this function") | |
226 | 226 | else C("Paused by admin") | |
227 | 227 | ||
228 | 228 | ||
229 | 229 | ||
230 | 230 | @Callable(al) | |
231 | 231 | func activate () = if (y) | |
232 | 232 | then throw("DApp is already active") | |
233 | 233 | else if (!(containsElement([u, v, w], al.callerPublicKey))) | |
234 | 234 | then throw("Only admin can call this function") | |
235 | 235 | else [BooleanEntry(a, true), DeleteEntry(b)] | |
236 | 236 | ||
237 | 237 | ||
238 | 238 | @Verifier(aC) | |
239 | 239 | func aD () = { | |
240 | 240 | let aE = if (sigVerify(aC.bodyBytes, aC.proofs[0], u)) | |
241 | 241 | then 1 | |
242 | 242 | else 0 | |
243 | 243 | let aF = if (sigVerify(aC.bodyBytes, aC.proofs[1], v)) | |
244 | 244 | then 1 | |
245 | 245 | else 0 | |
246 | 246 | let aG = if (sigVerify(aC.bodyBytes, aC.proofs[2], w)) | |
247 | 247 | then 1 | |
248 | 248 | else 0 | |
249 | 249 | (((aE + aF) + aG) >= 2) | |
250 | 250 | } | |
251 | 251 |
github/deemru/w8io/026f985 29.02 ms ◑