Strange warning 213: tag mismatch
#1

Why the fuck do I get these warnings?
pawn Код:
if(!strcmp(cmdtext, "/lock"))
    {
        if(IsPlayerConnected(playerid))
        {
          if(TmpCarKeys[playerid] == -1 && TmpCarKeys2[playerid] == -1)
          {
            SendClientMessage(playerid, RED, "Vous n'avez aucun vйhicule spawned.");
            return 1;
            }
            new Float:x, Float:y, Floart:z;
            new cartolock;
            GetVehiclePos(TmpCarKeys[playerid], x, y, z); // warning 213: tag mismatch
            if(TmpCarKeys[playerid] != -1 && TmpCarKeys2[playerid] == -1) cartolock = TmpCarKeys[playerid];
            if(TmpCarKeys2[playerid] != -1)
            {
              new Float:x2, Float:y2, Floart:z2;
              GetVehiclePos(TmpCarKeys2[playerid], x2, y2, z2); // warning 213: tag mismatch
              if(PlayerToPoint(10, playerid, x, y, z) && !PlayerToPoint(10, playerid, x2, y2, z2)) cartolock = TmpCarKeys[playerid]; // warning 213: tag mismatch x2
              else cartolock = TmpCarKeys2[playerid];
            }
            CarInfo[cartolock][cLock] = 1;
            format(string, sizeof(string), "Vous avez verrouillй les portes de votre %s", GetVehicleName(cartolock));
            SendClientMessage(playerid, YELLOW, string);
        }
        return 1;
    }
Reply
#2

Show us where you have defined TmpCarKeys
Reply
#3

top of the script, global variable:
pawn Код:
new TmpCarKeys[MAX_PLAYERS], TmpCarKeys2[MAX_PLAYERS];
And PlayerToPoint:
pawn Код:
stock PlayerToPoint(Float:radi, playerid, Float:x, Float:y, Float:z)
{
  if(IsPlayerConnected(playerid))
    {
        new Float:oldposx, Float:oldposy, Float:oldposz;
        new Float:tempposx, Float:tempposy, Float:tempposz;
        GetPlayerPos(playerid, oldposx, oldposy, oldposz);
        tempposx = (oldposx -x);
        tempposy = (oldposy -y);
        tempposz = (oldposz -z);
        if (((tempposx < radi) && (tempposx > -radi)) && ((tempposy < radi) && (tempposy > -radi)) && ((tempposz < radi) && (tempposz > -radi)))
        {
            return 1;
        }
    }
    return 0;
}
it works fine for the rest of the script..
Reply
#4

hah! I see why. Look at you x,y,z defines... "Floart:z;" I floart occasionally, but never in public.
Reply
#5

/facepalm...

Thanks for your quick answers =)
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)