Fraktions Fahrzeuge Frage

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
  • Hay wie kann ich bei Ordnungsamt das Kennzeichen so machen:


    Also bei jeden anders:




    new kennzeichen[12];
    format(kennzeichen, sizeof(kennzeichen), "LV-%d", randomEx(1000, 9999));
    SetVehicleNumberPlate(oAmtVehs[v], kennzeichen);
    SetVehicleToRespawn(oAmtVehs[v]);





    public LoadFactionCars(){
    if(!fexist(FACTION_CAR_FILE)){
    new File:tfFile=fopen(FACTION_CAR_FILE,io_write);
    fclose(tfFile);
    }
    new File:fFile=fopen(FACTION_CAR_FILE,io_read),Content[1024],fc;
    while(fread(fFile,Content) && fc<sizeof(FactionCars)){
    sscanf(Content,"dffffdddddddddddddddddddddd",
    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],
    FactionCars[fc][fFaction][0],
    FactionCars[fc][fFaction][1],
    FactionCars[fc][fFaction][2],
    FactionCars[fc][fFaction][3],
    FactionCars[fc][fFaction][4],
    FactionCars[fc][fTuning][0],
    FactionCars[fc][fTuning][1],
    FactionCars[fc][fTuning][2],
    FactionCars[fc][fTuning][3],
    FactionCars[fc][fTuning][4],
    FactionCars[fc][fTuning][5],
    FactionCars[fc][fTuning][6],
    FactionCars[fc][fTuning][7],
    FactionCars[fc][fTuning][8],
    FactionCars[fc][fTuning][9],
    FactionCars[fc][fTuning][10],
    FactionCars[fc][fTuning][11],
    FactionCars[fc][fTuning][12],
    FactionCars[fc][fTuning][13],
    FactionCars[fc][fPrice]);
    if(FactionCars[fc][fVehid] >= 400 && FactionCars[fc][fVehid] <= 611){
    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);
    switch(FactionCars[fc][fFaction][0])
    {
    case 1: SetVehicleNumberPlate(FactionCars[fc][fCarid], "LSPD");
    case 2: SetVehicleNumberPlate(FactionCars[fc][fCarid], "FBI");
    case 3: SetVehicleNumberPlate(FactionCars[fc][fCarid], "ARMY");
    case 4: SetVehicleNumberPlate(FactionCars[fc][fCarid], "ARZT");
    case 5: SetVehicleNumberPlate(FactionCars[fc][fCarid], "LCM");
    case 6: SetVehicleNumberPlate(FactionCars[fc][fCarid], "YAKUZA");
    case 7: SetVehicleNumberPlate(FactionCars[fc][fCarid], "PRÄSIDENT");
    case 8: SetVehicleNumberPlate(FactionCars[fc][fCarid], "HITMAN");
    case 9: SetVehicleNumberPlate(FactionCars[fc][fCarid], "SAN NEWS");
    case 10: SetVehicleNumberPlate(FactionCars[fc][fCarid], "TAXI");
    case 11: SetVehicleNumberPlate(FactionCars[fc][fCarid], "FAHRLEHRER");
    case 12: SetVehicleNumberPlate(FactionCars[fc][fCarid], "TRIADEN");
    case 13: SetVehicleNumberPlate(FactionCars[fc][fCarid], "GROVE");
    case 14: SetVehicleNumberPlate(FactionCars[fc][fCarid], "BALLAS");
    case 15: SetVehicleNumberPlate(FactionCars[fc][fCarid], "BIKER CLUB");
    case 16: SetVehicleNumberPlate(FactionCars[fc][fCarid], "VAGOS");
    case 17: SetVehicleNumberPlate(FactionCars[fc][fCarid], "AZTECAS");
    case 18: SetVehicleNumberPlate(FactionCars[fc][fCarid], "RIFA");
    case 19: SetVehicleNumberPlate(FactionCars[fc][fCarid], "RS");
    case 20: SetVehicleNumberPlate(FactionCars[fc][fCarid], "TERROR");
    case 21: SetVehicleNumberPlate(FactionCars[fc][fCarid], "WHEELMEN");
    case 22: SetVehicleNumberPlate(FactionCars[fc][fCarid], "FEUERWEHR");
    case 23: SetVehicleNumberPlate(FactionCars[fc][fCarid], "RUSSEN");
    case 24: SetVehicleNumberPlate(FactionCars[fc][fCarid], "ORDNUNGSAMT");
    }
    SetVehicleToRespawn(FactionCars[fc][fCarid]);
    printf("Fahrzeug %d (Idx: %d) steht: %f / %f / %f", FactionCars[fc][fCarid], fc, FactionCars[fc][fPos][0],FactionCars[fc][fPos][1],FactionCars[fc][fPos][2]);
    SetVehicleToRespawn(FactionCars[fc][fCarid]);
    printf("%d gehört zu: %d", FactionCars[fc][fCarid], FactionCars[fc][fFaction][0]);
    SetVehicleToRespawn(FactionCars[fc][fCarid]);
    #if defined FACTION_CARS_LOCKABLE
    fLockCar(FactionCars[fc][fCarid]);
    FactionCars[fc][fLock] = true;
    #endif
    #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
    fc++;
    }
    }fclose(fFile);
    return printf(" '%d' Fraktionsfahrzeuge wurden geladen & erstellt.",fc);
    }

  • C
    case 24: SetVehicleNumberPlate(FactionCars[fc][fCarid], "ORDNUNGSAMT");

    zu


    C
    case 24:
    {
    	new kennzeichen[12];
    	format(kennzeichen,sizeof(kennzeichen),"AMT-%d",randomEx(1000,9999));
    	SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }

    Meinst du so? :D

  • public LoadFactionCars(){
    if(!fexist(FACTION_CAR_FILE)){
    new File:tfFile=fopen(FACTION_CAR_FILE,io_write);
    fclose(tfFile);
    }
    new File:fFile=fopen(FACTION_CAR_FILE,io_read),Content[1024],fc;
    while(fread(fFile,Content) && fc<sizeof(FactionCars)){
    sscanf(Content,"dffffdddddddddddddddddddddd",
    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],
    FactionCars[fc][fFaction][0],
    FactionCars[fc][fFaction][1],
    FactionCars[fc][fFaction][2],
    FactionCars[fc][fFaction][3],
    FactionCars[fc][fFaction][4],
    FactionCars[fc][fTuning][0],
    FactionCars[fc][fTuning][1],
    FactionCars[fc][fTuning][2],
    FactionCars[fc][fTuning][3],
    FactionCars[fc][fTuning][4],
    FactionCars[fc][fTuning][5],
    FactionCars[fc][fTuning][6],
    FactionCars[fc][fTuning][7],
    FactionCars[fc][fTuning][8],
    FactionCars[fc][fTuning][9],
    FactionCars[fc][fTuning][10],
    FactionCars[fc][fTuning][11],
    FactionCars[fc][fTuning][12],
    FactionCars[fc][fTuning][13],
    FactionCars[fc][fPrice]);
    if(FactionCars[fc][fVehid] >= 400 && FactionCars[fc][fVehid] <= 611){
    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);
    switch(FactionCars[fc][fFaction][0])
    {
    case 1: SetVehicleNumberPlate(FactionCars[fc][fCarid], "LSPD");
    case 2: SetVehicleNumberPlate(FactionCars[fc][fCarid], "FBI");
    case 3: SetVehicleNumberPlate(FactionCars[fc][fCarid], "ARMY");
    case 4: SetVehicleNumberPlate(FactionCars[fc][fCarid], "ARZT");
    case 5: SetVehicleNumberPlate(FactionCars[fc][fCarid], "LCM");
    case 6: SetVehicleNumberPlate(FactionCars[fc][fCarid], "YAKUZA");
    case 7: SetVehicleNumberPlate(FactionCars[fc][fCarid], "PRÄSIDENT");
    case 8: SetVehicleNumberPlate(FactionCars[fc][fCarid], "HITMAN");
    case 9: SetVehicleNumberPlate(FactionCars[fc][fCarid], "SAN NEWS");
    case 10: SetVehicleNumberPlate(FactionCars[fc][fCarid], "TAXI");
    case 11: SetVehicleNumberPlate(FactionCars[fc][fCarid], "FAHRLEHRER");
    case 12: SetVehicleNumberPlate(FactionCars[fc][fCarid], "TRIADEN");
    case 13: SetVehicleNumberPlate(FactionCars[fc][fCarid], "GROVE");
    case 14: SetVehicleNumberPlate(FactionCars[fc][fCarid], "BALLAS");
    case 15: SetVehicleNumberPlate(FactionCars[fc][fCarid], "BIKER CLUB");
    case 16: SetVehicleNumberPlate(FactionCars[fc][fCarid], "VAGOS");
    case 17: SetVehicleNumberPlate(FactionCars[fc][fCarid], "AZTECAS");
    case 18: SetVehicleNumberPlate(FactionCars[fc][fCarid], "RIFA");
    case 19: SetVehicleNumberPlate(FactionCars[fc][fCarid], "RS");
    case 20: SetVehicleNumberPlate(FactionCars[fc][fCarid], "TERROR");
    case 21: SetVehicleNumberPlate(FactionCars[fc][fCarid], "WHEELMEN");
    case 22: SetVehicleNumberPlate(FactionCars[fc][fCarid], "FEUERWEHR");
    case 23:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LV-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    case 24:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LV-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    }
    SetVehicleToRespawn(FactionCars[fc][fCarid]);
    printf("Fahrzeug %d (Idx: %d) steht: %f / %f / %f", FactionCars[fc][fCarid], fc, FactionCars[fc][fPos][0],FactionCars[fc][fPos][1],FactionCars[fc][fPos][2]);
    SetVehicleToRespawn(FactionCars[fc][fCarid]);
    printf("%d gehört zu: %d", FactionCars[fc][fCarid], FactionCars[fc][fFaction][0]);
    SetVehicleNumberPlate(FactionCars[fc][fCarid], kennzeichen);
    #if defined FACTION_CARS_LOCKABLE
    new kennzeichen[12];
    format(kennzeichen, sizeof(kennzeichen), "LV-%d", randomEx(1000, 9999));
    fLockCar(FactionCars[fc][fCarid]);
    FactionCars[fc][fLock] = true;
    #endif
    #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
    fc++;
    }
    }fclose(fFile);
    return printf(" '%d' Fraktionsfahrzeuge wurden geladen & erstellt.",fc);
    }



    Geht das so?

  • C:\Windows\Vss\German v1.1\German[Scripts]\German Reallife v1.2\gamemodes\German.pwn(53750) : error 002: only a single statement (or expression) can follow each "case"C:\Windows\Vss\German v1.1\German[Scripts]\German Reallife v1.2\gamemodes\German.pwn(53750) : warning 215: expression has no effect



    public LoadFactionCars(){
    if(!fexist(FACTION_CAR_FILE)){
    new File:tfFile=fopen(FACTION_CAR_FILE,io_write);
    fclose(tfFile);
    }
    new File:fFile=fopen(FACTION_CAR_FILE,io_read),Content[1024],fc;
    while(fread(fFile,Content) && fc<sizeof(FactionCars)){
    sscanf(Content,"dffffdddddddddddddddddddddd",
    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],
    FactionCars[fc][fFaction][0],
    FactionCars[fc][fFaction][1],
    FactionCars[fc][fFaction][2],
    FactionCars[fc][fFaction][3],
    FactionCars[fc][fFaction][4],
    FactionCars[fc][fTuning][0],
    FactionCars[fc][fTuning][1],
    FactionCars[fc][fTuning][2],
    FactionCars[fc][fTuning][3],
    FactionCars[fc][fTuning][4],
    FactionCars[fc][fTuning][5],
    FactionCars[fc][fTuning][6],
    FactionCars[fc][fTuning][7],
    FactionCars[fc][fTuning][8],
    FactionCars[fc][fTuning][9],
    FactionCars[fc][fTuning][10],
    FactionCars[fc][fTuning][11],
    FactionCars[fc][fTuning][12],
    FactionCars[fc][fTuning][13],
    FactionCars[fc][fPrice]);
    if(FactionCars[fc][fVehid] >= 400 && FactionCars[fc][fVehid] <= 611){
    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);
    switch(FactionCars[fc][fFaction][0])
    {
    case 1:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LS-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    case 2:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"SF-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    case 3:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LV-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    case 4:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LS-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    case 5:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LV-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    case 6:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LV-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    case 7:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LS-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    case 8:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LV-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    case 9:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LV-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    case 10:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LS-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    case 11:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LS-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    case 12:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LV-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    case 13:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LS-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    case 14:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LS-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    case 15:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LS-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    case 16:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LS-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    case 17:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LS-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    case 18:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LS-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    case 19:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LS-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    case 20:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LS-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    case 21:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LS-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    case 22:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LS-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    case 23:
    {
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LV-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    case 24:
    {
    if(GetVehicleModel(FactionCars[fc][fCarid]) == 560) //53750
    {
    new obj = CreateObject(19420,0,0,0,0,0,0);
    AttachObjectToVehicle(obj, FactionCars[fc][fCarid], 0.000000, 0.000000, 0.814999, 0.000000, 0.000000, 0.000000);
    new kennzeichen[12];
    format(kennzeichen,sizeof(kennzeichen),"LV-%d",randomEx(1000,9999));
    SetVehicleNumberPlate(FactionCars[fc][fCarid],kennzeichen);
    }
    }
    SetVehicleToRespawn(FactionCars[fc][fCarid]);
    printf("Fahrzeug %d (Idx: %d) steht: %f / %f / %f", FactionCars[fc][fCarid], fc, FactionCars[fc][fPos][0],FactionCars[fc][fPos][1],FactionCars[fc][fPos][2]);
    SetVehicleToRespawn(FactionCars[fc][fCarid]);
    printf("%d gehört zu: %d", FactionCars[fc][fCarid], FactionCars[fc][fFaction][0]);
    #if defined FACTION_CARS_LOCKABLE
    fLockCar(FactionCars[fc][fCarid]);
    FactionCars[fc][fLock] = true;
    #endif
    #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
    fc++;
    }
    }fclose(fFile);
    return printf(" '%d' Fraktionsfahrzeuge wurden geladen & erstellt.",fc);
    }
    [size=12]


    Ich wollte bei case 24: einfach machen das wen ich für 24 ein fahzeug erstelle. Das die Sirene nur auf ID 560 ist.[/size]

    2 Mal editiert, zuletzt von DerFamer ()