AQUAS shaders are failing to compile in Unity 2018.1.0f2 - How to fix these?
Hey!
AQUAS shaders are failing to compile in Unity 2018.1.0f2 Personal (64 Bit).
These shaders from AQUAS seem to be failing in compilation:
Bubble
Camera Effects -> Wet Lens
Caustics
Desktop and Web -> Double-Sided -> Double-Textured
Desktop and Web -> Double-Sided -> River
Desktop and Web -> Double-Sided -> Single-Textured
Desktop and Web -> Double-Sided -> Triple-Textured Bumpy
Desktop and Web -> One-Sided -> Double-Textured
I’m having these errors and warnings after I added the basic water with Aquas in my Scene:
Shader error in 'AQUAS/Caustics': syntax error: unexpected token ';' at line 142 (on d3d11)
Compiling Vertex program with UNITY_PASS_FORWARDADD POINT
Platform defines: UNITY_ENABLE_REFLECTION_BUFFERS UNITY_USE_DITHER_MASK_FOR_ALPHABLENDED_SHADOWS UNITY_PBS_USE_BRDF1 UNITY_SPECCUBE_BOX_PROJECTION UNITY_SPECCUBE_BLENDING UNITY_ENABLE_DETAIL_NORMALMAP SHADER_API_DESKTOP UNITY_LIGHT_PROBE_PROXY_VOLUME UNITY_LIGHTMAP_RGBM_ENCODING
Shader warning in 'AQUAS/Caustics': 'UNITY_PASS_FORWARDADD' : macro redefinition at line 99 (on d3d11)
Compiling Vertex program with UNITY_PASS_FORWARDADD POINT
Platform defines: UNITY_ENABLE_REFLECTION_BUFFERS UNITY_USE_DITHER_MASK_FOR_ALPHABLENDED_SHADOWS UNITY_PBS_USE_BRDF1 UNITY_SPECCUBE_BOX_PROJECTION UNITY_SPECCUBE_BLENDING UNITY_ENABLE_DETAIL_NORMALMAP SHADER_API_DESKTOP UNITY_LIGHT_PROBE_PROXY_VOLUME UNITY_LIGHTMAP_RGBM_ENCODING
Shader error in 'AQUAS/Desktop and Web/Double-Sided/Triple-Textured Bumpy': syntax error: unexpected token ';' at line 510 (on d3d11)
Compiling Vertex program with UNITY_PASS_FORWARDADD POINT
Platform defines: UNITY_ENABLE_REFLECTION_BUFFERS UNITY_USE_DITHER_MASK_FOR_ALPHABLENDED_SHADOWS UNITY_PBS_USE_BRDF1 UNITY_SPECCUBE_BOX_PROJECTION UNITY_SPECCUBE_BLENDING UNITY_ENABLE_DETAIL_NORMALMAP SHADER_API_DESKTOP UNITY_LIGHT_PROBE_PROXY_VOLUME UNITY_LIGHTMAP_RGBM_ENCODING
Shader warning in 'AQUAS/Desktop and Web/Double-Sided/Triple-Textured Bumpy': 'UNITY_PASS_FORWARDADD' : macro redefinition at line 344 (on d3d11)
Compiling Vertex program with UNITY_PASS_FORWARDADD POINT
Platform defines: UNITY_ENABLE_REFLECTION_BUFFERS UNITY_USE_DITHER_MASK_FOR_ALPHABLENDED_SHADOWS UNITY_PBS_USE_BRDF1 UNITY_SPECCUBE_BOX_PROJECTION UNITY_SPECCUBE_BLENDING UNITY_ENABLE_DETAIL_NORMALMAP SHADER_API_DESKTOP UNITY_LIGHT_PROBE_PROXY_VOLUME UNITY_LIGHTMAP_RGBM_ENCODING
Any advice how to fix these? Thanks for the help!
Answer by DavidLieder · May 16, 2018 at 07:44 PM
I noticed this happening also. The error " syntax error: unexpected token ';'" is actually referring to LIGHT_ATTENUATION, which is deprecated.
LIGHT_ATTENUATION has been deprecated since Unity 5 shipped in 2015. It was replaced with UNITY_LIGHT_ATTENUATION. Note the various TRANSFER_SHADOW macros were also deprecated. See this tutorial for how to update your shaders to work.
http://catlikecoding.com/unity/tutorials/rendering/part-17/
Also you can refer to this post: https://forum.unity.com/threads/missing-changed-light_attenuation-macro.511767/
Your answer