(svn r16894) -Codechange: Add [Specialised]Vehicle::Last().

This commit is contained in:
frosch
2009-07-20 19:58:33 +00:00
parent a591dc6c8c
commit fec6129cd1
7 changed files with 42 additions and 24 deletions

View File

@@ -151,7 +151,7 @@ static void TrainDepotMoveVehicle(const Vehicle *wagon, VehicleID sel, const Veh
if (v == wagon) return;
if (wagon == NULL) {
if (head != NULL) wagon = GetLastVehicleInChain(head);
if (head != NULL) wagon = head->Last();
} else {
wagon = wagon->Previous();
if (wagon == NULL) return;