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

Withdrawals are distracting #75261

Merged
merged 7 commits into from
Jul 27, 2024

Conversation

Consoleable
Copy link
Contributor

@Consoleable Consoleable commented Jul 26, 2024

Summary

Interface "Addiction withdrawals are a toggleable distraction"

Purpose of change

Addictions have been annoying because withdrawals can reduce your stats while working on some long-term task, infinitely extending the task as you suffer more withdrawals while trying to complete it. The addiction system in game asks you to satsfy it but doesnt stop you from passing out trying to practice some activity. Despite causing distracting pain, there has been no distraction to interrupt or notify you. Unlike asthma etc.

Describe the solution

Now, you can enable/disable withdrawals as a distraction, meaning they will stop your activity before your character gets horrible withdrawal symptoms, giving you a means to address them. RPing a junkie has never been easier! If the distraction messages get annoying, you can ignore them or toggle them off in the distractions menu. Fixes Issue #75195

Describe alternatives you've considered

Auto-consuming drugs, which i'm still working on.

Testing

Tested in basic build, seems to work great.

Additional context

added withdrawal distraction to manager
added distraction_withdrawal
depluralize withdrawal
add withdrawal interrupt to suffer.cpp
added withdrawal as a distraction type
addd withdrawal to activity type
@Consoleable Consoleable changed the title Withdrawals are distraction Withdrawals are distracting Jul 26, 2024
@Consoleable Consoleable marked this pull request as ready for review July 26, 2024 22:25
@github-actions github-actions bot added <Bugfix> This is a fix for a bug (or closes open issue) Info / User Interface Game - player communication, menus, etc. [C++] Changes (can be) made in C++. Previously named `Code` labels Jul 26, 2024
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
@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 Jul 26, 2024
@Maleclypse Maleclypse merged commit b9b3f3f into CleverRaven:master Jul 27, 2024
19 of 26 checks passed
@Consoleable Consoleable deleted the addictions-are-distracting branch July 27, 2024 02:46
@Maleclypse
Copy link
Member

Just noticed there appears to be a clang tidy warning that was missed before I merged this. If you look at other PRs clang tests after this merged I’m seeing a couple mentions of withdrawal distractions.

@Consoleable
Copy link
Contributor Author

Just noticed there appears to be a clang tidy warning that was missed before I merged this. If you look at other PRs clang tests after this merged I’m seeing a couple mentions of withdrawal distractions.

Oh shit, really? I'll take a look and upload a fix if i can figure it out on my own.

@Consoleable
Copy link
Contributor Author

Just noticed there appears to be a clang tidy warning that was missed before I merged this. If you look at other PRs clang tests after this merged I’m seeing a couple mentions of withdrawal distractions.

So if i'm understanding this right, clang's saying that there's no test set up for it, but it should have one? So I should add this uistate option to one of the clang tests so it knows how to toggle it for automated testing? So it's not so much that there's a bug, it's that there's a feature missing for testing, and it's a problem that the feature isn't there?
Am I understanding this right?

@Consoleable
Copy link
Contributor Author

Afaik all the other PRs are running versions from before this PR. I think what's going on is the UI is trying to load in distraction_withdrawla from jsons that dont have it because they were made earlier. I will check later to see if this is still happening. If anyone knows let me know if i'm wrong. I'm happy to try and fix this if it isn't just a quirk of the game updating.

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
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants