anyone know how i would make health regen a thing? wanted to add a slow hp regen into mine (to test)
being honest with you I had a slight problem with it at the very beginning. Namely, my main concept was to use the command "openborvariant("elapsed_time")" which allows us to retrieve the time since the creation of this variable. Thanks to this, the variable that would have it would act as a kind of Timer. The problem with this is that for some reason this time can't be reset to zero or counted down from scratch, which made my job difficult.
However, I was helped by what
WeebLoop wrote, namely the sentence:
"Every X amount of
ticks, HP +Y. "
And thanks to this I was reminded that it is possible to create a file named: "timetick.c", which runs with each game tick.
And this allowed me to create a timer in this file, which I could already reset. With this, all I had to do was add a single if, a couple of commands and that was it.
I've provided the file below, which you just need to add to the "data/Scripts/" folder.
If anyone is curious about how exactly it works and how to configure it, I explain it more below.
P.s I'm surprised I came up with this at 01:00 a.m where I'm already slowly starting to fall asleep xd
View attachment timetick.zip