|
|
|
@ -61,6 +61,23 @@ func setupCommands() {
@@ -61,6 +61,23 @@ func setupCommands() {
|
|
|
|
|
Exec: Status, |
|
|
|
|
} |
|
|
|
|
commands = append(commands, status) |
|
|
|
|
|
|
|
|
|
listCommands := Command{ |
|
|
|
|
Name: "List Commands", |
|
|
|
|
RequiresAdmin: false, |
|
|
|
|
Keywords: []string{"help", "commands", "cmd", "cmds"}, |
|
|
|
|
Exec: Commands, |
|
|
|
|
} |
|
|
|
|
commands = append(commands, listCommands) |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
func Commands(b BotCommand) bool { |
|
|
|
|
defer log.PanicSafe() |
|
|
|
|
print := "Available commands:\n" |
|
|
|
|
for _, cmd := range commands { |
|
|
|
|
print += fmt.Sprintf("```%+v\n%+v\n%+v```\n", cmd.Name, cmd.Keywords, cmd.Help) |
|
|
|
|
} |
|
|
|
|
return true |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
func Reboot(b BotCommand) bool { |
|
|
|
|