tx · BSYg51q8R8dGXYRJKt3ikatRYyxKaHoDfdVS6aQWY1V6 3MwjJKGp7PLGJh7pzYrnrN9TnMXph6oL4nH: -0.05000000 Waves 2019.11.25 11:26 [780540] smart account 3MwjJKGp7PLGJh7pzYrnrN9TnMXph6oL4nH > SELF 0.00000000 Waves
{ "type": 13, "id": "BSYg51q8R8dGXYRJKt3ikatRYyxKaHoDfdVS6aQWY1V6", "fee": 5000000, "feeAssetId": null, "timestamp": 1574670448829, "version": 1, "sender": "3MwjJKGp7PLGJh7pzYrnrN9TnMXph6oL4nH", "senderPublicKey": "9Pw6KBYMgEWmrg24tEc8SkHPhMUBwRmHaJoKjWgDkUAK", "proofs": [ "31v4r5pqwuE9UttFZUUsr33uTpAngRsn45L5XWYP4bnXwf79dvsRyq5yZ64poRDaJk4L9hU1adW8rztk9tyvFm3V" ], "script": "base64:AAIDAAAAAAAAACEIARIDCgEIEgYKBAgICAESBQoDCAgIEgkKBwgIAQEBCAgAAAAKAAAAAAROT05FAgAAAARub25lAAAAAAZvcmFjbGUJAQAAABxAZXh0clVzZXIoYWRkcmVzc0Zyb21TdHJpbmcpAAAAAQIAAAAjM05BY29lV2RVVFduOGNzWEpQRzQ3djFGanRqY2ZxeGI1dHUAAAAABWFza0lEAgAAAAVXQVZFUwAAAAAFYmlkSUQCAAAABVVTRC1OAAAAAAZtaW5QaXAAAAAAAAAPQkABAAAACGdlbktleUlEAAAAAQAAAARhZGRyCQACWAAAAAEJAAH3AAAAAQkAAZsAAAABCQABLAAAAAIFAAAABGFkZHIJAAQlAAAAAQUAAAAEdGhpcwEAAAAHZ2VuR3JpZAAAAAIAAAABYQAAAAFiAwkAAAAAAAACBQAAAAFhAgAAAAAJAAGkAAAAAQUAAAABYgkAASwAAAACCQABLAAAAAIFAAAAAWECAAAAAXwJAAGkAAAAAQUAAAABYgEAAAAHZ2VuTGlzdAAAAAIAAAABYQAAAAFiCQAETAAAAAIFAAAAAWIFAAAAAWEBAAAACmdlbkxpc3RJbn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AAgkBAAAACURhdGFFbnRyeQAAAAIJAAEsAAAAAgUAAAAFa2V5SUQCAAAAB19zdGF0dXMCAAAAB2NyZWF0ZWQFAAAAA25pbAAAAAFpAQAAAA1kZWZpbmVTY2FscGVyAAAABwAAAAV0aXRsZQAAAARhZGRyAAAABGdyaWQAAAAFc3RlcHMAAAAIbGlmZXRpbWUAAAAIb3JkZXJpbmcAAAAKcmVPcmRlck91dAQAAAAGc2VuZGVyCQACWAAAAAEICAUAAAABaQAAAAZjYWxsZXIAAAAFYnl0ZXMEAAAABWtleUlECQEAAAAIZ2VuS2V5SUQAAAABBQAAAARhZGRyCQEAAAAIV3JpdGVTZXQAAAABCQAETAAAAAIJAQAAAAlEYXRhRW50cnkAAAACCQABLAAAAAIFAAAABWtleUlEAgAAAAVfZ3JpZAUAAAAEZ3JpZAkABEwAAAACCQEAAAAJRGF0YUVudHJ5AAAAAgkAASwAAAACBQAAAAVrZXlJRAIAAAAGX3N0ZXBzBQAAAAVzdGVwcwkABEwAAAACCQEAAAAJRGF0YUVudHJ5AAAAAgkAASwAAAACBQAAAAVrZXlJRAIAAAAJX2xpZmV0aW1lBQAAAAhsaWZldGltZQkABEwAAAACCQEAAAAJRGF0YUVudHJ5AAAAAgkAASwAAAACBQAAAAVrZXlJRAIAAAAJX29yZGVyaW5nBQAAAAhvcmRlcmluZwkABEwAAAACCQEAAAAJRGF0YUVudHJ5AAAAAgkAASwAAAACBQAAAAVrZXlJRAIAAAALX3JlT3JkZXJPdXQFAAAACnJlT3JkZXJPdXQJAARMAAAAAgkBAAAACURhdGFFbnRyeQAAAAIJAAEsAAAAAgUAAAAFa2V5SUQCAAAAB19zdGF0dXMCAAAAB2RlZmluZWQFAAAAA25pbAAAAAAO3BCP", "chainId": 84, "height": 780540, "spentComplexity": 0 } View: original | compacted Prev: HPY7yoYDxR7WCPVo1qAau9iBypbY6EC81VQXbYEvHmhx Next: BbbzZNwS6nGX9mwABa5hQ4NAA9b3VDi789wMfpqgYLc6 Diff:
Old | New | Differences | |
---|---|---|---|
179 | 179 | ||
180 | 180 | ||
181 | 181 | @Callable(o) | |
182 | - | func | |
182 | + | func createScalper (H,ac,g) = { | |
183 | 183 | let q = toBase58String(o.caller.bytes) | |
184 | 184 | let L = f(g) | |
185 | - | WriteSet([DataEntry((L + "_ | |
185 | + | WriteSet([DataEntry((L + "_scalperID"), g), DataEntry((L + "_title"), H), DataEntry((L + "_type"), ac), DataEntry((L + "_grid"), 0), DataEntry((L + "_steps"), 0), DataEntry((L + "_lifetime"), 0), DataEntry((L + "_ordering"), "middle"), DataEntry((L + "_reOrderOut"), "middle"), DataEntry((L + "_fundraised"), 0), DataEntry((L + "_priceOpen"), 0), DataEntry((L + "_priceClose"), 0), DataEntry((L + "_upOutGTD"), 0), DataEntry((L + "_downOutGTD"), 0), DataEntry((L + "_profit"), 0), DataEntry((L + "_profitFee"), 0), DataEntry((L + "_gridAsk"), "undefined asks"), DataEntry((L + "_gridBid"), "undefined bids"), DataEntry((L + "_blockStart"), 0), DataEntry((L + "_blockStop"), 0), DataEntry((L + "_status"), "created")]) | |
186 | 186 | } | |
187 | 187 | ||
188 | 188 | ||
189 | 189 | ||
190 | 190 | @Callable(o) | |
191 | - | func | |
191 | + | func defineScalper (H,g,ad,ae,af,ag,ah) = { | |
192 | 192 | let q = toBase58String(o.caller.bytes) | |
193 | 193 | let L = f(g) | |
194 | - | WriteSet([DataEntry((L + "_ | |
194 | + | WriteSet([DataEntry((L + "_grid"), ad), DataEntry((L + "_steps"), ae), DataEntry((L + "_lifetime"), af), DataEntry((L + "_ordering"), ag), DataEntry((L + "_reOrderOut"), ah), DataEntry((L + "_status"), "defined")]) | |
195 | 195 | } | |
196 | 196 | ||
197 | 197 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 3 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let a = "none" | |
5 | 5 | ||
6 | 6 | let b = addressFromStringValue("3NAcoeWdUTWn8csXJPG47v1Fjtjcfqxb5tu") | |
7 | 7 | ||
8 | 8 | let c = "WAVES" | |
9 | 9 | ||
10 | 10 | let d = "USD-N" | |
11 | 11 | ||
12 | 12 | let e = 1000000 | |
13 | 13 | ||
14 | 14 | func f (g) = toBase58String(sha256(toBytes((g + toString(this))))) | |
15 | 15 | ||
16 | 16 | ||
17 | 17 | func h (i,j) = if ((i == "")) | |
18 | 18 | then toString(j) | |
19 | 19 | else ((i + "|") + toString(j)) | |
20 | 20 | ||
21 | 21 | ||
22 | 22 | func k (i,j) = j :: i | |
23 | 23 | ||
24 | 24 | ||
25 | 25 | func l (i,j) = { | |
26 | 26 | let m = parseIntValue(j) | |
27 | 27 | (i[0] + 2) :: i | |
28 | 28 | } | |
29 | 29 | ||
30 | 30 | ||
31 | 31 | func n (i,j) = j :: i | |
32 | 32 | ||
33 | 33 | ||
34 | 34 | @Callable(o) | |
35 | 35 | func sendGridAsk (p) = { | |
36 | 36 | let q = toBase58String(o.caller.bytes) | |
37 | 37 | let r = split(p, "|") | |
38 | 38 | let s = { | |
39 | 39 | let t = r | |
40 | 40 | let u = size(t) | |
41 | 41 | let v = [69] | |
42 | 42 | if ((u == 0)) | |
43 | 43 | then v | |
44 | 44 | else { | |
45 | 45 | let w = l(v, t[0]) | |
46 | 46 | if ((u == 1)) | |
47 | 47 | then w | |
48 | 48 | else { | |
49 | 49 | let x = l(w, t[1]) | |
50 | 50 | if ((u == 2)) | |
51 | 51 | then x | |
52 | 52 | else { | |
53 | 53 | let y = l(x, t[2]) | |
54 | 54 | if ((u == 3)) | |
55 | 55 | then y | |
56 | 56 | else { | |
57 | 57 | let z = l(y, t[3]) | |
58 | 58 | if ((u == 4)) | |
59 | 59 | then z | |
60 | 60 | else { | |
61 | 61 | let A = l(z, t[4]) | |
62 | 62 | if ((u == 5)) | |
63 | 63 | then A | |
64 | 64 | else { | |
65 | 65 | let B = l(A, t[5]) | |
66 | 66 | if ((u == 6)) | |
67 | 67 | then B | |
68 | 68 | else { | |
69 | 69 | let C = l(B, t[6]) | |
70 | 70 | if ((u == 7)) | |
71 | 71 | then C | |
72 | 72 | else { | |
73 | 73 | let D = l(C, t[7]) | |
74 | 74 | if ((u == 8)) | |
75 | 75 | then D | |
76 | 76 | else { | |
77 | 77 | let E = l(D, t[8]) | |
78 | 78 | if ((u == 9)) | |
79 | 79 | then E | |
80 | 80 | else { | |
81 | 81 | let F = l(E, t[9]) | |
82 | 82 | if ((u == 10)) | |
83 | 83 | then F | |
84 | 84 | else { | |
85 | 85 | let G = l(F, t[10]) | |
86 | 86 | throw("List size exceed 10") | |
87 | 87 | } | |
88 | 88 | } | |
89 | 89 | } | |
90 | 90 | } | |
91 | 91 | } | |
92 | 92 | } | |
93 | 93 | } | |
94 | 94 | } | |
95 | 95 | } | |
96 | 96 | } | |
97 | 97 | } | |
98 | 98 | } | |
99 | 99 | WriteSet(nil) | |
100 | 100 | } | |
101 | 101 | ||
102 | 102 | ||
103 | 103 | ||
104 | 104 | @Callable(o) | |
105 | 105 | func defineScalping (H,p,I,J) = { | |
106 | 106 | let q = toBase58String(o.caller.bytes) | |
107 | 107 | let K = extract(o.payment) | |
108 | 108 | let L = f(q) | |
109 | 109 | let M = getIntegerValue(b, "waves_usd_2") | |
110 | 110 | if ((100000000 >= K.amount)) | |
111 | 111 | then throw(("Amount under of required: " + toString(K.amount))) | |
112 | 112 | else { | |
113 | 113 | let N = [5, 4, 3, 2, 1] | |
114 | 114 | let s = { | |
115 | 115 | let O = N | |
116 | 116 | let P = size(O) | |
117 | 117 | let Q = nil | |
118 | 118 | if ((P == 0)) | |
119 | 119 | then Q | |
120 | 120 | else { | |
121 | 121 | let R = k(Q, O[0]) | |
122 | 122 | if ((P == 1)) | |
123 | 123 | then R | |
124 | 124 | else { | |
125 | 125 | let S = k(R, O[1]) | |
126 | 126 | if ((P == 2)) | |
127 | 127 | then S | |
128 | 128 | else { | |
129 | 129 | let T = k(S, O[2]) | |
130 | 130 | if ((P == 3)) | |
131 | 131 | then T | |
132 | 132 | else { | |
133 | 133 | let U = k(T, O[3]) | |
134 | 134 | if ((P == 4)) | |
135 | 135 | then U | |
136 | 136 | else { | |
137 | 137 | let V = k(U, O[4]) | |
138 | 138 | if ((P == 5)) | |
139 | 139 | then V | |
140 | 140 | else { | |
141 | 141 | let W = k(V, O[5]) | |
142 | 142 | if ((P == 6)) | |
143 | 143 | then W | |
144 | 144 | else { | |
145 | 145 | let X = k(W, O[6]) | |
146 | 146 | if ((P == 7)) | |
147 | 147 | then X | |
148 | 148 | else { | |
149 | 149 | let Y = k(X, O[7]) | |
150 | 150 | if ((P == 8)) | |
151 | 151 | then Y | |
152 | 152 | else { | |
153 | 153 | let Z = k(Y, O[8]) | |
154 | 154 | if ((P == 9)) | |
155 | 155 | then Z | |
156 | 156 | else { | |
157 | 157 | let aa = k(Z, O[9]) | |
158 | 158 | if ((P == 10)) | |
159 | 159 | then aa | |
160 | 160 | else { | |
161 | 161 | let ab = k(aa, O[10]) | |
162 | 162 | throw("List size exceed 10") | |
163 | 163 | } | |
164 | 164 | } | |
165 | 165 | } | |
166 | 166 | } | |
167 | 167 | } | |
168 | 168 | } | |
169 | 169 | } | |
170 | 170 | } | |
171 | 171 | } | |
172 | 172 | } | |
173 | 173 | } | |
174 | 174 | } | |
175 | 175 | WriteSet(nil) | |
176 | 176 | } | |
177 | 177 | } | |
178 | 178 | ||
179 | 179 | ||
180 | 180 | ||
181 | 181 | @Callable(o) | |
182 | - | func | |
182 | + | func createScalper (H,ac,g) = { | |
183 | 183 | let q = toBase58String(o.caller.bytes) | |
184 | 184 | let L = f(g) | |
185 | - | WriteSet([DataEntry((L + "_ | |
185 | + | WriteSet([DataEntry((L + "_scalperID"), g), DataEntry((L + "_title"), H), DataEntry((L + "_type"), ac), DataEntry((L + "_grid"), 0), DataEntry((L + "_steps"), 0), DataEntry((L + "_lifetime"), 0), DataEntry((L + "_ordering"), "middle"), DataEntry((L + "_reOrderOut"), "middle"), DataEntry((L + "_fundraised"), 0), DataEntry((L + "_priceOpen"), 0), DataEntry((L + "_priceClose"), 0), DataEntry((L + "_upOutGTD"), 0), DataEntry((L + "_downOutGTD"), 0), DataEntry((L + "_profit"), 0), DataEntry((L + "_profitFee"), 0), DataEntry((L + "_gridAsk"), "undefined asks"), DataEntry((L + "_gridBid"), "undefined bids"), DataEntry((L + "_blockStart"), 0), DataEntry((L + "_blockStop"), 0), DataEntry((L + "_status"), "created")]) | |
186 | 186 | } | |
187 | 187 | ||
188 | 188 | ||
189 | 189 | ||
190 | 190 | @Callable(o) | |
191 | - | func | |
191 | + | func defineScalper (H,g,ad,ae,af,ag,ah) = { | |
192 | 192 | let q = toBase58String(o.caller.bytes) | |
193 | 193 | let L = f(g) | |
194 | - | WriteSet([DataEntry((L + "_ | |
194 | + | WriteSet([DataEntry((L + "_grid"), ad), DataEntry((L + "_steps"), ae), DataEntry((L + "_lifetime"), af), DataEntry((L + "_ordering"), ag), DataEntry((L + "_reOrderOut"), ah), DataEntry((L + "_status"), "defined")]) | |
195 | 195 | } | |
196 | 196 | ||
197 | 197 |
github/deemru/w8io/026f985 48.69 ms ◑