Server zeigt Unknown

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
  • SkyLight ich bin Moritz ;)


    Öhh hab ein public wenn ich den raus nehme funktioniert alles


    forward LoadFracCars();
    public LoadFracCars()
    {
    dini_Create("LSPDCars.ini");
    new keystring[128];
    new platestring[8];
    for(new i = 0; i < sizeof(PolizeiVehs); i++)
    {
    format(keystring,sizeof(keystring), "Car%i_Model",i);
    fCarparkInfo[1] [i] [ModelId] = dini_Int("LSPDCars.ini",keystring);
    format(keystring,sizeof(keystring), "Car%i_X",i);
    fCarparkInfo[1] [i] [ParkX] = dini_Float("LSPDCars.ini",keystring);
    format(keystring,sizeof(keystring), "Car%i_Y",i);
    fCarparkInfo[1] [i] [ParkY] = dini_Float("LSPDCars.ini",keystring);
    format(keystring,sizeof(keystring), "Car%i_Z",i);
    fCarparkInfo[1] [i] [ParkZ] = dini_Float("LSPDCars.ini",keystring);
    format(keystring,sizeof(keystring), "Car%i_Angle",i);
    fCarparkInfo[1] [i] [ParkAngle] = dini_Float("LSPDCars.ini",keystring);
    if(fCarparkInfo[1] [i] [ModelId] >= 400 && fCarparkInfo[1] [i] [ModelId] <= 611)
    {
    PolizeiVehs[i] = CreateVehicle(fCarparkInfo[1] [i] [ModelId], fCarparkInfo[1] [i] [ParkX], fCarparkInfo[1] [i] [ParkY], fCarparkInfo[1] [i] [ParkZ], fCarparkInfo[1] [i] [ParkAngle], 79, 1, 900);
    format(platestring, sizeof(platestring), "SAPD ");
    SetVehicleNumberPlate(PolizeiVehs[i],platestring);
    }
    }
    return 1;
    }

  • Ich versteh dein sinn dabei nicht
    bei jeden start lässt du die datei LSPDCars.ini erstellen bei 20 serverstarts hast du die datei 20 mal
    frag doch leiber erst ab ob die exestiert
    ich hab den verdacht, das es daran liegt

    All in all it's just another brick in the wall

  • Na die werden nach /fpark gespeichert


    if(strcmp(cmd,"/fcarpark",true)==0 || strcmp(cmd,"/fpark",true)==0)
    {
    new vehi;
    new modelstring[45],xstring[45], ystring[45], zstring[45], anglestring[45];
    new Float:vehx, Float:vehy, Float:vehz;
    new vehmodel;
    new platestring[8];
    new Float:vehangle;
    vehi = GetPlayerVehicleID(playerid);
    GetVehicleZAngle(vehi, vehangle);
    vehmodel = GetVehicleModel(vehi);
    GetVehiclePos(vehi, vehx, vehy, vehz);
    if(PlayerInfo[playerid][pLeader] == 1 || PlayerInfo[playerid][pMember] == 1)
    {
    for(new i = 0; i < sizeof(PolizeiVehs); i++)
    {
    if(vehi == PolizeiVehs[i])
    {
    RemovePlayerFromVehicle(playerid);
    DestroyVehicle(PolizeiVehs[i]);
    PolizeiVehs[i] = CreateVehicle(vehmodel, vehx+0.5, vehy+0.5, vehz+0.5, vehangle, 79, 1, 900);
    format(platestring, sizeof(platestring), "SAPD");
    SetVehicleNumberPlate(PolizeiVehs[i],platestring);


    fCarparkInfo[1] [i] [ModelId] = vehmodel;
    fCarparkInfo[1] [i] [ParkX] = vehx;
    fCarparkInfo[1] [i] [ParkY] = vehy;
    fCarparkInfo[1] [i] [ParkZ] = vehz;
    fCarparkInfo[1] [i] [ParkAngle] = vehangle;


    format(modelstring,sizeof(modelstring), "Car%i_Model",i);
    dini_IntSet("LSPDCars.ini",modelstring,fCarparkInfo[1] [i] [ModelId]);


    format(xstring,sizeof(xstring), "Car%i_X",i);
    dini_FloatSet("LSPDCars.ini",xstring,fCarparkInfo[1] [i] [ParkX]);


    format(ystring,sizeof(ystring), "Car%i_Y",i);
    dini_FloatSet("LSPDCars.ini",ystring,fCarparkInfo[1] [i] [ParkY]);


    format(zstring,sizeof(zstring), "Car%i_Z",i);
    dini_FloatSet("LSPDCars.ini",zstring,fCarparkInfo[1] [i] [ParkZ]);


    format(anglestring,sizeof(anglestring), "Car%i_Angle",i);
    dini_FloatSet("LSPDCars.ini",anglestring,fCarparkInfo[1] [i] [ParkAngle]);
    }
    }
    }
    }

  • Gut guck dir das muster mal an und sag mir was dir auffällt in gegensatz zu deinen?
    format(data,sizeof data,"bizzes/%d.ini",i);
    if(dini_Exists(data))
    {
    format(biz[i][bOwner],MAX_PLAYER_NAME,"%s",dini_Get(data,"Owner"));
    biz[i][bOpen]=dini_Int(data,"Open");
    biz[i][bEnter]=dini_Int(data,"Enter");
    biz[i][bProds]=dini_Int(data,"Prods");
    bi2[i][bPP]=dini_Int(data,"PP");
    biz[i][bKasse]=dini_Int(data,"Kasse");
    biz[i][bPayentry]=dini_Int(data,"Payentry");
    format(biz[i][bName],45,"%s",dini_Get(data,"Name"));}


    sol sollte dein code in etwa aussehen

    All in all it's just another brick in the wall

  • wie geht es jetzt?
    wenn nich versuch ma das
    forward LoadFracCars();
    public LoadFracCars()
    {
    if(dini_Exists("LSPDCars.ini"))
    {
    new keystring[128];
    new platestring[8];
    for(new i = 0; i < sizeof(PolizeiVehs); i++)
    {
    format(keystring,sizeof(keystring), "Car%i_Model",i);
    fCarparkInfo[1] [i] [ModelId] = dini_Int("LSPDCars.ini",keystring);
    format(keystring,sizeof(keystring), "Car%i_X",i);
    fCarparkInfo[1] [i] [ParkX] = dini_Float("LSPDCars.ini",keystring);
    format(keystring,sizeof(keystring), "Car%i_Y",i);
    fCarparkInfo[1] [i] [ParkY] = dini_Float("LSPDCars.ini",keystring);
    format(keystring,sizeof(keystring), "Car%i_Z",i);
    fCarparkInfo[1] [i] [ParkZ] = dini_Float("LSPDCars.ini",keystring);
    format(keystring,sizeof(keystring), "Car%i_Angle",i);
    fCarparkInfo[1] [i] [ParkAngle] = dini_Float("LSPDCars.ini",keystring);
    if(fCarparkInfo[1] [i] [ModelId] >= 400 && fCarparkInfo[1] [i] [ModelId] <= 611)
    {
    PolizeiVehs[i] = CreateVehicle(fCarparkInfo[1] [i] [ModelId], fCarparkInfo[1] [i] [ParkX], fCarparkInfo[1] [i] [ParkY], fCarparkInfo[1] [i] [ParkZ], fCarparkInfo[1] [i] [ParkAngle], 79, 1, 900);
    format(platestring, sizeof(platestring), "SAPD ");
    SetVehicleNumberPlate(PolizeiVehs[i],platestring);
    }
    }
    }
    else
    {
    dini_Create("LSPDCars.ini");
    LoadFracCars();
    }
    return 1;
    }

    All in all it's just another brick in the wall

  • do.de - Domain-Offensive - Domains für alle und zu super Preisen