0x004B2AFA
| 4451 | |
| 4452 | // 0x004B2AFA |
| 4453 | static void pickupToolUpdateAir(const Vehicles::VehicleHead& head, const int16_t x, const int16_t y) |
| 4454 | { |
| 4455 | auto placementArgs = getVehicleAirPlacementArgsFromCursor(head, x, y); |
| 4456 | if (!placementArgs) |
| 4457 | { |
| 4458 | removeAirplaneGhost(head); |
| 4459 | return; |
| 4460 | } |
| 4461 | |
| 4462 | if (_ghostAirportStationId != StationId::null && _ghostAirportStationId == placementArgs->stationId && _ghostAirportNode == placementArgs->airportNode) |
| 4463 | { |
| 4464 | return; |
| 4465 | } |
| 4466 | |
| 4467 | removeAirplaneGhost(head); |
| 4468 | if (GameCommands::doCommand(*placementArgs, GameCommands::Flags::apply | GameCommands::Flags::ghost | GameCommands::Flags::noErrorWindow) != GameCommands::kFailure) |
| 4469 | { |
| 4470 | _ghostAirportNode = placementArgs->airportNode; |
| 4471 | _ghostAirportStationId = placementArgs->stationId; |
| 4472 | } |
| 4473 | } |
| 4474 | |
| 4475 | // 0x004A43E4 |
| 4476 | static uint16_t getRoadProgressAtCursor(const Point& cursorLoc, Ui::Viewport& viewport, const RoadElement& roadElement, const World::Pos3& loc) |
no test coverage detected