Пример #1
0
		void update(float frameTime){
			removeDeadEntities();
			iterating = true;
			for (auto& entity : entities){
				entity->update(frameTime);
			}
			iterating = false;
			addQueueComponents();
		}
Пример #2
0
void ETHEntityArray::unique()
{
	removeDeadEntities();
	std::set<ETHEntityRawPtr> entitySet;
	for (std::vector<ETHEntityRawPtr>::iterator iter = m_vector.begin(); iter != m_vector.end(); ++iter)
	{
		entitySet.insert(*iter);
	}
	clear();
	for (std::set<ETHEntityRawPtr>::iterator iter = entitySet.begin(); iter != entitySet.end(); ++iter)
	{
		push_back(*iter);
	}
}