Documentation ¶
Index ¶
- func Accept(cmdInfo CommandInfo)
- func Close(cmdInfo CommandInfo)
- func Event(cmdInfo CommandInfo)
- func Help(cmdInfo CommandInfo)
- func List(cmdInfo CommandInfo)
- func Offer(cmdInfo CommandInfo)
- func Queue(cmdInfo CommandInfo)
- func Reject(cmdInfo CommandInfo)
- func Rep(cmdInfo CommandInfo)
- func Search(cmdInfo CommandInfo)
- func Trade(cmdInfo CommandInfo)
- func Unregister(cmdInfo CommandInfo)
- type CommandInfo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Accept ¶
func Accept(cmdInfo CommandInfo)
Accept will allow moderators (or bot controllers) to accept reputation application requests
The command usage should look like: ;accept 1234
func Close ¶
func Close(cmdInfo CommandInfo)
Close will attempt to parse event or trade types and close the event by ID through host request
func Event ¶
func Event(cmdInfo CommandInfo)
Event will parse through event commands and display embed with role ping
func Help ¶
func Help(cmdInfo CommandInfo)
Help defines the bot's help command
It prints the help message of a specific bot command using Discord's message embedding
func Queue ¶
func Queue(cmdInfo CommandInfo)
Queue handles the queue-ing system; queue ids are retrieved from event ids defined in event.go
func Rep ¶
func Rep(cmdInfo CommandInfo)
Rep will allow server members to update reputation points on another member
func Search ¶
func Search(cmdInfo CommandInfo)
Search will look up a possible insect or fish in the database and display to the user
func Trade ¶
func Trade(cmdInfo CommandInfo)
Trade will handle trade options within the server
Trade is meant to be paired along with offer.go in order for members to trade and offer items among each other
func Unregister ¶
func Unregister(cmdInfo CommandInfo)
Unregister allows a queue user to remove themselves from the queue
Types ¶
type CommandInfo ¶
type CommandInfo struct { // AdminRole: ID of the role which can control bot AdminRole string // Ses: discord session (discord) Ses *discordgo.Session // Msg: discord message (discord) Msg *discordgo.MessageCreate // Service: contains all services needed by bot (bot) Service models.Services // Channel ID to post event notices ListingID string // Channel ID to post general bot commands BotChID string // Channel ID of rep applications AppID string // Prefix: the prefix the bot recognizes set in .config Prefix string // CmdName: contains the command name CmdName string // CmdOps: the full slice of commands (unparsed) CmdOps []string // CmdList: contains the names of all commands CmdList []string }
CommandInfo represents all metadata discord and bot needs to execute certain API callbacks and commands