commands

package
v0.0.0-...-41e3a0e Latest Latest
Warning

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

Go to latest
Published: Nov 9, 2022 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var CoursCommand = discordgo.ApplicationCommand{
	Name:        "cours",
	Description: "Cours command",
	Options: []*discordgo.ApplicationCommandOption{
		{
			Name:        "add",
			Description: "add cours to an user",
			Type:        discordgo.ApplicationCommandOptionSubCommand,
			Options: []*discordgo.ApplicationCommandOption{
				{
					Type:        discordgo.ApplicationCommandOptionUser,
					Name:        "user-option",
					Description: "User option",
					Required:    true,
				},
				{
					Type:        discordgo.ApplicationCommandOptionInteger,
					Name:        "number-option",
					Description: "Number option",
					Required:    true,
				},
			},
		},
		{
			Name:        "show",
			Description: "show cours",
			Type:        discordgo.ApplicationCommandOptionSubCommand,
			Options: []*discordgo.ApplicationCommandOption{
				{
					Type:        discordgo.ApplicationCommandOptionUser,
					Name:        "user-option",
					Description: "User option",
					Required:    false,
				},
			},
		},
		{
			Name:        "help",
			Description: "help",
			Type:        discordgo.ApplicationCommandOptionSubCommand,
		},
		{
			Name:        "remove",
			Description: "remove cours",
			Type:        discordgo.ApplicationCommandOptionSubCommand,
			Options: []*discordgo.ApplicationCommandOption{
				{
					Type:        discordgo.ApplicationCommandOptionUser,
					Name:        "user-option",
					Description: "User option",
					Required:    true,
				},
				{
					Type:        discordgo.ApplicationCommandOptionInteger,
					Name:        "number-option",
					Description: "Number option",
					Required:    true,
				},
			},
		},
		{
			Name:        "remove-channel",
			Description: "remove cours channel",
			Type:        discordgo.ApplicationCommandOptionSubCommand,
			Options: []*discordgo.ApplicationCommandOption{
				{
					Type:        discordgo.ApplicationCommandOptionChannel,
					Name:        "channel-option",
					Description: "Channel option",
					Required:    true,
				},
			},
		},
	},
}
View Source
var KarmaCommand = discordgo.ApplicationCommand{
	Name:        "karma",
	Description: "Karma main command",
	Options: []*discordgo.ApplicationCommandOption{
		{
			Name:        "add",
			Description: "add karma",
			Type:        discordgo.ApplicationCommandOptionSubCommand,
			Options: []*discordgo.ApplicationCommandOption{
				{
					Type:        discordgo.ApplicationCommandOptionUser,
					Name:        "user-option",
					Description: "User option",
					Required:    true,
				},
			},
		},
		{
			Name:        "show",
			Description: "show karma",
			Type:        discordgo.ApplicationCommandOptionSubCommand,
			Options: []*discordgo.ApplicationCommandOption{
				{
					Type:        discordgo.ApplicationCommandOptionUser,
					Name:        "user-option",
					Description: "User option",
					Required:    false,
				},
			},
		},
		{
			Name:        "help",
			Description: "help",
			Type:        discordgo.ApplicationCommandOptionSubCommand,
		},
	},
}

Functions

func CoursCommandHandler

func CoursCommandHandler() func(s *discordgo.Session, i *discordgo.InteractionCreate)

func GetCommandHandlers

func GetCommandHandlers() map[string]func(s *discordgo.Session, i *discordgo.InteractionCreate)

func GetCommands

func GetCommands() []*discordgo.ApplicationCommand

func KarmaCommandHandler

func KarmaCommandHandler() func(s *discordgo.Session, i *discordgo.InteractionCreate)

func VersionCommand

func VersionCommand() func(s *discordgo.Session, i *discordgo.InteractionCreate)

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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