diff --git a/src/effect_cycle.cpp b/src/effect_cycle.cpp index 00ac92b..4a724ca 100644 --- a/src/effect_cycle.cpp +++ b/src/effect_cycle.cpp @@ -2,10 +2,12 @@ void CycleEffect::changeEffect() { Effect* new_effect; + int new_id; do { - int new_id = random8(cycle_effects->size()); + new_id = random8(cycle_effects->size()); new_effect = cycle_effects->get(new_id); } while (&new_effect == &effect); + LOG("CycleEffect * Changing effect to ID "); LOGln(new_id); if (effect) effect->stop(); effect = new_effect; effect->start();