on_corpse_expire
Fires when a corpse reaches the end of its lifetime without being looted. The event runs for the owner, if they are online.
Clearing corpses with the admin command does not fire this event, so staff cleanup cannot hand players a death penalty they did not earn.
Fields
| Field | Type | Description |
|---|---|---|
triggers | List<Ref<Triggerable>> | Entries to trigger when the corpse expires. |
Context keys
| Key | Type | Description |
|---|---|---|
OWNER_NAME | String | Name of the dead player. |
OWNER_UUID | String | UUID of the dead player. |
EXPERIENCE | Int | Experience lost with the corpse. |
ITEM_COUNT | Int | Number of item stacks lost. |
CORPSE_POSITION | Position | Where the corpse stood. |
How could this be used?
Tell the owner their belongings are gone, or apply a death penalty.