From 8a7c582d546eac7554f96a884091266bad236830 Mon Sep 17 00:00:00 2001 From: Wesley Wolfe Date: Fri, 2 Aug 2013 20:05:22 -0500 Subject: [PATCH] Ignore null sound by contract. Fixes BUKKIT-4641 --- src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java index 02c7b8a892..d5d43c9a60 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java @@ -259,6 +259,9 @@ public class CraftPlayer extends CraftHumanEntity implements Player { } public void playSound(Location loc, Sound sound, float volume, float pitch) { + if (sound == null) { + return; + } playSound(loc, CraftSound.getSound(sound), volume, pitch); }