mirror of
https://github.com/essentials/Essentials.git
synced 2025-08-12 01:25:26 +02:00
New permission: essentials.vanish.pvp
If you don't have this permission you cannot PVP while vanished.
This commit is contained in:
@@ -54,6 +54,11 @@ public class EssentialsEntityListener implements Listener
|
|||||||
event.setCancelled(true);
|
event.setCancelled(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (attacker.isHidden() && !attacker.isAuthorized("essentials.vanish.pvp"))
|
||||||
|
{
|
||||||
|
event.setCancelled(true);
|
||||||
|
}
|
||||||
|
|
||||||
attacker.updateActivity(true);
|
attacker.updateActivity(true);
|
||||||
final List<String> commandList = attacker.getPowertool(attacker.getItemInHand());
|
final List<String> commandList = attacker.getPowertool(attacker.getItemInHand());
|
||||||
if (commandList != null && !commandList.isEmpty())
|
if (commandList != null && !commandList.isEmpty())
|
||||||
|
Reference in New Issue
Block a user