Beiträge von DerFamer

    public DestroyAndCreateFactionCar(fc){
    if(FactionCars[fc][fVehid] >= 400 && FactionCars[fc][fVehid] <= 611){
    DestroyVehicle(FactionCars[fc][fCarid]);
    FactionCars[fc][fCarid] = CreateVehicle(FactionCars[fc][fVehid],FactionCars[fc][fPos][0],FactionCars[fc][fPos][1],FactionCars[fc][fPos][2],FactionCars[fc][fPos][3],FactionCars[fc][fCol][0],FactionCars[fc][fCol][1],-255);
    #if defined FACTION_CARS_TUNEABLE
    if(IsAllowedFactionToTune(FactionCars[fc][fFaction][0])){
    if(FactionCars[fc][fTuning][0] != 0) { AddVehicleComponent(FactionCars[fc][fCarid],FactionCars[fc][fTuning][0]); }
    if(FactionCars[fc][fTuning][1] != 0) { AddVehicleComponent(FactionCars[fc][fCarid],FactionCars[fc][fTuning][1]); }
    if(FactionCars[fc][fTuning][2] != 0) { AddVehicleComponent(FactionCars[fc][fCarid],FactionCars[fc][fTuning][2]); }
    if(FactionCars[fc][fTuning][3] != 0) { AddVehicleComponent(FactionCars[fc][fCarid],FactionCars[fc][fTuning][3]); }
    if(FactionCars[fc][fTuning][4] != 0) { AddVehicleComponent(FactionCars[fc][fCarid],FactionCars[fc][fTuning][4]); }
    if(FactionCars[fc][fTuning][5] != 0) { AddVehicleComponent(FactionCars[fc][fCarid],FactionCars[fc][fTuning][5]); }
    if(FactionCars[fc][fTuning][6] != 0) { AddVehicleComponent(FactionCars[fc][fCarid],FactionCars[fc][fTuning][6]); }
    if(FactionCars[fc][fTuning][7] != 0) { AddVehicleComponent(FactionCars[fc][fCarid],FactionCars[fc][fTuning][7]); }
    if(FactionCars[fc][fTuning][8] != 0) { AddVehicleComponent(FactionCars[fc][fCarid],FactionCars[fc][fTuning][8]); }
    if(FactionCars[fc][fTuning][9] != 0) { AddVehicleComponent(FactionCars[fc][fCarid],FactionCars[fc][fTuning][9]); }
    if(FactionCars[fc][fTuning][10] != 0) { AddVehicleComponent(FactionCars[fc][fCarid],FactionCars[fc][fTuning][10]); }
    if(FactionCars[fc][fTuning][11] != 0) { AddVehicleComponent(FactionCars[fc][fCarid],FactionCars[fc][fTuning][11]); }
    if(FactionCars[fc][fTuning][12] != 0) { AddVehicleComponent(FactionCars[fc][fCarid],FactionCars[fc][fTuning][12]); }
    if(FactionCars[fc][fTuning][13] != 0) { AddVehicleComponent(FactionCars[fc][fCarid],FactionCars[fc][fTuning][13]); }
    }
    #endif
    }return true;
    }

    public RespawnFactionBuylist(){
    for(new fbl;fbl<sizeof(FactionBuylist);fbl++)
    SetVehicleToRespawn(FactionBuylist[fbl][fbCarid]);
    return 1;
    }


    Soweit ich jetz nachgeschaut habe finde ich nur diesen hier!


    //E:
    Befehl zum Respawnen


    if(strcmp(cmdtext,"/rafa",true)==0){
    if(GetPlayerAdmin(playerid) >= NEEDED_ADMINLEVEL){
    new fName[MAX_PLAYER_NAME],string[128];
    GetPlayerName(playerid,fName,sizeof(fName));
    format(string,sizeof(string),"Server: %s hat alle Fraktionsfahrzeuge respawnt.",fName);
    SendClientMessageToAll(FACTION_COL_YELLOW,string);
    for(new fc;fc<sizeof(FactionCars);fc++){
    if(FactionCars[fc][fVehid] >= 400 && FactionCars[fc][fVehid] <= 611)
    DestroyAndCreateFactionCar(fc);
    }
    }else SendClientMessage(playerid,FACTION_COL_GREY,"Du bist nicht berechtigt diesen Befehl anzuwenden.");
    return true;
    }
    if(strcmp(cmdtext,"/ramfa",true)==0){
    if(GetPlayerLeader(playerid)){
    if(gettime() < LastRespawned[GetPlayerFaction(playerid)-1])
    return SendClientMessage(playerid,FACTION_COL_GREY,"Du kannst deine Fahrzeuge nur alle '1' Minuten respawnen.");
    LastRespawned[GetPlayerFaction(playerid)-1] = gettime()+(60*1);
    for(new fc;fc<sizeof(FactionCars);fc++){
    if(FactionCars[fc][fVehid] >= 400 && FactionCars[fc][fVehid] <= 611){
    if(FactionCars[fc][fFaction][0] == GetPlayerFaction(playerid)){
    DestroyAndCreateFactionCar(fc);
    }
    }
    }SendClientMessage(playerid,FACTION_COL_YELLOW,"Du hast deine Fraktionsfahrzeuge erfolgreich respawnt.");
    }else SendClientMessage(playerid,FACTION_COL_GREY,"Du bist nicht berechtigt diesen Befehl anzuwenden.");
    return true;
    }

    Function PlayerCarSpawn(playerid,Slot)
    {
    if(IsPlayerConnected(playerid))
    {
    if(Dtc_PlayerHaveCar[playerid][Slot])
    {
    PlayerCar[playerid][Slot][CarId] = CreateVehicle(PlayerCar[playerid][Slot][CarModel],PlayerCar[playerid][Slot][CarPos_x],PlayerCar[playerid][Slot][CarPos_y],PlayerCar[playerid][Slot][CarPos_z],PlayerCar[playerid][Slot][CarRotate],PlayerCar[playerid][Slot][CarC1],PlayerCar[playerid][Slot][CarC2],respawntime);/*vehicle spawn*/
    ChangeVehicleColor(PlayerCar[playerid][Slot][CarId],PlayerCar[playerid][Slot][CarC1],PlayerCar[playerid][Slot][CarC2]);
    if(PlayerCar[playerid][Slot][CarPJ] >= 0) {ChangeVehiclePaintjob(PlayerCar[playerid][Slot][CarId],PlayerCar[playerid][Slot][CarPJ]);}
    if(PlayerCar[playerid][Slot][CarNitro] != 0) {AddVehicleComponent(PlayerCar[playerid][Slot][CarId],PlayerCar[playerid][Slot][CarNitro]);}
    if(PlayerCar[playerid][Slot][CarHyd] != 0) {AddVehicleComponent(PlayerCar[playerid][Slot][CarId],PlayerCar[playerid][Slot][CarHyd]);}
    if(PlayerCar[playerid][Slot][CarWheel] != 0) {AddVehicleComponent(PlayerCar[playerid][Slot][CarId],PlayerCar[playerid][Slot][CarWheel]);}
    if(PlayerCar[playerid][Slot][CarAusp] != 0) {AddVehicleComponent(PlayerCar[playerid][Slot][CarId],PlayerCar[playerid][Slot][CarAusp]);}
    if(PlayerCar[playerid][Slot][CarSideL] != 0) {AddVehicleComponent(PlayerCar[playerid][Slot][CarId],PlayerCar[playerid][Slot][CarSideL]);}
    if(PlayerCar[playerid][Slot][CarSideR] != 0) {AddVehicleComponent(PlayerCar[playerid][Slot][CarId],PlayerCar[playerid][Slot][CarSideR]);}
    if(PlayerCar[playerid][Slot][CarFB] != 0) {AddVehicleComponent(PlayerCar[playerid][Slot][CarId],PlayerCar[playerid][Slot][CarFB]);}
    if(PlayerCar[playerid][Slot][CarRB] != 0) {AddVehicleComponent(PlayerCar[playerid][Slot][CarId],PlayerCar[playerid][Slot][CarRB]);}
    if(PlayerCar[playerid][Slot][CarSpoiler] != 0) {AddVehicleComponent(PlayerCar[playerid][Slot][CarId],PlayerCar[playerid][Slot][CarSpoiler]);}
    if(PlayerCar[playerid][Slot][CarRoof] != 0) {AddVehicleComponent(PlayerCar[playerid][Slot][CarId],PlayerCar[playerid][Slot][CarRoof]);}
    if(PlayerCar[playerid][Slot][CarHood] != 0) {AddVehicleComponent(PlayerCar[playerid][Slot][CarId],PlayerCar[playerid][Slot][CarHood]);}
    if(PlayerCar[playerid][Slot][CarVents] != 0) {AddVehicleComponent(PlayerCar[playerid][Slot][CarId],PlayerCar[playerid][Slot][CarVents]);}
    if(PlayerCar[playerid][Slot][CarLamps] != 0) {AddVehicleComponent(PlayerCar[playerid][Slot][CarId],PlayerCar[playerid][Slot][CarLamps]);}
    if(Dtc_LockOnSpawn)
    {
    Dtc_Carlock[PlayerCar[playerid][Slot][CarId]] = 1;
    Dtc_LockCar(PlayerCar[playerid][Slot][CarId]);
    }
    new strings[15];
    new name[MAX_PLAYER_NAME], str[128];
    GetPlayerName(playerid, name, sizeof name);
    format(str, sizeof str, "/Autos/%s%d.dtcar", name,Dtc_PlayerKey[playerid]);
    format(strings, sizeof(strings), "%s", dini_Get(str, "Plate"));
    SetVehicleNumberPlate(PlayerCar[playerid][Slot][CarId], strings);
    SetVehicleToRespawn(PlayerCar[playerid][Slot][CarId]);
    for(new x = 0; x < MaxVeh; x++)
    {
    PlayerCar[playerid][x][Plate] = strings;
    }
    }
    }
    }
    Function OnVehicleMod(playerid,vehicleid,componentid)
    {
    FRAC_OnVehicleMod(playerid, vehicleid, componentid);
    for(new x = 0; x < MaxVeh; x++)
    {
    if (vehicleid == PlayerCar[playerid][x][CarId] && Dtc_PlayerHaveCar[playerid][x])
    {
    if((componentid >= 1008) && (componentid <= 1010)) {PlayerCar[playerid][x][CarNitro] = componentid;}
    if((componentid >= 1142) && (componentid <= 1145)) {PlayerCar[playerid][x][CarVents] = componentid;}
    if((componentid == 1013) || (componentid == 1024)) {PlayerCar[playerid][x][CarLamps] = componentid;}
    if((componentid >= 1004) && (componentid <= 1005)||(componentid >= 1011) && (componentid <= 1012)) {PlayerCar[playerid][x][CarHood] = componentid;}
    if(componentid == 1087) {PlayerCar[playerid][x][CarHyd] = componentid;}
    if(componentid == 1086) {PlayerCar[playerid][x][CarHyd] = componentid;}
    if(IsAWheel(componentid)) {PlayerCar[playerid][x][CarWheel] = componentid;}
    if(IsAExhaust(componentid)) {PlayerCar[playerid][x][CarAusp] = componentid;}
    if(IsASideL(componentid)) {PlayerCar[playerid][x][CarSideL] = componentid; PlayerCar[playerid][x][CarSideR] = SideR;}
    if(IsASideR(componentid)) {PlayerCar[playerid][x][CarSideR] = componentid; PlayerCar[playerid][x][CarSideL] = SideL;}
    if(IsAFB(componentid)) {PlayerCar[playerid][x][CarFB] = componentid;}
    if(IsARB(componentid)) {PlayerCar[playerid][x][CarRB] = componentid;}
    if(IsASpoiler(componentid)) {PlayerCar[playerid][x][CarSpoiler] = componentid;}
    if(IsARoof(componentid)) {PlayerCar[playerid][x][CarRoof] = componentid;}
    }
    }
    return 1;
    }


    Das Problem hab ich auch^^

    Function OnVehicleDeath(vehicleid)
    {
    for(new playerid = 0; playerid < MAX_PLAYERS; playerid++)
    {
    for(new x = 0; x < MaxVeh; x++)
    {
    if(IsPlayerConnected(playerid) && Dtc_PlayerHaveCar[playerid][x])
    {
    if (vehicleid == PlayerCar[playerid][x][CarId])
    {
    DestroyVehicle(PlayerCar[playerid][x][CarId]);
    PlayerCarSpawn(playerid,x);
    }
    }
    }
    }
    return 1;
    }

    Aloha Liebe Bredfishler!


    Ich habe ein Problem.


    Undzwar ich habe nichts im script geändert und er compeilt nicht mehr?


    Bitte um Hilfe danke!


    //E:


    Habe Versucht mit Admin den pawno auszuführen!

    dcmd_efa(playerid,params[]){
    if(GetPlayerAdmin(playerid) >= NEEDED_ADMINLEVEL){
    new vehid,col1,col2,faction[5];
    if(!sscanf(params,"dddd",vehid,col1,col2,faction[0])){
    sscanf(params,"dddddddd",vehid,col1,col2,faction[0],faction[1],faction[2],faction[3],faction[4]);
    if(vehid < 400 || vehid > 611) return SendClientMessage(playerid,FACTION_COL_GREY,"Vehicle-ID nur von 400 bis 611.");
    if(col1 < 0 || col1 > 255) return SendClientMessage(playerid,FACTION_COL_GREY,"Falsche Farbe(1)!");
    if(col2 < 0 || col2 > 255) return SendClientMessage(playerid,FACTION_COL_GREY,"Falsche Farbe(2)!");
    if(faction[0] && faction[0] <= MAX_FACTIONS){
    for(new f;f<5;f++){
    if(faction[f] <= 0 || faction[f] > MAX_FACTIONS){
    faction[f] = -255;
    }
    }
    for(new fc;fc<sizeof(FactionCars);fc++){
    if(FactionCars[fc][fVehid] < 400 || FactionCars[fc][fVehid] > 611){
    FactionCars[fc][fVehid] = vehid;
    new Float:fX,Float:fY,Float:fZ,Float:fA;
    GetPlayerPos(playerid,fX,fY,fZ),GetPlayerFacingAngle(playerid,fA);
    FactionCars[fc][fPos][0] = fX;
    FactionCars[fc][fPos][1] = fY;
    FactionCars[fc][fPos][2] = fZ;
    FactionCars[fc][fPos][3] = fA;
    FactionCars[fc][fCol][0] = col1;
    FactionCars[fc][fCol][1] = col2;
    for(new f;f<5;f++){
    FactionCars[fc][fFaction][f] = faction[f];
    }
    FactionCars[fc][fPrice] = 0;
    for(new mod;mod<14;mod++)
    FactionCars[fc][fTuning][mod] = 0;
    FactionCars[fc][fCarid] = CreateVehicle(FactionCars[fc][fVehid],FactionCars[fc][fPos][0],FactionCars[fc][fPos][1],FactionCars[fc][fPos][2],FactionCars[fc][fPos][3],FactionCars[fc][fCol][0],FactionCars[fc][fCol][1],-255);
    #if defined FACTION_CARS_LOCKABLE
    FactionCars[fc][fLock] = true;
    #endif
    SendClientMessage(playerid,FACTION_COL_YELLOW,"Du hast das Fraktionsfahrzeug erfolgreich erstellt.");
    SendClientMessage(playerid,FACTION_COL_YELLOW,"Vergesse es nicht mit '/fpark' umzuparken.");
    PutPlayerInVehicle(playerid,FactionCars[fc][fCarid],0);
    return true;
    }
    }SendClientMessage(playerid,FACTION_COL_GREY,"Die Maximale Anzahl von Fraktionsfahrzeugen wurde bereits erreicht.");
    }else SendClientMessage(playerid,FACTION_COL_GREY,"Falsche Fraktion!");
    }else SendClientMessage(playerid,FACTION_COL_GREY,"Benutze: '/efa [Model] [Farbe(1)] [Farbe(2)] [Hauptfraktion]'.");
    }else SendClientMessage(playerid,FACTION_COL_GREY,"Du bist nicht berechtigt diesen Befehl anzuwenden.");
    return true;
    }


    So erstelle ich die Autos