forked from Slazanger/SMT
-
Notifications
You must be signed in to change notification settings - Fork 0
/
MapColours.cs
270 lines (205 loc) · 8.04 KB
/
MapColours.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
using System.ComponentModel;
using System.Windows.Media;
namespace SMT
{
public class MapColours
{
[Category("Incursion")]
[DisplayName("Active Incursion")]
public Color ActiveIncursionColour { get; set; }
[Category("Character")]
[DisplayName("Highlight")]
public Color CharacterHighlightColour { get; set; }
[Category("Character")]
[DisplayName("Text")]
public Color CharacterTextColour { get; set; }
[Category("Character")]
[DisplayName("OfflineText")]
public Color CharacterOfflineTextColour { get; set; }
[Category("Character")]
[DisplayName("Fleet Member Text")]
public Color FleetMemberTextColour { get; set; }
[Category("Character")]
[DisplayName("Text Size")]
public int CharacterTextSize { get; set; }
[Category("Gates")]
[DisplayName("Constellation")]
public Color ConstellationGateColour { get; set; }
[Category("Gates")]
[DisplayName("Region")]
public Color RegionGateColour { get; set; }
[Category("SOV")]
[DisplayName("Constellation Highlight")]
public Color ConstellationHighlightColour { get; set; }
[Category("ESI Data")]
[DisplayName("Overlay")]
public Color ESIOverlayColour { get; set; }
[Category("Jump Bridges")]
[DisplayName("Friendly")]
public Color FriendlyJumpBridgeColour { get; set; }
[Category("Jump Bridges")]
[DisplayName("Disabled")]
public Color DisabledJumpBridgeColour { get; set; }
[Category("Universe")]
[DisplayName("System")]
public Color UniverseSystemColour { get; set; }
[Category("Universe")]
[DisplayName("Constellation Gate")]
public Color UniverseConstellationGateColour { get; set; }
[Category("Universe")]
[DisplayName("Region Gate")]
public Color UniverseRegionGateColour { get; set; }
[Category("Universe")]
[DisplayName("Gate")]
public Color UniverseGateColour { get; set; }
[Category("Universe")]
[DisplayName("System Text")]
public Color UniverseSystemTextColour { get; set; }
[Category("Universe")]
[DisplayName("Map Background")]
public Color UniverseMapBackgroundColour { get; set; }
[Category("Systems")]
[DisplayName("In Region")]
public Color InRegionSystemColour { get; set; }
[Category("Systems")]
[DisplayName("In Region Text")]
public Color InRegionSystemTextColour { get; set; }
[Category("Intel")]
[DisplayName("Clear")]
public Color IntelClearOverlayColour { get; set; }
[Category("Intel")]
[DisplayName("Warning")]
public Color IntelOverlayColour { get; set; }
[Category("Navigation")]
[DisplayName("In Range")]
public Color JumpRangeInColour { get; set; }
[Category("Navigation")]
[DisplayName("In Range Highlight")]
public Color JumpRangeInColourHighlight { get; set; }
[Category("Navigation")]
[DisplayName("Jump Overlap Highlight")]
public Color JumpRangeOverlapHighlight { get; set; }
[Category("General")]
[DisplayName("Map Background")]
public Color MapBackgroundColour { get; set; }
[Browsable(false)]
public string Name { get; set; }
[Category("Gates")]
[DisplayName("Normal")]
public Color NormalGateColour { get; set; }
[Category("Systems")]
[DisplayName("Out of Region")]
public Color OutRegionSystemColour { get; set; }
[Category("Systems")]
[DisplayName("Out of Region Text")]
public Color OutRegionSystemTextColour { get; set; }
[Category("Popup")]
[DisplayName("Background")]
public Color PopupBackground { get; set; }
[Category("Popup")]
[DisplayName("Text")]
public Color PopupText { get; set; }
[Category("General")]
[DisplayName("Region Marker Zoomed")]
public Color RegionMarkerTextColour { get; set; }
[Category("General")]
[DisplayName("Region Marker")]
public Color RegionMarkerTextColourFull { get; set; }
[Category("General")]
[DisplayName("Selected System")]
public Color SelectedSystemColour { get; set; }
[Category("General")]
[DisplayName("System Popup")]
public bool ShowSystemPopup { get; set; }
[Category("SOV")]
[DisplayName("Structure Vunerable")]
public Color SOVStructureVunerableColour { get; set; }
[Category("SOV")]
[DisplayName("Structure Vunerable Soon")]
public Color SOVStructureVunerableSoonColour { get; set; }
[Category("Systems")]
[DisplayName("Outline")]
public Color SystemOutlineColour { get; set; }
[Category("Systems")]
[DisplayName("Name Size")]
public int SystemTextSize { get; set; }
[Category("Systems")]
[DisplayName("Name Subtext Size")]
public int SystemSubTextSize { get; set; }
[Category("Thera")]
[DisplayName("Thera Entrance (Region)")]
public Color TheraEntranceRegion { get; set; }
[Category("Thera")]
[DisplayName("Thera Entrance (System)")]
public Color TheraEntranceSystem { get; set; }
[Browsable(false)]
public bool UserEditable { get; set; }
[Category("Zkill")]
[DisplayName("Data Overlay")]
public Color ZKillDataOverlay { get; set; }
public static Color GetSecStatusColour(double secStatus, bool GradeTrueSec)
{
/*
Note : these are rounded to the nearest 0.1..
#FF2FEFEF 1.0
#FF48F0C0 0.9
#FF00EF47 0.8
#FF00F000 0.7
#FF8FEF2F 0.6
#FFEFEF00 0.5
#FFD77700 0.4
#FFF06000 0.3
#FFF04800 0.2
#FFD73000 0.1
#FFF00000 0.0
*/
Color secCol = (Color)ColorConverter.ConvertFromString("#FFF00000");
if (GradeTrueSec && secStatus < 0.0)
{
secCol.R = (byte)(60 + (1.0 - (secStatus / -1.0)) * 195);
}
if (secStatus > 0.05)
{
secCol = (Color)ColorConverter.ConvertFromString("#FFD73000");
}
if (secStatus > 0.15)
{
secCol = (Color)ColorConverter.ConvertFromString("#FFF04800");
}
if (secStatus > 0.25)
{
secCol = (Color)ColorConverter.ConvertFromString("#FFF06000");
}
if (secStatus > 0.35)
{
secCol = (Color)ColorConverter.ConvertFromString("#FFD77700");
}
if (secStatus > 0.45)
{
secCol = (Color)ColorConverter.ConvertFromString("#FFEFEF00");
}
if (secStatus > 0.55)
{
secCol = (Color)ColorConverter.ConvertFromString("#FF8FEF2F");
}
if (secStatus > 0.65)
{
secCol = (Color)ColorConverter.ConvertFromString("#FF00F000");
}
if (secStatus > 0.75)
{
secCol = (Color)ColorConverter.ConvertFromString("#FF00EF47");
}
if (secStatus > 0.85)
{
secCol = (Color)ColorConverter.ConvertFromString("#FF48F0C0");
}
if (secStatus > 0.95)
{
secCol = (Color)ColorConverter.ConvertFromString("#FF2FEFEF");
}
return secCol;
}
public override string ToString() => Name;
}
}