Documentation ¶ Index ¶ Variables type Event type Handler type Listener func NewListener(logger *zap.Logger) Listener func (l *Listener) Listen(ctx context.Context) error func (l *Listener) Register(h Handler) type Message func Text(message string) Message func WithScreenshot(message string) Message Constants ¶ This section is empty. Variables ¶ View Source var Events = make(chan Message, 10) Functions ¶ This section is empty. Types ¶ type Event ¶ type Event string const ( Kill Event = "kill" Death Event = "death" Chicken Event = "chicken" MercChicken Event = "merc chicken" Error Event = "error" ) type Handler ¶ type Handler func(ctx context.Context, m Message) error type Listener ¶ type Listener struct { // contains filtered or unexported fields } func NewListener ¶ func NewListener(logger *zap.Logger) Listener func (*Listener) Listen ¶ func (l *Listener) Listen(ctx context.Context) error func (*Listener) Register ¶ func (l *Listener) Register(h Handler) type Message ¶ type Message struct { Message string Image image.Image } func Text ¶ func Text(message string) Message func WithScreenshot ¶ func WithScreenshot(message string) Message Source Files ¶ View all Source files event.go listener.go Directories ¶ Show internal Expand all Path Synopsis stat Click to show internal directories. Click to hide internal directories.