config

package
v1.0.7 Latest Latest
Warning

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

Go to latest
Published: Aug 16, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CLIConfig

type CLIConfig struct {
	Profile    string `yaml:"profile"`
	ConfigFile string `yaml:"-"`

	// Connection
	Username   string `yaml:"username" json:"username"`
	Password   string `yaml:"password" json:"password"`
	AuthServer string `yaml:"auth_server" json:"auth_server"`

	// Character / play
	CharName   string `yaml:"char_name" json:"character_name"`
	RealmIndex int    `yaml:"realm_index" json:"realm_index"`
	Race       int    `yaml:"race" json:"race"`
	Class      int    `yaml:"class" json:"class"`
	Gender     uint8  `yaml:"gender" json:"gender"`

	// Behavior
	BotMode     string `yaml:"bot_mode" json:"mode"`
	DungeonName string `yaml:"dungeon" json:"dungeon_name"`
	LuaScript   string `yaml:"lua_script" json:"lua_script"`
	LuaCode     string `yaml:"lua_code" json:"lua_code"`

	// Data & pathfinding (embedded by default)
	DataDir            string `yaml:"data_dir" json:"data_dir"`
	PathfindingAddress string `yaml:"pathfinding_addr" json:"pathfinding_addr"`

	// Behavior flags
	DeleteExistingChars bool `yaml:"delete_existing_chars" json:"delete_existing_chars"`
	LogDecisionsToChat  bool `yaml:"log_decisions_to_chat" json:"log_decisions_to_chat"`
	DisableTargetCache  bool `yaml:"disable_target_cache" json:"disable_target_cache"`

	// Validation tooling flags (see bot.Config for details). These are off by default
	// so regular high-scale runs have no performance impact.
	ValidationMode      bool   `yaml:"validation_mode" json:"validation_mode"`
	ValidationLogPath   string `yaml:"validation_log" json:"validation_log"`
	EnablePacketTrace   bool   `yaml:"enable_packet_trace" json:"enable_packet_trace"`
	EnableDetailedAuras bool   `yaml:"enable_detailed_auras" json:"enable_detailed_auras"`

	// Node / server
	Listen string `yaml:"listen" json:"listen"`

	// Orchestrator / scenario
	NumBots           int           `yaml:"num_bots" json:"num_bots"`
	Nodes             string        `yaml:"nodes" json:"nodes"`
	AccountPrefix     string        `yaml:"account_prefix" json:"account_prefix"`
	AccountPassword   string        `yaml:"account_password" json:"account_password"`
	DBDSN             string        `yaml:"db_dsn" json:"db_dsn"`
	Duration          time.Duration `yaml:"duration"`
	SpawnRateLimit    int           `yaml:"spawn_rate_limit"`
	SpawnRateInterval time.Duration `yaml:"spawn_rate_interval"`

	// Internal
	AuthDBDSN       string `yaml:"auth_db_dsn"`
	CharactersDBDSN string `yaml:"characters_db_dsn"`
}

CLIConfig holds the merged configuration for azghost CLI, node, orchestrator and scenario modes.

func Load

func Load(profile, cfgPath string) (CLIConfig, error)

Load merges profile (yaml), config file, env and defaults. Profile is looked up in common locations.

Jump to

Keyboard shortcuts

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