Index: /code/branches/core7/src/libraries/core/Core.cc
===================================================================
--- /code/branches/core7/src/libraries/core/Core.cc	(revision 10361)
+++ /code/branches/core7/src/libraries/core/Core.cc	(revision 10362)
@@ -94,5 +94,5 @@
 
     // register Core as an abstract class to avoid problems if the class hierarchy is created within Core-constructor
-    RegisterAbstractClass(Core).inheritsFrom(Class(Configurable));
+    RegisterAbstractClass(Core).inheritsFrom<Configurable>();
 
     Core::Core(const std::string& cmdLine)
@@ -517,5 +517,5 @@
 
 
-    RegisterAbstractClass(DevModeListener).inheritsFrom(Class(Listable));
+    RegisterAbstractClass(DevModeListener).inheritsFrom<Listable>();
 
     DevModeListener::DevModeListener()
Index: /code/branches/core7/src/libraries/core/CoreIncludes.h
===================================================================
--- /code/branches/core7/src/libraries/core/CoreIncludes.h	(revision 10361)
+++ /code/branches/core7/src/libraries/core/CoreIncludes.h	(revision 10362)
@@ -127,5 +127,5 @@
 */
 #define RegisterClassWithFactory(ClassName, FactoryInstance, bLoadable) \
-    Identifier& _##ClassName##Identifier = (new orxonox::SI_I(orxonox::registerClass<ClassName>(#ClassName, FactoryInstance, bLoadable)))->getIdentifier()
+    orxonox::SI_I& _##ClassName##Identifier = (*new orxonox::SI_I(orxonox::registerClass<ClassName>(#ClassName, FactoryInstance, bLoadable)))
 
 /**
@@ -213,16 +213,49 @@
     }
 
+
+
+
+    /**
+     * The static initializer stores the parent classes of this identifier. The corresponding identifiers are later loaded. This prevents identifiers from
+     * being used before they are completely initialized.
+     */
     class _CoreExport StaticallyInitializedIdentifier : public StaticallyInitializedInstance
     {
+        struct InheritsFrom
+        {
+            virtual ~InheritsFrom() {}
+            virtual Identifier* getParent() = 0;
+        };
+
+        template <class T>
+        struct InheritsFromClass : public InheritsFrom
+        {
+            virtual Identifier* getParent() { return Class(T); }
+        };
+
         public:
             StaticallyInitializedIdentifier(Identifier* identifier) : identifier_(identifier) {}
-
-            virtual void load() {}
+            ~StaticallyInitializedIdentifier()
+            {
+                for (size_t i = 0; i < this->parents_.size(); ++i)
+                    delete parents_[i];
+            }
+
+            virtual void load()
+            {
+                for (size_t i = 0; i < this->parents_.size(); ++i)
+                    this->identifier_->inheritsFrom(this->parents_[i]->getParent());
+            }
 
             inline Identifier& getIdentifier()
                 { return *this->identifier_; }
 
+            template <class T>
+            inline StaticallyInitializedIdentifier& inheritsFrom()
+                { this->parents_.push_back(new InheritsFromClass<T>()); return *this; }
+
         private:
             Identifier* identifier_;
+            std::vector<InheritsFrom*> parents_;
     };
 
