Permission to teleport around besieged areas.
Intended for administrators. Defaults on for server ops.
This commit is contained in:
parent
70b8c242e2
commit
b5236aed9a
|
|
@ -245,6 +245,7 @@ permissions:
|
||||||
griefprevention.seeinactivity: true
|
griefprevention.seeinactivity: true
|
||||||
griefprevention.eavesdropimmune: true
|
griefprevention.eavesdropimmune: true
|
||||||
griefprevention.deleteclaimsinworld: true
|
griefprevention.deleteclaimsinworld: true
|
||||||
|
griefprevention.siegeteleport: true
|
||||||
griefprevention.siegeimmune:
|
griefprevention.siegeimmune:
|
||||||
description: Makes a player immune to /Siege.
|
description: Makes a player immune to /Siege.
|
||||||
default: op
|
default: op
|
||||||
|
|
@ -353,3 +354,6 @@ permissions:
|
||||||
griefprevention.mostaccrued:
|
griefprevention.mostaccrued:
|
||||||
description: Players with this permission can accrue more claim blocks (limit specified in the config file).
|
description: Players with this permission can accrue more claim blocks (limit specified in the config file).
|
||||||
default: false
|
default: false
|
||||||
|
griefprevention.siegeteleport:
|
||||||
|
description: Players with this permission can teleport into and out of besieged areas.
|
||||||
|
default: op
|
||||||
|
|
@ -1071,6 +1071,9 @@ class PlayerEventHandler implements Listener
|
||||||
//these rules only apply to siege worlds only
|
//these rules only apply to siege worlds only
|
||||||
if(!GriefPrevention.instance.config_siege_enabledWorlds.contains(player.getWorld())) return;
|
if(!GriefPrevention.instance.config_siege_enabledWorlds.contains(player.getWorld())) return;
|
||||||
|
|
||||||
|
//these rules do not apply to admins
|
||||||
|
if(player.hasPermission("griefprevention.siegeteleport")) return;
|
||||||
|
|
||||||
Location source = event.getFrom();
|
Location source = event.getFrom();
|
||||||
Claim sourceClaim = this.dataStore.getClaimAt(source, false, playerData.lastClaim);
|
Claim sourceClaim = this.dataStore.getClaimAt(source, false, playerData.lastClaim);
|
||||||
if(sourceClaim != null && sourceClaim.siegeData != null)
|
if(sourceClaim != null && sourceClaim.siegeData != null)
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user