Better remove metadata for #622
This commit is contained in:
parent
1c97612c9f
commit
df833cc4ca
@ -792,11 +792,11 @@ public abstract class Disguise {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (getEntity().hasMetadata("LastDisguise")) {
|
for (String meta : new String[]{"LastDisguise", "LD-LastAttacked", "forge_mods", "LibsRabbitHop", "ld_loggedin"}) {
|
||||||
getEntity().removeMetadata("LastDisguise", LibsDisguises.getInstance());
|
getEntity().removeMetadata(meta, LibsDisguises.getInstance());
|
||||||
}
|
}
|
||||||
|
|
||||||
if (DisguiseConfig.getPvPTimer() > 0) {
|
if (DisguiseConfig.getPvPTimer() > 0 && getEntity() instanceof Player) {
|
||||||
getEntity().setMetadata("LastDisguise", new FixedMetadataValue(LibsDisguises.getInstance(), System.currentTimeMillis()));
|
getEntity().setMetadata("LastDisguise", new FixedMetadataValue(LibsDisguises.getInstance(), System.currentTimeMillis()));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user