Platform Dependent Compilation for WebGL?

I want to run code that only is activated for WebGL, the same way you would only run code on Android ( #IF UNITY_ANDROID).

Does #IF UNITY_WEBGL exist or an equivalent to it exist?

Cheers.

1 Like

Yes. (And thanks for reminding me, I’ll add it to the docs!).

@jonas-echterhoff_1 thanks for confirming it, and no problem!

1 Like