#include <race.hpp>

Public Types | |
| enum | GENDER { MALE, FEMALE, NUM_GENDERS } |
Public Member Functions | |
| unit_race () | |
| unit_race (const config &cfg) | |
| const config & | get_cfg () const |
| const std::string & | id () const |
| const t_string & | name (GENDER gender=MALE) const |
| const t_string & | plural_name () const |
| const t_string & | description () const |
| std::string | generate_name (GENDER gender, rand_rng::simple_rng *rng=0) const |
| bool | uses_global_traits () const |
| const config::const_child_itors & | additional_traits () const |
| const config::const_child_itors & | additional_topics () const |
| unsigned int | num_traits () const |
| const std::string & | undead_variation () const |
Private Attributes | |
| const config | cfg_ |
| std::string | id_ |
| t_string | name_ [NUM_GENDERS] |
| t_string | plural_name_ |
| t_string | description_ |
| unsigned int | ntraits_ |
| markov_prefix_map | next_ [NUM_GENDERS] |
| int | chain_size_ |
| config::const_child_itors | traits_ |
| config::const_child_itors | topics_ |
| bool | global_traits_ |
| std::string | undead_variation_ |
Definition at line 29 of file race.hpp.
| enum unit_race::GENDER |
| unit_race::unit_race | ( | const config & | cfg | ) |
Definition at line 156 of file race.cpp.
References chain_size_, t_string::empty(), FEMALE, id_, MALE, markov_prefixes(), name_, next_, plural_name_, utils::split(), and lg::wml_error.

| const config::const_child_itors & unit_race::additional_topics | ( | ) | const |
| const config::const_child_itors & unit_race::additional_traits | ( | ) | const |
Definition at line 206 of file race.cpp.
References traits_.
Referenced by unit_type::build_full().

| const t_string& unit_race::description | ( | ) | const [inline] |
Definition at line 41 of file race.hpp.
References description_.
Referenced by impl_race_get().

| std::string unit_race::generate_name | ( | unit_race::GENDER | gender, | |
| rand_rng::simple_rng * | rng = 0 | |||
| ) | const |
Definition at line 194 of file race.cpp.
References chain_size_, markov_generate_name(), next_, and utils::wstring_to_string().
Referenced by unit::generate_name(), and generate_name().


| const config& unit_race::get_cfg | ( | ) | const [inline] |
Definition at line 37 of file race.hpp.
References cfg_.
Referenced by impl_race_get().

| const std::string& unit_race::id | ( | ) | const [inline] |
Definition at line 38 of file race.hpp.
References id_.
Referenced by unit_type::hide_help(), unit::internal_matches_filter(), unit_type_data::set_config(), unit_race(), and unit::write().

Definition at line 39 of file race.hpp.
References name_.
Referenced by dialogs::units_list_preview_pane::get_details(), impl_race_get(), and unit_race().

| unsigned int unit_race::num_traits | ( | ) | const |
Definition at line 216 of file race.cpp.
References ntraits_.
Referenced by unit_type::build_help_index(), and impl_race_get().

| const t_string& unit_race::plural_name | ( | ) | const [inline] |
Definition at line 40 of file race.hpp.
References plural_name_.
Referenced by impl_race_get().

| const std::string& unit_race::undead_variation | ( | ) | const [inline] |
Definition at line 50 of file race.hpp.
References undead_variation_.
Referenced by unit_type::build_full(), and impl_race_get().

| bool unit_race::uses_global_traits | ( | ) | const |
Definition at line 201 of file race.cpp.
References global_traits_.
Referenced by unit_type::build_full(), and impl_race_get().

const config unit_race::cfg_ [private] |
int unit_race::chain_size_ [private] |
Definition at line 61 of file race.hpp.
Referenced by generate_name(), and unit_race().
t_string unit_race::description_ [private] |
Definition at line 58 of file race.hpp.
Referenced by description().
bool unit_race::global_traits_ [private] |
Definition at line 65 of file race.hpp.
Referenced by uses_global_traits().
std::string unit_race::id_ [private] |
Definition at line 55 of file race.hpp.
Referenced by id(), and unit_race().
t_string unit_race::name_[NUM_GENDERS] [private] |
Definition at line 56 of file race.hpp.
Referenced by name(), and unit_race().
markov_prefix_map unit_race::next_[NUM_GENDERS] [private] |
Definition at line 60 of file race.hpp.
Referenced by generate_name(), and unit_race().
unsigned int unit_race::ntraits_ [private] |
Definition at line 59 of file race.hpp.
Referenced by num_traits().
t_string unit_race::plural_name_ [private] |
Definition at line 57 of file race.hpp.
Referenced by plural_name(), and unit_race().
config::const_child_itors unit_race::topics_ [private] |
Definition at line 64 of file race.hpp.
Referenced by additional_topics().
config::const_child_itors unit_race::traits_ [private] |
Definition at line 63 of file race.hpp.
Referenced by additional_traits().
std::string unit_race::undead_variation_ [private] |
Definition at line 66 of file race.hpp.
Referenced by undead_variation().
| Generated by doxygen 1.7.1 on Thu May 24 2012 01:17:40 for The Battle for Wesnoth | Gna! | Forum | Wiki | CIA | devdocs |