Warning

Wichtiger Hinweis: Bitte ändert nicht manuell die Schriftfarbe auf schwarz sondern belasst es bei der Standardeinstellung. Somit tragt ihr dazu bei dass euer Text auch bei Verwendung unseren dunklen Forenstils noch lesbar ist!

Tipp: Ihr wollt längere Codeausschnitte oder Logfiles bereitstellen? Benutzt unseren eigenen PasteBin-Dienst Link
  • Hey,


    wieso kommt der Warning? ?(


    C:\Users\Narushi\Desktop\samp\New-Evolution-Reallife\gamemodes\SelfmadeBT.pwn(3756) : warning 213: tag mismatch
    Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase



    1 Warning.


    stock mysql_GetFloat(Table[], Field[], Where[], Is[])
    {
    new query[128], Float:sqlfloat;
    mysql_real_escape_string(Table, Table);
    mysql_real_escape_string(Field, Field);
    mysql_real_escape_string(Where, Where);
    mysql_real_escape_string(Is, Is);
    format(query, 128, "SELECT `%s` FROM `%s` WHERE `%s` = '%s'", Field, Table, Where, Is);
    mysql_query(query);
    mysql_store_result();
    mysql_fetch_float(sqlfloat);
    mysql_free_result();
    return sqlfloat; //Zeile
    }

  • stock mysql_GetFloat(Table[], Field[], Where[], Is[])
    {
    new query[128], Float:sqlfloat;
    mysql_real_escape_string(Table, Table);
    mysql_real_escape_string(Field, Field);
    mysql_real_escape_string(Where, Where);
    mysql_real_escape_string(Is, Is);
    format(query, 128, "SELECT `%s` FROM `%s` WHERE `%s` = '%s'", Field, Table, Where, Is);
    mysql_query(query);
    mysql_store_result();
    mysql_fetch_float(sqlfloat);
    mysql_free_result();
    return true; //Zeile
    }

    Mit freundlichen Grüßen,


    Fabi.StaR :love::saint:


  • Falsch mach es so:

    forward Float:mysql_GetFloat(Table[], Field[], Where[], Is[]);
    stock Float:mysql_GetFloat(Table[], Field[], Where[], Is[])
    {
    new query[128], Float:sqlfloat;
    mysql_real_escape_string(Table, Table);
    mysql_real_escape_string(Field, Field);
    mysql_real_escape_string(Where, Where);
    mysql_real_escape_string(Is, Is);
    format(query, 128, "SELECT `%s` FROM `%s` WHERE `%s` = '%s'", Field, Table, Where, Is);
    mysql_query(query);
    mysql_store_result();
    mysql_fetch_float(sqlfloat);
    mysql_free_result();
    return sqlfloat;
    }


    MFG Piet

  • Noch eine Frage.. Warum spawn mein Auto nicht?
    Versuche schon seit Stunden -.-"


    stock LoadPCars(playerid)
    {
    if(IsPlayerConnected(playerid) && !IsPlayerNPC(playerid))
    {
    GetPlayerName(playerid,PrivatCar[playerid][PlayerName], MAX_PLAYER_NAME);
    PrivatCar[playerid][privatColor1] = mysql_GetInt("privatcars", "Color1", "Name",PrivatCar[playerid][PlayerName]);
    PrivatCar[playerid][privatColor2] = mysql_GetInt("privatcars", "Color2", "Name",PrivatCar[playerid][PlayerName]);
    PrivatCar[playerid][CarName] = mysql_GetString("privatcars", "Autoname", "Name",PrivatCar[playerid][PlayerName]);
    PrivatCar[playerid][modelid] = mysql_GetInt("privatcars", "modelid", "Name",PrivatCar[playerid][PlayerName]);
    PrivatCar[playerid][pcX] = mysql_GetFloat("privarcars", "CarX", "Name",PrivatCar[playerid][PlayerName]);
    PrivatCar[playerid][pcY] = mysql_GetFloat("privarcars", "CarY", "Name",PrivatCar[playerid][PlayerName]);
    PrivatCar[playerid][pcZ] = mysql_GetFloat("privarcars", "CarZ", "Name",PrivatCar[playerid][PlayerName]);
    PrivatCar[playerid][pcA] = mysql_GetFloat("privarcars", "CarA", "Name",PrivatCar[playerid][PlayerName]);
    PrivatCar[playerid][HaveKey] = mysql_GetInt("privarcars", "HaveKey", "Name",PrivatCar[playerid][PlayerName]);
    PrivatCar[playerid][vehid] = mysql_GetInt("privarcars", "vehid", "Name",PrivatCar[playerid][PlayerName]);
    meinauto[playerid] = CreateVehicle(PrivatCar[playerid][modelid],PrivatCar[playerid][pcX],PrivatCar[playerid][pcY],PrivatCar[playerid][pcZ],PrivatCar[playerid][pcA],PrivatCar[playerid][privatColor1],PrivatCar[playerid][privatColor2],0);
    }
    return 1;
    }
    stock SavePCars(playerid)
    {
    if(IsPlayerConnected(playerid) && !IsPlayerNPC(playerid))
    {
    GetPlayerName(playerid,PrivatCar[playerid][PlayerName], MAX_PLAYER_NAME);
    mysql_SetInt("privatcars","Color1",PrivatCar[playerid][privatColor1],"Name", PrivatCar[playerid][PlayerName]);
    mysql_SetInt("privatcars","Color2",PrivatCar[playerid][privatColor2],"Name", PrivatCar[playerid][PlayerName]);
    mysql_SetString("privatcars","Autoname",VehicleName[GetVehicleModel(GetPlayerVehicleID(playerid))-400],"Name", PrivatCar[playerid][PlayerName]);
    mysql_SetInt("privatcars","modelid",GetVehicleModel(meinauto[playerid]),"Name", PrivatCar[playerid][PlayerName]);
    mysql_SetFloat("privatcars","CarX",PrivatCar[playerid][pcX],"Name", PrivatCar[playerid][PlayerName]);
    mysql_SetFloat("privatcars","CarY",PrivatCar[playerid][pcY],"Name", PrivatCar[playerid][PlayerName]);
    mysql_SetFloat("privatcars","CarZ",PrivatCar[playerid][pcZ],"Name", PrivatCar[playerid][PlayerName]);
    mysql_SetFloat("privatcars","CarA",PrivatCar[playerid][pcA],"Name", PrivatCar[playerid][PlayerName]);
    mysql_SetInt("privatcars","vehid",PrivatCar[playerid][vehid],"Name", PrivatCar[playerid][PlayerName]);
    mysql_SetInt("privatcars","HaveKey",PrivatCar[playerid][HaveKey],"Name", PrivatCar[playerid][PlayerName]);
    }
    }