Take the 2-minute tour ×
Arqade is a question and answer site for passionate videogamers on all platforms. It's 100% free, no registration required.

So, my friend just implemented a bunch of new mods into his SMP server, which meant a host of new commands to play with.

I thought I'd give the /mobspawn command a few goes, and see what I could achieve. So I headed off to the server's jail (I forget why this particular location compelled me), and gave it a few spins.


I seem to have made a bit of an error in judgement.


About 60 assorted pigs, cows, and chickens crammed into a small enclosed space

What can I do to get rid of this mess? Is there a command or some other technique I can use to clear out any mobs in my immediate vicinity?

share|improve this question
10  
Is fire an option? –  BlueRaja - Danny Pflughoeft May 4 '11 at 5:24
    
@Blueraja > Unfortunately, since this is in the server jail, I can't build/place anything in the area. –  DwarfSlice May 4 '11 at 5:26
2  
I thought this was gonna be a dwarf fortress question! :( –  Raven Dreamer May 4 '11 at 6:21
8  
Part of me knows it's probably a bad idea, but the fact that this question is tagged with [murder] amuses me to no end. –  lilserf May 4 '11 at 14:15
1  
+1 for the murder tag! –  Lohoris May 15 '11 at 12:40

11 Answers 11

up vote 14 down vote accepted

Depending on the mods installed, /butcher [radius] should work. Of course, you'd need access to the commands to do so.

share|improve this answer
    
Is this command one of the defaults? –  DwarfSlice May 4 '11 at 20:23
5  
@Gnome it's part of WorldEdit's Utilities –  Zommuter May 4 '11 at 20:26
1  
@TobiasKienzler: That is also part of Bukkit Essentials, which also happens to be the same server mod that provides /spawnmob, conveniently. Of course, /butcher is just an alias of /killall if you only have Essentials installed. (Otherwise, I believe WorldEdit's butcher may overwrite Essentials's, but I'm not 100% sure. Still gets the job done though.) –  Reid Jan 29 '12 at 7:25

This is now possible in vanilla with a feature introduced in the 1.8 snapshots. You can now /kill animals and mobs using the @e selector. For instance to kill all the pigs in that pen, you would use

/kill @e[type=Pig,r=10]

And similarly, you'd use Cow instead of Pig to kill all the cows in the pen. I use the radius specifier so that you don't kill all the pigs or cows that are currently loaded in your world, just the ones that are within your vicinity (10m). Note that there's only one space, between /kill and @e, in this command. Adding additional spaces will cause the command to not parse properly, and will not only kill you, but possibly every other entity that's loaded in the world.

share|improve this answer

No-mod solution:

Place some water, and TNT in the water (make sure you aren't replacing the water), and light it. TNT in water will do no damage to blocks (leaving your jail intact), but full damage to entities (the unwanted animals). Do not place more than two TNT at a time, as explosions might blast other activated TNT out of the water, allowing it to do damage to blocks.

Note that the TNT will also damage any minecarts, boats, or loose resources in the area, whether or not there is a clear line-of-sight to them.

share|improve this answer
5  
OP mentioned he wasn't able to place anything in the room. –  Raven Dreamer May 4 '11 at 22:14
3  
@Raven > Yes, but that particular restriction is pretty localized. –  DwarfSlice May 4 '11 at 23:51
    
Oops, I didn't read all the comments. Hopefully this is useful elsewhere. –  Kevin Reid May 5 '11 at 13:17

Get some stone swords and button mash!

share|improve this answer

If you are in creative, turn into survival, then use a sword and just kill them, if this takes too long, well, I have no idea, I am having the same problem on my server right now too, somebody spawned thousands of chickens and i cant kill them all because of the lag.

share|improve this answer

This may not have been an option at the time the question was asked, but one as-yet unmentioned method to try is to throw a bunch of Splash Potion of Harming (II). Do note that if this same situation were to occur with undead mobs like zombies or skeletons, Splash Potion of Healing should be used instead.

This method tends to work best if you are in creative mode, as the splash potion will not be removed from your inventory when used, allowing you to easily rapid-fire carpet-bomb the infested area. It can be considerably quicker than manually swording every single mob in the area, doesn't rely on commands that may not be available to you, and works handily in protected areas where you cannot place blocks.

share|improve this answer

For pigs, make a pit of lava around you then hold a carrot/carrot on a stick - they will come to you and burn.

share|improve this answer
2  
The OP mentioned that they cannot build in the server jail. –  Jeffrey Lin Nov 3 '12 at 0:12
1  
That restriction is pretty localized. –  Timtech Nov 2 '13 at 23:01

Use splash potion of harming, it gets them all in a few shots.

share|improve this answer

The /killall command from Essentials should fix your problem

share|improve this answer
    
This would kill all mobs on the server. OP seems to just want to clean up the animals they spawned. –  Batophobia Mar 7 at 15:50

CoreProtect, it can rollback mobs as well. /co rollback u: t: r: a: b: e:

share|improve this answer

The only two ways I can think of are placing TNT in water, or going in survival and spam a sword.

share|improve this answer
3  
You are repeating answers already provided... –  Dom Oct 12 '13 at 4:19

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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