OpenXcom
1.0
Open-source clone of the original X-Com
|
Represents a specific type of armor. More...
#include <Armor.h>
Public Member Functions | |
Armor (const std::string &type) | |
Creates a blank armor ruleset. More... | |
~Armor () | |
Cleans up the armor ruleset. | |
void | load (const YAML::Node &node) |
Loads the armor data from YAML. More... | |
std::string | getType () const |
Gets the armor's type. More... | |
std::string | getSpriteSheet () const |
Gets the unit's sprite sheet. More... | |
std::string | getSpriteInventory () const |
Gets the unit's inventory sprite. More... | |
int | getFrontArmor () const |
Gets the front armor level. More... | |
int | getSideArmor () const |
Gets the side armor level. More... | |
int | getRearArmor () const |
Gets the rear armor level. More... | |
int | getUnderArmor () const |
Gets the under armor level. More... | |
std::string | getCorpseGeoscape () const |
Gets the Geoscape corpse item. More... | |
const std::vector< std::string > & | getCorpseBattlescape () const |
Gets the Battlescape corpse item. More... | |
std::string | getStoreItem () const |
Gets the stores item. More... | |
int | getDrawingRoutine () const |
Gets the battlescape drawing routine ID. More... | |
MovementType | getMovementType () const |
Gets whether the armor can fly. More... | |
int | getSize () const |
Gets whether this is a normal or big unit. More... | |
float | getDamageModifier (ItemDamageType dt) |
Gets damage modifier. More... | |
std::vector< int > | getLoftempsSet () const |
Gets loftempSet. More... | |
UnitStats * | getStats () |
Gets the armor's stats. More... | |
int | getWeight () |
Gets the armor's weight. More... | |
Represents a specific type of armor.
Not only soldier armor, but also alien armor - some alien races wear Soldier Armor, Leader Armor or Commander Armor depending on their rank.
OpenXcom::Armor::Armor | ( | const std::string & | type | ) |
Creates a blank armor ruleset.
Creates a blank ruleset for a certain type of armor.
type | String defining the type. |
const std::vector< std::string > & OpenXcom::Armor::getCorpseBattlescape | ( | ) | const |
Gets the Battlescape corpse item.
Gets the list of corpse items dropped by the unit in the Battlescape (one per unit tile).
std::string OpenXcom::Armor::getCorpseGeoscape | ( | ) | const |
Gets the Geoscape corpse item.
Gets the corpse item used in the Geoscape.
float OpenXcom::Armor::getDamageModifier | ( | ItemDamageType | dt | ) |
Gets damage modifier.
Gets the damage modifier for a certain damage type.
dt | The damageType. |
int OpenXcom::Armor::getDrawingRoutine | ( | ) | const |
Gets the battlescape drawing routine ID.
Gets the drawing routine ID.
int OpenXcom::Armor::getFrontArmor | ( | ) | const |
Gets the front armor level.
std::vector< int > OpenXcom::Armor::getLoftempsSet | ( | ) | const |
Gets loftempSet.
Gets the loftempSet.
MovementType OpenXcom::Armor::getMovementType | ( | ) | const |
Gets whether the armor can fly.
Gets the movement type of this armor.
Useful for determining whether the armor can fly.
int OpenXcom::Armor::getRearArmor | ( | ) | const |
Gets the rear armor level.
int OpenXcom::Armor::getSideArmor | ( | ) | const |
Gets the side armor level.
int OpenXcom::Armor::getSize | ( | ) | const |
Gets whether this is a normal or big unit.
Gets the size of the unit.
Normally this is 1 (small) or 2 (big).
std::string OpenXcom::Armor::getSpriteInventory | ( | ) | const |
Gets the unit's inventory sprite.
std::string OpenXcom::Armor::getSpriteSheet | ( | ) | const |
Gets the unit's sprite sheet.
UnitStats * OpenXcom::Armor::getStats | ( | ) |
Gets the armor's stats.
Gets pointer to the armor's stats.
std::string OpenXcom::Armor::getStoreItem | ( | ) | const |
Gets the stores item.
Gets the storage item needed to equip this.
std::string OpenXcom::Armor::getType | ( | ) | const |
Gets the armor's type.
Returns the language string that names this armor.
Each armor has a unique name. Coveralls, Power Suit,...
int OpenXcom::Armor::getUnderArmor | ( | ) | const |
Gets the under armor level.
int OpenXcom::Armor::getWeight | ( | ) |
Gets the armor's weight.
void OpenXcom::Armor::load | ( | const YAML::Node & | node | ) |
Loads the armor data from YAML.
Loads the armor from a YAML file.
node | YAML node. |