instance

package
v0.0.0-...-900e454 Latest Latest
Warning

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

Go to latest
Published: Jul 15, 2024 License: GPL-3.0 Imports: 24 Imported by: 0

Documentation

Index

Constants

View Source
const DMID = "270904126974590976"

Variables

This section is empty.

Functions

func Reverse

func Reverse(s string) string

Reverse function (Reverses any string)

Types

type Database

type Database struct {
	Database []TriviaDetail `json:"database"`
}

type Instance

type Instance struct {
	Client             *discord.Client
	Logger             *logrus.Logger
	ChannelID          string
	WG                 *sync.WaitGroup
	Master             *Instance
	Cluster            []*Instance
	Features           config.Features
	SuspicionAvoidance config.SuspicionAvoidance
	Compat             config.Compat
	Shifts             []config.Shift
	// contains filtered or unexported fields
}

func (*Instance) Balance

func (in *Instance) Balance() int

func (*Instance) IsClosed

func (in *Instance) IsClosed() bool

func (*Instance) LastBalanceUpdate

func (in *Instance) LastBalanceUpdate() time.Time

func (*Instance) Start

func (in *Instance) Start() error

func (*Instance) WorkEnd

func (in *Instance) WorkEnd(msg discord.Message)

type TriviaDetail

type TriviaDetail struct {
	Question string `json:"question"`
	Answer   string `json:"correct_answer"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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