minecraft:instant_despawn for you with a switch.Get GodCraftOverview
minecraft:instant_despawn is an entity component: it goes in the components object of a custom mob, or in one of its component groups. Removes the entity from the world as soon as the component is added. Add it from an event to delete a mob cleanly without drops or death animation.
Fields
| Field | Type | Default | Description |
|---|---|---|---|
remove_child_entities | boolean | false | Also removes linked entities, such as leashed mobs. |
Example
Inside the components object of BP/entities/<name>.json (values are the defaults or placeholders):
BP/entities/<name>.json
{
"minecraft:instant_despawn": {
"remove_child_entities": false
}
}