"Despawn entity" and "On Entity Despawn" procedure block/triggers

Published by mac44444 on
Status
Duplicate
Issue description

I would want a way to despawn entities without killing them and having them still drop things, and the option to trigger procedures when an entity despawns.

Dont know what else i can add onto this suggestion.

Issue comments

You can't despawn entity but drop its items as dropping items is part of the entites death process. I will try to add entity despawn though.

I am not sure if there is forge event for despawn, but I will check.

net.minecraftforge.event.entity.living.LivingDeathEvent is the event that is fired when an entity, that is a child of EntityLivingBase, dies

Edit: I have overlooked that is only about despawning, my bad. The closest thing to an "on despawn event" is net.minecraftforge.event.entity.living.AllowDespawn, however, you will have to mess with it a bit to achieve the desired effect.

Thanks Nuparu for the research :)

net.minecraftforge.event.entity.living.LivingDeathEvent is already in MCreator as On entity killed trigger but yes this would not be 100% same as despawning.

Raol, thank you for spotting a duplicate. I am closing this ticket and linking to it from the other one.