Beiträge von Eric_HD


    Wenn ich es schaffe Uploade ich es gleich.

    Hey,
    ich hab mal ne Frage.


    Wenn ich mir ein Fahrrad Miete, kann ich dann mit JEDEM anderem Fahrrad Fahren.
    Wie Verhindere ich das? Bitte Helft mir !


    Hier mein Code:


    nbike[0] = CreateVehicle(510,1716.50,-2186.39,13.19,180.00,106,1,-1);
    nbike[1] = CreateVehicle(510,1715.00,-2186.39,13.19,180.00,106,1,-1);
    nbike[2] = CreateVehicle(510,1713.50,-2186.39,13.19,180.00,106,1,-1);
    nbike[3] = CreateVehicle(510,1712.00,-2186.39,13.19,180.00,106,1,-1);
    nbike[4] = CreateVehicle(510,1710.30,-2186.39,13.19,180.00,106,1,-1);
    nbike[5] = CreateVehicle(510,1708.59,-2186.39,13.19,180.00,106,1,-1);
    nbike[6] = CreateVehicle(510,1707.00,-2186.39,13.19,180.00,106,1,-1);
    nbike[7] = CreateVehicle(510,1705.50,-2186.39,13.19,180.00,106,1,-1);
    nbike[8] = CreateVehicle(510,1703.90,-2186.39,13.19,180.00,106,1,-1);
    nbike[9] = CreateVehicle(510,1702.00,-2186.39,13.19,180.00,106,1,-1);
    nbike[10] = CreateVehicle(510,1699.90,-2186.39,13.19,180.00,106,1,-1);
    nbike[11] = CreateVehicle(510,1697.90,-2186.39,13.19,180.00,106,1,-1);
    nbike[12] = CreateVehicle(510,1695.80,-2186.39,13.19,180.00,106,1,-1);
    nbike[13] = CreateVehicle(510,1694.19,-2186.39,13.19,180.00,106,1,-1);
    nbike[14] = CreateVehicle(510,1692.69,-2186.39,13.19,180.00,106,1,-1);


    public OnPlayerStateChange(playerid, newstate, oldstate){
    if(newstate==PLAYER_STATE_DRIVER){
    for(new i=0; i<sizeof(nbike); i++){
    if(GetPlayerVehicleID(playerid)==nbike[i]){
    if(GetPVarInt(playerid,"nBike")==1){return SendClientMessage(playerid,Grün,"");}
    else{
    if(SpielerInfo[playerid][Level] <3){
    ShowPlayerDialog(playerid,DIALOG_NBIKE,DIALOG_STYLE_MSGBOX,"Fahrrad Verleih","Möchtest du dir das Fahrrad für $5 mieten?","Ja","Nein");
    return 1;
    }
    else{return RemovePlayerFromVehicle(playerid);}
    }
    }
    }
    }


    if(dialogid==DIALOG_NBIKE){
    if(response == 0){
    SendClientMessage(playerid,Weiß,"Vielen Dank für ihr Interesse.");
    RemovePlayerFromVehicle(playerid);
    return 1;
    }
    if(response == 1){
    GivePlayerMoney(playerid,-5);
    SendClientMessage(playerid,Grün,"Wir wünschen dir Viel Spaß mit deinem Fahrrad.");
    SetPVarInt(playerid,"nBike",1);
    TogglePlayerControllable(playerid,1);
    return 1;
    }
    }