Mods / Vigor (Alpha)

Tags: #Tweak
Author: chrisunfocused
Side: Both
Created: 5 days ago
Last modified: 3 days ago
Downloads: 217
Follow Unfollow 57

Recommended download (for Vintage Story 1.20.12):
vigor_0.3.0.zip  1-click install


About Vigor

This mod was created to add a layer of physical challenge and consequence to Vintage Story. Removing the ability to sprint and swim indefinitely adds challenge to combat, and encourages the use of rafts and boats for water traversal.
Vigor introduces a stamina system that is deeply integrated with the food you eat, making both physical exertion and a balanced diet critical components of your survival strategy.

Stamina System

A stamina bar is added to the HUD, which is consumed by the following actions:

  • Sprinting
  • Swimming
  • Jumping

 

Running out of stamina will leave you Exhausted. While exhausted:

  • Your movement speed is significantly reduced.
  • You cannot sprint.
  • If you are in the water, you will begin to drown.

 

Stamina regenerates after a short cooldown following any strenuous action.
However, if you push yourself to full exhaustion, you will face a longer recovery penalty before your stamina begins to return.

Nutrition Bonuses

Vigor ties directly into the vanilla nutrition system. Maintaining high levels in the five food groups provides significant, scaling bonuses to your stamina attributes. A balanced diet will make you more resilient and capable.

Nutrition Category Primary Bonus (at 100% saturation) Secondary Bonus (at 100% saturation)
Grain +30% Max Stamina -20% Jump Stamina Cost
Protein +30% Stamina Recovery Rate +20% Max Stamina
Vegetable -30% Stamina Drain Rate -20% Recovery Threshold
Dairy -30% Recovery Threshold +20% Stamina Recovery Rate
Fruit -30% Jump Stamina Cost -20% Stamina Drain Rate

 

Note: "Recovery Threshold" refers to the percentage of stamina you must recover to before the Exhausted state is removed.

Configuration

Vigor is highly configurable. Nearly all values, from stamina costs to the potency of nutrition bonuses, can be adjusted in the ModConfig/vigor.json file to tailor the experience to your liking.

Experimental

Vigor 0.3.0 adds experimental support for Stamina integration by other mods.
I have built a custom version of Verticality to iron out the API requirements. If you would like to test it out, please download the custom Verticality mod.
Release v0.3.1_vigor_experimental · cjohnsto-nz/Verticality

Future

  • Make the player slowly sink when exhausted in water.
  • Add stamina cost to other actions, like smithing and mining.
  • Reduce/remove hunger cost from those actions, in favor of stamina costs.
  • Add a hunger cost to recharging stamina.


This mod is in very early development!
My goal is to split this into two mods:
Vigor, which controls the sprinting, swimming, jumping costs, and the nutrition bonuses.
StaminaLib, which controls the UI rendering, state management, and intermod compaitibility. My goal is to provide a vanilla like standard stamina framework for all mods that use stamina to align on.
But I am just learning :)
Please let me know if you have any issues, or need changes for mod compatibility.

Mod Version For Game version Downloads Release date Changelog Download 1-click mod install*
0.3.0 83 3 days ago vigor_0.3.0.zip 1-click install

Added support for external integration.
Experimental support for a custom version of Verticality.
If you would like to try it out, please download the release and replace your Verticality with this version: Release v0.3.1_vigor_experimental · cjohnsto-nz/Verticality

0.2.1 26 4 days ago vigor_0.2.1.zip 1-click install

Fixed issue where the inventory bar was not clickable.

0.2.0 42 4 days ago vigor_0.2.0.zip 1-click install

Added compatibility with Hydrate or Diedrate (move stamina bar up and out of the way)

0.1.1 66 5 days ago vigor_v0.1.1.zip 1-click install

Initial Version


43 Comments (oldest first | newest first)

💬 SaltyWater, 4 hours ago

Damn nice mod!

💬 ryanberry, 9 hours ago

Sprinting stamina works, but my character is too slow to trigger it, unless sprinting on a path (with movespeed bonus). 

I hope this doesn't lead to a significant and annoying refactor or anything, but - there needs to be a way to detect when a player is sprinting, but is not meeting the "sprint speed threshold".

For example, I use the Butchering mod as well as Hydrate or Diedrate. In both of those mods, when you carry a certain item (dead animal of high weight, or lots of water) you will slow down universally. Walking AND sprinting get slower.
So even while sprinting while carrying a heavy load, stamina will not drain. 

