Warning 213: Tag Mismatch..
#1

I wont say much.. just show the lines that the warnings are on..

2 Warnings here.
Код:
    	
new string[256];
new string2[256];
format(string, sizeof(string), "{228B22}[ {FFFFFF}%s (%d){228B22} ]",TeleportInfo[hid][TeleportName], hid);
format(string2, sizeof(string2), "{228B22}[ {FFFFFF}%s (%d){228B22} ]",TeleportInfo[hid][TeleportName], hid);
I understand that I need to add Float, but no idea where :S

Much appreciated.
Reply
#2

How do you define hid is it a loop?, for example this code won't show me Warning 213: Tag Mismatch
The code below is an example, there must be something wrong with your Enum or Variable/Definition/Loop

pawn Код:
enum TpInfo
{
    TeleportName
}
new TeleportInfo[200][TpInfo];
new hid;

new string[256];
format(string, sizeof(string), "{228B22}[ {FFFFFF}%s (%d){228B22} ]", TeleportInfo[hid][TeleportName], hid);
format(string, sizeof(string), "{228B22}[ {FFFFFF}%s (%d){228B22} ]", TeleportInfo[hid][TeleportName], hid);
Reply
#3

Does the warning tell you which argument has the tag mismatch?
Reply
#4

Код:
for(new t=0; t<=MAX_TELEPORTS; t++)
??
Reply
#5

Quote:
Originally Posted by Brandon_More
Посмотреть сообщение
Код:
for(new t=0; t<=MAX_TELEPORTS; t++)
??
If you're using t for the loop, where you get the hid because that's the one which gives the warnings.
Reply
#6

Код:
enum teleportInfo
{
	gTeleport,
	Text3D:TeleportName,
	Text3D:TeleportNameInside,
	gStartVirtualWorld,
	gEndVirtualWorld,
	gEndInterior,
	gStartInterior,
	Float:gstartCX,
	Float:gstartCY,
	Float:gstartCZ,
	Float:gendCX,
	Float:gendCY,
	Float:gendCZ
}
new TeleportInfo[MAX_TELEPORTS][teleportInfo];
Sorry really confused.. right now xD
Reply
#7

Quote:
Originally Posted by Brandon_More
Посмотреть сообщение
Код:
enum teleportInfo
{
	gTeleport,
	Text3D:TeleportName,
	Text3D:TeleportNameInside,
	gStartVirtualWorld,
	gEndVirtualWorld,
	gEndInterior,
	gStartInterior,
	Float:gstartCX,
	Float:gstartCY,
	Float:gstartCZ,
	Float:gendCX,
	Float:gendCY,
	Float:gendCZ
}
new TeleportInfo[MAX_TELEPORTS][teleportInfo];
Sorry really confused.. right now xD
We're asking how do you define hid is it an Enumerator, Variable or Definition?

should look something like this

pawn Код:
for(new hid = 0;  hid <= MAX_TELEPORTS; hid++)
EDIT: Maybe read Konstantinos reply below
Reply
#8

pawn Код:
Text3D:TeleportName
The warning is given by the Text3D: tag.

For string, you need to use an array.

pawn Код:
TeleportName[32],
Reply
#9

Here I will upload all...

