dicebae

package module
v0.0.0-...-ba309c1 Latest Latest
Warning

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

Go to latest
Published: Jul 11, 2020 License: MIT Imports: 11 Imported by: 0

README

dicebae

I have no dice, but I must roll

go build -o runbae dicebae/cmd && ./runbae --key=SomeDiscordBotAPIKey --players=CSVOfDNDBeyondPlayerIDsFromTheCharacterSheetURL

Documentation

Overview

Package dicebae implements the baepi DiceBae interface. It essentially wraps a discordgo session to provide a more bae-focused experience. Specifically, it defines a bot centered around responding to hotwords spoken in discord channels with simple, easy-to-write handlers.

Package handlers registers packages for handling Baevents and providing Baesponses based on user input.

History handles storing previous Baesponses in-memory and exposes functions for handlers to query earlier responses.

Logging defines a logger interface to log to standard out and a local file.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewBae

func NewBae(args *Baergs) (baepi.DiceBae, error)

NewBae returns a hot, fresh bae with validated and initialized handlers.

Types

type Baergs

type Baergs struct {
	APIKey    string // Required.
	PlayerIDs []int
	LogDir    string
}

Baergs contains arguments for the creation of the bae.

Directories

Path Synopsis
Package baepi defines a simple api for interactions between the bae and any handlers that define bae features.
Package baepi defines a simple api for interactions between the bae and any handlers that define bae features.
Package main runs the bae forever.
Package main runs the bae forever.
Package roll defines a simple request/response interface for requesting dice rolls from free-form text and rolling 'dem bones.
Package roll defines a simple request/response interface for requesting dice rolls from free-form text and rolling 'dem bones.

Jump to

Keyboard shortcuts

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