Fixed Player disguises
Fixed all disguises Fixed issue where players would crash upon joining Fixed issue where disguises would crash when player left and reentered a location where a disguise previously was This is basically a beta build, FIND BUGS FOR ME! :D
This commit is contained in:
@@ -236,15 +236,15 @@ public class LibsDisguises extends JavaPlugin {
|
||||
for (WrappedWatchableObject watch : watcher.getWatchableObjects()) {
|
||||
disguiseValues.setMetaValue(watch.getIndex(), watch.getValue());
|
||||
// Uncomment when I need to find the new datawatcher values for a class..
|
||||
int id = watch.getIndex();
|
||||
Object val = watch.getValue();
|
||||
Class<?> valClazz = val != null ? watch.getValue().getClass() : null;
|
||||
try {
|
||||
val = val.toString();
|
||||
} catch (Exception e) {
|
||||
val = val != null ? val.getClass() : "null";
|
||||
}
|
||||
System.out.println("Disguise: " + disguiseType + ", ID: " + id + ", Class: " + (val == null ? "null" : valClazz) + ", Value: " + val);
|
||||
// int id = watch.getIndex();
|
||||
// Object val = watch.getValue();
|
||||
// Class<?> valClazz = val != null ? watch.getValue().getClass() : null;
|
||||
// try {
|
||||
// val = val.toString();
|
||||
// } catch (Exception e) {
|
||||
// val = val != null ? val.getClass() : "null";
|
||||
// }
|
||||
// System.out.println("Disguise: " + disguiseType + ", ID: " + id + ", Class: " + (val == null ? "null" : valClazz) + ", Value: " + val);
|
||||
}
|
||||
DisguiseSound sound = DisguiseSound.getType(disguiseType.name());
|
||||
if (sound != null) {
|
||||
|
Reference in New Issue
Block a user