- Home /
Ignoring Rendering
I am making a Mobile terrain with 2 floors. Is there a way to not render the gameobjects on the second floor. The second floor terrain can not be seen from the bottom terrain because of the back face culling (that is perfect), but all the game objects are floating. Is there a way for them not to be seen? My idea is to set a layer for all the game objects on the terrain above and not let the camera see that layer instill the player hits a trigger to activate the layer. Good idea?? Is there anyone with a different solution? & Is it possible to activate a deactivate layers while in game play?
Yes you can change the layer in runtime I do this on one of my game. And I use this method to show/hide some element function of my gamestate.
Same method than you :)
the easy way is just to turn off the renderer of any game object you don't want to see:
myObject.renderer.enabled = false;
http://docs.unity3d.com/Documentation/ScriptReference/Renderer-enabled.html
are you saying that when you look up from the bottom you can't see the cieling but you can see the objects resting on them?
yes you can if you don't disabled the collider :).
Both methods work !
Your answer
Follow this Question
Related Questions
Can't use material with shaders which need tangent geometry on terrain. 1 Answer
Terrain into Model 0 Answers
Noob Question - Custom trees and aliasing 1 Answer
rendering things in order 0 Answers
Improved Graphics for Terrain 1 Answer