13
0
geforkt von Mirrors/Paper

Fix fireballs freezing when the chunk unloads. Addresses BUKKIT-1228

Dieser Commit ist enthalten in:
feildmaster 2012-06-09 03:59:49 -05:00
Ursprung 3df6608a72
Commit d5ba6c6644

Datei anzeigen

@ -216,6 +216,8 @@ public class EntityFireball extends Entity {
nbttagcompound.setShort("zTile", (short) this.g);
nbttagcompound.setByte("inTile", (byte) this.h);
nbttagcompound.setByte("inGround", (byte) (this.i ? 1 : 0));
// CraftBukkit
nbttagcompound.set("Direction", this.a(new double[] { this.dirX, this.dirY, this.dirZ}));
}
public void a(NBTTagCompound nbttagcompound) {
@ -224,6 +226,14 @@ public class EntityFireball extends Entity {
this.g = nbttagcompound.getShort("zTile");
this.h = nbttagcompound.getByte("inTile") & 255;
this.i = nbttagcompound.getByte("inGround") == 1;
// CraftBukkit start
if (nbttagcompound.hasKey("Direction")) {
NBTTagList nbttaglist1 = nbttagcompound.getList("Direction");
this.dirX = ((NBTTagDouble) nbttaglist1.get(0)).data;
this.dirY = ((NBTTagDouble) nbttaglist1.get(1)).data;
this.dirZ = ((NBTTagDouble) nbttaglist1.get(2)).data;
}
// CraftBukkit end
}
public boolean o_() {