Index: code/branches/modularships/src/orxonox/ShipPart.cc
===================================================================
--- code/branches/modularships/src/orxonox/ShipPart.cc	(revision 10007)
+++ code/branches/modularships/src/orxonox/ShipPart.cc	(revision 10007)
@@ -0,0 +1,53 @@
+/*
+ *   ORXONOX - the hottest 3D action shooter ever to exist
+ *                    > www.orxonox.net <
+ *
+ *
+ *   License notice:
+ *
+ *   This program is free software; you can redistribute it and/or
+ *   modify it under the terms of the GNU General Public License
+ *   as published by the Free Software Foundation; either version 2
+ *   of the License, or (at your option) any later version.
+ *
+ *   This program is distributed in the hope that it will be useful,
+ *   but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *   GNU General Public License for more details.
+ *
+ *   You should have received a copy of the GNU General Public License
+ *   along with this program; if not, write to the Free Software
+ *   Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+ *
+ *   Author:
+ *      Noe Pedrazzini
+ *   Co-authors:
+ *      ...
+ *
+ */
+
+#include "ShipPart.h"
+
+#include <algorithm>
+
+#include "core/CoreIncludes.h"
+#include "core/GameMode.h"
+#include "core/XMLPort.h"
+#include "network/NetworkFunction.h"
+
+
+namespace orxonox
+{
+    RegisterClass(ShipPart);
+
+    ShipPart::ShipPart(Context* context)
+    {
+        //RegisterObject(ShipPart);
+    }
+
+    ShipPart::~ShipPart()
+    {
+
+    }
+
+}
Index: code/branches/modularships/src/orxonox/ShipPart.h
===================================================================
--- code/branches/modularships/src/orxonox/ShipPart.h	(revision 10007)
+++ code/branches/modularships/src/orxonox/ShipPart.h	(revision 10007)
@@ -0,0 +1,55 @@
+/*
+ *   ORXONOX - the hottest 3D action shooter ever to exist
+ *                    > www.orxonox.net <
+ *
+ *
+ *   License notice:
+ *
+ *   This program is free software; you can redistribute it and/or
+ *   modify it under the terms of the GNU General Public License
+ *   as published by the Free Software Foundation; either version 2
+ *   of the License, or (at your option) any later version.
+ *
+ *   This program is distributed in the hope that it will be useful,
+ *   but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *   GNU General Public License for more details.
+ *
+ *   You should have received a copy of the GNU General Public License
+ *   along with this program; if not, write to the Free Software
+ *   Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+ *
+ *   Author:
+ *      Noe Pedrazzini
+ *   Co-authors:
+ *      ...
+ *
+ */
+
+#ifndef _ShipPart_H__
+#define _ShipPart_H__
+
+#include "OrxonoxPrereqs.h"
+
+#include <string>
+
+
+namespace orxonox // tolua_export
+{ // tolua_export
+    class _OrxonoxExport ShipPart // tolua_export
+    { // tolua_export
+
+        public:
+            ShipPart(Context* context);
+            virtual ~ShipPart();
+
+        protected:
+
+
+        private:
+
+
+    }; // tolua_export
+} // tolua_export
+
+#endif /* _ShipPart_H__ */
Index: code/branches/modularships/src/orxonox/worldentities/pawns/Pawn.cc
===================================================================
--- code/branches/modularships/src/orxonox/worldentities/pawns/Pawn.cc	(revision 10006)
+++ code/branches/modularships/src/orxonox/worldentities/pawns/Pawn.cc	(revision 10007)
@@ -53,4 +53,5 @@
 #include <BulletCollision/CollisionShapes/btCollisionShape.h>
 #include <BulletCollision/CollisionShapes/btCompoundShape.h>
+#include "graphics/Model.h"
 
 
@@ -638,74 +639,27 @@
         orxout() << "  " << this->getRadarName() << " has the following Objects attached:" << endl;
         for (int i=0; i<10; i++)
-            orxout() << " " << i << ": " << this->getAttachedObject(i) << endl;
+        {
+            if (this->getAttachedObject(i)==NULL)
+                break;
+            orxout() << " " << i << ": " << this->getAttachedObject(i);
+            if(!orxonox_cast<Model*>(this->getAttachedObject(i)))
+                orxout() << " (SE)";
+            orxout() << endl;
+        }
+
+        if (this->health_ < 800)
+            this->detach(this->getAttachedObject(2));
 
         // print child shapes of this WECS
-        // printChildShapes(ownWECS, 2, 0);
         printBtChildShapes((btCompoundShape*)(ownWECS->getCollisionShape()), 2, 0);
 
