How to enable/disable volumetrics of <Light> component via script?

Hi all,
I am trying to enable/disable the volumetrics of the Light component via script.

_light.gameObject.GetComponent().???

The above line unfortunately gives me nothing that points in the direction of volumetrics?
Do I have to cast differently?
My light is a directional light, but this should not play a decisive role.
Does anyone know how to achieve this?

Try GetComponent()

1 Like

Thank you very much, Thermos. You have helped me a lot with this.

affectsVolumetric was the property i needed:

light.gameObject.GetComponent().affectsVolumetric