Condition overhaul completed

This commit is contained in:
Vidal committed 2026-02-20 21:36:08 -03:00
1 parent a2e0bb50b9
commit 89e87b7656
9 files changed
+290 -292

No files matched your search

@@ -1233,6 +1233,7 @@ public abstract class Ability implements IAbility, IAbilityAction {
public boolean checkConditions(EntityLivingBase caster, EntityLivingBase target) {
for (AbilityCondition c : conditions) {
if (!c.getUserType().allowsNpc()) continue;
if (!c.check(caster, target)) return false;
}
return true;
@@ -1243,6 +1244,7 @@ public abstract class Ability implements IAbility, IAbilityAction {
*/
public boolean checkConditionsForPlayer(EntityLivingBase caster) {
for (AbilityCondition c : conditions) {
if (!c.getUserType().allowsPlayer()) continue;
if (c.requiresTarget()) continue;
if (!c.check(caster, null)) return false;
}