elBukkit / PreciousStones

Self-service protection for Minecraft servers
http://dev.bukkit.org/server-mods/preciousstones/
10 stars 10 forks source link

Separate pressure plates, buttons, and levers from prevent-use-redstone #107

Open FireController1847 opened 3 years ago

FireController1847 commented 3 years ago

Thanks a ton for keeping this plugin maintained! I noticed the recent addition of prevent-use-redstone and I was eager to get started using it, but then I realized one major downside to it; while I could prevent players from modifying my repeaters and my note blocks, they couldn't press the button to get it started. Similarly, since I had it enabled by default, non-guest players were no longer able to use pressure plates to open doors.

I feel as though pressure plates, buttons, and levers are important enough to separate from the logical side of redstone, due to the fact that in many situations you only want to prevent the modification of your logic, not the initiation of your logic.

My proposal is one of two options:

  1. Add prevent-use-redstone-interactable

Though, I think option 1 may be a little confusing by its name, option two may be better:

  1. Add prevent-use-lever, prevent-use-button, and prevent-use-pressure-plate
xtomyserrax commented 3 years ago

Hey, how are you? Yeah the big problem of this is where should we put the end?

prevent-use is a list in which you can add any type of blocks you want to prevent outsiders from using. In the past this list was the only way to make this possible. So I decided to create this custom flags which would prevent the use of any types of doors or any types of redstone.

Adding more flags would be a mess, another idea would be to make prevent-use-doors and redstone configurable in the config file. But not sure

FireController1847 commented 3 years ago

Making it configurable is not a bad idea, though I am not sure it is necessarily the best solution. I cannot come up with any other solutions to this issue however :thinking: