Minecraft – Disable a villager spawner

minecraft-bedrock-edition

On our Pocket Edition skygrid, we found a Monster Spawner that spawns villagers. Now that we have all the villagers we need, we can't seem to disable the spawner. We don't want to destroy it. However, it does not seem to be able to be disabled.

Is there something I'm missing? How do I disable the villager spawner?

Best Answer

All spawners have a default Spawn Range (emphasis mine):

SpawnRange: The radius around which the spawner attempts to place mobs randomly. The spawn area is square, includes the block the spawner is in, and is centered around the spawner's x,z coordinates - not the spawner itself. It is 2 blocks high, centered around the spawner's y coordinate (its bottom), allowing mobs to spawn as high as its top surface and as low as 1 block below its bottom surface. Vertical spawn coordinates are integers, while horizontal coordinates are floating point and weighted towards values near the spawner itself. Default value is 4.

In this instance, since light levels do not affect its ability to spawn mobs, you can instead surround it with solid blocks, so that mobs cannot spawn.

Alternatively (as Bern Gerrits has already pointed out), all spawners have a mob limit - if mobs congregate within range of the spawner, the spawner will automatically disable itself (emphasis mine):

MaxNearbyEntities: Overrides the maximum number of nearby (within a box of spawnrange*2+1 x spawnrange*2+1 x 8 centered around the spawner block) entities whose IDs match this spawner's entity ID. Note that this is relative to a mob's hitbox, not their physical position. Also note that all entities within all chunk sections (16x16x16 cubes) overlapped by this box are tested for their ID and hitbox overlap, rather than just entities which are within the box, meaning a large amount of entities outside the box (or within it, of course) can cause substantial lag.

This is why most mob farms will create a pit for the mobs to fall into, so that mobs will immediately fall out of range of the spawner, therefore creating the potential to spawn more asap. In your instance, trapping them in this area will force the spawner to shut down once it reaches its cap, if you trap the mobs in this area.

Source

Alternatively, you could potentially create a "killing floor", to instead just kill any and all mobs that come form the spawner, by placing lava on the floor, etc. This will mean that the spawner never shuts off, but the mob count never grows.