File diff r24687:4a2fa1e7f559 → r24688:9c99e0da7aad
src/industry.h
Show inline comments
 
@@ -30,12 +30,19 @@ enum ProductionLevels {
 
	PRODLEVEL_CLOSURE = 0x00,  ///< signal set to actually close the industry
 
	PRODLEVEL_MINIMUM = 0x04,  ///< below this level, the industry is set to be closing
 
	PRODLEVEL_DEFAULT = 0x10,  ///< default level set when the industry is created
 
	PRODLEVEL_MAXIMUM = 0x80,  ///< the industry is running at full speed
 
};
 

	
 
enum class IndustryAction : byte {
 
	SetControlFlags = 0,       ///< Set IndustryControlFlags
 
	SetExclusiveSupplier = 1,  ///< Set exclusive supplier
 
	SetExclusiveConsumer = 2,  ///< Set exclusive consumer
 
	SetText = 3,               ///< Set additional text
 
};
 

	
 
/**
 
 * Flags to control/override the behaviour of an industry.
 
 * These flags are controlled by game scripts.
 
 */
 
enum IndustryControlFlags : byte {
 
	/** No flags in effect */
 
@@ -88,12 +95,13 @@ struct Industry : IndustryPool::PoolItem
 
	Date construction_date;        ///< Date of the construction of the industry
 
	uint8 construction_type;       ///< Way the industry was constructed (@see IndustryConstructionType)
 
	Date last_cargo_accepted_at[INDUSTRY_NUM_INPUTS]; ///< Last day each cargo type was accepted by this industry
 
	byte selected_layout;          ///< Which tile layout was used when creating the industry
 
	Owner exclusive_supplier;      ///< Which company has exclusive rights to deliver cargo (INVALID_OWNER = anyone)
 
	Owner exclusive_consumer;      ///< Which company has exclusive rights to take cargo (INVALID_OWNER = anyone)
 
	std::string text;              ///< General text with additional information.
 

	
 
	uint16 random;                 ///< Random value used for randomisation of all kinds of things
 

	
 
	PersistentStorage *psa;        ///< Persistent storage for NewGRF industries.
 

	
 
	Industry(TileIndex tile = INVALID_TILE) : location(tile, 0, 0) {}