Fix a npe
This commit is contained in:
parent
af6e6a1aa9
commit
6ae7d703b0
@ -159,7 +159,8 @@ public enum DisguiseSound {
|
|||||||
public SoundType getType(String name, boolean ignoreDamage) {
|
public SoundType getType(String name, boolean ignoreDamage) {
|
||||||
if (isCancelSound(name))
|
if (isCancelSound(name))
|
||||||
return SoundType.CANCEL;
|
return SoundType.CANCEL;
|
||||||
if (disguiseSounds.get(SoundType.STEP).startsWith("step.") && name.startsWith("step."))
|
if (disguiseSounds.containsKey(SoundType.STEP) && disguiseSounds.get(SoundType.STEP).startsWith("step.")
|
||||||
|
&& name.startsWith("step."))
|
||||||
return SoundType.STEP;
|
return SoundType.STEP;
|
||||||
for (SoundType type : SoundType.values()) {
|
for (SoundType type : SoundType.values()) {
|
||||||
if (!disguiseSounds.containsKey(type) || type == SoundType.DEATH || (ignoreDamage && type == SoundType.HURT))
|
if (!disguiseSounds.containsKey(type) || type == SoundType.DEATH || (ignoreDamage && type == SoundType.HURT))
|
||||||
|
Loading…
Reference in New Issue
Block a user