Started by
Veyas
on
Topic category: Help with Minecraft modding (Java Edition)
I'm working on a entity reviving effect with a small, 3 second cooldown. But everytime I try to kill myself with this effect, it's not working. I'm slowly getting annoyed cause I can't do anything with it. I also have another effect that cancel cow death, to drop something, then despawn it to prevent other drops, it's triggered the same way, but it's working. I can't figure it out.
I dont think you can cancel death?
The issue isn't that player death isn't cancellable, but the player's health after the cancel is still 0, so the game kills the player again. Here's how to fix it: Set your player's health to anything above 0, before the 'Cancel event that triggered global trigger' block.
Because their health is above 0 when their death is cancelled, they don't immediately die again. Plus, you can set the player back to a specific amount of health, or just back to full.