Scripting Lua: Enums y valores
Esta página enlaza a los Javadocs de Spigot para cada tipo de enum usado por los métodos Lua de EliteMobs. Use el nombre exacto de la constante enum (ej. "FLAME", "ZOMBIE", "STONE") como cadena en su código Lua.
- La ortografía debe coincidir exactamente con el nombre de la constante enum
- El caso generalmente se normaliza internamente, pero coincida con la ortografía de Javadoc para estar seguro
- Si el nombre es incorrecto, EliteMobs registra una advertencia y no hace nada
Enum Reference
| Enum | Used for | Javadoc |
|---|---|---|
BarColor | Boss bar color | BarColor |
BarStyle | Boss bar style | BarStyle |
DamageCause | Damage cause filtering | EntityDamageEvent.DamageCause |
EnderDragon.Phase | Ender dragon phase control | EnderDragon.Phase |
EntityEffect | Entity visual effects | EntityEffect |
EntityType | Entity spawning | EntityType |
EquipmentSlot | Entity equipment slots | EquipmentSlot |
FireworkEffect.Type | Firework shape | FireworkEffect.Type |
Material | Blocks and items | Material |
Particle | Particle effects | Particle |
PotionEffectType | Potion effects | PotionEffectType |
Non-Spigot Values
Zone shapes
nUsed by native zone definitions (kind field) and script utility zone specs (shape field).
Native (kind) | Script Utility (shape) |
|---|---|
sphere | SPHERE |
dome | DOME |
cylinder | CYLINDER |
cuboid | CUBOID |
cone | CONE |
static_ray | STATIC_RAY |
rotating_ray | ROTATING_RAY |
translating_ray | TRANSLATING_RAY |
Entity filters
nUsed by context.zones and context.entities query options.
| Filter | Matches |
|---|---|
player | Players only |
elite | Elite mobs only |
mob | Non-player living entities |
living | All living entities (default) |
Weather values
nUsed by context.world:set_weather(weather).
| Value | Effect |
|---|---|
CLEAR | Clear skies |
RAIN | Rain |
THUNDER | Thunderstorm |
Target types
nUsed by context.script:target() specs.
| Value | Resolves to |
|---|---|
SELF | The boss entity |
SELF_SPAWN | The boss's spawn location |
DIRECT_TARGET | The entity involved in the current event |
NEARBY_PLAYERS | Players within range of the boss |
NEARBY_MOBS | Non-player mobs within range |
NEARBY_ELITES | Elite mobs within range |
ALL_PLAYERS | All online players |
WORLD_PLAYERS | All players in the boss's world |
ZONE_FULL | Entities/locations inside a zone volume |
ZONE_BORDER | Entities/locations on a zone border |
LOCATION | A specific location from the spec |
