Configure blocks to be unbreakable under certain conditions. Compatible with Waystones.
This mod adds configurable rules for controlling whether a block can be broken. Rules allow for granular control through conditions and even modifiers (such as costing xp or items). This mod does not enable any unbreakable rules by default. Modpack developers or server owners must configure the mod, e.g. by enabling the "waystones:generated_waystones" ruleset. This mod is useless unless configured by a modpack or server owner.
Modpack developers or server owners must configure this mod in order for it to be useful.
That means either configuring rules in the config file or enabling an inbuilt ruleset. Mods or datapack developers can also provide rulesets through a datapack by providing a "data/yourpack/unbreakables/yourruleset.json" file.
rulesets = [ "waystones:generated_waystones" ]
rules = [ "[is_tag(waystones:waystones), is_not_state(origin, player)] refuse($chat.waystones.cannot_break_waystone)" ]
rules = [ "[is_in_dimension(minecraft:the_nether)] refuse(You cannot break blocks in the Nether)", "[is_block(minecraft:dirt)] refuse(You cannot break dirt)", "[is_state(lit, true)] refuse(You cannot break lit furnaces)" ]
{
"rules": [
"[is_tag(waystones:waystones), is_not_state(origin, player)] refuse($chat.waystones.cannot_break_waystone)"
]
}
Datapack rulesets must be enabled through the "ruleset" config option (see above).