Index: code/trunk/src/modules/invader/CMakeLists.txt
===================================================================
--- code/trunk/src/modules/invader/CMakeLists.txt	(revision 10216)
+++ code/trunk/src/modules/invader/CMakeLists.txt	(revision 10624)
@@ -13,5 +13,5 @@
 
 ORXONOX_ADD_LIBRARY(invader
-  MODULE
+  PLUGIN
   FIND_HEADER_FILES
   LINK_LIBRARIES
Index: code/trunk/src/modules/invader/Invader.cc
===================================================================
--- code/trunk/src/modules/invader/Invader.cc	(revision 10216)
+++ code/trunk/src/modules/invader/Invader.cc	(revision 10624)
@@ -62,10 +62,4 @@
         this->numberOfBots_ = 0; //sets number of default bots temporarly to 0
         this->center_ = 0;
-        init();
-        this->setHUDTemplate("InvaderHUD");
-    }
-
-    void Invader::init()
-    {
         bEndGame = false;
         lives = 3;
@@ -78,4 +72,5 @@
         enemySpawnTimer.setTimer(3.5f, true, createExecutor(createFunctor(&Invader::spawnEnemy, this)));
         comboTimer.setTimer(3.0f, true, createExecutor(createFunctor(&Invader::comboControll, this)));
+        this->setHUDTemplate("InvaderHUD");
     }
 
@@ -87,5 +82,5 @@
             for (int i = 0; i < 7; i++)
             {
-                WeakPtr<BigExplosion> chunk = new BigExplosion(this->center_->getContext());
+                BigExplosion* chunk = new BigExplosion(this->center_->getContext());
                 chunk->setPosition(Vector3(600, 0, 100.f * i - 300));
                 chunk->setVelocity(Vector3(1000, 0, 0));  //player->getVelocity()
@@ -99,5 +94,5 @@
     }
 
