[Orxonox-commit 5695] r10355 - code/branches/core7/src/libraries/core/command

landauf at orxonox.net landauf at orxonox.net
Sat Apr 11 22:46:40 CEST 2015


Author: landauf
Date: 2015-04-11 22:46:40 +0200 (Sat, 11 Apr 2015)
New Revision: 10355

Modified:
   code/branches/core7/src/libraries/core/command/CommandExecutor.cc
Log:
don't forget to register new commands (fixes 'alias' command)

Modified: code/branches/core7/src/libraries/core/command/CommandExecutor.cc
===================================================================
--- code/branches/core7/src/libraries/core/command/CommandExecutor.cc	2015-04-11 20:36:15 UTC (rev 10354)
+++ code/branches/core7/src/libraries/core/command/CommandExecutor.cc	2015-04-11 20:46:40 UTC (rev 10355)
@@ -295,9 +295,9 @@
 
             // create a new console command with the given alias as its name
             if (tokens.size() == 1)
-                new ConsoleCommand(tokens[0], executor);
+                ConsoleCommandManager::registerCommand(new ConsoleCommand(tokens[0], executor));
             else if (tokens.size() == 2)
-                new ConsoleCommand(tokens[0], tokens[1], executor);
+                ConsoleCommandManager::registerCommand(new ConsoleCommand(tokens[0], tokens[1], executor));
             else
                 orxout(user_error) << "\"" << alias << "\" is not a valid alias name (must have one or two words)." << endl;
         }




More information about the Orxonox-commit mailing list