PDA

View Full Version : Tag mismatches DestroyAllLabels() function


Sellize
11/12/2016, 07:49 PM
stock DestroyAllLabels() // Destroy ALL 3d labels on the server
{
for(new i; i < MAX_3DTEXT_GLOBAL; i++)
{
if(IsValidDynamic3DTextLabel(i)) DestroyDynamic3DTextLabel(i);
}
return 1;
}

gm.pwn(106) : warning 213: tag mismatch
gm.pwn(106) : warning 213: tag mismatch

106 is the line with if(IsValidDynamic3DTextLabel(i))

What's wrong here?

Vince
11/12/2016, 07:58 PM
Use a tag override in this case.

if(IsValidDynamic3DTextLabel(Text3D:i)) DestroyDynamic3DTextLabel(Text3D:i);

Sellize
11/12/2016, 08:18 PM
Use a tag override in this case.

if(IsValidDynamic3DTextLabel(Text3D:i)) DestroyDynamic3DTextLabel(Text3D:i);

Confusing. I thought you only used that when creating the variable. It works, so thanks!