mirror of
https://github.com/Sollace/Unicopia.git
synced 2024-11-23 21:38:00 +01:00
Fixed catapult spell constantly refiring when cast using the regular cast spell ability instead of shoot spell
This commit is contained in:
parent
f3d251c1d0
commit
a8e5c50e9b
3 changed files with 4 additions and 3 deletions
|
@ -59,7 +59,8 @@ public class CatapultSpell extends AbstractSpell implements ProjectileDelegate.B
|
|||
}
|
||||
|
||||
getTypeAndTraits().create().toThrowable().throwProjectile(caster);
|
||||
return false;
|
||||
setDead();
|
||||
return isDead();
|
||||
}
|
||||
|
||||
protected void apply(Caster<?> caster, Entity e) {
|
||||
|
|
|
@ -23,7 +23,7 @@ public class ChillingBreathSpell extends AbstractSpell implements HomingSpell {
|
|||
if (!source.subtractEnergyCost(90)) {
|
||||
setDead();
|
||||
}
|
||||
return false;
|
||||
return !isDead();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -170,7 +170,7 @@ public class MagicProjectileEntity extends ThrownItemEntity implements Caster<Ma
|
|||
@Override
|
||||
public void tick() {
|
||||
if (!world.isClient() && !homingTarget.isPresent(world)) {
|
||||
if (getVelocity().length() < 0.01) {
|
||||
if (getVelocity().length() < 0.1 || age > 90) {
|
||||
discard();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue