From 9d54e51ef995d2f2d65b12f74ce31cbcbf8848a1 Mon Sep 17 00:00:00 2001 From: celestar Date: Thu, 2 Mar 2006 08:55:12 +0000 Subject: (svn r3730) Multistop modifications: -Codechange: Completely rewritten the slot assignment system. It now consumes less CPU cycles and memory -Codechange: Increased maximum number of roadstops to 16. -Fix: Several conditions where a slot becomes unliked from a vehicle -Codechange: ClearSlot now only takes one parameter, the vehicle -Feature: Console command 'clearslots' to clear ALL currently assinged slots. debug usage only -Feature: vehicles that cannot get a slot now wait on the road instead of planlessly blocking stops or circling around -Codechange: Adjusted debug levels TODO: Make the slot finder compatible with (a) pathfinder(s). --- station_cmd.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'station_cmd.c') diff --git a/station_cmd.c b/station_cmd.c index 1ae40771e..07d7c5cc4 100644 --- a/station_cmd.c +++ b/station_cmd.c @@ -118,7 +118,7 @@ RoadStop* GetRoadStopByTile(TileIndex tile, RoadStopType type) return rs; } -static uint GetNumRoadStops(const Station* st, RoadStopType type) +uint GetNumRoadStops(const Station* st, RoadStopType type) { uint num = 0; const RoadStop *rs; @@ -1431,7 +1431,7 @@ static int32 RemoveRoadStop(Station *st, uint32 flags, TileIndex tile) for (i = 0; i != NUM_SLOTS; i++) { if (cur_stop->slot[i] != INVALID_VEHICLE) { Vehicle *v = GetVehicle(cur_stop->slot[i]); - ClearSlot(v, v->u.road.slot); + ClearSlot(v); } } -- cgit v1.2.3-54-g00ecf