Implemented a whole buncha Location overrides in CraftWorld
By: Dinnerbone <dinnerbone@dinnerbone.com>
This commit is contained in:
parent
a816dcad82
commit
a9f5460f0c
1 changed files with 16 additions and 0 deletions
|
@ -353,6 +353,22 @@ public class CraftWorld implements World {
|
||||||
return environment;
|
return environment;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public Block getBlockAt(Location location) {
|
||||||
|
return getBlockAt(location.getBlockX(), location.getBlockY(), location.getBlockZ());
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getBlockTypeIdAt(Location location) {
|
||||||
|
return getBlockTypeIdAt(location.getBlockX(), location.getBlockY(), location.getBlockZ());
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getHighestBlockYAt(Location location) {
|
||||||
|
return getHighestBlockYAt(location.getBlockX(), location.getBlockZ());
|
||||||
|
}
|
||||||
|
|
||||||
|
public Chunk getChunkAt(Location location) {
|
||||||
|
return getChunkAt(location.getBlockX() >> 4, location.getBlockZ() >> 4);
|
||||||
|
}
|
||||||
|
|
||||||
private final class ChunkCoordinate {
|
private final class ChunkCoordinate {
|
||||||
public final int x;
|
public final int x;
|
||||||
public final int z;
|
public final int z;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue