tx · 4xHqEuumEC4hhveU4qx7x2u65Kmx3Q27bfqgD533H3x4

3MzT6Lr8UBLvCnz1rU1KeRc5xws5SSGiFpT:  -0.01000000 Waves

2024.10.07 20:27 [3316721] smart account 3MzT6Lr8UBLvCnz1rU1KeRc5xws5SSGiFpT > SELF 0.00000000 Waves

{ "type": 13, "id": "4xHqEuumEC4hhveU4qx7x2u65Kmx3Q27bfqgD533H3x4", "fee": 1000000, "feeAssetId": null, "timestamp": 1728322125019, "version": 2, "chainId": 84, "sender": "3MzT6Lr8UBLvCnz1rU1KeRc5xws5SSGiFpT", "senderPublicKey": "GdxgUF82GpaMfqBobwBoNB8zb1whsmo2NpiZVc7JiNeC", "proofs": [ "2qLycUGEVb3Q3QtDNJpVon5EdovpMnn4vvuEKVSUNXZdcb7PVRWbLJgZHN4q1Vro1uwFVWiJECBsyWAWUfYtjkFk" ], "script": "base64:AAIFAAAAAAAAABIIAhIDCgEIEgQKAggBEgMKAQgAAAAJAQAAAAdnZXRCb29sAAAAAQAAAANrZXkEAAAAByRtYXRjaDAJAAQbAAAAAgUAAAAEdGhpcwUAAAADa2V5AwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAAAdCb29sZWFuBAAAAAFiBQAAAAckbWF0Y2gwBQAAAAFiBwEAAAAJaXNUZXN0RW52AAAAAAkBAAAAB2dldEJvb2wAAAABAgAAAAdURVNURU5WAQAAABdzdGF0aWNLZXlfb3JhY2xlQWRkcmVzcwAAAAACAAAAFHN0YXRpY19vcmFjbGVBZGRyZXNzAQAAABRzdGF0aWNLZXlfYW1tQWRkcmVzcwAAAAACAAAAEXN0YXRpY19hbW1BZGRyZXNzAQAAAAlnZXRPcmFjbGUAAAAACQEAAAAHQWRkcmVzcwAAAAEJAAJZAAAAAQkBAAAAEUBleHRyTmF0aXZlKDEwNTMpAAAAAgUAAAAEdGhpcwkBAAAAF3N0YXRpY0tleV9vcmFjbGVBZGRyZXNzAAAAAAEAAAANZ2V0QXNzZXRCeXRlcwAAAAEA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AAAAl0aGlyZFVzZXIAAAAAAAAAAAEDCQAB9AAAAAMIBQAAAAJ0eAAAAAlib2R5Qnl0ZXMJAAGRAAAAAggFAAAAAnR4AAAABnByb29mcwAAAAAAAAAAAgUAAAAJdGhpcmRVc2VyAAAAAAAAAAABAAAAAAAAAAAABAAAAA9zaWduYXR1cmVzQ291bnQJAABkAAAAAgkAAGQAAAACBQAAAA9maXJzdFVzZXJTaWduZWQFAAAAEHNlY29uZFVzZXJTaWduZWQFAAAAD3RoaXJkVXNlclNpZ25lZAQAAAAHJG1hdGNoMAUAAAACdHgJAABnAAAAAgUAAAAPc2lnbmF0dXJlc0NvdW50AAAAAAAAAAACwd2VCQ==", "height": 3316721, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: none Next: none Full:
OldNewDifferences
1-# no script
1+{-# STDLIB_VERSION 5 #-}
2+{-# SCRIPT_TYPE ACCOUNT #-}
3+{-# CONTENT_TYPE DAPP #-}
4+func a (b) = {
5+ let c = getBoolean(this, b)
6+ if ($isInstanceOf(c, "Boolean"))
7+ then {
8+ let d = c
9+ d
10+ }
11+ else false
12+ }
13+
14+
15+func e () = a("TESTENV")
16+
17+
18+func f () = "static_oracleAddress"
19+
20+
21+func g () = "static_ammAddress"
22+
23+
24+func h () = Address(fromBase58String(getStringValue(this, f())))
25+
26+
27+func i (j) = if ((j == "WAVES"))
28+ then unit
29+ else fromBase58String(j)
30+
31+
32+func k (l) = {
33+ let c = l
34+ if ($isInstanceOf(c, "ByteVector"))
35+ then {
36+ let m = c
37+ assetBalance(this, m)
38+ }
39+ else wavesBalance(this).available
40+ }
41+
42+
43+func n (o,p) = (o ++ [i(p)])
44+
45+
46+func q (r) = {
47+ let s = getStringValue(h(), g())
48+ let t = split(s, ",")
49+ if (containsElement(t, r))
50+ then value(addressFromString(r))
51+ else throw("BCO: AMM not found")
52+ }
53+
54+
55+@Callable(u)
56+func generateAndStakeIndex (r) = {
57+ let v = q(r)
58+ let w = {
59+ let x = split(getStringValue(v, "static_tokenIds"), ",")
60+ let y = size(x)
61+ let z = nil
62+ func A (B,C) = if ((C >= y))
63+ then B
64+ else n(B, x[C])
65+
66+ func D (B,C) = if ((C >= y))
67+ then B
68+ else throw("List size exceeds 10")
69+
70+ D(A(A(A(A(A(A(A(A(A(A(z, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10)
71+ }
72+ let E = i(getStringValue(v, "static_baseTokenId"))
73+ let F = removeByIndex(w, value(indexOf(w, E)))
74+ let G = getBinaryValue(v, "global_poolToken_id")
75+ let H = {
76+ let c = reentrantInvoke(v, "generateIndex", [true], u.payments)
77+ if ($isInstanceOf(c, "Int"))
78+ then {
79+ let I = c
80+ I
81+ }
82+ else 0
83+ }
84+ if ((H == H))
85+ then {
86+ let J = reentrantInvoke(v, "stakeIndex", nil, [AttachedPayment(G, H)])
87+ if ((J == J))
88+ then nil
89+ else throw("Strict value is not equal to itself.")
90+ }
91+ else throw("Strict value is not equal to itself.")
92+ }
93+
94+
95+
96+@Callable(u)
97+func unstakeAndRedeemIndex (r,K) = {
98+ let v = q(r)
99+ let w = {
100+ let x = split(getStringValue(v, "static_tokenIds"), ",")
101+ let y = size(x)
102+ let z = nil
103+ func A (B,C) = if ((C >= y))
104+ then B
105+ else n(B, x[C])
106+
107+ func D (B,C) = if ((C >= y))
108+ then B
109+ else throw("List size exceeds 10")
110+
111+ D(A(A(A(A(A(A(A(A(A(A(z, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10)
112+ }
113+ let E = i(getStringValue(v, "static_baseTokenId"))
114+ let F = removeByIndex(w, value(indexOf(w, E)))
115+ let G = getBinaryValue(v, "global_poolToken_id")
116+ let L = reentrantInvoke(v, "unstakeIndex", [K], u.payments)
117+ if ((L == L))
118+ then {
119+ let M = reentrantInvoke(v, "redeemIndex", [true], [AttachedPayment(G, K)])
120+ if ((M == M))
121+ then nil
122+ else throw("Strict value is not equal to itself.")
123+ }
124+ else throw("Strict value is not equal to itself.")
125+ }
126+
127+
128+
129+@Callable(u)
130+func configureOracle (N) = if ((u.caller != this))
131+ then throw("BCO: admin only")
132+ else [StringEntry(f(), N)]
133+
134+
135+@Verifier(O)
136+func P () = if (e())
137+ then sigVerify(O.bodyBytes, O.proofs[0], O.senderPublicKey)
138+ else {
139+ let Q = base58'6TdaXEfhnjYquvPf3yV7MFxt2CbgFmaqsvGwkKfXtKi4'
140+ let R = base58'7DsP2WaMLocbHuUxux7pbXRjTrrZ1TFQPsi5QumS3gr8'
141+ let S = base58'BpFWP3p3JgYrrP45xfrKzeMcWMEXoinj4FVPPkUiA8D3'
142+ let T = if (sigVerify(O.bodyBytes, O.proofs[0], Q))
143+ then 1
144+ else if (sigVerify(O.bodyBytes, O.proofs[1], Q))
145+ then 1
146+ else if (sigVerify(O.bodyBytes, O.proofs[2], Q))
147+ then 1
148+ else 0
149+ let U = if (sigVerify(O.bodyBytes, O.proofs[0], R))
150+ then 1
151+ else if (sigVerify(O.bodyBytes, O.proofs[1], R))
152+ then 1
153+ else if (sigVerify(O.bodyBytes, O.proofs[2], R))
154+ then 1
155+ else 0
156+ let V = if (sigVerify(O.bodyBytes, O.proofs[0], S))
157+ then 1
158+ else if (sigVerify(O.bodyBytes, O.proofs[1], S))
159+ then 1
160+ else if (sigVerify(O.bodyBytes, O.proofs[2], S))
161+ then 1
162+ else 0
163+ let W = ((T + U) + V)
164+ let c = O
165+ (W >= 2)
166+ }
167+

github/deemru/w8io/026f985 
17.42 ms