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

Some simple remedies for remedies: Basic pharmaceutical expansions #53152

Open
I-am-Erk opened this issue Dec 1, 2021 · 20 comments
Open

Some simple remedies for remedies: Basic pharmaceutical expansions #53152

I-am-Erk opened this issue Dec 1, 2021 · 20 comments
Labels
[C++] Changes (can be) made in C++. Previously named `Code` <Enhancement / Feature> New features, or enhancements on existing Items: Food / Vitamins Comestibles and drinks Items / Item Actions / Item Qualities Items and how they work and interact [JSON] Changes (can be) made in JSON (P4 - Low) Low priority issues: things which are e.g exotic, minor and/or hard to encounter <Suggestion / Discussion> Talk it out before implementing

Comments

@I-am-Erk
Copy link
Member

I-am-Erk commented Dec 1, 2021

Is your feature request related to a problem? Please describe.

I've been pushing for an expansion of available and existing pharmaceuticals in game for a while, but keep writing it up as too extensive a project. I'm going to propose some smaller, more attainable solutions to get a few more drugs in game, and fix the ones we have.

Solution you would like.

I've written out some changes that could be made, mostly to existing drugs in game, but also a few additions. Most of these changes are fairly simple to do. I may come back and add some numbers when I am at liberty to see what our current doses are and suggest good ones.

I do not recommend doing this all in one PR. This is an overarching to-do list. Any bullet point on this list could be a single small PR in itself... please link that PR back to this one and I'll try to cross stuff off as it's done.

New stats we should add: See #53141 for more information on why this is needed.

blood pressure: We should track player blood pressure behind the scenes. Rather than storing it as an actual BP number, we should probably store it as a "percent of player normal" value, so maybe normal is 100, 200ish is deadly elevated, and 0 is dead. Then, when we add ways to measure blood pressure, we can translate that in-game number to an appropriate systolic/diastolic value, where we can easily modify it with mutations and other things for flavour.

  • At extremely high levels, this might cause headaches and blurred vision, and at critical levels should cause dizziness, hallucinations, discoordination and then death. It should be very hard to get it to critical levels.
  • At extremely low levels, you should get dizzy, weak, stunned, and then pass out.
  • On a first pass creation, we should just have this sit comfortably at a safe zone unless modified with meds, later on we can make pain and blood loss and things affect it. Also, lying prone or being knocked down should mitigate the effects of low pressure.

heart rate: As with blood pressure we should store this as "percent of what is normal for player", not as "heart rate in BPM".

  • severely elevated heart rate should cause chest pain, anxiety (depicted as a dropped morale and messages in the status display), and reduced focus, and eventually could lapse into arrhythmia, which will almost always mean death.
  • severely lowered heart rate should decrease blood pressure and cause symptoms related to that.
  • Eventually we should have interactions between heart rate and blood pressure, so if your pressure drops eg. due to blood loss, your heart rate attempts to rise to compensate, and a rising heart rate should increase your blood pressure.

Respiratory rate: Again, store this as a percentage of normal. This one is a bit more complex than the other two, and we might consider instead having a stat like "oxygenation efficiency" which actually controls the downstream effects, where respiratory rate is just one of a few variables that impacts it. That could all be done later, though: we could just start with an RR stat so that opioids can have the desired effect.

  • lowered resp rate decreases stamina regeneration and eventually causes stamina loss. if your stamina runs out due to resp rate decrease, you aren't breathing anymore. This can cause problems.
  • Increased resp rate increases stamina regeneration slightly at first, and then causes dizziness and can make you faint. If it's drug induced and you don't stop when you faint, you may die from acidosis.

There are many more such hidden stats we can add, and interactions between them, but these would be a very good starting point to allow some more drug effects.

1. Stimulants

