Merge pull request #44 from devZoGok/bf-34-hide-complex-nodes

Bf 34 hide complex nodes
This commit is contained in:
devZoGok
2024-06-11 17:43:17 +00:00
committed by GitHub
+11 -1
View File
@@ -43,7 +43,17 @@ namespace vb01{
}
void Node::update(){
if(visible){
bool render = true;
Node *ancestor = this;
while(ancestor){
render = ancestor->isVisible();
ancestor = ancestor->getParent();
if(!render) break;
}
if(render){
for(Light *l : lights)
l->update();