Update CraftBukkit to Minecraft 1.3.1
This commit is contained in:
committed by
Travis Watkins
parent
08e2923bd4
commit
a43d621c01
@@ -13,17 +13,18 @@ public class BlockGrass extends Block {
|
||||
protected BlockGrass(int i) {
|
||||
super(i, Material.GRASS);
|
||||
this.textureId = 3;
|
||||
this.a(true);
|
||||
this.b(true);
|
||||
this.a(CreativeModeTab.b);
|
||||
}
|
||||
|
||||
public int a(int i, int j) {
|
||||
return i == 1 ? 0 : (i == 0 ? 2 : 3);
|
||||
}
|
||||
|
||||
public void a(World world, int i, int j, int k, Random random) {
|
||||
public void b(World world, int i, int j, int k, Random random) {
|
||||
if (!world.isStatic) {
|
||||
if (world.getLightLevel(i, j + 1, k) < 4 && Block.lightBlock[world.getTypeId(i, j + 1, k)] > 2) {
|
||||
// CraftBukkit start - reuse getLightLevel
|
||||
// CraftBukkit start
|
||||
org.bukkit.World bworld = world.getWorld();
|
||||
BlockState blockState = bworld.getBlockAt(i, j, k).getState();
|
||||
blockState.setTypeId(Block.DIRT.id);
|
||||
@@ -46,7 +47,7 @@ public class BlockGrass extends Block {
|
||||
// CraftBukkit start
|
||||
org.bukkit.World bworld = world.getWorld();
|
||||
BlockState blockState = bworld.getBlockAt(i1, j1, k1).getState();
|
||||
blockState.setTypeId(this.id);
|
||||
blockState.setTypeId(Block.GRASS.id);
|
||||
|
||||
BlockSpreadEvent event = new BlockSpreadEvent(blockState.getBlock(), bworld.getBlockAt(i, j, k), blockState);
|
||||
world.getServer().getPluginManager().callEvent(event);
|
||||
|
||||
Reference in New Issue
Block a user