tx · A2tX6pNKMBQqB7AhvDfD282TDaN8RnL99xmYkSZAswib 3MwjJKGp7PLGJh7pzYrnrN9TnMXph6oL4nH: -0.05000000 Waves 2019.11.25 10:47 [780504] smart account 3MwjJKGp7PLGJh7pzYrnrN9TnMXph6oL4nH > SELF 0.00000000 Waves
{ "type": 13, "id": "A2tX6pNKMBQqB7AhvDfD282TDaN8RnL99xmYkSZAswib", "fee": 5000000, "feeAssetId": null, "timestamp": 1574668138226, "version": 1, "sender": "3MwjJKGp7PLGJh7pzYrnrN9TnMXph6oL4nH", "senderPublicKey": "9Pw6KBYMgEWmrg24tEc8SkHPhMUBwRmHaJoKjWgDkUAK", "proofs": [ "BH5pigm8U7XBWAhTX3uKRwbCLwzHFmChFxZQsvovXyy5bRwMkRHHzAXKXPrDg245FKZVVH6azSzViB53QJfEZpU" ], "script": "base64:AAIDAAAAAAAAACEIARIDCgEIEgYKBAgICAESCQoHCAgBAQEICBIFCgMICAgAAAAKAAAAAAROT05FAgAAAARub25lAAAAAAZvcmFjbGUJAQAAABxAZXh0clVzZXIoYWRkcmVzc0Zyb21TdHJpbmcpAAAAAQIAAAAjM05BY29lV2RVVFduOGNzWEpQRzQ3djFGanRqY2ZxeGI1dHUAAAAABWFza0lEAgAAAAVXQVZFUwAAAAAFYmlkSUQCAAAABVVTRC1OAAAAAAZtaW5QaXAAAAAAAAAPQkABAAAACGdlbktleUlEAAAAAQAAAARhZGRyCQACWAAAAAEJAAH3AAAAAQkAAZsAAAABCQABLAAAAAIFAAAABGFkZHIJAAQlAAAAAQUAAAAEdGhpcwEAAAAHZ2VuR3JpZAAAAAIAAAABYQAAAAFiAwkAAAAAAAACBQAAAAFhAgAAAAAJAAGkAAAAAQUAAAABYgkAASwAAAACCQABLAAAAAIFAAAAAWECAAAAAXwJAAGkAAAAAQUAAAABYgEAAAAHZ2VuTGlzdAAAAAIAAAABYQAAAAFiCQAETAAAAAIFAAAAAWIFAAAAAWEBAAAACmdlbkxpc3RJbnQAAAACAAA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RW50cnkAAAACCQABLAAAAAIFAAAABWtleUlEAgAAAAlfdXBPdXRHVEQAAAAAAAAAAAAJAARMAAAAAgkBAAAACURhdGFFbnRyeQAAAAIJAAEsAAAAAgUAAAAFa2V5SUQCAAAAC19kb3duT3V0R1REAAAAAAAAAAAACQAETAAAAAIJAQAAAAlEYXRhRW50cnkAAAACCQABLAAAAAIFAAAABWtleUlEAgAAAAdfcHJvZml0AAAAAAAAAAAACQAETAAAAAIJAQAAAAlEYXRhRW50cnkAAAACCQABLAAAAAIFAAAABWtleUlEAgAAAApfcHJvZml0RmVlAAAAAAAAAAAACQAETAAAAAIJAQAAAAlEYXRhRW50cnkAAAACCQABLAAAAAIFAAAABWtleUlEAgAAAAhfZ3JpZEFzawIAAAAOdW5kZWZpbmVkIGFza3MJAARMAAAAAgkBAAAACURhdGFFbnRyeQAAAAIJAAEsAAAAAgUAAAAFa2V5SUQCAAAACF9ncmlkQmlkAgAAAA51bmRlZmluZWQgYmlkcwkABEwAAAACCQEAAAAJRGF0YUVudHJ5AAAAAgkAASwAAAACBQAAAAVrZXlJRAIAAAALX2Jsb2NrU3RhcnQAAAAAAAAAAAAJAARMAAAAAgkBAAAACURhdGFFbnRyeQAAAAIJAAEsAAAAAgUAAAAFa2V5SUQCAAAACl9ibG9ja1N0b3AAAAAAAAAAAAAJAARMAAAAAgkBAAAACURhdGFFbnRyeQAAAAIJAAEsAAAAAgUAAAAFa2V5SUQCAAAAB19zdGF0dXMCAAAAB2NyZWF0ZWQFAAAAA25pbAAAAACbaqc7", "chainId": 84, "height": 780504, "spentComplexity": 0 } View: original | compacted Prev: Cypc9kVJFufe8gUmtjQiGZ4nyXVZWZ8dMeY46P85gCSG Next: EcKzedvCCKgkx4XzfhuwUmc9ApMpfnNtkBEa9MHRRbEi Diff:
Old | New | Differences | |
---|---|---|---|
179 | 179 | ||
180 | 180 | ||
181 | 181 | @Callable(i) | |
182 | - | func defineScalper (title,addr,grid,steps,lifetime,ordering, | |
182 | + | func defineScalper (title,addr,grid,steps,lifetime,ordering,reOrderOut) = { | |
183 | 183 | let sender = toBase58String(i.caller.bytes) | |
184 | 184 | let keyID = genKeyID(addr) | |
185 | - | WriteSet([DataEntry((keyID + "_grid"), | |
185 | + | WriteSet([DataEntry((keyID + "_grid"), grid), DataEntry((keyID + "_steps"), steps), DataEntry((keyID + "_lifetime"), lifetime), DataEntry((keyID + "_ordering"), ordering), DataEntry((keyID + "_reOrderOut"), reOrderOut)]) | |
186 | 186 | } | |
187 | 187 | ||
188 | 188 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 3 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let NONE = "none" | |
5 | 5 | ||
6 | 6 | let oracle = addressFromStringValue("3NAcoeWdUTWn8csXJPG47v1Fjtjcfqxb5tu") | |
7 | 7 | ||
8 | 8 | let askID = "WAVES" | |
9 | 9 | ||
10 | 10 | let bidID = "USD-N" | |
11 | 11 | ||
12 | 12 | let minPip = 1000000 | |
13 | 13 | ||
14 | 14 | func genKeyID (addr) = toBase58String(sha256(toBytes((addr + toString(this))))) | |
15 | 15 | ||
16 | 16 | ||
17 | 17 | func genGrid (a,b) = if ((a == "")) | |
18 | 18 | then toString(b) | |
19 | 19 | else ((a + "|") + toString(b)) | |
20 | 20 | ||
21 | 21 | ||
22 | 22 | func genList (a,b) = b :: a | |
23 | 23 | ||
24 | 24 | ||
25 | 25 | func genListInt (a,b) = { | |
26 | 26 | let parseB = parseIntValue(b) | |
27 | 27 | (a[0] + 2) :: a | |
28 | 28 | } | |
29 | 29 | ||
30 | 30 | ||
31 | 31 | func revListInt (a,b) = b :: a | |
32 | 32 | ||
33 | 33 | ||
34 | 34 | @Callable(i) | |
35 | 35 | func sendGridAsk (gridA) = { | |
36 | 36 | let sender = toBase58String(i.caller.bytes) | |
37 | 37 | let gridAsk = split(gridA, "|") | |
38 | 38 | let ver = { | |
39 | 39 | let $list779812 = gridAsk | |
40 | 40 | let $size779812 = size($list779812) | |
41 | 41 | let $acc0779812 = [69] | |
42 | 42 | if (($size779812 == 0)) | |
43 | 43 | then $acc0779812 | |
44 | 44 | else { | |
45 | 45 | let $acc1779812 = genListInt($acc0779812, $list779812[0]) | |
46 | 46 | if (($size779812 == 1)) | |
47 | 47 | then $acc1779812 | |
48 | 48 | else { | |
49 | 49 | let $acc2779812 = genListInt($acc1779812, $list779812[1]) | |
50 | 50 | if (($size779812 == 2)) | |
51 | 51 | then $acc2779812 | |
52 | 52 | else { | |
53 | 53 | let $acc3779812 = genListInt($acc2779812, $list779812[2]) | |
54 | 54 | if (($size779812 == 3)) | |
55 | 55 | then $acc3779812 | |
56 | 56 | else { | |
57 | 57 | let $acc4779812 = genListInt($acc3779812, $list779812[3]) | |
58 | 58 | if (($size779812 == 4)) | |
59 | 59 | then $acc4779812 | |
60 | 60 | else { | |
61 | 61 | let $acc5779812 = genListInt($acc4779812, $list779812[4]) | |
62 | 62 | if (($size779812 == 5)) | |
63 | 63 | then $acc5779812 | |
64 | 64 | else { | |
65 | 65 | let $acc6779812 = genListInt($acc5779812, $list779812[5]) | |
66 | 66 | if (($size779812 == 6)) | |
67 | 67 | then $acc6779812 | |
68 | 68 | else { | |
69 | 69 | let $acc7779812 = genListInt($acc6779812, $list779812[6]) | |
70 | 70 | if (($size779812 == 7)) | |
71 | 71 | then $acc7779812 | |
72 | 72 | else { | |
73 | 73 | let $acc8779812 = genListInt($acc7779812, $list779812[7]) | |
74 | 74 | if (($size779812 == 8)) | |
75 | 75 | then $acc8779812 | |
76 | 76 | else { | |
77 | 77 | let $acc9779812 = genListInt($acc8779812, $list779812[8]) | |
78 | 78 | if (($size779812 == 9)) | |
79 | 79 | then $acc9779812 | |
80 | 80 | else { | |
81 | 81 | let $acc10779812 = genListInt($acc9779812, $list779812[9]) | |
82 | 82 | if (($size779812 == 10)) | |
83 | 83 | then $acc10779812 | |
84 | 84 | else { | |
85 | 85 | let $acc11779812 = genListInt($acc10779812, $list779812[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(i) | |
105 | 105 | func defineScalping (title,gridA,gridB,step) = { | |
106 | 106 | let sender = toBase58String(i.caller.bytes) | |
107 | 107 | let deposited = extract(i.payment) | |
108 | 108 | let keyID = genKeyID(sender) | |
109 | 109 | let usdV = getIntegerValue(oracle, "waves_usd_2") | |
110 | 110 | if ((100000000 >= deposited.amount)) | |
111 | 111 | then throw(("Amount under of required: " + toString(deposited.amount))) | |
112 | 112 | else { | |
113 | 113 | let arr = [5, 4, 3, 2, 1] | |
114 | 114 | let ver = { | |
115 | 115 | let $list15311555 = arr | |
116 | 116 | let $size15311555 = size($list15311555) | |
117 | 117 | let $acc015311555 = nil | |
118 | 118 | if (($size15311555 == 0)) | |
119 | 119 | then $acc015311555 | |
120 | 120 | else { | |
121 | 121 | let $acc115311555 = genList($acc015311555, $list15311555[0]) | |
122 | 122 | if (($size15311555 == 1)) | |
123 | 123 | then $acc115311555 | |
124 | 124 | else { | |
125 | 125 | let $acc215311555 = genList($acc115311555, $list15311555[1]) | |
126 | 126 | if (($size15311555 == 2)) | |
127 | 127 | then $acc215311555 | |
128 | 128 | else { | |
129 | 129 | let $acc315311555 = genList($acc215311555, $list15311555[2]) | |
130 | 130 | if (($size15311555 == 3)) | |
131 | 131 | then $acc315311555 | |
132 | 132 | else { | |
133 | 133 | let $acc415311555 = genList($acc315311555, $list15311555[3]) | |
134 | 134 | if (($size15311555 == 4)) | |
135 | 135 | then $acc415311555 | |
136 | 136 | else { | |
137 | 137 | let $acc515311555 = genList($acc415311555, $list15311555[4]) | |
138 | 138 | if (($size15311555 == 5)) | |
139 | 139 | then $acc515311555 | |
140 | 140 | else { | |
141 | 141 | let $acc615311555 = genList($acc515311555, $list15311555[5]) | |
142 | 142 | if (($size15311555 == 6)) | |
143 | 143 | then $acc615311555 | |
144 | 144 | else { | |
145 | 145 | let $acc715311555 = genList($acc615311555, $list15311555[6]) | |
146 | 146 | if (($size15311555 == 7)) | |
147 | 147 | then $acc715311555 | |
148 | 148 | else { | |
149 | 149 | let $acc815311555 = genList($acc715311555, $list15311555[7]) | |
150 | 150 | if (($size15311555 == 8)) | |
151 | 151 | then $acc815311555 | |
152 | 152 | else { | |
153 | 153 | let $acc915311555 = genList($acc815311555, $list15311555[8]) | |
154 | 154 | if (($size15311555 == 9)) | |
155 | 155 | then $acc915311555 | |
156 | 156 | else { | |
157 | 157 | let $acc1015311555 = genList($acc915311555, $list15311555[9]) | |
158 | 158 | if (($size15311555 == 10)) | |
159 | 159 | then $acc1015311555 | |
160 | 160 | else { | |
161 | 161 | let $acc1115311555 = genList($acc1015311555, $list15311555[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(i) | |
182 | - | func defineScalper (title,addr,grid,steps,lifetime,ordering, | |
182 | + | func defineScalper (title,addr,grid,steps,lifetime,ordering,reOrderOut) = { | |
183 | 183 | let sender = toBase58String(i.caller.bytes) | |
184 | 184 | let keyID = genKeyID(addr) | |
185 | - | WriteSet([DataEntry((keyID + "_grid"), | |
185 | + | WriteSet([DataEntry((keyID + "_grid"), grid), DataEntry((keyID + "_steps"), steps), DataEntry((keyID + "_lifetime"), lifetime), DataEntry((keyID + "_ordering"), ordering), DataEntry((keyID + "_reOrderOut"), reOrderOut)]) | |
186 | 186 | } | |
187 | 187 | ||
188 | 188 | ||
189 | 189 | ||
190 | 190 | @Callable(i) | |
191 | 191 | func createScalper (title,type,addr) = { | |
192 | 192 | let sender = toBase58String(i.caller.bytes) | |
193 | 193 | let keyID = genKeyID(addr) | |
194 | 194 | WriteSet([DataEntry((keyID + "_scalperID"), addr), DataEntry((keyID + "_title"), title), DataEntry((keyID + "_type"), type), DataEntry((keyID + "_grid"), 0), DataEntry((keyID + "_steps"), 0), DataEntry((keyID + "_lifetime"), 0), DataEntry((keyID + "_ordering"), "middle"), DataEntry((keyID + "_reOrderOut"), "middle"), DataEntry((keyID + "_fundraised"), 0), DataEntry((keyID + "_priceOpen"), 0), DataEntry((keyID + "_priceClose"), 0), DataEntry((keyID + "_upOutGTD"), 0), DataEntry((keyID + "_downOutGTD"), 0), DataEntry((keyID + "_profit"), 0), DataEntry((keyID + "_profitFee"), 0), DataEntry((keyID + "_gridAsk"), "undefined asks"), DataEntry((keyID + "_gridBid"), "undefined bids"), DataEntry((keyID + "_blockStart"), 0), DataEntry((keyID + "_blockStop"), 0), DataEntry((keyID + "_status"), "created")]) | |
195 | 195 | } | |
196 | 196 | ||
197 | 197 |
github/deemru/w8io/026f985 51.75 ms ◑