Closed emilberwald closed 3 years ago
Thanks for reporting this 👍
How are you guys getting it working with the .shader files?
How are you guys getting it working with the .shader files?
I #include .hlsl files to be able to separate unity-specific stuff with general shader stuff. I think it worked out of the box for me when I did that, had to update the shader tools config file when I updated Unity is all. Haven't tried with this bugfix yet but it sounds great to have it solved.
Macro argument for UNITY_FOG_COORDS(1) disappears for some reason after pressing Ctrl K + Ctrl D
Minimal example should be something like:
shadertoolsconfig.json:
{ "hlsl.preprocessorDefinitions": { }, "hlsl.additionalIncludeDirectories": [ "C:/Program Files/Unity/Hub/Editor/2020.1.9f1/Editor/Data/CGIncludes" ] }
`#include "UnityCG.cginc"
struct OUTPUT { UNITY_FOG_COORDS(1) };`