How do I kill every entity except arrows and players? [duplicate]

How do I kill every entity except arrows and players? [duplicate] - Silhouette of Man Holding Stick during Sunset

I was trying to make a world where arrows, if shot at a player, will destroy items, but keep the player alive.

However when I use the command /kill @e[type=!Player], the arrows will be destroyed.



Best Answer

Run this command first:

/scoreboard objectives add noKill dummy

Run these on a clock:

/scoreboard players set @e noKill 1
/scoreboard players set @e[type=Player] noKill 0
/scoreboard players set @e[type=Arrow] noKill 0

Now kill all entities with a noKill score that is not 0:

/kill @e[score_noKill_min = 1]

Comment if this doesn't work, but it works for me.




Pictures about "How do I kill every entity except arrows and players? [duplicate]"

How do I kill every entity except arrows and players? [duplicate] - Wall Clock at 5:50
How do I kill every entity except arrows and players? [duplicate] - Top view of slogan Stop Killing Us on surface of square blackboard on black background
How do I kill every entity except arrows and players? [duplicate] - Photo of Yellow Arrow Road Signage



How do you kill every entity in Minecraft?

Kill Command In all Minecraft editions, the command for killing everything in the world is \u201c /kill <target> \u201d. Typing \u201c /kill \u201d any target in the console will destroy pretty much everything that can be removed, including the player.

How do you kill all mobs around you?

If you want to kill mobs all at once then this step is the best.
  • Type /kill.
  • Use @e to target all the entities.
  • Type [type=! player]. This will kill every Mobs.
  • Execute the command by pressing Enter.




  • Kill Command Explained




    Sources: Stack Exchange - This article follows the attribution requirements of Stack Exchange and is licensed under CC BY-SA 3.0.

    Images: Clement Eastwood, Cats Coming, Brett Sayles, Josh Sorenson