Skip to main content
Module

x/natico/doc_mod.ts>NaticoCommandHandler

A powerful and customizable framework for Discordeno
Latest
class NaticoCommandHandler
extends NaticoHandler<T>
Re-export
import { NaticoCommandHandler } from "https://deno.land/x/natico@4.0.0-pre.4/doc_mod.ts";

Constructors

new
NaticoCommandHandler(client: T, unnamed 1: NaticoCommandHandlerOptions)

Properties

readonly
categories
commandUtil: boolean
cooldown: number
cooldowns: Collection<any, any>
guildonly: boolean
handleArgs: boolean
handleEdits: boolean
handleSlashCommands: boolean
IgnoreCD: bigint[]
mentionPrefix: boolean
owners: bigint[]
prefix: prefixFn | string | string[]
ratelimit: number
storeMessages: boolean
subType: "single" | "multiple"

Single means all subcommands in the same file; multiple means in every file

superusers: bigint[]

Methods

commandChecks(
command: NaticoCommand,
args: string | undefined,
)
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

prefixCheck(prefix: string, message: DiscordenoMessage)
runCommand(
command: NaticoCommand,
args?: string,
)
slashed(): any