mirror of
https://github.com/MikuLeaks/MikuSB.git
synced 2026-06-04 07:23:58 +00:00
19 lines
498 B
C#
19 lines
498 B
C#
|
|
namespace MikuSB.GameServer.Command;
|
|
|
|
public static class CommandExecutor
|
|
{
|
|
public delegate void RunCommand(ICommandSender sender, string cmd);
|
|
|
|
public static event RunCommand? OnRunCommand;
|
|
|
|
public static void ExecuteCommand(ICommandSender sender, string cmd)
|
|
{
|
|
OnRunCommand?.Invoke(sender, cmd);
|
|
}
|
|
|
|
public static void ConsoleExcuteCommand(string input)
|
|
{
|
|
CommandManager.HandleCommand(input, new ConsoleCommandSender(CommandManager.Logger));
|
|
}
|
|
} |