Refactor EntityList and prevent World to invalidate its own handles between updates

This commit is contained in:
Lynix
2017-04-20 23:42:45 +02:00
parent 0a75bce99d
commit 48b348135e
9 changed files with 231 additions and 144 deletions

View File

@@ -0,0 +1,14 @@
// Copyright (C) 2017 Jérôme Leclercq
// This file is part of the "Nazara Development Kit"
// For conditions of distribution and use, see copyright notice in Prerequesites.hpp
#include <NDK/EntityList.hpp>
#include <NDK/World.hpp>
namespace Ndk
{
const EntityHandle& EntityList::iterator::operator*() const
{
return m_list->GetWorld()->GetEntity(static_cast<EntityId>(m_nextEntityId));
}
}