diff --git a/custom_components/animated_scenes/animations.py b/custom_components/animated_scenes/animations.py index 41478e8..c9e0d0d 100644 --- a/custom_components/animated_scenes/animations.py +++ b/custom_components/animated_scenes/animations.py @@ -436,6 +436,10 @@ def build_light_attributes(self, light: str, initial: bool = False) -> dict[str, attributes["brightness"] = self.get_static_or_random(color[CONF_BRIGHTNESS]) elif self._animate_brightness and self._global_brightness is not None: attributes["brightness"] = self.get_static_or_random(self._global_brightness) + elif isinstance(self._global_brightness, int): + attributes["brightness"] = self._global_brightness + elif isinstance(self._global_brightness, list): + _LOGGER.warning("Global brightness is a list but animate_brightness is False, ignoring") if CONF_BRIGHTNESS in color and color[CONF_COLOR_ONE_CHANGE_PER_TICK]: self._light_status[light] = {