Fixed an issue with skill buffs not applying to mana & stamina for skill requirements

This commit is contained in:
Jules 2023-10-16 01:17:17 +02:00
parent eeaf13e2c0
commit 162f0cf3c4

View File

@ -108,13 +108,13 @@ public class AbilityData extends Skill {
return false;
// Check for mana cost
if (hasModifier("mana") && rpgPlayer.getMana() < getParameter("mana")) {
if (hasModifier("mana") && rpgPlayer.getMana() < meta.getParameter("mana")) {
Message.NOT_ENOUGH_MANA.format(ChatColor.RED).send(player);
return false;
}
// Check for stamina cost
if (hasModifier("stamina") && rpgPlayer.getStamina() < getParameter("stamina")) {
if (hasModifier("stamina") && rpgPlayer.getStamina() < meta.getParameter("stamina")) {
Message.NOT_ENOUGH_STAMINA.format(ChatColor.RED).send(player);
return false;
}