Garry's Mod

Garry's Mod

Oxygen and Stamina System (And Flashlight Battery)
128 Comments
NyanCatGamer02 3 hours ago 
There could be any way to fix the drowning feature that won't regenerate the lost health after drowning?
NyanCatGamer02 22 hours ago 
oh my god, I never knew I needed this until I subscribed to it, great job!!!
CyanStar 11 Jun @ 12:10am 
I love this addon, with my only real suggestion being maybe a way to assign different values for each slider to different players like you run out of stamina faster but others run out slower. Idk how difficult that would be to code tho-
sleepingpilot 3 May @ 3:46pm 
actually really underrated
MonoBoca 7 Feb @ 8:17pm 
i cant save configs:steamsad:
Sevka Slav 27 Jan @ 4:01pm 
meh fine, btw this mod of yours is hella cool, saying this so you feel good
is it possible someday for you to add UI modifications to it? I would like it to look more gritty and STALKER 2 like or dark instead of cartoony blue and green, not that I have a problem
Rad Poseidon  [author] 27 Jan @ 2:08pm 
I'm saying that it's on the creator of that mod. The code isn't open source so I'd have to unpackage it, and I don't think it's worth it to add compatibility for a specific mod when the developer of that one could have and should have just edited the player metatable to modify Player:FlashlightIsOn()
Sevka Slav 23 Jan @ 4:29pm 
... no I swear it does not use up the battery, besides I noticed this mod all it does is just paste a flashlight texture... which kinda sucks... but the animation is great
Sevka Slav 23 Jan @ 4:25pm 
wait, oh... sorry, hmm I don't know, when I used this, the flashlight battery hasn't gone done
Sevka Slav 23 Jan @ 4:25pm 
are you saying you could make a compatibility for this?
Rad Poseidon  [author] 23 Jan @ 4:08pm 
This addon uses GMod's default flashlight hooks to work. It's entirely possible for that mod to tie into them instead, which is what they should do.
Sevka Slav 22 Jan @ 12:11am 
is there any way you can make it compatible with this? https://steamhost.cn/steamcommunity_com/sharedfiles/filedetails/?id=2778699319&searchtext=flashlight+battery With this mod when I turn on the flashlight it doesn't drain battery
Rad Poseidon  [author] 26 Dec, 2024 @ 9:11pm 
Looks like TFA's old cbobbing. There are several reuploads
PixelPreasure 26 Dec, 2024 @ 12:23pm 
whats the viewbobbing addon?
Corcho 30 Nov, 2024 @ 1:57pm 
can hud you're using?
Rad Poseidon  [author] 17 Sep, 2024 @ 10:10am 
All of the gameplay values are server-sided, hence why they are prefixed with sv_
Domi Gamer 16 Sep, 2024 @ 10:07am 
And if you run this addon on the server, then all players have different stamina settings? Or is the server admin responsible for setting stamina for all players?
MERCY_ALL 20 Apr, 2024 @ 10:41am 
fun fact: if you set the width and height to 0 you just got the %
AzureAsher4544 13 Apr, 2024 @ 10:24am 
the position
AzureAsher4544 13 Apr, 2024 @ 10:22am 
how do i reset the things
Rad Poseidon  [author] 25 Feb, 2024 @ 12:04pm 
That is a plan, I sort of whipped out this current version over the summer when I had some time from school, as you can tell the O2 tank item is kind of buggy and incomplete.
It'll get updated again eventually, I haven't abandoned it, it's just more like the mod is on standby for the time being.
Fredrick 18 Feb, 2024 @ 11:40am 
I recommend adding in batteries to restore the flashlight's power by half in case the flashlight never recovers over time.
Olly 28 Jan, 2024 @ 4:19am 
The bars are all stuck empty for me despite the bars showing 100. any ideas why?
Coffee 19 Jan, 2024 @ 9:01am 
realistic!
wiimeiser 28 Dec, 2023 @ 6:47pm 
Might be a conflict with something Jmod added. I know it added nutrition and scrounging recently.
Smug Corvo 28 Dec, 2023 @ 10:37am 
For some reason, this mod paired with JMod prevents me from sprinting
Earl Whitehorse 3 Dec, 2023 @ 7:28pm 
thanks, maybe try improving the aspects you dont like about it if you want to. :steamthumbsup:
Rad Poseidon  [author] 3 Dec, 2023 @ 10:53am 
Old HUD I made. It's not very good, at least in my mind, but it is on my profile.
Earl Whitehorse 2 Dec, 2023 @ 6:43pm 
whats that hud
Jesiel61 30 Nov, 2023 @ 2:13pm 
i have some ideas for this addon, for the stamina bar there could be like a few different versions of it to look different since the one that we have is fine it's just kinda plain same for the oxygen meter maybe there could be alts like a oxygen tank or a bubble that would be cool, and for the flashlight maybe the meter could just be a battery or a flashlight and maybe you could add a thing that when your underwater bubbles come out of your playermodel's head area and you can control how much appear and that's all the idea's i have for this!
Kanye's bath water 10 Nov, 2023 @ 8:05pm 
Awesome mod!!! Recommend this mod to any gmod realism enthusiast!
5_Cell 21 Oct, 2023 @ 5:21pm 
dell you really popped off with this one i never knew you were steam workshop famous
Lunelle 20 Sep, 2023 @ 2:35pm 
i wish it looked like the vanilla half life 2-esque hud style
Fizzie 25 Aug, 2023 @ 5:21pm 
@Sargasm
I don't think this mod gives a blurred screen effect, even if you run out of stamina.
I've been using this mod for a long time, so you might be experiencing something from another mod.
Mental 25 Aug, 2023 @ 4:06pm 
no matter what I do with the values, even if I dsable everything, the screen stays blurry like I'm tired
findecisive 24 Aug, 2023 @ 2:05am 
just raise sv_oxygen_maxoxygen
prototype money stock broker 14 Aug, 2023 @ 8:37pm 
something you recently changed made oxygen deplete way faster
VintageDegenerate 12 Aug, 2023 @ 2:41pm 
Might also be something on my end, but it's worth a try regardless
VintageDegenerate 12 Aug, 2023 @ 2:41pm 
For those of you who still can't fix it, just make the cost values the tiniest bit below 1. Apparently if a cost percentage is 1, you can't start running.
Rad Poseidon  [author] 12 Aug, 2023 @ 12:43pm 
Just published a small fix, may take a little while to go through.
I changed all of the convar defaults to something that should work better, and I've also changed the networking to 32 bits (max of 2,147,483,647) which I think should come out to around 25 days worth of sprint stamina. If you need to sprint longer than that I recommend going outside and or just disabling stamina. Whichever is more convenient.
Rad Poseidon  [author] 12 Aug, 2023 @ 11:47am 
As t2hk said and as I said, this update changed how the values work internally to make them easier to understand and consistent, the drawback is that you will have to readjust your settings.
t2hk 12 Aug, 2023 @ 4:24am 
The mod STILL WORKS!! You have to adjust the settings. Optionally keep the stamina bar / percentage visible to check if its working or not. I did it and its working like a charm again.
wiimeiser 11 Aug, 2023 @ 6:39pm 
@Fizzie The fact that the exact value at which they break is 32767/32768 suggests that whatever part of the game the lua is manipulating in its latest version (suit battery, for example) is a signed 16-bit short.
Fizzie 11 Aug, 2023 @ 3:35pm 
Why do the meters work the way they do? If you set them high enough, they just break, and don't actually display an accurate percentage.
Sprint has been totally broken somehow, either not letting you sprint, or just not consuming any stamina when you run.

