Storage Drawers: Natura Pack

Storage Drawers: Natura Pack

9M Downloads

[Issue] StorageDrawers do not respect GriefPrevention claims or similar protection plugins

chaosblad3 opened this issue ยท 7 comments

commented

I only have limited coding experience, but from what I can tell you are not registering an interruptible event when a player tries to take an item out of a drawer which means that anti-theft protection plugins like GriefPrevention are not able to block that event when the player is not "trusted" in the "claim" the drawer is in, this unfortunately makes drawers very easy to steal from on multiplayer servers, where GP would otherwise be able to prevent it by cancelling the interaction if the player is not trusted, as it does with things like Factorization/JABBA barrels and pretty much all types of chests.

commented

See: #62

The resolution is that I fire the PlayerInteractEvent manually in the server click handler (https://github.com/jaquadro/StorageDrawers/blob/master/src/com/jaquadro/minecraft/storagedrawers/block/BlockDrawers.java#L362).

If that's not sufficient, then I don't think there's anything I can do. Being able to click different areas of the block face (for multiple drawer slots) means I can't use the same codepaths as JABBA.

commented

Ahh I'm sorry I didn't realize SirWilli had already posted about this (he is one of the two owners of the network im an admin on), but no, sadly they are still not respecting GP in the slightest on any of our servers.

commented

I was pretty sure this was fixed on our regrowth server on 1.6.2 or a few versions below, but it is not anymore. :-(
See #62 for more detail.

commented

Would it be possible to make a command (with permissions ;)) where the player have ability to add another player to their "trustlist" (a bit like the tesseracts from Thermal Expansion)

commented

Since I don't know how to get this definitively solved, I'm including an alternate solution in the next update.

I've added a third key type to protect drawers by binding them to an owner. Only the owner can insert/remove/modify. It's not bulletproof on its own since someone could still break the drawers or hook up external machines to them, but my assumption is the existing grief protection will be able to handle that.

commented

What if I added an optional integration with Thermal Foundation? Wrap up the key in signalum, and it will use the CoFH trust list instead of being owner-private?

commented

Personal keys have been released with the mod. The CoFH variant, if you have Thermal Foundation present, will allow sharing access with friends.