private static void OnChatCommandReceived(object sender, OnChatCommandReceivedArgs e) { Log.Message($"{e.Command.ChatMessage.DisplayName}: {e.Command.ChatMessage.Message}"); ToolkitChatCommand chatCommand = ChatCommandController.GetChatCommand(e.Command.CommandText); if (chatCommand != null) { chatCommand.TryExecute(e.Command as ITwitchCommand); } }
private static void OnChatCommandReceived(object sender, OnChatCommandReceivedArgs e) { if (Current.Game == null) { return; } ToolkitChatCommand chatCommand = ChatCommandController.GetChatCommand(e.Command.CommandText); if (chatCommand != null) { chatCommand.TryExecute(e.Command as ITwitchCommand); } }
public static CommandItem FromToolkitCore([NotNull] ToolkitChatCommand command) { var result = new CommandItem { Name = command.LabelCap.RawText ?? command.commandText, Usage = $"!{command.commandText}", DefName = command.defName }; result.PullFromExtension(command); if (command.requiresBroadcaster || command.requiresMod) { result.UserLevel = UserLevels.Moderator; } result.Data = new CommandData { IsShortcut = false, Mod = command.TryGetModName() }; return(result); }
public PawnHealthCommand(ToolkitChatCommand command) : base(command) { }
public PawnBodyCommand(ToolkitChatCommand command) : base(command) { }
public AwardPoints(ToolkitChatCommand command) : base(command) { }
public Balance(ToolkitChatCommand command) : base(command) { }
public PawnGearCommand(ToolkitChatCommand command) : base(command) { }
public PawnStoryCommand(ToolkitChatCommand command) : base(command) { }
public HelloWorld(ToolkitChatCommand command) : base(command) { }
public JoinQueueCommand(ToolkitChatCommand command) : base(command) { }
public PawnWorkCommand(ToolkitChatCommand command) : base(command) { }
public PawnSkillsCommand(ToolkitChatCommand command) : base(command) { }
public PawnNeedsCommand(ToolkitChatCommand command) : base(command) { }
public TakePoints(ToolkitChatCommand command) : base(command) { }