Documentation
¶
Overview ¶
Package sotdlgen implements a character generator for the SotDL RPG.
Index ¶
Constants ¶
const VERSION = "0.2.2"
VERSION number.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Armor ¶
type Armor struct { // TODO: Implement armor. Name string `json:"name"` Type string `json:"type"` DefenseBonus int `json:"defense"` }
Armor represents properties of a given suit of armor.
type Attributes ¶
type Attributes struct { Strength int `json:"strength"` Agility int `json:"agility"` Intellect int `json:"intellect"` Will int `json:"will"` Speed int `json:"speed"` Power int `json:"power"` Health int `json:"health"` Size string `json:"size"` Insanity int `json:"insanity"` Corruption int `json:"corruption"` Defense int `json:"defense"` Perception int `json:"perception"` HealingRate int `json:"healing_rate"` // contains filtered or unexported fields }
Attributes represents character statistics.
type CharDB ¶
CharDB represents path data extracted from the core rules PDF, along with a list of names for random character naming.
type Character ¶
type Character struct { Name string `json:"name"` Gender string `json:"gender"` Ancestry string `json:"ancestry"` LangAndProf []string `json:"languages_and_professions"` NovicePath string `json:"novice_path"` ExpertPath string `json:"expert_path"` MasterPath string `json:"master_path"` Talents []string `json:"talents"` Level int `json:"level"` Attributes Attributes `json:"attributes"` Seed string `json:"seed"` }
Character represents the primary features of the character.
func NewCharacter ¶
NewCharacter generates a SotDL character given a set of user options.
type Die ¶
type Die struct {
// contains filtered or unexported fields
}
Die represents a single die of the form <code>D6+<pips>.
type Level ¶
type Level struct { Strength int `json:"strength"` Agility int `json:"agility"` Intellect int `json:"intellect"` Will int `json:"will"` PerceptionMod int `json:"perception_mod"` DefenseMod int `json:"defense_mod"` HealthMod int `json:"health_mod"` HealingRate float64 `json:"healing_rate"` Speed int `json:"speed"` Power int `json:"power"` Damage int `json:"damage"` Insanity int `json:"insanity"` Corruption int `json:"corruption"` Size string `json:"size"` LangAndProf []string `json:"lang_and_prof"` Talents []string `json:"talents"` }
Level contains attributes and characteristics, as well as narrative talents and professions/languages extracted from the core rules. A single level represents an ancestry or path at a given character level.
type NameList ¶
type NameList struct { Ancestry string `json:"ancestry"` Ethnicity string `json:"ethnicity"` Type string `json:"type"` Names []string `json:"names"` }
NameList represents the list of names for a given ancestry, ethnicity, and type.
type Opts ¶
type Opts struct { Age string Ancestry string `docopt:"--ancestry"` Background string Description string ExpertPath string `docopt:"--expert-path"` Gender string `docopt:"--gender"` Languages string Level string `docopt:"--level"` LogLevel string `docopt:"--log-level"` MasterPath string `docopt:"--master-path"` Name string `docopt:"--name"` NovicePath string `docopt:"--novice-path"` Professions string Seed string `docopt:"--seed"` DataFile string `docopt:"--data-file"` }
Opts contains user input optionsr; used in CLI implementations.
type Spell ¶
type Spell struct { // TODO: Implement spells. Name string `json:"name"` Type string `json:"type"` Rank int `json:"rank"` Target string `json:"target"` Area string `json:"area"` Duration string `json:"duration"` Triggered bool `json:"triggered"` Sacrifice bool `json:"sacrifice"` Permanence bool `json:"permanence"` AttackRoll20 string `json:"attack_20+"` Description string `json:"description"` }
Spell represents properties of a given spell.
type Weapon ¶
type Weapon struct { // TODO: Implement weapons. Name string `json:"name"` Type string `json:"type"` Hands string `json:"hands"` Cumbersome bool `json:"cumbersome"` Finesse bool `json:"finesse"` DefenseBonus int `json:"defense_bonus"` Misfire bool `json:"misfire"` Range string `json:"range"` Reach int `json:"reach"` Reload bool `json:"reload"` Size int `json:"size"` Uses string `json:"uses"` Thrown bool `json:"thrown"` Damage Die `json:"damage"` }
Weapon represents properties of a given weapon.