SA-MP Forums Archive
Help error 001: expected token: ";", but found "-identifier-" - 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)
+--- Thread: Help error 001: expected token: ";", but found "-identifier-" (/showthread.php?tid=574894)



Help error 001: expected token: ";", but found "-identifier-" - Izaki - 21.05.2015

error 001: expected token: ";", but found "-identifier-"

Quote:

public vitals(playerid)
{
new string[5];
new FloatHealth

GetPlayerHealth(playerid,pHealth);
format(string, sizeof(string), "%.0f%", pHealth);
TextDrawSetString(Health[playerid], string);
}

You managed to help me

I would love reputation


Re: Help error 001: expected token: ";", but found "-identifier-" - Izaki - 21.05.2015

(1156) : error 001: expected token: ";", but found "-identifier-"

Quote:

GetPlayerHealth(playerid,pHealth); << 1156




Re: Help error 001: expected token: ";", but found "-identifier-" - rappy93 - 21.05.2015

Try this :

PHP код:
public vitals(playerid)
{
    new 
string[5];
    new 
Float:Health;
    
GetPlayerHealth(playerid,pHealth);
    
format(stringsizeof(string), "%.0f%"pHealth);
    
TextDrawSetString(Health[playerid], string);




Re: Help error 001: expected token: ";", but found "-identifier-" - Izaki - 21.05.2015

Thanks bro

Nice work

Rep++


Re: Help error 001: expected token: ";", but found "-identifier-" - rappy93 - 21.05.2015

You're welcome , always gotta be careful for them little typos