:: Habe 4 Errors bei einem Tank Filterscript ::

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
  • \tank.pwn(151) : error 012: invalid function call, not a valid address
    \tank.pwn(151) : warning 215: expression has no effect
    \tank.pwn(151) : error 001: expected token: ";", but found ")"
    \tank.pwn(151) : error 029: invalid expression, assumed zero
    \tank.pwn(151) : fatal error 107: too many error messages on one line


    Compilation aborted.Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase



    4 Errors.
    Hier der Komplette Script


    #define TANK_SYS
    #include <a_samp>
    #include sscanf
    #define WHITE 0xF6F6F6FF
    #define YELLOW 0xF6F600F6
    new IstAnderTanke;
    new Zwischensumme;
    new Float:SavedPOSx[MAX_PLAYERS],Float:SavedPOSy[MAX_PLAYERS],Float:SavedPOSz[MAX_PLAYERS];
    new Text:TT_0[MAX_PLAYERS];
    #if defined TANK_SYS
    new Text:TT_1[MAX_PLAYERS];
    #endif
    new Text:TT_2;
    new Text:TT_3;
    new Text:TT_4;
    enum fahrzeug
    {
    tank,
    hat_tank,
    }
    new AUTOX[MAX_VEHICLES][fahrzeug];
    public OnFilterScriptInit()
    {
    print("\n--------------------------------------");
    print(" TankSystem von Lonsdale");
    print("--------------------------------------\n");
    // Lokale Textdraws
    TT_2 = TextDrawCreate(101.000000,344.000000," /");
    TT_3 = TextDrawCreate(125.000000,340.000000,"--------");
    TT_4 = TextDrawCreate(117.000000,410.000000," ");
    TextDrawAlignment(TT_2,0);
    TextDrawAlignment(TT_3,0);
    TextDrawAlignment(TT_4,0);
    TextDrawBackgroundColor(TT_2,0x000000ff);
    TextDrawBackgroundColor(TT_3,0x000000ff);
    TextDrawBackgroundColor(TT_4,0x000000ff);
    TextDrawFont(TT_2,3);
    TextDrawLetterSize(TT_2,1.000000,1.000000);
    TextDrawFont(TT_3,3);
    TextDrawLetterSize(TT_3,1.000000,1.000000);
    TextDrawFont(TT_4,3);
    TextDrawLetterSize(TT_4,1.000000,1.000000);
    TextDrawColor(TT_2,0x000000ff);
    TextDrawColor(TT_3,0x000000ff);
    TextDrawColor(TT_4,0x000000ff);
    TextDrawSetOutline(TT_2,1);
    TextDrawSetOutline(TT_3,1);
    TextDrawSetOutline(TT_4,1);
    TextDrawSetProportional(TT_2,1);
    TextDrawSetProportional(TT_3,1);
    TextDrawSetProportional(TT_4,1);
    TextDrawSetShadow(TT_2,1);
    TextDrawSetShadow(TT_3,1);
    TextDrawSetShadow(TT_4,1);
    SetTimer("UpdateSpeed",1000,1);
    #if defined TANK_SYS
    SetTimer("Update_Tank",18000,1);
    for(new i = 0;i<MAX_VEHICLES;i++)
    {
    AUTOX[i][tank] = (100);
    AUTOX[i][hat_tank] = (1);
    }
    #endif
    return 1;
    }
    public OnPlayerConnect(playerid)
    {


    #if defined TANK_SYS
    TT_1[playerid] = TextDrawCreate(141.000000,382.000000,"Tank : 100/100");
    TextDrawUseBox(TT_1[playerid],1);
    TextDrawBoxColor(TT_1[playerid],0x00000099);
    TextDrawTextSize(TT_1[playerid],250.000000,0.000000);
    TextDrawAlignment(TT_1[playerid],0);
    TextDrawBackgroundColor(TT_1[playerid],0x000000ff);
    TextDrawFont(TT_1[playerid],3);
    TextDrawLetterSize(TT_1[playerid],0.399999,1.000000);
    TextDrawColor(TT_1[playerid],0xffffffff);
    TextDrawSetOutline(TT_1[playerid],1);
    TextDrawSetProportional(TT_1[playerid],1);
    TextDrawSetShadow(TT_1[playerid],1);
    #endif

    return 1;
    }


    public OnPlayerDisconnect(playerid, reason)
    {
    TextDrawDestroy(TT_0[playerid]);
    #if defined TANK_SYS
    TextDrawDestroy(TT_1[playerid]);
    #endif
    TextDrawHideForPlayer(playerid,TT_2);
    TextDrawHideForPlayer(playerid,TT_3);
    TextDrawHideForPlayer(playerid,TT_4);
    return 1;
    }


    public OnPlayerCommandText(playerid, cmdtext[])
    {
    #if defined TANK_SYS
    if (strcmp("/tanken", cmdtext, true) == 0)
    {
    if(IsPlayerConnected(playerid))
    {
    if(GetPlayerState(playerid) == 2)
    {
    new vehicleids = GetPlayerVehicleID(playerid);
    if(IstAnDerTanke(playerid) && !NoCar(vehicleids))
    {
    new ZwischenSumme;
    ZwischenSumme = 100 - AUTOX[vehicleids][tank];
    AUTOX[vehicleids][tank] += ZwischenSumme;
    GivePlayerMoney(playerid,-ZwischenSumme * 3);
    GameTextForPlayer(playerid,"~b~Auto ~r~wurde getankt",2000,0);
    new forS[128];
    format(forS,sizeof(forS),"* Du hast dein Auto fuer %d $ Getankt *",ZwischenSumme);
    SendClientMessage(playerid,YELLOW,forS);
    }
    else
    {
    SendClientMessage(playerid,WHITE,"* Du musst an einer Tankstelle sein! *");
    }
    }
    }
    return 1;
    }
    if (strcmp("/raus", cmdtext, true) == 0)
    {
    RemovePlayerFromVehicle(playerid);
    TogglePlayerControllable(playerid,1);
    return 1;
    }
    dcmd(raus,4,cmdtext);
    dcmd(tanken,6,cmdtext);
    #endif
    return 0;
    }


    dcmd_raus(playerid, params[]) {
    #pragma unused params
    RemovePlayerFromVehicle(playerid);
    TogglePlayerControllable(playerid,true);
    return 1;
    }


    dcmd_tanken(playerid, params[]) {
    if(GetPlayerState(playerid) != 2) return 1;
    new
    vehid = GetPlayerVehicleID(playerid);
    if(IstAnderTanke(playerid) && !NoCar(vehid)) {
    new ZwischenSumme = 100 - AUTOX[vehid][tank];
    AUTOX[vehid][tank] += ZwischenSumme;
    GivePlayerMoney(playerid,-Zwischensumme*3);
    GameTextForPlayer(playerid,"~b~Auto~r~ wurde getankt",2000,0);
    new forstr[64];
    format(forstr, sizeof(forstr),"* Du hast dein Auto fuer %d $ aufgetankt *", ZwischenSumme);
    SendClientMessage(playerid, YELLOW, forstr);
    }
    else return SendClientMessage(playerid,WHITE,"* Du musst an einer Tankstelle sein! *");
    return 1;
    }
    public OnPlayerStateChange(playerid, newstate, oldstate)
    {
    new vehicleid = GetPlayerVehicleID(playerid);
    if(newstate == 2)
    {
    new tankx[128];
    TextDrawShowForPlayer(playerid,TT_0[playerid]);
    TextDrawShowForPlayer(playerid,TT_1[playerid]);
    TextDrawShowForPlayer(playerid,TT_2);
    TextDrawShowForPlayer(playerid,TT_3);
    TextDrawShowForPlayer(playerid,TT_4);
    format(tankx,sizeof tankx,"Tank : %d/100",AUTOX[vehicleid][tank]);
    TextDrawSetString(TT_1[playerid],tankx);
    }
    else if(newstate == 1)
    {

    TextDrawHideForPlayer(playerid,TT_0[playerid]);
    #if defined TANK_SYS
    TextDrawHideForPlayer(playerid,TT_1[playerid]);
    #endif
    TextDrawHideForPlayer(playerid,TT_2);
    TextDrawHideForPlayer(playerid,TT_3);
    TextDrawHideForPlayer(playerid,TT_4);
    }
    return 1;
    }


    forward PlayerToPoint(Float:radi, playerid, Float:xs, Float:ys, Float:zs);


    forward IstAnDerTanke(playerid);
    public IstAnDerTanke(playerid)
    {
    if(IsPlayerConnected(playerid))
    {
    if(PlayerToPoint(6.0,playerid,1004.0070,-939.3102,42.1797) || PlayerToPoint(6.0,playerid,1944.3260,-1772.9254,13.3906))
    {
    return 1;
    }
    else if(PlayerToPoint(6.0,playerid,-90.5515,-1169.4578,2.4079) || PlayerToPoint(6.0,playerid,-1609.7958,-2718.2048,48.5391))
    {
    return 1;
    }
    else if(PlayerToPoint(6.0,playerid,-2029.4968,156.4366,28.9498) || PlayerToPoint(8.0,playerid,-2408.7590,976.0934,45.4175))
    {
    return 1;
    }
    else if(PlayerToPoint(5.0,playerid,-2243.9629,-2560.6477,31.8841) || PlayerToPoint(8.0,playerid,-1676.6323,414.0262,6.9484))
    {
    return 1;
    }
    else if(PlayerToPoint(6.0,playerid,2202.2349,2474.3494,10.5258) || PlayerToPoint(10.0,playerid,614.9333,1689.7418,6.6968))
    {
    return 1;
    }
    else if(PlayerToPoint(8.0,playerid,-1328.8250,2677.2173,49.7665) || PlayerToPoint(6.0,playerid,70.3882,1218.6783,18.5165))
    {
    return 1;
    }
    else if(PlayerToPoint(8.0,playerid,2113.7390,920.1079,10.5255) || PlayerToPoint(6.0,playerid,-1327.7218,2678.8723,50.0625))
    {
    return 1;
    }
    }
    return 0;
    }
    public PlayerToPoint(Float:radi, playerid, Float:xs, Float:ys, Float:zs)
    {
    if(IsPlayerConnected(playerid))
    {
    new Float:oldposx, Float:oldposy, Float:oldposz;
    new Float:tempposx, Float:tempposy, Float:tempposz;
    GetPlayerPos(playerid, oldposx, oldposy, oldposz);
    tempposx = (oldposx -xs);
    tempposy = (oldposy -ys);
    tempposz = (oldposz -zs);
    if (((tempposx < radi) && (tempposx > -radi)) && ((tempposy < radi) && (tempposy > -radi)) && ((tempposz < radi) && (tempposz > -radi)))
    {
    return 1;
    }
    }
    return 0;
    }
    forward Update_Tank();
    public Update_Tank()
    {
    for(new i = 0;i<MAX_PLAYERS;i++)
    {
    if(GetPlayerState(i) == 2)
    {
    if(IsPlayerConnected(i))
    {
    new vehicleid = GetPlayerVehicleID(i);
    new tank_format[128];
    if(AUTOX[vehicleid][tank] > 1)
    {
    if(!NoCar(vehicleid))
    {
    AUTOX[vehicleid][tank]--;
    format(tank_format,sizeof tank_format,"Tank : %d/100",AUTOX[vehicleid][tank]);
    TextDrawSetString(TT_1[i],tank_format);
    AUTOX[vehicleid][hat_tank] = 1;
    }
    else
    {
    TextDrawSetString(TT_1[i],"Tank : N/A");
    AUTOX[vehicleid][hat_tank] = 1;
    }
    }
    else
    {
    if(!NoCar(vehicleid))
    {
    TextDrawSetString(TT_1[i],"Tank Leer");
    AUTOX[vehicleid][hat_tank] = 0;
    TogglePlayerControllable(i,0);
    }
    }
    }
    }
    }
    return 1;
    }
    stock NoCar(vehicleid)
    {
    new modell = GetVehicleModel(vehicleid);
    switch(modell)
    {
    // Helis ( waere auch zu unrealistisch wenn die Dinger Freezed wären :/ )
    case 548:return 1;
    case 425:return 1;
    case 417:return 1;
    case 487:return 1;
    case 488:return 1;
    case 497:return 1;
    case 563:return 1;
    case 447:return 1;
    case 469:return 1;
    // RC
    case 464:return 1;
    case 465:return 1;
    case 501:return 1;
    case 564:return 1;
    case 594:return 1;
    // Trailer / Angeanger
    case 435:return 1;
    case 450:return 1;
    case 591:return 1;
    case 606:return 1;
    case 607:return 1;
    case 610:return 1;
    case 569:return 1;
    case 590:return 1;
    case 584:return 1;
    case 570:return 1;
    case 608:return 1;
    case 611:return 1;
    // Flugzeuge ( waere auch zu unrealistisch wenn die Dinger Freezed wären :/ ) ²
    case 592:return 1;
    case 577:return 1;
    case 511:return 1;
    case 512:return 1;
    case 593:return 1;
    case 520:return 1;
    case 553:return 1;
    case 476:return 1;
    case 519:return 1;
    case 460:return 1;
    case 513:return 1;
    // Zuege & andere non Cars
    case 485:return 1;
    case 538:return 1;
    case 457:return 1;
    case 530:return 1;
    case 537:return 1;
    case 571:return 1;
    case 572:return 1;
    case 574:return 1;
    case 449:return 1;
    }
    return 0;
    }


    [size=18][color=#000099][font='Comic Sans MS, sans-serif'][b]

  • :pinch:

    Spoiler anzeigen


    #define TANK_SYS
    #include <a_samp>
    #include sscanf
    #define dcmd(%1,%2,%3) if (!strcmp((%3)[1], #%1, true, (%2)) && ((((%3)[(%2) + 1] == '\0') && (dcmd_%1(playerid, ""))) || (((%3)[(%2) + 1] == ' ') && (dcmd_%1(playerid, (%3)[(%2) + 2]))))) return 1
    #define WHITE 0xF6F6F6FF
    #define YELLOW 0xF6F600F6

    Spoiler anzeigen
    new Zwischensumme;
    new Text:TT_0[MAX_PLAYERS];
    #if defined TANK_SYS
    new Text:TT_1[MAX_PLAYERS];
    #endif
    new Text:TT_2;
    new Text:TT_3;
    new Text:TT_4;
    enum fahrzeug
    {
    tank,
    hat_tank,
    }
    new AUTOX[MAX_VEHICLES][fahrzeug];
    public OnFilterScriptInit()
    {
    print("\n--------------------------------------");
    print(" TankSystem von Lonsdale");
    print("--------------------------------------\n");
    // Lokale Textdraws
    TT_2 = TextDrawCreate(101.000000,344.000000," /");
    TT_3 = TextDrawCreate(125.000000,340.000000,"--------");
    TT_4 = TextDrawCreate(117.000000,410.000000," ");
    TextDrawAlignment(TT_2,0);
    TextDrawAlignment(TT_3,0);
    TextDrawAlignment(TT_4,0);
    TextDrawBackgroundColor(TT_2,0x000000ff);
    TextDrawBackgroundColor(TT_3,0x000000ff);
    TextDrawBackgroundColor(TT_4,0x000000ff);
    TextDrawFont(TT_2,3);
    TextDrawLetterSize(TT_2,1.000000,1.000000);
    TextDrawFont(TT_3,3);
    TextDrawLetterSize(TT_3,1.000000,1.000000);
    TextDrawFont(TT_4,3);
    TextDrawLetterSize(TT_4,1.000000,1.000000);
    TextDrawColor(TT_2,0x000000ff);
    TextDrawColor(TT_3,0x000000ff);
    TextDrawColor(TT_4,0x000000ff);
    TextDrawSetOutline(TT_2,1);
    TextDrawSetOutline(TT_3,1);
    TextDrawSetOutline(TT_4,1);
    TextDrawSetProportional(TT_2,1);
    TextDrawSetProportional(TT_3,1);
    TextDrawSetProportional(TT_4,1);
    TextDrawSetShadow(TT_2,1);
    TextDrawSetShadow(TT_3,1);
    TextDrawSetShadow(TT_4,1);
    SetTimer("UpdateSpeed",1000,1);
    #if defined TANK_SYS
    SetTimer("Update_Tank",18000,1);
    for(new i = 0;i<MAX_VEHICLES;i++)
    {
    AUTOX[i][tank] = (100);
    AUTOX[i][hat_tank] = (1);
    }
    #endif
    return 1;
    }
    public OnPlayerConnect(playerid)
    {

    Spoiler anzeigen
    #if defined TANK_SYS
    TT_1[playerid] = TextDrawCreate(141.000000,382.000000,"Tank : 100/100");
    TextDrawUseBox(TT_1[playerid],1);
    TextDrawBoxColor(TT_1[playerid],0x00000099);
    TextDrawTextSize(TT_1[playerid],250.000000,0.000000);
    TextDrawAlignment(TT_1[playerid],0);
    TextDrawBackgroundColor(TT_1[playerid],0x000000ff);
    TextDrawFont(TT_1[playerid],3);
    TextDrawLetterSize(TT_1[playerid],0.399999,1.000000);
    TextDrawColor(TT_1[playerid],0xffffffff);
    TextDrawSetOutline(TT_1[playerid],1);
    TextDrawSetProportional(TT_1[playerid],1);
    TextDrawSetShadow(TT_1[playerid],1);
    #endif

    Spoiler anzeigen
    return 1;
    }

    Spoiler anzeigen
    public OnPlayerDisconnect(playerid, reason)
    {
    TextDrawDestroy(TT_0[playerid]);
    #if defined TANK_SYS
    TextDrawDestroy(TT_1[playerid]);
    #endif
    TextDrawHideForPlayer(playerid,TT_2);
    TextDrawHideForPlayer(playerid,TT_3);
    TextDrawHideForPlayer(playerid,TT_4);
    return 1;
    }

    Spoiler anzeigen
    public OnPlayerCommandText(playerid, cmdtext[])
    {
    #if defined TANK_SYS
    if (strcmp("/tanken", cmdtext, true) == 0)
    {
    if(IsPlayerConnected(playerid))
    {
    if(GetPlayerState(playerid) == 2)
    {
    new vehicleids = GetPlayerVehicleID(playerid);
    if(IstAnDerTanke(playerid) && !NoCar(vehicleids))
    {
    new ZwischenSumme;
    ZwischenSumme = 100 - AUTOX[vehicleids][tank];
    AUTOX[vehicleids][tank] += ZwischenSumme;
    GivePlayerMoney(playerid,-ZwischenSumme * 3);
    GameTextForPlayer(playerid,"~b~Auto ~r~wurde getankt",2000,0);
    new forS[128];
    format(forS,sizeof(forS),"* Du hast dein Auto fuer %d $ Getankt *",ZwischenSumme);
    SendClientMessage(playerid,YELLOW,forS);
    }
    else
    {
    SendClientMessage(playerid,WHITE,"* Du musst an einer Tankstelle sein! *");
    }
    }
    }
    return 1;
    }
    if (strcmp("/raus", cmdtext, true) == 0)
    {
    RemovePlayerFromVehicle(playerid);
    TogglePlayerControllable(playerid,1);
    return 1;
    }
    dcmd(raus,4,cmdtext);
    dcmd(tanken,6,cmdtext);
    #endif
    return 0;
    }

    Spoiler anzeigen
    dcmd_raus(playerid, params[]) {
    #pragma unused params
    RemovePlayerFromVehicle(playerid);
    TogglePlayerControllable(playerid,true);
    return 1;
    }

    Spoiler anzeigen
    dcmd_tanken(playerid, params[]) {
    #pragma unused params
    if(GetPlayerState(playerid) != 2) return 1;
    new
    vehid = GetPlayerVehicleID(playerid);
    if(IstAnDerTanke(playerid) && !NoCar(vehid)) {
    new ZwischenSumme = 100 - AUTOX[vehid][tank];
    AUTOX[vehid][tank] += ZwischenSumme;
    GivePlayerMoney(playerid,-Zwischensumme*3);
    GameTextForPlayer(playerid,"~b~Auto~r~ wurde getankt",2000,0);
    new forstr[64];
    format(forstr, sizeof(forstr),"* Du hast dein Auto fuer %d $ aufgetankt *", ZwischenSumme);
    SendClientMessage(playerid, YELLOW, forstr);
    }
    else return SendClientMessage(playerid,WHITE,"* Du musst an einer Tankstelle sein! *");
    return 1;
    }
    public OnPlayerStateChange(playerid, newstate, oldstate)
    {
    new vehicleid = GetPlayerVehicleID(playerid);
    if(newstate == 2)
    {
    new tankx[128];
    TextDrawShowForPlayer(playerid,TT_0[playerid]);
    TextDrawShowForPlayer(playerid,TT_1[playerid]);
    TextDrawShowForPlayer(playerid,TT_2);
    TextDrawShowForPlayer(playerid,TT_3);
    TextDrawShowForPlayer(playerid,TT_4);
    format(tankx,sizeof tankx,"Tank : %d/100",AUTOX[vehicleid][tank]);
    TextDrawSetString(TT_1[playerid],tankx);
    }
    else if(newstate == 1)
    {

    Spoiler anzeigen
    TextDrawHideForPlayer(playerid,TT_0[playerid]);
    #if defined TANK_SYS
    TextDrawHideForPlayer(playerid,TT_1[playerid]);
    #endif
    TextDrawHideForPlayer(playerid,TT_2);
    TextDrawHideForPlayer(playerid,TT_3);
    TextDrawHideForPlayer(playerid,TT_4);
    }
    return 1;
    }

    Spoiler anzeigen
    forward PlayerToPoint(Float:radi, playerid, Float:xs, Float:ys, Float:zs);

    Spoiler anzeigen
    forward IstAnDerTanke(playerid);
    public IstAnDerTanke(playerid)
    {
    if(IsPlayerConnected(playerid))
    {
    if(PlayerToPoint(6.0,playerid,1004.0070,-939.3102,42.1797) || PlayerToPoint(6.0,playerid,1944.3260,-1772.9254,13.3906))
    {
    return 1;
    }
    else if(PlayerToPoint(6.0,playerid,-90.5515,-1169.4578,2.4079) || PlayerToPoint(6.0,playerid,-1609.7958,-2718.2048,48.5391))
    {
    return 1;
    }
    else if(PlayerToPoint(6.0,playerid,-2029.4968,156.4366,28.9498) || PlayerToPoint(8.0,playerid,-2408.7590,976.0934,45.4175))
    {
    return 1;
    }
    else if(PlayerToPoint(5.0,playerid,-2243.9629,-2560.6477,31.8841) || PlayerToPoint(8.0,playerid,-1676.6323,414.0262,6.9484))
    {
    return 1;
    }
    else if(PlayerToPoint(6.0,playerid,2202.2349,2474.3494,10.5258) || PlayerToPoint(10.0,playerid,614.9333,1689.7418,6.6968))
    {
    return 1;
    }
    else if(PlayerToPoint(8.0,playerid,-1328.8250,2677.2173,49.7665) || PlayerToPoint(6.0,playerid,70.3882,1218.6783,18.5165))
    {
    return 1;
    }
    else if(PlayerToPoint(8.0,playerid,2113.7390,920.1079,10.5255) || PlayerToPoint(6.0,playerid,-1327.7218,2678.8723,50.0625))
    {
    return 1;
    }
    }
    return 0;
    }
    public PlayerToPoint(Float:radi, playerid, Float:xs, Float:ys, Float:zs)
    {
    if(IsPlayerConnected(playerid))
    {
    new Float:oldposx, Float:oldposy, Float:oldposz;
    new Float:tempposx, Float:tempposy, Float:tempposz;
    GetPlayerPos(playerid, oldposx, oldposy, oldposz);
    tempposx = (oldposx -xs);
    tempposy = (oldposy -ys);
    tempposz = (oldposz -zs);
    if (((tempposx < radi) && (tempposx > -radi)) && ((tempposy < radi) && (tempposy > -radi)) && ((tempposz < radi) && (tempposz > -radi)))
    {
    return 1;
    }
    }
    return 0;
    }
    forward Update_Tank();
    public Update_Tank()
    {
    for(new i = 0;i<MAX_PLAYERS;i++)
    {
    if(GetPlayerState(i) == 2)
    {
    if(IsPlayerConnected(i))
    {
    new vehicleid = GetPlayerVehicleID(i);
    new tank_format[128];
    if(AUTOX[vehicleid][tank] > 1)
    {
    if(!NoCar(vehicleid))
    {
    AUTOX[vehicleid][tank]--;
    format(tank_format,sizeof tank_format,"Tank : %d/100",AUTOX[vehicleid][tank]);
    TextDrawSetString(TT_1[i],tank_format);
    AUTOX[vehicleid][hat_tank] = 1;
    }
    else
    {
    TextDrawSetString(TT_1[i],"Tank : N/A");
    AUTOX[vehicleid][hat_tank] = 1;
    }
    }
    else
    {
    if(!NoCar(vehicleid))
    {
    TextDrawSetString(TT_1[i],"Tank Leer");
    AUTOX[vehicleid][hat_tank] = 0;
    TogglePlayerControllable(i,0);
    }
    }
    }
    }
    }
    return 1;
    }
    stock NoCar(vehicleid)
    {
    new modell = GetVehicleModel(vehicleid);
    switch(modell)
    {
    // Helis ( waere auch zu unrealistisch wenn die Dinger Freezed wären :/ )
    case 548:return 1;
    case 425:return 1;
    case 417:return 1;
    case 487:return 1;
    case 488:return 1;
    case 497:return 1;
    case 563:return 1;
    case 447:return 1;
    case 469:return 1;
    // RC
    case 464:return 1;
    case 465:return 1;
    case 501:return 1;
    case 564:return 1;
    case 594:return 1;
    // Trailer / Angeanger
    case 435:return 1;
    case 450:return 1;
    case 591:return 1;
    case 606:return 1;
    case 607:return 1;
    case 610:return 1;
    case 569:return 1;
    case 590:return 1;
    case 584:return 1;
    case 570:return 1;
    case 608:return 1;
    case 611:return 1;
    // Flugzeuge ( waere auch zu unrealistisch wenn die Dinger Freezed wären :/ ) ²
    case 592:return 1;
    case 577:return 1;
    case 511:return 1;
    case 512:return 1;
    case 593:return 1;
    case 520:return 1;
    case 553:return 1;
    case 476:return 1;
    case 519:return 1;
    case 460:return 1;
    case 513:return 1;
    // Zuege & andere non Cars
    case 485:return 1;
    case 538:return 1;
    case 457:return 1;
    case 530:return 1;
    case 537:return 1;
    case 571:return 1;
    case 572:return 1;
    case 574:return 1;
    case 449:return 1;
    }
    return 0;
    }