Addressable Lambda Effect and Brightness

Hello,

I currently try to set up a WS2812 adressable light with ESPhome.
When turning the light (all LEDs) on I have to set the brightness to 50%. I managed to do this with the “on_turn_on” trigger.
When running an effect, esp. the adressable lambda effect, I would like to override this previous setting within the lambda code. Additionally it would be awesome to set it back to 50% when setting the effect to none.
Well so far I was unable to find something that works. Maybe someone has an idea and could help? Thank you in advance

This is how I did the 50% on turn on.

light:
  - platform: neopixelbus
    type: GRB
    variant: WS2812
    pin: GPIO3
    num_leds: 880
    name: "NeoPixel LiquorShelf"
    id: liquorLight
    on_turn_on:
      - logger.log: "Light Turned On!"
      - light.control:
          id: liquorLight
          brightness: 50%
      - switch.turn_on: modulefan

In case someone wants a solution to this, mine is to create a second light and use its value within the lambda of the first. The second light is the one people control.

globals:
  - id: global_magic
    type: int
    restore_value: no
    initial_value: "0"
output:
  - platform: template
    id: magic_out
    type: float
    write_action:
      then:
      - lambda: |-
          id(global_magic) = state*100;
light:
  - platform: monochromatic
    name: "Use this light"
    id: magic_light
    output: magic_out
    gamma_correct: 1
    default_transition_length: 0s
    restore_mode: RESTORE_DEFAULT_OFF

  - platform: neopixelbus
    name: "This light is connected to your pixels"
    effects:
    - addressable_lambda:
        name: "Amazing Effect"
        update_interval: ${update_interval}
        lambda: |-
          int magic = id(global_magic);
          ...insert code here and use magic