Conditions
In this page you will learn how to make an exception to some actions using condition
Condition can be inside a list, for example:
another example:
or, it can be a section, for example:
Condition Types
HAS_PERMISSION
This checks whether theentity has the required permission
If negate is true, then it will pass if the entity does NOT have the permission instead
IS_HOLDING
This checks whether the entity is holding an item
To create an item, please see
IS_ITEM_IN_HAND_ENCHANTED
This checks whether the item held by the entity is enchanted
For list of enchantment types, please see
https://hub.spigotmc.org/javadocs/bukkit/org/bukkit/enchantments/Enchantment.html
WORLD_WHITELIST
This checks whether the entity is inside the whitelisted world
HAS_ITEM
This checks whether the entity has the item inside the inventory
HAS_EFFECT
This checks whether the entity has the potion effect or not
For list of potion effect types, please see
https://hub.spigotmc.org/javadocs/bukkit/org/bukkit/potion/PotionEffectType.html
TYPE_FILTER
This checks whether the entity type is allowed or not
Filter Types
CREATURE This allows every creature
To see the creature specification, please see
https://hub.spigotmc.org/javadocs/bukkit/org/bukkit/entity/Creature.html
TAMED This allows every tamed animals
To see the tameable specification, please see
https://hub.spigotmc.org/javadocs/bukkit/org/bukkit/entity/Tameable.html
ANIMALS This allows every animals
To see animals specification, please see
https://hub.spigotmc.org/javadocs/bukkit/org/bukkit/entity/Animals.html
MONSTER This allows every monster
To see monsters specification, please see
https://hub.spigotmc.org/javadocs/bukkit/org/bukkit/entity/Monster.html
<ENTITY TYPE> This allows specific type to be filtered
For entity types list, please see
https://hub.spigotmc.org/javadocs/bukkit/org/bukkit/entity/EntityType.html
You can combine more than 1 entity filter using boolean logic, for example, if you want to combine effects and those effects required to be passed, you can use "and" or "&&" or "&", for example:
if you want to combine effects and only need one filter to pass, you can use "or" or "||" or "|", for example:
if you want to combine effects and only one filter can pass, you can use "xor" or "^", for example:
You can also combine more than 1 boolean logic and group them with parenthesis, for example:
POWER_REQUIREMENT
This checks whether the beacon pass the power requirement
FREE_POWER_REQUIREMENT
This checks whether the beacon pass the power requirement remaining
AND_LOGIC
Combines two or more conditions, needs all condition to be valid/pass
Example:
OR_LOGIC
Combines two or more conditions, only need one condition to be valid/pass
PLOTSQUARED_IS_IN_PLOT
Checks whether the beacon is inside a plot
Requires PlotSquared
PLOTSQUARED_IS_SAME_PLOT
Checks whether the beacon and the target entity is in the same plot
Requires PlotSquared
PLOTSQUARED_IS_IN_PLOT_AREA
Checks whether the beacon is in a plot area
Requires PlotSquared
PLOTSQUARED_IS_SAME_PLOT_AREA
Checks whether the beacon and the target entity is in the same plot area
Requires PlotSquared
GRIEFPREVENTION_SAME_CLAIM
Checks whether the beacon and the target entity is in the same claim area
Requires GriefPrevention
GRIEFPREVENTION_PERMISSION
Checks whether the player has GriefPrevention claim permission
Requires GriefPrevention
GRIEFPREVENTION_OWNER
Checks whether the player is the land/claim owner
Requires GriefPrevention
GRIEFPREVENTION_CLAIMED
Checks whether the beacon is in claimed land
Requires GriefPrevention
FACTIONS_IN_FACTION
Checks whether the beacon is inside faction land
Requires either Factions, FactionsX, FactionsBlue, KingdomsX, Kingdoms, LegacyFactions, MedievalFactions, UltimateFactions, Towny, or Improved Factions
FACTIONS_IN_SAME_FACTION
Checks whether the beacon and the target entity is in the same faction land
Requires either Factions, FactionsX, FactionsBlue, KingdomsX, Kingdoms, LegacyFactions, MedievalFactions, UltimateFactions, Towny, or Improved Factions
FACTIONS_IS_ROLE
Checks the target entity role inside a faction
If Compare To Current Location Faction
is true
then it will compare if the role belongs to the faction at the entity location
Requires either Factions, FactionsX, FactionsBlue, KingdomsX, Kingdoms, LegacyFactions, MedievalFactions, UltimateFactions, Towny, or Improved Factions
TOTAL_ACTIVE_BEACON_EFFECTS
Checks how many active beacon effects on a beacon
If the minimum is specified and the total is less than the minimum, it will not pass the check
If the maximum is specified and the total is greater than the maximum, it will not pass the check
If you use this condition on the effect config, players still can upgrade and activate more than the minimum and maximum range specified in the config, but when the total is outside of the range, it will deactivate the effect.
NESTING CONDITION
You can combine AND LOGIC and OR LOGIC, for example:
Last updated