import { NaticoCommandHandler } from "https://deno.land/x/natico@4.0.0-pre.4/examples/deps.ts";
Constructors
new
NaticoCommandHandler(client: T, unnamed 1: NaticoCommandHandlerOptions)Type Parameters
T extends NaticoClient
Properties
cooldowns: Collection<any, any>
generator: ArgumentGenerator
inhibitorHandler: NaticoInhibitorHandler<NaticoClient>
modules: Collection<string, NaticoCommand | NaticoSubCommand>
prefix: prefixFn | string | string[]
Single means all subcommands in the same file; multiple means in every file
Methods
enableSlash(guildID?: bigint)
Check if commands have slash data and if they do it will activete it be carefull to no accidentally enable them globally, first searches if the command is already enabled and if it changed since and edit it accordingly otherwise creates a command also deletes unused slash commands
findCommand(command: string | undefined): NaticoCommand | undefined
Simple function to find a command could be useful outside of the handler
handleCommand(message: DiscordenoMessage)
handleSlashCommand(interaction: DiscordenoInteraction)
prefixCheck(prefix: string, message: DiscordenoMessage)
runCooldowns(message: DiscordenoMessage, command: NaticoCommand)
setInhibitorHandler(inhibitorHandler: NaticoInhibitorHandler)
slashed(): any
start()