(svn r3199) -Fix: There are only 2 possible directions for ship depots, not 4
authortron
Wed, 16 Nov 2005 12:20:15 +0000
changeset 2657 d72100c6a799
parent 2656 796b75ba15e3
child 2658 4ecf9bbf3258
(svn r3199) -Fix: There are only 2 possible directions for ship depots, not 4
water_cmd.c
--- a/water_cmd.c	Wed Nov 16 12:10:45 2005 +0000
+++ b/water_cmd.c	Wed Nov 16 12:20:15 2005 +0000
@@ -47,7 +47,7 @@
 
 /** Build a ship depot.
  * @param x,y tile coordinates where ship depot is built
- * @param p1 depot direction (0 through 3), where 0 is NW, 1 is NE, etc.
+ * @param p1 depot direction (0 == X or 1 == Y)
  * @param p2 unused
  */
 int32 CmdBuildShipDepot(int x, int y, uint32 flags, uint32 p1, uint32 p2)
@@ -59,7 +59,7 @@
 
 	SET_EXPENSES_TYPE(EXPENSES_CONSTRUCTION);
 
-	if (p1 > 3) return CMD_ERROR;
+	if (p1 > 1) return CMD_ERROR;
 
 	tile = TileVirtXY(x, y);
 	if (!EnsureNoVehicle(tile)) return CMD_ERROR;