summaryrefslogtreecommitdiff
path: root/src/ai/api
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2010-08-19 20:42:00 +0000
committerrubidium <rubidium@openttd.org>2010-08-19 20:42:00 +0000
commit646fbb628aa1e19a19d02a3ad8abf24146fe5a12 (patch)
treeeb71d14916da6883714d2b0775fcd8a3e1ce3f74 /src/ai/api
parente89a0fb7f9059c995383d91a6aa16edac5ad841e (diff)
downloadopenttd-646fbb628aa1e19a19d02a3ad8abf24146fe5a12.tar.xz
(svn r20572) -Codechange: free/reserve some bits in the wagon move command to increase the vehicle pool limit
Diffstat (limited to 'src/ai/api')
-rw-r--r--src/ai/api/ai_vehicle.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/ai/api/ai_vehicle.cpp b/src/ai/api/ai_vehicle.cpp
index 73ad3e928..bacf10935 100644
--- a/src/ai/api/ai_vehicle.cpp
+++ b/src/ai/api/ai_vehicle.cpp
@@ -102,7 +102,7 @@
while (dest_wagon-- > 0) w = w->GetNextUnit();
}
- return AIObject::DoCommand(0, v->index | ((w == NULL ? ::INVALID_VEHICLE : w->index) << 16), move_attached_wagons ? 1 : 0, CMD_MOVE_RAIL_VEHICLE);
+ return AIObject::DoCommand(0, v->index | (move_attached_wagons ? 1 : 0) << 20, w == NULL ? ::INVALID_VEHICLE : w->index, CMD_MOVE_RAIL_VEHICLE);
}
/* static */ bool AIVehicle::MoveWagon(VehicleID source_vehicle_id, int source_wagon, int dest_vehicle_id, int dest_wagon)