Beiträge von [BlaZZeR]BirD

    die fehler haben nichts mit dem waffen speichern/laden zu tun die kommen irgentwie von meinem Fraktions system (was aber nicht seien kann da wen ich normal compile ohne das waffen speichern/laden system keine fehler bekomme)

    ich hab mir die zwei stocks und den enum + das dazugehörige new ... in mein GM kopiert den rest habe ich so gescriptet


    if(strcmp(cmdtext,"/saveguns",true)==0){
    if(PlayerInfo[playerid][pInt] >= 1){
    WaffenSpeichern(playerid);
    }return SendClientMessage(playerid,COLOR_WHITE,"Du bist in keinem Haus.");
    }
    if(strcmp(cmdtext,"/getguns",true)==0){
    if(PlayerInfo[playerid][pInt] >= 1){
    WaffenLaden(playerid);
    GivePlayerWeapon(playerid,wInfo[playerid][wslot],wInfo[playerid][aslot]);
    GivePlayerWeapon(playerid,wInfo[playerid][wslot1],wInfo[playerid][aslot1]);
    GivePlayerWeapon(playerid,wInfo[playerid][wslot2],wInfo[playerid][aslot2]);
    GivePlayerWeapon(playerid,wInfo[playerid][wslot3],wInfo[playerid][aslot3]);
    GivePlayerWeapon(playerid,wInfo[playerid][wslot4],wInfo[playerid][aslot4]);
    GivePlayerWeapon(playerid,wInfo[playerid][wslot5],wInfo[playerid][aslot5]);
    GivePlayerWeapon(playerid,wInfo[playerid][wslot6],wInfo[playerid][aslot6]);
    GivePlayerWeapon(playerid,wInfo[playerid][wslot7],wInfo[playerid][aslot7]);
    GivePlayerWeapon(playerid,wInfo[playerid][wslot8],wInfo[playerid][aslot8]);
    GivePlayerWeapon(playerid,wInfo[playerid][wslot9],wInfo[playerid][aslot9]);
    GivePlayerWeapon(playerid,wInfo[playerid][wslot10],wInfo[playerid][aslot10]);
    GivePlayerWeapon(playerid,wInfo[playerid][wslot11],wInfo[playerid][aslot11]);
    }return SendClientMessage(playerid,COLOR_WHITE,"Du bist in keinem Haus.");
    }


    nun bekomme ich immer diese Errors
    C:\Users\Test\Desktop\Neuer Ordner\GDR.pwn(14444) : error 021: symbol already defined: "strtok"
    C:\Users\Test\Desktop\Neuer Ordner\GDR.pwn(14459) : error 047: array sizes do not match, or destination array is too small
    C:\Users\Test\Desktop\Neuer Ordner\GDR.pwn(26930) : error 047: array sizes do not match, or destination array is too small
    C:\Users\Test\Desktop\Neuer Ordner\GDR.pwn(26964) : error 047: array sizes do not match, or destination array is too small
    C:\Users\Test\Desktop\Neuer Ordner\GDR.pwn(27005) : error 047: array sizes do not match, or destination array is too small
    C:\Users\Test\Desktop\Neuer Ordner\GDR.pwn(44909) : error 021: symbol already defined: "StripNewLine"
    Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase



    6 Errors.


    die hatte ich vorher nicht..

    C:\Users\Test\Desktop\Neuer Ordner\GDR.pwn(45613) : error 017: undefined symbol "fLocked"
    Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase



    1 Error.


    Danke :) hab nurnoch diese Errors
    forward FRAC_OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]);
    public FRAC_OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]){
    if(dialogid == DIALOG_FRACTION_CAR_BUY){
    if(response){
    new Float:pPos[3];
    GetPlayerPos(playerid,pPos[0],pPos[1],pPos[2]);
    SetPlayerPos(playerid,pPos[0]+2.5,pPos[1]+2.5,pPos[2]);
    TogglePlayerControllable(playerid,true);
    }
    if(!response){
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER){
    if(IsAllowedFractionToBuy(GetPlayerLeader(playerid))){
    if(GetFractioncarsOfFraction(GetPlayerLeader(playerid)) < MAX_BUY){
    new Carid1 = GetPlayerVehicleID(playerid);
    for(new fbl;fbl<sizeof(FractionBuylist);fbl++){
    if(Carid1 == FractionBuylist[fbl][fbCarid]){
    if(CallRemoteFunction("Script_GetPlayerMoney","i",playerid) >= FractionBuylist[fbl][fbPrice]){
    for(new fc;fc<sizeof(FractionCars);fc++){
    if(FractionCars[fc][fVehid] < 400 || FractionCars[fc][fVehid] > 611){
    FractionCars[fc][fVehid] = FractionBuylist[fbl][fbVehid];
    FractionCars[fc][fPos][0] = FractionBuySpawn[0];
    FractionCars[fc][fPos][1] = FractionBuySpawn[1];
    FractionCars[fc][fPos][2] = FractionBuySpawn[2];
    FractionCars[fc][fPos][3] = FractionBuySpawn[3];
    new Color[2];
    GetDefaultCarColorOfFraction(GetPlayerLeader(playerid),Color[0],Color[1]);
    FractionCars[fc][fCol][0] = Color[0];
    FractionCars[fc][fCol][1] = Color[1];


    FractionCars[fc][fPrice] = FractionBuylist[fbl][fbPrice];
    for(new slot;slot<14;slot++)
    FractionCars[fc][fTuning][slot] = 0;
    FractionCars[fc][fCarid] = CreateVehicle(FractionCars[fc][fVehid],FractionCars[fc][fPos][0],FractionCars[fc][fPos][1],FractionCars[fc][fPos][2],FractionCars[fc][fPos][3],FractionCars[fc][fCol][0],FractionCars[fc][fCol][1],-255);
    print(">>> Nach dem Autoerstellen!");
    #if defined FRACTION_CARS_LOCKABLE
    fLockCar(FractionCars[fc][fCarid]);
    FractionCars[fc][fLocked] = true;//zeile 45613
    #endif
    for(new f;f<5;f++)
    {
    FractionCars[fc][fFraction][f] = -255;
    }
    FractionCars[fc][fFraction][0] = GetPlayerLeader(playerid);
    PutPlayerInVehicle(playerid,FractionCars[fc][fCarid],0);
    CallRemoteFunction("Script_SetPlayerMoney","id",playerid,(CallRemoteFunction("Script_GetPlayerMoney","i",playerid)-FractionBuylist[fbl][fbPrice]));
    new Float:pPos[3];
    GetPlayerPos(playerid,pPos[0],pPos[1],pPos[2]);
    SetPlayerPos(playerid,pPos[0]+2.5,pPos[1]+2.5,pPos[2]);
    TogglePlayerControllable(playerid,true);
    SendClientMessage(playerid,FRACTION_COL_YELLOW,"Glückwunsch zum neuen Fahrzeug.");
    SendClientMessage(playerid,FRACTION_COL_YELLOW,"Bitte vergesse nicht das Fahrzeug mit: '/fpark' umzuparken.");
    SendClientMessage(playerid,FRACTION_COL_YELLOW,"Das Fahrzeug steht am Ausgabepunkt bereit!");
    return 1;
    }
    }SendClientMessage(playerid,FRACTION_COL_GREY,"Die maximale Anzahl von Fraktionsfahrzeugen ist bereits erreicht.");
    }else SendClientMessage(playerid,FRACTION_COL_GREY,"Du hast nicht genügend Geld bei dir!");
    break;
    }
    }
    }else SendClientMessage(playerid,FRACTION_COL_GREY,"Deine Fraktion hat das Limit von Fahrzeugen bereits erreicht.");
    }else SendClientMessage(playerid,FRACTION_COL_GREY,"Du bist nicht brechtigt Fraktionsfahrzeuge zu kaufen!");
    new Float:pPos[3];
    GetPlayerPos(playerid,pPos[0],pPos[1],pPos[2]);
    SetPlayerPos(playerid,pPos[0]+2.5,pPos[1]+2.5,pPos[2]);
    TogglePlayerControllable(playerid,true);
    }
    }return 1;
    }return 0;
    }

    dann bekomme ich diese Errors
    C:\Users\Test\Desktop\Neuer Ordner\GDR.pwn(44929) : warning 235: public function lacks forward declaration (symbol "fLockCar")
    C:\Users\Test\Desktop\Neuer Ordner\GDR.pwn(44934) : warning 235: public function lacks forward declaration (symbol "fUnlockCar")
    C:\Users\Test\Desktop\Neuer Ordner\GDR.pwn(45613) : error 017: undefined symbol "fLocked"
    Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase



    1 Error.
    public fLockCar(Carid){//zeile 44929
    for(new i;i<GetMaxPlayers();i++){
    SetVehicleParamsForPlayer(Carid,i,0,1);
    }return 1;
    }
    public fUnlockCar(Carid){//zeile 44934
    for(new i;i<GetMaxPlayers();i++){
    SetVehicleParamsForPlayer(Carid,i,0,0);
    }return 1;
    }

    //EDIT fail hatte mich verschrieben nun kommt
    //edit2 hab viele errors/warnings wegbekommen doch diese bleiben
    //edit3 habe nur noch diese Warnings/errors pls help


    C:\Users\Test\Desktop\Neuer Ordner\GDR.pwn(44929) : warning 235: public function lacks forward declaration (symbol "fLockCar")
    C:\Users\Test\Desktop\Neuer Ordner\GDR.pwn(44934) : warning 235: public function lacks forward declaration (symbol "fUnlockCar")
    C:\Users\Test\Desktop\Neuer Ordner\GDR.pwn(45613) : error 017: undefined symbol "fLocked"
    C:\Users\Test\Desktop\Neuer Ordner\GDR.pwn(45701) : error 025: function heading differs from prototype
    C:\Users\Test\Desktop\Neuer Ordner\GDR.pwn(45701) : error 021: symbol already defined: "fLockCar"
    C:\Users\Test\Desktop\Neuer Ordner\GDR.pwn(45706) : error 025: function heading differs from prototype
    C:\Users\Test\Desktop\Neuer Ordner\GDR.pwn(45706) : error 021: symbol already defined: "fUnlockCar"
    Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase



    5 Errors.
    public fLockCar(Carid){//zeile 44929
    for(new i;i<GetMaxPlayers();i++){
    SetVehicleParamsForPlayer(Carid,i,0,1);
    }return 1;
    }
    public fUnlockCar(Carid){// zeile 44934
    for(new i;i<GetMaxPlayers();i++){
    SetVehicleParamsForPlayer(Carid,i,0,0);
    }return 1;
    }
    forward FRAC_OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]);
    public FRAC_OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]){
    if(dialogid == DIALOG_FRACTION_CAR_BUY){
    if(response){
    new Float:pPos[3];
    GetPlayerPos(playerid,pPos[0],pPos[1],pPos[2]);
    SetPlayerPos(playerid,pPos[0]+2.5,pPos[1]+2.5,pPos[2]);
    TogglePlayerControllable(playerid,true);
    }
    if(!response){
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER){
    if(IsAllowedFractionToBuy(GetPlayerLeader(playerid))){
    if(GetFractioncarsOfFraction(GetPlayerLeader(playerid)) < MAX_BUY){
    new Carid1 = GetPlayerVehicleID(playerid);
    for(new fbl;fbl<sizeof(FractionBuylist);fbl++){
    if(Carid1 == FractionBuylist[fbl][fbCarid]){
    if(CallRemoteFunction("Script_GetPlayerMoney","i",playerid) >= FractionBuylist[fbl][fbPrice]){
    for(new fc;fc<sizeof(FractionCars);fc++){
    if(FractionCars[fc][fVehid] < 400 || FractionCars[fc][fVehid] > 611){
    FractionCars[fc][fVehid] = FractionBuylist[fbl][fbVehid];
    FractionCars[fc][fPos][0] = FractionBuySpawn[0];
    FractionCars[fc][fPos][1] = FractionBuySpawn[1];
    FractionCars[fc][fPos][2] = FractionBuySpawn[2];
    FractionCars[fc][fPos][3] = FractionBuySpawn[3];
    new Color[2];
    GetDefaultCarColorOfFraction(GetPlayerLeader(playerid),Color[0],Color[1]);
    FractionCars[fc][fCol][0] = Color[0];
    FractionCars[fc][fCol][1] = Color[1];


    FractionCars[fc][fPrice] = FractionBuylist[fbl][fbPrice];
    for(new slot;slot<14;slot++)
    FractionCars[fc][fTuning][slot] = 0;
    FractionCars[fc][fCarid] = CreateVehicle(FractionCars[fc][fVehid],FractionCars[fc][fPos][0],FractionCars[fc][fPos][1],FractionCars[fc][fPos][2],FractionCars[fc][fPos][3],FractionCars[fc][fCol][0],FractionCars[fc][fCol][1],-255);
    print(">>> Nach dem Autoerstellen!");
    #if defined FRACTION_CARS_LOCKABLE
    fLockCar(FractionCars[fc][fCarid]);
    FractionCars[fc][fLocked] = true;//zeile 45613
    #endif
    for(new f;f<5;f++)
    {
    FractionCars[fc][fFraction][f] = -255;
    }
    FractionCars[fc][fFraction][0] = GetPlayerLeader(playerid);
    PutPlayerInVehicle(playerid,FractionCars[fc][fCarid],0);
    CallRemoteFunction("Script_SetPlayerMoney","id",playerid,(CallRemoteFunction("Script_GetPlayerMoney","i",playerid)-FractionBuylist[fbl][fbPrice]));
    new Float:pPos[3];
    GetPlayerPos(playerid,pPos[0],pPos[1],pPos[2]);
    SetPlayerPos(playerid,pPos[0]+2.5,pPos[1]+2.5,pPos[2]);
    TogglePlayerControllable(playerid,true);
    SendClientMessage(playerid,FRACTION_COL_YELLOW,"Glückwunsch zum neuen Fahrzeug.");
    SendClientMessage(playerid,FRACTION_COL_YELLOW,"Bitte vergesse nicht das Fahrzeug mit: '/fpark' umzuparken.");
    SendClientMessage(playerid,FRACTION_COL_YELLOW,"Das Fahrzeug steht am Ausgabepunkt bereit!");
    return 1;
    }
    }SendClientMessage(playerid,FRACTION_COL_GREY,"Die maximale Anzahl von Fraktionsfahrzeugen ist bereits erreicht.");
    }else SendClientMessage(playerid,FRACTION_COL_GREY,"Du hast nicht genügend Geld bei dir!");
    break;
    }
    }
    }else SendClientMessage(playerid,FRACTION_COL_GREY,"Deine Fraktion hat das Limit von Fahrzeugen bereits erreicht.");
    }else SendClientMessage(playerid,FRACTION_COL_GREY,"Du bist nicht brechtigt Fraktionsfahrzeuge zu kaufen!");
    new Float:pPos[3];
    GetPlayerPos(playerid,pPos[0],pPos[1],pPos[2]);
    SetPlayerPos(playerid,pPos[0]+2.5,pPos[1]+2.5,pPos[2]);
    TogglePlayerControllable(playerid,true);
    }
    }return 1;
    }return 0;
    }
    stock fLockCar(vehicleid){//zeile 45701
    ForAllPlayers(i)
    SetVehicleParamsForPlayer(vehicleid,i,false,true);
    return true;
    }
    stock fUnlockCar(vehicleid){//zeile 45706
    ForAllPlayers(i)
    SetVehicleParamsForPlayer(vehicleid,i,false,false);
    return true;
    }

    hier ist der enum
    enum fCar{
    fCarid,
    fVehid,
    Float:fPos[4],
    fCol[2],
    fFraction[5],
    fTuning[14],
    fPrice,
    #if defined FRACTION_CARS_LOCKABLE
    bool:fLock
    fLock = true;
    fLock = false
    #endif
    };


    und ich denke das ist möglich da man das Fahrzeug ja ab/aufschließen kann

    Hallo, versuche schon seit ner halben std den fehler zu beheben


    Warnings
    C:\Users\Test\Desktop\Neuer Ordner\GDR.pwn(16124) : warning 213: tag mismatch
    C:\Users\Test\Desktop\Neuer Ordner\GDR.pwn(16143) : warning 213: tag mismatch
    C:\Users\Test\Desktop\Neuer Ordner\GDR.pwn(16145) : warning 213: tag mismatch
    C:\Users\Test\Desktop\Neuer Ordner\GDR.pwn(16150) : warning 213: tag mismatch
    C:\Users\Test\Desktop\Neuer Ordner\GDR.pwn(16152) : warning 213: tag mismatch
    C:\Users\Test\Desktop\Neuer Ordner\GDR.pwn(42071) : warning 213: tag mismatch
    Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase



    6 Warnings.


    if(strcmp(cmdtext,"/delfcar",true)==0){
    if(PlayerAdministrator(playerid) >= Fraction_Need_Adminlevel){
    new fc; while(fc<MAX_FRACTION_CARS){
    if(FractionCars[fc][fVehid] >= 400 && FractionCars[fc][fVehid] <= 611){
    new Float:fX,Float:fY,Float:fZ;
    GetVehiclePos(FractionCars[fc][fCarid],fX,fY,fZ);
    if(IsPlayerInRangeOfPoint(playerid,5.0,fX,fY,fZ)){
    FractionCars[fc][fVehid]=-255;
    if(fUnlockCar(FractionCars[fc][fCarid]))
    FractionCars[fc][fLock] = false;//zeile 16124
    if(DestroyVehicle(FractionCars[fc][fCarid]))
    FractionCars[fc][fCarid] = -255;
    new Text[256];
    format(Text,sizeof(Text),">> Du hast das Fraktionsfahrzeug der Fraktion '%d' entfernt.",FractionCars[fc][fFraction][0]);
    return SendClientMessage(playerid,fColYellow,Text);
    }
    }fc++;
    }return SendClientMessage(playerid,fColGrey,"Du bist nicht in der Nähe eines Fraktionsfahrzeuges.");
    }return SendClientMessage(playerid,fColGrey,"Du bist nicht berechtigt diesen Befehl auszuführen.");
    }
    if(strcmp(cmdtext,"/flock",true)==0){
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER){
    new Carid=GetPlayerVehicleID(playerid);
    new fc;while(fc<MAX_FRACTION_CARS){
    if(FractionCars[fc][fVehid] >= 400 && FractionCars[fc][fVehid] <= 611){
    if(FractionCars[fc][fCarid] == Carid){
    for(new f;f<5;f++){
    if(PlayerFraction(playerid) == FractionCars[fc][fFraction][f]){
    if(FractionCars[fc][fLock])//zeile 16143
    {
    FractionCars[fc][fLock]=false;//zeile 16145
    fUnlockCar(FractionCars[fc][fCarid]);
    GameTextForPlayer(playerid,"~w~Fahrzeug~n~~g~Aufgeschlossen",5000,3);
    return true;
    }
    if(!FractionCars[fc][fLock]){//zeile 16150
    fLockCar(FractionCars[fc][fCarid]);
    FractionCars[fc][fLock]=true;//zeile 16152
    GameTextForPlayer(playerid,"~w~Fahrzeug~n~~r~Abgeschlossen",5000,3);
    return true;
    }
    }
    }
    }
    }fc++;
    }
    }else{
    if(GetPlayerState(playerid)==PLAYER_STATE_PASSENGER)
    return SendClientMessage(playerid,fColGrey,"Du musst der Fahrer dieses Fahrzeuges sein.");
    return SendClientMessage(playerid,fColGrey,"Du muss in einem Fahrzeug sitzen.");
    }return SendClientMessage(playerid,fColGrey,"Du sitzt in keinem Fraktionsfahrzeug!");
    }


    FractionCars[fc][fCarid] = CreateVehicle(FractionCars[fc][fVehid],FractionCars[fc][fPos][0],FractionCars[fc][fPos][1],FractionCars[fc][fPos][2],FractionCars[fc][fPos][3],FractionCars[fc][fCol][0],FractionCars[fc][fCol][1],-255);
    FractionCars[fc][fLock] = true;//Zeile 42071
    SendClientMessage(playerid,fColYellow,">>> Du hast das Fraktionsfahrzeug erfolgreich erstellt.");
    SendClientMessage(playerid,fColYellow,">>> Vergesse es nicht mit '/fpark' zu umzuparken.");


    währe für Hilfe sehr dankbar


    MFG
    BlaZZeR

    habs schon :)


    ich meinte das z.b. so
    if(strcmp(cmd, "/vehmotor",true) == 0)
    {
    if(IsPlayerInAnyVehicle(playerid))
    {
    if(GetPlayerState(playerid) == 2)
    {
    new vid = GetPlayerVehicleID(playerid);
    GetVehicleParamsEx(vid,engine,lights,alarm,doors,bonnet,boot,objective);
    if(engine == VEHICLE_PARAMS_OFF || engine == VEHICLE_PARAMS_UNSET)
    {
    if(vid != INVALID_VEHICLE_ID)
    {
    SendClientMessage(playerid,COLOR_WHITE,"Motor angeschaltet");
    SetVehicleParamsEx(vid,VEHICLE_PARAMS_ON,lights,alarm,doors,bonnet,boot,objective);
    }
    } else {
    if(vid != INVALID_VEHICLE_ID)
    {
    SendClientMessage(playerid,COLOR_WHITE,"Motor ausgeschaltet");
    SetVehicleParamsEx(vid,VEHICLE_PARAMS_OFF,lights,alarm,doors,bonnet,boot,objective);
    }
    }
    } else {
    SendClientMessage(playerid,COLOR_WHITE,"Du bist nicht der Fahrer");
    }
    }
    return 1;
    }