-    WeakPtr<InvaderShip> Invader::getPlayer()
+    InvaderShip* Invader::getPlayer()
     {
         if (player == NULL)
@@ -116,5 +111,5 @@
         for (int i = 0; i < (3*log10(static_cast<double>(level)) + 1); i++)
         {
-            WeakPtr<InvaderEnemy> newPawn;
+            InvaderEnemy* newPawn;
             if (rand() % 42/(1 + level*level) == 0)
             {
@@ -155,5 +150,4 @@
     void Invader::start()
     {
-        init();
         // Set variable to temporarily force the player to spawn.
         this->bForceSpawn_ = true;
Index: code/trunk/src/modules/invader/Invader.h
===================================================================
--- code/trunk/src/modules/invader/Invader.h	(revision 10216)
+++ code/trunk/src/modules/invader/Invader.h	(revision 10624)
@@ -71,5 +71,4 @@
             // checks if multiplier should be reset.
             void comboControll();
-            void init();
             int lives;
             int multiplier;
@@ -78,5 +77,5 @@
         private:
             void toggleShowLevel(){bShowLevel = !bShowLevel;}
-            WeakPtr<InvaderShip> getPlayer();
+            InvaderShip* getPlayer();
             WeakPtr<InvaderCenterPoint> center_;
             WeakPtr<InvaderShip> player;
Index: code/trunk/src/modules/invader/InvaderCenterPoint.cc
===================================================================
--- code/trunk/src/modules/invader/InvaderCenterPoint.cc	(revision 10216)
+++ code/trunk/src/modules/invader/InvaderCenterPoint.cc	(revision 10624)
@@ -54,17 +54,9 @@
     }
 
-    void InvaderCenterPoint::changedGametype()
-    {
-        SUPER(InvaderCenterPoint, changedGametype);
-
-        // Check, whether it's still Invader.
-        this->checkGametype();
-    }
-
     void InvaderCenterPoint::checkGametype()
     {
         if (this->getGametype() != NULL && this->getGametype()->isA(Class(Invader)))
         {
-            Invader* InvaderGametype = orxonox_cast<Invader*>(this->getGametype().get());
+            Invader* InvaderGametype = orxonox_cast<Invader*>(this->getGametype());
             InvaderGametype->setCenterpoint(this);
         }
Index: code/trunk/src/modules/invader/InvaderCenterPoint.h
===================================================================
--- code/trunk/src/modules/invader/InvaderCenterPoint.h	(revision 10216)
+++ code/trunk/src/modules/invader/InvaderCenterPoint.h	(revision 10624)
@@ -49,5 +49,4 @@
             virtual void XMLPort(Element& xmlelement, XMLPort::Mode mode);
 
-            virtual void changedGametype(); //!< Is called when the gametype has changed.
         private:
             void checkGametype();
Index: code/trunk/src/modules/invader/InvaderEnemy.cc
===================================================================
--- code/trunk/src/modules/invader/InvaderEnemy.cc	(revision 10216)
+++ code/trunk/src/modules/invader/InvaderEnemy.cc	(revision 10624)
@@ -69,5 +69,5 @@
     }
 
-    WeakPtr<Invader> InvaderEnemy::getGame()
+    Invader* InvaderEnemy::getGame()
     {
         if (game == NULL)
Index: code/trunk/src/modules/invader/InvaderEnemy.h
===================================================================
--- code/trunk/src/modules/invader/InvaderEnemy.h	(revision 10216)
+++ code/trunk/src/modules/invader/InvaderEnemy.h	(revision 10624)
@@ -49,9 +49,9 @@
             virtual bool collidesAgainst(WorldEntity* otherObject, btManifoldPoint& contactPoint);
             virtual void damage(float damage, float healthdamage, float shielddamage, Pawn* originator);
-            virtual void setPlayer(WeakPtr<InvaderShip> player){this->player = player;}
+            virtual void setPlayer(InvaderShip* player){this->player = player;}
 
             int level;
         protected:
-            WeakPtr<Invader> getGame();
+            Invader* getGame();
             WeakPtr<Invader> game;
             WeakPtr<InvaderShip> player;
Index: code/trunk/src/modules/invader/InvaderHUDinfo.cc
===================================================================
--- code/trunk/src/modules/invader/InvaderHUDinfo.cc	(revision 10216)
+++ code/trunk/src/modules/invader/InvaderHUDinfo.cc	(revision 10624)
@@ -128,5 +128,5 @@
         if (this->getOwner() && this->getOwner()->getGametype())
         {
-            this->InvaderGame = orxonox_cast<Invader*>(this->getOwner()->getGametype().get());
+            this->InvaderGame = orxonox_cast<Invader*>(this->getOwner()->getGametype());
         }
         else
Index: code/trunk/src/modules/invader/InvaderShip.cc
===================================================================
--- code/trunk/src/modules/invader/InvaderShip.cc	(revision 10216)
+++ code/trunk/src/modules/invader/InvaderShip.cc	(revision 10624)
@@ -91,5 +91,5 @@
 
         // Camera
-        WeakPtr<Camera> camera = this->getCamera();
+        Camera* camera = this->getCamera();
         if (camera != NULL)
         {
@@ -142,6 +142,6 @@
     {
         // orxout() << "touch!!! " << endl; //<< otherObject << " at " << contactPoint;
-        WeakPtr<InvaderEnemy> enemy = orxonox_cast<InvaderEnemy*>(otherObject);
-        WeakPtr<Projectile> shot = orxonox_cast<Projectile*>(otherObject);
+        InvaderEnemy* enemy = orxonox_cast<InvaderEnemy*>(otherObject);
+        Projectile* shot = orxonox_cast<Projectile*>(otherObject);
         // ensure that this gets only called once per enemy.
         if (enemy != NULL && lastEnemy != enemy)
@@ -171,5 +171,5 @@
     }
 
-    WeakPtr<Invader> InvaderShip::getGame()
+    Invader* InvaderShip::getGame()
     {
         if (game == NULL)
Index: code/trunk/src/modules/invader/InvaderShip.h
===================================================================
--- code/trunk/src/modules/invader/InvaderShip.h	(revision 10216)
+++ code/trunk/src/modules/invader/InvaderShip.h	(revision 10624)
@@ -70,5 +70,5 @@
             virtual void death();
         private:
-            WeakPtr<Invader> getGame();
+            Invader* getGame();
             WeakPtr<Invader> game;
             Camera* camera;
Index: code/trunk/src/modules/invader/InvaderWeapon.cc
===================================================================
--- code/trunk/src/modules/invader/InvaderWeapon.cc	(revision 10216)
+++ code/trunk/src/modules/invader/InvaderWeapon.cc	(revision 10624)
@@ -68,5 +68,5 @@
         // Create the projectile.projectile
         projectile = new Projectile(this->getContext());
-        WeakPtr<Model> model = new Model(projectile->getContext());
+        Model* model = new Model(projectile->getContext());
         model->setMeshSource(mesh_);
         model->setCastShadows(false);
