--- a/console_cmds.c Mon May 16 12:15:53 2005 +0000
+++ b/console_cmds.c Mon May 16 13:46:26 2005 +0000
@@ -268,7 +268,6 @@
return true;
}
-
DEF_CONSOLE_CMD(ConPrintWorkingDirectory)
{
const char *path;
@@ -287,6 +286,18 @@
return true;
}
+DEF_CONSOLE_CMD(ConClearBuffer)
+{
+ if (argc == 0) {
+ IConsoleHelp("Clear the console buffer. Usage: 'clear'");
+ return true;
+ }
+
+ IConsoleClearBuffer();
+ InvalidateWindow(WC_CONSOLE, 0);
+ return true;
+}
+
// ********************************* //
// * Network Core Console Commands * //
@@ -1217,6 +1228,7 @@
IConsoleCmdRegister("ls", ConListFiles);
IConsoleCmdRegister("cd", ConChangeDirectory);
IConsoleCmdRegister("pwd", ConPrintWorkingDirectory);
+ IConsoleCmdRegister("clear", ConClearBuffer);
IConsoleAliasRegister("dir", "ls");
IConsoleAliasRegister("newmap", "newgame");