I really want this mod to work well because it's the closest thing to being an actual good stamina, oxygen, AND flashlight mod, but ever since the newest update it's not functioning well. The bars have had the looping value problem exacerbated somehow.

I will give credit where it's due though, I love the addition of choosing how quickly stamina, air, and battery regenerate, even if it's a bit weird with how it works. I still appreciate it
Fizzie 10 Aug, 2023 @ 4:53pm 
Why can I not sprint at all when stamina is enabled?
bebralolka777 8 Aug, 2023 @ 7:04am 
this mod is broken :steamthumbsdown:
wiimeiser 6 Aug, 2023 @ 8:04pm 
@Skaian For me it only happens when max values for stamina and oxygen are set to 32768 or higher. This suggests a signed short is in use somewhere.
rtgeorge 6 Aug, 2023 @ 11:46am 
For some reason this makes my screen get insane motion blur whenever I move. Shame it's broken now. I wonder what happened.
Skaian 6 Aug, 2023 @ 5:43am 
Yep can confirm that the stamina bar is always depleted so the mod doesnt work now :(
wiimeiser 6 Aug, 2023 @ 4:07am 
Values over 32767 completely stop regeneration from working. I don't know what you did, but it seems the max values are now being interpreted as signed 16-bit shorts instead of the integers from before.