Existing stimulants need more effects:

  • all stimulants should give a flat increase to focus regeneration independent of morale.
  • simulants should increase heart rate a lot, and blood pressure a little.
  • Withdrawal may decrease heart rate and bp.
  • Should cause shaking hands both with use and withdrawal.
  • Cause stomach upset (heartburn specifically) at medium to high doses.
  • Should give a morale boost, but for most stimulants (eg caffeine, adderall) taht shouldn't be significant until high doses
  • Reduce fatigue, hunger, and weariness significantly - both the reported symptoms and any effect they have.
  • increase stamina regeneration
  • at higher (excessive/recreational) doses, stimulants should reduce the rate of XP gain across the board, offsetting the focus boost but in a non-obvious way (you feel very focused indeed!). At these levels the morale bonus should also increase.

2. Opioids

All opioids should:

  • give a significant morale boost that declines with extended use
  • decrease focus
  • decrease blood pressure and heart rate slightly
  • decrease respiratory rate - this is generally how they kill you
  • increased fatigue and weariness, decrease stamina regeneration
  • decreases hunger
    Withdrawal should:
  • increase hunger
  • increase pain
  • increase blood pressure and heart rate
  • cause nausea and vomiting
  • make you absolutely miserable in a way that is hard to even comprehend

3. Marijuana

Marijuana is a weird one.

  • It should mildly reduce pain
  • it should increase morale and decrease focus
  • increase hunger, mildly increase fatigue
  • forgetfulness: reduce xp gain boost due to difference between knowledge and practical skill. At high doses may reduce knowledge levels temporarily.

I would (in all seriousness) suggest giving marijuana a special effect that intersperses happy faces in the message log, more and more often as the dose increases.

You hit :) the zombie for :) 10 damage
The zombie falls over :)

We might consider a few other changes to message display in this vein, but I would be careful to overdo it. At the very least, perhaps we could very occasionally finish log messages with an extra "woah."

"You shut off :) the compact car's engine. Woah."

4. Antidepressants

Antidepressant medications should be totally different. I don't think anyone has changed 'prozac' in some time, but the existing med should pretty much just be thrown out, as it bears no resemblance to real medications.

  • Antidepressants should work very slowly, and might be better implemented with the vitamin system. You need to keep a therapeutic dose of antidepressant in your system for about 2 weeks before effects develop, and effects should max out at 4 weeks. Managing it as a vitamin would be a good way to track whether or not you're at a therapeutic dose, as that vitamin level could drop and increase over several days rather than as soon as you take a dose.
  • Antidepressants should not give a morale boost. Rather, they should reduce the impact of negative morale effects slightly overall, and specific negative morale effects (especially due to low mood traits) by a larger amount.
  • In the short term, antidepressants should cause some side effects such as stomach upset and fatigue. As the 'vitamin' level increases these should stop or become less severe. The list of possible side effects is actually enormous, and in a later version we may want to track which side effects a given player gets from a given antidepressant, and add several brands and subtypes.
  • antidepressants should slightly increase weight gain, but not until we fix weight gain overall.

Once we get antidepressants working, we might want to add at least a few categories. SNRI antidepressants (eg effexor) are mostly the same as SSRI but might also slightly lower experienced pain when at effective doses in the longer term. NDRI antidepressants (bupropion) do not have the fatigue side effect and instead should have a mild short term stimulant effect.

5. Alcohol

Alcohol is always hard to model in game, because people have a lot of expectations around it. In addition to what we already have, we could consider:

  • Similar to antidepressants, reduce the magnitude of both positive and negative morale effects. This should be a bit fancy: if negative morale effects are very high, regardless of positive morale, the alcohol effect should trend towards a negative morale bonus. However if negative morale is not too high, alcohol should generally trend towards increasing morale. Higher dose alcohol obviously magnifies this effect.
  • Alcohol should tank your focus.
  • Alcohol should lower your practical skill levels while under influence, potentially causing you to be unable to do things you could do before. The skill level drop should be hidden from the player.
  • Alcohol should severely drop any xp benefits due to having a difference in knowledge and practical skill.
  • Alcohol is mildly dissociative and should reduce pain effects.

