Fix DBC Turbo Bounceback in Liquid and Lava

This commit is contained in:
Kam committed 2026-02-21 04:41:14 -05:00
1 parent 0a6d9e1ef9
commit aa58cf8041
1 file changed
+8 -9
@@ -66,26 +66,25 @@ public class AbilityCharge extends AbilityMovement implements IAbilityCharge {
}
/**
* Called on the first tick of windup - lock direction here so it matches telegraph.
* During windup, NPCs face toward their target for animation purposes.
* Players aim freely — the telegraph follows their look direction on the client,
* and direction is locked at the end of windup in onExecute().
*/
@Override
public void onWindUpTick(EntityLivingBase caster, EntityLivingBase target, int tick) {
if (tick == 1) {
lockDirection(caster, target);
if (!isPlayerCaster(caster) && target != null) {
lockDirectionToTarget(caster, target);
enforceLockedRotation(caster);
}
enforceLockedRotation(caster);
}
@Override
public void onExecute(EntityLivingBase caster, EntityLivingBase target) {
// Lock final direction at end of windup so it matches the telegraph
lockDirection(caster, target);
initMovement(caster, maxRange, chargeSpeed);
hitEntities.clear();
// If direction wasn't set during windup (shouldn't happen), set it now
if (movementDirection == null) {
lockDirection(caster, target);
}
enforceLockedRotation(caster);
}