TileConstants: two new helper methods: isDozeable, isZoneCenter

git-svn-id: https://micropolis.googlecode.com/svn/trunk/micropolis-java@616 d9718cc8-9f43-0410-858b-315f434eb58c
This commit is contained in:
jason@long.name 2013-05-05 18:52:21 +00:00
parent e9f06bb1c2
commit db0a450076

View file

@ -344,6 +344,11 @@ public class TileConstants
return (tile & LOMASK) > 4 && (tile & LOMASK) < 21;
}
public static boolean isDozeable(int tile)
{
return (tile & BULLBIT) != 0;
}
static boolean isFloodable(int tile)
{
return (tile == DIRT || ((tile & BULLBIT) != 0 && (tile & BURNBIT) != 0));
@ -360,4 +365,9 @@ public class TileConstants
int tmp = tile & LOMASK;
return (tmp >= RAILBASE && tmp < RESBASE);
}
public static boolean isZoneCenter(int tile)
{
return (tile & ZONEBIT) != 0;
}
}