Make the player not die even though he would've died.
#1

Is there some way, possibly through OnPlayerTakeDamage or something like that, that if the player was supposed to die, his health reaching 0, that you can before he actually dies ingame recover his health to let's just say 100.

As far as I understand OnPlayerTakeDamage is a callback after the player has taken damage, is there someway to detect it before it actually happens somehow and that way prevent the kill?
Reply
#2

OnPlayerUpdate doesn't work.
Reply
#3

Quote:
Originally Posted by SaYrOn
Посмотреть сообщение
You can add a check under OnPlayerUpdate. It is called each 30ms, if I remember right, so you will catch if player's health is below 1, for example.
https://www.youtube.com/watch?v=umDr0mPuyQc

Don't use OnPlayerUpdate because it calls EVERY action of what the player make.

Use a custom timer,like HealthCheck (remember public and forward).
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)