Fixed AbnormalShield effect related formulas.

This commit is contained in:
MobiusDev
2019-01-12 07:57:16 +00:00
parent 89d8e11288
commit 0597899192
10 changed files with 90 additions and 150 deletions

View File

@@ -595,10 +595,7 @@ public final class Formulas
{ {
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
return false; return false;
} }
} }
@@ -637,19 +634,19 @@ public final class Formulas
{ {
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
resisted = true; resisted = true;
} }
} }
if (!resisted)
{
final double sphericBarrierRange = target.getStat().getValue(Stats.SPHERIC_BARRIER_RANGE, 0); final double sphericBarrierRange = target.getStat().getValue(Stats.SPHERIC_BARRIER_RANGE, 0);
if (!resisted && (sphericBarrierRange > 0)) if (sphericBarrierRange > 0)
{ {
resisted = attacker.calculateDistance3D(target) > sphericBarrierRange; resisted = attacker.calculateDistance3D(target) > sphericBarrierRange;
} }
}
if (resisted) if (resisted)
{ {
@@ -704,10 +701,7 @@ public final class Formulas
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
return false; return false;
} }
} }

View File

@@ -595,10 +595,7 @@ public final class Formulas
{ {
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
return false; return false;
} }
} }
@@ -637,19 +634,19 @@ public final class Formulas
{ {
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
resisted = true; resisted = true;
} }
} }
if (!resisted)
{
final double sphericBarrierRange = target.getStat().getValue(Stats.SPHERIC_BARRIER_RANGE, 0); final double sphericBarrierRange = target.getStat().getValue(Stats.SPHERIC_BARRIER_RANGE, 0);
if (!resisted && (sphericBarrierRange > 0)) if (sphericBarrierRange > 0)
{ {
resisted = attacker.calculateDistance3D(target) > sphericBarrierRange; resisted = attacker.calculateDistance3D(target) > sphericBarrierRange;
} }
}
if (resisted) if (resisted)
{ {
@@ -704,10 +701,7 @@ public final class Formulas
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
return false; return false;
} }
} }

View File

@@ -595,10 +595,7 @@ public final class Formulas
{ {
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
return false; return false;
} }
} }
@@ -637,19 +634,19 @@ public final class Formulas
{ {
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
resisted = true; resisted = true;
} }
} }
if (!resisted)
{
final double sphericBarrierRange = target.getStat().getValue(Stats.SPHERIC_BARRIER_RANGE, 0); final double sphericBarrierRange = target.getStat().getValue(Stats.SPHERIC_BARRIER_RANGE, 0);
if (!resisted && (sphericBarrierRange > 0)) if (sphericBarrierRange > 0)
{ {
resisted = attacker.calculateDistance3D(target) > sphericBarrierRange; resisted = attacker.calculateDistance3D(target) > sphericBarrierRange;
} }
}
if (resisted) if (resisted)
{ {
@@ -704,10 +701,7 @@ public final class Formulas
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
return false; return false;
} }
} }

View File

@@ -595,10 +595,7 @@ public final class Formulas
{ {
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
return false; return false;
} }
} }
@@ -637,19 +634,19 @@ public final class Formulas
{ {
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
resisted = true; resisted = true;
} }
} }
if (!resisted)
{
final double sphericBarrierRange = target.getStat().getValue(Stats.SPHERIC_BARRIER_RANGE, 0); final double sphericBarrierRange = target.getStat().getValue(Stats.SPHERIC_BARRIER_RANGE, 0);
if (!resisted && (sphericBarrierRange > 0)) if (sphericBarrierRange > 0)
{ {
resisted = attacker.calculateDistance3D(target) > sphericBarrierRange; resisted = attacker.calculateDistance3D(target) > sphericBarrierRange;
} }
}
if (resisted) if (resisted)
{ {
@@ -704,10 +701,7 @@ public final class Formulas
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
return false; return false;
} }
} }

View File

@@ -595,10 +595,7 @@ public final class Formulas
{ {
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
return false; return false;
} }
} }
@@ -637,19 +634,19 @@ public final class Formulas
{ {
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
resisted = true; resisted = true;
} }
} }
if (!resisted)
{
final double sphericBarrierRange = target.getStat().getValue(Stats.SPHERIC_BARRIER_RANGE, 0); final double sphericBarrierRange = target.getStat().getValue(Stats.SPHERIC_BARRIER_RANGE, 0);
if (!resisted && (sphericBarrierRange > 0)) if (sphericBarrierRange > 0)
{ {
resisted = attacker.calculateDistance3D(target) > sphericBarrierRange; resisted = attacker.calculateDistance3D(target) > sphericBarrierRange;
} }
}
if (resisted) if (resisted)
{ {
@@ -704,10 +701,7 @@ public final class Formulas
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
return false; return false;
} }
} }

View File