Also, just gonna yap a feature suggestion for a sec. I've been considering using StepUp Continued/Advanced, but I think it would make traversing rough terrain too easy (no jumping needed to scale slopes, therefore no additional stamina drain for "climbing")
If you could find a way to apply stamina drain (maybe half of the default jump stamina) for stepping up a block with the StepUp mods, that would be incredible! Jumping up like 1.3 meters constantly is unimmersive and annoying anyways lol

Still enjoy your mod majorly regardless. Do you have a ko-fi or similar?

💬 Araewin, 1 day ago

chrisunfocused Ok thanks it's very appreciated ^^ yes i try on a dedicated server in multiplayer maybe it's the multiplayer part its not working reach me when you want ;)

💬 chrisunfocused , 1 day ago

ryanberry I'll give your settings a go! If I still struggle to reproduce the issue, I'll hit you up on dc this weekend :)

SerHause and Araewin I will try multiplayer and Xskills more this weekend. Would love to integrate with xskills, but I've never used it before.
Araewin, I have not encountered that issue. It is probably a stuff up on my end. Will do some digging. I might reach out to you this weekend

Thank you everyone for trying out the mod!

💬 ryanberry, 3 days ago

chrisunfocused Alt of berryland here again lmao. Here's my SprintMomentum config:

Also THANK YOU for this mod and being an awesome attentive dev. If you eventually would like any kind of logs I can provide, let me know and I gotchu. Can also DM on discord if you want some faster communication (ryanberry)

 

And SerHause I've been using this in multiplayer exclusively. It works for jumping, and sometimes works for sprinting. Either way it definitely loads in properly.

 

SprintMomentumConfig
{
"EnableDebugLoggingComment": "Show extra log messages if you want to know more about what the mod is doing.",
"EnableDebugLogging": false,
"GetWalkSpeedMultiplierSeparator": "========== RUNNING SPEED SETTINGS ==========",
"ExtraSprintBoostComment": "How much extra speed you get when sprinting. Adjust to run faster or slower.",
"ExtraSprintBoost": 1.0,
"SprintRampUpRateComment": "How quickly the extra speed builds up when you start sprinting.",
"SprintRampUpRate": 0.5,
"SprintDecelerationRateComment": "How gently your speed falls when you stop sprinting.",
"SprintDecelerationRate": 0.6,
"NormalAccelerationRateComment": "How fast you speed up when walking normally.",
"NormalAccelerationRate": 3,
"NormalDecelerationRateComment": "How fast you slow down when you stop walking normally.",
"NormalDecelerationRate": 2,
"CalcMovementVectorsSeparator": "========== WALK VECTOR SMOOTHING SETTINGS ==========",
"MovementDecelerationRateComment": "How gradually your speed fades when no movement key is pressed.",
"MovementDecelerationRate": 0.5,
"CalcMovementVectorsSidewaysSeparator": "========== DIRECTIONAL SMOOTHING SETTINGS ==========",
"SidewaysSmoothingRateReversedComment": "When turning the wrong way, this controls how slowly your current momentum changes.",
"SidewaysSmoothingRateReversed": 1.5,
"SidewaysSmoothingRateNormalComment": "When turning gently, this controls how quickly your movement adjusts.",
"SidewaysSmoothingRateNormal": 4,
"SidewaysDecayRateComment": "How quickly sideways movement fades when no key is pressed.",
"SidewaysDecayRate": 3,
"AnimationMetaDataSeparator": "========== ANIMATION SETTINGS ==========",
"WalkEaseInSpeedComment": "How quickly the walk animation starts when you begin moving.",
"WalkEaseInSpeed": 3,
"WalkEaseOutSpeedComment": "How quickly the walk animation stops when you stop moving.",
"WalkEaseOutSpeed": 13,
"WalkWeightComment": "How strong the walk animation appears compared to others.",
"WalkWeight": 8,
"WalkBlendModeComment": "How the walk animation blends with other animations.",
"WalkBlendMode": 1,
"SprintEaseInSpeedComment": "How quickly the sprint animation starts when you begin sprinting.",
"SprintEaseInSpeed": 3,
"SprintEaseOutSpeedComment": "How quickly the sprint animation stops when you stop sprinting.",
"SprintEaseOutSpeed": 13,
"SprintWeightComment": "How strong the sprint animation appears compared to others.",
"SprintWeight": 8,
"SprintBlendModeComment": "This option lets you choose how the sprinting animation blends with others.",
"SprintBlendMode": 1,
"MonsterSeparator": "========== MOBS SETTINGS ==========",
"EnableMonsterSmoothingComment": "If true, monsters/animals get exponential speed smoothing, like players.",
"EnableMonsterSmoothing": true,
"CreatureExtraSprintBoostComment": "How much extra speed creatures get when sprinting.",
"CreatureExtraSprintBoost": 5,
"CreatureRampUpRateComment": "When creatures begin sprinting, how quickly they accelerate upward.",
"CreatureRampUpRate": 0.8,
"CreatureSprintDecelerationRateComment": "When creatures stop sprinting, how quickly they decelerate from sprint speed.",
"CreatureSprintDecelerationRate": 0.6,
"CreatureNormalAccelerationRateComment": "If a creature is walking normally, how quickly it speeds up.",
"CreatureNormalAccelerationRate": 2,
"CreatureNormalDecelerationRateComment": "If a creature stops walking, how quickly it slows down.",
"CreatureNormalDecelerationRate": 0.5,
"CreatureMovementDecelerationRateComment": "Movement deceleration for creatures when no input is pressed.",
"CreatureMovementDecelerationRate": 0.5,
"CreatureSidewaysSmoothingRateReversedComment": "If reversing direction, how slowly the creature\u0027s momentum changes.",
"CreatureSidewaysSmoothingRateReversed": 1.5,
"CreatureSidewaysSmoothingRateNormalComment": "If mostly same direction, how quickly the creature adjusts sideways.",
"CreatureSidewaysSmoothingRateNormal": 4,
"CreatureSidewaysDecayRateComment": "How fast the creature\u0027s sideways momentum decays if no input is pressed.",
"CreatureSidewaysDecayRate": 3
}
💬 SerHause, 3 days ago

