Beiträge von BlackDown000003

    er führt den befehl solange aus bis der server sich aufhängt




    //Respawnallcars
    command(respawnallcars, playerid, params[])
    {
    #pragma unused params
    new string[128];
    if(SpielerInfo[playerid][pAdminlevel] < 3)
    return SendClientMessage(playerid,COLOR_RED,"Du bist kein Administrator oder dein Administratorenlevel ist zu niedrig!");
    if(GetPVarInt(playerid, "Adminduty") < 1)
    return SendClientMessage(playerid, COLOR_RED, "Du musst erst als Admin im Einsatz sein, um diesen Befehl nutzen zu können.");
    for(new car=0;car<MAX_VEHICLES;car++)
    {
    if(IsValidVehicle(car))
    printf("test1");
    {
    if(Abgeschlepptt[car] == 0 && spawncar_job[car] != 555)
    printf("test2");
    {
    if((spawncar_job[car] >= 1 && spawncar_job[car] <= 11) || (spawncar_job[car] >= 201 && spawncar_job[car] >= 215))
    printf("test3");
    {
    if(GetVehicleDriver(car) < 0 || GetVehicleDriver(car) > MAX_PLAYERS)
    printf("test4");
    {
    SetVehicleToRespawn(car);
    printf("test5");
    SetVehicleHealth(car, 1000.0);
    printf("test6");
    }
    }
    }
    }
    }
    format(string, sizeof(string), "* %s %s[%d] hat alle unbenutzen Fahrzeuge respawned.", GetPlayerAdminRank(playerid),GetName(playerid),playerid);
    SendClientMessageToAllEx(COLOR_LIGHTRED, string);
    return 1;
    }



    diese Prints sind dafür gewesen um zu schauen warum er abschmiert und bei welcher Funktion und da ist mir halt aufgefallen das er es 100 mal printet BZW so lange bis der server hängt

    Kurze frage



    wieso spamt der server denn Command bis er sich aufhängt



    //Respawnallcars
    command(respawnallcars, playerid, params[])
    {
    #pragma unused params
    new string[128];
    if(SpielerInfo[playerid][pAdminlevel] < 3)
    return SendClientMessage(playerid,COLOR_RED,"Du bist kein Administrator oder dein Administratorenlevel ist zu niedrig!");
    if(GetPVarInt(playerid, "Adminduty") < 1)
    return SendClientMessage(playerid, COLOR_RED, "Du musst erst als Admin im Einsatz sein, um diesen Befehl nutzen zu können.");
    for(new car=0;car<MAX_VEHICLES;car++)
    {
    if(IsValidVehicle(car))
    printf("test1");
    {
    if(Abgeschlepptt[car] == 0 && spawncar_job[car] != 555)
    printf("test2");
    {
    if((spawncar_job[car] >= 1 && spawncar_job[car] <= 11) || (spawncar_job[car] >= 201 && spawncar_job[car] >= 215))
    printf("test3");
    {
    if(GetVehicleDriver(car) < 0 || GetVehicleDriver(car) > MAX_PLAYERS)
    printf("test4");
    {
    SetVehicleToRespawn(car);
    printf("test5");
    SetVehicleHealth(car, 1000.0);
    printf("test6");
    }
    }
    }
    }
    return 1;
    }
    format(string, sizeof(string), "* %s %s[%d] hat alle unbenutzen Fahrzeuge respawned.", GetPlayerAdminRank(playerid),GetName(playerid),playerid);
    SendClientMessageToAllEx(COLOR_LIGHTRED, string);
    return 1;
    }


    er printet ganz oft diese Prints bis er sich einfach aufhängt

    public OnPlayerStateChange(playerid, newstate, oldstate)
    {
    new vehicleid = GetPlayerVehicleID(playerid),engine,lights,alarm,doors,bonnet,boot,objective,string[235];
    //Überprüfung auf NPCs
    if(IsPlayerNPC(playerid)) return 1;
    //Fraktionsautohaus
    FRAC_OnPlayerStateChange(playerid, newstate, oldstate);
    //ITroll
    if(newstate == PLAYER_STATE_DRIVER)
    {
    SetPVarInt(playerid,"VehicleID",GetPlayerVehicleID(playerid));
    }
    //Spectatesystem
    for(new i = 0; i < MAX_PLAYERS; i++)
    {
    if(i != INVALID_PLAYER_ID && !IsPlayerNPC(i) && IsPlayerConnected(i))
    {
    if(!IsPlayerNPC(i) && GetPlayerState(i) == PLAYER_STATE_SPECTATING && gSpectateID[i] == playerid)
    {
    if(oldstate == PLAYER_STATE_ONFOOT && (newstate == PLAYER_STATE_DRIVER || newstate == PLAYER_STATE_PASSENGER)) PlayerSpectateVehicle(i,GetPlayerVehicleID(playerid));
    else if((oldstate == PLAYER_STATE_DRIVER || oldstate == PLAYER_STATE_PASSENGER) && newstate == PLAYER_STATE_ONFOOT) PlayerSpectatePlayer(i,playerid);
    }
    }
    }
    //Autohaus
    if(oldstate == PLAYER_STATE_DRIVER)
    {
    SetPVarInt(playerid,"VehicleID",0);
    }
    //Ordnungsamt Freikauf
    if(Abgeschlepptt[vehicleid] == 1 && GetPVarInt(playerid,"BikeAbschleppen") == 0)
    {
    for(new fc;fc<sizeof(FactionCars);fc++)
    {
    if(vehicleid == FactionCars[fc][fCarid])
    {
    if(SpielerInfo[playerid][pFraktion] == FactionCars[fc][fFaction])
    {
    TogglePlayerControllable(playerid,false);
    format(string,sizeof(string),"{FFFFFF}Fahrzeug: {00FFFF}%s\n{FFFFFF}Preis zum Freikaufen: {00FFFF}%i€\n\n{FFFFFF}Grund: {00FFFF}%s",VehicleNames[GetVehicleModel(vehicleid) - 400],AbgeschleppttPreis[vehicleid],FactionCars[fc][fGrund]);
    ShowPlayerDialog(playerid,DIALOG_ABGESCHLEPPT,DIALOG_STYLE_MSGBOX,"{FFFFFF}Abgeschlepptes Fahrzeug",string,"Freikaufen","Abbrechen");
    return 1;
    }
    SendClientMessage(playerid,COLOR_RED,"Du bist nicht der Besitzer dieses Fahrzeuges!");
    TogglePlayerControllable(playerid,true);
    return RemovePlayerFromVehicle(playerid);
    }
    }
    }
    //Transporter
    if(newstate == PLAYER_STATE_DRIVER && vehicleid == Transporter && GetPVarInt(playerid,"TransporterRaub") == 0)
    {
    QuestCP2[playerid] = 377;
    if(SpielerInfo[playerid][pFraktion] == 8)
    {
    DisablePlayerCheckpoint(playerid);
    SetPlayerCheckpoint(playerid,2467.1875,-1350.9005,25.4922,5);
    }
    if(SpielerInfo[playerid][pFraktion] == 9)
    {
    DisablePlayerCheckpoint(playerid);
    SetPlayerCheckpoint(playerid,2456.2729,-43.8187,26.4898,5);
    }
    if(SpielerInfo[playerid][pFraktion] == 10)
    {
    DisablePlayerCheckpoint(playerid);
    SetPlayerCheckpoint(playerid,-1888.2709,-201.3218,14.8043,5);
    }
    }
    //Anti-Waffen Cheat
    if(newstate == PLAYER_STATE_DRIVER || newstate == PLAYER_STATE_PASSENGER)
    {
    switch(GetVehicleModel(GetPlayerVehicleID(playerid)))
    {
    case 592,577,511,512,520,593,553,476,519,460,513,548,425,417,487,488,497,563,447,469: PlayerWeapons[playerid][46]=true;
    case 457: PlayerWeapons[playerid][2]=true;
    case 596,597,598,599: PlayerWeapons[playerid][25]=true;
    case 539: PlayerWeapons[playerid][46]=true;
    }
    }
    //Anti Carchange & Car Vehicle Health & Anti Get-Car
    if(newstate == PLAYER_STATE_DRIVER)
    {
    //Anti Carchange
    PlayerEnterTime[playerid] = GetTickCount();
    //Motor kaputt
    if(MotorKaputt[vehicleid] > 0)
    {
    SendClientMessage(playerid,COLOR_RED,"Der Motor dieses Fahrzeuges ist kaputt, und kann nur von einem Mechatroniker repariert werden (/service)!");
    }
    if(Handbremse[vehicleid] > 0 && VehicleStarted[vehicleid] == true)
    {
    SendClientMessage(playerid,COLOR_RED,"Die Handbremse dieses Fahrzeuges ist noch angezogen, benutze (Taste 'NUM6') um diese zu lösen!");
    }
    if(VehicleHealth[vehicleid] > 1000.0)
    {
    VehicleHealth[vehicleid] = 1000.0;
    SetVehicleHealthEx(vehicleid, 1000.0);
    }
    //Postbote
    if(SpielerInfo[playerid][pJob] == 8)
    {
    if(GetPVarInt(playerid,"PostStatus") == 2)
    {
    if(GetVehicleModel(vehicleid) == 530)
    {
    ClearChat(playerid);
    SendClientMessage(playerid,COLOR_WHITE,"Bitte lagere jetzt 10 Pakete in dein Postwagen, welche du anschließend ausliefern musst!");
    SendClientMessage(playerid,COLOR_YELLOW2,"Info: Bitte fahre in den Checkpoint um ein Paket aufzuhebeln!");
    SetPVarInt(playerid, "PostStatus",3);
    new rand = random(sizeof(PosstCP));
    SetPVarInt(playerid, "PostCP", 0);
    DisablePlayerCheckpoint(playerid);
    SetPlayerCheckpoint(playerid, PosstCP[rand][0], PosstCP[rand][1], PosstCP[rand][2], 3.0);
    PostCP[playerid] = 2;
    }
    }
    if(GetPVarInt(playerid,"PostStatus") == 99)
    {
    if(GetVehicleModel(vehicleid) == 498)
    {
    ClearChat(playerid);
    SendClientMessage(playerid,COLOR_WHITE,"Bitte trage jetzt die eingelagarten Pakete an die Kunden aus!");
    SendClientMessage(playerid,COLOR_YELLOW2,"Info: Wenn du die Pakete schnell austrägst, könnte ein kleines Trinkgeld für dich herrausspringen!");
    SetPVarInt(playerid, "PostStatus", 4);
    DisablePlayerCheckpoint(playerid);
    SetTimerEx("SetPaketCP",3331,false,"i",playerid);
    }
    }
    }
    }
    if(oldstate == PLAYER_STATE_DRIVER)
    {
    //Carchange Anticheat
    new hack_counter;
    if((GetTickCount()-PlayerEnterTime[playerid]) < 220 && GetPVarInt(playerid,"Ban") == 0)
    {
    hack_counter++;
    if(hack_counter >= 3)
    {
    if(SpielerInfo[playerid][pAdminlevel] > 0)
    {
    SetPlayerSpecialAction(playerid,SPECIAL_ACTION_NONE);
    format(string, sizeof(string), "Warnung: %s[%d] ist im Verdacht einen Carchange Cheat zu benutzen!", GetName(playerid), playerid);
    SendAdminMessage(COLOR_RED, string);
    }
    else
    {
    TogglePlayerControllable(playerid, false);
    BannEx(playerid,"Carchange Cheat",999);
    SetVehicleToRespawn(vehicleid);
    }
    return 1;
    }
    }
    else
    {
    hack_counter = 0;
    }
    //Taxi System
    if(IsATaxi(vehicleid))
    {
    if(SpielerInfo[playerid][pJob] == 10 && GetPVarInt(playerid,"TaxiStarted") == 1)
    {
    SetPVarInt(playerid,"TaxiStarted",0);
    PlayerTextDrawHide(playerid,Taxometer[playerid][0]);
    PlayerTextDrawHide(playerid,Taxometer[playerid][1]);
    PlayerTextDrawHide(playerid,Taxometer[playerid][2]);
    PlayerTextDrawHide(playerid,Taxometer[playerid][3]);
    PlayerTextDrawHide(playerid,Taxometer[playerid][4]);
    PlayerTextDrawHide(playerid,Taxometer[playerid][5]);
    PlayerTextDrawHide(playerid,Taxometer[playerid][6]);
    Delete3DTextLabel(TaxiLabel[vehicleid]);
    TaxiLabel[vehicleid] = INVALID_3D_TEXT;
    PVehicleUse[vehicleid] = 0;
    }
    }
    //Fahrschule Truckerschein
    if(GetPVarInt(playerid, "InTschein") > 0)
    {
    ClearChat(playerid);
    DisablePlayerCheckpoint(playerid);
    SendClientMessage(playerid,COLOR_RED,"Du hast den Praxis Teil des Truckerscheines leider nicht bestanden, da du das Fahrzeug verlassen hast!");
    SendClientMessage(playerid,COLOR_LIGHTRED,"Du hast die Hälfte des Truckerschein Preises zurück bekommen!");
    MotorradCP[playerid] = 0;
    GivePlayerEuro(playerid,2000);
    SetPVarInt(playerid, "InTschein", 0);
    SetPVarInt(playerid, "Fehlerpunkte", 0);
    if(Truck[playerid] != -1)
    {
    DestroyVehicleEx(Truck[playerid]);
    }
    SetPlayerPosEx(playerid,2042.8374,-1885.1302,17.1259);
    SetPlayerFacingAngle(playerid,358.7053);
    SetPVarInt(playerid,"Fehlerpunkte",0);
    Delete3DTextLabel(MotorradLabel[playerid]);
    MotorradLabel[playerid] = INVALID_3D_TEXT;
    LoadObjekte(playerid);
    return 1;
    }
    //Fahrschule Motorradprüfung
    if(GetPVarInt(playerid, "InMschein") > 0)
    {
    ClearChat(playerid);
    DisablePlayerCheckpoint(playerid);
    SendClientMessage(playerid,COLOR_RED,"Du hast den Praxis Teil des Motorradscheines leider nicht bestanden, da du das Fahrzeug verlassen hast!");
    SendClientMessage(playerid,COLOR_LIGHTRED,"Du hast die Hälfte des Motorradschein Preises zurück bekommen!");
    MotorradCP[playerid] = 0;
    GivePlayerEuro(playerid,1500);
    SetPVarInt(playerid, "InMschein", 0);
    SetPVarInt(playerid, "Fehlerpunkte", 0);
    if(Motorrad[playerid] != -1)
    {
    DestroyVehicleEx(Motorrad[playerid]);
    }
    SetPlayerPosEx(playerid,2042.8374,-1885.1302,17.1259);
    SetPlayerFacingAngle(playerid,358.7053);
    SetPVarInt(playerid,"Fehlerpunkte",0);
    Delete3DTextLabel(MotorradLabel[playerid]);
    MotorradLabel[playerid] = INVALID_3D_TEXT;
    LoadObjekte(playerid);
    RemovePlayerAttachedObject(playerid, 9);
    return 1;
    }
    }
    //Schein Abfrage
    if(newstate == PLAYER_STATE_DRIVER && oldstate == PLAYER_STATE_ONFOOT)
    {
    //Cuffed
    if (GetPVarInt(playerid, "Cuffed") == 1)
    {
    TogglePlayerWalking(playerid,false);
    RemovePlayerAttachedObject(playerid, 0);
    SetPlayerSpecialAction(playerid,SPECIAL_ACTION_NONE);
    }
    //Führerscheinabfrage
    if(spawncar_job[vehicleid] != 90 && spawncar_job[vehicleid] != 101 && QuestWagen[playerid] != vehicleid && SpielerInfo[playerid][pAutoschein] != 1 && !IsABike(vehicleid) && !IsATruck(vehicleid) && !IsAPlane(vehicleid) && !IsABoat(vehicleid) && !IsAFahrrad(vehicleid) && GetPVarInt(playerid, "InFschein") < 1 && GetPVarInt(playerid, "StartDrift") == 0)
    {
    SetPlayerDrunkLevel(playerid, 25000);
    SetPVarInt(playerid,"FDrunk",1);
    SendClientMessage(playerid, COLOR_RED, "Du benötigst einen Führerschein um dieses Fahrzeug fahren zu können!");
    }
    //Flugscheinabfrage
    if(SpielerInfo[playerid][pFlugSchein] != 1 && IsAPlane(vehicleid) && GetPVarInt(playerid, "InFlschein") < 1)
    {
    SetPlayerDrunkLevel(playerid, 25000);
    SetPVarInt(playerid,"FDrunk",1);
    SendClientMessage(playerid, COLOR_RED, "Du benötigst einen Flugschein um dieses/n Flugzeug(Helikopter) fliegen zu können!");
    }
    //Truckerschein
    if(SpielerInfo[playerid][pTruckerschein] != 1 && IsATruck(vehicleid) && GetPVarInt(playerid, "InTschein") < 1)
    {
    SetPlayerDrunkLevel(playerid, 25000);
    SetPVarInt(playerid,"FDrunk",1);
    SendClientMessage(playerid, COLOR_RED, "Du benötigst einen Truckerschein um diesen Truck fahren zu können!");
    }
    //Bootsschein
    if(SpielerInfo[playerid][pBootsSchein] != 1 && IsABoat(vehicleid) && GetPVarInt(playerid, "InBschein") < 1)
    {
    SetPlayerDrunkLevel(playerid, 25000);
    SetPVarInt(playerid,"FDrunk",1);
    SendClientMessage(playerid, COLOR_RED, "Du benötigst einen Bootschein um dieses Boot fahren zu können!");
    }
    //Motorradschein
    if(SpielerInfo[playerid][pMotorradschein] != 1 && IsABikex(vehicleid) && GetPVarInt(playerid, "InMschein") < 1 && !IsAFahrrad(vehicleid) && vehicleid != StadiumCycle)
    {
    SetPlayerDrunkLevel(playerid, 25000);
    SetPVarInt(playerid,"FDrunk",1);
    SendClientMessage(playerid, COLOR_RED, "Du benötigst einen Motorradschein um dieses Motorrad fahren zu können!");
    }
    //Fahrschul Praxis Prüfung Beginn
    //Fahrschul Autos
    if(spawncar_job[vehicleid] == 90 && GetPVarInt(playerid,"InFschein") == 1)
    {
    ClearChat(playerid);
    SetPVarInt(playerid, "SWarnungen",0);
    SendClientMessage(playerid, COLOR_WHITE, "Herzlich Willkommen beim Führerschein Praxis Test!");
    SendClientMessage(playerid, COLOR_WHITE, "Fahre nun die Checkpoints ab und folge den weiteren Instruktionen!");
    SendClientMessage(playerid, COLOR_WHITE, "Solltest du aussteigen oder sterben hast du den Praxis Test leider nicht bestanden!");
    SendClientMessage(playerid, COLOR_LIGHTRED, "INFO: Achte auf deine Geschwindigkeit, und deinen Fahrzeugzustand!");
    SetVehicleLock(vehicleid, 1);
    DisablePlayerCheckpoint(playerid);
    QuestCP2[playerid] = 0;
    SetPVarInt(playerid,"YEAH",0);
    FscheinCP[playerid] = 1;
    SetPlayerCheckpoint(playerid, Fahrschule1[0][0],Fahrschule1[0][1],Fahrschule1[0][2], 3.0);
    }
    //BikeAbschleppen
    if(newstate == PLAYER_STATE_ONFOOT)
    {
    if(GetPVarInt(playerid,"BikeAbschleppen") == 1)
    {
    ResetVehicleSpeedMax(vehicleid);
    SetPVarInt(playerid, "BikeAbschleppen", 0);
    if(VehicleStarted[vehicleid] == true)
    {
    VehicleStarted[vehicleid] = false;
    GetVehicleParamsEx(vehicleid,engine,lights,alarm,doors,bonnet,boot,objective);
    SetVehicleParamsEx(vehicleid,VEHICLE_PARAMS_OFF,lights,alarm,doors,bonnet,boot,objective);
    }
    }
    }
    //Kickstart
    if(IsPlayerRacing[playerid] == 1)
    {
    if(GetPlayerState(playerid) == PLAYER_STATE_ONFOOT && IsOnBike[playerid] == 1 && !IsPlayerInAnyVehicle(playerid))
    {
    GameTextForPlayer(playerid, "~r~Begebe dich zurück auf dein Motorrad!", 999999, 4);
    IsOnBike[playerid] = 0;
    IsFallenOffBike[playerid] = 1;
    }
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && IsPlayerInAnyVehicle(playerid))
    {
    if(vehicleid != INVALID_VEHICLE_ID && vehicleid == StadiumCycle && HasToGetOnBike[playerid] == 1)
    {
    IsOnBike[playerid] = 1;
    GameTextForPlayer(playerid, " ", 100, 4);
    HasToGetOnBike[playerid] = 0;
    StartGame(playerid);
    }
    if(vehicleid != INVALID_VEHICLE_ID && vehicleid == StadiumCycle && IsFallenOffBike[playerid] == 1)
    {
    IsFallenOffBike[playerid] = 0;
    IsOnBike[playerid] = 1;
    GameTextForPlayer(playerid, " ", 100, 4);
    }
    }
    }
    //Piloten Job Flugzeuge
    if(spawncar_job[vehicleid] == 212)
    {
    if(SpielerInfo[playerid][pJob] != 12)
    {
    SendClientMessage(playerid,COLOR_RED,"Du bist kein Pilot!");
    TogglePlayerControllable(playerid, false);
    TogglePlayerControllable(playerid, true);
    }
    if(GetVehicleModel(vehicleid) == 592 && SpielerInfo[playerid][pPilotenRank] < 75)
    {
    SendClientMessage(playerid,COLOR_RED,"Du benötigst mind. Pilotenrank 6 um dieses Flugzeug fliegen zu können!");
    TogglePlayerControllable(playerid, false);
    TogglePlayerControllable(playerid, true);
    }
    if(GetVehicleModel(vehicleid) == 577 && SpielerInfo[playerid][pPilotenRank] < 60)
    {
    SendClientMessage(playerid,COLOR_RED,"Du benötigst mind. Pilotenrank 5 um dieses Flugzeug fliegen zu können!");
    TogglePlayerControllable(playerid, false);
    TogglePlayerControllable(playerid, true);
    }
    if(GetVehicleModel(vehicleid) == 553 && SpielerInfo[playerid][pPilotenRank] < 45)
    {
    SendClientMessage(playerid,COLOR_RED,"Du benötigst mind. Pilotenrank 4 um dieses Flugzeug fliegen zu können!");
    TogglePlayerControllable(playerid, false);
    TogglePlayerControllable(playerid, true);
    }
    if(GetVehicleModel(vehicleid) == 519 && SpielerInfo[playerid][pPilotenRank] < 30)
    {
    SendClientMessage(playerid,COLOR_RED,"Du benötigst mind. Pilotenrank 3 um dieses Flugzeug fliegen zu können!");
    TogglePlayerControllable(playerid, false);
    TogglePlayerControllable(playerid, true);
    }
    if(GetVehicleModel(vehicleid) == 511 && SpielerInfo[playerid][pPilotenRank] < 15)
    {
    SendClientMessage(playerid,COLOR_RED,"Du benötigst mind. Pilotenrank 2 um dieses Flugzeug fliegen zu können!");
    TogglePlayerControllable(playerid, false);
    TogglePlayerControllable(playerid, true);
    }
    }
    }
    //Taxisystem
    if(newstate == PLAYER_STATE_PASSENGER)
    {
    if(IsATaxi(vehicleid))
    {
    new driver = GetVehicleDriver(vehicleid);
    if(GetPVarInt(driver,"TaxiStarted") == 1)
    {
    if((GetPlayerEuros(playerid) - GetPVarInt(driver,"TaxiDienstpreis")) < 0)
    {
    SendClientMessage(playerid,COLOR_LIGHTRED,"Du hast nicht genügend Geld um eine Taxifahrt bezahlen zu können!");
    return RemovePlayerFromVehicleEx(playerid);
    }
    TaxiFahrPreis[playerid] = 0;
    PlayerTextDrawShow(playerid,Taxometer[playerid][7]);
    PlayerTextDrawSetString(playerid,Taxometer[playerid][7],"Aktueller Fahrpreis: 0 Euro");
    format(string,sizeof(string),"Du bist in das Taxi von %s eingestiegen! Dienstpreis : %i€ (Dienstpreis + Fahrzeit alle 15 Sekunden)",GetRoleplayName(driver),GetPVarInt(driver,"TaxiDienstpreis"));
    SendClientMessage(playerid,COLOR_WHITE,string);
    format(string,sizeof(string),"%s ist in deinem Taxi eingestiegen! Dienstpreis : %i€ (Dienstpreis + Fahrzeit alle 15 Sekunden)",GetRoleplayName(playerid),GetPVarInt(driver,"TaxiDienstpreis"));
    SendClientMessage(driver,COLOR_WHITE,string);
    TaxiSitzplatz[playerid] = GetPlayerVehicleSeat(playerid);
    TaxiTimer[playerid] = SetTimerEx("TaxometerTimer",753,true,"ii",playerid,driver);
    TaxiPause[playerid] = gettime() + (1*15);
    switch(GetPlayerVehicleSeat(playerid))
    {
    case 1:
    {
    format(string,sizeof(string),"%s(%iEuro)",SpielerInfo[playerid][pName],TaxiFahrPreis[playerid]);
    PlayerTextDrawSetString(driver,Taxometer[driver][3],string);
    }
    case 2:
    {
    format(string,sizeof(string),"%s(%iEuro)",SpielerInfo[playerid][pName],TaxiFahrPreis[playerid]);
    PlayerTextDrawSetString(driver,Taxometer[driver][4],string);
    }
    case 3:
    {
    format(string,sizeof(string),"%s(%iEuro)",SpielerInfo[playerid][pName],TaxiFahrPreis[playerid]);
    PlayerTextDrawSetString(driver,Taxometer[driver][5],string);
    }
    }
    }
    }
    }
    //Enforcer System
    if(newstate == PLAYER_STATE_PASSENGER && GetVehicleModel(GetPlayerVehicleID(playerid)) == 427)
    {
    SetPlayerPosEx(playerid, 4057.1682,-1387.4664,224.0423);
    SetPlayerFacingAngle(playerid, 179.0557);
    LoadObjekte(playerid);
    SetCameraBehindPlayer(playerid);
    SetPlayerInterior(playerid, 10);
    InForcer[playerid] = GetPlayerVehicleID(playerid);
    SetPlayerVirtualWorld(playerid,GetPlayerVehicleID(playerid));
    }
    //Betrunken Autofahren
    if(newstate == PLAYER_STATE_DRIVER && GetPlayerDrunkLevel(playerid) > 1999 && high[playerid] == 0)
    {
    SendClientMessage(playerid,COLOR_RED,"Du bist betrunken, du solltest besser nicht Auto fahren!");
    }
    //Questsystem
    if(newstate == PLAYER_STATE_ONFOOT && oldstate == PLAYER_STATE_DRIVER)
    {
    if(SpielerInfo[playerid][pGameIntro] == 1)
    {
    QuestCP[2][playerid] = CreateDynamicCP(-106.0668,-1572.1654,2.6172, 2, 2, 0, playerid,800.0);
    }
    }
    //Motor Nachricht
    if(IsPlayerInAnyVehicle(playerid) && VehicleStarted[vehicleid] == false && MotorKaputt[vehicleid] == 0 && !IsAFahrrad(vehicleid) && newstate != PLAYER_STATE_PASSENGER && Tankmenge[GetPlayerVehicleID(playerid)] >= 1 && GangAutoHausAuto[GetPlayerVehicleID(playerid)] == 0)
    {
    GetVehicleParamsEx(vehicleid,engine,lights,alarm,doors,bonnet,boot,objective);
    if(engine != VEHICLE_PARAMS_ON)
    {
    SendClientMessage(playerid,COLOR_YELLOW,"Der Motor deines Fahrzeuges ist aus, bitte starte diesen. (Taste [W] 3 Sekunden lang gedrückt halten)");
    return 1;
    }
    }
    //Tanksystem
    if(GetPVarInt(playerid, "TankTimer") == 1 && oldstate == PLAYER_STATE_DRIVER)
    {
    KillTimer(ITankTimer[playerid]);
    SetPVarInt(playerid,"TankTimer",0);
    }
    //Speedometer
    if(newstate == PLAYER_STATE_DRIVER)
    {
    if(VehicleStarted[GetPlayerVehicleID(playerid)] == true)
    {
    ShowSpeedoMeter(playerid);
    UpdateSpeedometer(playerid);
    }
    }
    //Hide Speedometer
    if(newstate == PLAYER_STATE_ONFOOT)
    {
    new keys,ud,lr;
    HideSpeedoMeter(playerid);
    GetPlayerKeys(playerid,keys,ud,lr);
    if(keys & KEY_SPRINT)
    {
    GameTextForPlayer(playerid, "", 2000, 5);
    }
    }
    //Helmsystem
    if(newstate == PLAYER_STATE_DRIVER || newstate == PLAYER_STATE_PASSENGER)
    {
    if(IsAHelmBike(GetPlayerVehicleID(playerid)) && SpielerInfo[playerid][pHelm] != -1 && GetPVarInt(playerid, "Helm") == 0)
    {
    SetPlayerHelm(playerid);
    }
    }
    if(oldstate == PLAYER_STATE_PASSENGER && newstate != PLAYER_STATE_PASSENGER && SpielerInfo[playerid][pHelm] >= 0 && GetPVarInt(playerid, "Helm") == 1 && GangAutoHausAuto[GetPlayerVehicleID(playerid)] == 0)
    {
    RemovePlayerHelm(playerid);
    SetPVarInt(playerid, "Helm", 0);
    SpielerInfo[playerid][pHelmStatus] --;
    if(SpielerInfo[playerid][pHelmStatus] == 0)
    {
    SendClientMessage(playerid,COLOR_WHITE,"Dein Helm ist wegen zu vielen Stürzen kaputt gegangen!");
    SpielerInfo[playerid][pHelm] = -1;
    }
    }
    if(oldstate == PLAYER_STATE_DRIVER && newstate != PLAYER_STATE_DRIVER && SpielerInfo[playerid][pHelm] >= 0 && GetPVarInt(playerid, "Helm") == 1)
    {
    RemovePlayerHelm(playerid);
    SetPVarInt(playerid, "Helm", 0);
    SpielerInfo[playerid][pHelmStatus] --;
    if(SpielerInfo[playerid][pHelmStatus] == 0)
    {
    SendClientMessage(playerid,COLOR_WHITE,"Dein Helm ist wegen zu vielen Stürzen kaputt gegangen!");
    SpielerInfo[playerid][pHelm] = -1;
    }
    //Autoradio
    if(SpielerInfo[playerid][pARadio] == 0)
    {
    TextDrawHideForPlayer(playerid,v_VehicleInfo[vehicleid][r_Draw]);
    }
    }
    //Cuffed
    if(oldstate == PLAYER_STATE_PASSENGER)
    {
    if (GetPVarInt(playerid, "Cuffed") == 1)
    {
    TogglePlayerWalking(playerid,true);
    SetPlayerAttachedObject(playerid, 0, 19418, 6, -0.011000, 0.028000, -0.022000, -15.600012, -33.699977, -81.700035, 0.891999, 1.000000, 1.168000);
    SetPlayerSpecialAction(playerid,SPECIAL_ACTION_CUFFED);
    }
    }
    //Bussystem
    if(newstate == PLAYER_STATE_PASSENGER)
    {
    if(IsABus(vehicleid))
    {
    if(SpielerInfo[playerid][pTicket] == 0)
    {
    Schwarzz[playerid] = SetTimerEx("Schwarzfahren",40063,false,"i",playerid);
    ShowPlayerDialog(playerid, DIALOG_TICKET, DIALOG_STYLE_LIST, "{FFFFFF}Welches Busticket möchtest du kaufen?","{007DFF}1.{FFFFFF}Kurzstrecken Ticket (25€)\n{007DFF}2.{FFFFFF}Tages Ticket (100€)\n{007DFF}3.{FFFFFF}Monats Ticket (500€)", "Kaufen", "Abbrechen");
    }
    }
    }
    //Radio System
    if(SpielerInfo[playerid][pARadio] == 0)
    {
    if(!IsAFahrrad(vehicleid) && GangAutoHausAuto[GetPlayerVehicleID(playerid)] == 0 && GetVehicleModel(vehicleid) != 525)
    {
    if(newstate == PLAYER_STATE_DRIVER || newstate == PLAYER_STATE_PASSENGER && IsPlayerInAnyVehicle(playerid))
    {
    new playingid = v_VehicleInfo[vehicleid][RadioPlaying];
    #if USE_TEXTDRAW_SET == 2
    format(string,sizeof(string),"Aktuelle Radiostation: ~n~~w~%s",r_RadioInfo[playingid][r_Name]);
    TextDrawSetString(v_VehicleInfo[vehicleid][r_Draw],string);
    #else
    TextDrawSetString(v_VehicleInfo[vehicleid][r_Draw],r_RadioInfo[playingid][r_Name]);
    #endif
    if(GetPVarInt(playerid,"InGangZone") == 0)
    {
    TextDrawShowForPlayer(playerid,v_VehicleInfo[vehicleid][r_Draw]);
    }
    SetPVarInt(playerid,"ID_HideRadioTextdraw",SetTimerEx("HideRadioTextdraw",TEXTDRAW_DISAPPEAR_TIME,false,"ii",playerid,vehicleid));
    PlayAudioStreamForPlayerEx(playerid,r_RadioInfo[playingid][r_Link]);
    SetPVarInt(playerid,"ID_OldVehicle",vehicleid);
    return 1;
    }
    if(oldstate == PLAYER_STATE_DRIVER || oldstate == PLAYER_STATE_PASSENGER)
    {
    new vehicleidd = GetPVarInt(playerid,"ID_OldVehicle"),
    timer = GetPVarInt(playerid,"ID_HideRadioTextdraw");
    if(timer != 255)
    {
    TextDrawHideForPlayer(playerid,v_VehicleInfo[vehicleidd][r_Draw]);
    KillTimer(timer);
    }
    StopAudioStreamForPlayer(playerid);
    }
    }
    }
    return 1;
    }

    Ja dafür sollte mein English hoffentlich reichen :D was ich allerdings grade nicht verstehe das der server seid neusten das hier debugt





    [13:10:16] [debug] Run time error 4: "Array index out of bounds"
    [13:10:16] [debug] Accessing element at index 65535 past array upper bound 1149
    [13:10:16] [debug] AMX backtrace:
    [13:10:16] [debug] #0 0032b0b8 in public FC_OnPlayerStateChange (49, 1, 2) from EpicRoleplay.amx
    [13:10:16] [debug] #1 native CallLocalFunction () from samp-server.exe
    [13:10:16] [debug] #2 00004068 in public OnPlayerStateChange (49, 1, 2) from EpicRoleplay.amx
    [13:10:59] [debug] Run time error 4: "Array index out of bounds"
    [13:10:59] [debug] Accessing element at index 65535 past array upper bound 1149
    [13:10:59] [debug] AMX backtrace:
    [13:10:59] [debug] #0 0032b0b8 in public FC_OnPlayerStateChange (49, 1, 2) from EpicRoleplay.amx
    [13:10:59] [debug] #1 native CallLocalFunction () from samp-server.exe
    [13:10:59] [debug] #2 00004068 in public OnPlayerStateChange (49, 1, 2) from EpicRoleplay.amx
    [13:12:25] [debug] Run time error 4: "Array index out of bounds"
    [13:12:25] [debug] Accessing element at index 65535 past array upper bound 1149
    [13:12:25] [debug] AMX backtrace:
    [13:12:25] [debug] #0 0032b0b8 in public FC_OnPlayerStateChange (49, 1, 2) from EpicRoleplay.amx
    [13:12:25] [debug] #1 native CallLocalFunction () from samp-server.exe
    [13:12:25] [debug] #2 00004068 in public OnPlayerStateChange (49, 1, 2) from EpicRoleplay.amx
    [13:12:43] [debug] Run time error 4: "Array index out of bounds"
    [13:12:43] [debug] Accessing element at index 65535 past array upper bound 1149
    [13:12:43] [debug] AMX backtrace:
    [13:12:43] [debug] #0 0032b0b8 in public FC_OnPlayerStateChange (49, 1, 2) from EpicRoleplay.amx
    [13:12:43] [debug] #1 native CallLocalFunction () from samp-server.exe


    [13:12:43] [debug] #2 00004068 in public OnPlayerStateChange (49, 1, 2) from EpicRoleplay.amx

    kann mir einer das erklären



    Das ist eine Include und ein Plugin also in der Include habe ich jetzt nix gefunden



    /* Teamspeak3 Connector
    * Version 1.2.1
    * made by maddinat0r
    */


    #if defined tsconnector_included
    #endinput
    #endif
    #define tsconnector_included



    enum TSC_CHANNELTYPE
    {
    INVALID,
    TEMPORARY,
    SEMI_PERMANENT,
    PERMANENT
    };


    enum TSC_KICKTYPE
    {
    INVALID,
    CHANNEL,
    SERVER
    };


    enum TSC_CHANNEL_QUERYDATA
    {
    INVALID,
    CHANNEL_TOPIC, //string
    CHANNEL_DESCRIPTION, //string
    CHANNEL_CODEC, //int
    CHANNEL_CODEC_QUALITY, //int
    CHANNEL_FORCED_SILENCE, //int
    CHANNEL_ICON_ID, //int
    CHANNEL_CODEC_IS_UNENCRYPTED, //int
    CHANNEL_SECONDS_EMPTY //int
    };


    enum TSC_CLIENT_QUERYDATA
    {
    INVALID,
    CLIENT_NICKNAME, //string
    CLIENT_VERSION, //string
    CLIENT_PLATFORM, //string
    CLIENT_INPUT_MUTED, //int
    CLIENT_OUTPUT_MUTED, //int
    CLIENT_INPUT_HARDWARE, //int
    CLIENT_OUTPUT_HARDWARE, //int
    CLIENT_CHANNEL_GROUP_ID, //int
    CLIENT_SERVER_GROUPS, //string (list of numbers, separated by a comma)
    CLIENT_FIRSTCONNECTED, //int (UTC timestamp of first connection)
    CLIENT_LASTCONNECTED, //int (UTC timestamp of last connection)
    CLIENT_TOTALCONNECTIONS, //int
    CLIENT_AWAY, //int
    CLIENT_AWAY_MESSAGE, //string
    CLIENT_AVATAR, //string
    CLIENT_TALK_POWER, //int
    CLIENT_TALK_REQUEST, //int
    CLIENT_TALK_REQUEST_MSG, //string
    CLIENT_IS_TALKER, //int
    CLIENT_IS_PRIORITY_SPEAKER, //int
    CLIENT_DESCRIPTION, //string
    CLIENT_IS_CHANNEL_COMMANDER, //int
    CLIENT_ICON_ID, //int
    CLIENT_COUNTRY, //string
    CLIENT_IDLE_TIME, //int (seconds)
    CLIENT_IS_RECORDING //int
    };


    enum /*teamspeak channel codecs*/
    {
    CODEC_SPEEX_NARROWBAND = 0, // 0: speex narrowband (mono, 16bit, 8kHz)
    CODEC_SPEEX_WIDEBAND, // 1: speex wideband (mono, 16bit, 16kHz)
    CODEC_SPEEX_ULTRAWIDEBAND, // 2: speex ultra-wideband (mono, 16bit, 32kHz)
    CODEC_CELT_MONO, // 3: celt mono (mono, 16bit, 48kHz)
    CODEC_OPUS_VOICE, //4: opus voice
    CODEC_OPUS_MUSIC //5: opus music
    };


    enum TSC_ERROR_TYPE
    {
    INVALID,
    CONNECTION_ERROR,
    TEAMSPEAK_ERROR,
    CALLBACK_ERROR
    };



    //server functions
    native TSC_Connect(user[], pass[], hostname[], port = 9987, serverquery_port = 10011);
    native TSC_Disconnect();
    native TSC_ChangeNickname(nickname[]);
    native TSC_SendServerMessage(msg[]);



    //data query functions
    native TSC_QueryChannelData(channelid, TSC_CHANNEL_QUERYDATA:data, const callback[], const format[] = "", {Float, _}:...);
    native TSC_QueryClientData(clientid, TSC_CLIENT_QUERYDATA:data, const callback[], const format[] = "", {Float, _}:...);
    native TSC_GetQueriedData(dest[], max_len = sizeof(dest));
    native TSC_GetQueriedDataAsInt();



    //channel functions
    native TSC_CreateChannel(channelname[], TSC_CHANNELTYPE:type = TEMPORARY, maxusers = -1, parentchannelid = -1, upperchannelid = -1, talkpower = 0);
    native TSC_DeleteChannel(channelid);
    native TSC_GetChannelIdByName(channelname[]);
    native TSC_IsValidChannel(channelid);
    native TSC_SetChannelName(channelid, channelname[]);
    native TSC_GetChannelName(channelid, dest[], maxlen = sizeof(dest));
    native TSC_SetChannelDescription(channelid, desc[]);
    native TSC_SetChannelType(channelid, TSC_CHANNELTYPE:type);
    native TSC_CHANNELTYPE:TSC_GetChannelType(channelid);
    native TSC_SetChannelPassword(channelid, password[]);
    native TSC_HasChannelPassword(channelid);
    native TSC_SetChannelRequiredTP(channelid, talkpower);
    native TSC_GetChannelRequiredTP(channelid);
    native TSC_SetChannelUserLimit(channelid, maxusers);
    native TSC_GetChannelUserLimit(channelid);
    native TSC_SetChannelParentId(channelid, parentchannelid);
    native TSC_GetChannelParentId(channelid);
    native TSC_SetChannelOrderId(channelid, upperchannelid);
    native TSC_GetChannelOrderId(channelid);
    native TSC_GetDefaultChannelId();



    //client functions
    native TSC_GetClientIdByUid(uid[]);
    native TSC_GetClientIdByIpAddress(ip[]);


    native TSC_GetClientUid(clientid, dest[], maxlen = sizeof(dest));
    native TSC_GetClientDatabaseId(clientid);
    native TSC_GetClientChannelId(clientid);
    native TSC_GetClientIpAddress(clientid, dest[], maxlen = sizeof(dest));


    native TSC_KickClient(clientid, TSC_KICKTYPE:kicktype, reasonmsg[] = "");
    native TSC_BanClient(clientuid[], seconds, reasonmsg[]);
    native TSC_MoveClient(clientid, channelid);


    native TSC_SetClientChannelGroup(clientid, groupid, channelid);
    native TSC_AddClientToServerGroup(clientid, groupid);
    native TSC_RemoveClientFromServerGroup(clientid, groupid);


    native TSC_PokeClient(clientid, msg[]);
    native TSC_SendClientMessage(clientid, msg[]);





    //server callbacks
    forward TSC_OnConnect();
    forward TSC_OnError(TSC_ERROR_TYPE:error_type, error_id, const error_msg[]);


    //channel callbacks
    forward TSC_OnChannelCreated(channelid);
    forward TSC_OnChannelDeleted(channelid);
    forward TSC_OnChannelReorder(channelid, orderid);
    forward TSC_OnChannelMoved(channelid, parentid, orderid);
    forward TSC_OnChannelRenamed(channelid, name[]);
    forward TSC_OnChannelPasswordEdited(channelid, bool:ispassworded, bool:passwordchanged);
    forward TSC_OnChannelTypeChanged(channelid, TSC_CHANNELTYPE:type);
    forward TSC_OnChannelSetDefault(channelid);
    forward TSC_OnChannelMaxClientsChanged(channelid, maxclients);
    forward TSC_OnChannelRequiredTPChanged(channelid, talkpower);


    //client callbacks
    forward TSC_OnClientConnect(clientid, nickname[]);
    forward TSC_OnClientDisconnect(clientid, reasonid, reasonmsg[]);
    forward TSC_OnClientMoved(clientid, to_channelid, invokerid);
    forward TSC_OnClientServerText(clientid, nickname[], msg[]);
    forward TSC_OnClientPrivateText(from_clid, from_nickname[], to_clid, msg[]);


    hey ich habe grade angefangen mit dem Ts3 connector zu arbeiten alledings habe ich grade eine fehler


    C:\Users\Admin\Desktop\ServerKram\EpicRP\gamemodes\epicRoleplay.pwn(7411) : error 035: argument type mismatch (argument 4)Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase1 Error.


    Und das hier ist die Betroffene zeile


    TSC_Connect("serveradmin", "********", "Epic-roleplay.de", "9987","10011");