Inner Gamer: read the animated hue while composing so the colors keep cycling

This commit is contained in:
FX192 authored and Kurt Himebauch committed 2026-10-23 11:20:34 -04:00
1 parent c7961bdacf
commit 6b010baa9e
1 file changed
+2 -2
@@ -173,6 +173,6 @@ private fun InnerGamerHue(speed: Int) {
val hue by rememberInfiniteTransition(label = "innerGamer").animateFloat(
0f, 360f, infiniteRepeatable(tween(Motion.ms(Themes.rgbCycleMillis(speed)).coerceAtLeast(1), easing = LinearEasing), RepeatMode.Restart), label = "hue",
)
val step = Themes.RGB_HUE_STEP
SideEffect { Themes.moveRgbHue((hue / step).toInt() * step) }
val stepped = (hue / Themes.RGB_HUE_STEP).toInt() * Themes.RGB_HUE_STEP
SideEffect { Themes.moveRgbHue(stepped) }
}