6. Basic pain killers

  • Aspirin should slightly increase bleeding rate.
  • Add acetaminophen, which works just like aspirin but is complementary to it. The effects are the same but have different names so that they stack. Acetaminophen does not cause bleeding.
  • Add NSAID class painkiller(s), most well known is ibuprofen. This works just like aspirin but does not cause bleeding. It does slightly increase blood pressure and has a random chance of causing stomach pain at moderate doses. This should have the same painkiller effect as aspirin, so it can be used complementary with acetaminophen but not with aspirin. We might want a short acting (ibuprofen) and a long acting (naproxen) version.

7. New basic medications:

  1. Metoprolol: Lasts about 12 hours. Takes about 30 minutes to kick in. A single 25mg dose should drop blood pressure and heart rate by about 10%. Should have a "beta blockade" special effect that removes increase on heart rate from non-medical effects, so pain and exertion don't increase your heart rate, once we have the ability for these to increase your heart rate. Also decreases stamina regeneration by a very small amount, and slightly increases rate of weariness gain.
  2. Bisoprolol: Same as metoprolol but lasts about 24 hours and a dose is 2.5mg
  3. Ramipril: Drops blood pressure by about 10% but does not affect heart rate directly. A 5mg dose lasts about 16 hours. About 1/10 characters get a harmless but annoying dry cough taking ramipril; I'd say this should be determined the first time you take a dose and kept as a hidden stat on your character thereafter.
  4. Naloxone: Skin injection, easy to do: Adds an effect, "lazarus", that cancels any opioid ongoing effects for its duration and, if you had opioids in your system, puts you into opioid withdrawal of intensity equal to whatever opioid effects you just cancelled. When the lazarus effect wears off, the opioid effects return in full.

Describe alternatives you have considered.

I could add drugs forever, but these are some okay ones to start with. I may add more to the list, like some antidepressants and things.

Additional context

These don't have to all be done at once.

I am open to suggestions for other gameplay affecting changes we could implement.

Medications are a great candidate for having several identical meds separated by brand names, as we do with drugs. There is no major in-game difference between ramipril, quinapril, perindopril, and enalopril. We could call them all "Antihypertensive (ACEi)" by default, and allow you to split out the brands if you so choose. If we got his way we should similarly reduce opioids to "short" and "long" acting, and have a single dose of either be a constant morphine equivalent for that formulation. Again, there's no in-game difference between short-acting oral hydromorphone or morphine at the same dose.

@I-am-Erk I-am-Erk added <Enhancement / Feature> New features, or enhancements on existing <Suggestion / Discussion> Talk it out before implementing Items / Item Actions / Item Qualities Items and how they work and interact Items: Food / Vitamins Comestibles and drinks (P4 - Low) Low priority issues: things which are e.g exotic, minor and/or hard to encounter [C++] Changes (can be) made in C++. Previously named `Code` [JSON] Changes (can be) made in JSON labels Dec 1, 2021
@anoobindisguise
Copy link
Contributor

anoobindisguise commented Dec 2, 2021

Does this mean that eating dozens of chunks of lard will finally have a more tangible health consequence than "You feel crummy. You should eat healthier"?

I also figure this is a good time to expand on mutant toxins, currently you can just sort of max out your toxins and be mostly fine. More dramatic effects like negative mutations might be interesting also as a deterrent.

@Venera3
Copy link
Member

Venera3 commented Dec 2, 2021

I'll give it a proper read soon, but the way I could see circulatory stuff being modeled on the quick is

