1

I'm making a Minecraft minigame map using commandblocks (no code or mods). One of the game end conditions is that a team is eliminated.

How to I reliably check that a team has no members left alive on it?

I am using 1.8, and this will (obviously) be multiplayer

1
  • You're not using any building blocks? And what does the title means?
    – Q20
    Commented Feb 3, 2015 at 8:25

1 Answer 1

2

First set up an objective tracking player death, similar to what I outlined in my answer here. For the following, I assume that this objective is named hasDied and there are two teams, red and blue.

Instead of the testfor command in that answer, you can use

/testfor @a[team=red,score_hasDied=0]

Invert the redstone output, so that it turns on when nobody is left alive in team red and continue from there. Do the same thing for the blue team.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.