discordbot

package
v0.2.8 Latest Latest
Warning

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

Go to latest
Published: Jan 4, 2022 License: ISC Imports: 29 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Bot

type Bot struct {
	Ctx *bot.Context
	// contains filtered or unexported fields
}

func New

func New(client *http.Client, cfg Config) *Bot

func (*Bot) Caption

func (bot *Bot) Caption(m *gateway.MessageCreateEvent, raw bot.RawArguments) error

func (*Bot) Edit

func (bot *Bot) Edit(m *gateway.MessageCreateEvent, cmd editArguments) error

func (*Bot) Gif

func (bot *Bot) Gif(m *gateway.MessageCreateEvent) error

func (*Bot) Meme

func (bot *Bot) Meme(m *gateway.MessageCreateEvent, args MemeArguments) error

func (*Bot) Motivate

func (bot *Bot) Motivate(m *gateway.MessageCreateEvent, args MemeArguments) error

func (*Bot) Ping

func (b *Bot) Ping(m *gateway.MessageCreateEvent) error

func (*Bot) Uncaption

func (bot *Bot) Uncaption(m *gateway.MessageCreateEvent) error

type Config

type Config struct {
	Tenor     string `toml:"tenor"`
	OutputDir string `toml:"output-dir"`
	OutputURL string `toml:"output-url"`
}

type Media

type Media struct {
	URL    string
	Height int
	Width  int
	Type   mediaType
}

type MemeArguments

type MemeArguments struct {
	Top,
	Bottom string
}

func (*MemeArguments) CustomParse

func (m *MemeArguments) CustomParse(args string) error

Jump to

Keyboard shortcuts

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