Hello, I’ve been trying to figure out why whenever I use a script place an object down with this line of code, the object gets a weird shader effect where the brights are really bright–kind of shiny:
GameObject clone = Instantiate(objectToPlace, hit.collider.transform.position, hit.collider.transform.rotation) as GameObject;
clone.transform.parent = hit.collider.transform;
I’ve tried parenting the object to a different transform, and the effect goes away. The parent object is simply a cube without its mesh renderer active, so I’m not sure why it’s being weird. The only difference between that parent and a parent that makes the effect go away is that the cube was previously instantiated (as part of a grid system). The code to do this is:
gos[i,j] = Instantiate(Resources.Load("Cell")) as GameObject;
And then it is assigned a layer. I can’t think of anything else out of the ordinary. Any help would be appreciated!