support

package
v0.0.0-...-b615ece Latest Latest
Warning

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

Go to latest
Published: Dec 18, 2022 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Config config

Config is a config interface.

View Source
var ErrEnvVarEmpty = errors.New("getenv: environment variable empty")
View Source
var Users []UserList

Users is a slice of UserList.

Functions

func CacheDiscordMembers

func CacheDiscordMembers(s *discordgo.Session)

CacheDiscordMembers caches the users list to be searched.

func Chat

Chat pipes in-game chat to Discord.

func ErrorLog

func ErrorLog(err error)

ErrorLog logs the error to file and then exits the application with an exit code of 1.

func Exit

func Exit(ExitCode int)

Exit exits the application.

func LocateMentionPosition

func LocateMentionPosition(List []string) []int

LocateMentionPosition locates the position in a string list for the discord mention.

func SearchForUser

func SearchForUser(name string) *discordgo.User

SearchForUser searches for the user to be mentioned.

Types

type UserList

type UserList struct {
	UserID string
	Nick   string
	User   *discordgo.User
}

UserList is a struct for member info.

Jump to

Keyboard shortcuts

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