Fixed spiritshots being charged late causing skills casted without speed bonus.

Contributed by Sahar.
This commit is contained in:
MobiusDevelopment
2019-09-27 21:34:08 +00:00
parent 8742f26b09
commit d571c1943c

View File

@@ -5542,6 +5542,12 @@ public abstract class Creature extends WorldObject implements ISkillsHolder, IDe
_skillCast = null; _skillCast = null;
_castInterruptTime = 0; _castInterruptTime = 0;
// On each repeat recharge shots before cast.
if (mut.getCount() > 0)
{
rechargeShots(mut.getSkill().useSoulShot(), mut.getSkill().useSpiritShot());
}
// Stop casting // Stop casting
setIsCastingNow(false); setIsCastingNow(false);
setIsCastingSimultaneouslyNow(false); setIsCastingSimultaneouslyNow(false);
@@ -5549,12 +5555,6 @@ public abstract class Creature extends WorldObject implements ISkillsHolder, IDe
final Skill skill = mut.getSkill(); final Skill skill = mut.getSkill();
final WorldObject target = mut.getTargets().length > 0 ? mut.getTargets()[0] : null; final WorldObject target = mut.getTargets().length > 0 ? mut.getTargets()[0] : null;
// On each repeat recharge shots before cast.
if (mut.getCount() > 0)
{
rechargeShots(mut.getSkill().useSoulShot(), mut.getSkill().useSpiritShot());
}
// Attack target after skill use // Attack target after skill use
if ((skill.nextActionIsAttack()) && (_target != this) && (target != null) && (_target == target) && _target.isCreature() && target.canBeAttacked()) if ((skill.nextActionIsAttack()) && (_target != this) && (target != null) && (_target == target) && _target.isCreature() && target.canBeAttacked())
{ {