Making use of Suit Power/Aux Power

Is there any way to get or modify of the Aux Power/Suit Power from within a game mode using lua? I’ve scoured all over the wiki and the net, but I can’t find any information about it, or even information about not being able to do it. It would be incredibly nice to tap into this for a few things within my game mode, and if not I think I am going to have to somehow disable it and replace everything that uses aux power with something not nearly as clean. Or perhaps I’ll just have to let run and flashlight stay as they are and make everything else use my own solution.

Also, is there any way to do the same with flashlight power, or at least make the flashlight last indefinitely?

Thank you in advance for any replies.

-whatever,snip-

I don’t think it’s removed, I think sv_infinite_aux_power is just set to 1 by default.

Yeah, it’s set to 1 by default, but I want to emulate that effect if I cannot just tap into suit power. I have limited running working; tested across multiple machines too. It’s not just removed, I just think there’s no way to access it and change it through lua, which makes me sad. It really would be useful to tap into for things such as game modes. I also somehow have limited flashlight, though if this is not normal I can’t tell you how I did it.

Thank you for your replies however; insight into the issue is much appreciated.

If you search on gmod.org you can find a addon that add a limited swep flashlight or limits the hl2 flashlight ( cant remember ).

The command “sv_infinite_aux_power” is set to 0 for me.

The aux power is also called Stanimo… Might want to look for it on facepunch / garrysmod.org

Maybe you have it installed without knowing it.

Thanks for the replies, though no one had a clear answer on whether or not the suit system could be accessed within a game mode. It certainly seems like a no even through hackish means, so I went and remade it on my own.

I made a nice pretty Energy class that drains energy when the player runs (underwater breathing forthcoming) and replaces the inbuilt running controls. It also can be used to fly and will be tapped into for other abilities within the game mode. When nothing is draining power, it starts regenerating energy again. It’s all displayed on a pretty little bar on the screen too, though this is part of the UI for my game mode.

In short to anyone who might attempt to do this in the future, your only option appears to be replacing the inbuilt system.

Since it was requested by someone 6 years later, here’s what I did. I haven’t tested this in 5 years, and it is likely based off of outdated fretta gamemode stuff, but in case it’s useful, I threw it on pastebin here: http://pastebin.com/R9Spya0s