Built-in Events
shogi:on_death
shogi:on_death is evaluated on the server whenever a living entity dies. The dying entity is used as the rule context, so entity, position, and world conditions describe that entity and the place where it died.
For example, this rule adds a cooldown when a player dies, which you could then later query elsewhere:
{
"shogi:on_death": [
"is_player -> add_cooldown('death', '5m')"
]
}
The event applies to every LivingEntity, not only players. Use conditions such as is_player, has_entity_tag, is_dimension, or is_biome to select the deaths that should trigger an action.
{
"shogi:on_death": [
"is_player + is_dimension('minecraft:the_nether') -> add_cooldown('nether_death', '10m')"
]
}
true, failure(...), or refuse(...).Datapack configuration
Instead of the global config file, a datapack can define this event at:
data/shogi/shogi/rules/on_death.json
The file contains the rule payload directly, without the surrounding shogi:on_death property:
[
"is_player -> add_cooldown('death', '5m')"
]
For the conditions and actions that can be used in an event rule, see Available Effects.