A Minecraft Java Edition datapack that allows players to recover and reuse mob spawners with Silk Touch while preserving the original mob type.
When a player breaks a mob spawner with Silk Touch, the datapack stores the mob type inside the recovered spawner.
When the spawner is placed again:
custom_data.SpawnData is restored.SpawnPotentials is restored.The system is completely generic and does not require a separate function for each mob.
The datapack has currently been tested successfully with:
Other mobs using standard mob spawners should work with the same system.
datapacks folder./reload.The datapack does not require any mods.
Obtain a mob spawner with Silk Touch.
Break the spawner normally with the Silk Touch tool.
Place the recovered spawner again.
The datapack automatically restores the original mob type.
No command is required between placements.
The datapack uses:
minecraft:custom_dataSpawnDataSpawnPotentialsThe mob identifier is read dynamically from:
minecraft:custom_data.spawner_mob
This allows the same functions to handle different mob types without hardcoding individual mobs.
🟢 Functional — v1.0.0
The core recovery and restoration system has been tested with multiple mob types and repeated spawner placement.
See the repository for licensing information.
Created by CpyBad.