I have two function nodes and I want to add them together. Both work well, but when I want to do something with them, an error occurs. This happens not only with adding.
this is just an example.
I'm defining the Function via File. Both files are the same, except one returns red, and the second blue. Code:
//UNITY_SHADER_NO_UPGRADE
#ifndef MYHLSLINCLUDE_INCLUDED
#define MYHLSLINCLUDE_INCLUDED
void Function1_float(out float4 Red)
{
Red = float4(1, 0, 0, 0);
}
#endif //MYHLSLINCLUDE_INCLUDED
I used this guide to create them: Unity Manual - Custom Function