Index: code/trunk/src/libraries/tools/Timer.cc
===================================================================
--- code/trunk/src/libraries/tools/Timer.cc	(revision 7174)
+++ code/trunk/src/libraries/tools/Timer.cc	(revision 7284)
@@ -33,12 +33,12 @@
 #include "util/Clock.h"
 #include "core/CoreIncludes.h"
-#include "core/ConsoleCommand.h"
-#include "core/CommandExecutor.h"
-#include "core/Functor.h"
+#include "core/command/ConsoleCommand.h"
+#include "core/command/CommandExecutor.h"
+#include "core/command/Functor.h"
 
 namespace orxonox
 {
-    SetConsoleCommandShortcutExtern(delay);
-    SetConsoleCommandShortcutExtern(killdelays);
+    SetConsoleCommand("delay", &delay).argumentCompleter(1, autocompletion::command());
+    SetConsoleCommand("killdelays", &killdelays);
 
     static std::set<Timer*> delaytimerset;
@@ -54,5 +54,5 @@
         delaytimerset.insert(delaytimer);
 
-        ExecutorStatic* delayexecutor = createExecutor(createFunctor(&executeDelayedCommand));
+        const ExecutorStaticPtr& delayexecutor = createExecutor(createFunctor(&executeDelayedCommand));
         delayexecutor->setDefaultValues(delaytimer, command);
         delaytimer->setTimer(delay, false, delayexecutor);
@@ -97,5 +97,5 @@
         @param exeuctor A executor of the function to call
     */
-    Timer::Timer(float interval, bool bLoop, Executor* executor, bool bKillAfterCall)
+    Timer::Timer(float interval, bool bLoop, const ExecutorPtr& executor, bool bKillAfterCall)
     {
         this->init();
@@ -103,12 +103,4 @@
 
         this->setTimer(interval, bLoop, executor, bKillAfterCall);
-    }
-
-    /**
-        @brief Deletes the executor.
-    */
-    Timer::~Timer()
-    {
-        this->deleteExecutor();
     }
 
@@ -138,13 +130,4 @@
         if (temp)
             this->destroy();
-    }
-
-    /**
-        @brief Deletes the executor.
-    */
-    void Timer::deleteExecutor()
-    {
-      if (this->executor_)
-          delete this->executor_;
     }
 
Index: code/trunk/src/libraries/tools/Timer.h
===================================================================
--- code/trunk/src/libraries/tools/Timer.h	(revision 7174)
+++ code/trunk/src/libraries/tools/Timer.h	(revision 7284)
@@ -44,5 +44,5 @@
 
     source.cc:
-        include "core/Executor.h"
+        #include "core/command/Executor.h"
 
         ClassName::ClassName()
@@ -63,6 +63,6 @@
 #include "tools/ToolsPrereqs.h"
 
-#include "core/Executor.h"
 #include "core/OrxonoxClass.h"
+#include "core/command/Executor.h"
 #include "tools/interfaces/TimeFactorListener.h"
 
@@ -78,7 +78,6 @@
         public:
             Timer();
-            ~Timer();
 
-            Timer(float interval, bool bLoop, Executor* executor, bool bKillAfterCall = false);
+            Timer(float interval, bool bLoop, const ExecutorPtr& executor, bool bKillAfterCall = false);
 
             /**
@@ -89,8 +88,6 @@
                 @param executor A executor of the function to call
             */
-            void setTimer(float interval, bool bLoop, Executor* executor, bool bKillAfterCall = false)
+            void setTimer(float interval, bool bLoop, const ExecutorPtr& executor, bool bKillAfterCall = false)
             {
-                this->deleteExecutor();
-
                 this->setInterval(interval);
                 this->bLoop_ = bLoop;
@@ -103,5 +100,4 @@
 
             void run();
-            void deleteExecutor();
 
             /** @brief Starts the Timer: Function-call after 'interval' seconds. */
@@ -141,12 +137,12 @@
             void init();
 
-            Executor* executor_;  //!< The executor of the function that should be called when the time expires
+            ExecutorPtr executor_;  //!< The executor of the function that should be called when the time expires
 
-            long long interval_;  //!< The time-interval in micro seconds
-            bool bLoop_;          //!< If true, the function gets called every 'interval' seconds
-            bool bActive_;        //!< If true, the Timer ticks and calls the function if the time's up
-            bool bKillAfterCall_; //!< If true the timer gets deleted after it called the function
+            long long interval_;    //!< The time-interval in micro seconds
+            bool bLoop_;            //!< If true, the function gets called every 'interval' seconds
+            bool bActive_;          //!< If true, the Timer ticks and calls the function if the time's up
+            bool bKillAfterCall_;   //!< If true the timer gets deleted after it called the function
 
-            long long time_;      //!< Internal variable, counting the time till the next function-call
+            long long time_;        //!< Internal variable, counting the time till the next function-call
     };
 }
