Skip to content

[HL2MP] Make melee cooldown prediction deterministic - #2051

Open
speedvoltage wants to merge 1 commit into
ValveSoftware:masterfrom
speedvoltage:fix/prediction-melee-cooldowns
Open

[HL2MP] Make melee cooldown prediction deterministic#2051
speedvoltage wants to merge 1 commit into
ValveSoftware:masterfrom
speedvoltage:fix/prediction-melee-cooldowns

Conversation

@speedvoltage

Copy link
Copy Markdown
Contributor

Issue:

HL2MP melee weapons schedule their primary attack from GetFireRate() but their secondary attack from SequenceDuration(). Hit and miss animation state can differ between client prediction and the lag-compensated server, causing their attack deadlines to diverge.

Fix:

Use one GetFireRate() deadline for primary attack, secondary attack, and weapon idle timing.

Use one fire-rate deadline for primary, secondary, and idle timing. Cooldowns no longer depend on hit or miss animations that can differ under lag compensation.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant