MCPcopy Create free account
hub / github.com/OpenTTD/OpenTTD / UnselectVehicle

Method UnselectVehicle

src/group_gui.cpp:1152–1155  ·  view source on GitHub ↗

* Tests whether a given vehicle is selected in the window, and unselects it if necessary. * Called when the vehicle is deleted. * @param vehicle Vehicle that is going to be deleted */

Source from the content-addressed store, hash-verified

1150 * @param vehicle Vehicle that is going to be deleted
1151 */
1152 void UnselectVehicle(VehicleID vehicle)
1153 {
1154 if (this->vehicle_sel == vehicle) ResetObjectToPlace();
1155 }
1156
1157 /**
1158 * Selects the specified group in the list

Callers 1

Calls 1

ResetObjectToPlaceFunction · 0.85

Tested by

no test coverage detected