We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 19fc42a commit f9a1fd9Copy full SHA for f9a1fd9
1 file changed
src/switch18.cpp
@@ -155,7 +155,12 @@ struct Switch18 : Module, SwitchBase {
155
outputs[STEP_1_OUTPUT + i].setVoltage(signal * volumes[i]);
156
}
157
else {
158
- outputs[STEP_1_OUTPUT + i].setVoltage(signal);
+ if (i == current_step) {
159
+ outputs[STEP_1_OUTPUT + i].setVoltage(signal);
160
+ }
161
+ else {
162
+ outputs[STEP_1_OUTPUT +i].setVoltage(0.f);
163
164
165
lights[STEP_1_LIGHT + i].setBrightness(i == current_step ? 1.f : 0.f);
166
0 commit comments