1

I want to be able to summon a potion that can hurt all mobs, undead or alive. I currently summon potions of harming to kill mobs, but that only affects creepers, spiders, etc. If there is a way to use command blocks to damage mobs directly, or some other alternative, please feel free to say it.

If I'm going to use potions, do you know how to get rid of the particles without the user doing so?

1

There is no potion that kill/damage all mobs, there is only damage or heal and some work on one mob and some work on another mob.

0

You could use this:

/kill @e[type=Entity]

Do note, the above solution will kill all entities, including dropped items. This will also kill you, the player as well. If you don't want that, the below solution works as well:

/kill @e[type=!Player]
  • 1
    I'm afraid I wasn't too clear. Sorry about that. I'm hoping I can damage an entity, not "kill" it. – mashedpotats Jul 8 '15 at 6:18
0

If you want to make them take damage progressively, the best option is probably poisoning them selectively. This idea makes use of the fact that undead entities revert not only the result of poisoning/harming effects, but also the ones of healing effects.

Thus, for each "normal" entity type (Creeper, Spider etc.), you would do:

/effect @e[type=TheType] minecraft:poison desiredDuration desiredAmplifier

And for undead entity types (Zombie, Skeleton etc.), you would do:

/effect @e[type=TheType] minecraft:regeneration desiredDuration desiredAmplifier

Also works with healing. IDs are minecraft:instant_damage for harming and minecraft:instant_health for healing (i.e. harming the undead). Not sure right now what you need to put for the duration there, 0 is the only thing that makes sense though.

Note that, while harming heals undead monsters as much as it harms other monsters, healing deals more damage to them than normal monsters are healed. In fact, it deals as much damage to them as harming to other monsters.

For removing the particles, just add {ShowParticles:0b} at the end of the command. (I think that does work with the effect command as well, not quite sure though. It definitely works when applying effects via NBT, so if everything else fails, you could make that work by calling the entitydata command.)

0

You can use the wither effect to act as a poison that can kill any entity, but there is also the alternate poison effectt called fatal_poison, which is the same as poison but it doesn’t stop at any point, even if it kills the entity

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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