diff options
| author | Selene ToyKeeper | 2020-09-24 09:06:27 -0600 |
|---|---|---|
| committer | Selene ToyKeeper | 2020-09-24 09:06:27 -0600 |
| commit | a650fcfa5f1e81a25a9879b25cbb48cc04327b44 (patch) | |
| tree | 7d18cfc8dad1d10c95d10abfe394b2513ea27206 /spaghetti-monster | |
| parent | re-added features to build targets which were too big before (diff) | |
| download | anduril-a650fcfa5f1e81a25a9879b25cbb48cc04327b44.tar.gz anduril-a650fcfa5f1e81a25a9879b25cbb48cc04327b44.tar.bz2 anduril-a650fcfa5f1e81a25a9879b25cbb48cc04327b44.zip | |
fixed bug: zero clicks in ceiling config set ceiling to nonsense value
Diffstat (limited to 'spaghetti-monster')
| -rw-r--r-- | spaghetti-monster/anduril/ramp-mode.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/spaghetti-monster/anduril/ramp-mode.c b/spaghetti-monster/anduril/ramp-mode.c index 695c3a2..b2c5102 100644 --- a/spaghetti-monster/anduril/ramp-mode.c +++ b/spaghetti-monster/anduril/ramp-mode.c @@ -410,11 +410,11 @@ void ramp_config_save(uint8_t step, uint8_t value) { uint8_t style = ramp_style; if (current_state == simple_ui_config_state) style = 2; - // ceiling value is inverted - if (step == 2) value = MAX_LEVEL + 1 - value; - // save adjusted value to the correct slot if (value) { + // ceiling value is inverted + if (step == 2) value = MAX_LEVEL + 1 - value; + // which option are we configuring? // TODO? maybe rearrange definitions to avoid the need for this table // (move all ramp values into a single array?) |