Has anyone tried this in Multiplayer? It's not working for me but I have other mods installed and cant remove them all to test.

💬 Araewin, 3 days ago

I use XSkills maybe it's not working with that mod :S ?

💬 Araewin, 3 days ago

Here what i got its weird he waiting data from stamina if it's not enable when i can found the option to enable it :S :

💬 Kaschperle, 3 days ago

@chrisunfcoused I am not using toggle sprint but I also tweaked the run config to be slower by a margin so its the speed as I also reduced global server speed settings.

💬 chrisunfocused , 3 days ago

berryland That's probably it! I'll see how I can work around that and I'll let you know.

💬 berryland, 3 days ago

I can't share my Momentum config right now, but will tomorrow. I can however say that I use toggle sprint on shift instead of the default key. I'm also running the walk speed in world config 1 step lower than default. 

💬 chrisunfocused , 3 days ago

I have added experimental support for integration by other mods. If you use Verticality, and would like to test it out, please download this custom version: Release v0.3.1_vigor_experimental · cjohnsto-nz/Verticality

IgnisPolonia Thank you 😊

berryland Would you be able to share your momentum config? The sprint detection code basically just checks to see that you are A: Holding Sprint key. B: On the ground. C: Moving faster than 0.01. 
I'll see if I can reproduce if you can share with me.

Araewin That looks really weird. Can you bring up the Debug menu with F8? Does the stamina system actually work? I have been having a really hard time getting the stat bar foreground and background to align. Maybe it's a GUI scale/aspect ratio setting that is causing the foreground to go missing.

💬 IgnisPolonia, 3 days ago

Awersome! It Works! Crafting is full symbiosis by Vigor and Hydrate of course. Full thanks for autor again - well done! 

💬 berryland, 4 days ago

chrisunfocused OH INTERESTING. I lowered the speed of sprinting from Salty's Momentum. By default, even on slow classes, it felt comically fast. And due to that, the game only registers the player as actually sprinting, when sprinting AND falling lmao. I noticed that sometimes I did drain stam after sprinting and not jumping, so I thought it was just inconsistent.

I guess I could up the sprint speed slightly, because it's like, right on the edge of not being flagged as sprinting. Do you think there's some way to workaround the issue otherwise?

💬 PepperCat, 4 days ago

If it works as an example, I'm playing with Momentum mod and I see the stamina getting decreased

💬 Araewin, 4 days ago

Thats weird me i got that :

 
💬 chrisunfocused , 4 days ago

ryanberry and Kaschperle
I tested with Salty's Sprint & Momentum, and it seems to work fine for me at least.


Can you confirm what the issue you were having was specifically? F8 to open Debug menu. If Sprinting = True when sprinting, it should be working okay.

💬 chrisunfocused , 4 days ago

IgnisPolonia and Araewin
The issue with not being able to click on the inventory bar is fixed in 0.2.1!

PepperCat
Thanks for the kind words :)
I love playing on tiny islands, and I didn't really like that I could just swim forever to escape, so that was the main motive behind this.

Wrum
Maybe! That mod is closed source at the moment, so I would need to do a lot of debugging to see if there's something I can hook into.
Ideally I will split this mod out into a separate, vanilla style StaminaLib that other mod makers can hook into. Then Vigor can just take care of adding stamina costs for vanilla actions.
I'm going to try to do Sprint Momentum next. Will look at Salty's Dodgemaster after that!

