101 void attack_expected_damage(
double attacker_inflict,
double defender_inflict);
102 void attack_result(
hit_result res,
int cth,
int damage,
int drain);
103 void defend_result(
hit_result res,
int cth,
int damage,
int drain);
112 stats& attacker_stats();
113 stats& defender_stats();
136 typedef std::vector< std::pair<const std::string *, const stats *>>
levels;
int chance_to_hit_defender
std::ostream & operator<<(std::ostream &outstream, const statistics::stats::hitrate_t &by_cth)
long long damage_inflicted
battle_result_map defends_taken
Statistics of enemies' attacks against this side on their turns.
This class represents a single unit of a specific type.
void un_recall_unit(const unit &u)
long long turn_damage_taken
std::map< int, hitrate_t > hitrate_map
A type that maps chance-to-hit percentage to number of hits and strikes at that CTH.
int sum_str_int_map(const std::map< std::string, int > &m)
void reset_current_scenario()
Reset the stats of the current scenario to the beginning.
void reset_turn_stats(const std::string &save_id)
void recruit_unit(const unit &u)
std::vector< std::pair< const std::string *, const stats * > > levels
Stats (and name) for each scenario.
long long expected_damage_taken
long long turn_expected_damage_inflicted
battle_result_map attacks_inflicted
Statistics of this side's attacks on its own turns.
std::string defender_side
static const int decimal_shift
Class for writing a config out to a file in pieces.
std::map< int, battle_sequence_frequency_map > battle_result_map
A type that will map different % chances to hit to different results.
int un_recall_unit_cost(const unit &u)
battle_result_map defends_inflicted
Statistics of this side's attacks on enemies' turns.
levels level_stats(const std::string &save_id)
Returns a list of names and stats for each scenario in the current campaign.
hitrate_map turn_by_cth_taken
void read_stats(const config &cfg)
void read(const config &cfg)
battle_result_map attacks_taken
Statistics of enemies' counter attacks on this side's turns.
hitrate_map turn_by_cth_inflicted
int sum_cost_str_int_map(const std::map< std::string, int > &m)
void advance_unit(const unit &u)
stats calculate_stats(const std::string &save_id)
long long turn_damage_inflicted
void recall_unit(const unit &u)
long long expected_damage_inflicted
std::string defender_type
str_int_map battle_sequence_frequency_map
std::map< std::string, int > str_int_map
long long turn_expected_damage_taken
void un_recruit_unit(const unit &u)
A config object defines a single node in a WML file, with access to child nodes.
void clear_current_scenario()
Delete the current scenario from the stats.
hitrate_map by_cth_inflicted