Tag mismatch - 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: Tag mismatch (
/showthread.php?tid=646207)
Tag mismatch -
Barnwell - 12.12.2017
I don't know what's the problem here.
C:\Users\Nevinn\Desktop\HCRP\gamemodes\HCRPpwn(480 6) : warning 213: tag mismatch
C:\Users\Nevinn\Desktop\HCRP\gamemodes\HCRP.pwn(48 07) : warning 213: tag mismatch
pawn Код:
GetPlayerHealth(playerid,PlayerInfo[playerid][pHealth]);
GetPlayerArmour(playerid,PlayerInfo[playerid][pArmour]);
Re: Tag mismatch -
aoky - 12.12.2017
PHP код:
new Float:armour;
new Float:health;
PHP код:
GetPlayerHealth(playerid, health);
GetPlayerArmour(playerid, armour);
Re: Tag mismatch -
RogueDrifter - 12.12.2017
the health and armour parameters must be float mate, aoky's example explains it perfectly.
Re: Tag mismatch -
Xeon™ - 12.12.2017
PHP код:
GetPlayerHealth(playerid,PlayerInfo[playerid][pHealth]);
GetPlayerArmour(playerid,PlayerInfo[playerid][pArmour]);
pArmour and pHealth should have the Float: tag.
something like this on your script
PHP код:
enum
{
Float:pHealth,
Float:pArmour
}
for once, RogerDrifter try to help people in their code not on your code.
Re: Tag mismatch -
Barnwell - 12.12.2017
Thanks alot Xeon!
+Rep
Re: Tag mismatch -
RogueDrifter - 12.12.2017
Quote:
Originally Posted by Xeon™
PHP код:
GetPlayerHealth(playerid,PlayerInfo[playerid][pHealth]);
GetPlayerArmour(playerid,PlayerInfo[playerid][pArmour]);
pArmour and pHealth should have the Float: tag.
something like this on your script
PHP код:
enum
{
Float:pHealth,
Float:pArmour
}
for once, RogerDrifter try to help people in their code not on your code.
|
Wait sorry what do u mean? what was wrong about my statement or aoky's?
Re: Tag mismatch -
Xeon™ - 13.12.2017
Quote:
Originally Posted by RogueDrifter
Wait sorry what do u mean? what was wrong about my statement or aoky's?
|
he is using an enum to organize his code instead of creating a variable for players or a single global one.
so instead of adding another variable to do this. he can simply edit his enum by adding Float: tag to the element missed.
Re: Tag mismatch -
RogueDrifter - 13.12.2017
Quote:
Originally Posted by Xeon™
he is using an enum to organize his code instead of creating a variable for players or a single global one.
so instead of adding another variable to do this. he can simply edit his enum by adding Float: tag to the element missed.
|
Ahh yeah i get what you mean, thanks.