Index: trunk/src/lib/shell/shell_command.cc
===================================================================
--- trunk/src/lib/shell/shell_command.cc	(revision 5170)
+++ trunk/src/lib/shell/shell_command.cc	(revision 5171)
@@ -57,15 +57,37 @@
 }
 
-const ShellCommandClass* ShellCommandClass::isRegistered(const char* className)
-{
-  if (ShellCommandClass::commandClassList == NULL)
-    initCommandClassList();
-
+/**
+ * unregisters all Commands that exist
+ */
+void ShellCommandClass::unregisterAllCommands()
+{
   tIterator<ShellCommandClass>* iterator = ShellCommandClass::commandClassList->getIterator();
   ShellCommandClass* elem = iterator->firstElement();
   while(elem != NULL)
   {
+    delete elem;
+
+    elem = iterator->nextElement();
+  }
+  delete iterator;
+
+  delete ShellCommandClass::commandClassList;
+  ShellCommandClass::commandClassList = NULL;
+}
+
+const ShellCommandClass* ShellCommandClass::isRegistered(const char* className)
+{
+  if (ShellCommandClass::commandClassList == NULL)
+    initCommandClassList();
+
+  tIterator<ShellCommandClass>* iterator = ShellCommandClass::commandClassList->getIterator();
+  ShellCommandClass* elem = iterator->firstElement();
+  while(elem != NULL)
+  {
     if (!strcmp(className, elem->className))
     {
+      if (elem->classID == CL_NULL)
+        elem->classID = ClassList::StringToID(className);
+
       delete iterator;
       return elem;
@@ -178,23 +200,4 @@
 
 /**
- * unregisters all Commands that exist
- */
-void ShellCommandBase::unregisterAllCommands()
-{
-//   tIterator<ShellCommandBase>* iterator = ShellCommandBase::commandList->getIterator();
-//   ShellCommandBase* elem = iterator->firstElement();
-//   while(elem != NULL)
-//   {
-//     delete elem;
-//
-//     elem = iterator->nextElement();
-//   }
-//   delete iterator;
-//
-//   delete ShellCommandBase::commandList;
-//   ShellCommandBase::commandList = NULL;
-}
-
-/**
  * unregister an existing commandName
  * @param className the name of the Class the command belongs to.
@@ -205,5 +208,31 @@
 void ShellCommandBase::unregisterCommand(const char* commandName, const char* className)
 {
-  PRINTF(1)("IMPLEMENT THIS\n");
+  if (ShellCommandClass::commandClassList == NULL)
+    ShellCommandClass::initCommandClassList();
+
+ const  ShellCommandClass* checkClass = ShellCommandClass::isRegistered(className);
+
+  if (checkClass != NULL)
+  {
+    tIterator<ShellCommandBase>* iterator = checkClass->commandList->getIterator();
+    ShellCommandBase* elem = iterator->firstElement();
+    while(elem != NULL)
+    {
+      if (!strcmp(commandName, elem->getName()))
+      {
+        checkClass->commandList->remove(elem);
+        delete elem;
+        break;
+      }
+      elem = iterator->nextElement();
+    }
+    delete iterator;
+
+    if (checkClass->commandList->getSize() == 0)
+    {
+      ShellCommandClass::commandClassList->remove(checkClass);
+      delete checkClass;
+    }
+  }
 }
 
@@ -378,5 +407,5 @@
   if (ShellCommandClass::commandClassList == NULL)
   {
-    PRINT(0)("No Command registered so far\n");
+    PRINT(0)("No Command registered.\n");
     return;
   }
@@ -386,9 +415,9 @@
   while(elemCL != NULL)
   {
+    PRINT(0)("Class:'%s' registered %d commands: \n", elemCL->className, elemCL->commandList->getSize());
     tIterator<ShellCommandBase>* iterator = elemCL->commandList->getIterator();
     const ShellCommandBase* elem = iterator->firstElement();
     {
-      PRINT(0)("Class:'%s' registered: \n", elemCL->className);
-      PRINT(0)("  command:'%s':params:%d: ", elem->getName(), elem->paramCount);
+      PRINT(0)("  command:'%s' : params:%d: ", elem->getName(), elem->paramCount);
       for (unsigned int i = 0; i< elem->paramCount; i++)
        printf("%s ", ShellCommandBase::paramToString(elem->parameters[i]));
Index: trunk/src/lib/shell/shell_command.h
===================================================================
--- trunk/src/lib/shell/shell_command.h	(revision 5170)
+++ trunk/src/lib/shell/shell_command.h	(revision 5171)
@@ -45,4 +45,5 @@
     static const tList<ShellCommandClass>* getCommandClassList() { return ShellCommandClass::commandClassList; };
     static ShellCommandClass* getCommandClass(const char* className);
+    static void unregisterAllCommands();
 
   private:
@@ -54,8 +55,8 @@
 
   private:
-  const char*                      className;
-  ClassID                          classID;
-  tList<ShellCommandBase>*         commandList;
-  static tList<ShellCommandClass>* commandClassList;                     //!< A list of Classes
+    const char*                      className;                 //!< The Name of the Class. This should match the ClassName of the Commands Class.
+    long                             classID;                   //!< The classID of this Class
+    tList<ShellCommandBase>*         commandList;               //!< A list of Commands from this Class
+    static tList<ShellCommandClass>* commandClassList;          //!< A list of Classes
 };
 
@@ -72,5 +73,4 @@
     /** @returns the CommandList of the Shell */
 
-    static void unregisterAllCommands();
     static void unregisterCommand(const char* commandName, const char* className);
 
Index: trunk/src/lib/util/list.h
===================================================================
--- trunk/src/lib/util/list.h	(revision 5170)
+++ trunk/src/lib/util/list.h	(revision 5171)
@@ -37,5 +37,5 @@
   void add(T* entity);
   void addAtBeginning(T* entity); //!< @todo This should be made with an ENUM
-  void remove(T* entity);
+  void remove(const T* entity);
   void removeLast();
   void flush();
@@ -138,5 +138,5 @@
 */
 template<class T>
-inline void tList<T>::remove(T* entity)
+inline void tList<T>::remove(const T* entity)
 {
   this->currentEl = this->first;
Index: trunk/src/orxonox.cc
===================================================================
--- trunk/src/orxonox.cc	(revision 5170)
+++ trunk/src/orxonox.cc	(revision 5171)
@@ -93,5 +93,6 @@
   FastFactory::deleteAll();
   ShellCommandBase::debug();
-//  ShellCommandBase::unregisterAllCommands();
+  ShellCommandClass::unregisterAllCommands();
+  ShellCommandBase::debug();
 
   delete EventHandler::getInstance();
