16 #ifndef ATTACK_PREDICTION_DISPLAY_H_INCLUDED
17 #define ATTACK_PREDICTION_DISPLAY_H_INCLUDED
80 std::vector<std::string>& left_strings, std::vector<std::string>& right_strings,
81 int& left_strings_width,
int& right_strings_width,
int& strings_width);
91 std::vector<std::pair<int, double> >& hp_prob_vector);
95 void draw_unit(
int x_off,
int damage_line_skip,
int left_strings_width,
96 const std::vector<std::string>& left_strings,
97 const std::vector<std::string>& right_strings,
99 surface& hp_distrib,
int hp_distrib_width);
std::vector< std::string > defender_left_strings_
int attacker_hp_distrib_height_
int get_strings_max_length(const std::vector< std::string > &strings)
void get_hp_prob_vector(const std::vector< double > &hp_dist, std::vector< std::pair< int, double > > &hp_prob_vector)
int attacker_hp_distrib_width_
int hp_distrib_string_width_
std::string hp_distrib_string_
std::string defender_label_
surface defender_hp_distrib_
surface attacker_hp_distrib_
int attacker_strings_width_
int attacker_right_strings_width_
static const int inter_column_gap_
int attacker_label_width_
const map_location & defender_loc_
battle_prediction_pane(const battle_context &bc, const map_location &attacker_loc, const map_location &defender_loc)
std::vector< std::string > attacker_left_strings_
void get_unit_strings(const battle_context_unit_stats &stats, const unit &u, const map_location &u_loc, float u_unscathed, const unit &opp, const map_location &opp_loc, const attack_type *opp_weapon, std::vector< std::string > &left_strings, std::vector< std::string > &right_strings, int &left_strings_width, int &right_strings_width, int &strings_width)
const std::vector< battle_context > & bc_vector_
void draw_unit(int x_off, int damage_line_skip, int left_strings_width, const std::vector< std::string > &left_strings, const std::vector< std::string > &right_strings, const std::string &label, int label_width, surface &hp_distrib, int hp_distrib_width)
static const int inter_line_gap_
Computes the statistics of a battle between an attacker and a defender unit.
std::string attacker_label_
int defender_hp_distrib_height_
void get_hp_distrib_surface(const std::vector< std::pair< int, double > > &hp_prob_vector, const battle_context_unit_stats &stats, const battle_context_unit_stats &opp_stats, surface &surf, int &width, int &height)
Structure describing the statistics of a unit involved in the battle.
static const int inter_units_gap_
static const int max_hp_distrib_rows_
Encapsulates the map of the game.
const map_location & attacker_loc_
GLsizei const GLchar ** strings
int attacker_left_strings_width_
int defender_left_strings_width_
int defender_right_strings_width_
int units_strings_height_
GLint GLint GLint GLint GLint GLint GLsizei GLsizei height
std::vector< std::string > defender_right_strings_
const map_location & attacker_loc_
const map_location & defender_loc_
attack_prediction_displayer(const std::vector< battle_context > &bc_vector, const map_location &attacker_loc, const map_location &defender_loc)
RESULT button_pressed(int selection)
std::vector< std::string > attacker_right_strings_
GLint GLint GLint GLint GLint GLint GLsizei width
GLsizei const GLcharARB ** string
int defender_strings_width_
int defender_hp_distrib_width_
int defender_label_width_