racing

package
v0.0.0-...-56a85f5 Latest Latest
Warning

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

Go to latest
Published: Feb 23, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MongoCollectionRacing = "racing"
	MongoDBRacing         = "racing"

	CommandJoinRace   = "!rjoin"
	CommandLeaveRace  = "!rleave"
	CommandStartRace  = "!rstart"
	CommandResetRace  = "!rreset"
	CommandJoinedRace = "!rjoined"

	RacerEmoji = ":wheelchair:"

	DatetimeLayout = "2006-01-02 15:04:05"

	RaceDelimiter   = "   "
	RaceTrackLength = 25

	MaximumDiscordMessageLength = 2000

	SpeedCoefficient       = 70
	BeingSlowedCoefficient = 10
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Racer

type Racer struct {
	ID       string `bson:"id"`
	Username string `bson:"username"`
	Emoticon string `bson:"emoticon"`
}

type RacerStats

type RacerStats struct {
	Racer      *Racer
	FinishTime int
}

type Racing

type Racing struct {
	// contains filtered or unexported fields
}

func NewRacing

func NewRacing(mgoConn *mgo.Session, mysqlConn *sql.DB) (*Racing, error)

DEPRECATED: currently bot don't support Mongo, so this package doesn't work as well

func (*Racing) GetInfo

func (q *Racing) GetInfo() map[string]string

func (*Racing) MessageCreate

func (r *Racing) MessageCreate(s *discordgo.Session, m *discordgo.MessageCreate)

Jump to

Keyboard shortcuts

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