v3.2.0: fixed new thrown weapon delay change triggering on aim pos
This commit is contained in:
@@ -646,7 +646,7 @@ public class Item implements Bundlable {
|
|||||||
Char enemy = Actor.findChar( cell );
|
Char enemy = Actor.findChar( cell );
|
||||||
QuickSlotButton.target(enemy);
|
QuickSlotButton.target(enemy);
|
||||||
|
|
||||||
final float delay = castDelay(user, dst);
|
final float delay = castDelay(user, cell);
|
||||||
|
|
||||||
if (enemy != null) {
|
if (enemy != null) {
|
||||||
((MissileSprite) user.sprite.parent.recycle(MissileSprite.class)).
|
((MissileSprite) user.sprite.parent.recycle(MissileSprite.class)).
|
||||||
@@ -694,7 +694,7 @@ public class Item implements Bundlable {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public float castDelay( Char user, int dst ){
|
public float castDelay( Char user, int cell ){
|
||||||
return TIME_TO_THROW;
|
return TIME_TO_THROW;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -387,7 +387,7 @@ public class SpiritBow extends Weapon {
|
|||||||
user.buff(Talent.LethalMomentumTracker.class).detach();
|
user.buff(Talent.LethalMomentumTracker.class).detach();
|
||||||
user.next();
|
user.next();
|
||||||
} else {
|
} else {
|
||||||
user.spendAndNext(castDelay(user, dst));
|
user.spendAndNext(castDelay(user, cell));
|
||||||
}
|
}
|
||||||
sniperSpecial = false;
|
sniperSpecial = false;
|
||||||
flurryCount = -1;
|
flurryCount = -1;
|
||||||
@@ -442,7 +442,7 @@ public class SpiritBow extends Weapon {
|
|||||||
user.buff(Talent.LethalMomentumTracker.class).detach();
|
user.buff(Talent.LethalMomentumTracker.class).detach();
|
||||||
user.next();
|
user.next();
|
||||||
} else {
|
} else {
|
||||||
user.spendAndNext(castDelay(user, dst));
|
user.spendAndNext(castDelay(user, cell));
|
||||||
}
|
}
|
||||||
sniperSpecial = false;
|
sniperSpecial = false;
|
||||||
flurryCount = -1;
|
flurryCount = -1;
|
||||||
|
|||||||
@@ -59,12 +59,12 @@ public class ForceCube extends MissileWeapon {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public float castDelay(Char user, int dst) {
|
public float castDelay(Char user, int cell) {
|
||||||
//special rules as throwing this onto empty space or yourself does trigger it
|
//special rules as throwing this onto empty space or yourself does trigger it
|
||||||
if (!Dungeon.level.pit[dst] && Actor.findChar(dst) == null){
|
if (!Dungeon.level.pit[cell] && Actor.findChar(cell) == null){
|
||||||
return delayFactor( user );
|
return delayFactor( user );
|
||||||
} else {
|
} else {
|
||||||
return super.castDelay(user, dst);
|
return super.castDelay(user, cell);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -391,12 +391,11 @@ abstract public class MissileWeapon extends Weapon {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public float castDelay(Char user, int dst) {
|
public float castDelay(Char user, int cell) {
|
||||||
if (Actor.findChar(dst) != null && Actor.findChar(dst) != user){
|
if (Actor.findChar(cell) != null && Actor.findChar(cell) != user){
|
||||||
//TODO force cube
|
|
||||||
return delayFactor( user );
|
return delayFactor( user );
|
||||||
} else {
|
} else {
|
||||||
return super.castDelay(user, dst);
|
return super.castDelay(user, cell);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user