aboutsummaryrefslogtreecommitdiff
path: root/src/staticobject.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/staticobject.h')
-rw-r--r--src/staticobject.h9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/staticobject.h b/src/staticobject.h
index 575c15b18..95a1b945e 100644
--- a/src/staticobject.h
+++ b/src/staticobject.h
@@ -23,7 +23,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
#include "irrlichttypes_bloated.h"
#include <string>
#include <sstream>
-#include <list>
+#include <vector>
#include <map>
#include "debug.h"
@@ -68,8 +68,7 @@ public:
{
dstream<<"ERROR: StaticObjectList::insert(): "
<<"id already exists"<<std::endl;
- assert(0);
- return;
+ FATAL_ERROR("StaticObjectList::insert()");
}
m_active[id] = obj;
}
@@ -77,7 +76,7 @@ public:
void remove(u16 id)
{
- assert(id != 0);
+ assert(id != 0); // Pre-condition
if(m_active.find(id) == m_active.end())
{
dstream<<"WARNING: StaticObjectList::remove(): id="<<id
@@ -95,7 +94,7 @@ public:
from m_stored and inserted to m_active.
The caller directly manipulates these containers.
*/
- std::list<StaticObject> m_stored;
+ std::vector<StaticObject> m_stored;
std::map<u16, StaticObject> m_active;
private: