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
|
using grapher.Models.Options;
namespace grapher.Layouts
{
public abstract class LayoutBase
{
public const string Acceleration = "Acceleration";
public const string GrowthRate = "Growth Rate";
public const string DecayRate = "Decay Rate";
public const string Scale = "Scale";
public const string Exponent = "Exponent";
public const string OutputOffset = "Output Offset";
public const string PowerClassic = "Power";
public const string Limit = "Limit";
public const string Midpoint = "Midpoint";
public const string Motivity = "Motivity";
public const string InputOffset = "Input Offset";
public const string CapType = "Cap Type";
public const string Weight = "Weight";
public const string Smooth = "Smooth";
public const string Gain = "Gain";
public const string Input = "Input";
public const string Output = "Output";
public LayoutBase()
{
DecayRateLayout = new OptionLayout(false, string.Empty);
GrowthRateLayout = new OptionLayout(false, string.Empty);
SmoothLayout = new OptionLayout(false, string.Empty);
ClassicCapLayout = new OptionLayout(false, string.Empty);
PowerCapLayout = new OptionLayout(false, string.Empty);
InputJumpLayout = new OptionLayout(false, string.Empty);
InputOffsetLayout = new OptionLayout(false, string.Empty);
LimitLayout = new OptionLayout(false, string.Empty);
PowerClassicLayout = new OptionLayout(false, string.Empty);
ExponentLayout = new OptionLayout(false, string.Empty);
OutputJumpLayout = new OptionLayout(false, string.Empty);
OutputOffsetLayout = new OptionLayout(false, string.Empty);
MidpointLayout = new OptionLayout(false, string.Empty);
LutTextLayout = new OptionLayout(false, string.Empty);
LutPanelLayout = new OptionLayout(false, string.Empty);
LutApplyOptionsLayout = new OptionLayout(false, string.Empty);
GainSwitchOptionLayout = new OptionLayout(false, string.Empty);
LogarithmicCharts = false;
}
public AccelMode Mode { get; protected set; }
public string Name { get; protected set; }
public virtual string ActiveName { get => Name; }
public bool LogarithmicCharts { get; protected set; }
protected OptionLayout DecayRateLayout { get; set; }
protected OptionLayout GrowthRateLayout { get; set; }
protected OptionLayout SmoothLayout { get; set; }
protected OptionLayout ClassicCapLayout { get; set; }
protected OptionLayout PowerCapLayout { get; set; }
protected OptionLayout InputJumpLayout { get; set; }
protected OptionLayout InputOffsetLayout { get; set; }
protected OptionLayout LimitLayout { get; set; }
protected OptionLayout PowerClassicLayout { get; set; }
protected OptionLayout ExponentLayout { get; set; }
protected OptionLayout OutputJumpLayout { get; set; }
protected OptionLayout OutputOffsetLayout { get; set; }
protected OptionLayout MidpointLayout { get; set; }
protected OptionLayout LutTextLayout { get; set; }
protected OptionLayout LutPanelLayout { get; set; }
protected OptionLayout LutApplyOptionsLayout { get; set; }
protected OptionLayout GainSwitchOptionLayout { get; set; }
public override string ToString()
{
return Name;
}
public void Layout(
IOption gainSwitchOption,
IOption classicCapOption,
IOption powerCapOption,
IOption decayRateOption,
IOption growthRateOption,
IOption smoothOption,
IOption inputJumpOption,
IOption inputOffsetOption,
IOption limitOption,
IOption powerClassicOption,
IOption expOption,
IOption outputJumpOption,
IOption outputOffsetOption,
IOption midpointOption,
IOption lutTextOption,
IOption lutPanelOption,
IOption lutApplyOption,
int top)
{
IOption previous = null;
foreach (var option in new (OptionLayout, IOption)[] {
(GainSwitchOptionLayout, gainSwitchOption),
(ClassicCapLayout, classicCapOption),
(PowerCapLayout, powerCapOption),
(DecayRateLayout, decayRateOption),
(GrowthRateLayout, growthRateOption),
(SmoothLayout, smoothOption),
(InputJumpLayout, inputJumpOption),
(InputOffsetLayout, inputOffsetOption),
(LimitLayout, limitOption),
(PowerClassicLayout, powerClassicOption),
(ExponentLayout, expOption),
(OutputJumpLayout, outputJumpOption),
(OutputOffsetLayout, outputOffsetOption),
(MidpointLayout, midpointOption),
(LutTextLayout, lutTextOption),
(LutPanelLayout, lutPanelOption),
(LutApplyOptionsLayout, lutApplyOption)})
{
option.Item1.Layout(option.Item2);
if (option.Item2.Visible)
{
if (previous != null)
{
option.Item2.SnapTo(previous);
}
else
{
option.Item2.Top = top;
}
previous = option.Item2;
}
}
}
public void Layout(
IOption gainSwitchOption,
IOption classicCapOption,
IOption powerCapOption,
IOption decayRateOption,
IOption growthRateOption,
IOption smoothOption,
IOption inputJumpOption,
IOption inputOffsetOption,
IOption limitOption,
IOption powerClassicOption,
IOption expOption,
IOption outputJumpOption,
IOption outputOffsetOption,
IOption midpointOption,
IOption lutTextOption,
IOption lutPanelOption,
IOption lutApplyOption)
{
Layout(gainSwitchOption,
classicCapOption,
powerCapOption,
decayRateOption,
growthRateOption,
smoothOption,
inputJumpOption,
inputOffsetOption,
limitOption,
powerClassicOption,
expOption,
outputJumpOption,
outputOffsetOption,
midpointOption,
lutTextOption,
lutPanelOption,
lutApplyOption,
gainSwitchOption.Top);
}
}
}
|