ConditionEntity
variableEquals
since v4.6Checks if the given variable has a particular value.
Aliases
variableeqvarequalsvareq
Configuration Fields (1)
| Name | Type | Default | Description |
|---|---|---|---|
| value val, v | PolymorphicPlaceholder | — | The value to match |
Examples & Notes
Examples
In this example, the target players would only hear growling from any number of nearby bears once every 10 minutes.
BearMob:
Skills:
- skill:BearGrowl @PlayersInRadius{r=40} ~onTimer:60
BearGrowl:
TargetConditions:
- variableEquals{var=target.heardbear;value="yes"} cancel
Skills:
- message{m="&7You hear a growling noise..."}
- setvariable{var=target.heardbear;value="yes";duration=6000}
In this example, the skill would only fire if the global variable “poison_storm” is set to true.
PoisonStormDamage:
Conditions:
- varEquals{var=global.poison_storm;value="yes"}
Skills:
- potion{type=POISON;duration=100}
- damage{amount=1;ignorearmor=true}
Universal Condition Options
- Author:
- Ashijin