cleanup: rename isRoadAny() to isRoad()... ditto for isRailAny()
This commit is contained in:
parent
1da5fdf402
commit
d4a80ec466
4 changed files with 6 additions and 6 deletions
|
@ -615,7 +615,7 @@ class MapScanner extends TileBehavior
|
||||||
// look for road
|
// look for road
|
||||||
if (city.testBounds(xx, yy)) {
|
if (city.testBounds(xx, yy)) {
|
||||||
int tmp = city.getTile(xx, yy);
|
int tmp = city.getTile(xx, yy);
|
||||||
if (isRoadAny(tmp) || isRailAny(tmp))
|
if (isRoad(tmp) || isRail(tmp))
|
||||||
{
|
{
|
||||||
score++;
|
score++;
|
||||||
}
|
}
|
||||||
|
|
|
@ -180,7 +180,7 @@ public abstract class Sprite
|
||||||
|
|
||||||
int t = city.getTile(xpos, ypos);
|
int t = city.getTile(xpos, ypos);
|
||||||
if (isOverWater(t)) {
|
if (isOverWater(t)) {
|
||||||
if (isRoadAny(t)) {
|
if (isRoad(t)) {
|
||||||
// becomes water
|
// becomes water
|
||||||
city.setTile(xpos, ypos, RIVER);
|
city.setTile(xpos, ypos, RIVER);
|
||||||
}
|
}
|
||||||
|
|
|
@ -384,7 +384,7 @@ public class TileConstants
|
||||||
return (tile == DIRT || (isDozeable(tile) && isCombustible(tile)));
|
return (tile == DIRT || (isDozeable(tile) && isCombustible(tile)));
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean isRoadAny(int tile)
|
public static boolean isRoad(int tile)
|
||||||
{
|
{
|
||||||
assert (tile & LOMASK) == tile;
|
assert (tile & LOMASK) == tile;
|
||||||
|
|
||||||
|
@ -447,7 +447,7 @@ public class TileConstants
|
||||||
(tile != VBRIDGE));
|
(tile != VBRIDGE));
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean isRailAny(int tile)
|
public static boolean isRail(int tile)
|
||||||
{
|
{
|
||||||
assert (tile & LOMASK) == tile;
|
assert (tile & LOMASK) == tile;
|
||||||
|
|
||||||
|
|
|
@ -345,8 +345,8 @@ public class OverlayMapView extends JComponent
|
||||||
case TRANSPORT:
|
case TRANSPORT:
|
||||||
case TRAFFIC_OVERLAY:
|
case TRAFFIC_OVERLAY:
|
||||||
if (isConstructed(tile)
|
if (isConstructed(tile)
|
||||||
&& !isRoadAny(tile)
|
&& !isRoad(tile)
|
||||||
&& !isRailAny(tile))
|
&& !isRail(tile))
|
||||||
{
|
{
|
||||||
tile = DIRT;
|
tile = DIRT;
|
||||||
}
|
}
|
||||||
|
|
Reference in a new issue