Check Effect Type
Check if the effect of a status effect instance is of a type or if it's included in an effect type tag.
Type ID: kaya:check_effect_type
Format
| Field | Type | Default | Description |
|---|---|---|---|
key |
Identifier | optional | If specified, checks if the effect of a status effect instance is of this specific type. |
tag |
Effect Type Tag | optional | If specified, checks if the effect of a status effect instance is included in this effect type tag. |
effect |
Effect Provider | The status effect instance to check. |
Warning
Both key and tag fields should not be present or absent at the same time! Otherwise an error will be thrown.
Example
This example will check if the effect of the status effect instance provided by the kaya:applied_effect context parameter is of a minecraft:poison effect type.
History
| Minecraft | Mod | Changelog |
| 1.21.5 | 0.1.0 | Added the type. |