promotional bannermobile promotional banner
premium banner
Make entity (Boss) auto respawn with custom properties

Description

Entity Respawner Mod

A Minecraft mod that allows specific entities to automatically respawn after death, perfect for boss mobs and other important entities.

Configuration:

The mod uses a datapack to define respawn rules:

Example:

Use entity id to create a new json file under the data/mod_id/entity_to_respawn folder.

Params:

Every field is optional.

  • respawn_timer: How long it takes for entities to respawn, must > 1
  • respawn_when_reload_from_disk: Whether entities respawn immediately when chunks load
  • soul_effect: Show particle effects during countdown
  • broadcast: Broadcast to all players when the entity ready to respawn
  • keep_nbt: Configure keep old nbt or create a custom nbt after entity respawn.
  • pos_override: Configure a new spawn position.
  • nbt_override: Custom entity data. Can be merged with old nbt data.

API:

use RespawnableEntityManager#createFrom(Entity entity, RespawnableEntityData data) to create a SoulEntity. You can modify it's pos or some params. Don't forget to add it to the level after create it.

The respawned entity will contains a "create-from-soul-entity" tag.