Index: branches/new_class_id/src/lib/graphics/effects/atmospheric_engine.cc
===================================================================
--- branches/new_class_id/src/lib/graphics/effects/atmospheric_engine.cc	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/effects/atmospheric_engine.cc	(revision 9685)
@@ -22,14 +22,13 @@
 #include "util/loading/load_param.h"
 #include "util/loading/factory.h"
-#include "class_list.h"
 
-
-
+NewObjectListDefinition(AtmosphericEngine);
 
 /**
  * @param root The XML-element to load the AtmosphericEngine from
  */
-AtmosphericEngine::AtmosphericEngine() {
-    this->setClassID(CL_ATMOSPHERIC_ENGINE, "AtmosphericEngine");
+AtmosphericEngine::AtmosphericEngine()
+{
+  this->registerObject(this, AtmosphericEngine::_objectList);
 }
 
@@ -43,13 +42,10 @@
  *  destroys a AtmosphericEngine
  */
-AtmosphericEngine::~AtmosphericEngine() {
-    AtmosphericEngine::singletonRef = NULL;
+AtmosphericEngine::~AtmosphericEngine()
+{
+  AtmosphericEngine::singletonRef = NULL;
 
-    const std::list<BaseObject*>* weatherEffects = ClassList::getList( CL_WEATHER_EFFECT);
-
-    if (weatherEffects != NULL) {
-        while(!weatherEffects->empty())
-            delete weatherEffects->front();
-    }
+  while(!WeatherEffect::objectList().empty())
+    delete WeatherEffect::objectList().front();
 }
 
@@ -57,7 +53,8 @@
  * @param root The XML-element to load the AtmosphericEngine from
  */
-void AtmosphericEngine::loadParams(const TiXmlElement* root) {
-    LoadParamXML(root, "WeatherEffect", this, AtmosphericEngine, loadWeatherEffect);
-    LoadParamXML(root, "SunEffect", this, AtmosphericEngine, loadSunEffect);
+void AtmosphericEngine::loadParams(const TiXmlElement* root)
+{
+  LoadParamXML(root, "WeatherEffect", this, AtmosphericEngine, loadWeatherEffect);
+  LoadParamXML(root, "SunEffect", this, AtmosphericEngine, loadSunEffect);
 }
 
@@ -65,15 +62,16 @@
  * @param root The XML-element to load WeatherEffects from
  */
-void AtmosphericEngine::loadWeatherEffect(const TiXmlElement* root) {
-    LOAD_PARAM_START_CYCLE(root, element);
-    {
-        PRINTF(4)("element is: %s\n", element->Value());
-        // Factory::fabricate(element);
+void AtmosphericEngine::loadWeatherEffect(const TiXmlElement* root)
+{
+  LOAD_PARAM_START_CYCLE(root, element);
+  {
+    PRINTF(4)("element is: %s\n", element->Value());
+    // Factory::fabricate(element);
 
-        BaseObject* bo = Factory::fabricate(element);
-        if( bo == NULL)
-            PRINTF(0)(" Could not create Element %s\n", element->Value());
-    }
-    LOAD_PARAM_END_CYCLE(element);
+    BaseObject* bo = Factory::fabricate(element);
+    if( bo == NULL)
+      PRINTF(0)(" Could not create Element %s\n", element->Value());
+  }
+  LOAD_PARAM_END_CYCLE(element);
 }
 
@@ -81,10 +79,11 @@
  * @param root The XML-element to load SunEffects from
  */
-void AtmosphericEngine::loadSunEffect(const TiXmlElement* root) {
-    LOAD_PARAM_START_CYCLE(root, element);
-    {
-        PRINTF(4)("element is: %s\n", element->Value());
-    }
-    LOAD_PARAM_END_CYCLE(element);
+void AtmosphericEngine::loadSunEffect(const TiXmlElement* root)
+{
+  LOAD_PARAM_START_CYCLE(root, element);
+  {
+    PRINTF(4)("element is: %s\n", element->Value());
+  }
+  LOAD_PARAM_END_CYCLE(element);
 }
 
@@ -93,13 +92,10 @@
  * draws the effect, if needed
  */
-void AtmosphericEngine::draw() const {
-    const std::list<BaseObject*>* weatherEffects = ClassList::getList( CL_WEATHER_EFFECT);
-
-    // draw the weather effects
-    if (weatherEffects != NULL) {
-        std::list<BaseObject*>::const_iterator it;
-        for (it = weatherEffects->begin(); it != weatherEffects->end(); it++)
-            dynamic_cast<WeatherEffect*>(*it)->draw();
-    }
+void AtmosphericEngine::draw() const
+{
+  for (NewObjectList<WeatherEffect>::const_iterator it = WeatherEffect::objectList().begin();
+       it != WeatherEffect::objectList().end();
+       ++it)
+    (*it)->draw();
 }
 
@@ -109,14 +105,10 @@
  * ticks the effect if there is any time dependancy
  */
-void AtmosphericEngine::tick(float dt) {
-    const std::list<BaseObject*>* weatherEffects = ClassList::getList( CL_WEATHER_EFFECT);
+void AtmosphericEngine::tick(float dt)
+{
 
-    // tick the weather effects
-    if (weatherEffects != NULL) {
-        std::list<BaseObject*>::const_iterator it;
-        for (it = weatherEffects->begin(); it != weatherEffects->end(); it++) {
-            /*      printf("%s::%s \n", (*it)->getClassCName(), (*it)->getName());*/
-            dynamic_cast<WeatherEffect*>(*it)->tick(dt);
-        }
-    }
+  for (NewObjectList<WeatherEffect>::const_iterator it = WeatherEffect::objectList().begin();
+       it != WeatherEffect::objectList().end();
+       ++it)
+    (*it)->tick(dt);
 }
Index: branches/new_class_id/src/lib/graphics/effects/atmospheric_engine.h
===================================================================
--- branches/new_class_id/src/lib/graphics/effects/atmospheric_engine.h	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/effects/atmospheric_engine.h	(revision 9685)
@@ -1,5 +1,5 @@
 /*!
  * @file atmospheric_engine.h
- *  
+ *
  */
 
@@ -14,4 +14,5 @@
 class AtmosphericEngine : public BaseObject
 {
+  NewObjectListDeclaration(AtmosphericEngine);
   public:
     ~AtmosphericEngine();
Index: branches/new_class_id/src/lib/graphics/effects/graphics_effect.cc
===================================================================
--- branches/new_class_id/src/lib/graphics/effects/graphics_effect.cc	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/effects/graphics_effect.cc	(revision 9685)
@@ -22,8 +22,5 @@
 #include "util/loading/load_param.h"
 
-
-
-
-
+NewObjectListDefinition(GraphicsEffect);
 
 /**
@@ -33,5 +30,5 @@
  */
 GraphicsEffect::GraphicsEffect(const TiXmlElement* root) {
-    this->setClassID(CL_GRAPHICS_EFFECT, "GraphicsEffect");
+  this->registerObject(this, GraphicsEffect::_objectList);
     this->bActivated = false;
 }
Index: branches/new_class_id/src/lib/graphics/effects/graphics_effect.h
===================================================================
--- branches/new_class_id/src/lib/graphics/effects/graphics_effect.h	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/effects/graphics_effect.h	(revision 9685)
@@ -13,5 +13,6 @@
 //! A class that handles GraphicsEffects. The GraphicsEffectManager operates on this.
 class GraphicsEffect : public BaseObject {
-public:
+  NewObjectListDeclaration(GraphicsEffect);
+  public:
     GraphicsEffect(const TiXmlElement* root = NULL);
     virtual ~GraphicsEffect();
Index: branches/new_class_id/src/lib/graphics/effects/weather_effect.cc
===================================================================
--- branches/new_class_id/src/lib/graphics/effects/weather_effect.cc	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/effects/weather_effect.cc	(revision 9685)
@@ -20,7 +20,5 @@
 #include "util/loading/load_param.h"
 
-
-
-
+NewObjectListDefinition(WeatherEffect);
 
 /**
@@ -29,5 +27,5 @@
 WeatherEffect::WeatherEffect(const TiXmlElement* root)
 {
-  this->setClassID(CL_WEATHER_EFFECT, "WeatherEffect");
+  this->registerObject(this, WeatherEffect::_objectList);
   this->bActivated = false;
 }
Index: branches/new_class_id/src/lib/graphics/effects/weather_effect.h
===================================================================
--- branches/new_class_id/src/lib/graphics/effects/weather_effect.h	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/effects/weather_effect.h	(revision 9685)
@@ -12,4 +12,6 @@
 class WeatherEffect : public BaseObject
 {
+  NewObjectListDeclaration(WeatherEffect);
+
   public:
     WeatherEffect(const TiXmlElement* root = NULL);
Index: branches/new_class_id/src/lib/graphics/graphics_engine.cc
===================================================================
--- branches/new_class_id/src/lib/graphics/graphics_engine.cc	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/graphics_engine.cc	(revision 9685)
@@ -45,5 +45,4 @@
 #include "util/loading/load_param.h"
 #include "util/loading/factory.h"
-#include "class_list.h"
 
 #ifdef __WIN32__
@@ -54,4 +53,6 @@
 SHELL_COMMAND(fps, GraphicsEngine, toggleFPSdisplay);
 
+NewObjectListDefinition(GraphicsEngine);
+
 /**
  * @brief standard constructor
@@ -59,5 +60,5 @@
 GraphicsEngine::GraphicsEngine ()
 {
-  this->setClassID(CL_GRAPHICS_ENGINE, "GraphicsEngine");
+  this->registerObject(this, GraphicsEngine::_objectList);
   this->setName("GraphicsEngine");
 
@@ -590,10 +591,8 @@
 
   // tick the graphics effects
-  if (this->graphicsEffects != NULL || (this->graphicsEffects = ClassList::getList(CL_GRAPHICS_EFFECT)) != NULL)
-  {
-    std::list<BaseObject*>::const_iterator it;
-    for (it = this->graphicsEffects->begin(); it != this->graphicsEffects->end(); it++)
-      dynamic_cast<GraphicsEffect*>(*it)->tick(dt);
-  }
+  for (NewObjectList<GraphicsEffect>::const_iterator it = GraphicsEffect::objectList().begin();
+       it != GraphicsEffect::objectList().end();
+       ++it)
+    (*it)->tick(dt);
 }
 
@@ -688,6 +687,6 @@
   {
     case EV_VIDEO_RESIZE:
-      this->resolutionChanged(event.resize);
-      break;
-  }
-}
+    this->resolutionChanged(event.resize);
+    break;
+  }
+}
Index: branches/new_class_id/src/lib/graphics/graphics_engine.h
===================================================================
--- branches/new_class_id/src/lib/graphics/graphics_engine.h	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/graphics_engine.h	(revision 9685)
@@ -30,4 +30,5 @@
 class GraphicsEngine : public EventListener
 {
+  NewObjectListDeclaration(GraphicsEngine);
   public:
     virtual ~GraphicsEngine();
Index: branches/new_class_id/src/lib/graphics/importer/material.cc
===================================================================
--- branches/new_class_id/src/lib/graphics/importer/material.cc	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/importer/material.cc	(revision 9685)
@@ -27,4 +27,6 @@
 #include "util/loading/resource_manager.h"
 
+NewObjectListDefinition(Material);
+
 /**
  * @brief creates a Material.
@@ -33,5 +35,5 @@
 Material::Material (const std::string& mtlName)
 {
-  this->setClassID(CL_MATERIAL, "Material");
+  this->registerObject(this, Material::_objectList);
 
   this->setIllum(3);
Index: branches/new_class_id/src/lib/graphics/importer/material.h
===================================================================
--- branches/new_class_id/src/lib/graphics/importer/material.h	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/importer/material.h	(revision 9685)
@@ -24,4 +24,5 @@
 class Material : public BaseObject
 {
+  NewObjectListDeclaration(Material);
 public:
   Material (const std::string& mtlName = "");
Index: branches/new_class_id/src/lib/graphics/importer/md2/md2Model.cc
===================================================================
--- branches/new_class_id/src/lib/graphics/importer/md2/md2Model.cc	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/importer/md2/md2Model.cc	(revision 9685)
@@ -22,5 +22,5 @@
 
 
-
+NewObjectListDefinition(MD2Model);
 
 //! the model anorms
@@ -78,5 +78,5 @@
 MD2Model::MD2Model(const std::string& modelFileName, const std::string& skinFileName, float scale)
 {
-  this->setClassID(CL_MD2_MODEL, "MD2Model");
+  this->registerObject(this, MD2Model::_objectList);
   /* this creates the data container via ressource manager */
   if (!modelFileName.empty())
Index: branches/new_class_id/src/lib/graphics/importer/md2/md2Model.h
===================================================================
--- branches/new_class_id/src/lib/graphics/importer/md2/md2Model.h	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/importer/md2/md2Model.h	(revision 9685)
@@ -149,5 +149,5 @@
 //! This is a MD2 Model class
 class MD2Model : public InteractiveModel {
-
+  NewObjectListDeclaration(MD2Model);
 public:
   MD2Model(const std::string& modelFileName, const std::string& skinFileName = "", float scale = 1.0f);
Index: branches/new_class_id/src/lib/graphics/importer/media_container.cc
===================================================================
--- branches/new_class_id/src/lib/graphics/importer/media_container.cc	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/importer/media_container.cc	(revision 9685)
@@ -30,4 +30,5 @@
 #include "debug.h"
 
+NewObjectListDefinition(MediaContainer);
 
 /**
@@ -37,5 +38,5 @@
 {
   // set the class id for the base object
-  this->setClassID(CL_MEDIA_CONTAINER, "MediaContainer");
+  this->registerObject(this, MediaContainer::_objectList);
 
   fps = 0;
Index: branches/new_class_id/src/lib/graphics/importer/media_container.h
===================================================================
--- branches/new_class_id/src/lib/graphics/importer/media_container.h	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/importer/media_container.h	(revision 9685)
@@ -24,5 +24,5 @@
 class MediaContainer : public TextureSequence
 {
-
+  NewObjectListDeclaration(MediaContainer);
 private:
 
Index: branches/new_class_id/src/lib/graphics/importer/movie_player.cc
===================================================================
--- branches/new_class_id/src/lib/graphics/importer/movie_player.cc	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/importer/movie_player.cc	(revision 9685)
@@ -30,10 +30,10 @@
 #include "debug.h"
 
+NewObjectListDefinition(MoviePlayer);
 
 MoviePlayer::MoviePlayer(const std::string& filename)
 {
   // set the class id for the base object
-  this->setClassID(CL_MOVIE_PLAYER, "MoviePlayer");
-
+  this->registerObject(this, MoviePlayer::_objectList);
   status = STOP;
   timer = 0;
Index: branches/new_class_id/src/lib/graphics/importer/movie_player.h
===================================================================
--- branches/new_class_id/src/lib/graphics/importer/movie_player.h	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/importer/movie_player.h	(revision 9685)
@@ -31,4 +31,5 @@
 class MoviePlayer : public BaseObject
 {
+  NewObjectListDeclaration(MoviePlayer);
 
 private:
Index: branches/new_class_id/src/lib/graphics/importer/texture.cc
===================================================================
--- branches/new_class_id/src/lib/graphics/importer/texture.cc	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/importer/texture.cc	(revision 9685)
@@ -64,5 +64,5 @@
 #endif
 
-
+NewObjectListDefinition(Texture);
 
 /**
@@ -86,5 +86,5 @@
     : data(texture.data)
 {
-  this->setClassID(CL_TEXTURE, "Texture");
+  this->registerObject(this, Texture::_objectList);
   this->priority = 0.5;
 }
@@ -149,5 +149,5 @@
 void Texture::init()
 {
-  this->setClassID(CL_TEXTURE, "Texture");
+  this->registerObject(this, Texture::_objectList);
 
   this->data = TextureDataPointer(new TextureData());
Index: branches/new_class_id/src/lib/graphics/importer/texture.h
===================================================================
--- branches/new_class_id/src/lib/graphics/importer/texture.h	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/importer/texture.h	(revision 9685)
@@ -20,4 +20,5 @@
 class Texture : public BaseObject
 {
+  NewObjectListDeclaration(Texture);
 public:
   Texture();
Index: branches/new_class_id/src/lib/graphics/importer/texture_sequence.cc
===================================================================
--- branches/new_class_id/src/lib/graphics/importer/texture_sequence.cc	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/importer/texture_sequence.cc	(revision 9685)
@@ -28,4 +28,6 @@
 #endif
 
+NewObjectListDefinition(TextureSequence);
+
 /**
  * @brief Constructor for a Texture
@@ -33,5 +35,5 @@
 TextureSequence::TextureSequence(unsigned int count, ...)
 {
-  this->setClassID(CL_TEXTURE_SEQUENCE, "TextureSequence");
+  this->registerObject(this, TextureSequence::_objectList);
 
   va_list textureNameList;
@@ -54,5 +56,5 @@
 TextureSequence::TextureSequence(const std::vector<std::string>& textureNames, const std::string& prependFolder)
 {
-  this->setClassID(CL_TEXTURE_SEQUENCE, "TextureSequence");
+  this->registerObject(this, TextureSequence::_objectList);
   this->loadImageSeries(textureNames, prependFolder);
 }
Index: branches/new_class_id/src/lib/graphics/importer/texture_sequence.h
===================================================================
--- branches/new_class_id/src/lib/graphics/importer/texture_sequence.h	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/importer/texture_sequence.h	(revision 9685)
@@ -15,4 +15,5 @@
 class TextureSequence : public Texture
 {
+  NewObjectListDeclaration(TextureSequence);
   public:
     TextureSequence(unsigned int count = 0, ...);
Index: branches/new_class_id/src/lib/graphics/light.cc
===================================================================
--- branches/new_class_id/src/lib/graphics/light.cc	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/light.cc	(revision 9685)
@@ -27,5 +27,8 @@
 #include "debug.h"
 
+#include "class_id.h"
+
 CREATE_FACTORY(Light, CL_LIGHT);
+NewObjectListDefinitionID(Light, CL_LIGHT);
 
 //! Definition of the Lights and their Names
@@ -51,7 +54,8 @@
   PRINTF(4)("initializing Light number %d.\n", this->lightNumber);
 
+  this->registerObject(this, Light::_objectList);
+
   this->lightNumber = LightManager::getInstance()->registerLight(this);
 
-  this->setClassID(CL_LIGHT, "Light");
   char tmpName[10];
   sprintf(tmpName, "Light[%d]", this->lightNumber);
@@ -211,4 +215,5 @@
 ** LIGHT-MANAGER **
 ******************/
+NewObjectListDefinition(LightManager);
 /**
  *  standard constructor for a Light
@@ -216,5 +221,5 @@
 LightManager::LightManager ()
 {
-  this->setClassID(CL_LIGHT_MANAGER, "LightManager");
+  this->registerObject(this, LightManager::_objectList);
 
   glEnable (GL_LIGHTING);
Index: branches/new_class_id/src/lib/graphics/light.h
===================================================================
--- branches/new_class_id/src/lib/graphics/light.h	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/light.h	(revision 9685)
@@ -25,38 +25,39 @@
 class Light : public PNode
 {
-	public:
-		Light(const TiXmlElement* root = NULL);
-		virtual ~Light();
-		
-		virtual void loadParams(const TiXmlElement* root);
-		
-		void setDiffuseColor(GLfloat r, GLfloat g, GLfloat b);
-		void setSpecularColor(GLfloat r, GLfloat g, GLfloat b);
-		void setAttenuation(float constantAttenuation, float linearAttenuation, float quadraticAttenuation);
-		void setSpotDirection(const Vector& direction);
-		void setSpotDirection(float x, float y, float z) { setSpotDirection(Vector(x,y,z)); };
-		void setSpotCutoff(GLfloat cutoff);
-		
-		/** @returns the lightNumber*/
-		int getLightNumber() const {return this->lightNumber;}
-		
-		virtual void draw() const;
-		
-		void debug() const;
-	
-	// attributes
-	private:
-		int              lightNumber;               //!< The number of this Light.
-		GLfloat          diffuseColor[4];           //!< The Diffuse Color this Light emmits.
-		GLfloat          specularColor[4];          //!< The specular Color of this Light.
-		float            constantAttenuation;       //!< The Factor of the the Constant Attenuation.
-		float            linearAttenuation;         //!< The Factor of the the Linear Attenuation.
-		float            quadraticAttenuation;      //!< The Factor of the the Quadratic Attenuation.
-		GLfloat          spotDirection[4];          //!< The direction of the Spot Light.
-		GLfloat          spotCutoff;                //!< The cutoff Angle of the Light Source
+  NewObjectListDeclaration(Light);
+public:
+  Light(const TiXmlElement* root = NULL);
+  virtual ~Light();
+
+  virtual void loadParams(const TiXmlElement* root);
+
+  void setDiffuseColor(GLfloat r, GLfloat g, GLfloat b);
+  void setSpecularColor(GLfloat r, GLfloat g, GLfloat b);
+  void setAttenuation(float constantAttenuation, float linearAttenuation, float quadraticAttenuation);
+  void setSpotDirection(const Vector& direction);
+  void setSpotDirection(float x, float y, float z) { setSpotDirection(Vector(x,y,z)); };
+  void setSpotCutoff(GLfloat cutoff);
+
+  /** @returns the lightNumber*/
+  int getLightNumber() const {return this->lightNumber;}
+
+  virtual void draw() const;
+
+  void debug() const;
+
+  // attributes
+private:
+  int              lightNumber;               //!< The number of this Light.
+  GLfloat          diffuseColor[4];           //!< The Diffuse Color this Light emmits.
+  GLfloat          specularColor[4];          //!< The specular Color of this Light.
+  float            constantAttenuation;       //!< The Factor of the the Constant Attenuation.
+  float            linearAttenuation;         //!< The Factor of the the Linear Attenuation.
+  float            quadraticAttenuation;      //!< The Factor of the the Quadratic Attenuation.
+  GLfloat          spotDirection[4];          //!< The direction of the Spot Light.
+  GLfloat          spotCutoff;                //!< The cutoff Angle of the Light Source
 };
-	
-	
-	
+
+
+
 //! A class that handles Lights
 /**
@@ -87,38 +88,39 @@
 */
 class LightManager : public BaseObject
-	{
-	friend class Light;
+{
+  NewObjectListDeclaration(LightManager);
 
-	public:
-		virtual ~LightManager();
-		/** @returns a Pointer to the only object of this Class */
-		inline static LightManager* getInstance() { if (!singletonRef) singletonRef = new LightManager();  return singletonRef; };
+  friend class Light;
+public:
+  virtual ~LightManager();
+  /** @returns a Pointer to the only object of this Class */
+  inline static LightManager* getInstance() { if (!singletonRef) singletonRef = new LightManager();  return singletonRef; };
 
-		virtual void loadParams(const TiXmlElement* root);
-		void loadLights(const TiXmlElement* root);
+  virtual void loadParams(const TiXmlElement* root);
+  void loadLights(const TiXmlElement* root);
 
-		void setAmbientColor(GLfloat r, GLfloat g, GLfloat b);
-		// HACK: Assuming r = g = b values
-		inline GLfloat getAmbientColor() {  return this->ambientColor[0]; }
+  void setAmbientColor(GLfloat r, GLfloat g, GLfloat b);
+  // HACK: Assuming r = g = b values
+inline GLfloat getAmbientColor() {  return this->ambientColor[0]; }
 
-		Light* getLight(int lightNumber) const;
-		inline Light* getLight() const { return this->currentLight; };
+  Light* getLight(int lightNumber) const;
+  inline Light* getLight() const { return this->currentLight; };
 
-		void draw() const;
+  void draw() const;
 
-		void debug() const;
+  void debug() const;
 
-	private:
-		LightManager();
+private:
+  LightManager();
 
-		int  registerLight(Light* light);
-		void unregisterLight(Light* light);
+  int  registerLight(Light* light);
+  void unregisterLight(Light* light);
 
-	private:
-		static LightManager*    singletonRef;       //!< This is the LightHandlers Reference.
-		GLfloat                 ambientColor[4];    //!< The ambient Color of the scene.
+private:
+  static LightManager*    singletonRef;       //!< This is the LightHandlers Reference.
+  GLfloat                 ambientColor[4];    //!< The ambient Color of the scene.
 
-		Light**                 lights;             //!< An array of Lenght NUMBEROFLIGHTS, that holds pointers to all LightValues.
-		Light*                  currentLight;       //!< The current Light, we are working with.
+  Light**                 lights;             //!< An array of Lenght NUMBEROFLIGHTS, that holds pointers to all LightValues.
+  Light*                  currentLight;       //!< The current Light, we are working with.
 
 };
Index: branches/new_class_id/src/lib/graphics/render2D/element_2d.cc
===================================================================
--- branches/new_class_id/src/lib/graphics/render2D/element_2d.cc	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/render2D/element_2d.cc	(revision 9685)
@@ -29,5 +29,4 @@
 #include "graphics_engine.h"
 #include "util/loading/load_param.h"
-#include "class_list.h"
 
 #include "color.h"
@@ -35,4 +34,6 @@
 #include "shell_command.h"
 SHELL_COMMAND(debug, Element2D, debug2D);
+
+NewObjectListDefinition(Element2D);
 
 
@@ -46,5 +47,5 @@
 Element2D::Element2D (Element2D* parent, E2D_LAYER layer, short nodeFlags)
 {
-  this->setClassID(CL_ELEMENT_2D, "Element2D");
+  this->registerObject(this, Element2D::_objectList);
 
   this->setVisibility(true);
@@ -268,5 +269,5 @@
 void Element2D::setBindNode(const std::string& bindNode)
 {
-  const PNode* tmpBindNode = dynamic_cast<const PNode*>(ClassList::getObject(bindNode, CL_PARENT_NODE));
+  const PNode* tmpBindNode = PNode::objectList().getObject(bindNode);
   if (tmpBindNode != NULL)
     this->bindNode = tmpBindNode;
@@ -640,5 +641,5 @@
 void Element2D::addChild2D (const std::string& childName)
 {
-  Element2D* childNode = dynamic_cast<Element2D*>(ClassList::getObject(childName, CL_ELEMENT_2D));
+  Element2D* childNode = Element2D::objectList().getObject(childName);
   if (childNode != NULL)
     this->addChild2D(childNode);
@@ -718,5 +719,5 @@
 void Element2D::setParent2D (const std::string& parentName)
 {
-  Element2D* parentNode = dynamic_cast<Element2D*>(ClassList::getObject(parentName, CL_ELEMENT_2D));
+  Element2D* parentNode = Element2D::objectList().getObject(parentName);
   if (parentNode != NULL)
     parentNode->addChild2D(this);
@@ -771,5 +772,5 @@
 void Element2D::setParentSoft2D(const std::string& parentName, float bias)
 {
-  Element2D* parentNode = dynamic_cast<Element2D*>(ClassList::getObject(parentName, CL_ELEMENT_2D));
+  Element2D* parentNode = Element2D::objectList().getObject(parentName);
   if (parentNode != NULL)
     this->setParentSoft2D(parentNode, bias);
Index: branches/new_class_id/src/lib/graphics/render2D/element_2d.h
===================================================================
--- branches/new_class_id/src/lib/graphics/render2D/element_2d.h	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/render2D/element_2d.h	(revision 9685)
@@ -47,5 +47,5 @@
 
   E2D_PARENT_MOVEMENT                = 0x0004,    //!< Moves all children along with the parent.
-// special linkage modes
+  // special linkage modes
   E2D_PARENT_ALL                     = 0x0003,    //!< Moves all children around the center of their parent, and also rotates their centers
   E2D_PARENT_ROTATE_AND_MOVE         = 0x0005,    //!< Rotates all children around their axis, and moves them as the Parent Moves, but does not rotate around the center of their parent.
@@ -58,5 +58,5 @@
   E2D_REPARENT_DELETE_CHILDREN       = 0x0040,    //!< Deletes the Children of the node when This Node is Removed. (Use with care).
   /// FIXME
-   E2D_REPARENT_KEEP_POSITION         = 0x0080,   //!< Tries to keep the Position if the Node is reparented.
+  E2D_REPARENT_KEEP_POSITION         = 0x0080,   //!< Tries to keep the Position if the Node is reparented.
 
 
@@ -87,195 +87,197 @@
  * -> the tree is sorted on insertion of a new Child: @see Element2D::addChild2D()
  */
-class Element2D : virtual public BaseObject {
-
-  public:
-    Element2D(Element2D* parent = Element2D::getNullElement(), E2D_LAYER layer = E2D_DEFAULT_LAYER, short nodeFlags = E2D_PARENT_MODE_DEFAULT);
-    virtual ~Element2D();
-
-    virtual void loadParams(const TiXmlElement* root);
-
-    // ACTIVATION //
-    inline void activate2D() { this->bActive = this->bRelCoorChanged = this->bRelDirChanged = true; };
-    inline void deactivate2D() { this->bActive = false; };
-    inline bool get2DActiveState() { return this->bActive; };
-
-    // ALIGNMENT //
-    /** @param alignment the new Alignment of the 2D-Element */
-    inline void setAlignment(E2D_ALIGNMENT alignment) { this->alignment = alignment; };
-    void setAlignment(const std::string& alignment);
-    inline E2D_ALIGNMENT getAlignment() const { return this->alignment; };
-
-    // LAYERING //
-    void setLayer(E2D_LAYER layer);
-    void setLayer(const std::string& layer);
-    /** @returns the Layer this Element is drawn to */
-    inline E2D_LAYER getLayer() const { return this->layer; };
-
-    // VISIBILITY //
-    /** @param visible true if the Element should be visible false otherwise (will not be rendered) */
-    inline void setVisibility(bool visible) { this->bVisible = visible; };
-    /** @returns the visibility state */
-    inline bool isVisible() const { return (this->bVisible && this->bCurrentlyVisible);  };
-
-
-    // POSITIONAL (E2D-specials) //
-    /** @param bindNode the Node this 2D-element should follow. if NULL the Element will not follow anything */
-    void setBindNode(const PNode* bindNode);
-    void setBindNode(const std::string& bindNode);
-    inline const PNode* getBindNode() const { return this->bindNode; };
-
-    inline void setSize2D(float x, float y) { this->size = Vector2D(x, y); };
-    inline void setSize2D(const Vector2D& size) { this->size = size; };
-    inline const Vector2D& getSize2D() const { return this->size; };
-    void setSizeSoft2D(float x, float y, float bias = 1.0);
-    inline void setSizeX2D(float x) { this->size.x = x; };
-    inline void setSizeY2D(float y) { this->size.y = y; };
-    inline float getSizeX2D() const { return this->size.x; };
-    inline float getSizeY2D() const { return this->size.y; };
-
-  public:
-    virtual void tick(float dt) {};
-    virtual void draw() const  {};
-    void tick2D(float dt);
-    void draw2D(E2D_LAYER from, E2D_LAYER to) const;
-    void drawChildren(E2D_LAYER from, E2D_LAYER to) const;
-
-    // LIKE PNODE
-  public:
-    void setRelCoor2D (const Vector2D& relCoord);
-    void setRelCoorX2D(float x);
-    void setRelCoorY2D(float y);
-    void setRelCoor2D (float x, float y);
-    void setRelCoor2Dpx (int x, int y);
-    void setRelCoorSoft2D (const Vector2D& relCoordSoft, float bias = 1.0);
-    void setRelCoorSoft2D (float x, float y, float bias = 1.0);
-    void setRelCoorSoft2Dpx (int x, int y, float bias = 1.0);
-    /** @returns the relative position */
-    inline const Vector2D& getRelCoor2D () const { return this->prevRelCoordinate; };
-    /** @returns the Relative Coordinate Destination */
-    inline const Vector2D& getRelCoorSoft2D() const { return (this->toCoordinate)?*this->toCoordinate:this->relCoordinate; };
-    const Vector2D& getRelCoor2Dpx() const;
-    void setAbsCoor2D (const Vector2D& absCoord);
-    void setAbsCoor2D (float x, float y);
-    void setAbsCoorX2D(float x);
-    void setAbsCoorY2D(float y);
-    void setAbsCoor2Dpx (int x, int y);
-    void setAbsCoorSoft2D (const Vector2D& absCoordSoft, float bias = 1.0);
-    void setAbsCoorSoft2D (float x, float y, float bias = 1.0);
-    /** @returns the absolute position */
-    inline const Vector2D& getAbsCoor2D () const { return this->absCoordinate; };
-    const Vector2D& getAbsCoor2Dpx () const;
-
-    void shiftCoor2D (const Vector2D& shift);
-    void shiftCoor2Dpx (int x, int y);
-
-    void setRelDir2D (float relDir);
-    void setRelDirSoft2D(float relDirSoft, float bias = 1.0);
-    /** @returns the relative Direction */
-    inline float getRelDir2D () const { return this->prevRelDirection; };
-    /** @returns the Relative Directional Destination */
-    inline float getRelDirSoft2D() const { return (this->toDirection)?*this->toDirection:this->relDirection; };
-    void setAbsDir2D (float absDir);
-    void setAbsDirSoft2D (float absDirSoft, float bias = 1.0);
-    /** @returns the absolute Direction */
-    inline float getAbsDir2D () const { return this->absDirection; };
-    void shiftDir2D (float shiftDir);
-
-    /** @returns the Speed of the Node */
-    inline float getSpeed() const { return 0; };
-    /** @returns the Velocity of the Node */
-    inline const Vector2D& getVelocity() const { return this->velocity; };
-
-
-    void addChild2D (Element2D* child);
-    void addChild2D (const std::string& childName);
-    void removeChild2D (Element2D* child);
-    void remove2D();
-
-    /** @param parent the new parent of this Element2D */
-    void setParent2D (Element2D* parent) { parent->addChild2D(this); };
-    void setParent2D (const std::string& parentName);
-    /** @returns the parent of this Element2D */
-    inline Element2D* getParent2D () const { return this->parent; };
-    /** @returns the List of Children of this Element2D */
-    inline const std::list<Element2D*>& getChildren2D() const { return this->children; };
-
-    void setParentSoft2D(Element2D* parentNode, float bias = 1.0);
-    void setParentSoft2D(const std::string& parentName, float bias = 1.0);
-
-    void setParentMode2D (E2D_PARENT_MODE parentMode);
-    void setParentMode2D (const std::string& parentingMode);
-    /** @returns the Parenting mode of this node */
-    int getParentMode2D() const { return this->parentMode; };
-
-    // NULL_PARENT //
-    /** @returns the NullParent, the (main) ROOT of the PNode Tree. If it does not yet exist, it will be created. */
-    static Element2D* getNullElement()  { return (Element2D::nullElement != NULL)? Element2D::nullElement : Element2D::createNullElement(); };
-
-
-    void update2D (float dt);
-
-    void debug2D (unsigned int depth = 1, unsigned int level = 0) const;
-    void debugDraw2D(unsigned int depth = 1, float size = 1.0, Vector color = Vector(1,0,0), unsigned int level = 0) const;
-
-    // helper functions //
-    static const char* parentingModeToString2D(int parentingMode);
-    static E2D_PARENT_MODE stringToParentingMode2D(const std::string& parentingMode);
-
-    static const char* layer2DToChar(E2D_LAYER layer);
-    static E2D_LAYER charToLayer2D(const std::string& layer);
-
-    static bool layerSortPredicate(const Element2D* elem1, const Element2D* elem2);
-
-  private:
-    void eraseChild2D(Element2D* child);
-    /** tells the child that the parent's Coordinate has changed */
-    inline void parentCoorChanged2D () { this->bRelCoorChanged = true; }
-    /** tells the child that the parent's Direction has changed */
-    inline void parentDirChanged2D () { this->bRelDirChanged = true; }
-    /** @returns the last calculated coordinate */
-    inline Vector2D getLastAbsCoor2D() { return this->lastAbsCoordinate; }
-
-    void reparent2D();
-    static Element2D* createNullElement();
-    bool checkIntegrity(const Element2D* checkParent) const;
-
-
-  private:
-    const PNode*            bindNode;           //!< a node over which to display this 2D-element
-    Vector2D                size;               //!< The size of the rendered item
-    Vector2D*               toSize;             //!< The Size to iterate to.
-
-    E2D_ALIGNMENT           alignment;          //!< How the Element is aligned around its Position
-
-    bool                    bVisible;           //!< If the given Element2D is visible.
-    bool                    bCurrentlyVisible;  //!< Evaluated in the TICK process, to see if the Element is Currently visible.
-    bool                    bActive;            //!< If the given Element2D is active.
-    E2D_LAYER               layer;              //!< What layer this Element2D is on.
-
-    bool                    bRelCoorChanged;    //!< If Relative Coordinate has changed since last time we checked
-    bool                    bRelDirChanged;     //!< If Relative Direction has changed since last time we checked
-
-    Vector2D                relCoordinate;      //!< coordinates relative to the parent
-    Vector2D                absCoordinate;      //!< absolute coordinates in the world ( from (0,0,0) )
-    float                   relDirection;       //!< direction relative to the parent
-    float                   absDirection;       //!< absolute diretion in the world ( from (0,0,1) )
-
-    Vector2D                prevRelCoordinate;  //!< The last Relative Coordinate from the last update-Cycle.
-    Vector2D                lastAbsCoordinate;  //!< this is used for speedcalculation, it stores the last coordinate
-    float                   prevRelDirection;   //!< The last Relative Direciton from the last update-Cycle.
-
-    Vector2D                velocity;           //!< Saves the velocity.
-
-    Vector2D*               toCoordinate;       //!< a position to which to iterate. (This is used in conjunction with setParentSoft.and set*CoorSoft)
-    float*                  toDirection;        //!< a direction to which to iterate. (This is used in conjunction with setParentSoft and set*DirSoft)
-    float                   bias;               //!< how fast to iterate to the given position (default is 1)
-
-    Element2D*              parent;             //!< a pointer to the parent node
-    std::list<Element2D*>   children;           //!< list of the children of this Element2D
-
-    unsigned int            parentMode;         //!< the mode of the binding
-
-    static Element2D*       nullElement;        //!< The top-most Element
+class Element2D : virtual public BaseObject
+{
+  NewObjectListDeclaration(Element2D);
+
+public:
+  Element2D(Element2D* parent = Element2D::getNullElement(), E2D_LAYER layer = E2D_DEFAULT_LAYER, short nodeFlags = E2D_PARENT_MODE_DEFAULT);
+  virtual ~Element2D();
+
+  virtual void loadParams(const TiXmlElement* root);
+
+  // ACTIVATION //
+  inline void activate2D() { this->bActive = this->bRelCoorChanged = this->bRelDirChanged = true; };
+  inline void deactivate2D() { this->bActive = false; };
+  inline bool get2DActiveState() { return this->bActive; };
+
+  // ALIGNMENT //
+  /** @param alignment the new Alignment of the 2D-Element */
+  inline void setAlignment(E2D_ALIGNMENT alignment) { this->alignment = alignment; };
+  void setAlignment(const std::string& alignment);
+  inline E2D_ALIGNMENT getAlignment() const { return this->alignment; };
+
+  // LAYERING //
+  void setLayer(E2D_LAYER layer);
+  void setLayer(const std::string& layer);
+  /** @returns the Layer this Element is drawn to */
+  inline E2D_LAYER getLayer() const { return this->layer; };
+
+  // VISIBILITY //
+  /** @param visible true if the Element should be visible false otherwise (will not be rendered) */
+  inline void setVisibility(bool visible) { this->bVisible = visible; };
+  /** @returns the visibility state */
+  inline bool isVisible() const { return (this->bVisible && this->bCurrentlyVisible);  };
+
+
+  // POSITIONAL (E2D-specials) //
+  /** @param bindNode the Node this 2D-element should follow. if NULL the Element will not follow anything */
+  void setBindNode(const PNode* bindNode);
+  void setBindNode(const std::string& bindNode);
+  inline const PNode* getBindNode() const { return this->bindNode; };
+
+  inline void setSize2D(float x, float y) { this->size = Vector2D(x, y); };
+  inline void setSize2D(const Vector2D& size) { this->size = size; };
+  inline const Vector2D& getSize2D() const { return this->size; };
+  void setSizeSoft2D(float x, float y, float bias = 1.0);
+  inline void setSizeX2D(float x) { this->size.x = x; };
+  inline void setSizeY2D(float y) { this->size.y = y; };
+  inline float getSizeX2D() const { return this->size.x; };
+  inline float getSizeY2D() const { return this->size.y; };
+
+public:
+  virtual void tick(float dt) {};
+  virtual void draw() const  {};
+  void tick2D(float dt);
+  void draw2D(E2D_LAYER from, E2D_LAYER to) const;
+  void drawChildren(E2D_LAYER from, E2D_LAYER to) const;
+
+  // LIKE PNODE
+public:
+  void setRelCoor2D (const Vector2D& relCoord);
+  void setRelCoorX2D(float x);
+  void setRelCoorY2D(float y);
+  void setRelCoor2D (float x, float y);
+  void setRelCoor2Dpx (int x, int y);
+  void setRelCoorSoft2D (const Vector2D& relCoordSoft, float bias = 1.0);
+  void setRelCoorSoft2D (float x, float y, float bias = 1.0);
+  void setRelCoorSoft2Dpx (int x, int y, float bias = 1.0);
+  /** @returns the relative position */
+  inline const Vector2D& getRelCoor2D () const { return this->prevRelCoordinate; };
+  /** @returns the Relative Coordinate Destination */
+inline const Vector2D& getRelCoorSoft2D() const { return (this->toCoordinate)?*this->toCoordinate:this->relCoordinate; };
+  const Vector2D& getRelCoor2Dpx() const;
+  void setAbsCoor2D (const Vector2D& absCoord);
+  void setAbsCoor2D (float x, float y);
+  void setAbsCoorX2D(float x);
+  void setAbsCoorY2D(float y);
+  void setAbsCoor2Dpx (int x, int y);
+  void setAbsCoorSoft2D (const Vector2D& absCoordSoft, float bias = 1.0);
+  void setAbsCoorSoft2D (float x, float y, float bias = 1.0);
+  /** @returns the absolute position */
+  inline const Vector2D& getAbsCoor2D () const { return this->absCoordinate; };
+  const Vector2D& getAbsCoor2Dpx () const;
+
+  void shiftCoor2D (const Vector2D& shift);
+  void shiftCoor2Dpx (int x, int y);
+
+  void setRelDir2D (float relDir);
+  void setRelDirSoft2D(float relDirSoft, float bias = 1.0);
+  /** @returns the relative Direction */
+  inline float getRelDir2D () const { return this->prevRelDirection; };
+  /** @returns the Relative Directional Destination */
+inline float getRelDirSoft2D() const { return (this->toDirection)?*this->toDirection:this->relDirection; };
+  void setAbsDir2D (float absDir);
+  void setAbsDirSoft2D (float absDirSoft, float bias = 1.0);
+  /** @returns the absolute Direction */
+  inline float getAbsDir2D () const { return this->absDirection; };
+  void shiftDir2D (float shiftDir);
+
+  /** @returns the Speed of the Node */
+  inline float getSpeed() const { return 0; };
+  /** @returns the Velocity of the Node */
+  inline const Vector2D& getVelocity() const { return this->velocity; };
+
+
+  void addChild2D (Element2D* child);
+  void addChild2D (const std::string& childName);
+  void removeChild2D (Element2D* child);
+  void remove2D();
+
+  /** @param parent the new parent of this Element2D */
+  void setParent2D (Element2D* parent) { parent->addChild2D(this); };
+  void setParent2D (const std::string& parentName);
+  /** @returns the parent of this Element2D */
+  inline Element2D* getParent2D () const { return this->parent; };
+  /** @returns the List of Children of this Element2D */
+  inline const std::list<Element2D*>& getChildren2D() const { return this->children; };
+
+  void setParentSoft2D(Element2D* parentNode, float bias = 1.0);
+  void setParentSoft2D(const std::string& parentName, float bias = 1.0);
+
+  void setParentMode2D (E2D_PARENT_MODE parentMode);
+  void setParentMode2D (const std::string& parentingMode);
+  /** @returns the Parenting mode of this node */
+  int getParentMode2D() const { return this->parentMode; };
+
+  // NULL_PARENT //
+  /** @returns the NullParent, the (main) ROOT of the PNode Tree. If it does not yet exist, it will be created. */
+static Element2D* getNullElement()  { return (Element2D::nullElement != NULL)? Element2D::nullElement : Element2D::createNullElement(); };
+
+
+  void update2D (float dt);
+
+  void debug2D (unsigned int depth = 1, unsigned int level = 0) const;
+  void debugDraw2D(unsigned int depth = 1, float size = 1.0, Vector color = Vector(1,0,0), unsigned int level = 0) const;
+
+  // helper functions //
+  static const char* parentingModeToString2D(int parentingMode);
+  static E2D_PARENT_MODE stringToParentingMode2D(const std::string& parentingMode);
+
+  static const char* layer2DToChar(E2D_LAYER layer);
+  static E2D_LAYER charToLayer2D(const std::string& layer);
+
+  static bool layerSortPredicate(const Element2D* elem1, const Element2D* elem2);
+
+private:
+  void eraseChild2D(Element2D* child);
+  /** tells the child that the parent's Coordinate has changed */
+  inline void parentCoorChanged2D () { this->bRelCoorChanged = true; }
+  /** tells the child that the parent's Direction has changed */
+  inline void parentDirChanged2D () { this->bRelDirChanged = true; }
+  /** @returns the last calculated coordinate */
+  inline Vector2D getLastAbsCoor2D() { return this->lastAbsCoordinate; }
+
+  void reparent2D();
+  static Element2D* createNullElement();
+  bool checkIntegrity(const Element2D* checkParent) const;
+
+
+private:
+  const PNode*            bindNode;           //!< a node over which to display this 2D-element
+  Vector2D                size;               //!< The size of the rendered item
+  Vector2D*               toSize;             //!< The Size to iterate to.
+
+  E2D_ALIGNMENT           alignment;          //!< How the Element is aligned around its Position
+
+  bool                    bVisible;           //!< If the given Element2D is visible.
+  bool                    bCurrentlyVisible;  //!< Evaluated in the TICK process, to see if the Element is Currently visible.
+  bool                    bActive;            //!< If the given Element2D is active.
+  E2D_LAYER               layer;              //!< What layer this Element2D is on.
+
+  bool                    bRelCoorChanged;    //!< If Relative Coordinate has changed since last time we checked
+  bool                    bRelDirChanged;     //!< If Relative Direction has changed since last time we checked
+
+  Vector2D                relCoordinate;      //!< coordinates relative to the parent
+  Vector2D                absCoordinate;      //!< absolute coordinates in the world ( from (0,0,0) )
+  float                   relDirection;       //!< direction relative to the parent
+  float                   absDirection;       //!< absolute diretion in the world ( from (0,0,1) )
+
+  Vector2D                prevRelCoordinate;  //!< The last Relative Coordinate from the last update-Cycle.
+  Vector2D                lastAbsCoordinate;  //!< this is used for speedcalculation, it stores the last coordinate
+  float                   prevRelDirection;   //!< The last Relative Direciton from the last update-Cycle.
+
+  Vector2D                velocity;           //!< Saves the velocity.
+
+  Vector2D*               toCoordinate;       //!< a position to which to iterate. (This is used in conjunction with setParentSoft.and set*CoorSoft)
+  float*                  toDirection;        //!< a direction to which to iterate. (This is used in conjunction with setParentSoft and set*DirSoft)
+  float                   bias;               //!< how fast to iterate to the given position (default is 1)
+
+  Element2D*              parent;             //!< a pointer to the parent node
+  std::list<Element2D*>   children;           //!< list of the children of this Element2D
+
+  unsigned int            parentMode;         //!< the mode of the binding
+
+  static Element2D*       nullElement;        //!< The top-most Element
 };
 
Index: branches/new_class_id/src/lib/graphics/render2D/image_plane.cc
===================================================================
--- branches/new_class_id/src/lib/graphics/render2D/image_plane.cc	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/render2D/image_plane.cc	(revision 9685)
@@ -21,12 +21,11 @@
 
 #include "graphics_engine.h"
-#include "glincl.h"
 #include "p_node.h"
 
 
+#include "class_id.h"
+CREATE_FACTORY(ImagePlane, CL_IMAGE_ENTITY);
 
-
-
-CREATE_FACTORY(ImagePlane, CL_IMAGE_ENTITY);
+NewObjectListDefinitionID(ImagePlane, CL_IMAGE_ENTITY);
 
 
@@ -56,5 +55,5 @@
 void ImagePlane::init()
 {
-  this->setClassID(CL_IMAGE_PLANE, "ImagePlane");
+  this->registerObject(this, ImagePlane::_objectList);
   this->setName("ImagePlane");
 
Index: branches/new_class_id/src/lib/graphics/render2D/image_plane.h
===================================================================
--- branches/new_class_id/src/lib/graphics/render2D/image_plane.h	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/render2D/image_plane.h	(revision 9685)
@@ -17,5 +17,5 @@
 class ImagePlane :  public Element2D
 {
-
+  NewObjectListDeclaration(ImagePlane);
   public:
     ImagePlane(const TiXmlElement* root = NULL);
Index: branches/new_class_id/src/lib/graphics/render2D/render_2d.cc
===================================================================
--- branches/new_class_id/src/lib/graphics/render2D/render_2d.cc	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/render2D/render_2d.cc	(revision 9685)
@@ -19,7 +19,7 @@
 
 #include "graphics_engine.h"
-#include "class_list.h"
 #include "element_2d.h"
 
+NewObjectListDefinition(Render2D);
 
 
@@ -29,8 +29,8 @@
 Render2D::Render2D ()
 {
-   this->setClassID(CL_RENDER_2D, "Render2D");
-   this->setName("Render2D");
+  this->registerObject(this, Render2D::_objectList);
+  this->setName("Render2D");
 
-   this->showNodes = false;
+  this->showNodes = false;
 }
 
Index: branches/new_class_id/src/lib/graphics/render2D/render_2d.h
===================================================================
--- branches/new_class_id/src/lib/graphics/render2D/render_2d.h	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/render2D/render_2d.h	(revision 9685)
@@ -12,24 +12,27 @@
 
 //! A default singleton class.
-class Render2D : public BaseObject {
+class Render2D : public BaseObject
+{
+  NewObjectListDeclaration(Render2D);
+
   friend class Element2D;
 
-  public:
-    virtual ~Render2D();
-    /** @returns a Pointer to the only object of this Class */
-    inline static Render2D* getInstance() { if (!singletonRef) singletonRef = new Render2D();  return singletonRef; };
+public:
+  virtual ~Render2D();
+  /** @returns a Pointer to the only object of this Class */
+  inline static Render2D* getInstance() { if (!singletonRef) singletonRef = new Render2D();  return singletonRef; };
 
-    void toggleNodesVisibility() { this->showNodes = !this->showNodes; };
+void toggleNodesVisibility() { this->showNodes = !this->showNodes; };
 
-    void update(float dt);
-    void tick(float dt);
-    void draw(E2D_LAYER from, E2D_LAYER to) const;
+  void update(float dt);
+  void tick(float dt);
+  void draw(E2D_LAYER from, E2D_LAYER to) const;
 
-  private:
-    Render2D();
-    static Render2D*              singletonRef;                    //!< Reference to this class.
+private:
+  Render2D();
+  static Render2D*              singletonRef;                    //!< Reference to this class.
 
-    bool                          showNodes;                       //!< If the debug-Nodes should be visible
- };
+  bool                          showNodes;                       //!< If the debug-Nodes should be visible
+};
 
 #endif /* _RENDER_2D_H */
Index: branches/new_class_id/src/lib/graphics/shader.cc
===================================================================
--- branches/new_class_id/src/lib/graphics/shader.cc	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/shader.cc	(revision 9685)
@@ -33,5 +33,5 @@
 
 
-
+NewObjectListDefinition(Shader);
 
 /**
@@ -40,6 +40,5 @@
 Shader::Shader (const std::string& vertexShaderFile, const std::string& fragmentShaderFile)
 {
-   this->setClassID(CL_SHADER, "Shader");
-
+  this->registerObject(this, Shader::_objectList);
    this->shaderProgram = 0;
    this->vertexShader = 0;
Index: branches/new_class_id/src/lib/graphics/shader.h
===================================================================
--- branches/new_class_id/src/lib/graphics/shader.h	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/shader.h	(revision 9685)
@@ -19,4 +19,5 @@
 class Shader : public BaseObject
 {
+  NewObjectListDeclaration(Shader);
 public:
   class Uniform
@@ -42,15 +43,15 @@
       {
         case 1:
-          glUniform1fv(this->uniform, 1, vv);
-          break;
+        glUniform1fv(this->uniform, 1, vv);
+        break;
         case 2:
-          glUniform2fv(this->uniform, 2, vv);
-          break;
+        glUniform2fv(this->uniform, 2, vv);
+        break;
         case 3:
-          glUniform3fv(this->uniform, 3, vv);
-          break;
+        glUniform3fv(this->uniform, 3, vv);
+        break;
         case 4:
-          glUniform4fv(this->uniform, 4, vv);
-          break;
+        glUniform4fv(this->uniform, 4, vv);
+        break;
       }
     }
@@ -60,18 +61,18 @@
       {
         case 1:
-          glUniform1iv(this->uniform, 1, vv);
-          break;
+        glUniform1iv(this->uniform, 1, vv);
+        break;
         case 2:
-          glUniform2iv(this->uniform, 2, vv);
-          break;
+        glUniform2iv(this->uniform, 2, vv);
+        break;
         case 3:
-          glUniform3iv(this->uniform, 3, vv);
-          break;
+        glUniform3iv(this->uniform, 3, vv);
+        break;
         case 4:
-          glUniform4iv(this->uniform, 4, vv);
-          break;
+        glUniform4iv(this->uniform, 4, vv);
+        break;
       }
     }
-    private:
+  private:
     GLint uniform;
   };
@@ -99,5 +100,5 @@
   static void deactivateShader();
 
-  Shader::Uniform getUniform(const std::string& location) { return Shader::Uniform(this, location); }
+Shader::Uniform getUniform(const std::string& location) { return Shader::Uniform(this, location); }
 
   bool loadShaderProgramm(Shader::Type type, const std::string& fileName);
@@ -118,5 +119,5 @@
 
 
-  GLhandleARB getProgram() const { return this->shaderProgram; }
+GLhandleARB getProgram() const { return this->shaderProgram; }
   GLhandleARB getVertexS() const { return this->vertexShader; }
   GLhandleARB getFragmentS() const { return this->fragmentShader; }
Index: branches/new_class_id/src/lib/graphics/spatial_separation/quadtree.cc
===================================================================
--- branches/new_class_id/src/lib/graphics/spatial_separation/quadtree.cc	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/spatial_separation/quadtree.cc	(revision 9685)
@@ -27,4 +27,5 @@
 #define QUADTREE_MATERIAL_COUNT       4
 
+NewObjectListDefinition(Quadtree);
 /**
  *  standard constructor
@@ -32,5 +33,5 @@
 Quadtree::Quadtree (const modelInfo* pModelInfo, const int treeDepth)
 {
-  this->setClassID(CL_QUADTREE, "Quadtree");
+  this->registerObject(this, Quadtree::_objectList);
   this->pModelInfo = pModelInfo;
   this->treeDepth = treeDepth;
Index: branches/new_class_id/src/lib/graphics/spatial_separation/quadtree.h
===================================================================
--- branches/new_class_id/src/lib/graphics/spatial_separation/quadtree.h	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/spatial_separation/quadtree.h	(revision 9685)
@@ -21,5 +21,5 @@
 //! A class for quadtree separation of the world
 class Quadtree : public BaseObject {
-
+  NewObjectListDeclaration(Quadtree);
 
   public:
Index: branches/new_class_id/src/lib/graphics/spatial_separation/quadtree_node.cc
===================================================================
--- branches/new_class_id/src/lib/graphics/spatial_separation/quadtree_node.cc	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/spatial_separation/quadtree_node.cc	(revision 9685)
@@ -27,5 +27,5 @@
 
 
-
+NewObjectListDefinition(QuadtreeNode);
 
 /**
@@ -102,5 +102,5 @@
 void QuadtreeNode::init()
 {
-  this->setClassID(CL_QUADTREE_NODE, "QuadtreeNode");
+  this->registerObject(this, QuadtreeNode::_objectList);
 
   /* init the rest of the variables for both init types */
Index: branches/new_class_id/src/lib/graphics/spatial_separation/quadtree_node.h
===================================================================
--- branches/new_class_id/src/lib/graphics/spatial_separation/quadtree_node.h	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/spatial_separation/quadtree_node.h	(revision 9685)
@@ -26,4 +26,5 @@
 //! A class for a Quadtree Node representation
 class QuadtreeNode : public BaseObject {
+  NewObjectListDeclaration(QuadtreeNode);
 
   public:
Index: branches/new_class_id/src/lib/graphics/spatial_separation/spatial_separation.cc
===================================================================
--- branches/new_class_id/src/lib/graphics/spatial_separation/spatial_separation.cc	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/spatial_separation/spatial_separation.cc	(revision 9685)
@@ -24,13 +24,13 @@
 
 
-
+NewObjectListDefinition(SpatialSeparation);
 
 /**
- *  standard constructor
+ * @brief standard constructor
  * @param model the model that is to be separated
  * @param overlapSize each box will overlap for a given size
-
-   The boxes are overlaping because this makes collision detection a lot simpler
-
+ *
+ * The boxes are overlaping because this makes collision detection a lot simpler
+ *
  */
 SpatialSeparation::SpatialSeparation (Model* model, float overlapSize)
@@ -39,5 +39,5 @@
   PRINT(3)("+-| (Event) Spatial Separation process kicked on\n");
 
-  this->setClassID(CL_SPATIAL_SEPARATION, "SpatialSeparation");
+  this->registerObject(this, SpatialSeparation::_objectList);
   /* debug vice */
   this->createQuadtree(model);
@@ -46,5 +46,5 @@
 
 /**
- *  standard constructor
+ * @brief standard constructor
  * @param model the model that is to be separated
  * @param overlapSize each box will overlap for a given size
@@ -54,5 +54,5 @@
 SpatialSeparation::SpatialSeparation (Model* model, Model* playerModel)
 {
-  this->setClassID(CL_SPATIAL_SEPARATION, "SpatialSeparation");
+  this->registerObject(this, SpatialSeparation::_objectList);
 
 }
@@ -60,5 +60,5 @@
 
 /**
- *  standard deconstructor
+ * @brief standard deconstructor
  */
 SpatialSeparation::~SpatialSeparation ()
@@ -70,5 +70,5 @@
 
 /**
- *  creates a quadtree
+ * @brief creates a quadtree
  * @param model the model to do a quadtree on
  * @param minLength the minimal length of a quadtree node
@@ -83,5 +83,5 @@
 
 /**
- *  brief creates a quadtree
+ * @brief creates a quadtree
  * @param model the model to do a quadtree on
  * @param minLength the minimal length of a quadtree node
@@ -95,5 +95,5 @@
 
 /**
- *  creates a quadtree
+ * @brief creates a quadtree
  * @param model the model to do a quadtree on
  * @param minLength the minimal length of a quadtree node
@@ -109,5 +109,5 @@
 
 /**
- *  draws all the quadtrees
+ * @brief draws all the quadtrees
  */
 void SpatialSeparation::drawQuadtree()
@@ -118,14 +118,2 @@
   this->quadtree->drawTree();
 }
-
-
-
-
-
-
-
-
-
-
-
-
Index: branches/new_class_id/src/lib/graphics/spatial_separation/spatial_separation.h
===================================================================
--- branches/new_class_id/src/lib/graphics/spatial_separation/spatial_separation.h	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/spatial_separation/spatial_separation.h	(revision 9685)
@@ -19,4 +19,5 @@
 //! A class for spatial separation of vertices based arrays
 class SpatialSeparation : public BaseObject {
+  NewObjectListDeclaration(SpatialSeparation);
 
   public:
Index: branches/new_class_id/src/lib/graphics/text_engine/font.cc
===================================================================
--- branches/new_class_id/src/lib/graphics/text_engine/font.cc	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/text_engine/font.cc	(revision 9685)
@@ -29,4 +29,5 @@
 #include "compiler.h"
 
+NewObjectListDefinition(Font);
 
 Font::Font()
@@ -130,5 +131,5 @@
   this->setBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
 
-  this->setClassID(CL_FONT, "Font");
+  this->registerObject(this, Font::_objectList);
   if (Font::defaultFontData.get() == NULL)
   {
Index: branches/new_class_id/src/lib/graphics/text_engine/font.h
===================================================================
--- branches/new_class_id/src/lib/graphics/text_engine/font.h	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/text_engine/font.h	(revision 9685)
@@ -19,4 +19,5 @@
 class Font : public Material
 {
+  NewObjectListDeclaration(Font);
 
 public:
Index: branches/new_class_id/src/lib/graphics/text_engine/limited_width_text.cc
===================================================================
--- branches/new_class_id/src/lib/graphics/text_engine/limited_width_text.cc	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/text_engine/limited_width_text.cc	(revision 9685)
@@ -19,4 +19,5 @@
 #include "font.h"
 
+NewObjectListDefinition(LimitedWidthText);
 /**
  * @brief creates a new Text Element
@@ -27,5 +28,5 @@
     : Text(fontFile, textSize)
 {
-  this->setClassID(CL_LIMITED_WIDTH_TEXT, "LimitedWidthText");
+  this->registerObject(this, LimitedWidthText::_objectList);
 
   this->_dotsPosition = End;
Index: branches/new_class_id/src/lib/graphics/text_engine/limited_width_text.h
===================================================================
--- branches/new_class_id/src/lib/graphics/text_engine/limited_width_text.h	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/text_engine/limited_width_text.h	(revision 9685)
@@ -14,4 +14,5 @@
 class LimitedWidthText : public Text
 {
+  NewObjectListDeclaration(LimitedWidthText);
   public:
     typedef enum {
Index: branches/new_class_id/src/lib/graphics/text_engine/multi_line_text.cc
===================================================================
--- branches/new_class_id/src/lib/graphics/text_engine/multi_line_text.cc	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/text_engine/multi_line_text.cc	(revision 9685)
@@ -19,4 +19,6 @@
 #include "font.h"
 
+NewObjectListDefinition(MultiLineText);
+
 /**
  * @brief creates a new Text Element
@@ -27,5 +29,5 @@
   : Text(fontFile, textSize)
 {
-  this->setClassID(CL_MULTI_LINE_TEXT, "MultiLineText");
+  this->registerObject(this, MultiLineText::_objectList);
 
   this->lineSpacing = 1.0;
Index: branches/new_class_id/src/lib/graphics/text_engine/multi_line_text.h
===================================================================
--- branches/new_class_id/src/lib/graphics/text_engine/multi_line_text.h	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/text_engine/multi_line_text.h	(revision 9685)
@@ -14,4 +14,5 @@
 class MultiLineText : public Text
 {
+  NewObjectListDeclaration(MultiLineText);
   public:
     MultiLineText(const std::string& fontFile = "", unsigned int fontSize = TEXT_DEFAULT_SIZE, float lineWidth = 100.0);
Index: branches/new_class_id/src/lib/graphics/text_engine/text.cc
===================================================================
--- branches/new_class_id/src/lib/graphics/text_engine/text.cc	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/text_engine/text.cc	(revision 9685)
@@ -22,4 +22,6 @@
 #include "debug.h"
 
+NewObjectListDefinition(Text);
+
 /**
  * @brief creates a new Text Element
@@ -30,5 +32,5 @@
     // : _font(fontFile, FONT_DEFAULT_RENDER_SIZE)
 {
-  this->setClassID(CL_TEXT, "Text");
+  this->registerObject(this, Text::_objectList);
 
   // initialize this Text
@@ -44,5 +46,5 @@
     : _font()
 {
-  this->setClassID(CL_TEXT, "Text");
+  this->registerObject(this, Text::_objectList);
 
   *this = text;
Index: branches/new_class_id/src/lib/graphics/text_engine/text.h
===================================================================
--- branches/new_class_id/src/lib/graphics/text_engine/text.h	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/text_engine/text.h	(revision 9685)
@@ -26,4 +26,5 @@
 class Text : public Element2D
 {
+  NewObjectListDeclaration(Text);
   public:
     Text(const std::string& fontFile = "", unsigned int fontSize = TEXT_DEFAULT_SIZE);
Index: branches/new_class_id/src/lib/graphics/text_engine/text_engine.cc
===================================================================
--- branches/new_class_id/src/lib/graphics/text_engine/text_engine.cc	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/text_engine/text_engine.cc	(revision 9685)
@@ -34,5 +34,4 @@
 #include "graphics_engine.h"
 #include "util/loading/resource_manager.h"
-#include "class_list.h"
 
 #include "debug.h"
@@ -40,4 +39,5 @@
 /// TEXT-ENGINE ///
 ///////////////////
+NewObjectListDefinition(TextEngine);
 /**
  *  standard constructor
@@ -45,7 +45,7 @@
 TextEngine::TextEngine ()
 {
-   this->setClassID(CL_TEXT_ENGINE, "TextEngine");
-   this->setName("TextEngine");
-   this->enableFonts();
+  this->registerObject(this, TextEngine::_objectList);
+  this->setName("TextEngine");
+  this->enableFonts();
 }
 
@@ -62,18 +62,15 @@
 {
   // first remove all the remaining Texts (if any).
-  const std::list<BaseObject*>* textList = ClassList::getList(CL_TEXT);
-  if (textList != NULL)
-  {
-    while(textList->size() > 0)
-      delete dynamic_cast<Text*>(textList->front());
-  }
+  while (!Text::objectList().empty())
+    delete Text::objectList().front();
   // delete all remaining fonts (There should not be Anything to do here)
-  const std::list<BaseObject*>* fontList = ClassList::getList(CL_FONT);
-  if (fontList != NULL)
+
+  //const std::list<BaseObject*>* fontList = ClassList::getList(CL_FONT);
+  //if (fontList != NULL)
   {
     ///FIXME
-//    while (fontList->size() > 0)
+    //    while (fontList->size() > 0)
     {
-//      Font* font = dynamic_cast<Font*>(fontList->back());
+      //      Font* font = dynamic_cast<Font*>(fontList->back());
       //if (likely(font != Font::getDefaultFont()))
       //        ResourceManager::getInstance()->unload(font, RP_GAME);
@@ -91,10 +88,10 @@
 {
   if (!TTF_WasInit())
-    {
-      if(TTF_Init()==-1)
-        PRINTF(1)("TTF_Init: %s\n", TTF_GetError());
+  {
+    if(TTF_Init()==-1)
+      PRINTF(1)("TTF_Init: %s\n", TTF_GetError());
 
-      TextEngine::checkVersion();
-    }
+    TextEngine::checkVersion();
+  }
   else
     PRINTF(4)("Fonts already initialized\n");
@@ -107,8 +104,8 @@
 {
   if (TTF_WasInit())
-    {
-//      Font::removeDefaultFont();
-      TTF_Quit();
-    }
+  {
+    //      Font::removeDefaultFont();
+    TTF_Quit();
+  }
   else
     PRINTF(4)("Fonts were not initialized.\n");
@@ -122,15 +119,14 @@
 void TextEngine::debug() const
 {
-  const std::list<BaseObject*>* textList = ClassList::getList(CL_TEXT);
-  if (textList != NULL)
+  PRINT(0)("+-------------------------------+\n");
+  PRINT(0)("+ TEXT ENGINE DEBUG INFORMATION +\n");
+  PRINT(0)("+-------------------------------+\n");
+  PRINT(0)("Reference: %p; Text Counts: %d\n", this, Text::objectList().size());
+
+  for (NewObjectList<Text>::const_iterator it = Text::objectList().begin();
+       it != Text::objectList().end();
+       ++it)
   {
-    PRINT(0)("+-------------------------------+\n");
-    PRINT(0)("+ TEXT ENGINE DEBUG INFORMATION +\n");
-    PRINT(0)("+-------------------------------+\n");
-    PRINT(0)("Reference: %p; Text Counts: %d\n", this, textList->size());
-
-    std::list<BaseObject*>::const_iterator text;
-    for ( text = textList->begin(); text != textList->end(); text++)
-      dynamic_cast<Text*>(*text)->debug();
+      (*it)->debug();
     PRINT(0)("+---------------------------TE--+\n");
   }
@@ -152,19 +148,19 @@
       compile_version.minor == link_version.minor &&
       compile_version.patch == link_version.patch)
-    {
-      return true;
-    }
+  {
+    return true;
+  }
   else
-    {
-      PRINTF(2)("compiled with SDL_ttf version: %d.%d.%d\n",
-                compile_version.major,
-                compile_version.minor,
-                compile_version.patch);
+  {
+    PRINTF(2)("compiled with SDL_ttf version: %d.%d.%d\n",
+              compile_version.major,
+              compile_version.minor,
+              compile_version.patch);
 
-      PRINTF(2)("running with SDL_ttf version: %d.%d.%d\n",
-                link_version.major,
-                link_version.minor,
-                link_version.patch);
-      return false;
-    }
+    PRINTF(2)("running with SDL_ttf version: %d.%d.%d\n",
+              link_version.major,
+              link_version.minor,
+              link_version.patch);
+    return false;
+  }
 }
Index: branches/new_class_id/src/lib/graphics/text_engine/text_engine.h
===================================================================
--- branches/new_class_id/src/lib/graphics/text_engine/text_engine.h	(revision 9684)
+++ branches/new_class_id/src/lib/graphics/text_engine/text_engine.h	(revision 9685)
@@ -24,5 +24,6 @@
 class TextEngine : public BaseObject
 {
- public:
+  NewObjectListDeclaration(TextEngine);
+  public:
   virtual ~TextEngine();
   /** @returns a Pointer to the only object of this Class */
