[SOLVED] Health stuff - Help please! - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: [SOLVED] Health stuff - Help please! (
/showthread.php?tid=89735)
[SOLVED] Health stuff - Help please! -
Mowgli - 03.08.2009
solvde
Re: [HELP] -
saiberfun - 03.08.2009
well couldn't u tell the ppl how u solved ur probs?
and change ur subject to [SOLVED]?
Re: [HELP] -
Mowgli - 04.08.2009
Quote:
Originally Posted by saiberfun
well couldn't u tell the ppl how u solved ur probs?
and change ur subject to [SOLVED]?
|
i got this new problem now
Re: [HELP] Health stuff - Help please! -
Correlli - 04.08.2009
I believe you're saving player's health in float format.
so, you should change this:
pawn Код:
new hp = PlayerInfo[playerid][pHealth];
to:
pawn Код:
new Float:hp = PlayerInfo[playerid][pHealth];
Re: [HELP] Health stuff - Help please! -
Mowgli - 04.08.2009
Quote:
Originally Posted by Don Correlli
I believe you're saving player's health in float format.
so, you should change this:
pawn Код:
new hp = PlayerInfo[playerid][pHealth];
to:
pawn Код:
new Float:hp = PlayerInfo[playerid][pHealth];
|
i tried that and then when i did
setplayerhealth(playerid,float:hp);
that had tag mismatch
Re: [HELP] Health stuff - Help please! -
Correlli - 04.08.2009
Use:
pawn Код:
SetPlayerHealth(playerid, hp);
without Float: in front of hp.
If that doesn't work, then use:
pawn Код:
SetPlayerHealth(playerid, floatround(hp));
Re: [HELP] Health stuff - Help please! -
Mowgli - 04.08.2009
Both Have tag mis match
Код:
new float:hp = PlayerInfo[playerid][pHealth];
SetPlayerHealth(playerid, hp);
Re: [HELP] Health stuff - Help please! -
Correlli - 04.08.2009
Quote:
Originally Posted by Mowgli
Both Have tag mis match
Код:
new float:hp = PlayerInfo[playerid][pHealth];
SetPlayerHealth(playerid, hp);
|
I told you to use
Float:hp and not
float:hp.
Re: [HELP] Health stuff - Help please! -
Mowgli - 04.08.2009
ahaha , i neede F not f this whole time...thanks!
Re: [HELP] Health stuff - Help please! -
Correlli - 04.08.2009
You're welcome.