💬 Wrum, 4 days ago

Yesssss, any chance of integrating salty's dodgemaster into this so dodging costs stamina? I need more dark souls in my vintage story 

💬 PepperCat, 4 days ago

I just logged in to say that mods that makes the character management more complicated are always my favourite type of mods so I'll be 100% using this! Love it! Thanks for the compat with Hydrate

💬 IgnisPolonia, 4 days ago

great idea for a modification. this mechanic should be in the basic version! now you will have to strategically sneak up on the bear instead of running around the whole map aimlessly. I believe you will be able to fix the problem. we are waiting patiently

💬 Araewin, 4 days ago

Perfect thanks a lot i love the idea of your mod keep up the great work and thanks for fast answer ^^

💬 chrisunfocused , 4 days ago

IgnisPolonia and Araewin
Thanks for the report! I'll have a look into this. I changed the way the HUD renders to match Hydrate, but maybe I did something wrong and it's interfering. Hope to have a fix up today. Thanks for your patience 🙏

ryanberry and Kaschperle
I will try to get Sprint Momentum working today too.

CherryRook
Combat, Smithing, Mining etc costing stamina are all part of the plan. Just need to get the basics ironed out first.

💬 IgnisPolonia, 4 days ago

I checked it with and without Hydrate - dragging the mouse with the vigor mod doesn't work. With the Hydrate mod it works normally. So here's a big request to the author to try to fix it

💬 Araewin, 4 days ago

Yes crafting not working and when you try to drag and drop from your toolbar we cant and me the bar is there but stay in gray color maybe because hydratation mod dont know

💬 IgnisPolonia, 4 days ago

Alert. Crafting doesn't work. Im testing only this mod

💬 ryanberry, 4 days ago

Mr. 2nd account of @berryland here lmao. Can report that the new stamina bar placement works great! Thank you for this mod and for the quick fix. 

I must however, also echo Kaschperle from earlier: the Sprint Momentum mod makes stamina not properly drain while sprinting. 

If you could possibly look in to that, the immersion fiends out there would be very appreciative! In the mean time, I'm happy with jumping costing stamina lol

💬 IgnisPolonia, 4 days ago

there is one major problem. with the Hydrate mod the inventory doesn't work. You can't craft anything. I've also tested it only with these two mods.

💬 Hydromancerx, 4 days ago

Thanks for making it compatable with other mods that add bars.

💬 CherryRook, 4 days ago

Very cool mod ! Would it be possible in the future to make it so using weapons takes stamina too ? 

💬 Kaschperle, 4 days ago

So a little testing with my modpack of mine It seems like it's not playing well with the modpack and 1 certain mod especially called sprint momentum! The stamina doesnt deplete when running at least when I tested it.

💬 Kaschperle, 4 days ago

thank you I let you know if I find any bugs!

💬 chrisunfocused , 4 days ago

MRGOOSE I've added a quick demo video to the description :)

💬 MRGOOSE, 4 days ago

can we have a video of how this mod works?

💬 chrisunfocused , 4 days ago

Wahazar Stamina regenerates in a few seconds. It is designed to limit short term physical exertion like sprinting, swimming, jumping (climbing, smithing etc but those aren't implemented)
Tiredness is a cool idea though! We could have a max stamina/stamina recharge penalty depending on the number of hours since sleep? I really like that actually. I'll add it to the to do list.

💬 Wahazar, 4 days ago

Does sleeping regenerate stamina? 

Option with high stamina capacity, which allow whole day of intense activity, but require sleeping to recover fully, would be avesome for servers - now everybody agree for sleeping ;)

💬 chrisunfocused , 4 days ago

IgnisPolonia berryland Kaschperle
Vigor 0.2.0 is compatible with Hydrate or Diedrate. Let me know if you have any issues :)

💬 IgnisPolonia, 4 days ago

Great! Thank You!

💬 chrisunfocused , 5 days ago

I will try to make these compatible today! Will update you all once I've had a chance 🙂

💬 Kaschperle, 5 days ago

yes those mods need to be compatible to not overlap each other! As both are important for the immersive lovers like us

💬 IgnisPolonia, 5 days ago

Yep! for sure. Vigor is great idea mod, creates very realistic situation, but Hydrate is a legendary mod. Dear Autors @chrisunfocused please - listen to us! 

💬 berryland, 5 days ago

Seconding interest in Hydrate or Diedrate compatibility. I would use Vigor right now on my server if the bars didn't overlap.

💬 IgnisPolonia, 5 days ago

good idea! but please make compatibylity or Hydrate Diderate mod becouse HUD bar the same please in the game

 (edit comment delete)