2008-03-31 02:06:17 +02: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 08:42:26 +02:00
|
|
|
#include "rail_type.h"
|
2008-03-31 02:06:17 +02:00
|
|
|
#include "road_type.h"
|
|
|
|
#include "tile_type.h"
|
|
|
|
#include "cargo_type.h"
|
|
|
|
#include "vehicle_type.h"
|
2009-01-13 19:18:53 +01:00
|
|
|
#include "core/smallvec_type.hpp"
|
2008-03-31 02:06:17 +02:00
|
|
|
|
2008-09-30 22:39:50 +02:00
|
|
|
void ModifyStationRatingAround(TileIndex tile, Owner owner, int amount, uint radius);
|
2008-03-31 02:06:17 +02:00
|
|
|
|
2009-01-13 19:18:53 +01:00
|
|
|
typedef SmallVector<Station*, 1> StationList;
|
2009-01-13 21:43:53 +01:00
|
|
|
void FindStationsAroundTiles(TileIndex tile, int w_prod, int h_prod, StationList *stations);
|
2008-03-31 02:06:17 +02:00
|
|
|
|
|
|
|
void ShowStationViewWindow(StationID station);
|
|
|
|
void UpdateAllStationVirtCoord();
|
|
|
|
|
2009-06-27 20:26:50 +02: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 02:06:17 +02: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 22:39:50 +02:00
|
|
|
bool HasStationInUse(StationID station, CompanyID company);
|
2008-03-31 02:06:17 +02:00
|
|
|
|
2009-06-23 23:44:48 +02:00
|
|
|
RoadStop *GetRoadStopByTile(TileIndex tile, RoadStopType type);
|
2009-01-10 01:31:47 +01:00
|
|
|
uint GetNumRoadStops(const Station *st, RoadStopType type);
|
2008-03-31 02:06:17 +02:00
|
|
|
|
2009-05-22 22:18:45 +02:00
|
|
|
void ClearSlot(struct RoadVehicle *v);
|
2008-03-31 02:06:17 +02:00
|
|
|
|
|
|
|
void DeleteOilRig(TileIndex t);
|
|
|
|
|
2008-03-31 08:42:26 +02: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 04:54:47 +02:00
|
|
|
void UpdateAirportsNoise();
|
2008-03-31 08:42:26 +02:00
|
|
|
|
2008-03-31 02:06:17 +02:00
|
|
|
#endif /* STATION_FUNC_H */
|