1

How do I testfor a zombie with a health of 0?

DovahSilThur's Avatar DovahSilThur11/12/18 1:40 pm
1 emeralds 187 4
11/16/2018 10:50 pm
DovahSilThur's Avatar DovahSilThur
I'm working on an adventure map, and one of the things in the tutorial is you have to fight a beast (Zombie with green leather armor and oak leaves on it's head). I need to have a command that finds out when the zombie has died.
I have tried making it's armor a 100% drop chance and testing for the armor it drops because that will only come out when it dies, but that didn't work, then I tried searching the internet for a way to testfor a zombie with a health of 0 and found nothing good beside doing all that weird scoreboards and such but for one I don't want to make an entire scoreboard because of one tutorial beast and for two I have absolutely no clue how to do scoreboards. Is there a simple way to just test for if the zombies health is at 0?
Posted by DovahSilThur's Avatar
DovahSilThur
Level 8 : Apprentice Skinner
2

Create an account or sign in to comment.

4

1
11/12/2018 4:12 pm
Level 46 : Master Architect
Isz
Isz's Avatar
It's been a while since i've made a singleplayer adventure map but you could invert the signal and test for no zombie. You'd have to only have that command block be powered after the zombie has spawned though.
1
11/15/2018 10:14 pm
Level 8 : Apprentice Skinner
DovahSilThur
DovahSilThur's Avatar
How would you go about that? Would it be like a redstone clock that starts when the beast spawns and it is dependent upon command block that tests for the zombie, followed by a compactor, and every time the clock repeats it adds a pulse into a repeater and it goes faster than the repeater, then after the repeater do a not gate, followed by the rest of the tutorial so as soon as the command block's output is false because it can't find the zombie the clock stops and the not gates turns on the rest of the tutorial?
1
11/16/2018 6:18 pm
Level 46 : Master Architect
Isz
Isz's Avatar
Well without trying anything in game I would do:
- When the command to spawn the zombie is triggered it also sets a redstone block near another (repeating, needs redstone) commandblock that is testing for the zombie with inverted output signal.
- Then when the zombie is killed that inverted signal is back to normal so would power an impulse command block to set that redstone block back to air and also do whatever other commands you need for the boss killing.
1
11/16/2018 10:50 pm
Level 8 : Apprentice Skinner
DovahSilThur
DovahSilThur's Avatar
All right, I tried it and it worked, thanks for the help!
Planet Minecraft

Website

© 2010 - 2024
www.planetminecraft.com

Welcome