src/road_cmd.cpp
changeset 8166 074d00278f8c
parent 8137 67a9579abd74
child 8171 9e36b23ecbff
equal deleted inserted replaced
8165:606d97bce909 8166:074d00278f8c
   651 	}
   651 	}
   652 
   652 
   653 	/* On the X-axis, we have to swap the initial bits, so they
   653 	/* On the X-axis, we have to swap the initial bits, so they
   654 	 * will be interpreted correctly in the GTTS. Futhermore
   654 	 * will be interpreted correctly in the GTTS. Futhermore
   655 	 * when you just 'click' on one tile to build them. */
   655 	 * when you just 'click' on one tile to build them. */
   656 	if (HASBIT(p2, 2) == (start_tile == end_tile)) drd ^= DRD_BOTH;
   656 	if (HASBIT(p2, 2) == (start_tile == end_tile && HASBIT(p2, 0) == HASBIT(p2, 1))) drd ^= DRD_BOTH;
   657 	/* No disallowed direction bits have to be toggled */
   657 	/* No disallowed direction bits have to be toggled */
   658 	if (!HASBIT(p2, 5)) drd = DRD_NONE;
   658 	if (!HASBIT(p2, 5)) drd = DRD_NONE;
   659 
   659 
   660 	tile = start_tile;
   660 	tile = start_tile;
   661 	/* Start tile is the small number. */
   661 	/* Start tile is the small number. */