|
OpenTTD Source
14.0-beta3
|
Go to the documentation of this file.
49 void FillDefaultCapacities(
const Engine *e);
64 void ShowVehicleListWindow(
const Vehicle *v);
100 default: NOT_REACHED();
111 bool VehicleClicked(VehicleList::const_iterator begin, VehicleList::const_iterator end);
116 void StopGlobalFollowVehicle(
const Vehicle *v);
@ VEH_AIRCRAFT
Aircraft vehicle type.
void StartStopVehicle(const Vehicle *v, bool texteffect)
Executes CMD_START_STOP_VEHICLE for given vehicle.
byte VehicleOrderID
The index of an order within its current vehicle (not pool related)
@ WC_ROADVEH_LIST
Road vehicle list; Window numbers:
void DrawTrainImage(const Train *v, const Rect &r, VehicleID selection, EngineImageType image_type, int skip, VehicleID drag_dest=INVALID_VEHICLE)
Draws an image of a whole train.
uint height
Vehicle cell height.
uint16_t mail_capacity
Mail capacity if available.
@ TDW_TAB_CAPACITY
Tab with cargo capacity of the vehicles.
CargoArray all_capacities
Capacities for all cargoes.
int GetVehicleWidth(const Vehicle *v, EngineImageType image_type)
Get the width of a vehicle (including all parts of the consist) in pixels.
uint32_t StringID
Numeric value that represents a string, independent of the selected language.
Class for storing amounts of cargo.
void DrawRoadVehImage(const Vehicle *v, const Rect &r, VehicleID selection, EngineImageType image_type, int skip=0)
Draws an image of a road vehicle chain.
uint extend_right
Extend of the cell to the right.
EngineImageType
Visualisation contexts of vehicles and engines.
@ TDW_TAB_INFO
Tab with name and value of the vehicles.
@ VEH_ROAD
Road vehicle type.
Owner
Enum for all companies/owners.
uint GetVehicleHeight(VehicleType type)
Get the height of a single vehicle in the GUIs.
void DrawAircraftImage(const Vehicle *v, const Rect &r, VehicleID selection, EngineImageType image_type)
Draws an image of an aircraft.
uint capacity
Cargo capacity.
Vehicle * CheckClickOnVehicle(const Viewport *vp, int x, int y)
Find the vehicle close to the clicked coordinates.
void DrawVehicleImage(const Vehicle *v, const Rect &r, VehicleID selection, EngineImageType image_type, int skip)
Draws an image of a vehicle chain.
VehicleCellSize GetVehicleImageCellSize(VehicleType type, EngineImageType image_type)
Get the GUI cell size for a vehicle image.
Data structure for viewport, display of a part of the world.
uint ShowRefitOptionsList(int left, int right, int y, EngineID engine)
Display list of cargo types of the engine, for the purchase information window.
static const VehicleID INVALID_VEHICLE
Constant representing a non-existing vehicle.
'Train' is either a loco or a wagon.
@ WC_SHIPS_LIST
Ships list; Window numbers:
Extra information about refitted cargo and capacity.
WindowClass
Window classes.
uint32_t VehicleID
The type all our vehicle IDs have.
byte CargoID
Cargo slots to indicate a cargo type within a game.
@ WC_TRAINS_LIST
Trains list; Window numbers:
StringID GetCargoSubtypeText(const Vehicle *v)
Get the cargo subtype text from NewGRF for the vehicle details window.
VehicleType
Available vehicle types.
void DrawShipImage(const Vehicle *v, const Rect &r, VehicleID selection, EngineImageType image_type)
Draws an image of a ship.
#define DECLARE_ENUM_AS_ADDABLE(EnumType)
Operator that allows this enumeration to be added to any other enumeration.
@ VIWD_CONSIST_CHANGED
Vehicle composition was changed.
int GetSingleVehicleWidth(const Vehicle *v, EngineImageType image_type)
Get the width of a vehicle (part) in pixels.
void SetMouseCursorVehicle(const Vehicle *v, EngineImageType image_type)
Set the mouse cursor to look like a vehicle.
@ VIWD_AUTOREPLACE
Autoreplace replaced the vehicle.
void ShowVehicleRefitWindow(const Vehicle *v, VehicleOrderID order, Window *parent, bool auto_refit=false)
Show the refit window for a vehicle.
TrainDetailsWindowTabs
The tabs in the train details window.
Dimensions of a cell in the purchase/depot windows.
int DrawVehiclePurchaseInfo(int left, int right, int y, EngineID engine_number, TestedEngineDetails &te)
Draw the purchase info details of a vehicle at a given location.
VehicleInvalidateWindowData
Special values for vehicle-related windows for the data parameter of InvalidateWindowData.
@ TDW_TAB_TOTALS
Tab with sum of total cargo transported.
uint16_t EngineID
Unique identification number of an engine.
Data structure for an opened window.
@ VEH_TRAIN
Train vehicle type.
@ VIWD_MODIFY_ORDERS
Other order modifications.
@ VEH_SHIP
Ship vehicle type.
Specification of a rectangle with absolute coordinates of all edges.
@ VIWD_REMOVE_ALL_ORDERS
Removed / replaced all orders (after deleting / sharing).
@ WC_AIRCRAFT_LIST
Aircraft list; Window numbers:
uint extend_left
Extend of the cell to the left.
void ShowVehicleViewWindow(const Vehicle *v)
Shows the vehicle view window of the given vehicle.
bool VehicleClicked(const Vehicle *v)
Dispatch a "vehicle selected" event if any window waits for it.
@ TDW_TAB_CARGO
Tab with cargo carried by the vehicles.
WindowClass GetWindowClassForVehicleType(VehicleType vt)
Get WindowClass for vehicle list of given vehicle type.