I am making an adventure map and I want a section where you practice combat. This section needs to go through doing a critical attack, a sweep attack, and a normal attack. I was wondering if I'm able to detect what kind of attack is being done through command blocks.

I'm attacking an armor stand.

  • Doing this looks to be a bit annoying... I dont see a way to track any of the three actions alone (aside from swinging in general), and armor stands don't have hp, meaning you can't check how much damage it took, nor the damage dealt stats... You could potentially do it with other mobs (?)
    – BunnyMerz
    Aug 5 at 0:34
  • @BunnyMerz Using other mobs is a perfect solution for criticals, at least, since you can give a mob regen 127 and set its HP to exactly the amount required for a critical hit, and a normal hit is similar. Tracking sweep attack seems like the most annoying, though. At best you could detect if multiple mobs are killed, but I wouldn't know how to detect multiple dying at the /same time/.
    – Corsaka
    Aug 5 at 11:42
  • Just detect if their HurtTime all changed at the same time. Just put one on each side of the target.
    – BunnyMerz
    Aug 6 at 1:15


You must log in to answer this question.

Browse other questions tagged .