Monster Spawner

From Minecraft Wiki
(Redirected from Mob Spawners)
Jump to: navigation, search
Monster Spawner
Monster Spawner.gif
Grid Monster Spawner.png
Type Solid Block
Requirements None
Physics No
Transparency Yes
Luminance No
Blast Resistance [edit] 25
Tool Grid Wooden Pickaxe.png
Stackable Yes (64)
First Appearance Infdev (Seecret Friday Update 2)
Data value dec: 52 hex: 34
A monster spawner with a skeleton inside in 1.0.0

Monster Spawners or Mob Spawners are blocks with a transparent dark grey lattice structure found in dungeons, Abandoned Mine Shafts, Strongholds and Nether fortresses. Inside the block there are flames that do not give off any light and a miniature spinning version of the mob that will spawn, which slowly increases speed until the next mob spawns.

Players have designed many traps to kill mobs from spawners, employing a long fall, drowning, lava, cactus or a combination of these, which allow the player to collect drops or experience in great numbers with little risk (see dungeon mob farming.)

The Monster Spawner is one of the few blocks not made available in Creative Mode.

Contents

[edit] Occurrences

Spawners may occur in these locations:

Dungeons
Spawning Zombies (50% chance), Skeletons (25%), or Spiders (25%). One per dungeon.
Abandoned Mine Shafts
Spawning Cave Spiders. Located in horizontal tunnels, surrounded by Cobwebs.
Strongholds
Spawning Silverfish. Located in End Portal rooms.
Nether Fortresses
Spawning Blazes. Located on balconies with stairs leading up to them.

No naturally occurring spawners will spawn mobs not on the above list, such as passive animals, Creepers, and Endermen; however, if a map editor or mod is used to create a spawner for any mob, it will function as expected.

There is no way to obtain a spawner in your inventory (even in creative mode), except using an Inventory Editor program or the `/give` operator command in a multiplayer server. If such a spawner is placed, or if a spawner is missing its tile entity data, it will spawn pigs.

[edit] Spawning Behavior

A spawner block will create mobs in the surrounding area, provided suitable spawning locations for the block's mob type can be found in the area. Spawning conditions vary from mob to mob. For example, Overworld monsters can only spawn in darkness (light level 7 or below), and animals must spawn on top of grass (light level 9 or above). However, spawner blocks can spawn mobs in mid-air, ignoring general rules about spawning on solid ground.

A monster spawner is only active when a player is within a distance of 16 blocks from the spawner (where distance is calculated the standard (euclidean) way). While the block is active, it will spawn mobs within an 8x3x8 block area (8x8 wide and 3 high), centered on the corner of the spawner block with the lower x and z coordinates. Mobs can spawn anywhere in this range that is suitable, even if the immediate vicinity of the spawner block itself is not suitable.

The block will spawn up to 4 mobs at once and then wait anywhere from 200 to 799 ticks (10 to 40 seconds) before spawning again. As it waits, the mob inside the block will spin faster and faster. If the block fails to spawn any mobs because it did not find any suitable locations, it will search constantly until it does. Only when it manages to spawn at least one mob will it start waiting for the next cycle. If, at the time of spawning, 6 or more monsters of the block's type are present within a 17x9x17 area (17x17 wide and 9 high), centered on the spawner block, the spawner "poofs" without creating any monsters and then waits for the next cycle.

Note that, while mobs are spawned at a discrete y coordinate, the x and z coordinates are real-valued i.e. not aligned to blocks. Mobs will spawn with their legs at either the same level as the spawner block, one block above it, or one block below it. But horizontally, a mob can spawn with its center point anywhere within the 8x8 range. Since the mob itself takes up some horizontal space, this must be added to the range of the spawner to get the full dimensions of the area they can potentially occupy.

Spider spawners have the same 1% chance of spawning Spider Jockeys as natural spider spawning. Spawners can be given unusual entity IDs like Minecart or Boat to make a decorative block with the named entity spinning inside the cage which will not spawn anything.

In Peaceful difficulty, Monster Spawner blocks will still appear, but any spawned mobs will disappear the instant they spawn. This makes it easy to make the traps without being troubled by the mobs. The brief instant that the monster exists in the world before being removed is enough time for the player to be pushed around and, in some cases, for the sound file to play.

[edit] Detailed Spawning algorithm

This pseudo-code is derived straight from the decompiled source of Minecraft Beta 1.7.3.

every spawn cycle (every randInt(200,799) ticks when a player is in range of the spawner),
loop 4 times {
	if there are 6 or more of the mob type in the 17x9x17 area around the spawner, skip this spawn cycle
	calculate spawnerX = X coordinate of center of spawner - 0.5
	calculate spawnerY = Y coordinate of center of spawner - 0.5
	calculate spawnerZ = Z coordinate of center of spawner - 0.5
	calculate x coordinate of mob = spawnerX + (randDouble() - randDouble()) * 4, randDouble being a random number between 0 and 1
	calculate y coordinate of mob = spawnerY + a random whole number between -1 and 1
	calculate z coordinate of mob = spawnerZ + (randDouble() - randDouble()) * 4, randDouble being a random number between 0 and 1
	if all of the conditions specific to the mob type are met, spawn the mob {
	  chicken, cow, pig, sheep, wolf:
		block below spawning block is grass
		spawning block has a light level of 9 or higher

	


	  slime:
		difficulty is not set to peaceful or slime size is small (if it's not peaceful, the algorithm won't get to this point)
		spawn block y coordinate is less than 40
		the chunk containing the spawn block is a slime chunk (1 in 10 chance)
		pass a 1 in 10 random test
	  
	  ghast:
		pass a 1 in 20 random test
	  
	  squid:
		must not collide with any other entities

	  all except squid and slimes:
		must not collide with any other entities
		must not collide with any blocks
		must not collide with water or lava
	}
}

[edit] Trivia

Spawning

The miniature mob inside the spawner


Hacking spawners

[edit] Gallery

[edit] See also

[edit] References

  1. [1]Video clearly showing two, three and four mobs spawning at the same time from a monster spawner.
  2. http://imageshack.us/f/7/kerwrew.png/ Notice how the miniature mob is not spinning and no flames are being emitted.
  3. Giant spawner: File:2011-03-15 14.05.55.png
  4. Ghast spawner: File:2011-03-15 14.06.55.png
Personal tools
Namespaces
Variants
Actions
Minecraft Wiki
Minecraft
Toolbox
In other languages

Recent Community Articles

Mojang Tweets

    Getting your tweets...