diff --git a/pkg/commands/seventv.go b/pkg/commands/seventv.go new file mode 100644 index 0000000..fae893c --- /dev/null +++ b/pkg/commands/seventv.go @@ -0,0 +1,13 @@ +package commands + +import ( + "fmt" + + "github.com/lyx0/nourybot/cmd/bot" +) + +func SevenTV(target, emote string, nb *bot.Bot) { + reply := fmt.Sprintf("https://7tv.app/emotes?query=%s", emote) + + nb.Send(target, reply) +} diff --git a/pkg/handlers/command.go b/pkg/handlers/command.go index 4f9f570..4b973da 100644 --- a/pkg/handlers/command.go +++ b/pkg/handlers/command.go @@ -37,6 +37,13 @@ func Command(message twitch.PrivateMessage, nb *bot.Bot) { nb.Send(target, "xd") return } + case "7tv": + if msgLen == 1 { + nb.Send(target, "Usage: ()7tv [emote]") + return + } + commands.SevenTV(target, cmdParams[1], nb) + return case "bot": commands.Help(target, nb)