Move the "sm" command to core/logic.

This commit is contained in:
David Anderson
2015-09-20 14:33:17 -07:00
parent 1a7b708df8
commit 8a7dfdbc11
6 changed files with 6 additions and 57 deletions
+5
View File
@@ -57,6 +57,10 @@ void RootConsoleMenu::OnSourceModStartup(bool late)
bridge->DefineCommand("sm_dump_handles", "Dumps Handle usage to a file for finding Handle leaks",
sm_dump_handles);
bridge->DefineCommand("sm", "SourceMod Menu", [this] (int client, const ICommandArgs *args) -> bool {
GotRootCmd(args);
return true;
});
}
void RootConsoleMenu::OnSourceModAllInitialized()
@@ -281,4 +285,5 @@ static bool sm_dump_handles(int client, const ICommandArgs *args)
g_HandleSys.Dump(write_handles_to_log);
fclose(fp);
return true;
}
-6
View File
@@ -114,11 +114,6 @@ static void RegisterProfiler(IProfilingTool *tool)
g_ProfileToolManager.RegisterTool(tool);
}
static void OnRootCommand(const ICommandArgs *args)
{
g_RootMenu.GotRootCmd(args);
}
// Defined in smn_filesystem.cpp.
extern bool OnLogPrint(const char *msg);
@@ -150,7 +145,6 @@ static sm_logic_t logic =
GenerateError,
AddNatives,
RegisterProfiler,
OnRootCommand,
CDataPack::New,
CDataPack::Free,
&g_PluginSys,