command

package
v1.20.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 17, 2026 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	CategoryGeneral = dispatch.CommandCategory{
		Name:        "General",
		Description: "General bot commands",
	}
	CategoryOwner = dispatch.CommandCategory{
		Name:        "Owner",
		Description: "Mainanance and other bot-owner commands",
	}
	CategoryEconomy = dispatch.CommandCategory{
		Name:        "Economy",
		Description: "Gambling and other economy based commands",
	}
	CategoryModeration = dispatch.CommandCategory{
		Name:        "Moderation",
		Description: "Moderation and guild safety",
	}
	CategoryMisc = dispatch.CommandCategory{
		Name:        "Misc",
		Description: "Commands that don't fit into other categories",
	}
)
View Source
var CommandHandler *dispatch.CommandHandler

Functions

func HasPerms

func HasPerms(guildID, channelID, userID string, perm int64) bool

func InitCommandHandler

func InitCommandHandler(session *discordgo.Session)

func IsGuildBanned

func IsGuildBanned(guildID string) bool

IsGuildBanned returns a boolean of whether the guild is banned or not

func OwnerCommand

func OwnerCommand(inner dispatch.Run) dispatch.Run

func RegisterCommands added in v1.20.0

func RegisterCommands(commands ...*dispatch.Command)

Types

type BetArg

type BetArg struct {
	Options []string
	Min     int64
	Max     int64
}

func (*BetArg) Help

func (b *BetArg) Help() string

func (*BetArg) ParseArg

func (b *BetArg) ParseArg(arg *dispatch.ParsedArg, data *dispatch.Data) (any, bool)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL