1

I can use /setblock to create a mob_spawner but I want to set a mob_spawner without it actually spawning any entities, just for display in a shop, yet I can't find out how to do that.

2
  • Do you want to see the entity inside the spawner, or for it to be blank? Do you want the flame particles and spinning animation to continue?
    – SirBenet
    Commented Dec 29, 2016 at 12:59
  • Yes I would like the entity inside the spawner but no flame particles, spinning animation can be on or off.
    – majus
    Commented Dec 29, 2016 at 16:17

2 Answers 2

1

You can accomplish this by setting the spawner's MaxNearbyEntities:

/setblock ~ ~1 ~ mob_spawner 0 replace {MaxNearbyEntities:0}
2
  • Got what I needed from this, thank here is the end results...
    – majus
    Commented Dec 30, 2016 at 0:22
  • /setblock ~2 ~ ~ mob_spawner 0 replace {MaxNearbyEntities:0,SpawnPotentials:[{SpawnCount:"0",Entity:{id:"Cave_spider"}}]}
    – majus
    Commented Dec 30, 2016 at 0:23
0

Well one thing you could try is just having the mob spawner there and then behind it place a repeating command block behind it (make sure players cant see it) that has the following command:

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

this command block is killing any pigs that come withing a 10 block radius of it

please note that if you chose this path you must be precise with the entity name for it, for example if you do /kill @e[type=pig] (with no capital p) it will go on a constant loop killing you. if this happens simply go to your properties file and disable command blocks, restart , destroy the command block turn command block back on restart again and your good hope this helps :D

2
  • I will give that a try if all else fails, thank you!
    – majus
    Commented Dec 29, 2016 at 16:17
  • Near the spawner, you would be able to see/hear pigs dying, and you could collect their drops. I don't think this is the solution you want.
    – user170887
    Commented Jan 6, 2017 at 16:29

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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