diff options
author | feildmaster <admin@feildmaster.com> | 2013-01-29 17:25:39 -0600 |
---|---|---|
committer | feildmaster <admin@feildmaster.com> | 2013-01-29 17:25:39 -0600 |
commit | b4b7cacf5eae52d9bd5aefd09ac60a20a316d2e7 (patch) | |
tree | 5df8e9bb9e3f2770ae4e7afff06772c236445188 /src | |
parent | 37975946a274889c647294283afa6c1366481264 (diff) | |
download | craftbukkit-b4b7cacf5eae52d9bd5aefd09ac60a20a316d2e7.tar craftbukkit-b4b7cacf5eae52d9bd5aefd09ac60a20a316d2e7.tar.gz craftbukkit-b4b7cacf5eae52d9bd5aefd09ac60a20a316d2e7.tar.lz craftbukkit-b4b7cacf5eae52d9bd5aefd09ac60a20a316d2e7.tar.xz craftbukkit-b4b7cacf5eae52d9bd5aefd09ac60a20a316d2e7.zip |
Fix NPE when getting bed spawn location.
Diffstat (limited to 'src')
-rw-r--r-- | src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java index 6adc3cd0..b6c7b1ce 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java @@ -610,7 +610,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player { World world = getServer().getWorld(getHandle().spawnWorld); ChunkCoordinates bed = getHandle().getBed(); - if (world != null) { + if (world != null && bed != null) { bed = EntityHuman.getBed(((CraftWorld) world).getHandle(), bed, getHandle().isRespawnForced()); if (bed != null) { return new Location(world, bed.x, bed.y, bed.z); |