I am trying to figure out a way to disable the ability to sprint and jump when I have no stamina left. I have a stamina system set up which decreases when you sprint or jump, however you can still continue to sprint and jump with 0 stamina. This is why I ask the question, can I disable the ability to sprint and jump if i have 0 stamina.?
I sort of understand what you mean but I am confused as too how I can check when I am below 0 stamina. I understand it but not sure on calling the right actions.
So this is how I have setup the whole stamina system, some of it comes from the tutorial on the forums by HorusHeretic (Sorry for all the links)
Ok now I’ actually confused. Shouldn’t it be like really easy?
If stamina is below or equal to 0 set “Is Sprinting” false. It’s that easy.
The nodes for that are real simple: “Get Current Stamina” into a “<=” node comparing it with 0. The pin to this branch goes into the fourth execution pin at the very beginning at your sequence node and if it throws true set “isSprinting” false.
In addition to what Erasio said, you should always clamp your stamina between zero and its max value, then check if its zero for a cleaner process. Type “Branch” after right clicking; it should give you an idea.