Player Health problem
#4

Whenever you use SetPlayerHealth, use this instead.
pawn Code:
SetPlayerHealthEx(playerid, 90.0); //example
And add this stock to your script.

pawn Code:
stock SetPlayerHealthEx(playerid,Float:health)
{
    SetPlayerHealth(playerid,health);
    PlayerInfo[playerid][pHealth] = health;
    return 1;
}
This way, your serverside health will equal the clientside health.

Don't forget to make your OnPlayerTakeDamage callbacks and everything use the new stock.
Reply


Messages In This Thread
Player Health problem - by Gilbonzo - 31.01.2014, 21:49
Re: Player Health problem - by MisterTickle - 31.01.2014, 22:48
Re: Player Health problem - by erminpr0 - 31.01.2014, 23:01
Re: Player Health problem - by EiresJason - 31.01.2014, 23:04
Re: Player Health problem - by Gilbonzo - 31.01.2014, 23:26
Re: Player Health problem - by CuervO - 31.01.2014, 23:54
Re: Player Health problem - by Gilbonzo - 01.02.2014, 10:03
Re: Player Health problem - by CuervO - 01.02.2014, 10:16

Forum Jump:


Users browsing this thread: 1 Guest(s)