SA-MP Forums Archive
warning 213: tag mismatch - one line only - 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: warning 213: tag mismatch - one line only (/showthread.php?tid=399027)



warning 213: tag mismatch - one line only - Saddin - 12.12.2012

(37083) : warning 213: tag mismatch

Here is the line:
Код:
public OnPlayerUnPause(playerid)
{
    DeletePlayer3DTextLabel(playerid, AfkLabel[playerid]); //this is the line with warning
    return 1;
}



Re: warning 213: tag mismatch - one line only - LarzI - 12.12.2012

Is AfkLabel assigned to Create3DTextLabel? Because if it's not, then that's why you get the error.
Please show where you assign AfkLabel[playerid].


Re: warning 213: tag mismatch - one line only - Saddin - 12.12.2012

AfkLabel[playerid] = Create3DTextLabel("OVAJ IGRAČ \n JE PAUZIRAN",0x2A6CD699,0,0,0,50,-1,1);
Attach3DTextLabelToPlayer(AfkLabel[playerid], playerid, 0,0,0);


Re: warning 213: tag mismatch - one line only - InActtive™ - 12.12.2012

Quote:
Originally Posted by Saddin
Посмотреть сообщение
AfkLabel[playerid] = Create3DTextLabel("OVAJ IGRAČ \n JE PAUZIRAN",0x2A6CD699,0,0,0,50,-1,1);
Attach3DTextLabelToPlayer(AfkLabel[playerid], playerid, 0,0,0);
I don't think that little bit of code will help someone figure out your problem, you have anymore instances of your AfkLabel anywhere in your code?


Re: warning 213: tag mismatch - one line only - Saddin - 12.12.2012

Код:
new Text3D:AfkLabel[MAX_PLAYERS];
Код:
public OnPlayerPause(playerid)
{
    AfkLabel[playerid] = Create3DTextLabel("OVAJ IGRAČ \n JE PAUZIRAN",0x2A6CD699,0,0,0,50,-1,1);
	Attach3DTextLabelToPlayer(AfkLabel[playerid], playerid, 0,0,0);
    return 1;
}
public OnPlayerUnPause(playerid)
{
    DeletePlayer3DTextLabel(playerid, AfkLabel[playerid]);
    return 1;
}
This is all.


Re: warning 213: tag mismatch - one line only - [HK]Ryder[AN] - 12.12.2012

This is because, you are creating a normal 3D Text label, but trying to remove it with a Player 3d text label..
change the code to this
pawn Код:
Delete3DTextLabel(AfkLabel[playerid]);