-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
Disease infrastructure #35843
Merged
Merged
Disease infrastructure #35843
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Thank you for doing this! I look forward to using it to rework water-borne pathogens. |
ZhilkinSerg
added
0.E Feature Freeze
[C++]
Changes (can be) made in C++. Previously named `Code`
[JSON]
Changes (can be) made in JSON
Mechanics: Character / Player
Character / Player mechanics
Mechanics: Effects / Skills / Stats
Effects / Skills / Stats
labels
Dec 4, 2019
Co-Authored-By: Anton Burmistrov <Night_Pryanik@mail.ru>
kevingranade
reviewed
Apr 2, 2020
src/character.h
Outdated
@@ -21,6 +21,7 @@ | |||
#include "character_id.h" | |||
#include "character_martial_arts.h" | |||
#include "creature.h" | |||
#include "disease.h" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No need to include this here, it needs to be in character.cpp and consumption.cpp
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
[C++]
Changes (can be) made in C++. Previously named `Code`
[JSON]
Changes (can be) made in JSON
Mechanics: Character / Player
Character / Player mechanics
Mechanics: Effects / Skills / Stats
Effects / Skills / Stats
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
SUMMARY: Infrastructure "Add basic infrastructure for diseases"
Purpose of change
Add basic infrastructure to define diseases
Add a system for foodborne disease, improved from #35829
Describe the solution
disease_type
expose_to_disease()
function to CharacterDescribe alternatives you've considered
Testing
Drink gallon jug of raw milk
Get sick after drinking 2/3 of it
Put health to 100
Drink gallon jug
No sickness
Mispell bad_food in raw_milk definition
Get error on load
Additional context
This is a very basic implementation, it only affect food contamination and is only used by raw milk currently
It could be expended to other disease and health could affect the probability to get and sick and the intensity of the effects instead of being an on/off threshold.