Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2008-09-21 08:39:40 +0400
committerCampbell Barton <ideasman42@gmail.com>2008-09-21 08:39:40 +0400
commit2064f5542ae8edf0c52bcc104f10696f5b6e3659 (patch)
tree2fd0555aba609d6be2969f92113fc1f0b9400583
parentdeba5ab9a72ad09d935c29790f4af57c9bcb2a3a (diff)
set the visibility state based on the objects render option in the outliner.
- saves adding UV's to faces just to set the invisibility option or having an logic bricks to set the visibility state.
-rw-r--r--source/gameengine/Converter/BL_BlenderDataConversion.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/source/gameengine/Converter/BL_BlenderDataConversion.cpp b/source/gameengine/Converter/BL_BlenderDataConversion.cpp
index ae9b8602500..daa67b147c3 100644
--- a/source/gameengine/Converter/BL_BlenderDataConversion.cpp
+++ b/source/gameengine/Converter/BL_BlenderDataConversion.cpp
@@ -1601,6 +1601,8 @@ static KX_GameObject *gameobject_from_blenderobject(
gameobj->SetPhysicsEnvironment(kxscene->GetPhysicsEnvironment());
gameobj->SetLayer(ob->lay);
gameobj->SetBlenderObject(ob);
+ /* set the visibility state based on the objects render option in the outliner */
+ if(ob->restrictflag & OB_RESTRICT_RENDER) gameobj->SetVisible(0, 0);
}
return gameobj;
}