Beiträge von [ATC]eRaZoR

    beispiel:


    new IstFraktion[MAX_PLAYERS];



    //dann deine fraktionen
    if(deine definition)
    {
    //dein fraktions zeug
    IstFraktion[playerid] = 1;
    return 1;
    }



    //dann dein payday
    if(IstFraktion)
    {
    //dein payday zeug
    return 1;
    }
    //dein payday zeug für user die in keiner fraktion sind

    new IstFraktion[MAX_PALYERS]


    //unter den fraktionen


    IstFraktion[playerid] = 1;


    // dann bei deinem payday


    if(IstFraktion)
    {
    dein payday
    return 1;
    }


    //und dann das payday für die normalen einfach unter die if abfrage ;)

    hm.. ich sehe keinen fehler..
    das einzigste was du mal probieren könntest währe das hier:


    case 0:
    {
    SendClientMessage(playerid, FARBE, "Kannst du das lesen? Wechselt der Skin??");
    SetPlayerSkin(playerid, 282);
    Team[playerid] = Job_Cop;
    return 1;
    }
    case 1:
    {
    SendClientMessage(playerid, FARBE, "Kannst du das lesen? Wechselt der Skin??");
    SetPlayerSkin(playerid, 125);
    Team[playerid] = Job_Hitman;
    return 1;
    }


    wenn du die nachricht nciht siehst und der skin wechselt dann klappts ^^

    ich denke nicht..
    ich denke das es so sein muss



    public OnGameModeInit()
    {
    StreamObject_OnGameModeInit();
    CreateObjectToStream(8659, 1822.597168, -1094.967163, 24.078125, 0.0000, 0.0000, 0.0000);
    CreateObjectToStream(8659, 1822.651001, -1094.978516, 25.960835, 0.8596, 0.0000, 0.0000);
    CreateObjectToStream(8659, 1820.663208, -1094.987549, 27.836596, 0.8596, 0.0000, 0.0000);
    CreateObjectToStream(972, 1803.771484, -1098.337646, 21.425032, 0.0000, 0.0000, 89.2774);
    return 1;
    }


    so würde ich denken das es richtig ist

    public OnPlayerSelectedMenuRow(playerid, row)
    {
    new Menu:CurrentMenu = GetPlayerMenu(playerid);
    if(CurrentMenu == OttoMenu)
    {
    switch(row)
    {
    case 0: //Bullet
    {
    if (IsPlayerConnected(playerid))
    {
    if (GetPlayerMoney(playerid) >= 65000)
    {
    new c[20];
    vehicleid10 = CreateVehicle(541,-2218.0332,2426.9214,1.7144,135.2682,-1,-1,-1);
    for(new i=0; i<1000; i++)
    {
    format(c,sizeof(c),"cars/%d.ini",i);
    if(!dini_Exists(c))
    {
    dini_Create(c);
    dini_IntSet(c,"id",id);
    dini_FloatSet(c,"x",-2218.0332);
    dini_FloatSet(c,"y",2426.9214);
    dini_FloatSet(c,"z",1.7144);
    dini_FloatSet(c,"angel",135.2682);
    dini_FloatSet(c,"health",1000.0000);
    dini_IntSet(c,"cid",-1);
    dini_IntSet(c,"cid2",-1);
    dini_Set(c,"besitzer",name);
    dini_IntSet(c,name,2);
    dini_IntSet(c,"benzin",maxbenzin[id]-(maxbenzin[id]/5));
    dini_Set(c, "plate", "OttoCars");
    SetVehicleNumberPlate(vehicleid10, "OttoCars");
    format(string,sizeof(string),"Vehicle (ID: %d) Gekauft",id);
    SendClientMessage(playerid,green,string);
    format(vehicle[vehicleid10],20,"%s",c);
    GivePlayerMoney(playerid, -65000);
    SendClientMessage(playerid, INFORMATION, "Du hast ein Auto gekauft! Hole es ab!");
    }
    }
    }
    }
    }
    else
    {
    SendClientMessage(playerid, ERROR, "Du hast nicht genügend Geld!");
    }
    case 1: //Banshee
    {
    if (IsPlayerConnected(playerid))
    {
    if (GetPlayerMoney(playerid) >= 80000)
    {
    new c[20];
    vehicleid10 = CreateVehicle(429,-2218.0332,2426.9214,1.7144,135.2682,-1,-1,-1);
    for(new i=0; i<1000; i++){
    format(c,sizeof(c),"cars/%d.ini",i);
    if(!dini_Exists(c))
    {
    dini_Create(c);
    dini_IntSet(c,"id",id);
    dini_FloatSet(c,"x",-2218.0332);
    dini_FloatSet(c,"y",2426.9214);
    dini_FloatSet(c,"z",1.7144);
    dini_FloatSet(c,"angel",135.2682);
    dini_FloatSet(c,"health",1000.0000);
    dini_IntSet(c,"cid",-1);
    dini_IntSet(c,"cid2",-1);
    dini_Set(c,"besitzer",name);
    dini_IntSet(c,name,2);
    dini_IntSet(c,"benzin",maxbenzin[id]-(maxbenzin[id]/5));
    dini_Set(c, "plate", "OttoCars");
    SetVehicleNumberPlate(vehicleid10, "OttoCars");
    format(string,sizeof(string),"Vehicle (ID: %d) Gekauft",id);
    SendClientMessage(playerid,green,string);
    format(vehicle[vehicleid10],20,"%s",c);
    GivePlayerMoney(playerid, -80000);
    SendClientMessage(playerid, INFORMATION, "Du hast ein Auto gekauft! Hole es ab!");
    }
    }
    }
    }
    else
    {
    SendClientMessage(playerid, ERROR, "Du hast nicht genügend Geld!");
    }
    case 2: //Infernur
    {
    if (IsPlayerConnected(playerid))
    {
    if (GetPlayerMoney(playerid) >= 115000)
    {
    new c[20];
    vehicleid10 = CreateVehicle(411,-2218.0332,2426.9214,1.7144,135.2682,-1,-1,-1);
    for(new i=0; i<1000; i++)
    {
    format(c,sizeof(c),"cars/%d.ini",i);
    if(!dini_Exists(c))
    {
    dini_Create(c);
    dini_IntSet(c,"id",id);
    dini_FloatSet(c,"x",-2218.0332);
    dini_FloatSet(c,"y",2426.9214);
    dini_FloatSet(c,"z",1.7144);
    dini_FloatSet(c,"angel",135.2682);
    dini_FloatSet(c,"health",1000.0000);
    dini_IntSet(c,"cid",-1);
    dini_IntSet(c,"cid2",-1);
    dini_Set(c,"besitzer",name);
    dini_IntSet(c,name,2);
    dini_IntSet(c,"benzin",maxbenzin[id]-(maxbenzin[id]/5));
    dini_Set(c, "plate", "OttoCars");
    SetVehicleNumberPlate(vehicleid10, "OttoCars");
    format(string,sizeof(string),"Vehicle (ID: %d) Gekauft",id);
    SendClientMessage(playerid,green,string);
    format(vehicle[vehicleid10],20,"%s",c);
    GivePlayerMoney(playerid, -115000);
    SendClientMessage(playerid, INFORMATION, "Du hast ein Auto gekauft! Hole es ab!");
    }
    }
    }
    }
    }
    else
    {
    SendClientMessage(playerid, ERROR, "Du hast nicht genügend Geld!");
    }
    case 3: //Cheetah
    {
    if (IsPlayerConnected(playerid))
    {
    if (GetPlayerMoney(playerid) >= 135000)
    {
    new c[20];
    vehicleid10 = CreateVehicle(415,-2218.0332,2426.9214,1.7144,135.2682,-1,-1,-1);
    for(new i=0; i<1000; i++)
    {
    format(c,sizeof(c),"cars/%d.ini",i);
    if(!dini_Exists(c))
    {
    dini_Create(c);
    dini_IntSet(c,"id",id);
    dini_FloatSet(c,"x",-2218.0332);
    dini_FloatSet(c,"y",2426.9214);
    dini_FloatSet(c,"z",1.7144);
    dini_FloatSet(c,"angel",135.2682);
    dini_FloatSet(c,"health",1000.0000);
    dini_IntSet(c,"cid",-1);
    dini_IntSet(c,"cid2",-1);
    dini_Set(c,"besitzer",name);
    dini_IntSet(c,name,2);
    dini_IntSet(c,"benzin",maxbenzin[id]-(maxbenzin[id]/5));
    dini_Set(c, "plate", "OttoCars");
    SetVehicleNumberPlate(vehicleid10, "OttoCars");
    format(string,sizeof(string),"Vehicle (ID: %d) Gekauft",id);
    SendClientMessage(playerid,green,string);
    format(vehicle[vehicleid10],20,"%s",c);
    GivePlayerMoney(playerid, -135000);
    SendClientMessage(playerid, INFORMATION, "Du hast ein Auto gekauft! Hole es ab!");
    }
    }
    }
    }
    }
    else
    {
    SendClientMessage(playerid, ERROR, "Du hast nicht genügend Geld!");
    }
    case 4: //Turismo
    {
    if (IsPlayerConnected(playerid))
    {
    if (GetPlayerMoney(playerid) >= 140000)
    {
    new c[20];
    vehicleid10 = CreateVehicle(451,-2218.0332,2426.9214,1.7144,135.2682,-1,-1,-1);
    for(new i=0; i<1000; i++)
    {
    format(c,sizeof(c),"cars/%d.ini",i);
    if(!dini_Exists(c))
    {
    dini_Create(c);
    dini_IntSet(c,"id",id);
    dini_FloatSet(c,"x",-2218.0332);
    dini_FloatSet(c,"y",2426.9214);
    dini_FloatSet(c,"z",1.7144);
    dini_FloatSet(c,"angel",135.2682);
    dini_FloatSet(c,"health",1000.0000);
    dini_IntSet(c,"cid",-1);
    dini_IntSet(c,"cid2",-1);
    dini_Set(c,"besitzer",name);
    dini_IntSet(c,name,2);
    dini_IntSet(c,"benzin",maxbenzin[id]-(maxbenzin[id]/5));
    dini_Set(c, "plate", "OttoCars");
    SetVehicleNumberPlate(vehicleid10, "OttoCars");
    format(string,sizeof(string),"Vehicle (ID: %d) Gekauft",id);
    SendClientMessage(playerid,green,string);
    format(vehicle[vehicleid10],20,"%s",c);
    GivePlayerMoney(playerid, -140000);
    SendClientMessage(playerid, INFORMATION, "Du hast ein Auto gekauft! Hole es ab!");
    }
    }
    }
    }
    }
    else
    {
    SendClientMessage(playerid, ERROR, "Du hast nicht genügend Geld!");
    }
    case 5: //Super GT
    {
    if (IsPlayerConnected(playerid))
    {
    if (GetPlayerMoney(playerid) >= 150000)
    {
    new c[20];
    vehicleid10 = CreateVehicle(506,-2218.0332,2426.9214,1.7144,135.2682,-1,-1,-1);
    for(new i=0; i<1000; i++)
    {
    format(c,sizeof(c),"cars/%d.ini",i);
    if(!dini_Exists(c))
    {
    dini_Create(c);
    dini_IntSet(c,"id",id);
    dini_FloatSet(c,"x",-2218.0332);
    dini_FloatSet(c,"y",2426.9214);
    dini_FloatSet(c,"z",1.7144);
    dini_FloatSet(c,"angel",135.2682);
    dini_FloatSet(c,"health",1000.0000);
    dini_IntSet(c,"cid",-1);
    dini_IntSet(c,"cid2",-1);
    dini_Set(c,"besitzer",name);
    dini_IntSet(c,name,2);
    dini_IntSet(c,"benzin",maxbenzin[id]-(maxbenzin[id]/5));
    dini_Set(c, "plate", "OttoCars");
    SetVehicleNumberPlate(vehicleid10, "OttoCars");
    format(string,sizeof(string),"Vehicle (ID: %d) Gekauft",id);
    SendClientMessage(playerid,green,string);
    format(vehicle[vehicleid10],20,"%s",c);
    GivePlayerMoney(playerid, -150000);
    SendClientMessage(playerid, INFORMATION, "Du hast ein Auto gekauft! Hole es ab!");
    }
    }
    }
    }
    }
    else
    {
    SendClientMessage(playerid, ERROR, "Du hast nicht genügend Geld!");
    }
    }
    }
    return 1;
    }


    habe nochmal nach dem von eben geguckt, kannst das ja mal versuchen..

    public OnPlayerSelectedMenuRow(playerid, row)
    {
    new Menu:CurrentMenu = GetPlayerMenu(playerid);
    if(CurrentMenu == OttoMenu)
    {
    switch(row)
    {
    case 0: //Bullet
    if (IsPlayerConnected(playerid))
    {
    if (GetPlayerMoney(playerid) >= 65000)
    {
    new c[20];
    new name[20];
    new id;
    new string[60];
    vehicleid10 = CreateVehicle(541,-2218.0332,2426.9214,1.7144,135.2682,-1,-1,-1);
    for(new i=0; i<1000; i++)
    {
    format(c,sizeof(c),"cars/%d.ini",i);
    if(!dini_Exists(c))
    {
    dini_Create(c);
    dini_FloatSet(c,"x",-2218.0332);
    dini_FloatSet(c,"y",2426.9214);
    dini_FloatSet(c,"z",1.7144);
    dini_FloatSet(c,"angel",135.2682);
    dini_FloatSet(c,"health",1000.0000);
    dini_IntSet(c,"cid",-1);
    dini_IntSet(c,"cid2",-1);
    dini_Set(c,"besitzer",name);
    dini_IntSet(c,name,2);
    dini_IntSet(c,"benzin",maxbenzin[id]-(maxbenzin[id]/5));
    dini_Set(c, "plate", "OttoCars");
    SetVehicleNumberPlate(vehicleid10, "OttoCars");
    format(string,sizeof(string),"Vehicle (ID: %d) Gekauft",id);
    SendClientMessage(playerid,green,string);
    format(vehicle[vehicleid10],20,"%s",c);
    GivePlayerMoney(playerid, -65000);
    SendClientMessage(playerid, INFORMATION, "Du hast ein Auto gekauft! Hole es ab!");
    }
    }
    else
    {
    SendClientMessage(playerid, ERROR, "Du hast nicht genügend Geld!");
    }
    case 1: //Banshee
    {
    if (IsPlayerConnected(playerid))
    {
    if (GetPlayerMoney(playerid) >= 80000)
    {
    new c[20];
    vehicleid10 = CreateVehicle(429,-2218.0332,2426.9214,1.7144,135.2682,-1,-1,-1);
    for(new i=0; i<1000; i++){
    format(c,sizeof(c),"cars/%d.ini",i);
    if(!dini_Exists(c))
    {
    dini_Create(c);
    dini_FloatSet(c,"x",-2218.0332);
    dini_FloatSet(c,"y",2426.9214);
    dini_FloatSet(c,"z",1.7144);
    dini_FloatSet(c,"angel",135.2682);
    dini_FloatSet(c,"health",1000.0000);
    dini_IntSet(c,"cid",-1);
    dini_IntSet(c,"cid2",-1);
    dini_Set(c,"besitzer",name);
    dini_IntSet(c,name,2);
    dini_IntSet(c,"benzin",maxbenzin[id]-(maxbenzin[id]/5));
    dini_Set(c, "plate", "OttoCars");
    SetVehicleNumberPlate(vehicleid10, "OttoCars");
    format(string,sizeof(string),"Vehicle (ID: %d) Gekauft",id);
    SendClientMessage(playerid,green,string);
    format(vehicle[vehicleid10],20,"%s",c);
    GivePlayerMoney(playerid, -80000);
    SendClientMessage(playerid, INFORMATION, "Du hast ein Auto gekauft! Hole es ab!");
    }
    }
    }
    }
    else
    {
    SendClientMessage(playerid, ERROR, "Du hast nicht genügend Geld!");
    }
    case 2: //Infernur
    {
    if (IsPlayerConnected(playerid))
    {
    if (GetPlayerMoney(playerid) >= 115000)
    {
    new c[20];
    vehicleid10 = CreateVehicle(411,-2218.0332,2426.9214,1.7144,135.2682,-1,-1,-1);
    for(new i=0; i<1000; i++)
    {
    format(c,sizeof(c),"cars/%d.ini",i);
    if(!dini_Exists(c))
    {
    dini_Create(c);
    dini_FloatSet(c,"x",-2218.0332);
    dini_FloatSet(c,"y",2426.9214);
    dini_FloatSet(c,"z",1.7144);
    dini_FloatSet(c,"angel",135.2682);
    dini_FloatSet(c,"health",1000.0000);
    dini_IntSet(c,"cid",-1);
    dini_IntSet(c,"cid2",-1);
    dini_Set(c,"besitzer",name);
    dini_IntSet(c,name,2);
    dini_IntSet(c,"benzin",maxbenzin[id]-(maxbenzin[id]/5));
    dini_Set(c, "plate", "OttoCars");
    SetVehicleNumberPlate(vehicleid10, "OttoCars");
    format(string,sizeof(string),"Vehicle (ID: %d) Gekauft",id);
    SendClientMessage(playerid,green,string);
    format(vehicle[vehicleid10],20,"%s",c);
    GivePlayerMoney(playerid, -115000);
    SendClientMessage(playerid, INFORMATION, "Du hast ein Auto gekauft! Hole es ab!");
    }
    }
    }
    }
    }
    }
    else
    {
    SendClientMessage(playerid, ERROR, "Du hast nicht genügend Geld!");
    }
    case 3: //Cheetah
    {
    if (IsPlayerConnected(playerid))
    {
    if (GetPlayerMoney(playerid) >= 135000)
    {
    new c[20];
    vehicleid10 = CreateVehicle(415,-2218.0332,2426.9214,1.7144,135.2682,-1,-1,-1);
    for(new i=0; i<1000; i++)
    {
    format(c,sizeof(c),"cars/%d.ini",i);
    if(!dini_Exists(c))
    {
    dini_Create(c);
    dini_FloatSet(c,"x",-2218.0332);
    dini_FloatSet(c,"y",2426.9214);
    dini_FloatSet(c,"z",1.7144);
    dini_FloatSet(c,"angel",135.2682);
    dini_FloatSet(c,"health",1000.0000);
    dini_IntSet(c,"cid",-1);
    dini_IntSet(c,"cid2",-1);
    dini_Set(c,"besitzer",name);
    dini_IntSet(c,name,2);
    dini_IntSet(c,"benzin",maxbenzin[id]-(maxbenzin[id]/5));
    dini_Set(c, "plate", "OttoCars");
    SetVehicleNumberPlate(vehicleid10, "OttoCars");
    format(string,sizeof(string),"Vehicle (ID: %d) Gekauft",id);
    SendClientMessage(playerid,green,string);
    format(vehicle[vehicleid10],20,"%s",c);
    GivePlayerMoney(playerid, -135000);
    SendClientMessage(playerid, INFORMATION, "Du hast ein Auto gekauft! Hole es ab!");
    }
    }
    }
    }
    }
    }
    else
    {
    SendClientMessage(playerid, ERROR, "Du hast nicht genügend Geld!");
    }
    case 4: //Turismo
    {
    if (IsPlayerConnected(playerid))
    {
    if (GetPlayerMoney(playerid) >= 140000)
    {
    new c[20];
    vehicleid10 = CreateVehicle(451,-2218.0332,2426.9214,1.7144,135.2682,-1,-1,-1);
    for(new i=0; i<1000; i++)
    {
    format(c,sizeof(c),"cars/%d.ini",i);
    if(!dini_Exists(c))
    {
    dini_Create(c);
    dini_FloatSet(c,"x",-2218.0332);
    dini_FloatSet(c,"y",2426.9214);
    dini_FloatSet(c,"z",1.7144);
    dini_FloatSet(c,"angel",135.2682);
    dini_FloatSet(c,"health",1000.0000);
    dini_IntSet(c,"cid",-1);
    dini_IntSet(c,"cid2",-1);
    dini_Set(c,"besitzer",name);
    dini_IntSet(c,name,2);
    dini_IntSet(c,"benzin",maxbenzin[id]-(maxbenzin[id]/5));
    dini_Set(c, "plate", "OttoCars");
    SetVehicleNumberPlate(vehicleid10, "OttoCars");
    format(string,sizeof(string),"Vehicle (ID: %d) Gekauft",id);
    SendClientMessage(playerid,green,string);
    format(vehicle[vehicleid10],20,"%s",c);
    GivePlayerMoney(playerid, -140000);
    SendClientMessage(playerid, INFORMATION, "Du hast ein Auto gekauft! Hole es ab!");
    }
    }
    }
    }
    }
    }
    else
    {
    SendClientMessage(playerid, ERROR, "Du hast nicht genügend Geld!");
    }
    case 5: //Super GT
    {
    if (IsPlayerConnected(playerid))
    {
    if (GetPlayerMoney(playerid) >= 150000)
    {
    new c[20];
    vehicleid10 = CreateVehicle(506,-2218.0332,2426.9214,1.7144,135.2682,-1,-1,-1);
    for(new i=0; i<1000; i++)
    {
    format(c,sizeof(c),"cars/%d.ini",i);
    if(!dini_Exists(c))
    {
    dini_Create(c);
    dini_FloatSet(c,"x",-2218.0332);
    dini_FloatSet(c,"y",2426.9214);
    dini_FloatSet(c,"z",1.7144);
    dini_FloatSet(c,"angel",135.2682);
    dini_FloatSet(c,"health",1000.0000);
    dini_IntSet(c,"cid",-1);
    dini_IntSet(c,"cid2",-1);
    dini_Set(c,"besitzer",name);
    dini_IntSet(c,name,2);
    dini_IntSet(c,"benzin",maxbenzin[id]-(maxbenzin[id]/5));
    dini_Set(c, "plate", "OttoCars");
    SetVehicleNumberPlate(vehicleid10, "OttoCars");
    format(string,sizeof(string),"Vehicle (ID: %d) Gekauft",id);
    SendClientMessage(playerid,green,string);
    format(vehicle[vehicleid10],20,"%s",c);
    GivePlayerMoney(playerid, -150000);
    SendClientMessage(playerid, INFORMATION, "Du hast ein Auto gekauft! Hole es ab!");
    }
    }
    }
    }
    }
    }
    else
    {
    SendClientMessage(playerid, ERROR, "Du hast nicht genügend Geld!");
    }
    }
    return 1;
    }


    versuchs mal so...

    such mal im forum mit den stunt parks und alles..


    die sachen um sich dahin zu porten sind ganz einfach..


    if(strcmp("/ls-stunt",cmdtext,true, 10) ==0) // das /ls-stunt kannst du auch ändern
    {
    SetPlayerPos(Float:X, Float:Y,Float:Z); // im spiel /save machen und im ordner "Savepositions" gucken und die X,Y,Z koordinaten kopieren
    SendClientMessage(playerid, FARBE, "Willkommen im LS Stuntpark. Nalos, zeig was du kannst ;)"); // text kannst du nachtürlich auch ändern
    return 1;
    }


    fertig.. ;)