(svn r3047) The parameters for the railtype check got flipped in the train build window (this caused no visible problem so far, therefore no Fix tag)
authortron
Sat, 15 Oct 2005 16:43:18 +0000
changeset 2518 bec1f669b1ff
parent 2517 6e3832ddd0f6
child 2519 beb11a5ac48c
(svn r3047) The parameters for the railtype check got flipped in the train build window (this caused no visible problem so far, therefore no Fix tag)
train_gui.c
--- a/train_gui.c	Sat Oct 15 11:06:54 2005 +0000
+++ b/train_gui.c	Sat Oct 15 16:43:18 2005 +0000
@@ -181,7 +181,7 @@
 		const Engine *e = GetEngine(i);
 		const RailVehicleInfo *rvi = RailVehInfo(i);
 
-		if (!IsCompatibleRail(railtype, e->railtype) || !(rvi->flags & RVI_WAGON) != is_engine ||
+		if (!IsCompatibleRail(e->railtype, railtype) || !(rvi->flags & RVI_WAGON) != is_engine ||
 				!HASBIT(e->player_avail, _local_player))
 			continue;
 
@@ -213,7 +213,7 @@
 
 			for (i = 0; i < NUM_TRAIN_ENGINES; i++) {
 				const Engine *e = GetEngine(i);
-				if (IsCompatibleRail(railtype, e->railtype)
+				if (IsCompatibleRail(e->railtype, railtype)
 				    && HASBIT(e->player_avail, _local_player))
 					count++;
 			}