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)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Tag mismatch (
/showthread.php?tid=126051)
Tag mismatch -
NewYorkRP - 06.02.2010
- This is the line it says tag mismatch = PlayerInfo[i][pArmour] = armour;
i get an warning = Tag mismatch, my code is:
Код:
new Float:armour;
GetPlayerArmour(i, armour);
SetPlayerArmour(i, armour);
PlayerInfo[i][pArmour] = armour;
OnPlayerUpdate(i);
:S
Re: Tag mismatch -
Correlli - 06.02.2010
Is
pArmour a float value?
Re: Tag mismatch -
NewYorkRP - 06.02.2010
It's the same as pLevel, pCash, in LA-RP/Godfather...?
Re: Tag mismatch -
Correlli - 06.02.2010
It should be a float value, like
Float
Armour or you could use a floatround function to round it to an integer.
Re: Tag mismatch -
NewYorkRP - 06.02.2010

, it works with other things, this is my whole code...
Код:
public CheckArmour()
{
for (new i=0; i < MAX_PLAYERS; i++)
{
if (IsPlayerConnected(i))
{
new Float:armour;
GetPlayerArmour(i, armour);
SetPlayerArmour(i, armour);
PlayerInfo[i][pArmour] = armour;
OnPlayerUpdate(i);
}
}
}
pArmour is just stored as a number, and on login it sets that number to the players armour.
SetPlayerArmour(playerid, PlayerInfo[playerid][pArmour]); - That works on login.