forked from Minecraft/canopeas
28 lines
478 B
Go
28 lines
478 B
Go
package discord
|
|
|
|
import "git.canopymc.net/Etzelia/inspiro"
|
|
|
|
func init() {
|
|
commands = append(commands, &command{
|
|
name: "inspire",
|
|
validate: func(cmd commandInit) bool {
|
|
return true
|
|
},
|
|
run: func(cmd commandInit) (string, error) {
|
|
if !memeRateLimit.Try() {
|
|
return "", nil
|
|
}
|
|
|
|
sendTyping(cmd.session, cmd.message.ChannelID)
|
|
|
|
img, err := inspiro.Generate()
|
|
if err != nil {
|
|
return "", err
|
|
}
|
|
|
|
return img, nil
|
|
},
|
|
help: "Get inspired!",
|
|
})
|
|
}
|