Small refactoring for previous commit.
This commit is contained in:
parent
895cf3b173
commit
e2efcc4170
@ -273,12 +273,11 @@ public class GeoEngine
|
||||
final int y = geoY / GeoStructure.BLOCK_CELLS_Y;
|
||||
|
||||
// if x or y is out of array return null
|
||||
if ((x >= GeoStructure.GEO_BLOCKS_X) || (y >= GeoStructure.GEO_BLOCKS_Y))
|
||||
if ((x < GeoStructure.GEO_BLOCKS_X) && (y < GeoStructure.GEO_BLOCKS_Y))
|
||||
{
|
||||
return null;
|
||||
return _blocks[x][y];
|
||||
}
|
||||
|
||||
return _blocks[x][y];
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -273,12 +273,11 @@ public class GeoEngine
|
||||
final int y = geoY / GeoStructure.BLOCK_CELLS_Y;
|
||||
|
||||
// if x or y is out of array return null
|
||||
if ((x >= GeoStructure.GEO_BLOCKS_X) || (y >= GeoStructure.GEO_BLOCKS_Y))
|
||||
if ((x < GeoStructure.GEO_BLOCKS_X) && (y < GeoStructure.GEO_BLOCKS_Y))
|
||||
{
|
||||
return null;
|
||||
return _blocks[x][y];
|
||||
}
|
||||
|
||||
return _blocks[x][y];
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -273,12 +273,11 @@ public class GeoEngine
|
||||
final int y = geoY / GeoStructure.BLOCK_CELLS_Y;
|
||||
|
||||
// if x or y is out of array return null
|
||||
if ((x >= GeoStructure.GEO_BLOCKS_X) || (y >= GeoStructure.GEO_BLOCKS_Y))
|
||||
if ((x < GeoStructure.GEO_BLOCKS_X) && (y < GeoStructure.GEO_BLOCKS_Y))
|
||||
{
|
||||
return null;
|
||||
return _blocks[x][y];
|
||||
}
|
||||
|
||||
return _blocks[x][y];
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -271,12 +271,11 @@ public class GeoEngine
|
||||
final int y = geoY / GeoStructure.BLOCK_CELLS_Y;
|
||||
|
||||
// if x or y is out of array return null
|
||||
if ((x >= GeoStructure.GEO_BLOCKS_X) || (y >= GeoStructure.GEO_BLOCKS_Y))
|
||||
if ((x < GeoStructure.GEO_BLOCKS_X) && (y < GeoStructure.GEO_BLOCKS_Y))
|
||||
{
|
||||
return null;
|
||||
return _blocks[x][y];
|
||||
}
|
||||
|
||||
return _blocks[x][y];
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -273,12 +273,11 @@ public class GeoEngine
|
||||
final int y = geoY / GeoStructure.BLOCK_CELLS_Y;
|
||||
|
||||
// if x or y is out of array return null
|
||||
if ((x >= GeoStructure.GEO_BLOCKS_X) || (y >= GeoStructure.GEO_BLOCKS_Y))
|
||||
if ((x < GeoStructure.GEO_BLOCKS_X) && (y < GeoStructure.GEO_BLOCKS_Y))
|
||||
{
|
||||
return null;
|
||||
return _blocks[x][y];
|
||||
}
|
||||
|
||||
return _blocks[x][y];
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user