Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var StringToLevel = map[string]logger.LogLevel{ "trace": logger.LevelTrace, "debug": logger.LevelDebug, "info": logger.LevelInfo, "warn": logger.LevelWarning, "error": logger.LevelError, "fatal": logger.LevelFatal, }
Functions ¶
Types ¶
type Character ¶
type Character string
Right now we are using strings for songs and characters, but they could be more complicated structures with more metadata later.
type Characters ¶
type Characters struct {
Lists []CharList `toml:"list"`
}
func ReadCharacters ¶
func ReadCharacters() (*Characters, error)
Attempts to read character settings. Returns nil CharList and an error if it fails.
type Music ¶
type Music struct {
Categories []SongCategory `toml:"category"`
}
type Room ¶
type Room struct { Name string `toml:"name"` DefaultDesc string `toml:"description"` DefaultBg string `toml:"background"` LockBg bool `toml:"lock_background"` DefaultAmbiance string `toml:"ambiance"` LockAmbiance bool `toml:"lock_ambiance"` AdjacentRooms []string `toml:"adjacent_rooms"` CharLists []string `toml:"character_lists"` SongCategories []string `toml:"song_categories"` Sides []string `toml:"side_list"` AllowBlankpost bool `toml:"allow_blankpost"` AllowShouting bool `toml:"allow_shouting"` AllowIniswap bool `toml:"allow_iniswap"` ForceImmediate bool `toml:"force_immediate"` // TODO: add buffered logging LogMethods []string `toml:"log_methods"` DebugLog bool `toml:"log_debug"` }
func RoomDefault ¶
func RoomDefault() *Room
type Server ¶
type Server struct { Name string `toml:"name"` Username string `toml:"server_username"` Desc string `toml:"description"` MaxPlayers int `toml:"max_players"` PortWS int `toml:"ws_port"` PortTCP int `toml:"legacy_port"` PortRPC int `toml:"rpc_port"` AllowAO bool `toml:"allow_ao"` AssetURL string `toml:"asset_url"` // these seem more appropriate for a different section? MaxMsgSize int `toml:"max_msg_size"` MaxNameSize int `toml:"max_name_size"` LevelString string `toml:"log_level"` }
func ReadServer ¶
Attempts to read server configuration. Returns default server settings if it fails.
func ServerDefault ¶
func ServerDefault() *Server
type Song ¶
type Song string //TODO: song aliases
Right now we are using strings for songs and characters, but they could be more complicated structures with more metadata later.
type SongCategory ¶
Click to show internal directories.
Click to hide internal directories.