tx · B55Cz3nd9dYbnwi6sEZtbGgAGsxX65uZeBxJJaHF2wcc 3NCUHuSn2Xb5YRp8xtCCr5uJvHswERvbAM3: -0.01000000 Waves 2020.06.09 11:08 [1035578] smart account 3NCUHuSn2Xb5YRp8xtCCr5uJvHswERvbAM3 > SELF 0.00000000 Waves
{ "type": 13, "id": "B55Cz3nd9dYbnwi6sEZtbGgAGsxX65uZeBxJJaHF2wcc", "fee": 1000000, "feeAssetId": null, "timestamp": 1591690166665, "version": 1, "sender": "3NCUHuSn2Xb5YRp8xtCCr5uJvHswERvbAM3", "senderPublicKey": "AyG1AxMM25EF4Tp6aofMdCuc8U2tgPWx4x68Y7FmVE2d", "proofs": [ "4hNuxkm2mAFvYw7oJK5mo2EKqoD5KnRbRsSiSLHvxSvVE1HMvZH1Ke8pBY1ptTrmJ3WCiQ2DvPLSHqPviSSpLgZ4" ], "script": "base64:AAIDAAAAAAAAAAcIARIDCgEIAAAAFgAAAAALYWRkcmVzc0Jvb2sJAQAAAAdBZGRyZXNzAAAAAQEAAAAaAVRWgdR5NBM7vuJoxo7QLI34uXJ2wFdvAd4AAAAAE3doaXRlbGlzdEFkZHJlc3NLZXkCAAAAEHdoaXRlbGlzdEFkZHJlc3MAAAAAF2RBcHBXaGl0ZWxpc3RBZGRyZXNzS2V5AgAAABRkQXBwV2hpdGVsaXN0QWRkcmVzcwAAAAAOY29lZmZpY2llbnRLZXkCAAAAC2NvZWZmaWNpZW50AAAAABBkaXZpZGVuZHNBc3NldElkAQAAACCvOUhH768SCeA6PrRTnXQmq/k9bwVLiF0VD6knNWeEWAAAAAAVZGl2aWRlbmRzQXNzZXRJc1dhdmVzBwAAAAAbc2VjdXJpdHlBc3NldERlY2ltYWxzT2Zmc2V0AAAAAAAF9eEAAAAAAAlzdGFydFRpbWUAAAAAAF7tJ1AAAAAAB2VuZFRpbWUAAAAAAGDOWtAAAAAAA3ZlcgIAAAAFNS4wLjEAAAAACnZhbGlkU3RhdGUAAAAAAAAAA+gAA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mVkBQAAAAtwS2V5M1NpZ25lZAUAAAALcEtleTRTaWduZWQFAAAAC3BLZXk1U2lnbmVkBQAAAAtwS2V5NlNpZ25lZAUAAAALcEtleTdTaWduZWQFAAAAC3BLZXk4U2lnbmVkAAAAAAAAAAADAwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAAA9EYXRhVHJhbnNhY3Rpb24EAAAAAnR4BQAAAAckbWF0Y2gwCQAB9AAAAAMIBQAAAAJ0eAAAAAlib2R5Qnl0ZXMJAAGRAAAAAggFAAAAAnR4AAAABnByb29mcwAAAAAAAAAAAAgFAAAAAnR4AAAAD3NlbmRlclB1YmxpY0tleQc4X+d3", "chainId": 84, "height": 1035578, "spentComplexity": 0 } View: original | compacted Prev: none Next: none Full:
Old | New | Differences | |
---|---|---|---|
1 | - | # no script | |
1 | + | {-# STDLIB_VERSION 3 #-} | |
2 | + | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | + | {-# CONTENT_TYPE DAPP #-} | |
4 | + | let a = Address(base58'3MwoVRAPfC2NKuuYJKHVAVtUFhq8MyTEfQh') | |
5 | + | ||
6 | + | let b = "whitelistAddress" | |
7 | + | ||
8 | + | let c = "dAppWhitelistAddress" | |
9 | + | ||
10 | + | let d = "coefficient" | |
11 | + | ||
12 | + | let e = base58'Co11Tbj83TeZCnuXrZQwv6Bs4XG2sm1vGQiQ4FLDjJWs' | |
13 | + | ||
14 | + | let f = false | |
15 | + | ||
16 | + | let g = 100000000 | |
17 | + | ||
18 | + | let h = 1592600400 | |
19 | + | ||
20 | + | let i = 1624136400 | |
21 | + | ||
22 | + | let j = "5.0.1" | |
23 | + | ||
24 | + | let k = 1000 | |
25 | + | ||
26 | + | let l = (lastBlock.timestamp / 1000) | |
27 | + | ||
28 | + | func m () = (l >= h) | |
29 | + | ||
30 | + | ||
31 | + | func n () = (l > i) | |
32 | + | ||
33 | + | ||
34 | + | func o (p) = { | |
35 | + | let q = getString(a, p) | |
36 | + | if ($isInstanceOf(q, "String")) | |
37 | + | then { | |
38 | + | let r = q | |
39 | + | Address(fromBase58String(r)) | |
40 | + | } | |
41 | + | else throw("no key") | |
42 | + | } | |
43 | + | ||
44 | + | ||
45 | + | func s (p) = { | |
46 | + | let q = getInteger(this, p) | |
47 | + | if ($isInstanceOf(q, "Int")) | |
48 | + | then { | |
49 | + | let r = q | |
50 | + | r | |
51 | + | } | |
52 | + | else 0 | |
53 | + | } | |
54 | + | ||
55 | + | ||
56 | + | func t (p) = { | |
57 | + | let q = getBoolean(this, p) | |
58 | + | if ($isInstanceOf(q, "Boolean")) | |
59 | + | then { | |
60 | + | let r = q | |
61 | + | r | |
62 | + | } | |
63 | + | else false | |
64 | + | } | |
65 | + | ||
66 | + | ||
67 | + | func u (v,w) = if ((v == false)) | |
68 | + | then w | |
69 | + | else unit | |
70 | + | ||
71 | + | ||
72 | + | func x (y,z) = if ((size(y) > 10)) | |
73 | + | then y | |
74 | + | else z | |
75 | + | ||
76 | + | ||
77 | + | let A = o(b) | |
78 | + | ||
79 | + | let B = o(c) | |
80 | + | ||
81 | + | let C = u(f, e) | |
82 | + | ||
83 | + | @Callable(D) | |
84 | + | func withdrawal (E) = { | |
85 | + | let F = { | |
86 | + | let q = getInteger(B, toString(this)) | |
87 | + | if ($isInstanceOf(q, "Int")) | |
88 | + | then { | |
89 | + | let r = q | |
90 | + | r | |
91 | + | } | |
92 | + | else 0 | |
93 | + | } | |
94 | + | let G = x(E, toString(D.caller)) | |
95 | + | let H = extract(addressFromString(G)) | |
96 | + | let I = (("address_" + G) + "_tokens") | |
97 | + | let J = (("address_" + G) + "_paid") | |
98 | + | let K = (("address_" + G) + "_paidAmount") | |
99 | + | let L = s(I) | |
100 | + | let M = t(J) | |
101 | + | if ((F != 1)) | |
102 | + | then throw("#001 dApp is not active") | |
103 | + | else if (!(m())) | |
104 | + | then throw("#002 dApp has not started yet") | |
105 | + | else if (n()) | |
106 | + | then throw("#003 dApp already completed") | |
107 | + | else if ((L == 0)) | |
108 | + | then throw("#005 This account does not have dividends to recieve.") | |
109 | + | else if ((M == true)) | |
110 | + | then throw("#006 This account has already received dividends.") | |
111 | + | else { | |
112 | + | let N = s(d) | |
113 | + | let O = fraction(L, N, g) | |
114 | + | ScriptResult(WriteSet([DataEntry(J, true), DataEntry(K, O)]), TransferSet([ScriptTransfer(H, O, C)])) | |
115 | + | } | |
116 | + | } | |
117 | + | ||
118 | + | ||
119 | + | @Verifier(P) | |
120 | + | func Q () = { | |
121 | + | let q = P | |
122 | + | if ($isInstanceOf(q, "SetScriptTransaction")) | |
123 | + | then { | |
124 | + | let P = q | |
125 | + | let R = toBase58String(P.id) | |
126 | + | let S = o("pAddress1") | |
127 | + | let T = o("pAddress2") | |
128 | + | let U = o("pAddress3") | |
129 | + | let V = o("pAddress4") | |
130 | + | let W = o("pAddress5") | |
131 | + | let X = o("pAddress6") | |
132 | + | let Y = o("pAddress7") | |
133 | + | let Z = o("pAddress8") | |
134 | + | let aa = if (isDefined(getInteger(S, R))) | |
135 | + | then 1 | |
136 | + | else 0 | |
137 | + | let ab = if (isDefined(getInteger(T, R))) | |
138 | + | then 1 | |
139 | + | else 0 | |
140 | + | let ac = if (isDefined(getInteger(U, R))) | |
141 | + | then 1 | |
142 | + | else 0 | |
143 | + | let ad = if (isDefined(getInteger(V, R))) | |
144 | + | then 1 | |
145 | + | else 0 | |
146 | + | let ae = if (isDefined(getInteger(W, R))) | |
147 | + | then 1 | |
148 | + | else 0 | |
149 | + | let af = if (isDefined(getInteger(X, R))) | |
150 | + | then 1 | |
151 | + | else 0 | |
152 | + | let ag = if (isDefined(getInteger(Y, R))) | |
153 | + | then 1 | |
154 | + | else 0 | |
155 | + | let ah = if (isDefined(getInteger(Z, R))) | |
156 | + | then 1 | |
157 | + | else 0 | |
158 | + | ((((((((aa + ab) + ac) + ad) + ae) + af) + ag) + ah) >= 3) | |
159 | + | } | |
160 | + | else if ($isInstanceOf(q, "DataTransaction")) | |
161 | + | then { | |
162 | + | let P = q | |
163 | + | sigVerify(P.bodyBytes, P.proofs[0], P.senderPublicKey) | |
164 | + | } | |
165 | + | else false | |
166 | + | } | |
167 | + |
github/deemru/w8io/169f3d6 20.24 ms ◑