Events system
Events system (deep dive)
Each preset is a separate file in plugins/WujaRift/events/. Defaults: nether_breach and void_incursion.
Lifecycle
- Scheduler — interval / cron + chance; respects global cooldown and max concurrent.
- Location — near-players or fixed-locations from config.
- Announce / open — beam particles, boss bar, broadcast.
- Waves — wave list with delays and mobs (HP/damage multipliers, custom names).
- Boss — after waves (optional), phases by health-percent with abilities.
- Rewards — last-hit / top-damage / participation from rewards.yml.
- Cleanup + cooldown — rift timeout, concurrent limit.
Preset structure
# events/void_incursion.yml
id: void_incursion
display-name: "<gradient:#5B2C6F:#BB8FCE>Void Incursion</gradient>"
weight: 8
duration-seconds: 720
announce: true
visuals:
beam-particle: REVERSE_PORTAL
ambient-particle: PORTAL
boss-bar-color: PURPLE
boss-bar-style: SEGMENTED_12
waves:
- delay-seconds: 0
announcement: true
mobs:
- type: ENDERMAN
amount: 4
health-multiplier: 1.3
damage-multiplier: 1.2
name: "<dark_purple>Void Walker</dark_purple>"
boss:
enabled: true
spawn-after-waves: true
delay-after-last-wave-seconds: 20
type: ENDERMAN
name: "<bold>The Void Herald</bold>"
health: 500.0
damage-multiplier: 2.0
glowing: true
boss-bar: true
phases:
- health-percent: 75
message: true
abilities:
- type: SUMMON_MINIONS
cooldown-seconds: 16
mob-type: ENDERMITE
amount: 6
- type: AOE_DAMAGE
cooldown-seconds: 14
radius: 4.5
damage: 6.0
Typical phase abilities
- SUMMON_MINIONS — spawns adds
- AOE_DAMAGE — damage in a radius
- LEAP — jump / charge
- More types depend on the release — check the preset YAML
Scheduling
- settings.auto-events in config.yml
- default-events — pool of random presets
- weight in a preset affects selection chance
- Manual: /rift start void_incursion or /rift start (random)
SMP balance: start with default presets, then cut mob amounts if TPS drops. Rift timeout prevents hanging events.