Namespaces | Functions

unit_display.hpp File Reference

Display units performing various actions: moving, attacking, and dying. More...

#include "unit_map.hpp"
#include "gamestatus.hpp"
Include dependency graph for unit_display.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

namespace  unit_display
 

Contains a number of free functions which display units.


Functions

void unit_display::move_unit (const std::vector< map_location > &path, unit &u, const std::vector< team > &teams, bool animate=true, map_location::DIRECTION dir=map_location::NDIRECTIONS)
 Display a unit moving along a given path.
void unit_display::move_unit_start (const std::vector< map_location > &path, unit &temp_unit, const team &tm)
void unit_display::move_unit_step (const std::vector< map_location > &path, size_t i, unit &temp_unit, const team &tm)
void unit_display::move_unit_finish (const std::vector< map_location > &path, unit &temp_unit)
void unit_display::unit_draw_weapon (const map_location &loc, unit &u, const attack_type *attack=NULL, const attack_type *secondary_attack=NULL, const map_location &defender_loc=map_location::null_location, unit *defender=NULL)
 Play a pre-fight animation First unit is the attacker, second unit the defender.
void unit_display::unit_sheath_weapon (const map_location &loc, unit *u=NULL, const attack_type *attack=NULL, const attack_type *secondary_attack=NULL, const map_location &defender_loc=map_location::null_location, unit *defender=NULL)
 Play a post-fight animation Both unit can be set to null, only valid units will play their animation.
void unit_display::unit_die (const map_location &loc, unit &u, const attack_type *attack=NULL, const attack_type *secondary_attack=NULL, const map_location &winner_loc=map_location::null_location, unit *winner=NULL)
 Show a unit fading out.
void unit_display::unit_attack (const map_location &a, const map_location &b, int damage, const attack_type &attack, const attack_type *secondary_attack, int swing, std::string hit_text, int drain_amount, std::string att_text)
 Make the unit on tile 'a' attack the unit on tile 'b'.
void unit_display::unit_recruited (const map_location &loc, const map_location &leader_loc)
void unit_display::unit_healing (unit &healed, const map_location &healed_loc, const std::vector< unit * > &healers, int healing)
 This will use a poisoning anim if healing<0.
void unit_display::wml_animation (const vconfig &cfg, const map_location &default_location=map_location::null_location)
 Parse a standard WML for animations and play the corresponding animation.

Detailed Description

Display units performing various actions: moving, attacking, and dying.

Definition in file unit_display.hpp.

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated by doxygen 1.7.1 on Fri May 25 2012 01:11:01 for The Battle for Wesnoth
Gna! | Forum | Wiki | CIA | devdocs