- Home /
Question by
LiakhimAsenhold · Apr 08, 2021 at 03:25 AM ·
shaderbuild-erroruniversal
Custom Shader not working on build (Windows and URP)
Hello! I have a shader that i made using the Shader Graph for a simple dither effect:
On the editor is working as intended, but in my build i only see a pink color, like when there is a missing texture, is there something i might need to set different in the settings?
Also, im calling the material with this shader in a OnTriggerEnter script like this
using UnityEngine;
private Renderer ditherRender;
public GameObject WestDoor;
public Shader shader2;
private void OnTriggerEnter(Collider other)
{
if (other.tag == "WDoor_I")
{
ditherRender = WestDoor.GetComponent<Renderer>();
ditherRender.material.shader = shader2;
}
}
Thanks in advance for reading and your time.
sg.png
(123.5 kB)
Comment