Siguza / VirtualPack

Bukkit Plugin "VirtualPack"
http://dev.bukkit.org/bukkit-plugins/virtualpack/
7 stars 10 forks source link

Permission node issues. #11

Closed mibby closed 10 years ago

mibby commented 10 years ago

@Siguza

When I negate the following two permission nodes for my Admin group, it outputs 'You're not allowed to use the anvil/enchantment table.'

    - -vpack.use.enchanttable.free
    - -vpack.use.anvil.free

In other words, I am unable to block the ability for my Admins to use both the enchantment table and anvil for free. If I block those permission nodes, they are unable to use the virtual items in general.

I believe this is because you have the base permission for each listed as a child permission under the 'free' nodes. So if you negate the parent permission 'vpack.use.enchanttable.free', it negates the base permission that allows you to even use the virtual tool.

https://github.com/Siguza/VirtualPack/blob/master/src/main/resources/plugin.yml#L56 https://github.com/Siguza/VirtualPack/blob/master/src/main/resources/plugin.yml#L71

Siguza commented 10 years ago

You should be able to work around this by putting the permissions this way:

- vpack.use.enchanttable
- vpack.use.anvil
- -vpack.use.enchanttable.free
- -vpack.use.enchanttable.free
- <rest>

If I'm wrong and this is not possible, I will make changes to the permissions.

mibby commented 10 years ago

I find that unnecessary though. Redundant to add more permission nodes to fix invalid logic in the plugin.yml. The permission nodes for .free should be feature permissions, not permissions to allow the function or not.

That being said, if you have no intentions in changing it, I can edit the plugin.yml myself every update. Not a big deal.