12 #ifndef INDUSTRYTYPE_H 13 #define INDUSTRYTYPE_H 88 INDTILE_SPECIAL_NONE = 0,
110 byte production_rate[2];
202 static const uint8 IT_INVALID = 255;
can be exploded by a military airplane (oil refinery)
DECLARE_ENUM_AS_BIT_SET(GenderEthnicity) enum CompanyManagerFaceVariable
Bitgroups of the CompanyManagerFace variable.
const IndustrySpec * GetIndustrySpec(IndustryType thistype)
Array of industries data.
bool enabled
entity still available (by default true).newgrf can disable it, though
Types related to the industry.
IndustryConstructionType
How was the industry created.
byte map_colour
colour used for the small map
in previous game version or without newindustries activated
Money GetRemovalCost() const
Get the cost for removing this industry Take note that the cost will always be zero for non-grf indus...
uint32 prospecting_chance
Chance prospecting succeeds.
Industries at sea should be positioned near edge of the map.
Free the dynamically allocated sounds table.
static const IndustryGfx INVALID_INDUSTRYTILE
one above amount is considered invalid
ai will attempt to establish air/ship routes to this industry (oil rig)
IndustryLifeType life_type
This is also known as Industry production flag, in newgrf specs.
periodically plants fields around itself (temp and arctic farms)
do not increase production (oil wells) in the temperate climate
Definitions related to NewGRF animation.
uint16 callback_mask
Bitmask of industry callbacks that have to be called.
uint32 removal_cost_multiplier
Base removal cost multiplier.
during random map creation
can cause a subsidence (coal mine, shaft that collapses)
const IndustryTileSpec * GetIndustryTileSpec(IndustryGfx gfx)
Array of industry tiles data.
const IndustryTileTable *const * table
List of the tiles composing the industry.
is always built near towns (toy shop)
Types related to cargoes...
StringID production_down_text
Message appearing when the industry's production is decreasing.
StringID name
Displayed name of the industry.
Automatic production multiplier handling.
IndustryTileSpecialFlags special_flags
Bitmask of extra flags used by the tile.
can only be built in towns (arctic/tropic banks, water tower)
Do not force one instance of this type to appear on map generation.
Industry should be below snow-line in arctic.
IndustryLifeType
Available types of industry lifetimes.
can be exploded by a military helicopter (factory)
static IndustryGfx GetTranslatedIndustryTileID(IndustryGfx gfx)
Do industry gfx ID translation for NewGRFs.
uint8 cleanup_flag
flags indicating which data should be freed upon cleaning up
Slope slopes_refused
slope pattern on which this tile cannot be built
const uint8 * random_sounds
array of random sounds.
can only be built after 1960 (oil rigs)
bool IsRawIndustry() const
Is an industry with the spec a raw industry?
Like power plants and banks.
either by user or random creation process
bool IsProcessingIndustry() const
Is an industry with the spec a processing industry?
Data related to the handling of grf files.
void ResetIndustries()
This function initialize the spec arrays of both industry and industry tiles.
bool UsesSmoothEconomy() const
Determines whether this industrytype uses smooth economy or whether it uses standard/newgrf productio...
StringID new_industry_text
Message appearing when the industry is built.
End marker of the industry check procedures.
byte anim_production
Animation frame to start when goods are produced.
Industry should be build above snow-line in arctic climate.
static const IndustryGfx NUM_INDUSTRYTILES
total number of industry tiles, new and old
Industry should be in the desert.
Defines the data structure for constructing industry.
bool enabled
entity still available (by default true).newgrf can disable it, though
GRFFileProps grf_prop
properties related to the grf file
Industry should be positioned near edge of the map.
Money GetConstructionCost() const
Get the cost for constructing this industry.
IndustryBehaviour behaviour
How this industry will behave, and how others entities can use it.
GRFFileProps grf_prop
properties related to the grf file
byte appear_ingame[NUM_LANDSCAPE]
Probability of appearance in game.
cuts trees and produce first output cargo from them (lumber mill)
uint32 StringID
Numeric value that represents a string, independent of the selected language.
IndustryType _sorted_industry_types[NUM_INDUSTRYTYPES]
Industry types sorted by name.
Industry should NOT be in the desert.
Industry should be in the rain forest.
uint16 input_cargo_multiplier[3][2]
Input cargo multipliers (multiply amount of incoming cargo for the produced cargoes) ...
uint8 callback_mask
Bitmask of industry tile callbacks that have to be called.
uint16 override
id of the entity been replaced by
A pair-construct of a TileIndexDiff.
byte num_table
Number of elements in the table.
IndustryTileSpecialFlags
Flags for miscellaneous industry tile specialities.
is built on water (oil rig)
byte minimal_cargo
minimum amount of cargo transported to the stations.
uint8 cost_multiplier
Base construction cost multiplier.
byte appear_creation[NUM_LANDSCAPE]
Probability of appearance during map creation.
Types related to the landscape.
AnimationInfo animation
Information about the animation (is it looping, how many loops etc)
static const IndustryType NUM_INDUSTRYTYPES
total number of industry types, new and old; limited to 240 because we need some special ids like INV...
StringID closure_text
Message appearing when the industry closes.
byte anim_next
Next frame in an animation.
CheckProc
Available procedures to check whether an industry may build at a given location.
Slope
Enumeration for the slope-type.
void SortIndustryTypes()
Initialize the list of sorted industry types.
byte climate_availability
Bitmask, giving landscape enums as bit position.
IndustryBehaviour
Various industry behaviours mostly to represent original TTD specialities.
Callback 0x26 needs random bits.
IndustryType conflicting[3]
Industries this industry cannot be close to.
Fields are planted around when built (all farms)
Allow closing down the last instance of this type.
This file simplyfies and embeds a common mechanism of loading/saving and mapping of grf entities...
CargoID accepts_cargo[3]
3 accepted cargoes.
Information about animation.
uint8 number_of_sounds
Number of sounds available in the sounds array.
StringID station_name
Default name for nearby station.
StringID production_up_text
Message appearing when the industry's production is increasing.
byte check_proc
Index to a procedure to check for conflicting circumstances.
byte CargoID
Cargo slots to indicate a cargo type within a game.
Free the dynamically allocated tile layout structure.
Defines the data structure of each individual tile of an industry.
can only be built in towns larger than 1200 inhabitants (temperate bank)
Industry should be in low land.
Production callback needs random bits in var 10.
can only be built before 1950 (oil wells)
bool anim_state
When true, the tile has to be drawn using the animation state instead of the construction state...