mirror of
https://github.com/TotalFreedomMC/TF-EssentialsX.git
synced 2025-06-28 18:20:31 +00:00
[Feature] Adds meta permissions
TL MetaItemStack.java Some meta cleanup Parameter refactor for clarity Full list of added perms http://goo.gl/do1XL
This commit is contained in:
parent
292f8a8799
commit
4aaf0eda79
17 changed files with 190 additions and 40 deletions
|
@ -118,6 +118,10 @@ public class Commandfirework extends EssentialsCommand
|
|||
{
|
||||
FireworkMeta fmeta = (FireworkMeta)mStack.getItemStack().getItemMeta();
|
||||
FireworkEffect effect = mStack.getFireworkBuilder().build();
|
||||
if (fmeta.getEffects().size() > 0 && !user.isAuthorized("essentials.firework.multiple"))
|
||||
{
|
||||
throw new Exception(_("multipleCharges"));
|
||||
}
|
||||
fmeta.addEffect(effect);
|
||||
stack.setItemMeta(fmeta);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue