unity disable sprite rendere on trigger code example
Example: how to turn off sprite renderer in unity
public Renderer rend;
void Start()
{
rend = GetComponent<Renderer>();
rend.enabled = true;
}
public Renderer rend;
void Start()
{
rend = GetComponent<Renderer>();
rend.enabled = true;
}