tx · Cf4zs8fS3VHjh5C5t8SNk8SQ2ujTKovFD6KjPpz9pxkF

3N3y7nQfqDc7rBUExjKQi5ZbspWRh9q8PYH:  -0.00200000 Waves

2023.11.17 12:12 [2847168] smart account 3N3y7nQfqDc7rBUExjKQi5ZbspWRh9q8PYH > SELF 0.00000000 Waves

{ "type": 13, "id": "Cf4zs8fS3VHjh5C5t8SNk8SQ2ujTKovFD6KjPpz9pxkF", "fee": 200000, "feeAssetId": null, "timestamp": 1700212365968, "version": 2, "chainId": 84, "sender": "3N3y7nQfqDc7rBUExjKQi5ZbspWRh9q8PYH", "senderPublicKey": "9ggtmbyecVRfUY2zeZhNaoLBp2iymhnQhffXQhemTJaG", "proofs": [ "53c3t9qS72utgxdc864cABnhQq8SUd45QmzTgaQmBQzmtxAbqrPadPJm2jJjBsVcgvBLttCjaqgUf6f33fSkLQ7d" ], "script": "base64:BgIECAISAAkADFRlc3RTQ1B1YktleQEgoVeU11muwc+hUBHN7HeslecfLlzb1kPRfhzSdE7YqzYACFRlc3RVc2VyCQEHQWRkcmVzcwEBGgFUmiSvdpHfcyUoO/Y3lJR5RVM/EC7LIlBGAA5UZXN0VXNlclB1YktleQEggQhA7lSDBAV96QCBw6VWWREBAkOfczsVMMZRMcDjO10ACVRlc3RVc2VyMgkBB0FkZHJlc3MBARoBVNBVQEgvriq5Wd7cAHuvw7N/9YPdF0K61wAPVGVzdFVzZXIyUHViS2V5ASAaFa4tDyIv1uhzDfwRR/IHtg7qNN7P3pYq2N1IFBp+EAATUHV6emxlTWFzdGVyQWRkcmVzcwkBB0FkZHJlc3MBARoBV85X8yTRB6SzTv7SuuIorMWQltaK0W0F7gASUHV6emxlTWFzdGVyUHViS2V5ASA7NU1uP5+++FSclkQHgFarL+ITYEXEe/I/F0P0QgUmXQANYWNjZXNzQWRkcmVzcwkAzAgCBQR0aGlzCQDMCAIFCFRlc3RVc2VyCQDMCAIFCVRlc3RVc2VyMgUDbmlsAAZhY2Nlc3MJAMwIAgUMVGV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dGlvbgYJAAECBQckbWF0Y2gwAhJSZWlzc3VlVHJhbnNhY3Rpb24EA3R0eAUHJG1hdGNoMAkAAAIJAQ9jb250YWluc0VsZW1lbnQCBQ1hY2Nlc3NBZGRyZXNzCAUDdHR4BnNlbmRlcgYHY907+g==", "height": 2847168, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: Gm1pYpHu5Wsovqg8f6Rofb5zvFQQwhBZhc6CF5eqDwJ4 Next: 6KnG2oLavkjwq6H87xNeVZh2oGs8AdJ4ptH9RU84TLan Full:
OldNewDifferences
11 {-# STDLIB_VERSION 6 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
4-let a = ["1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19", "20", "21", "22", "23", "24", "25", "26", "27", "28", "29", "30", "31", "32", "33", "34", "35", "36", "37", "38", "39", "40", "41", "42", "43", "44", "45", "46", "47", "48", "49", "50", "51", "52", "53", "55", "56"]
4+let a = base58'Brp6cacBXyKUcZr5Uc6VDKsnFcaEeQ8nQzrZQyobDsuf'
55
6-let b = 1
6+let b = Address(base58'3N3y7nQfqDc7rBUExjKQi5ZbspWRh9q8PYH')
77
8-let c = 10
8+let c = base58'9ggtmbyecVRfUY2zeZhNaoLBp2iymhnQhffXQhemTJaG'
99
10-func d (e) = {
11- let f = getInteger(this, e)
12- if ($isInstanceOf(f, "Int"))
13- then {
14- let g = f
15- g
16- }
17- else 0
18- }
10+let d = Address(base58'3N8ueTAufEUYDKWJDbfK7aZ4HHxBkX4DXA6')
11+
12+let e = base58'2kpmuzw1ZbrtgAN3BrR7vbEW1XrJoJKCstL7mf7XNf2P'
13+
14+let f = Address(base58'3PLjwHcz9NEuaTo63NZR9B9okQiKQxZSbmf')
15+
16+let g = base58'4z8CKSYQBKkzx7PBb5uBP1YPa6YAHRNTApW1sQVHT5eU'
17+
18+let h = [this, b, d]
19+
20+let i = [a, c, e]
21+
22+@Callable(j)
23+func activate () = [IntegerEntry(if ((j.caller == this))
24+ then "Activated blockheight"
25+ else "Activated by anybody blockheight", height)]
1926
2027
21-func h (e) = {
22- let f = getString(this, e)
23- if ($isInstanceOf(f, "String"))
28+@Verifier(k)
29+func l () = {
30+ let m = k
31+ if (if ($isInstanceOf(m, "Order"))
32+ then true
33+ else if ($isInstanceOf(m, "DataTransaction"))
34+ then true
35+ else if ($isInstanceOf(m, "SponsorFeeTransaction"))
36+ then true
37+ else if ($isInstanceOf(m, "SetScriptTransaction"))
38+ then true
39+ else if ($isInstanceOf(m, "CreateAliasTransaction"))
40+ then true
41+ else if ($isInstanceOf(m, "LeaseCancelTransaction"))
42+ then true
43+ else if ($isInstanceOf(m, "LeaseTransaction"))
44+ then true
45+ else if ($isInstanceOf(m, "IssueTransaction"))
46+ then true
47+ else if ($isInstanceOf(m, "InvokeExpressionTransaction"))
48+ then true
49+ else if ($isInstanceOf(m, "UpdateAssetInfoTransaction"))
50+ then true
51+ else if ($isInstanceOf(m, "InvokeScriptTransaction"))
52+ then true
53+ else if ($isInstanceOf(m, "SetAssetScriptTransaction"))
54+ then true
55+ else if ($isInstanceOf(m, "TransferTransaction"))
56+ then true
57+ else if ($isInstanceOf(m, "ExchangeTransaction"))
58+ then true
59+ else if ($isInstanceOf(m, "MassTransferTransaction"))
60+ then true
61+ else if ($isInstanceOf(m, "BurnTransaction"))
62+ then true
63+ else $isInstanceOf(m, "ReissueTransaction"))
2464 then {
25- let g = f
26- g
65+ let n = m
66+ (containsElement(h, n.sender) == true)
2767 }
28- else ""
68+ else false
2969 }
30-
31-
32-func i (j) = {
33- let f = j
34- if ($isInstanceOf(f, "ByteVector"))
35- then {
36- let g = f
37- toBase58String(g)
38- }
39- else "WAVES"
40- }
41-
42-
43-func k (l) = if ((l == "WAVES"))
44- then unit
45- else fromBase58String(l)
46-
47-
48-func m (n) = {
49- let o = d((("boosting_" + n) + "_lastHeight"))
50- let p = d((("boosting_" + n) + "_finishHeight"))
51- if (if ((o != 0))
52- then (p > o)
53- else false)
54- then {
55- let q = (d((("boosting_" + n) + "_totalAmount")) / ((d((("boosting_" + n) + "_days")) * b) * c))
56- let r = fraction((min([p, height]) - o), q, 1)
57- let s = h((("boosting_" + n) + "_poolId"))
58- let t = h((("pool_" + s) + "_boostings"))
59- let u = size(t)
60- let v = value(indexOf(t, n))
61- let w = if ((v == 0))
62- then 0
63- else 1
64- let x = if ((v == 0))
65- then 2
66- else 1
67- let y = take(t, (u - ((u - v) + w)))
68- let z = takeRight(t, (u - (v + x)))
69- let A = (y + z)
70-[IntegerEntry((("boosting_" + n) + "_lastHeight"), height), ScriptTransfer(addressFromStringValue(h((("boosting_" + n) + "_poolId"))), r, k(h((("boosting_" + n) + "_assetId")))), StringEntry((("pool_" + s) + "_boostings"), if ((p > height))
71- then h((("pool_" + s) + "_boostings"))
72- else A)]
73- }
74- else nil
75- }
76-
77-
78-func B (n) = {
79- let o = d((("boosting_" + n) + "_lastHeight"))
80- let p = d((("boosting_" + n) + "_finishHeight"))
81- if ((o >= p))
82- then [StringEntry((("list ended " + toString(height)) + " boostingIds"), ((h((("list ended " + toString(height)) + " boostingIds")) + n) + ","))]
83- else [StringEntry((("list ongoing boosts " + toString(height)) + " boostingIds"), ((h((("list ongoing boosts " + toString(height)) + " boostingIds")) + n) + ","))]
84- }
85-
86-
87-@Callable(C)
88-func addBoosting (D,E) = if ((1 > E))
89- then throw("amount of days has to be between 1 and 365")
90- else if ((E > 365))
91- then throw("amount of days has to be between 1 and 365")
92- else if (false)
93- then throw("under maintenance until further notice")
94- else {
95- let F = C.payments[0].amount
96- if ((1440 > (F / E)))
97- then throw((("boosting amount too small, minimum is " + toString((1440 * E))) + " of the smallest unit of payment asset"))
98- else {
99- let j = i(C.payments[0].assetId)
100- if ((height == d("height")))
101- then throw("wait 1 minute")
102- else {
103- let G = if ((size(h((("pool_" + D) + "_boostings"))) > 11))
104- then throw("max 5 boosts per pool")
105- else invoke(this, "entryEnded", nil, nil)
106- if ((G == G))
107- then {
108- let n = if ((size((("list ongoing boosts " + toString(height)) + " boostingIds")) > 112))
109- then throw("wait till other boosts are finished")
110- else take(h((("list ended " + toString(height)) + " boostingIds")), 1)
111- if ((addressFromString(D) == unit))
112- then throw("incorrect pool address")
113- else [IntegerEntry((("boosting_" + n) + "_days"), E), IntegerEntry((("boosting_" + n) + "_totalAmount"), F), IntegerEntry((("boosting_" + n) + "_dailyAmount"), (F / E)), IntegerEntry((("boosting_" + n) + "_startHeight"), height), IntegerEntry((("boosting_" + n) + "_finishHeight"), (height + ((E * b) * c))), IntegerEntry((("boosting_" + n) + "_finishTimestamp"), (lastBlock.timestamp + ((((E * b) * c) * 60) * 1000))), IntegerEntry((("boosting_" + n) + "_lastHeight"), height), StringEntry((("boosting_" + n) + "_assetId"), j), StringEntry((("boosting_" + n) + "_owner"), toString(C.caller)), StringEntry((("boosting_" + n) + "_poolId"), D), StringEntry((("pool_" + D) + "_boostings"), ((h((("pool_" + D) + "_boostings")) + n) + ","))]
114- }
115- else throw("Strict value is not equal to itself.")
116- }
117- }
118- }
119-
120-
121-
122-@Callable(C)
123-func payBoosting (n) = m(n)
124-
125-
126-
127-@Callable(C)
128-func payBoostings () = {
129- func H (I,J) = {
130- let K = invoke(this, "payBoosting", [J], nil)
131- if ((K == K))
132- then K
133- else throw("Strict value is not equal to itself.")
134- }
135-
136- let L = {
137- let M = a
138- let N = size(M)
139- let O = 0
140- func P (Q,R) = if ((R >= N))
141- then Q
142- else H(Q, M[R])
143-
144- func S (Q,R) = if ((R >= N))
145- then Q
146- else throw("List size exceeds 56")
147-
148- S(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(O, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20), 21), 22), 23), 24), 25), 26), 27), 28), 29), 30), 31), 32), 33), 34), 35), 36), 37), 38), 39), 40), 41), 42), 43), 44), 45), 46), 47), 48), 49), 50), 51), 52), 53), 54), 55), 56)
149- }
150- if ((L == L))
151- then nil
152- else throw("Strict value is not equal to itself.")
153- }
154-
155-
156-
157-@Callable(C)
158-func endedBoostings (n) = B(n)
159-
160-
161-
162-@Callable(C)
163-func entryEnded () = {
164- func H (I,J) = {
165- let K = invoke(this, "endedBoostings", [J], nil)
166- if ((K == K))
167- then K
168- else throw("Strict value is not equal to itself.")
169- }
170-
171- let T = {
172- let M = a
173- let N = size(M)
174- let O = 0
175- func P (Q,R) = if ((R >= N))
176- then Q
177- else H(Q, M[R])
178-
179- func S (Q,R) = if ((R >= N))
180- then Q
181- else throw("List size exceeds 56")
182-
183- S(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(P(O, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20), 21), 22), 23), 24), 25), 26), 27), 28), 29), 30), 31), 32), 33), 34), 35), 36), 37), 38), 39), 40), 41), 42), 43), 44), 45), 46), 47), 48), 49), 50), 51), 52), 53), 54), 55), 56)
184- }
185- if ((T == T))
186- then [IntegerEntry("height", height)]
187- else throw("Strict value is not equal to itself.")
188- }
189-
190-
191-
192-@Callable(C)
193-func deleteEntr (D) = [DeleteEntry((("pool_" + D) + "_boostings"))]
194-
195-
196-
197-@Callable(C)
198-func checkStr (n) = {
199- let U = h((("boosting_" + n) + "_poolId"))
200- let t = h((("pool_" + U) + "_boostings"))
201- let u = size(t)
202- if ((indexOf(t, n) == unit))
203- then nil
204- else {
205- let v = value(indexOf(t, n))
206- let x = if ((v == 0))
207- then 2
208- else 1
209- let w = if ((v == 0))
210- then 0
211- else 1
212- let V = (take(t, (u - ((u - v) + w))) + takeRight(t, (u - (v + x))))
213-[StringEntry("getFinishedPoolId", U), StringEntry("getPoolBoostings", t), IntegerEntry("findIndex", v), IntegerEntry("sizeStr", u), StringEntry("left string", take(t, (u - (u - v)))), StringEntry("right string", takeRight(t, (u - (v + x)))), StringEntry((("pool_" + U) + "_boostings"), V)]
214- }
215- }
216-
217-
218-
219-@Callable(C)
220-func remove (n) = {
221- let s = h((("boosting_" + n) + "_poolId"))
222- let t = h((("pool_" + s) + "_boostings"))
223- let u = size(t)
224- let v = value(indexOf(t, n))
225- let w = if ((v == 0))
226- then 0
227- else 1
228- let x = if ((v == 0))
229- then 2
230- else 1
231- let y = take(t, (u - ((u - v) + w)))
232- let z = takeRight(t, (u - (v + x)))
233- let A = (y + z)
234-[StringEntry("getFinishedPoolId", s), StringEntry("getPoolBoostings", t), IntegerEntry("findIndex", v), IntegerEntry("sizeStr", u), StringEntry("left string", y), StringEntry("right string", z), StringEntry("openBoostingsIds", A), StringEntry((("pool_" + s) + "_boostings"), A)]
235- }
236-
23770

github/deemru/w8io/169f3d6 
41.02 ms