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 Killer Drive trait not liking murder, not prompting on cannibalism #2889

Merged
merged 1 commit into from
May 29, 2023

Conversation

chaosvolt
Copy link
Member

@chaosvolt chaosvolt commented May 26, 2023

Summary

SUMMARY: Bugfixes "Killer Drive now rewards for killing innocent NPCs, prompts before committing cannibalism"

Purpose of change

One annoyance I found was that Killer Drive clashed with the Psychopath trait, motivating you to kill but still prompting guilt when you kill an innocent NPC. It also had the flaw where the CANNIBAL trait flag would mark human flesh as safe to eat and fail to prompt you, but because the morale effect only looks for the Cannibal trait itself, you'd end up getting sad about it.

Describe the solution

C++ changes:

  1. In npc.cpp, set it so the check for inflicting morale from murdering an innoect NPC also excludes characters with the Killer Drive trait.
  2. Additionally, set it so killing NPCs counts as a kill for the sake of the Killer Drive morale effects. This is separate from the other morale effects because the if statement for guilt over murdering the innocent only checks if the NPC was considered innocent, when it logically should trigger on killing NPCs in general. Since NPC kills a a bit more special than regular kills, I set it to always print the kill enjoyment message, but kept the morale impact the same.

JSON changes:

  1. Switched Killer Drive to use the PSYCHOPATH trait flag. Its effects are buried in the code largely unused, but the key thing is it counts as identical to Cannibal and Sapiovore for the purpose of butchering human corpses, without flagging human flesh as being safe to eat (when it secretly isn't in the case of Killer Drive).

Describe alternatives you've considered

  1. Letting it count as Psychopath for the purpose of eating human flesh. I think it's probably good enough like this, allowing you to murder innocents and butcher them is plenty enough. It's Killer Drive after all, not Killer and Eater Drive. If the player wants to put their victims to good use afterward, the trait goes quite well with Cannibal.
  2. Conversely, making it so Killer Drive still penalizes you for butchering human corpses, so your focus is entirely on murder, and warranting the purchase of the Cannibal trait if you want to do anything fun with victims after the main event is finished.
  3. Allowing Killer Drive to dig up graves without penalty. Also probably out of focus for it I figure, and far more niche than other applications of Psychopath. Besides, gravedigging isn't killing, the victims have already been used up and tossed aside by the cataclysm at large.
  4. Making NPCs more fun to kill than monsters.

If we increased the overlap between Psychopath and Killer Drive, since it comes with morale for doing what the average Cata player will be doing by the dozen anyway, we're likely want to bump the point cost of Killer Drive up a bit. In its current form as of this PR, you get all of the murder-related benefits of Psychopath and have the option to spend an extra point to get a morale-increasing equivalent to the people-eating benefits, leaving only gravedigging absent.

Testing

  1. Checked affected JSON file for syntax and lint errors.
  2. Compiled and load-tested.
  3. Started up a world with Killer Drive.
  4. Spawned in an M2 Browning and debugged my skills to max.
  5. Tenderized the meat in my starting shelter.
  6. Enjoyed tenderizing the meat instead of hating it.
  7. Butchered the corpses without any sadness, observed the meat was nonetheless not good eatin's since didn't add the Cannibal trait.
  8. Tenderized a few more delicious friends, observed they always printed the happy message.
  9. Checked affected C++ file for astyle.

Additional context

The discovery of the PSYCHOPATH flag also gives me something I can use for Arcana, to allow sanguinist professions to always be okay with butchering corpses.

@github-actions github-actions bot added JSON related to game datas in JSON format. src changes related to source code. labels May 26, 2023
@chaosvolt chaosvolt changed the title Fix Killer Drive trait not liking murder, not prompting on nasty cann… Fix Killer Drive trait not liking murder, not prompting on cannibalism May 26, 2023
@scarf005 scarf005 self-assigned this May 27, 2023
Copy link
Member

@scarf005 scarf005 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image
image
Cataclysm: Bright Nights - cbn-experimental-2023-05-26-1006-1-g7a66091492d_01

works as intended.

@scarf005 scarf005 merged commit 9f1d96e into cataclysmbnteam:upload May 29, 2023
@chaosvolt chaosvolt deleted the killer-drive-goes-nyoom branch May 29, 2023 15:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
JSON related to game datas in JSON format. src changes related to source code.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants