19 #ifndef OPENXCOM_ARMOR_H
20 #define OPENXCOM_ARMOR_H
24 #include <yaml-cpp/yaml.h>
39 static const int DAMAGE_TYPES = 10;
41 std::string _type, _spriteSheet, _spriteInv, _corpseGeo, _storeItem;
42 std::vector<std::string> _corpseBattle;
43 int _frontArmor, _sideArmor, _rearArmor, _underArmor, _drawingRoutine;
44 MovementType _movementType;
46 float _damageModifier[DAMAGE_TYPES];
47 std::vector<int> _loftempsSet;
51 Armor(
const std::string &type);
55 void load(
const YAML::Node& node);
int getSize() const
Gets whether this is a normal or big unit.
Definition: Armor.cpp:202
int getFrontArmor() const
Gets the front armor level.
Definition: Armor.cpp:118
std::string getSpriteInventory() const
Gets the unit's inventory sprite.
Definition: Armor.cpp:109
int getSideArmor() const
Gets the side armor level.
Definition: Armor.cpp:127
std::string getSpriteSheet() const
Gets the unit's sprite sheet.
Definition: Armor.cpp:100
float getDamageModifier(ItemDamageType dt)
Gets damage modifier.
Definition: Armor.cpp:212
Represents a specific type of armor.
Definition: Armor.h:36
~Armor()
Cleans up the armor ruleset.
Definition: Armor.cpp:38
This struct holds some plain unit attribute data together.
Definition: Unit.h:32
Armor(const std::string &type)
Creates a blank armor ruleset.
Definition: Armor.cpp:29
const std::vector< std::string > & getCorpseBattlescape() const
Gets the Battlescape corpse item.
Definition: Armor.cpp:165
std::string getType() const
Gets the armor's type.
Definition: Armor.cpp:91
UnitStats * getStats()
Gets the armor's stats.
Definition: Armor.cpp:229
int getRearArmor() const
Gets the rear armor level.
Definition: Armor.cpp:136
void load(const YAML::Node &node)
Loads the armor data from YAML.
Definition: Armor.cpp:47
MovementType getMovementType() const
Gets whether the armor can fly.
Definition: Armor.cpp:193
std::string getStoreItem() const
Gets the stores item.
Definition: Armor.cpp:174
int getUnderArmor() const
Gets the under armor level.
Definition: Armor.cpp:145
std::string getCorpseGeoscape() const
Gets the Geoscape corpse item.
Definition: Armor.cpp:155
std::vector< int > getLoftempsSet() const
Gets loftempSet.
Definition: Armor.cpp:220
int getDrawingRoutine() const
Gets the battlescape drawing routine ID.
Definition: Armor.cpp:183
int getWeight()
Gets the armor's weight.
Definition: Armor.cpp:238