Код:
F:\Completed Scripts\FS Test\filterscripts\Dynamic_Teleports.pwn(110) : warning 213: tag mismatch
F:\Completed Scripts\FS Test\filterscripts\Dynamic_Teleports.pwn(111) : warning 213: tag mismatch
F:\Completed Scripts\FS Test\filterscripts\Dynamic_Teleports.pwn(161) : warning 213: tag mismatch
F:\Completed Scripts\FS Test\filterscripts\Dynamic_Teleports.pwn(162) : warning 213: tag mismatch
Код:
#define MAX_TELEPORTS 1001 //You can edit this at any point..
enum teleportInfo
{
	gTeleport,
	TeleportName[32],
	TeleportNameInside[32],
	gStartVirtualWorld,
	gEndVirtualWorld,
	gEndInterior,
	gStartInterior,
	Float:gstartCX,
	Float:gstartCY,
	Float:gstartCZ,
	Float:gendCX,
	Float:gendCY,
	Float:gendCZ
}
new TeleportInfo[MAX_TELEPORTS][teleportInfo];
Код:
stock CreateNewTeleport(hid)
{
	new file[64];
    format(file,sizeof(file),"teleports/teleport%d.txt",hid);
    new Float: X, Float: Y, Float: Z, Float: SX, Float: SY, Float: SZ;
    X = dini_Float(file,"startfloatx");
 	Y = dini_Float(file,"startfloaty");
 	Z = dini_Float(file,"startfloatz");
 	SX = dini_Float(file,"endfloatx");
 	SY = dini_Float(file,"endfloaty");
 	SZ = dini_Float(file,"endfloatz");
    new R = dini_Int(file,"teleportid");
    new Q = dini_Int(file,"startvirtualworld");
    new W = dini_Int(file,"startinterior");
    new QQ = dini_Int(file,"endtinterior");
    new WW = dini_Int(file,"endtvirtualworld");
	if(dini_Exists(file))
	{
		TeleportInfo[hid][gStartVirtualWorld] = Q;
		TeleportInfo[hid][gStartInterior] = W;
		TeleportInfo[hid][gEndVirtualWorld] = WW;
		TeleportInfo[hid][gEndInterior] = QQ;
	    TeleportInfo[hid][gTeleport] = R;
		TeleportInfo[hid][gstartCX] = X;
		TeleportInfo[hid][gstartCY] = Y;
		TeleportInfo[hid][gstartCZ] = Z;
		TeleportInfo[hid][gendCX] = SX;
		TeleportInfo[hid][gendCY] = SY;
		TeleportInfo[hid][gendCZ] = SZ;
		new string[256];
		new string2[256];
    	format(string, sizeof(string), "{228B22}[ {FFFFFF}%s (%d){228B22} ]",TeleportInfo[hid][TeleportName], hid);
    	format(string2, sizeof(string2), "{228B22}[ {FFFFFF}%s (%d){228B22} ]",TeleportInfo[hid][TeleportName], hid);
		TeleportInfo[hid][TeleportName] = CreateDynamic3DTextLabel(string, 0xFFFFFFFF, TeleportInfo[hid][gstartCX], TeleportInfo[hid][gstartCY], TeleportInfo[hid][gstartCZ], 10);
		TeleportInfo[hid][TeleportNameInside] = CreateDynamic3DTextLabel(string2, 0xFFFFFFFF, TeleportInfo[hid][gendCX], TeleportInfo[hid][gendCY], TeleportInfo[hid][gendCZ], 10);
	}
	print("Teleports loaded successfully.");
	return 1;
}

stock LoadTeleports()
{
	new file[64];
	for(new hid=0; hid<=MAX_TELEPORTS; hid++)
	{
	    format(file,sizeof(file),"teleports/teleport%d.txt",hid);
	    new Float: X, Float: Y, Float: Z, Float: SX, Float: SY, Float: SZ;
	    X = dini_Float(file,"startfloatx");
	 	Y = dini_Float(file,"startfloaty");
	 	Z = dini_Float(file,"startfloatz");
	 	SX = dini_Float(file,"endfloatx");
	 	SY = dini_Float(file,"endfloaty");
	 	SZ = dini_Float(file,"endfloatz");
        new R = dini_Int(file,"teleportid");
        new Q = dini_Int(file,"startvirtualworld");
        new W = dini_Int(file,"endinterior");
	    new QQ = dini_Int(file,"endtinterior");
	    new WW = dini_Int(file,"endtvirtualworld");
		if(dini_Exists(file))
		{
		    TeleportInfo[hid][gTeleport] = R;
			TeleportInfo[hid][gStartVirtualWorld] = Q;
			TeleportInfo[hid][gStartInterior] = W;
			TeleportInfo[hid][gEndVirtualWorld] = WW;
			TeleportInfo[hid][gEndInterior] = QQ;
			TeleportInfo[hid][gstartCX] = X;
			TeleportInfo[hid][gstartCY] = Y;
			TeleportInfo[hid][gstartCZ] = Z;
			TeleportInfo[hid][gendCX] = SX;
			TeleportInfo[hid][gendCY] = SY;
			TeleportInfo[hid][gendCZ] = SZ;
			new string[256];
			new string2[256];
	    	format(string, sizeof(string), "{228B22}[ {FFFFFF}%s (%d){228B22} ]",TeleportInfo[hid][TeleportName], hid);
	    	format(string2, sizeof(string2), "{228B22}[ {FFFFFF}%s (%d){228B22} ]",TeleportInfo[hid][TeleportName], hid);
			TeleportInfo[hid][TeleportName] = CreateDynamic3DTextLabel(string, 0xFFFFFFFF, TeleportInfo[hid][gstartCX], TeleportInfo[hid][gstartCY], TeleportInfo[hid][gstartCZ], 10);
			TeleportInfo[hid][TeleportNameInside] = CreateDynamic3DTextLabel(string2, 0xFFFFFFFF, TeleportInfo[hid][gendCX], TeleportInfo[hid][gendCY], TeleportInfo[hid][gendCZ], 10);
		}
	}
	print("Teleports loaded successfully.");
	return 1;
}
Reply
#10

I have added String Array and doing same shit..
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)