22 #include <yaml-cpp/yaml.h> 40 std::vector<std::string> _requires;
42 int _fuelMax, _damageMax, _speedMax, _accel, _weapons, _soldiers, _vehicles, _costBuy, _costRent, _costSell;
43 std::string _refuelItem;
44 int _repairRate, _refuelRate, _radarRange, _radarChance, _sightRange, _transferTime, _score;
47 int _listOrder, _maxItems, _maxAltitude;
48 std::vector<std::vector <int> > _deployment;
55 void load(
const YAML::Node& node,
Mod *mod,
int listOrder);
void load(const YAML::Node &node, Mod *mod, int listOrder)
Loads craft data from YAML.
Definition: RuleCraft.cpp:51
unsigned int getWeapons() const
Gets the craft's weapon capacity.
Definition: RuleCraft.cpp:182
int getRentCost() const
Gets the craft's rent for a month.
Definition: RuleCraft.cpp:221
int getMaxFuel() const
Gets the craft's maximum fuel.
Definition: RuleCraft.cpp:142
int getMaxDamage() const
Gets the craft's maximum damage.
Definition: RuleCraft.cpp:152
int getSightRange() const
Gets the craft's sight range.
Definition: RuleCraft.cpp:281
int getRepairRate() const
Gets the craft's repair rate.
Definition: RuleCraft.cpp:251
int getSellCost() const
Gets the craft's value.
Definition: RuleCraft.cpp:231
Contains all the game-specific static data that never changes throughout the game, like rulesets and resources.
Definition: Mod.h:87
int getMaxSpeed() const
Gets the craft's maximum speed.
Definition: RuleCraft.cpp:162
bool isWaterOnly() const
Gets if this craft only fights on water.
Definition: RuleCraft.cpp:365
std::string getType() const
Gets the craft's type.
Definition: RuleCraft.cpp:104
int getRadarRange() const
Gets the craft's radar range.
Definition: RuleCraft.cpp:271
~RuleCraft()
Cleans up the craft ruleset.
Definition: RuleCraft.cpp:39
int getSprite() const
Gets the craft's sprite.
Definition: RuleCraft.cpp:124
int getScore() const
Gets the craft's score.
Definition: RuleCraft.cpp:301
int getListOrder() const
Gets the list weight for this craft.
Definition: RuleCraft.cpp:328
int getBuyCost() const
Gets the craft's cost.
Definition: RuleCraft.cpp:212
std::string getRefuelItem() const
Gets the craft's refuel item.
Definition: RuleCraft.cpp:241
RuleTerrain * getBattlescapeTerrainData()
Gets the craft's terrain data.
Definition: RuleCraft.cpp:310
bool getSpacecraft() const
Checks if this craft is capable of travelling to mars.
Definition: RuleCraft.cpp:319
RuleCraft(const std::string &type)
Creates a blank craft ruleset.
Definition: RuleCraft.cpp:31
Represents a specific type of craft.
Definition: RuleCraft.h:36
int getRefuelRate() const
Gets the craft's refuel rate.
Definition: RuleCraft.cpp:261
int getRadarChance() const
Gets the craft's radar chance.
Definition: RuleCraft.h:93
int getMaxItems() const
Gets the item limit for this craft.
Definition: RuleCraft.cpp:346
int getVehicles() const
Gets the craft's vehicle capacity.
Definition: RuleCraft.cpp:202
int getSoldiers() const
Gets the craft's soldier capacity.
Definition: RuleCraft.cpp:192
Represents a specific type of Battlescape Terrain.
Definition: RuleTerrain.h:39
int getTransferTime() const
Gets the craft's transfer time.
Definition: RuleCraft.cpp:291
int getMaxAltitude() const
Gets how high this craft can go.
Definition: RuleCraft.cpp:355
std::vector< std::vector< int > > & getDeployment()
Gets the deployment priority for the craft.
Definition: RuleCraft.cpp:337
const std::vector< std::string > & getRequirements() const
Gets the craft's requirements.
Definition: RuleCraft.cpp:114
int getMarker() const
Gets the craft's globe marker.
Definition: RuleCraft.cpp:133
int getAcceleration() const
Gets the craft's acceleration.
Definition: RuleCraft.cpp:172
Definition: BaseInfoState.cpp:40