Index: /code/branches/core7/src/libraries/core/ViewportEventListener.cc
===================================================================
--- /code/branches/core7/src/libraries/core/ViewportEventListener.cc	(revision 10361)
+++ /code/branches/core7/src/libraries/core/ViewportEventListener.cc	(revision 10362)
@@ -32,5 +32,5 @@
 namespace orxonox
 {
-    RegisterAbstractClass(ViewportEventListener).inheritsFrom(Class(Listable));
+    RegisterAbstractClass(ViewportEventListener).inheritsFrom<Listable>();
 
     ViewportEventListener::ViewportEventListener()
Index: /code/branches/core7/src/libraries/core/WindowEventListener.cc
===================================================================
--- /code/branches/core7/src/libraries/core/WindowEventListener.cc	(revision 10361)
+++ /code/branches/core7/src/libraries/core/WindowEventListener.cc	(revision 10362)
@@ -35,5 +35,5 @@
     unsigned int WindowEventListener::windowHeight_s = 0;
 
-    RegisterAbstractClass(WindowEventListener).inheritsFrom(Class(Listable));
+    RegisterAbstractClass(WindowEventListener).inheritsFrom<Listable>();
 
     WindowEventListener::WindowEventListener()
Index: /code/branches/core7/src/libraries/core/XMLNameListener.cc
===================================================================
--- /code/branches/core7/src/libraries/core/XMLNameListener.cc	(revision 10361)
+++ /code/branches/core7/src/libraries/core/XMLNameListener.cc	(revision 10362)
@@ -32,5 +32,5 @@
 namespace orxonox
 {
-    RegisterAbstractClass(XMLNameListener).inheritsFrom(Class(Listable));
+    RegisterAbstractClass(XMLNameListener).inheritsFrom<Listable>();
 
     XMLNameListener::XMLNameListener()
Index: /code/branches/core7/src/libraries/network/ClientConnectionListener.cc
===================================================================
--- /code/branches/core7/src/libraries/network/ClientConnectionListener.cc	(revision 10361)
+++ /code/branches/core7/src/libraries/network/ClientConnectionListener.cc	(revision 10362)
@@ -35,5 +35,5 @@
 namespace orxonox
 {
-    RegisterAbstractClass(ClientConnectionListener).inheritsFrom(Class(Listable));
+    RegisterAbstractClass(ClientConnectionListener).inheritsFrom<Listable>();
 
     ClientConnectionListener::ClientConnectionListener()
Index: /code/branches/core7/src/libraries/network/NetworkFunction.cc
===================================================================
--- /code/branches/core7/src/libraries/network/NetworkFunction.cc	(revision 10361)
+++ /code/branches/core7/src/libraries/network/NetworkFunction.cc	(revision 10362)
@@ -38,7 +38,7 @@
 
   // no suitable factory for NetworkFunctionBase (and children), so we declare it abstract
-  RegisterAbstractClass(NetworkFunctionBase).inheritsFrom(Class(Listable));
-  RegisterAbstractClass(NetworkFunctionStatic).inheritsFrom(Class(NetworkFunctionBase));
-  RegisterAbstractClass(NetworkMemberFunctionBase).inheritsFrom(Class(NetworkFunctionBase));
+  RegisterAbstractClass(NetworkFunctionBase).inheritsFrom<Listable>();
+  RegisterAbstractClass(NetworkFunctionStatic).inheritsFrom<NetworkFunctionBase>();
+  RegisterAbstractClass(NetworkMemberFunctionBase).inheritsFrom<NetworkFunctionBase>();
 
   NetworkFunctionBase::NetworkFunctionBase(const std::string& name)
Index: /code/branches/core7/src/libraries/network/synchronisable/Synchronisable.cc
===================================================================
--- /code/branches/core7/src/libraries/network/synchronisable/Synchronisable.cc	(revision 10361)
+++ /code/branches/core7/src/libraries/network/synchronisable/Synchronisable.cc	(revision 10362)
@@ -45,5 +45,5 @@
   uint8_t Synchronisable::state_=0x1; // detemines wheter we are server (default) or client
 
-  RegisterAbstractClass(Synchronisable).inheritsFrom(Class(OrxonoxInterface));
+  RegisterAbstractClass(Synchronisable).inheritsFrom<OrxonoxInterface>();
 
   /**
Index: /code/branches/core7/src/libraries/tools/interfaces/ToolsInterfaceCompilation.cc
===================================================================
--- /code/branches/core7/src/libraries/tools/interfaces/ToolsInterfaceCompilation.cc	(revision 10361)
+++ /code/branches/core7/src/libraries/tools/interfaces/ToolsInterfaceCompilation.cc	(revision 10362)
@@ -46,5 +46,5 @@
     float TimeFactorListener::timefactor_s = 1.0f;
 
-    RegisterAbstractClass(TimeFactorListener).inheritsFrom(Class(Listable));
+    RegisterAbstractClass(TimeFactorListener).inheritsFrom<Listable>();
 
     TimeFactorListener::TimeFactorListener()
@@ -67,5 +67,5 @@
     // Tickable
     //----------------------------
-    RegisterAbstractClass(Tickable).inheritsFrom(Class(OrxonoxInterface));
+    RegisterAbstractClass(Tickable).inheritsFrom<OrxonoxInterface>();
 
     /**
Index: /code/branches/core7/src/modules/docking/DockingAnimation.cc
===================================================================
--- /code/branches/core7/src/modules/docking/DockingAnimation.cc	(revision 10361)
+++ /code/branches/core7/src/modules/docking/DockingAnimation.cc	(revision 10362)
@@ -39,5 +39,5 @@
 namespace orxonox
 {
-    RegisterAbstractClass(DockingAnimation).inheritsFrom(Class(BaseObject));
+    RegisterAbstractClass(DockingAnimation).inheritsFrom<BaseObject>();
 
     DockingAnimation::DockingAnimation(Context* context) : BaseObject(context)
Index: /code/branches/core7/src/modules/docking/DockingEffect.cc
===================================================================
--- /code/branches/core7/src/modules/docking/DockingEffect.cc	(revision 10361)
+++ /code/branches/core7/src/modules/docking/DockingEffect.cc	(revision 10362)
@@ -37,5 +37,5 @@
 namespace orxonox
 {
-    RegisterAbstractClass(DockingEffect).inheritsFrom(Class(BaseObject));
+    RegisterAbstractClass(DockingEffect).inheritsFrom<BaseObject>();
 
     DockingEffect::DockingEffect(Context* context) : BaseObject(context)
Index: /code/branches/core7/src/modules/objects/collisionshapes/AbstractRadiusHeightCollisionShape.cc
===================================================================
--- /code/branches/core7/src/modules/objects/collisionshapes/AbstractRadiusHeightCollisionShape.cc	(revision 10361)
+++ /code/branches/core7/src/modules/objects/collisionshapes/AbstractRadiusHeightCollisionShape.cc	(revision 10362)
@@ -40,5 +40,5 @@
 namespace orxonox
 {
-    RegisterAbstractClass(AbstractRadiusHeightCollisionShape).inheritsFrom(Class(CollisionShape));
+    RegisterAbstractClass(AbstractRadiusHeightCollisionShape).inheritsFrom<CollisionShape>();
 
     /**
Index: /code/branches/core7/src/modules/pickup/CollectiblePickup.cc
===================================================================
--- /code/branches/core7/src/modules/pickup/CollectiblePickup.cc	(revision 10361)
+++ /code/branches/core7/src/modules/pickup/CollectiblePickup.cc	(revision 10362)
@@ -40,5 +40,5 @@
 namespace orxonox
 {
-    RegisterAbstractClass(CollectiblePickup).inheritsFrom(Class(Pickupable));
+    RegisterAbstractClass(CollectiblePickup).inheritsFrom<Pickupable>();
 
     /**
Index: /code/branches/core7/src/modules/questsystem/Quest.cc
===================================================================
--- /code/branches/core7/src/modules/questsystem/Quest.cc	(revision 10361)
+++ /code/branches/core7/src/modules/questsystem/Quest.cc	(revision 10362)
@@ -45,5 +45,5 @@
 namespace orxonox
 {
-    RegisterAbstractClass(Quest).inheritsFrom(Class(QuestItem));
+    RegisterAbstractClass(Quest).inheritsFrom<QuestItem>();
 
     /**
Index: /code/branches/core7/src/modules/questsystem/QuestEffect.cc
===================================================================
--- /code/branches/core7/src/modules/questsystem/QuestEffect.cc	(revision 10361)
+++ /code/branches/core7/src/modules/questsystem/QuestEffect.cc	(revision 10362)
@@ -37,5 +37,5 @@
 namespace orxonox
 {
-    RegisterAbstractClass(QuestEffect).inheritsFrom(Class(BaseObject));
+    RegisterAbstractClass(QuestEffect).inheritsFrom<BaseObject>();
 
     /**
Index: /code/branches/core7/src/modules/questsystem/effects/ChangeQuestStatus.cc
===================================================================
--- /code/branches/core7/src/modules/questsystem/effects/ChangeQuestStatus.cc	(revision 10361)
+++ /code/branches/core7/src/modules/questsystem/effects/ChangeQuestStatus.cc	(revision 10362)
@@ -42,5 +42,5 @@
 namespace orxonox
 {
-    RegisterAbstractClass(ChangeQuestStatus).inheritsFrom(Class(QuestEffect));
+    RegisterAbstractClass(ChangeQuestStatus).inheritsFrom<QuestEffect>();
 
     /**
Index: /code/branches/core7/src/orxonox/chat/ChatManager.cc
===================================================================
--- /code/branches/core7/src/orxonox/chat/ChatManager.cc	(revision 10361)
+++ /code/branches/core7/src/orxonox/chat/ChatManager.cc	(revision 10362)
@@ -113,5 +113,5 @@
     // ChatListener                                                         //
     //////////////////////////////////////////////////////////////////////////
-    RegisterAbstractClass(ChatListener).inheritsFrom(Class(Listable));
+    RegisterAbstractClass(ChatListener).inheritsFrom<Listable>();
 
     ChatListener::ChatListener()
Index: /code/branches/core7/src/orxonox/collisionshapes/CollisionShape.cc
===================================================================
--- /code/branches/core7/src/orxonox/collisionshapes/CollisionShape.cc	(revision 10361)
+++ /code/branches/core7/src/orxonox/collisionshapes/CollisionShape.cc	(revision 10362)
@@ -44,5 +44,5 @@
 namespace orxonox
 {
-    RegisterAbstractClass(CollisionShape).inheritsFrom(Class(BaseObject)).inheritsFrom(Class(Synchronisable));
+    RegisterAbstractClass(CollisionShape).inheritsFrom<BaseObject>().inheritsFrom<Synchronisable>();
 
     /**
Index: /code/branches/core7/src/orxonox/gamestates/GSLevel.cc
===================================================================
--- /code/branches/core7/src/orxonox/gamestates/GSLevel.cc	(revision 10361)
+++ /code/branches/core7/src/orxonox/gamestates/GSLevel.cc	(revision 10362)
@@ -252,5 +252,5 @@
     ///////////////////////////////////////////////////////////////////////////
 
-    RegisterAbstractClass(GSLevelMemento).inheritsFrom(Class(OrxonoxInterface));
+    RegisterAbstractClass(GSLevelMemento).inheritsFrom<OrxonoxInterface>();
 
     GSLevelMemento::GSLevelMemento()
Index: /code/branches/core7/src/orxonox/infos/PlayerInfo.cc
===================================================================
--- /code/branches/core7/src/orxonox/infos/PlayerInfo.cc	(revision 10361)
+++ /code/branches/core7/src/orxonox/infos/PlayerInfo.cc	(revision 10362)
@@ -40,5 +40,5 @@
 namespace orxonox
 {
-    RegisterAbstractClass(PlayerInfo).inheritsFrom(Class(Info));
+    RegisterAbstractClass(PlayerInfo).inheritsFrom<Info>();
 
     PlayerInfo::PlayerInfo(Context* context) : Info(context)
Index: /code/branches/core7/src/orxonox/interfaces/InterfaceCompilation.cc
===================================================================
--- /code/branches/core7/src/orxonox/interfaces/InterfaceCompilation.cc	(revision 10361)
+++ /code/branches/core7/src/orxonox/interfaces/InterfaceCompilation.cc	(revision 10362)
@@ -50,5 +50,5 @@
     // GametypeMessageListener
     //----------------------------
-    RegisterAbstractClass(GametypeMessageListener).inheritsFrom(Class(OrxonoxInterface));
+    RegisterAbstractClass(GametypeMessageListener).inheritsFrom<OrxonoxInterface>();
 
     GametypeMessageListener::GametypeMessageListener()
@@ -60,5 +60,5 @@
     // PlayerTrigger
     //----------------------------
-    RegisterAbstractClass(PlayerTrigger).inheritsFrom(Class(OrxonoxInterface));
+    RegisterAbstractClass(PlayerTrigger).inheritsFrom<OrxonoxInterface>();
 
     PlayerTrigger::PlayerTrigger()
@@ -80,5 +80,5 @@
     // RadarListener
     //----------------------------
-    RegisterAbstractClass(RadarListener).inheritsFrom(Class(OrxonoxInterface));
+    RegisterAbstractClass(RadarListener).inheritsFrom<OrxonoxInterface>();
 
     RadarListener::RadarListener()
@@ -90,5 +90,5 @@
     // TeamColourable
     //----------------------------
-    RegisterAbstractClass(TeamColourable).inheritsFrom(Class(OrxonoxInterface));
+    RegisterAbstractClass(TeamColourable).inheritsFrom<OrxonoxInterface>();
 
     TeamColourable::TeamColourable()
@@ -100,5 +100,5 @@
     // Rewardable
     //----------------------------
-    RegisterAbstractClass(Rewardable).inheritsFrom(Class(OrxonoxInterface));
+    RegisterAbstractClass(Rewardable).inheritsFrom<OrxonoxInterface>();
 
     Rewardable::Rewardable()
Index: /code/branches/core7/src/orxonox/interfaces/PickupCarrier.cc
===================================================================
--- /code/branches/core7/src/orxonox/interfaces/PickupCarrier.cc	(revision 10361)
+++ /code/branches/core7/src/orxonox/interfaces/PickupCarrier.cc	(revision 10362)
@@ -41,5 +41,5 @@
 namespace orxonox
 {
-    RegisterAbstractClass(PickupCarrier).inheritsFrom(Class(OrxonoxInterface));
+    RegisterAbstractClass(PickupCarrier).inheritsFrom<OrxonoxInterface>();
 
     /**
Index: /code/branches/core7/src/orxonox/interfaces/Pickupable.cc
===================================================================
--- /code/branches/core7/src/orxonox/interfaces/Pickupable.cc	(revision 10361)
+++ /code/branches/core7/src/orxonox/interfaces/Pickupable.cc	(revision 10362)
@@ -46,5 +46,5 @@
 namespace orxonox
 {
-    RegisterAbstractClass(Pickupable).inheritsFrom(Class(OrxonoxInterface)).inheritsFrom(Class(Rewardable));
+    RegisterAbstractClass(Pickupable).inheritsFrom<OrxonoxInterface>().inheritsFrom<Rewardable>();
 
     /**
Index: /code/branches/core7/src/orxonox/interfaces/RadarViewable.cc
===================================================================
--- /code/branches/core7/src/orxonox/interfaces/RadarViewable.cc	(revision 10361)
+++ /code/branches/core7/src/orxonox/interfaces/RadarViewable.cc	(revision 10362)
@@ -38,5 +38,5 @@
 namespace orxonox
 {
-    RegisterAbstractClass(RadarViewable).inheritsFrom(Class(OrxonoxInterface));
+    RegisterAbstractClass(RadarViewable).inheritsFrom<OrxonoxInterface>();
 
     /**
Index: /code/branches/core7/src/orxonox/sound/BaseSound.cc
===================================================================
--- /code/branches/core7/src/orxonox/sound/BaseSound.cc	(revision 10361)
+++ /code/branches/core7/src/orxonox/sound/BaseSound.cc	(revision 10362)
@@ -43,5 +43,5 @@
 namespace orxonox
 {
-    RegisterAbstractClass(BaseSound).inheritsFrom(Class(Listable));
+    RegisterAbstractClass(BaseSound).inheritsFrom<Listable>();
 
     BaseSound::BaseSound()
Index: /code/branches/core7/src/orxonox/weaponsystem/WeaponMode.cc
===================================================================
--- /code/branches/core7/src/orxonox/weaponsystem/WeaponMode.cc	(revision 10361)
+++ /code/branches/core7/src/orxonox/weaponsystem/WeaponMode.cc	(revision 10362)
@@ -45,5 +45,5 @@
 namespace orxonox
 {
-    RegisterAbstractClass(WeaponMode).inheritsFrom(Class(BaseObject));
+    RegisterAbstractClass(WeaponMode).inheritsFrom<BaseObject>();
 
     WeaponMode::WeaponMode(Context* context) : BaseObject(context)
Index: /code/branches/core7/src/orxonox/worldentities/WorldEntity.cc
===================================================================
--- /code/branches/core7/src/orxonox/worldentities/WorldEntity.cc	(revision 10361)
+++ /code/branches/core7/src/orxonox/worldentities/WorldEntity.cc	(revision 10362)
@@ -61,5 +61,5 @@
     BOOST_STATIC_ASSERT((int)Ogre::Node::TS_WORLD  == (int)WorldEntity::World);
 
-    RegisterAbstractClass(WorldEntity).inheritsFrom(Class(BaseObject)).inheritsFrom(Class(Synchronisable));
+    RegisterAbstractClass(WorldEntity).inheritsFrom<BaseObject>().inheritsFrom<Synchronisable>();
 
     /**
