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

Don't make NPC angry if he's already dead #55689

Merged
merged 3 commits into from
Mar 3, 2022
Merged

Don't make NPC angry if he's already dead #55689

merged 3 commits into from
Mar 3, 2022

Conversation

Night-Pryanik
Copy link

@Night-Pryanik Night-Pryanik commented Feb 26, 2022

Summary

Bugfixes "Don't make NPC angry if he's already dead"

Purpose of change

Describe the solution

  1. Don't make NPC angry at "target confirmed" phase of aiming ranged weapon.
  2. Instead, make him angry at "attack committed" phase, i.e. right after you fired your gun.
  3. Check for NPC being dead before making him angry.

Describe alternatives you've considered

None.

Testing

  1. Made a friendly follower. Obtained M4 carbine. Fired at the follower. He correctly got mad at me and resigned from my leadership.
    изображение

  2. Got Barrett. Fired at the follower. He was one-shot killed. No messages about NPC got angry or resignation because NPC is dead.
    изображение

Additional context

None.

@Night-Pryanik Night-Pryanik added NPC / Factions NPCs, AI, Speech, Factions, Ownership Info / User Interface Game - player communication, menus, etc. [C++] Changes (can be) made in C++. Previously named `Code` <Bugfix> This is a fix for a bug (or closes open issue) Ranged Ranged (firearms, bows, crossbows, throwing), balance, tactics labels Feb 26, 2022
@github-actions github-actions bot added json-styled JSON lint passed, label assigned by github actions astyled astyled PR, label is assigned by github actions BasicBuildPassed This PR builds correctly, label assigned by github actions labels Feb 26, 2022
@kevingranade kevingranade merged commit 3046771 into CleverRaven:master Mar 3, 2022
@Night-Pryanik Night-Pryanik deleted the dont-get-angry-if-youre-dead branch March 3, 2022 03:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
astyled astyled PR, label is assigned by github actions BasicBuildPassed This PR builds correctly, label assigned by github actions <Bugfix> This is a fix for a bug (or closes open issue) [C++] Changes (can be) made in C++. Previously named `Code` Info / User Interface Game - player communication, menus, etc. json-styled JSON lint passed, label assigned by github actions NPC / Factions NPCs, AI, Speech, Factions, Ownership Ranged Ranged (firearms, bows, crossbows, throwing), balance, tactics
Projects
None yet
Development

Successfully merging this pull request may close these issues.

NPCs declare their resignation after they were one-shot killed
2 participants