19 #ifndef OPENXCOM_RULECRAFT_H
20 #define OPENXCOM_RULECRAFT_H
24 #include <yaml-cpp/yaml.h>
42 std::vector<std::string> _requires;
44 int _fuelMax, _damageMax, _speedMax, _accel, _weapons, _soldiers, _vehicles, _costBuy, _costRent, _costSell;
45 std::string _refuelItem;
46 int _repairRate, _refuelRate, _radarRange, _transferTime, _score;
50 std::vector<std::vector <int> > _deployment;
57 void load(
const YAML::Node& node,
Ruleset *ruleset,
int modIndex,
int nextCraftIndex);
int getBuyCost() const
Gets the craft's cost.
Definition: RuleCraft.cpp:204
int getAcceleration() const
Gets the craft's acceleration.
Definition: RuleCraft.cpp:164
int getRentCost() const
Gets the craft's rent for a month.
Definition: RuleCraft.cpp:213
void load(const YAML::Node &node, Ruleset *ruleset, int modIndex, int nextCraftIndex)
Loads craft data from YAML.
Definition: RuleCraft.cpp:54
int getSellCost() const
Gets the craft's value.
Definition: RuleCraft.cpp:223
int getMaxSpeed() const
Gets the craft's maximum speed.
Definition: RuleCraft.cpp:154
int getMaxDamage() const
Gets the craft's maximum damage.
Definition: RuleCraft.cpp:144
~RuleCraft()
Cleans up the craft ruleset.
Definition: RuleCraft.cpp:42
int getWeapons() const
Gets the craft's weapon capacity.
Definition: RuleCraft.cpp:174
Set of rules and stats for a game.
Definition: Ruleset.h:69
int getSprite() const
Gets the craft's sprite.
Definition: RuleCraft.cpp:125
int getTransferTime() const
Gets the craft's transfer time.
Definition: RuleCraft.cpp:273
int getSoldiers() const
Gets the craft's soldier capacity.
Definition: RuleCraft.cpp:184
RuleTerrain * getBattlescapeTerrainData()
Gets the craft's terrain data.
Definition: RuleCraft.cpp:292
RuleCraft(const std::string &type)
Creates a blank craft ruleset.
Definition: RuleCraft.cpp:30
Represents a specific type of craft.
Definition: RuleCraft.h:38
const std::vector< std::string > & getRequirements() const
Gets the craft's requirements.
Definition: RuleCraft.cpp:115
int getRefuelRate() const
Gets the craft's refuel rate.
Definition: RuleCraft.cpp:253
bool getSpacecraft() const
Checks if this craft is capable of travelling to mars.
Definition: RuleCraft.cpp:301
int getRadarRange() const
Gets the craft's radar range.
Definition: RuleCraft.cpp:263
int getVehicles() const
Gets the craft's vehicle capacity.
Definition: RuleCraft.cpp:194
Represents a specific type of Battlescape Terrain.
Definition: RuleTerrain.h:41
std::string getRefuelItem() const
Gets the craft's refuel item.
Definition: RuleCraft.cpp:233
int getListOrder() const
Gets the list weight for this craft.
Definition: RuleCraft.cpp:310
int getMaxFuel() const
Gets the craft's maximum fuel.
Definition: RuleCraft.cpp:134
std::vector< std::vector< int > > & getDeployment()
Gets the deployment priority for the craft.
Definition: RuleCraft.cpp:320
int getRepairRate() const
Gets the craft's repair rate.
Definition: RuleCraft.cpp:243
int getScore() const
Gets the craft's score.
Definition: RuleCraft.cpp:283
std::string getType() const
Gets the craft's type.
Definition: RuleCraft.cpp:105