OpenTTD Source: VehiclesNearTileXY Class Reference

OpenTTD Source 15.3

Data Structures | Public Member Functions | Private Attributes
VehiclesNearTileXY Class Reference

Iterate over all vehicles near a given world coordinate. More...

`#include <vehicle_func.h>`

## Data Structures
class | Iterator
| Forward iterator. More...

## Public Member Functions
| VehiclesNearTileXY (int32_t x, int32_t y, uint max_dist)
Iterator | begin () const
std::default_sentinel_t | end () const

## Private Attributes
Iterator | start

## Detailed Description

Iterate over all vehicles near a given world coordinate.

Warning
  This only works for vehicles with proper Vehicle::Tile, so only ground vehicles outside wormholes.
  The order is non-deterministic. You have to make sure, that your processing is not order dependant.

Definition at line 119 of file vehicle_func.h.

## Constructor & Destructor Documentation

## ◆ VehiclesNearTileXY()

VehiclesNearTileXY::VehiclesNearTileXY | ( | int32_t | x,
|  | int32_t | y,
|  | uint | max_dist
| ) |  |
| inlineexplicit

Definition at line 163 of file vehicle_func.h.

## Member Function Documentation

## ◆ begin()

Iterator VehiclesNearTileXY::begin | ( |  | ) | const
| inline

Definition at line 164 of file vehicle_func.h.

## ◆ end()

std::default_sentinel_t VehiclesNearTileXY::end | ( |  | ) | const
| inline

Definition at line 165 of file vehicle_func.h.

## Field Documentation

## ◆ start

Iterator VehiclesNearTileXY::start
| private

Definition at line 167 of file vehicle_func.h.

The documentation for this class was generated from the following file:

- src/vehicle_func.h