I'm looking for a command block creation that allows me to mine spawners in singleplayer.
I found "http://onecmd.com/cmd/better-spawners-updated" but when I put it into a command block and power it nothing happens. What can be done to fix it or is there a replacement?
Update: By "Mine spawners" I mean I want to be able to pick them up as an item.
I found "http://onecmd.com/cmd/better-spawners-updated" but when I put it into a command block and power it nothing happens. What can be done to fix it or is there a replacement?
Update: By "Mine spawners" I mean I want to be able to pick them up as an item.
6
Using the snapshots for 1.13, you can detect when a player uses a silktouch pick to destroy a spawner pretty easily:
/scoreboard objectives add brokespawner (broke spawner) then repeat this every tick: /execute as @a[nbt:{(current item has silktouch)},scores={brokespawner=1}], at @p run /give @p minecraft:spawner. However, there is no method to detect what type of spawner was broken.
Here's what I would recommend:
-breaking a spawner gives an empty spawner
-throw 64 flesh/bones/string/blazerods on top of a spawner to "fill" the spawner with zombies/skeletons/spiders/blazes
-since silverfish don't have a unique drop, throw 64 stone instead
-other mobs could be a bit OP, but you can still add them if you want. You might slow down the spawn rate of slimes/magma cubes.
/scoreboard objectives add brokespawner (broke spawner) then repeat this every tick: /execute as @a[nbt:{(current item has silktouch)},scores={brokespawner=1}], at @p run /give @p minecraft:spawner. However, there is no method to detect what type of spawner was broken.
Here's what I would recommend:
-breaking a spawner gives an empty spawner
-throw 64 flesh/bones/string/blazerods on top of a spawner to "fill" the spawner with zombies/skeletons/spiders/blazes
-since silverfish don't have a unique drop, throw 64 stone instead
-other mobs could be a bit OP, but you can still add them if you want. You might slow down the spawn rate of slimes/magma cubes.
Something along the lines of this:
+Test for diamond pick with silk touch
>Test for being on top of a spawner
>Test for facing down
>test for the block being destroyed
>give the player a monster spawner
+Test for diamond pick with silk touch
>Test for being on top of a spawner
>Test for facing down
>test for the block being destroyed
>give the player a monster spawner
I don't know if this will work (It may only work in adventure mode): /give @s diamond_pickaxe 1 0 {"can_destroy":{"blocks":["spawner"]}} or /give @s diamond_pickaxe 1 0 {CanDestroy:["minecraft:spawner"]}
Neither of those worked. I don't want to just break the spawners, I can do that in singleplayer already. I want to mine it and get the item from it...
Isnt that just to be able to destroy the spawner in adventure mode? I havent tested it, but as far as i know that wont make the spawner drop after being mined. It just makes it breakable in gm 2
im think its the second one.
