I've created an extensive Hunger,Thirst,Fatigue system using Status Effects and formulas. I did research, I read tutorials and forum. So far I am successful in making status effects for different levels of sleepiness that use a status value called Rest that decreased over time. (When rest is <90%, slightly drowsy effect is applied which lowers certain status values.)

I'm stuck at this part: (When rest <60%, you have a 1% chance of falling asleep per hour) the status effect handles the having rest<60% and would then activate another status effect of being asleep which restores rest.

I can't find how to make the formula wait 60 seconds before checking chance.
  • Use wait Node.
  • See, I've been looking for a Wait Node in formulas. Cant find it. So I just looked under AI and still cant find it...
  • Ok Wait Node is under Events -> Add -> Base -> Wait. Thank you man.
  • You can also use search function to find nodes. You won't need to remember where to find them if you start using search.
  • Yeah thats how I was certain that Wait was not under Formulas or AI, and I must say the filter by type fuction is also a godsend when making a status system as complicated as i am attempting. I stopped the tutorials at #33, and that was a mistake according to a conversation between Gamingislove and another user in another thread. I'm going to finish up the tutorial to completion now. Thx guys.
  • Yeah, formulas don't have wait due to, well, having to immediately calculate an outcome :)

    Depending on how complex you want to go, you could e.g. use global events or even status effects (which can also periodically use game events) for these kinds of system.
    E.g. via status effect, you can set up a falling asleep chance effect via the status effect's Game Events settings (they work pretty much like the status conditions, just use events instead of change status values). The event can do the chance check and apply the actual sleep status effect.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • Id recommend status effects for stuff like this, they give you a ton of control over when and how something is applied.
Sign In or Register to comment.