+        int temp = entityOfCollisionShape(cs);
+        if (temp==0)
+            orxout() << this->getRadarName() << " has been hit on it's main body." << endl;
+        else
+            orxout() << this->getRadarName() << " has been hit on the attached entity no. " << temp << endl;
 
         // end
-        orxout() << "  " << this->getRadarName() << ": no matching CS found." << endl;
         return -1;
-    }
-
-    void Pawn::printChildShapes(CompoundCollisionShape* cs, int indent, int subshape)
-    {
-        for (int i=0; i < cs->getNumChildShapes(); i++)
-        {
-            orxout() << "" << endl;
-        }
-        /*
-        // e.g. "  Childshape 1 (WECS 0x126dc8c0) has 2 childshapes:"
-        printSpaces(indent);  orxout() << "Childshape " << subshape << " (CS* " << cs << ") has " << cs->getNumChildShapes() << " childshapes:" << endl;
-
-        // e.g. "Box 4 is WorldEntityCollisionShape 0x126dd060"
-        printSpaces(indent);  orxout() << "Childshape " << subshape << " is btCollisionShape* " << cs->getCollisionShape() << endl;
-
-        for (int i=0; i < cs->getNumChildShapes(); i++)
-        {
-            printSpaces(indent+2);  orxout() << "- " << i << " - - -" << endl;
-            printSpaces(indent+2);  orxout() << "This Shape is a ";
-            if (orxonox_cast<WorldEntityCollisionShape*>(cs->getAttachedShape(i)))
-                orxout() << "WECS ";
-            if (orxonox_cast<CompoundCollisionShape*>(cs->getAttachedShape(i)))
-                orxout() << "CCS ";
-            if (orxonox_cast<CollisionShape*>(cs->getAttachedShape(i)))
-                orxout() << "CS ";
-            orxout() << endl;
-
-            // For each childshape, print:
-
-            // parentID of the CollisionShape
-            printSpaces(indent+2);  orxout() << "ParentID: " << cs->getAttachedShape(i)->getObjectID() << endl;
-
-            // parentID of the CollisionShape
-            printSpaces(indent+2);  orxout() << "ParentID: " << cs->getAttachedShape(i)->getParentID() << endl;
-
-            // parent of the CollisionShape
-            printSpaces(indent+2);  orxout() << "ParentCCS*: " << cs->getAttachedShape(i)->getParent() << endl;
-
-            // pointer to the btCollisionShape
-            printSpaces(indent+2);  orxout() << "btCollisionShape*: " << cs->getAttachedShape(i)->getCollisionShape() << endl;
-
-            // pointer to the CollisionShape
-            printSpaces(indent+2);  orxout() << "CollisionShape*: " << cs->getAttachedShape(i) << endl;
-
-            if (cs->getAttachedShape(i)->getCollisionShape() != NULL)
-            {
-                // pointer to the user of the btCollisionShape
-                printSpaces(indent+2);  orxout() << "bt: getUserPointer: " << cs->getAttachedShape(i)->getCollisionShape()->getUserPointer() << endl;
-
-                //
-                printSpaces(indent+2);  orxout() << "bt: isCompound: " << cs->getAttachedShape(i)->getCollisionShape()->isCompound() << endl;
-            }
-
-            // if the childshape is a CompoundCollisionShape, print its children.
-            if (orxonox_cast<CompoundCollisionShape*>(cs->getAttachedShape(i)))
-            {
-                printChildShapes((CompoundCollisionShape*)(cs->getAttachedShape(i)), indent+2, i);
-            }
-
-        }*/
     }
 
@@ -736,4 +690,11 @@
     }
 
+    int Pawn::entityOfCollisionShape(const btCollisionShape* cs)
+    {
+        btCompoundShape* ownBtCS = (btCompoundShape*)(this->getWorldEntityCollisionShape()->getCollisionShape());
+
+        return -1;
+    }
+
     void Pawn::printSpaces(int num)
     {
Index: code/branches/modularships/src/orxonox/worldentities/pawns/Pawn.h
===================================================================
--- code/branches/modularships/src/orxonox/worldentities/pawns/Pawn.h	(revision 10006)
+++ code/branches/modularships/src/orxonox/worldentities/pawns/Pawn.h	(revision 10007)
@@ -233,7 +233,7 @@
 
             virtual int isMyCollisionShape(const btCollisionShape* cs);
-            void printChildShapes(CompoundCollisionShape* cs, int indent, int subshape);
             void printBtChildShapes(btCompoundShape* cs, int indent, int subshape);
             void printSpaces(int num);
+            int entityOfCollisionShape(const btCollisionShape* cs);
 
         private:
