Leviathan  0.8.0.0
Leviathan game engine
Leviathan::RenderNodePropertiesSystem Class Reference

Handles properties of scene objects that have a changed RenderNode. More...

#include <Systems.h>

Public Member Functions

void Run (GameWorld &world, std::unordered_map< ObjectID, RenderNode * > &index)
 

Detailed Description

Handles properties of scene objects that have a changed RenderNode.

Definition at line 102 of file Systems.h.

Member Function Documentation

◆ Run()

void Leviathan::RenderNodePropertiesSystem::Run ( GameWorld world,
std::unordered_map< ObjectID, RenderNode * > &  index 
)
inline

Definition at line 104 of file Systems.h.

105  {
106  for(auto iter = index.begin(); iter != index.end(); ++iter) {
107 
108  auto& node = *iter->second;
109 
110  if(!node.Marked)
111  continue;
112 
113  // This check being here, may or may not be faster than just always setting it
114  if(node.Node->getActive() != !node.Hidden)
115  node.Node->setActive(!node.Hidden);
116 
117  node.Node->setScale(node.Scale);
118  node.Marked = false;
119  }
120  }

The documentation for this class was generated from the following file: