Compatibility
Minecraft: Java Edition
Platforms
Supported environments
Creators
Details

Structure Shield prevents players from breaking or placing blocks inside structures.
It is fully data-driven and configurable, allowing you to choose which structures are protected and which blocks may be broken or placed while inside protected structures.
Now players can't trivialize structures or completely destroy them for future players. It will also increase difficulty as you can't just block off doors to stop mobs or get around jumps or parkour courses by placing platforms.
It was built with performance in mind and shouldn't impact your servers performance or interfere with other mods. If a mod does require a block to be broken or placed inside a structure you can quickly allow that via data packs.
There is a default data pack built in for vanilla Minecraft. This can be easily tweaked to your needs if you want to make changes, but should be good enough for most people. Just install and you're good to go.
I am currently backporting this to 1.20.1, it will be out in the next few days.
About
I built this mod to make it so players had to experience structures more in line with the way they were intended. Being able to break or place all blocks inside structures often trivialized them or made them too easy. This mod gives you full control over which structures should be protected, and which blocks are allowed to be broken or placed. It will create more interesting experiences inside structures.
With Structure Shield you have to navigate and keep track of where you are. You can't just place blocks to block off a room to stop monsters. Doing jumps or parkour courses can now be enforced. I find structures much more enjoyable this way, hopefully you do too!
Some structures do require blocks to be broken or placed in order to function properly. In those cases you can easily add allowed block types using block tags, explained below.
This mod was inspired by Modern Inhibited (and by extension Inhibited). Modern Inhibited hasn't been ported to 1.21.1 Neoforge yet, and I wanted a little more granularity in allowing some blocks to be broken or placed.
Tags
This mod operates mainly off of 3 different tags (1 structure tag and 2 block tags):
"structure_shield:structure_shield_protected"
Any structure with this tag will be protected by this mod. If you want to add structures to this tag then you would create a json file at yourdatapack/data/structure_shield/tags/worldgen/structure/structure_shield_protected.json in your datapack with contents like
{ "replace": false, "values": [ "minecraft:buried_treasure", "othermod:structure" }
If you want to add these structures in addition to the ones already there then leave "replace": false. If you want to replace all previous tag data and only have your own set it to true.
"structure_shield:structure_shield_breakable"
Any block with this tag will be breakable inside of structures that are protected by the tag above. If you want to modify this block tag, like replacing its values or adding new ones, you would add blocks using a datapack and adding this json file: yourdatapack/data/structure_shield/tags/block/structure_shield_breakable.json. You would configure it by adding blocks in the same way we did above with structures. To overwrite the default datapack use "replace": true. Or keep it false to just add the values in.
Block Tag | "structure_shield:structure_shield_placeable"
Any block with this tag will be placeable inside of protected structures. By default it only includes things like torches, so players can add light as they move around. I would be careful adding blocks to this that you don't also add to the breakable tag. If you place a block that isn't in the breakable tag, you won't be able to break it. You would modify these tags the same way you do above with a file added to yourdatapack/data/structure_shield/tags/block/structure_shield_placeable.json.
Configs
There are 2 server side config options in config/structure_shield-server.toml.
Config | protectAllStructures = false
Setting this to true will make every structure in the game protected regardless of what you have in the tags. This can work fine for a lot of people who don't want to fine tune on a structure by structure basis. Default is false.
Config | sanctumsCurseEffectDuration = 4
When a player breaks or places a block they are not supposed to in a protected structure they are given a temporary effect calls Sanctum's Curse. This effect stops them from breaking and placing all blocks for a few seconds (on top of the block they already broke). By default it is 4 seconds, but can be configured or turned off here. To turn off set it to 0 seconds. I created this effect to give more clarity to the player as to why the block can't be placed or broken, as well as increase performance by reducing structure checks.
Default Datapack Values
Structures Protected:
minecraft:ancient_city,
minecraft:bastion_remnant,
minecraft:desert_pyramid,
minecraft:end_city,
minecraft:fortress,
minecraft:igloo,
minecraft:jungle_pyramid,
minecraft:mineshaft,
minecraft:mineshaft_mesa,
minecraft:monument,
minecraft:pillager_outpost,
minecraft:shipwreck,
minecraft:shipwreck_beached,
minecraft:stronghold,
minecraft:swamp_hut,
minecraft:trail_ruins,
minecraft:trial_chambers,
minecraft:village_plains,
minecraft:village_desert,
minecraft:village_savanna,
minecraft:village_snowy,
minecraft:village_taiga,
minecraft:mansion
Blocks Breakable
minecraft:sand,
minecraft:gravel,
minecraft:netherrack,
minecraft:end_stone,
minecraft:amethyst_cluster,
minecraft:small_amethyst_bud,
minecraft:medium_amethyst_bud,
minecraft:large_amethyst_bud,
minecraft:ice,
minecraft:packed_ice,
minecraft:blue_ice,
minecraft:coal_ore,
minecraft:copper_ore,
minecraft:iron_ore,
minecraft:gold_ore,
minecraft:emerald_ore,
minecraft:diamond_ore,
minecraft:lapis_ore,
minecraft:redstone_ore,
minecraft:ancient_debris,
minecraft:deepslate_coal_ore,
minecraft:deepslate_copper_ore,
minecraft:deepslate_iron_ore,
minecraft:deepslate_lapis_ore,
minecraft:deepslate_redstone_ore,
minecraft:deepslate_gold_ore,
minecraft:deepslate_emerald_ore,
minecraft:deepslate_diamond_ore,
minecraft:coal_block,
minecraft:copper_block,
minecraft:iron_block,
minecraft:gold_block,
minecraft:emerald_block,
minecraft:diamond_block,
minecraft:lapis_block,
minecraft:netherite_block,
minecraft:raw_copper_block,
minecraft:raw_iron_block,
minecraft:raw_gold_block,
minecraft:nether_quartz_ore,
minecraft:nether_gold_ore,
minecraft:glowstone,
minecraft:sea_lantern,
minecraft:shroomlight,
minecraft:ochre_froglight,
minecraft:pearlescent_froglight,
minecraft:verdant_froglight,
minecraft:magma_block,
minecraft:jack_o_lantern,
minecraft:redstone_lamp,
minecraft:lantern,
minecraft:soul_lantern,
minecraft:torch,
minecraft:wall_torch,
minecraft:soul_torch,
minecraft:soul_wall_torch,
minecraft:end_rod,
minecraft:azalea,
minecraft:azalea_leaves,
minecraft:flowering_azalea,
minecraft:flowering_azalea_leaves,
minecraft:allium,
minecraft:azure_bluet,
minecraft:blue_orchid,
minecraft:cornflower,
minecraft:dandelion,
minecraft:lilac,
minecraft:lily_of_the_valley,
minecraft:orange_tulip,
minecraft:oxeye_daisy,
minecraft:peony,
minecraft:pink_tulip,
minecraft:poppy,
minecraft:red_tulip,
minecraft:rose_bush,
minecraft:sunflower,
minecraft:white_tulip,
minecraft:wither_rose,
minecraft:short_grass,
minecraft:tall_grass,
minecraft:fern,
minecraft:large_fern,
minecraft:dead_bush,
minecraft:vine,
minecraft:weeping_vines,
minecraft:weeping_vines_plant,
minecraft:twisting_vines,
minecraft:twisting_vines_plant,
minecraft:glow_lichen,
minecraft:hanging_roots,
minecraft:spore_blossom,
minecraft:bamboo,
minecraft:bamboo_sapling,
minecraft:kelp,
minecraft:kelp_plant,
minecraft:seagrass,
minecraft:tall_seagrass,
minecraft:wheat,
minecraft:carrots,
minecraft:potatoes,
minecraft:beetroots,
minecraft:melon,
minecraft:melon_stem,
minecraft:attached_melon_stem,
minecraft:pumpkin,
minecraft:pumpkin_stem,
minecraft:attached_pumpkin_stem,
minecraft:sugar_cane,
minecraft:cactus,
minecraft:nether_wart,
minecraft:torchflower,
minecraft:torchflower_crop,
minecraft:pitcher_crop,
minecraft:pitcher_plant,
minecraft:sweet_berry_bush,
minecraft:skeleton_skull,
minecraft:skeleton_wall_skull,
minecraft:wither_skeleton_skull,
minecraft:wither_skeleton_wall_skull,
minecraft:creeper_head,
minecraft:creeper_wall_head,
minecraft:dragon_head,
minecraft:dragon_wall_head,
minecraft:piglin_head,
minecraft:piglin_wall_head,
minecraft:player_head,
minecraft:player_wall_head,
minecraft:zombie_head,
minecraft:zombie_wall_head,
minecraft:white_banner,
minecraft:white_wall_banner,
minecraft:orange_banner,
minecraft:orange_wall_banner,
minecraft:magenta_banner,
minecraft:magenta_wall_banner,
minecraft:light_blue_banner,
minecraft:light_blue_wall_banner,
minecraft:yellow_banner,
minecraft:yellow_wall_banner,
minecraft:lime_banner,
minecraft:lime_wall_banner,
minecraft:pink_banner,
minecraft:pink_wall_banner,
minecraft:gray_banner,
minecraft:gray_wall_banner,
minecraft:light_gray_banner,
minecraft:light_gray_wall_banner,
minecraft:cyan_banner,
minecraft:cyan_wall_banner,
minecraft:purple_banner,
minecraft:purple_wall_banner,
minecraft:blue_banner,
minecraft:blue_wall_banner,
minecraft:brown_banner,
minecraft:brown_wall_banner,
minecraft:green_banner,
minecraft:green_wall_banner,
minecraft:red_banner,
minecraft:red_wall_banner,
minecraft:black_banner,
minecraft:black_wall_banner
Blocks Placeable
minecraft:torch,
minecraft:wall_torch,
minecraft:soul_torch,
minecraft:soul_wall_torch
FAQS
Q: Will you make this for Fabric?
A: I will not be porting to Fabric, but anyone is welcome to do so! For Forge I will only be supporting 1.20.1 for now, and I will be porting this to NeoForge going forward on 1.21. From there I will stay on NeoForge, I don't have the time to manage too many different versions of this.
Q: Will you backport this to older Minecraft version?
A: Unless it sees a lot of interest I will only be developing on 1.20.1 and forward. The focus will be on 1.21.1 Neoforge.
Q: Can I use this on my server or modpack?
A: Of course!





