Minecraft 1.9.4

By: md_5 <git@md-5.net>
This commit is contained in:
CraftBukkit/Spigot
2016-05-10 21:47:39 +10:00
parent c9a6e9175c
commit d506c12c07
236 changed files with 1471 additions and 1822 deletions

View File

@@ -1,8 +1,8 @@
--- a/net/minecraft/server/BlockFire.java
+++ b/net/minecraft/server/BlockFire.java
@@ -4,6 +4,12 @@
import java.util.Map;
@@ -5,6 +5,12 @@
import java.util.Random;
import javax.annotation.Nullable;
+// CraftBukkit start
+import org.bukkit.craftbukkit.event.CraftEventFactory;
@@ -13,7 +13,7 @@
public class BlockFire extends Block {
public static final BlockStateInteger AGE = BlockStateInteger.of("age", 0, 15);
@@ -93,7 +99,7 @@
@@ -95,7 +101,7 @@
public void b(World world, BlockPosition blockposition, IBlockData iblockdata, Random random) {
if (world.getGameRules().getBoolean("doFireTick")) {
if (!this.canPlace(world, blockposition)) {
@@ -22,7 +22,7 @@
}
Block block = world.getType(blockposition.down()).getBlock();
@@ -106,7 +112,7 @@
@@ -108,7 +114,7 @@
int i = ((Integer) iblockdata.get(BlockFire.AGE)).intValue();
if (!flag && world.W() && this.b(world, blockposition) && random.nextFloat() < 0.2F + (float) i * 0.03F) {
@@ -31,7 +31,7 @@
} else {
if (i < 15) {
iblockdata = iblockdata.set(BlockFire.AGE, Integer.valueOf(i + random.nextInt(3) / 2));
@@ -117,14 +123,14 @@
@@ -119,14 +125,14 @@
if (!flag) {
if (!this.c(world, blockposition)) {
if (!world.getType(blockposition.down()).q() || i > 3) {
@@ -48,7 +48,7 @@
return;
}
}
@@ -170,7 +176,26 @@
@@ -172,7 +178,26 @@
l1 = 15;
}
@@ -76,7 +76,7 @@
}
}
}
@@ -208,6 +233,17 @@
@@ -210,6 +235,17 @@
if (random.nextInt(i) < k) {
IBlockData iblockdata = world.getType(blockposition);
@@ -94,7 +94,7 @@
if (random.nextInt(j + 10) < 5 && !world.isRainingAt(blockposition)) {
int l = j + random.nextInt(5) / 4;
@@ -217,7 +253,7 @@
@@ -219,7 +255,7 @@
world.setTypeAndData(blockposition, this.getBlockData().set(BlockFire.AGE, Integer.valueOf(l)), 3);
} else {
@@ -103,16 +103,16 @@
}
if (iblockdata.getBlock() == Blocks.TNT) {
@@ -274,7 +310,7 @@
@@ -276,7 +312,7 @@
public void doPhysics(World world, BlockPosition blockposition, IBlockData iblockdata, Block block) {
public void a(IBlockData iblockdata, World world, BlockPosition blockposition, Block block) {
if (!world.getType(blockposition.down()).q() && !this.c(world, blockposition)) {
- world.setAir(blockposition);
+ fireExtinguished(world, blockposition); // CraftBukkit - fuel block gone
}
}
@@ -282,7 +318,7 @@
@@ -284,7 +320,7 @@
public void onPlace(World world, BlockPosition blockposition, IBlockData iblockdata) {
if (world.worldProvider.getDimensionManager().getDimensionID() > 0 || !Blocks.PORTAL.b(world, blockposition)) {
if (!world.getType(blockposition.down()).q() && !this.c(world, blockposition)) {
@@ -121,7 +121,7 @@
} else {
world.a(blockposition, (Block) this, this.a(world) + world.random.nextInt(10));
}
@@ -304,4 +340,12 @@
@@ -306,4 +342,12 @@
protected BlockStateList getStateList() {
return new BlockStateList(this, new IBlockState[] { BlockFire.AGE, BlockFire.NORTH, BlockFire.EAST, BlockFire.SOUTH, BlockFire.WEST, BlockFire.UPPER});
}