- Home /
Why does an object change color depending on where I look
I made a scene with a Player which can move and look around, and a big dark blue rectangle as the floor. However, when I look forward the rectangle looks gray/light blue.
However, when I look straight down it is the color its supposed to be(dark blue).
I also put walls around before with the same color and the same thing happened, they were gray.
Answer by Eno-Khaon · Jan 19, 2021 at 07:20 PM
Assuming you haven't done anything else yourself, the floor is using the Standard shader, built on the principles of "Physically-Based Rendering" (often referred to as PBR). A common attribute of "realistic" materials is that they reflect different amounts of light when viewed at a steep angle.
In this case, you're likely seeing the color of the skybox (light blue) being blended into your ground, further mixed in with a greater brightness attributed to "Rim Lighting" (likely white), also provided by the same shader.
Is there a way to change the material/shader so this doesnt happen?
If you create a new $$anonymous$$aterial, it will also have the Standard shader assigned to it, but it will be configurable. You can try changing the properties of that Shader or assign a new one (or even create your own Shader and assign it to the $$anonymous$$aterial).
At any time during this, you can apply the $$anonymous$$aterial onto your GameObject (the floor) to see the immediate results of any changes you're making to it.
So far, nothing has worked. Also, I changed the color of the skybox and the color of the rectangle stayed the same.