Use isPlayerDisguise
This commit is contained in:
parent
a3b67b9a4f
commit
465257f11a
@ -102,7 +102,7 @@ public class DisguiseListener implements Listener {
|
|||||||
if (newLoc != null) {
|
if (newLoc != null) {
|
||||||
for (HashSet<TargetedDisguise> list : DisguiseUtilities.getDisguises().values()) {
|
for (HashSet<TargetedDisguise> list : DisguiseUtilities.getDisguises().values()) {
|
||||||
for (TargetedDisguise disguise : list) {
|
for (TargetedDisguise disguise : list) {
|
||||||
if (disguise.getType() == DisguiseType.PLAYER && disguise.canSee(player)
|
if (disguise.isPlayerDisguise() && disguise.canSee(player)
|
||||||
&& ((PlayerDisguise) disguise).getWatcher().isSleeping()
|
&& ((PlayerDisguise) disguise).getWatcher().isSleeping()
|
||||||
&& DisguiseUtilities.getPerverts(disguise).contains(player)) {
|
&& DisguiseUtilities.getPerverts(disguise).contains(player)) {
|
||||||
PacketContainer[] packets = DisguiseUtilities.getBedPackets(player,
|
PacketContainer[] packets = DisguiseUtilities.getBedPackets(player,
|
||||||
|
Loading…
Reference in New Issue
Block a user