~onLoad
Fires when an entity is loaded from save data (chunk load, world load, etc.).
Parameters
| Parameter | Default | Description |
|---|---|---|
once | false | Only trigger once per entity lifetime |
Examples
Skills:
- animation{name=wake_up} ~onLoad
Common Patterns
Wake Up Animation
Skills:
- animation{name=stretch} ~onLoad
Restore Visual State
Skills:
- showbone{bone=equipment} ~onLoad
- animation{name=idle} ~onLoad
Re-initialization
Skills:
- hidebone{bone=death_particles} ~onLoad
- showbone{bone=living_effects} ~onLoad
Notes
- Different from
~onSpawn- this fires when loading existing entities ~onSpawnfires when the entity is first created~onLoadfires when the entity is loaded from NBT data- Useful for restoring visual states that may not persist through save/load