tx · BmgcgxssVLPeLLrj4APW3dinkwgLQz1smNpZnu3G34J9 3NAVsUiHMQhkX4keYNiV59vmRTzsnvCTA4a: -0.01400000 Waves 2020.10.19 23:21 [1227930] smart account 3NAVsUiHMQhkX4keYNiV59vmRTzsnvCTA4a > SELF 0.00000000 Waves
{ "type": 13, "id": "BmgcgxssVLPeLLrj4APW3dinkwgLQz1smNpZnu3G34J9", "fee": 1400000, "feeAssetId": null, "timestamp": 1603138960678, "version": 2, "chainId": 84, "sender": "3NAVsUiHMQhkX4keYNiV59vmRTzsnvCTA4a", "senderPublicKey": "7rC1eUHm39ujzNxeYHmmZia2bTsJ1Un38mzD1QHNVwUN", "proofs": [ "XQJDEgmDznvK22eFPMG8AhxEZfRMdvRVvw512duY65T9cN3U7zXmHHe3DwrYajteDVL3to1uPkW5mrAVnzzqNms" ], "script": "base64:AAIEAAAAAAAAABEIAhIDCgEIEgMKAQgSAwoBCAAAAA0AAAAAAXYBAAAAIEog5FEp0a5b61Us9FxZZv7TFazObMUmFN4GJ9vOqfk7AAAAAAFvAQAAACBlwAgSzsM+70d8C1Jb3wzHWPTczpzKAVyB9scXCgMiOwAAAAABbAIAAAAjM04yaEhhcUVFWGpGSEU1RzhOVHc2djdLTk13Y0hvYjJFbmEAAAAAAWYAAAAAAAAAAAoAAAAAAXAAAAAAAAAAB9AAAAAAA3ByMQAAAAAAAAABLAAAAAADcHIyAAAAAAAAAADIAAAAAANwcjMAAAAAAAAAAGQAAAAAAWgFAAAABmhlaWdodAEAAAAMZ2V0U3RhdGlzdGljAAAAAAQAAAAHJG1hdGNoMAkABB0AAAACBQAAAAR0aGlzAgAAAAlzdGF0aXN0aWMDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAABlN0cmluZwQAAAABYQUAAAAHJG1hdGNoMAUAAAABYQkAASwAAAACAgAAABQwXzBfMF8wXzBfMF8wXzBfMF8wXwkAAaQAAAABBQAAAAFoAQAAAAdnZXRVc2VyAAAAAgAAAAF1AAAAAXIEAAA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QABkQAAAAIFAAAAAXMAAAAAAAAAAAIJAARMAAAAAgkAAZEAAAACBQAAAAFzAAAAAAAAAAADCQAETAAAAAIJAAGRAAAAAgUAAAABcwAAAAAAAAAABAkABEwAAAACCQABkQAAAAIFAAAAAXMAAAAAAAAAAAUJAARMAAAAAgkAAZEAAAACBQAAAAFzAAAAAAAAAAAGCQAETAAAAAIJAAGRAAAAAgUAAAABcwAAAAAAAAAABwkABEwAAAACCQABkQAAAAIFAAAAAXMAAAAAAAAAAAgJAARMAAAAAgkAAZEAAAACBQAAAAFzAAAAAAAAAAAJCQAETAAAAAIJAAGRAAAAAgUAAAABcwAAAAAAAAAACgUAAAADbmlsAgAAAAFfCQAETAAAAAIJAQAAAA5TY3JpcHRUcmFuc2ZlcgAAAAMIBQAAAAFpAAAABmNhbGxlcgUAAAABeQUAAAABdgUAAAADbmlsAAAAAQAAAAJ0eAEAAAAGdmVyaWZ5AAAAAAQAAAAHJG1hdGNoMAUAAAACdHgDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAAFFNldFNjcmlwdFRyYW5zYWN0aW9uBAAAAAFkBQAAAAckbWF0Y2gwCQAB9AAAAAMIBQAAAAJ0eAAAAAlib2R5Qnl0ZXMJAAGRAAAAAggFAAAAAnR4AAAABnByb29mcwAAAAAAAAAAAAUAAAABbwbqTlXl", "height": 1227930, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: Dpv3NJ76Fz7aTeyHLznRE8eYGk7QNSkAda6Fa8eNZeK4 Next: 4ZjNiPmXjMJsQkZNuiPia6CnELj3mu9z4iBe1RTL7rg4 Diff:
Old | New | Differences | |
---|---|---|---|
9 | 9 | ||
10 | 10 | let f = 10 | |
11 | 11 | ||
12 | - | let p = | |
12 | + | let p = 2000 | |
13 | 13 | ||
14 | - | let pr1 = | |
14 | + | let pr1 = 300 | |
15 | 15 | ||
16 | - | let pr2 = | |
16 | + | let pr2 = 200 | |
17 | 17 | ||
18 | - | let pr3 = 1 | |
18 | + | let pr3 = 100 | |
19 | + | ||
20 | + | let h = height | |
19 | 21 | ||
20 | 22 | func getStatistic () = match getString(this, "statistic") { | |
21 | 23 | case a: String => | |
22 | 24 | a | |
23 | 25 | case _ => | |
24 | - | "0_0_0_0_0_0_0_0_0" | |
26 | + | ("0_0_0_0_0_0_0_0_0_0_" + toString(h)) | |
25 | 27 | } | |
26 | 28 | ||
27 | 29 | ||
28 | - | func getUser ( | |
30 | + | func getUser (u,r) = match getString(this, u) { | |
29 | 31 | case a: String => | |
30 | 32 | a | |
31 | 33 | case _ => | |
32 | - | "0_0_0_0_0_0_0 | |
34 | + | makeString(["0_0_0_0_0_0_0", r, "0_0_0_0"], "_") | |
33 | 35 | } | |
36 | + | ||
37 | + | ||
38 | + | func getReferral (r) = { | |
39 | + | let z = split(r, "referral:") | |
40 | + | if (isDefined(z[1])) | |
41 | + | then if (isDefined(addressFromString(z[1]))) | |
42 | + | then z[1] | |
43 | + | else "0" | |
44 | + | else "0" | |
45 | + | } | |
34 | 46 | ||
35 | 47 | ||
36 | 48 | func getWithdraw (s) = { | |
44 | 56 | ||
45 | 57 | ||
46 | 58 | @Callable(i) | |
47 | - | func deposit ( | |
59 | + | func deposit (r) = { | |
48 | 60 | let t = value(i.payments[0]) | |
49 | 61 | let z = t.amount | |
50 | 62 | let k = match t.assetId { | |
55 | 67 | } | |
56 | 68 | if ((t.assetId != v)) | |
57 | 69 | then throw("Only III token") | |
58 | - | else { | |
59 | - | let a = toBase58String(i.caller.bytes) | |
60 | - | let s = split(getStatistic(), "_") | |
61 | - | if ((a == l)) | |
62 | - | then [StringEntry("statistic", makeString([s[0], s[1], s[2], s[3], s[4], s[5], s[6], toString((parseIntValue(s[7]) + z)), s[8]], "_"))] | |
63 | - | else { | |
64 | - | let h = lastBlock.height | |
65 | - | let x = ((z / 100) * (100 + p)) | |
66 | - | let y = (x - z) | |
67 | - | let u = split(getUser(a), "_") | |
68 | - | let ud2 = parseIntValue(u[2]) | |
69 | - | if ((u[7] == "0")) | |
70 | - | then [StringEntry("statistic", makeString([toString((parseIntValue(s[0]) + z)), toString((parseIntValue(s[1]) + 1)), s[2], s[3], s[4], s[5], s[6], s[7], toString((parseIntValue(s[8]) + y))], "_")), StringEntry(a, makeString([toString((parseIntValue(u[0]) + z)), toString((parseIntValue(u[1]) + x)), toString((ud2 + x)), toString(((ud2 + x) / f)), toString(h), u[5], u[6], u[7], u[8], u[9], u[10], u[11]], "_"))] | |
71 | - | else { | |
72 | - | let r1 = split(getUser(u[7]), "_") | |
73 | - | let sr1 = ((z / 100) * pr1) | |
74 | - | if ((r1[7] == "0")) | |
75 | - | then [StringEntry("statistic", makeString([toString((parseIntValue(s[0]) + z)), toString((parseIntValue(s[1]) + 1)), s[2], s[3], toString((parseIntValue(s[4]) + sr1)), toString((parseIntValue(s[5]) + 1)), s[6], s[7], toString(((parseIntValue(s[8]) + y) + sr1))], "_")), StringEntry(a, makeString([toString((parseIntValue(u[0]) + z)), toString((parseIntValue(u[1]) + x)), toString((ud2 + x)), toString(((ud2 + x) / f)), toString(h), u[5], u[6], u[7], u[8], u[9], u[10], u[11]], "_")), StringEntry(u[7], makeString([r1[0], r1[1], r1[2], r1[3], r1[4], r1[5], r1[6], r1[7], toString((parseIntValue(r1[8]) + sr1)), r1[9], r1[10], toString((parseIntValue(r1[11]) + sr1))], "_"))] | |
76 | - | else { | |
77 | - | let r2 = split(getUser(r1[7]), "_") | |
78 | - | let sr2 = ((z / 100) * pr2) | |
79 | - | if ((r2[7] == "0")) | |
80 | - | then [StringEntry("statistic", makeString([toString((parseIntValue(s[0]) + z)), toString((parseIntValue(s[1]) + 1)), s[2], s[3], toString(((parseIntValue(s[4]) + sr1) + sr2)), toString((parseIntValue(s[5]) + 2)), s[6], s[7], toString((((parseIntValue(s[8]) + y) + sr1) + sr2))], "_")), StringEntry(a, makeString([toString((parseIntValue(u[0]) + z)), toString((parseIntValue(u[1]) + x)), toString((ud2 + x)), toString(((ud2 + x) / f)), toString(h), u[5], u[6], u[7], u[8], u[9], u[10], u[11]], "_")), StringEntry(u[7], makeString([r1[0], r1[1], r1[2], r1[3], r1[4], r1[5], r1[6], r1[7], toString((parseIntValue(r1[8]) + sr1)), r1[9], r1[10], toString((parseIntValue(r1[11]) + sr1))], "_")), StringEntry(r1[7], makeString([r2[0], r2[1], r2[2], r2[3], r2[4], r2[5], r2[6], r2[7], r2[8], toString((parseIntValue(r2[9]) + sr2)), r2[10], toString((parseIntValue(r2[11]) + sr2))], "_"))] | |
81 | - | else { | |
82 | - | let r3 = split(getUser(r2[7]), "_") | |
83 | - | let sr3 = ((z / 100) * pr3) | |
84 | - | [StringEntry("statistic", makeString([toString((parseIntValue(s[0]) + z)), toString((parseIntValue(s[1]) + 1)), s[2], s[3], toString((((parseIntValue(s[4]) + sr1) + sr2) + sr3)), toString((parseIntValue(s[5]) + 3)), s[6], s[7], toString(((((parseIntValue(s[8]) + y) + sr1) + sr2) + sr3))], "_")), StringEntry(a, makeString([toString((parseIntValue(u[0]) + z)), toString((parseIntValue(u[1]) + x)), toString((ud2 + x)), toString(((ud2 + x) / f)), toString(h), u[5], u[6], u[7], u[8], u[9], u[10], u[11]], "_")), StringEntry(u[7], makeString([r1[0], r1[1], r1[2], r1[3], r1[4], r1[5], r1[6], r1[7], toString((parseIntValue(r1[8]) + sr1)), r1[9], r1[10], toString((parseIntValue(r1[11]) + sr1))], "_")), StringEntry(r1[7], makeString([r2[0], r2[1], r2[2], r2[3], r2[4], r2[5], r2[6], r2[7], r2[8], toString((parseIntValue(r2[9]) + sr2)), r2[10], toString((parseIntValue(r2[11]) + sr2))], "_")), StringEntry(r2[7], makeString([r3[0], r3[1], r3[2], r3[3], r3[4], r3[5], r3[6], r3[7], r3[8], r3[9], toString((parseIntValue(r3[10]) + sr3)), toString((parseIntValue(r3[11]) + sr3))], "_"))] | |
85 | - | } | |
86 | - | } | |
87 | - | } | |
88 | - | } | |
89 | - | } | |
70 | + | else if ((10000 > z)) | |
71 | + | then throw("Min sum 0.0001 III token") | |
72 | + | else { | |
73 | + | let a = toBase58String(i.caller.bytes) | |
74 | + | let s = split(getStatistic(), "_") | |
75 | + | if ((a == l)) | |
76 | + | then [StringEntry("statistic", makeString([s[0], s[1], s[2], s[3], s[4], s[5], s[6], toString((parseIntValue(s[7]) + z)), s[8], s[9], s[10]], "_"))] | |
77 | + | else { | |
78 | + | let x = ((z / 10000) * (10000 + p)) | |
79 | + | let y = (x - z) | |
80 | + | let u = split(getUser(a, getReferral(r)), "_") | |
81 | + | let ud2 = parseIntValue(u[2]) | |
82 | + | if ((u[7] == "0")) | |
83 | + | then [StringEntry("statistic", makeString([toString((parseIntValue(s[0]) + z)), toString((parseIntValue(s[1]) + 1)), s[2], s[3], s[4], s[5], s[6], s[7], toString((parseIntValue(s[8]) + y)), s[9], s[10]], "_")), StringEntry(a, makeString([toString((parseIntValue(u[0]) + z)), toString((parseIntValue(u[1]) + x)), toString((ud2 + x)), toString(((ud2 + x) / f)), toString(h), u[5], u[6], u[7], u[8], u[9], u[10], u[11]], "_"))] | |
84 | + | else { | |
85 | + | let r1 = split(getUser(u[7], "0"), "_") | |
86 | + | let sr1 = ((z / 10000) * pr1) | |
87 | + | if ((r1[7] == "0")) | |
88 | + | then [StringEntry("statistic", makeString([toString((parseIntValue(s[0]) + z)), toString((parseIntValue(s[1]) + 1)), s[2], s[3], toString((parseIntValue(s[4]) + sr1)), toString((parseIntValue(s[5]) + 1)), s[6], s[7], toString(((parseIntValue(s[8]) + y) + sr1)), s[9], s[10]], "_")), StringEntry(a, makeString([toString((parseIntValue(u[0]) + z)), toString((parseIntValue(u[1]) + x)), toString((ud2 + x)), toString(((ud2 + x) / f)), toString(h), u[5], u[6], u[7], u[8], u[9], u[10], u[11]], "_")), StringEntry(u[7], makeString([r1[0], r1[1], r1[2], r1[3], r1[4], r1[5], r1[6], r1[7], toString((parseIntValue(r1[8]) + sr1)), r1[9], r1[10], toString((parseIntValue(r1[11]) + sr1))], "_"))] | |
89 | + | else { | |
90 | + | let r2 = split(getUser(r1[7], "0"), "_") | |
91 | + | let sr2 = ((z / 10000) * pr2) | |
92 | + | if ((r2[7] == "0")) | |
93 | + | then [StringEntry("statistic", makeString([toString((parseIntValue(s[0]) + z)), toString((parseIntValue(s[1]) + 1)), s[2], s[3], toString(((parseIntValue(s[4]) + sr1) + sr2)), toString((parseIntValue(s[5]) + 2)), s[6], s[7], toString((((parseIntValue(s[8]) + y) + sr1) + sr2)), s[9], s[10]], "_")), StringEntry(a, makeString([toString((parseIntValue(u[0]) + z)), toString((parseIntValue(u[1]) + x)), toString((ud2 + x)), toString(((ud2 + x) / f)), toString(h), u[5], u[6], u[7], u[8], u[9], u[10], u[11]], "_")), StringEntry(u[7], makeString([r1[0], r1[1], r1[2], r1[3], r1[4], r1[5], r1[6], r1[7], toString((parseIntValue(r1[8]) + sr1)), r1[9], r1[10], toString((parseIntValue(r1[11]) + sr1))], "_")), StringEntry(r1[7], makeString([r2[0], r2[1], r2[2], r2[3], r2[4], r2[5], r2[6], r2[7], r2[8], toString((parseIntValue(r2[9]) + sr2)), r2[10], toString((parseIntValue(r2[11]) + sr2))], "_"))] | |
94 | + | else { | |
95 | + | let r3 = split(getUser(r2[7], "0"), "_") | |
96 | + | let sr3 = ((z / 10000) * pr3) | |
97 | + | [StringEntry("statistic", makeString([toString((parseIntValue(s[0]) + z)), toString((parseIntValue(s[1]) + 1)), s[2], s[3], toString((((parseIntValue(s[4]) + sr1) + sr2) + sr3)), toString((parseIntValue(s[5]) + 3)), s[6], s[7], toString(((((parseIntValue(s[8]) + y) + sr1) + sr2) + sr3)), s[9], s[10]], "_")), StringEntry(a, makeString([toString((parseIntValue(u[0]) + z)), toString((parseIntValue(u[1]) + x)), toString((ud2 + x)), toString(((ud2 + x) / f)), toString(h), u[5], u[6], u[7], u[8], u[9], u[10], u[11]], "_")), StringEntry(u[7], makeString([r1[0], r1[1], r1[2], r1[3], r1[4], r1[5], r1[6], r1[7], toString((parseIntValue(r1[8]) + sr1)), r1[9], r1[10], toString((parseIntValue(r1[11]) + sr1))], "_")), StringEntry(r1[7], makeString([r2[0], r2[1], r2[2], r2[3], r2[4], r2[5], r2[6], r2[7], r2[8], toString((parseIntValue(r2[9]) + sr2)), r2[10], toString((parseIntValue(r2[11]) + sr2))], "_")), StringEntry(r2[7], makeString([r3[0], r3[1], r3[2], r3[3], r3[4], r3[5], r3[6], r3[7], r3[8], r3[9], toString((parseIntValue(r3[10]) + sr3)), toString((parseIntValue(r3[11]) + sr3))], "_"))] | |
98 | + | } | |
99 | + | } | |
100 | + | } | |
101 | + | } | |
102 | + | } | |
90 | 103 | } | |
91 | 104 | ||
92 | 105 | ||
95 | 108 | func withdraw (w) = { | |
96 | 109 | let y = getWithdraw(w) | |
97 | 110 | let a = toBase58String(i.caller.bytes) | |
98 | - | let u = split(getUser(a), "_") | |
111 | + | let u = split(getUser(a, "0"), "_") | |
99 | 112 | let s = split(getStatistic(), "_") | |
100 | - | let h = lastBlock.height | |
101 | 113 | let j = parseIntValue(u[4]) | |
102 | 114 | let x = parseIntValue(u[2]) | |
103 | 115 | let d = parseIntValue(u[3]) | |
106 | 118 | let m = if ((h >= g)) | |
107 | 119 | then (x + b) | |
108 | 120 | else ((((f - g) + h) * d) + b) | |
109 | - | if ((0 > y)) | |
121 | + | if ((0 >= y)) | |
110 | 122 | then throw("Can't withdraw negative amount") | |
111 | 123 | else if ((b >= y)) | |
112 | - | then [StringEntry("statistic", makeString([s[0], s[1], s[2], toString((parseIntValue(s[3]) + 1)), s[4], s[5], toString((parseIntValue(s[6]) + y)), s[7], s[8]], "_")), StringEntry(a, makeString([u[0], u[1], u[2], u[3], u[4], toString((parseIntValue(u[5]) + y)), toString((parseIntValue(u[6]) + y)), u[7], u[8], u[9], u[10], toString((parseIntValue(u[11]) - y))], "_")), ScriptTransfer(i.caller, y, v)] | |
124 | + | then [StringEntry("statistic", makeString([s[0], s[1], s[2], toString((parseIntValue(s[3]) + 1)), s[4], s[5], toString((parseIntValue(s[6]) + y)), s[7], s[8], s[9], s[10]], "_")), StringEntry(a, makeString([u[0], u[1], u[2], u[3], u[4], toString((parseIntValue(u[5]) + y)), toString((parseIntValue(u[6]) + y)), u[7], u[8], u[9], u[10], toString((parseIntValue(u[11]) - y))], "_")), ScriptTransfer(i.caller, y, v)] | |
113 | 125 | else if ((0 > (m - y))) | |
114 | - | then throw(((((((((((((((("h" + toString(h)) + " / j") + toString(j)) + " / x") + toString(x)) + " / d") + toString(d)) + " / b") + toString(b)) + " / g") + toString(g)) + " / m") + toString(m)) + " / ((f-g+h)*d)+b ") + toString(((((f - g) + h) * d) + b)))) | |
115 | - | else throw(((((((((((((((("h" + toString(h)) + " / j") + toString(j)) + " / x") + toString(x)) + " / d") + toString(d)) + " / b") + toString(b)) + " / g") + toString(g)) + " / m") + toString(m)) + " / ((f-g+h)*d)+b ") + toString(((((f - g) + h) * d) + b)))) | |
126 | + | then throw("Not enough balance") | |
127 | + | else { | |
128 | + | let n = ((x + b) - y) | |
129 | + | [StringEntry("statistic", makeString([s[0], s[1], toString(((parseIntValue(s[2]) + y) - parseIntValue(u[11]))), toString((parseIntValue(s[3]) + 1)), s[4], s[5], toString((parseIntValue(s[6]) + parseIntValue(u[11]))), s[7], s[8], s[9], s[10]], "_")), StringEntry(a, makeString([u[0], u[1], toString(n), u[3], u[4], toString((parseIntValue(u[5]) + y)), toString((parseIntValue(u[6]) + y)), u[7], u[8], u[9], (u[10] + "_0")], "_")), ScriptTransfer(i.caller, y, v)] | |
130 | + | } | |
131 | + | } | |
132 | + | ||
133 | + | ||
134 | + | ||
135 | + | @Callable(i) | |
136 | + | func Marketing (w) = { | |
137 | + | let y = getWithdraw(w) | |
138 | + | let a = toBase58String(i.caller.bytes) | |
139 | + | let s = split(getStatistic(), "_") | |
140 | + | if ((0 >= y)) | |
141 | + | then throw("Can't withdraw negative amount") | |
142 | + | else if ((y > 10000)) | |
143 | + | then throw("Not enough balance") | |
144 | + | else [StringEntry("statistic", makeString([s[0], s[1], s[2], s[3], s[4], s[5], s[6], s[7], s[8], s[9], s[10]], "_")), ScriptTransfer(i.caller, y, v)] | |
116 | 145 | } | |
117 | 146 | ||
118 | 147 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 4 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let v = base58'5zNG3WFGEh3tA38hAZSvD9fMTsR7hwPU7XR4qZqGjs46' | |
5 | 5 | ||
6 | 6 | let o = base58'7rC1eUHm39ujzNxeYHmmZia2bTsJ1Un38mzD1QHNVwUN' | |
7 | 7 | ||
8 | 8 | let l = "3N2hHaqEEXjFHE5G8NTw6v7KNMwcHob2Ena" | |
9 | 9 | ||
10 | 10 | let f = 10 | |
11 | 11 | ||
12 | - | let p = | |
12 | + | let p = 2000 | |
13 | 13 | ||
14 | - | let pr1 = | |
14 | + | let pr1 = 300 | |
15 | 15 | ||
16 | - | let pr2 = | |
16 | + | let pr2 = 200 | |
17 | 17 | ||
18 | - | let pr3 = 1 | |
18 | + | let pr3 = 100 | |
19 | + | ||
20 | + | let h = height | |
19 | 21 | ||
20 | 22 | func getStatistic () = match getString(this, "statistic") { | |
21 | 23 | case a: String => | |
22 | 24 | a | |
23 | 25 | case _ => | |
24 | - | "0_0_0_0_0_0_0_0_0" | |
26 | + | ("0_0_0_0_0_0_0_0_0_0_" + toString(h)) | |
25 | 27 | } | |
26 | 28 | ||
27 | 29 | ||
28 | - | func getUser ( | |
30 | + | func getUser (u,r) = match getString(this, u) { | |
29 | 31 | case a: String => | |
30 | 32 | a | |
31 | 33 | case _ => | |
32 | - | "0_0_0_0_0_0_0 | |
34 | + | makeString(["0_0_0_0_0_0_0", r, "0_0_0_0"], "_") | |
33 | 35 | } | |
36 | + | ||
37 | + | ||
38 | + | func getReferral (r) = { | |
39 | + | let z = split(r, "referral:") | |
40 | + | if (isDefined(z[1])) | |
41 | + | then if (isDefined(addressFromString(z[1]))) | |
42 | + | then z[1] | |
43 | + | else "0" | |
44 | + | else "0" | |
45 | + | } | |
34 | 46 | ||
35 | 47 | ||
36 | 48 | func getWithdraw (s) = { | |
37 | 49 | let a = split(s, " III") | |
38 | 50 | let b = split(a[0], ".") | |
39 | 51 | let i = (parseIntValue(b[0]) * 100000000) | |
40 | 52 | if ((size(b) == 1)) | |
41 | 53 | then i | |
42 | 54 | else ((parseIntValue(b[1]) * pow(10, 0, (8 - size(b[1])), 0, 0, HALFDOWN)) + i) | |
43 | 55 | } | |
44 | 56 | ||
45 | 57 | ||
46 | 58 | @Callable(i) | |
47 | - | func deposit ( | |
59 | + | func deposit (r) = { | |
48 | 60 | let t = value(i.payments[0]) | |
49 | 61 | let z = t.amount | |
50 | 62 | let k = match t.assetId { | |
51 | 63 | case id: ByteVector => | |
52 | 64 | toBase58String(id) | |
53 | 65 | case _ => | |
54 | 66 | "" | |
55 | 67 | } | |
56 | 68 | if ((t.assetId != v)) | |
57 | 69 | then throw("Only III token") | |
58 | - | else { | |
59 | - | let a = toBase58String(i.caller.bytes) | |
60 | - | let s = split(getStatistic(), "_") | |
61 | - | if ((a == l)) | |
62 | - | then [StringEntry("statistic", makeString([s[0], s[1], s[2], s[3], s[4], s[5], s[6], toString((parseIntValue(s[7]) + z)), s[8]], "_"))] | |
63 | - | else { | |
64 | - | let h = lastBlock.height | |
65 | - | let x = ((z / 100) * (100 + p)) | |
66 | - | let y = (x - z) | |
67 | - | let u = split(getUser(a), "_") | |
68 | - | let ud2 = parseIntValue(u[2]) | |
69 | - | if ((u[7] == "0")) | |
70 | - | then [StringEntry("statistic", makeString([toString((parseIntValue(s[0]) + z)), toString((parseIntValue(s[1]) + 1)), s[2], s[3], s[4], s[5], s[6], s[7], toString((parseIntValue(s[8]) + y))], "_")), StringEntry(a, makeString([toString((parseIntValue(u[0]) + z)), toString((parseIntValue(u[1]) + x)), toString((ud2 + x)), toString(((ud2 + x) / f)), toString(h), u[5], u[6], u[7], u[8], u[9], u[10], u[11]], "_"))] | |
71 | - | else { | |
72 | - | let r1 = split(getUser(u[7]), "_") | |
73 | - | let sr1 = ((z / 100) * pr1) | |
74 | - | if ((r1[7] == "0")) | |
75 | - | then [StringEntry("statistic", makeString([toString((parseIntValue(s[0]) + z)), toString((parseIntValue(s[1]) + 1)), s[2], s[3], toString((parseIntValue(s[4]) + sr1)), toString((parseIntValue(s[5]) + 1)), s[6], s[7], toString(((parseIntValue(s[8]) + y) + sr1))], "_")), StringEntry(a, makeString([toString((parseIntValue(u[0]) + z)), toString((parseIntValue(u[1]) + x)), toString((ud2 + x)), toString(((ud2 + x) / f)), toString(h), u[5], u[6], u[7], u[8], u[9], u[10], u[11]], "_")), StringEntry(u[7], makeString([r1[0], r1[1], r1[2], r1[3], r1[4], r1[5], r1[6], r1[7], toString((parseIntValue(r1[8]) + sr1)), r1[9], r1[10], toString((parseIntValue(r1[11]) + sr1))], "_"))] | |
76 | - | else { | |
77 | - | let r2 = split(getUser(r1[7]), "_") | |
78 | - | let sr2 = ((z / 100) * pr2) | |
79 | - | if ((r2[7] == "0")) | |
80 | - | then [StringEntry("statistic", makeString([toString((parseIntValue(s[0]) + z)), toString((parseIntValue(s[1]) + 1)), s[2], s[3], toString(((parseIntValue(s[4]) + sr1) + sr2)), toString((parseIntValue(s[5]) + 2)), s[6], s[7], toString((((parseIntValue(s[8]) + y) + sr1) + sr2))], "_")), StringEntry(a, makeString([toString((parseIntValue(u[0]) + z)), toString((parseIntValue(u[1]) + x)), toString((ud2 + x)), toString(((ud2 + x) / f)), toString(h), u[5], u[6], u[7], u[8], u[9], u[10], u[11]], "_")), StringEntry(u[7], makeString([r1[0], r1[1], r1[2], r1[3], r1[4], r1[5], r1[6], r1[7], toString((parseIntValue(r1[8]) + sr1)), r1[9], r1[10], toString((parseIntValue(r1[11]) + sr1))], "_")), StringEntry(r1[7], makeString([r2[0], r2[1], r2[2], r2[3], r2[4], r2[5], r2[6], r2[7], r2[8], toString((parseIntValue(r2[9]) + sr2)), r2[10], toString((parseIntValue(r2[11]) + sr2))], "_"))] | |
81 | - | else { | |
82 | - | let r3 = split(getUser(r2[7]), "_") | |
83 | - | let sr3 = ((z / 100) * pr3) | |
84 | - | [StringEntry("statistic", makeString([toString((parseIntValue(s[0]) + z)), toString((parseIntValue(s[1]) + 1)), s[2], s[3], toString((((parseIntValue(s[4]) + sr1) + sr2) + sr3)), toString((parseIntValue(s[5]) + 3)), s[6], s[7], toString(((((parseIntValue(s[8]) + y) + sr1) + sr2) + sr3))], "_")), StringEntry(a, makeString([toString((parseIntValue(u[0]) + z)), toString((parseIntValue(u[1]) + x)), toString((ud2 + x)), toString(((ud2 + x) / f)), toString(h), u[5], u[6], u[7], u[8], u[9], u[10], u[11]], "_")), StringEntry(u[7], makeString([r1[0], r1[1], r1[2], r1[3], r1[4], r1[5], r1[6], r1[7], toString((parseIntValue(r1[8]) + sr1)), r1[9], r1[10], toString((parseIntValue(r1[11]) + sr1))], "_")), StringEntry(r1[7], makeString([r2[0], r2[1], r2[2], r2[3], r2[4], r2[5], r2[6], r2[7], r2[8], toString((parseIntValue(r2[9]) + sr2)), r2[10], toString((parseIntValue(r2[11]) + sr2))], "_")), StringEntry(r2[7], makeString([r3[0], r3[1], r3[2], r3[3], r3[4], r3[5], r3[6], r3[7], r3[8], r3[9], toString((parseIntValue(r3[10]) + sr3)), toString((parseIntValue(r3[11]) + sr3))], "_"))] | |
85 | - | } | |
86 | - | } | |
87 | - | } | |
88 | - | } | |
89 | - | } | |
70 | + | else if ((10000 > z)) | |
71 | + | then throw("Min sum 0.0001 III token") | |
72 | + | else { | |
73 | + | let a = toBase58String(i.caller.bytes) | |
74 | + | let s = split(getStatistic(), "_") | |
75 | + | if ((a == l)) | |
76 | + | then [StringEntry("statistic", makeString([s[0], s[1], s[2], s[3], s[4], s[5], s[6], toString((parseIntValue(s[7]) + z)), s[8], s[9], s[10]], "_"))] | |
77 | + | else { | |
78 | + | let x = ((z / 10000) * (10000 + p)) | |
79 | + | let y = (x - z) | |
80 | + | let u = split(getUser(a, getReferral(r)), "_") | |
81 | + | let ud2 = parseIntValue(u[2]) | |
82 | + | if ((u[7] == "0")) | |
83 | + | then [StringEntry("statistic", makeString([toString((parseIntValue(s[0]) + z)), toString((parseIntValue(s[1]) + 1)), s[2], s[3], s[4], s[5], s[6], s[7], toString((parseIntValue(s[8]) + y)), s[9], s[10]], "_")), StringEntry(a, makeString([toString((parseIntValue(u[0]) + z)), toString((parseIntValue(u[1]) + x)), toString((ud2 + x)), toString(((ud2 + x) / f)), toString(h), u[5], u[6], u[7], u[8], u[9], u[10], u[11]], "_"))] | |
84 | + | else { | |
85 | + | let r1 = split(getUser(u[7], "0"), "_") | |
86 | + | let sr1 = ((z / 10000) * pr1) | |
87 | + | if ((r1[7] == "0")) | |
88 | + | then [StringEntry("statistic", makeString([toString((parseIntValue(s[0]) + z)), toString((parseIntValue(s[1]) + 1)), s[2], s[3], toString((parseIntValue(s[4]) + sr1)), toString((parseIntValue(s[5]) + 1)), s[6], s[7], toString(((parseIntValue(s[8]) + y) + sr1)), s[9], s[10]], "_")), StringEntry(a, makeString([toString((parseIntValue(u[0]) + z)), toString((parseIntValue(u[1]) + x)), toString((ud2 + x)), toString(((ud2 + x) / f)), toString(h), u[5], u[6], u[7], u[8], u[9], u[10], u[11]], "_")), StringEntry(u[7], makeString([r1[0], r1[1], r1[2], r1[3], r1[4], r1[5], r1[6], r1[7], toString((parseIntValue(r1[8]) + sr1)), r1[9], r1[10], toString((parseIntValue(r1[11]) + sr1))], "_"))] | |
89 | + | else { | |
90 | + | let r2 = split(getUser(r1[7], "0"), "_") | |
91 | + | let sr2 = ((z / 10000) * pr2) | |
92 | + | if ((r2[7] == "0")) | |
93 | + | then [StringEntry("statistic", makeString([toString((parseIntValue(s[0]) + z)), toString((parseIntValue(s[1]) + 1)), s[2], s[3], toString(((parseIntValue(s[4]) + sr1) + sr2)), toString((parseIntValue(s[5]) + 2)), s[6], s[7], toString((((parseIntValue(s[8]) + y) + sr1) + sr2)), s[9], s[10]], "_")), StringEntry(a, makeString([toString((parseIntValue(u[0]) + z)), toString((parseIntValue(u[1]) + x)), toString((ud2 + x)), toString(((ud2 + x) / f)), toString(h), u[5], u[6], u[7], u[8], u[9], u[10], u[11]], "_")), StringEntry(u[7], makeString([r1[0], r1[1], r1[2], r1[3], r1[4], r1[5], r1[6], r1[7], toString((parseIntValue(r1[8]) + sr1)), r1[9], r1[10], toString((parseIntValue(r1[11]) + sr1))], "_")), StringEntry(r1[7], makeString([r2[0], r2[1], r2[2], r2[3], r2[4], r2[5], r2[6], r2[7], r2[8], toString((parseIntValue(r2[9]) + sr2)), r2[10], toString((parseIntValue(r2[11]) + sr2))], "_"))] | |
94 | + | else { | |
95 | + | let r3 = split(getUser(r2[7], "0"), "_") | |
96 | + | let sr3 = ((z / 10000) * pr3) | |
97 | + | [StringEntry("statistic", makeString([toString((parseIntValue(s[0]) + z)), toString((parseIntValue(s[1]) + 1)), s[2], s[3], toString((((parseIntValue(s[4]) + sr1) + sr2) + sr3)), toString((parseIntValue(s[5]) + 3)), s[6], s[7], toString(((((parseIntValue(s[8]) + y) + sr1) + sr2) + sr3)), s[9], s[10]], "_")), StringEntry(a, makeString([toString((parseIntValue(u[0]) + z)), toString((parseIntValue(u[1]) + x)), toString((ud2 + x)), toString(((ud2 + x) / f)), toString(h), u[5], u[6], u[7], u[8], u[9], u[10], u[11]], "_")), StringEntry(u[7], makeString([r1[0], r1[1], r1[2], r1[3], r1[4], r1[5], r1[6], r1[7], toString((parseIntValue(r1[8]) + sr1)), r1[9], r1[10], toString((parseIntValue(r1[11]) + sr1))], "_")), StringEntry(r1[7], makeString([r2[0], r2[1], r2[2], r2[3], r2[4], r2[5], r2[6], r2[7], r2[8], toString((parseIntValue(r2[9]) + sr2)), r2[10], toString((parseIntValue(r2[11]) + sr2))], "_")), StringEntry(r2[7], makeString([r3[0], r3[1], r3[2], r3[3], r3[4], r3[5], r3[6], r3[7], r3[8], r3[9], toString((parseIntValue(r3[10]) + sr3)), toString((parseIntValue(r3[11]) + sr3))], "_"))] | |
98 | + | } | |
99 | + | } | |
100 | + | } | |
101 | + | } | |
102 | + | } | |
90 | 103 | } | |
91 | 104 | ||
92 | 105 | ||
93 | 106 | ||
94 | 107 | @Callable(i) | |
95 | 108 | func withdraw (w) = { | |
96 | 109 | let y = getWithdraw(w) | |
97 | 110 | let a = toBase58String(i.caller.bytes) | |
98 | - | let u = split(getUser(a), "_") | |
111 | + | let u = split(getUser(a, "0"), "_") | |
99 | 112 | let s = split(getStatistic(), "_") | |
100 | - | let h = lastBlock.height | |
101 | 113 | let j = parseIntValue(u[4]) | |
102 | 114 | let x = parseIntValue(u[2]) | |
103 | 115 | let d = parseIntValue(u[3]) | |
104 | 116 | let b = parseIntValue(u[11]) | |
105 | 117 | let g = (j + f) | |
106 | 118 | let m = if ((h >= g)) | |
107 | 119 | then (x + b) | |
108 | 120 | else ((((f - g) + h) * d) + b) | |
109 | - | if ((0 > y)) | |
121 | + | if ((0 >= y)) | |
110 | 122 | then throw("Can't withdraw negative amount") | |
111 | 123 | else if ((b >= y)) | |
112 | - | then [StringEntry("statistic", makeString([s[0], s[1], s[2], toString((parseIntValue(s[3]) + 1)), s[4], s[5], toString((parseIntValue(s[6]) + y)), s[7], s[8]], "_")), StringEntry(a, makeString([u[0], u[1], u[2], u[3], u[4], toString((parseIntValue(u[5]) + y)), toString((parseIntValue(u[6]) + y)), u[7], u[8], u[9], u[10], toString((parseIntValue(u[11]) - y))], "_")), ScriptTransfer(i.caller, y, v)] | |
124 | + | then [StringEntry("statistic", makeString([s[0], s[1], s[2], toString((parseIntValue(s[3]) + 1)), s[4], s[5], toString((parseIntValue(s[6]) + y)), s[7], s[8], s[9], s[10]], "_")), StringEntry(a, makeString([u[0], u[1], u[2], u[3], u[4], toString((parseIntValue(u[5]) + y)), toString((parseIntValue(u[6]) + y)), u[7], u[8], u[9], u[10], toString((parseIntValue(u[11]) - y))], "_")), ScriptTransfer(i.caller, y, v)] | |
113 | 125 | else if ((0 > (m - y))) | |
114 | - | then throw(((((((((((((((("h" + toString(h)) + " / j") + toString(j)) + " / x") + toString(x)) + " / d") + toString(d)) + " / b") + toString(b)) + " / g") + toString(g)) + " / m") + toString(m)) + " / ((f-g+h)*d)+b ") + toString(((((f - g) + h) * d) + b)))) | |
115 | - | else throw(((((((((((((((("h" + toString(h)) + " / j") + toString(j)) + " / x") + toString(x)) + " / d") + toString(d)) + " / b") + toString(b)) + " / g") + toString(g)) + " / m") + toString(m)) + " / ((f-g+h)*d)+b ") + toString(((((f - g) + h) * d) + b)))) | |
126 | + | then throw("Not enough balance") | |
127 | + | else { | |
128 | + | let n = ((x + b) - y) | |
129 | + | [StringEntry("statistic", makeString([s[0], s[1], toString(((parseIntValue(s[2]) + y) - parseIntValue(u[11]))), toString((parseIntValue(s[3]) + 1)), s[4], s[5], toString((parseIntValue(s[6]) + parseIntValue(u[11]))), s[7], s[8], s[9], s[10]], "_")), StringEntry(a, makeString([u[0], u[1], toString(n), u[3], u[4], toString((parseIntValue(u[5]) + y)), toString((parseIntValue(u[6]) + y)), u[7], u[8], u[9], (u[10] + "_0")], "_")), ScriptTransfer(i.caller, y, v)] | |
130 | + | } | |
131 | + | } | |
132 | + | ||
133 | + | ||
134 | + | ||
135 | + | @Callable(i) | |
136 | + | func Marketing (w) = { | |
137 | + | let y = getWithdraw(w) | |
138 | + | let a = toBase58String(i.caller.bytes) | |
139 | + | let s = split(getStatistic(), "_") | |
140 | + | if ((0 >= y)) | |
141 | + | then throw("Can't withdraw negative amount") | |
142 | + | else if ((y > 10000)) | |
143 | + | then throw("Not enough balance") | |
144 | + | else [StringEntry("statistic", makeString([s[0], s[1], s[2], s[3], s[4], s[5], s[6], s[7], s[8], s[9], s[10]], "_")), ScriptTransfer(i.caller, y, v)] | |
116 | 145 | } | |
117 | 146 | ||
118 | 147 | ||
119 | 148 | @Verifier(tx) | |
120 | 149 | func verify () = match tx { | |
121 | 150 | case d: SetScriptTransaction => | |
122 | 151 | sigVerify(tx.bodyBytes, tx.proofs[0], o) | |
123 | 152 | case _ => | |
124 | 153 | true | |
125 | 154 | } | |
126 | 155 |
github/deemru/w8io/169f3d6 89.32 ms ◑