Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix free counters #44533

Merged
merged 3 commits into from
Oct 2, 2020
Merged

Conversation

kevingranade
Copy link
Member

Summary

SUMMARY: None

Purpose of change

Counter techniques have had a hack applied for years setting their move cost to 0 to avoid having the player stunlock themselves when countering.
See #15101
#25859

Describe the solution

Remove the hack and replace it with a guard that prevents a player from stun locking themselves with counters by not selecting a counter if using it would result in the character skipping their next turn.

Describe alternatives you've considered

Some of these counters probably deserve a move cost multiplier as per typical attacks of their style, but I'm not well versed enough in the styles to make that determination, so if that happens it needs to be in a follow up PR.

Testing

Spawn a skilled character with a martial art that grants a counter and hang out near some attacking enemies. Player should be able to act every turn and occasionally fire off counters.
Do the same but with a character with impaired speed.

src/melee.cpp Outdated Show resolved Hide resolved
@ZhilkinSerg ZhilkinSerg merged commit e49eaa0 into CleverRaven:master Oct 2, 2020
@anothersimulacrum anothersimulacrum added <Bugfix> This is a fix for a bug (or closes open issue) [C++] Changes (can be) made in C++. Previously named `Code` Melee Melee weapons, tactics, techniques, reach attack labels Nov 8, 2020
@kevingranade kevingranade deleted the fix-free-counters branch November 20, 2020 03:40
@Hymore246 Hymore246 mentioned this pull request Sep 28, 2021
15 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
<Bugfix> This is a fix for a bug (or closes open issue) [C++] Changes (can be) made in C++. Previously named `Code` Melee Melee weapons, tactics, techniques, reach attack
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants