Mods / SlowTox
Author: XyrVexus
Side: Server
Created: Jul 9th at 8:49 PM
Last modified: Nov 14th at 8:24 PM
Downloads: 34762
Follow Unfollow 715
Recommended download (for Vintage Story 1.21.0, 1.21.1 and 1.21.2 - 1.21.5):
slowtox_4.0.1.zip
1-click install
SlowTox
Make better use of brewed drinks, give purpose to Taverns, or enhance your RP as the server's drunkard, with SlowTox!
Has your Seraph ever had a pint of mead to toughen up before a battle?
Perhaps they've drunk their body weight in whiskey and brandy to endure the harsh winter cold and temporal storms?
Have they ever been so sloshed the ocean waves rise up to meet them as the mountains reach out for a big hug?
NO? Well, now with SlowTox all of this can be experienced!
Why modify vanilla VS Intoxication?
- Without mods, alcohol instantly causes drunkeness. So unrealistic!
- Players cannot sleep off drunkenness
- The volume of liquid consumed is ignored; drinking a serving of 0.1L yields the same intoxicants as 1L
- Even 0.1L of wine impedes the player's abilities
- There is a low intoxication limit of 1.1 - that's no fun
- Alcohols mostly aren't useful even though they require loads of time and resources to make
What does SlowTox do?
- Realistic ramp up of the effects of alcohol
- Intoxication respects passage of in-game time so players can sleep off their drunkenness
- Serving size matters! Consume single servings from the jug or bowl. I also recommend: Daymare's Cup Mod, Liquid Containers, Tankards and Goblets & A Culinary Artillery's bottles.
- Use drinks for their calories without becoming overwhelmingly drunk
- No strict intoxication limit. Drinking too much can result in becoming over-intoxicated which hurts the player (but also creates some really wild visuals.) So be cautious with that Aqua Vitae!
- Benefits! The Seraph, empowered by intoxicants, experiences many useful effects
- Tolerance will slowly build up if your Seraph drinks regularly; abstaining will gradually return tolerance to normal
- Tolerance can be set by class traits to change how much intoxication is gained
- The /tox command can be used to view intoxication levels. Admins can also set their own values
- Makes intoxication very configurable
- And a final note, it is safe for existing worlds to add / remove SlowTox
Benefits! ...and Consequences!
All that work to create some strong drinks finally pays off!
Strength refers to both mining speed and melee damage. Damage resist can also provide some protection to cold damage.
You'll get maximum benefit when intoxication is near the middle of each effect's range. Benefits at default config settings:
Max HP Regen: 0.1 per 5 seconds
Max Stability Regen: 1% per 8 seconds
Max Attack & Mining Speed boost: 20%
Max Damage Reduction (after armor is applied): 1
The penalties increase in severity as intoxication rises.
1 liter of mead/ale/wine increases intoxication by roughly 0.13;
1 liter of vodka/whiskey/brandy will yield about 0.85
As your intoxication level rises and falls, the effects will change! So take some drinks with you on your next adventure!
Upon start, there will be a configuration file (SlowTox.json) located in the ModConfig directory. It contains these items which you may alter:
| Config Item Name | Default Value | Description |
| Enabled | true | Enables SlowTox features |
| DefaultTolerance | 1 | The Tolerance level players should begin with. Ranges from 0.1 to 10. Tolerance of 2 will |
| CommandsAllowed | true |
Allows use of commands such as /tox. Requires restart to take effect
|
| IntoxicationSpeed | 1 |
The overall rate at which intoxicants are processed
|
| IntakeRate | 0.01 |
How quickly intoxication builds up (this is carefully tuned, adjusting IntoxicationSpeed is preferred)
|
| DecayRate | 0.0023 |
How quickly intoxication is removed (this is carefully tuned, adjusting IntoxicationSpeed is preferred)
|
|
HabitualToleranceChangeRate |
1.0 |
The rate at which tolerance adjusts based on habits
|
| OverintoxicationThreshold | 1.2 |
Threshold after which intoxication causes self-damage
|
|
HealthRegenIntoxRangeBottom
|
0 |
Threshold after which health regeneration is given
|
|
HealthRegenIntoxRangeTop
|
0.6 |
Threshold after which health regeneration is no longer given
|
|
HealthRegenRateMax
|
0.02 |
The maximum health regeneration rate that intoxication can provide
|
|
StabilityRegenIntoxRangeBottom
|
0 |
Threshold after which stability regeneration is given
|
|
StabilityRegenIntoxRangeTop
|
0.6 |
Threshold after which stability regeneration is no longer given
|
|
StabilityRegenRateMax
|
0.00125 |
The maximum stability regeneration rate that intoxication can provide
|
|
StrengthBonusMultiplierIntoxRangeBottom
|
0.2 |
Threshold after which strength bonus is given
|
|
StrengthBonusMultiplierIntoxRangeTop
|
1 |
Threshold after which strength bonus is no longer given
|
|
StrengthBonusMultiplierMax
|
0.2 |
The maximum strength bonus that intoxication can provide
|
|
DamageReductionIntoxRangeBottom
|
0.2 |
Threshold after which damage reduction is given
|
|
DamageReductionIntoxRangeTop
|
1 |
Threshold after which damage reduction is no longer given
|
|
DamageReductionMax
|
1 |
The maximum damage reduction that intoxication can provide
|
|
IgnoreSmallDamageChanceMax
|
0.67 |
The maximum chance to ignore small damage
|
|
WalkSpeedPenaltyIntoxBeginApply
|
0.6 |
The intoxication level at which the walk speed penalty begins to apply
|
|
WalkSpeedPenaltyIntoxFullApply
|
3 |
The intoxication level at which the walk speed penalty is fully applied
|
|
WalkSpeedPenaltyMax
|
0.6 |
The maximum walk speed penalty that intoxication can cause
|
Unintended uses (but uses nonetheless!) via the Config options & commands:
- Disable intoxication: configure IntakeRate to 0
- Make intoxication last until death: lower DecayRate to 0
- Shorten the duration of intoxication: raise IntoxicationSpeed to 5
- All intoxicants hurt the player: set OverintoxicationThreshold at 0
- Make yourself sick & blast off to the stars: Set your Tolerance to 0.1 and drink
- Make configurable
- Benefits for slight intoxication
- Allow intake of additional intoxicants while intoxication is above 1.1
- Change the damage reduction: it should apply after armor, and reduce a percentage of the damage up to the max allowed amount.
- Change health regeneration and stability: it should diminish after exceeding the maximum threshold, resulting in a "sweet spot"
- Integrate with ImGUI
- Intoxication gain/loss based on in-game time rather than real time
- Reduce the chilled vision effect while resistance is active
- Add status indicator for effects
- What would it take for non-code mods to set the tolerance according to class?
- Consider integrating with XSkills
SlowTox exposes some attributes which other mods can manipulate:
entity.WatchedAttributes.SetFloat("slowtox:newToxins", value)
entity.WatchedAttributes.SetFloat("slowtox:detoxicants", value)
entity.Stats.Set("slowtox:tolerance", <yourCodeHere>, value);
For those adding class traits, you add multipliers for the Tolerance system in json:
[
{
"code": <anyNameYouLike>,
"type": "positive",
"attributes": { "slowtox:tolerance": <yourMultiplier> }
}
]
SlowTox uses a Harmony patch to bypass the base game's intoxication system. This works out-of-the-box for food items - if you're writing a content mod you don't have to do anything special, just set the intoxication field in NutritionProperties. A detoxicant is simply a food with a negative intoxication value.
Code modders can add directly to the slowtox:newToxins or slowtox:detoxicants attributes. Tolerance can also be adjusted to weaken or strengthen how much intoxication a player gains from intoxicants.
If you're working on a mod and need assistance in integrating with SlowTox, please reach out to me in the VintageStory discord server!
Other notes:
Should be compatible with almost every mod, including Hydrate or Diedrate. You should also know that Hydrate or Diedrate has a configuration setting to DisableDrunkSway
For more strong drinks, check out these mods:
And for fancy containers try:
*** If you have issues with rubberbanding (sometimes described as lag, stuttering, hitching), Rubberbandaid should take care of that!
Please let me know if you experience any issues or find any incompatibilities. I also love hearing how the mod enhances your enjoyment of Vintage Story. And since you've got the drinkin' mod, why not try my smokin' mod? Real Smoke, that is!
Please drink responsibly.
| Mod Version | For Game version | Downloads | Released | Changelog | Download | 1-click mod install* |
|---|---|---|---|---|---|---|
| 4.0.1 | 1341 | Nov 14th at 8:24 PM | slowtox_4.0.1.zip | 1-click install | ||
|
Prevents unnecessary attribute changes that contribute to rubberbanding | ||||||
| 4.0.0 | 1601 | Oct 31st at 1:14 AM | slowtox_4.0.0.zip | 1-click install | ||
|
Preserve ingested toxins between reloads. | ||||||
| 3.0.3 | 2424 | Oct 15th at 3:15 PM | slowtox_3.0.3.zip | 1-click install | ||
|
Specify side as "Server" so clients don't have to download it | ||||||
| 3.0.2 | 52 | Oct 15th at 2:37 PM | slowtox_3.0.2.zip | 1-click install | ||
|
Remove duplicate marking dirty of attributes to reduce rubberbanding | ||||||
| 3.0.1 | 15387 | Sep 11th at 2:22 AM | slowtox_3.0.1.zip | 1-click install | ||
|
Mark watched attributes dirty when set; only add SlowToxBehavior to players once. | ||||||
| 3.0.0 | 10938 | Aug 19th at 7:52 PM | slowtox_3.0.0.zip | 1-click install | ||
|
Intoxication respects passage of in-game time instead of real time so players can sleep off intoxication. Health regen and stability regen still respect passage of real time, but also occur rapidly while sleeping. Support for mods that would like to create detoxicants or modify intoxication tolerance. Config can now be used to enable/disable SlowTox or set DefaultTolerance. Detoxicants have a negative intoxication in the NutritionProperties. Added commands to view all stats, set detoxicants and set tolerance. Add mod icon. | ||||||
| 2.3.2 | 1395 | Aug 7th at 2:13 PM | slowtox_2.3.2.zip | 1-click install | ||
|
Removed dependency DLLs from zip | ||||||
| 2.3.1 | 599 | Jul 30th at 5:51 PM | slowtox_2.3.1.zip | 1-click install | ||
|
remove pending intoxicants when setting intoxication with /tox. SlowToxBehavior's OnEntityDeath now invokes base.OnEntityDeath( ) | ||||||
| 2.3.0 | 125 | Jul 30th at 3:38 AM | slowtox_2.3.0.zip | 1-click install | ||
|
Add effects: meleeWeaponsDamage, miningSpeedMult, wallkspeed. Apply damage reduction post-armor calculation. Can also set intoxication with /tox command. | ||||||
| 2.2.0 | 284 | Jul 27th at 9:37 PM | slowtox_2.2.0.zip | 1-click install | ||
|
Add health regen during intoxication. Now makes use of a configuration file. | ||||||
| 2.1.0 | 180 | Jul 26th at 4:01 AM | slowtox_2.1.0.zip | 1-click install | ||
|
The state of intoxication slightly reduces many types of damage and increases temporal stability. | ||||||
| 2.0.0 | 170 | Jul 24th at 3:40 AM | slowtox_2.0.0.zip | 1-click install | ||
|
Utilizes harmony patching to better define intoxication intake & decay. Compatible with Culinary Artillery bottles. Intoxication gain is proportional to serving size. | ||||||
| 1.0.0 | 266 | Jul 9th at 8:53 PM | slowtox_1.0.0.zip | 1-click install | ||
|
Initial release | ||||||
Any plans to add commands for admins to set other players' tox stats?
I was in a position on a roleplaying server where I wanted to let a player recover more quickly from a binge by roleplaying vomiting, but right now we can only set our own tox stats.
Could be useful for general debugging/testing too.
It would be totally cool if you could get blackout drunk where you either go blind and can't see or you just pass out and are left at the mercy of whatever finds you. I hear bears like their meat brined before they eat it...
Also if you can get black out drunk, at high enough levels of intoxication, you should be able to hallucinate pink drifters that you can chase around.
Downed a liter and a couple mugs' worth of cherry brandy as the resident Blackguard...ended up going nuts in the front yard of the base after a medium temporal storm, asking my hunter friend if the drifters were real. 10/10 would do again. 😆
GhrimVortex I'll check my mod versions of both cullinary artillery + expanded foods and slow tox, but last I checked, the /tox command worked, and setting intoxication via it also worked, however no amount of alcohol caused the intoxication value to raise while all three were installed.
GhrimVortex Do you mean blood from Butchering? It does seem to be mildly intoxicating. SlowTox uses the "Intoxication" value from the nutrition properties, it will never add or remove drunkenness to any item!
captanredbeard It seems to work for me, verify using the /tox command as described above. if you have hydrate or diedrate make sure to re-enable the drunksway in its config.
Wulff I'm very glad to hear the rubberbanding is improved, thank you for the feedback!
I love the mod so far, just wondering if blood from culinary artillery is supposed to make you drunk?
Does support for Expanded Foods need to be redone? I'm running expanded foods dev and even after 100 liters of aqua vitae I'm not getting any alcohol effects
I dont know how long whatever issue here was casuing the rubberbanding but i have had this on my server, which has a fair bit of mods, since we started it about a month or so ago and we all have had periods of rough rubberbanding and just lived with the struggles. One of the people has it far worse than the rest of us even though they are the closest to the server location.Today after updating i would say this one fix has for sure improved the performance single handedly. most of the stuttering and such has cleared up also. we still had some lag spikes but that is to be expected
Zalea the Rubberbandaid mod should fix that
Players reported a lot of rubberbanding with this mod (version 4.0.0) installed. Is there any workaround/server setting around this? Would really like to use this mod!!
BlueSamoyed So kinda like drinking on an empty stomach, the alcohol hits stronger and/or faster? I could totally do something like that. I will probably opt to get the status indicator working before I further complicate the existing system, because I don't want to mentally overload players with additional interactions
Would be interesting to add more toxicological relevancy to things like healing, although it would have to be implemented along with a mod that introduces more healing options like additional medicinal plants that must have their active compounds extracted by solvent. Could you maybe implement an effect where a lower saturaation level on the hunger bar = quicker max response? This may have been mentioned before, however.
Krakulous would you happen to have Hydrate or Diedrate? it has a configuration setting to DisableDrunkSway by default
I drank 30 liters of wine and didnt get drunk?
Ceeroy I think that is very interesting. If I add adjusting tolerance, I wonder if it should be enabled by default. I'll try to run a poll on the Discord.
Awesome mod! Do you think it would be possible to make tolerance build up over time after months of drinking and then decay to default when not drinking regularly? When I first saw the tolerance value I tried increasing it naturally with the hope that my dwarf character could outdrink all the other races, lol
ThatFolfy Nope, and I don't see anything in their repo specifically about intoxication... Update: it looks like they identified some issues and released a new version!
Hey, is there any built-in, intended interaction between this mod and SleepNeed? I've already asked about an issue I'm having on that mod's page, because it has to do with that mod's energy absolutely TANKING after my character gets drunk, but I just wanna make sure I haven't missed anything I could tweak.
Mountainmanmad Yeah when I get the time I'd really like to add an icon to Status Hud Continued, ideally a tankard icon with opacity or color representing the intoxication level, and benefits/penalties icons appearing inside the tankard
XyrVexus Thanks for the response! Have you considered making an icon for the mod, or a notice as to what bonus range you are in while in game?
Mountainmanmad The drunk sway will kick in a little bit then, yes. You can adjust your tolerance as you like. See the commands and config options. You can also adjust the benefits and penalties to any intoxication ranges that you prefer, for example if you lower the range for StrengthBonusMultiplier you can have that benefit while experiencing less of the drunken sway.
Should I be getting the drunk sway even after a litre of wine? Or am i still intaking too much alchohol?
That's awesome. Now, in true dwarves, we can be mine forever without having stability issues as long as we have a steady supply of ale.
Could you add a display to alcoholic containers that indicates their strength somehow? Either a "proof" value or just outright showing how much intoxication they add?
> And since you've got the drinkin' mod, why not try my smokin' mod?
Very amused by this, thank you
Any possibility of this also being usable with other, actual toxins ie mushrooms and (modded) poisonous berries?
There's some...interesting potential in running this + foragers gamble, accidentally eating some deathcaps, and knowing you only have so long to live before the shrooms "digest" and kill you. Especially if someone makes a companion mod that lets you "detox" to hail-marry try and save yourself.
Or allowing people to partake of the fly agaric without suffering from poison, unless they eat too many. Probably beyond the scope of this mod but fly agarics are hallucinogenic...
thank you for still backporting fixes to 1.20.12!
qlVegetalp all sorted out in 3.0.1 :-)
weird incompatibility but rustbound magic and this mod together make the character creator break like it keeps reseting to default
CrusaderRoy Mining Speed only applies to ore and stone. Maybe there's a mod out there that can make it apply to more materials? That'd be nice.
I'm not sure if it's a conlfict or a bug, but I don't seem to be getting any benefits to mining speed. I wanted to use alchohol to speed up my terraforming efforts, but the benefits seem to be non exsitant. My damage did go up however. I tried upping the strength modifier and was able to confirm that I could 1-shot mobs in a temporal storm, but still had no mining bonuses. I didn't see an official place to submit bugs. If you;d like more information on my mod list please let me know!
i think it'd be neat if tolerance was influenced by max HP, like i can see a blackguard downing a few pints and being mostly okay, while the feeble but humble clockmaker just keels over after like one shot
edit: it would also mean healthier diets can handle alcohol better, giving slightly more use to the nutrition system
Tasshroom33 Good catch - I'll make sure to update the modinfo.json in the next release
Did you change your dependencies in modinfo.json from 1.20.12 to 1.21.0?
"Recommended download (for Vintage Story 1.20.12 and 1.21.0-rc.1 - 1.21.0):"
Awesome! Thank you so much!
LaurelAurelia Yes it is!
Tasshroom33 That's very exciting, reach out to me in Discord for anything! And also I'm highly anticipating your Hardcore Winter mod!
Nice hook, after I'm done with Hardcore Winter(deeper snow) I'll try to add integration so you can get fat and drunk lol.
entity.WatchedAttributes.SetFloat("slowtox:newToxins", value)entity.WatchedAttributes.SetFloat("slowtox:tolerance", value)entity.WatchedAttributes.SetFloat("slowtox:detoxicants", value)I'm curious if this is compatible with "A Warrior's Drink!" which adds Arkhi Liquor.
Thank you for this immersive mod!)
Alcohol doesn't increase cold resistince IRL, it only gives the illusion of being warm, because it pulls heat from your core body tempature, where it protects vital organs from cold damage (there was even a mythbusters episode on it). Alcohol actually accelerates cold damage, but it could be useful for warming up quickly for the same reason, assuming you are sober by the time you need to go back out into the cold.
Zolgrim Should be no issues, I would expect you'd be able to get the stat bonuses from both mods
Is there any known compatibility issues with the alchemy mod?
Thanks for bringing that to my attention, ProfCupcake, I've released 2.3.2 to address this.
Aranyani See if NoDrunkenShaking works for you; I can't speak on for it though.
This - and also your new mod, Real Smoke, I suspect, from a quick check - is causing issues when loaded with others due to the inclusion of the System .dlls in the mod files. If more than one mod has these, only the first one encountered will load; the rest will throw an exception stating that the assembly is already loaded and fail to load.
The other mod I had that did this was Toggle Mouse Control; I reported the same thing on their page.
Is there a way to get rid of the wavy visuals when even mildly intoxicated? it really makes me seasick. Thank you for this mod, I love any attention to the brewery. o7
I like the ideas in this, could work great with the new revive feature, where you can pass out from getting too drunk and need to be woken up by another player.
Hewholurks Wilihey I love to see how this mod has enhanced your gameplay and created new stories ☺️
Drakosha I will look into something along those lines, especially the detoxication - as is, if intoxication is above 3 it's so hard to do anything that you may as well be passed out haha.
Kierantheking I believe those are added by mods such as Expanded Foods; the intoxication each drink yields is determined by the configuration of its respective mod, and will work perfectly well with SlowTox.
Do the aged alcohols also have a stronger effect than the basics, ie strong/fine wines and aged/vintage brandy?
Would be fun if you were passing out because of overly high intoxication (during team events, lol).
If all players passed out, you may skip time like with sleeping to prevent players waiting. Maybe add temporary debuff as aftereffect to prevent abuse. Or make passing out not that long so players won't get bored.
Also eating food could help getting detoxicated a little, while drinking alcohol could make you hunger faster (don't know if that already implemented, haven't found that in description)
Me and my friend started playing a week ago and were discussing how it would be great if wine barrels we stored gave us actual benefits. Our whining has been heard!
very cool!! theres not much to do during a temporal storm and my safe room is always in the cellar with my rocks of alcohol, now i'll be able to pass time that much more quickly drinking the storm away :^)
JohnVicres Yes SlowTox should be broadly compatible with other mods, the exception being those that add new ways of consuming food/drink. For example, I had to write a specific patch just for A Culinary Artillery's bottles. And if meals ever included intoxicants that would require code patches as well.
I will consider adding HP restoration once I make the mod configurable. I want to give alcohols more purpose without being too powerful, so that it becomes more like a tool you can take with you. Expanded Foods, Booze Expansion, and More Mead Options include alcohols that heal albeit instantly which is less than ideal imo.
thanks for the update! this is exactly what ive been looking for
I'm testing Expanded Food's alcohols rn, and it appears they work! Had to check the wiki on how intoxication is handled, and so long as modded alcohol drinks follow the vanilla system, anything will be compatible I think.
Also, one thing I've wanted for a while is for alcohol to straight up restore HP; the stronger the alcohol (except Aqua Vitae), the more HP gained. I feel it's a pretty neat trade for the visual and motor impairments, and would be awesome as a side-grade for the standard healing items - especially the higher tier ones, since they require not-that-abundant resources.
This and the Gloomeclasses miner is such power couple. Since the miner loses sanity when on the surface and what is better then getting to rp as a constantly drunk miner because oof the shit you have seen in the mines that starts to properly go insane outside of the cold mines they know as home unless sloshes.
Thanks for your feedback Pell, those benefits are exactly in line with what I was thinking!
this looks interesting, especially your future plans for giving alcohol benefits. perhaps giving minor buffs to health/damage resistance or cold resistance? or even giving a slight resistance to temporal instabilty!