Fix bug. And it only removes the disguises targeted towards certain players.
This commit is contained in:
parent
6e5241aec3
commit
bd83ff0c80
@ -171,10 +171,10 @@ public class DisguiseUtilities {
|
|||||||
for (TargetedDisguise disguise : disguises) {
|
for (TargetedDisguise disguise : disguises) {
|
||||||
if (disguise.getDisguiseTarget() == TargetType.HIDE_DISGUISE_TO_EVERYONE_BUT_THESE_PLAYERS) {
|
if (disguise.getDisguiseTarget() == TargetType.HIDE_DISGUISE_TO_EVERYONE_BUT_THESE_PLAYERS) {
|
||||||
if (disguise.canSee(viewer)) {
|
if (disguise.canSee(viewer)) {
|
||||||
boolean add = false;
|
boolean add = true;
|
||||||
for (String observer : disguise.getObservers()) {
|
for (String observer : disguise.getObservers()) {
|
||||||
if (!observer.equals(viewer) && Bukkit.getPlayerExact(observer) != null) {
|
if (!observer.equals(viewer) && Bukkit.getPlayerExact(observer) != null) {
|
||||||
add = true;
|
add = false;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user