EssentialsX

EssentialsX

2M Downloads

Config option to allow unsafe enchantments via console.

mibby opened this issue ยท 6 comments

commented

Would it be possible to add a config option to allow unsafe enchantments with console commands? That way you could spawn in items via console with enchant parameters that go beyond vanilla minecraft but force in-game users to not be able to enchant past vanilla limits? Currently you can only set it one way or the other.

I'd like to be able to have automated commands run via console to reward users with protection 6 boots for example but not allow unsafe enchantments with in-game commands. To do so, I currently have to allow it for both because console doesn't override the enforcement.

commented

Already there. Search configuration for unsafe and you should find it.

commented

If I'm understanding this correctly, mibby is specifically asking for the unsafe-enchantments setting to stay false so that players in game can't create unsafe enchantments, but there is a permission that permits you to create unsafe-enchantments: essentials.enchantments.allowunsafe.

commented

@SupaHam But the console does not bypass the config check because there are no permissions tied to the direct console... I want to allow the console to create unsafe enchantments (through commands initiated from console for automated rewards) and not allow players in-game to.

commented

The console has all op permissions, so you could just set allow unsafe in config and negate the permission for players ingame.

commented

@mibby No one bypasses the config check. There's only a permission to permit players, it's not a bypass permission. So this means that, if the config option is not enabled, the feature is never enabled, if the config option is enabled, then only players with the essentials.enchantments.allowunsafe permission can use the feature. Does that make more sense?

commented

Ah, that makes much more sense. I thought the feature would be always enabled for console regardless of if the setting is set to false in the config. Thanks for clarifying.