newgrf_industrytiles.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00012 #ifndef NEWGRF_INDUSTRYTILES_H
00013 #define NEWGRF_INDUSTRYTILES_H
00014
00015 enum IndustryAnimationTrigger {
00016 IAT_CONSTRUCTION_STATE_CHANGE,
00017 IAT_TILELOOP,
00018 IAT_INDUSTRY_TICK,
00019 IAT_INDUSTRY_RECEIVED_CARGO,
00020 IAT_INDUSTRY_DISTRIBUTES_CARGO,
00021 };
00022
00023 bool DrawNewIndustryTile(TileInfo *ti, Industry *i, IndustryGfx gfx, const IndustryTileSpec *inds);
00024 uint16 GetIndustryTileCallback(CallbackID callback, uint32 param1, uint32 param2, IndustryGfx gfx_id, Industry *industry, TileIndex tile);
00025 bool PerformIndustryTileSlopeCheck(TileIndex ind_base_tile, TileIndex ind_tile, const IndustryTileSpec *its, IndustryType type, IndustryGfx gfx, uint itspec_index);
00026
00027 void AnimateNewIndustryTile(TileIndex tile);
00028 bool StartStopIndustryTileAnimation(TileIndex tile, IndustryAnimationTrigger iat, uint32 random = Random());
00029 bool StartStopIndustryTileAnimation(const Industry *ind, IndustryAnimationTrigger iat);
00030
00031
00032 enum IndustryTileTrigger {
00033
00034 INDTILE_TRIGGER_TILE_LOOP = 0x01,
00035
00036 INDUSTRY_TRIGGER_INDUSTRY_TICK = 0x02,
00037
00038 INDUSTRY_TRIGGER_RECEIVED_CARGO = 0x04,
00039 };
00040 void TriggerIndustryTile(TileIndex t, IndustryTileTrigger trigger);
00041 void TriggerIndustry(Industry *ind, IndustryTileTrigger trigger);
00042
00043 #endif