C = BVI x R x HRI
C: "Circulation" - magic number, with different ranges confering different effects (this is what I'd show as "blood pressure" on the player side)
BVI: Blood Volume Index - current BV/max BV 
R: Resistance - mostly just there to be messed with by adrenaline/venoms and as a way to compensate the others' loss
HRI: Heart Rate Index - current HR/base HR, the other way to compensate within certain ranges

Indexing isn't strictly speaking necessary, but A) it makes the math way easier (and in the game) and B) it helps futureproof it for mutations messing with your resting values - HR is already influenced by a few things kn a hardcoded way.
The meat of the effects would come from C veering out of range. Ideally we could have some conpensational range on R and HR to keep it in-bounds, but for a first pass we can get away with a wide range of tolerance(dynamic compensation might get a bit expensive as well, depending on how often we do it).

@PatrikLundell
Copy link
Contributor

Stimulants may increase the rate of focus regeneration, but I think being over stimulated more or less makes you unable to apply the focus because it's always jumping around between new shiny targets?

@I-am-Erk
Copy link
Member Author

I-am-Erk commented Dec 2, 2021

That's a good point... Many substances have a dose response curve with a paradoxic effect at higher doses, and stimulants are a bit one. They should increase focus at lower doses and then decrease it at higher ones, possibly in a less obvious way. I'll add that in.

@I-am-Erk
Copy link
Member Author

I-am-Erk commented Dec 2, 2021

I'll give it a proper read soon, but the way I could see circulatory stuff being modeled on the quick is

C = BVI x R x HRI
C: "Circulation" - magic number, with different ranges confering different effects (this is what I'd show as "blood pressure" on the player side)
BVI: Blood Volume Index - current BV/max BV 
R: Resistance - mostly just there to be messed with by adrenaline/venoms and as a way to compensate the others' loss
HRI: Heart Rate Index - current HR/base HR, the other way to compensate within certain ranges

Indexing isn't strictly speaking necessary, but A) it makes the math way easier (and in the game) and B) it helps futureproof it for mutations messing with your resting values - HR is already influenced by a few things kn a hardcoded way. The meat of the effects would come from C veering out of range. Ideally we could have some conpensational range on R and HR to keep it in-bounds, but for a first pass we can get away with a wide range of tolerance(dynamic compensation might get a bit expensive as well, depending on how often we do it).

Yeah, this is basically the model I am alluding to. Putting it explicitly in the issue is probably a good idea.

Later on, we'll probably want to have some way of assessing a character's ability to maintain their circulation integrity. While intact, they will adjust resistance and HR as needed to maintain circulation, and when they lose that reserve they start dropping circulation. It might be best to write this as a new issue and link it here.

@Inglonias
Copy link
Contributor

While I understand the realism bonus that implementing this could have, I am concerned that this would just be more meters that people have to keep track of. People have enough trouble tracking these stats in real life. To expect them to be able and willing to do so in a game seems a little excessive. If playing normally is enough to stop any obvious downsides from occurring, we may as well not add this at all.

@I-am-Erk
Copy link
Member Author

I-am-Erk commented Dec 2, 2021

Most of the time, effects on heart rate and blood pressure would be behind the scenes to track when other effects should show up. For a pharmacy revamp, they allow mutliple medications to interact, so one medication may do nothing on its own, but causes effects when combined with another.

Unless you're playing with weird stuff, all you need to know is that your player is feeling dizzy due to blood loss, or your stamina isn't regenerating as fast because you're high on heroin. On the back end, that will be because blood volume has dropped and your circulation is lowered, or because your breathing has slowed down. If IRL people don't track their vitals regualrly, you won't need to either. If you're messing with experimental soldier serums that raise your blood pressure to 200/120, then you might want to monitor that stuff, and that would be a feature, not a bug, of making yourself into a walking lab rat.

@Venera3
Copy link
Member

Venera3 commented Dec 3, 2021

The only things I'd potentially show on the player side are HR and BP(which I wouldn't let stuff influence directly, for sanity's sake), all the rest is "just" there to give the relevant effects something to interact with. That means that you don't have to define each drug/venom/mutation/medicine interaction by hand (forgetting a few, inevitably), instead you can point them at the underlying parameter to modify and let them fight it out.

@gkarfakis19
Copy link
Contributor

gkarfakis19 commented Dec 3, 2021

I'm also thinking about how this pharmacy overhaul would interact with mutations - it seems obvious that mutated anatomy should have large effects on the tolerance of these drugs.
A post-threshold Beast Mutant's cardiovascular system should be able to take much more abuse than a Rat/Mouse Mutant's.

In any case, these changes + the corresponding Supersoldier serums seem incredibly exciting to me, to the point where I think I'll try my hand at implementing some small part of this once I get the time.

@I-am-Erk
Copy link
Member Author

I-am-Erk commented Dec 3, 2021

Part of the initial implementation would be to just say your heart rate is at "90% normal" and then if you used something to measure HR, we'd check your mutations, size, cardio health, etc and declare what was normal. So, if you're an obese mouse mutant, you might show an HR of 190 even though you're at 90% normal. If you're a huge cow mutant that lifts weights and jogs 10k daily, that might put your HR at 40. The effect on your character would be the same.

later on we could do other stuff using this framework but that at least would be fun for flavour.

@Shodan14
Copy link

Shodan14 commented Dec 4, 2021

Could we please have some anti-nausea drugs (antiemetics) as well? They would be very handy even without any huge changes.

@gkarfakis19
Copy link
Contributor

Could we please have some anti-nausea drugs (antiemetics) as well? They would be very handy even without any huge changes.

I imagine antiemetics will have to be added along with the superserums, as the side-effects cause vomiting and a vomiting supersoldier is not an effective supersoldier,

@Shodan14
Copy link

Shodan14 commented Dec 4, 2021

Could we please have some anti-nausea drugs (antiemetics) as well? They would be very handy even without any huge changes.

I imagine antiemetics will have to be added along with the superserums, as the side-effects cause vomiting and a vomiting supersoldier is not an effective supersoldier,

Plenty of stuff already makes you throw up when you don't want to like evil eyes.

@I-am-Erk
Copy link
Member Author

I-am-Erk commented Dec 4, 2021

Do we not already have some? If not yeah, we should at least have ondansetron (fast acting, few side effects, rare) and dimenhydrinate (long acting, makes you sleepy, common).

@Shodan14
Copy link

Shodan14 commented Dec 4, 2021

Do we not already have some? If not yeah, we should at least have ondansetron (fast acting, few side effects, rare) and dimenhydrinate (long acting, makes you sleepy, common).

I don't think I've ever seen any myself.

@Ciac32
Copy link
Contributor

Ciac32 commented Dec 4, 2021

If we are revising medication like antidepressants I feel we should incorporate the effects of blob psychosis in some way. I can imagine the infection would be amplifying or surpressing certain aspects of the medication while it's messing with your brain chemistry.

@I-am-Erk
Copy link
Member Author

I-am-Erk commented Dec 4, 2021

It's not really clear whether or not the player has blob psychosis, or what blob psychosis even is on a biological level... That's not very doable.

@BHasselaar
Copy link

What is the cap for adding medications? There are some classes that I never seen mentioned but I feel could be an interesting addition for e.g. diuretics (another 10% BP decrease), androgens (strength increase?), inhaled corticosteroids (preventing asthma attacks), anorexigens (reduce hunger and weight), antiallergic (for sneezing and clogged noses), bupropion (antidepressant for smoking cessation), anxiolytics, antineoplastics (for decreasing random mutations maybe?), narcolepsy medication (modafinil)... and much more

@Shodan14
Copy link

Shodan14 commented Apr 18, 2022

Oh man, I look forward to people accidentally killing themselves when all the drug effects are implemented.

@I-am-Erk
Copy link
Member Author

What is the cap for adding medications? There are some classes that I never seen mentioned but I feel could be an interesting addition for e.g. diuretics (another 10% BP decrease), androgens (strength increase?), inhaled corticosteroids (preventing asthma attacks), anorexigens (reduce hunger and weight), antiallergic (for sneezing and clogged noses), bupropion (antidepressant for smoking cessation), anxiolytics, antineoplastics (for decreasing random mutations maybe?), narcolepsy medication (modafinil)... and much more

Anything that can reasonably be modeled in game is fair game, but I'd encourage people to not add relatively useless medications (at least to start) nor to gamify medication effects to make them more noticeable (there will be room for sci fi drugs to do that later)

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` <Enhancement / Feature> New features, or enhancements on existing Items: Food / Vitamins Comestibles and drinks Items / Item Actions / Item Qualities Items and how they work and interact [JSON] Changes (can be) made in JSON (P4 - Low) Low priority issues: things which are e.g exotic, minor and/or hard to encounter <Suggestion / Discussion> Talk it out before implementing
Projects
None yet
Development

No branches or pull requests

9 participants