@@ -595,10 +595,7 @@ public final class Formulas
{ {
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
return false; return false;
} }
} }
@@ -637,19 +634,19 @@ public final class Formulas
{ {
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
resisted = true; resisted = true;
} }
} }
if (!resisted)
{
final double sphericBarrierRange = target.getStat().getValue(Stats.SPHERIC_BARRIER_RANGE, 0); final double sphericBarrierRange = target.getStat().getValue(Stats.SPHERIC_BARRIER_RANGE, 0);
if (!resisted && (sphericBarrierRange > 0)) if (sphericBarrierRange > 0)
{ {
resisted = attacker.calculateDistance3D(target) > sphericBarrierRange; resisted = attacker.calculateDistance3D(target) > sphericBarrierRange;
} }
}
if (resisted) if (resisted)
{ {
@@ -704,10 +701,7 @@ public final class Formulas
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
return false; return false;
} }
} }

View File

@@ -595,10 +595,7 @@ public final class Formulas
{ {
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
return false; return false;
} }
} }
@@ -637,19 +634,19 @@ public final class Formulas
{ {
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
resisted = true; resisted = true;
} }
} }
if (!resisted)
{
final double sphericBarrierRange = target.getStat().getValue(Stats.SPHERIC_BARRIER_RANGE, 0); final double sphericBarrierRange = target.getStat().getValue(Stats.SPHERIC_BARRIER_RANGE, 0);
if (!resisted && (sphericBarrierRange > 0)) if (sphericBarrierRange > 0)
{ {
resisted = attacker.calculateDistance3D(target) > sphericBarrierRange; resisted = attacker.calculateDistance3D(target) > sphericBarrierRange;
} }
}
if (resisted) if (resisted)
{ {
@@ -704,10 +701,7 @@ public final class Formulas
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
return false; return false;
} }
} }

View File

@@ -595,10 +595,7 @@ public final class Formulas
{ {
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
return false; return false;
} }
} }
@@ -637,19 +634,19 @@ public final class Formulas
{ {
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
resisted = true; resisted = true;
} }
} }
if (!resisted)
{
final double sphericBarrierRange = target.getStat().getValue(Stats.SPHERIC_BARRIER_RANGE, 0); final double sphericBarrierRange = target.getStat().getValue(Stats.SPHERIC_BARRIER_RANGE, 0);
if (!resisted && (sphericBarrierRange > 0)) if (sphericBarrierRange > 0)
{ {
resisted = attacker.calculateDistance3D(target) > sphericBarrierRange; resisted = attacker.calculateDistance3D(target) > sphericBarrierRange;
} }
}
if (resisted) if (resisted)
{ {
@@ -704,10 +701,7 @@ public final class Formulas
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
return false; return false;
} }
} }

View File

@@ -595,10 +595,7 @@ public final class Formulas
{ {
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
return false; return false;
} }
} }
@@ -637,19 +634,19 @@ public final class Formulas
{ {
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
resisted = true; resisted = true;
} }
} }
if (!resisted)
{
final double sphericBarrierRange = target.getStat().getValue(Stats.SPHERIC_BARRIER_RANGE, 0); final double sphericBarrierRange = target.getStat().getValue(Stats.SPHERIC_BARRIER_RANGE, 0);
if (!resisted && (sphericBarrierRange > 0)) if (sphericBarrierRange > 0)
{ {
resisted = attacker.calculateDistance3D(target) > sphericBarrierRange; resisted = attacker.calculateDistance3D(target) > sphericBarrierRange;
} }
}
if (resisted) if (resisted)
{ {
@@ -704,10 +701,7 @@ public final class Formulas
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
return false; return false;
} }
} }

View File

@@ -595,10 +595,7 @@ public final class Formulas
{ {
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
return false; return false;
} }
} }
@@ -637,19 +634,19 @@ public final class Formulas
{ {
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
resisted = true; resisted = true;
} }
} }
if (!resisted)
{
final double sphericBarrierRange = target.getStat().getValue(Stats.SPHERIC_BARRIER_RANGE, 0); final double sphericBarrierRange = target.getStat().getValue(Stats.SPHERIC_BARRIER_RANGE, 0);
if (!resisted && (sphericBarrierRange > 0)) if (sphericBarrierRange > 0)
{ {
resisted = attacker.calculateDistance3D(target) > sphericBarrierRange; resisted = attacker.calculateDistance3D(target) > sphericBarrierRange;
} }
}
if (resisted) if (resisted)
{ {
@@ -704,10 +701,7 @@ public final class Formulas
if (target.getAbnormalShieldBlocks() > 0) if (target.getAbnormalShieldBlocks() > 0)
{ {
if (target.decrementAbnormalShieldBlocks() == 0) target.decrementAbnormalShieldBlocks();
{
target.stopEffects(EffectFlag.ABNORMAL_SHIELD);
}
return false; return false;
} }
} }