/// <summary> /// Base constructor - construct the common features across all commands. /// </summary> /// <param name="commandHandlerType"></param> /// <param name="module"></param> /// <param name="aliases"></param> /// <param name="examples"></param> /// <param name="help"></param> protected Command(CommandHandlerType commandHandlerType, string[] aliases, string examples, string help, ModuleType module, bool requiresSymbol = true, bool noSetAlias = false) { this.CommandHandlerType = commandHandlerType; this.Aliases = aliases; this.Examples = examples; this.Help = help; this.Module = module; this.RequiresSymbol = requiresSymbol; this.NoSetAlias = noSetAlias; }
internal Command(CommandType type, CommandHandlerType handler, string commandFormat, string about, string successMessage, string failMessage, string errorMessage, bool broadcasterOnly, bool modPermission, bool sendWhisp, TimeSpan cd) { this.CommandHandlerType = handler; this.CommandFormat = commandFormat; this.AboutMessage = about; this.SuccessMessage = successMessage; this.FailMessage = failMessage; this.ErrorMessage = errorMessage; this.CommandType = type; this.BroadcasterOnly = broadcasterOnly; this.ModeratorPermissionRequired = modPermission; this.SendWhisper = sendWhisp; this._cooldown = cd; this._throttler = new CommandThrottling(this._cooldown); }