Documentation ¶
Index ¶
- Variables
- func DetectAndUpdateVersion(config *runner.Config) error
- func DetectServerVersion() (string, error)
- func DownloadServerJar(url, savePath string) error
- type BeforeLaunchFunc
- type Launcher
- func (l *Launcher) AddToOp(players []string)
- func (l *Launcher) AddToWhiteList(players []string)
- func (l *Launcher) Launch() error
- func (l *Launcher) QuickUndo(slot int) error
- func (l *Launcher) RegisterBeforeLaunchHook(fn BeforeLaunchFunc)
- func (l *Launcher) RegisterOnHealthyHook(fn OnHealthyFunc)
- func (l *Launcher) SaveAll() error
- func (l *Launcher) Stop()
- func (l *Launcher) StopToRestart()
- type LevelDat
- type OnHealthyFunc
- type PlayerList
- type Rcon
- func (r *Rcon) AddToOp(player string) error
- func (r *Rcon) AddToWhiteList(player string) error
- func (r *Rcon) Execute(cmd string) (string, error)
- func (r *Rcon) List() (PlayerList, error)
- func (r *Rcon) SaveAll() error
- func (r *Rcon) Say(message string) error
- func (r *Rcon) Seed() (string, error)
- func (r *Rcon) Stop() error
- type ServerProperties
- func (p *ServerProperties) DangerouslySetProperty(k, v string)
- func (p *ServerProperties) LoadConfig(config *runner.Config) error
- func (p *ServerProperties) OverrideProperties(props map[string]string)
- func (p *ServerProperties) SetDifficulty(difficulty string) error
- func (p *ServerProperties) SetLevelType(levelType string) error
- func (p *ServerProperties) SetMotd(motd string)
- func (p *ServerProperties) SetSeed(seed string)
- func (p *ServerProperties) Write(out io.Writer) error
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrRestartRequested = errors.New("restart requested")
)
Functions ¶
func DetectAndUpdateVersion ¶
func DetectServerVersion ¶
func DownloadServerJar ¶
Types ¶
type BeforeLaunchFunc ¶
type BeforeLaunchFunc func(l *Launcher)
type Launcher ¶
type Launcher struct { Rcon *Rcon // contains filtered or unexported fields }
func NewLauncher ¶
func NewLauncher(config *runner.Config, world *world.WorldService) *Launcher
func (*Launcher) AddToWhiteList ¶
func (*Launcher) RegisterBeforeLaunchHook ¶
func (l *Launcher) RegisterBeforeLaunchHook(fn BeforeLaunchFunc)
func (*Launcher) RegisterOnHealthyHook ¶
func (l *Launcher) RegisterOnHealthyHook(fn OnHealthyFunc)
func (*Launcher) StopToRestart ¶
func (l *Launcher) StopToRestart()
type OnHealthyFunc ¶
type OnHealthyFunc func(l *Launcher)
type PlayerList ¶
type PlayerList []string
type Rcon ¶
type Rcon struct {
// contains filtered or unexported fields
}
func (*Rcon) AddToWhiteList ¶
func (*Rcon) List ¶
func (r *Rcon) List() (PlayerList, error)
type ServerProperties ¶
type ServerProperties struct {
// contains filtered or unexported fields
}
func NewServerProperties ¶
func NewServerProperties() *ServerProperties
func (*ServerProperties) DangerouslySetProperty ¶
func (p *ServerProperties) DangerouslySetProperty(k, v string)
func (*ServerProperties) LoadConfig ¶
func (p *ServerProperties) LoadConfig(config *runner.Config) error
func (*ServerProperties) OverrideProperties ¶
func (p *ServerProperties) OverrideProperties(props map[string]string)
func (*ServerProperties) SetDifficulty ¶
func (p *ServerProperties) SetDifficulty(difficulty string) error
func (*ServerProperties) SetLevelType ¶
func (p *ServerProperties) SetLevelType(levelType string) error
func (*ServerProperties) SetMotd ¶
func (p *ServerProperties) SetMotd(motd string)
func (*ServerProperties) SetSeed ¶
func (p *ServerProperties) SetSeed(seed string)
Click to show internal directories.
Click to hide internal directories.