Prevent sound listener from being registered, should prevent sounds from borking anything else until we can get it fixed

This commit is contained in:
NavidK0 2016-03-14 05:26:22 -04:00
parent 207e4574fd
commit 61f091308c
2 changed files with 14 additions and 14 deletions

View File

@ -79,12 +79,11 @@ public enum DisguiseSound {
public static DisguiseSound getType(String name) { public static DisguiseSound getType(String name) {
//TODO: FIX the disguise sounds //TODO: FIX the disguise sounds
try {
return valueOf(name);
} catch (Exception ex) {
return null; return null;
// try { }
// return valueOf(name);
// } catch (Exception ex) {
// return null;
// }
} }
private HashSet<String> cancelSounds = new HashSet<>(); private HashSet<String> cancelSounds = new HashSet<>();

View File

@ -1099,14 +1099,15 @@ public class PacketsManager {
} }
public static void setHearDisguisesListener(boolean enabled) { public static void setHearDisguisesListener(boolean enabled) {
if (soundsListenerEnabled != enabled) { //TODO: FIX SOUNDS
soundsListenerEnabled = enabled; // if (soundsListenerEnabled != enabled) {
if (soundsListenerEnabled) { // soundsListenerEnabled = enabled;
ProtocolLibrary.getProtocolManager().addPacketListener(soundsListener); // if (soundsListenerEnabled) {
} else { // ProtocolLibrary.getProtocolManager().addPacketListener(soundsListener);
ProtocolLibrary.getProtocolManager().removePacketListener(soundsListener); // } else {
} // ProtocolLibrary.getProtocolManager().removePacketListener(soundsListener);
} // }
// }
} }
public static void setInventoryListenerEnabled(boolean enabled) { public static void setInventoryListenerEnabled(boolean enabled) {