2008-03-31 01:06:17 +01:00
|
|
|
/* $Id$ */
|
|
|
|
|
|
|
|
/** @file station_func.h Functions related to stations. */
|
|
|
|
|
|
|
|
#ifndef STATION_FUNC_H
|
|
|
|
#define STATION_FUNC_H
|
|
|
|
|
|
|
|
#include "station_type.h"
|
|
|
|
#include "sprite.h"
|
2008-03-31 07:42:26 +01:00
|
|
|
#include "rail_type.h"
|
2008-03-31 01:06:17 +01:00
|
|
|
#include "road_type.h"
|
|
|
|
#include "tile_type.h"
|
|
|
|
#include "cargo_type.h"
|
|
|
|
#include "vehicle_type.h"
|
2009-01-13 18:18:53 +00:00
|
|
|
#include "core/smallvec_type.hpp"
|
2008-03-31 01:06:17 +01:00
|
|
|
|
2008-09-30 21:39:50 +01:00
|
|
|
void ModifyStationRatingAround(TileIndex tile, Owner owner, int amount, uint radius);
|
2008-03-31 01:06:17 +01:00
|
|
|
|
2009-01-13 18:18:53 +00:00
|
|
|
typedef SmallVector<Station*, 1> StationList;
|
2009-01-13 20:43:53 +00:00
|
|
|
void FindStationsAroundTiles(TileIndex tile, int w_prod, int h_prod, StationList *stations);
|
2008-03-31 01:06:17 +01:00
|
|
|
|
|
|
|
void ShowStationViewWindow(StationID station);
|
|
|
|
void UpdateAllStationVirtCoord();
|
|
|
|
|
2009-06-27 19:26:50 +01:00
|
|
|
void GetProductionAroundTiles(CargoArray produced, TileIndex tile, int w, int h, int rad);
|
|
|
|
void GetAcceptanceAroundTiles(CargoArray acceptance, TileIndex tile, int w, int h, int rad);
|
2008-03-31 01:06:17 +01:00
|
|
|
|
|
|
|
const DrawTileSprites *GetStationTileLayout(StationType st, byte gfx);
|
|
|
|
void StationPickerDrawSprite(int x, int y, StationType st, RailType railtype, RoadType roadtype, int image);
|
|
|
|
|
2008-09-30 21:39:50 +01:00
|
|
|
bool HasStationInUse(StationID station, CompanyID company);
|
2008-03-31 01:06:17 +01:00
|
|
|
|
2009-06-23 22:44:48 +01:00
|
|
|
RoadStop *GetRoadStopByTile(TileIndex tile, RoadStopType type);
|
2009-01-10 00:31:47 +00:00
|
|
|
uint GetNumRoadStops(const Station *st, RoadStopType type);
|
2008-03-31 01:06:17 +01:00
|
|
|
|
2009-05-22 21:18:45 +01:00
|
|
|
void ClearSlot(struct RoadVehicle *v);
|
2008-03-31 01:06:17 +01:00
|
|
|
|
|
|
|
void DeleteOilRig(TileIndex t);
|
|
|
|
|
2008-03-31 07:42:26 +01:00
|
|
|
/* Check if a rail station tile is traversable. */
|
|
|
|
bool IsStationTileBlocked(TileIndex tile);
|
|
|
|
|
|
|
|
/* Check if a rail station tile is electrifiable. */
|
|
|
|
bool IsStationTileElectrifiable(TileIndex tile);
|
|
|
|
|
2008-05-24 03:54:47 +01:00
|
|
|
void UpdateAirportsNoise();
|
2008-03-31 07:42:26 +01:00
|
|
|
|
2008-03-31 01:06:17 +01:00
|
|
|
#endif /* STATION_FUNC_H */
|