Alle Spieler die connecten in VERSCHIEDENE zugewiesene Autos teleportieren

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
  • Habe da mal eine Frage,


    Wie soll man es schaffen das jede PlayerID ein Fahrzeug bekommt?


    Habe es so gemacht jedoch streitet sich dann jeder um ein Auto und es buggt rum bzw. wen man austeigt hat jemand anderes das Fahrzeug.



    switch(random(27))
    {
    case 0: PutPlayerInVehicle(playerid,Bot1, 0);
    case 1: PutPlayerInVehicle(playerid,Bot2, 0);
    case 2: PutPlayerInVehicle(playerid,Bot3, 0);
    case 3: PutPlayerInVehicle(playerid,Bot4, 0);
    case 4: PutPlayerInVehicle(playerid,Bot5, 0);
    case 5: PutPlayerInVehicle(playerid,Bot6, 0);
    case 6: PutPlayerInVehicle(playerid,Bot7, 0);
    case 7: PutPlayerInVehicle(playerid,Bot8, 0);
    case 8: PutPlayerInVehicle(playerid,Bot9, 0);
    case 9: PutPlayerInVehicle(playerid,Bot10, 0);
    case 10: PutPlayerInVehicle(playerid,Bot11, 0);
    case 11: PutPlayerInVehicle(playerid,Bot12, 0);
    case 12: PutPlayerInVehicle(playerid,Bot13, 0);
    case 13: PutPlayerInVehicle(playerid,Bot14, 0);
    case 14: PutPlayerInVehicle(playerid,Bot15, 0);
    case 15: PutPlayerInVehicle(playerid,Bot16, 0);
    case 16: PutPlayerInVehicle(playerid,Bot17, 0);
    case 17: PutPlayerInVehicle(playerid,Bot18, 0);
    case 18: PutPlayerInVehicle(playerid,Bot19, 0);
    case 19: PutPlayerInVehicle(playerid,Bot20, 0);
    case 20: PutPlayerInVehicle(playerid,Bot21, 0);
    case 21: PutPlayerInVehicle(playerid,Bot22, 0);
    case 22: PutPlayerInVehicle(playerid,Bot23, 0);
    case 23: PutPlayerInVehicle(playerid,Bot24, 0);
    case 24: PutPlayerInVehicle(playerid,Bot25, 0);
    case 25: PutPlayerInVehicle(playerid,Bot26, 0);
    case 26: PutPlayerInVehicle(playerid,Bot27, 0);


    Will das jede Playerid ein eigenes Fahrzeug bekommt , danke.

  • Moinseeeeeen er meint es soo



    switch(random(27))
    {
    case 0: PutPlayerInVehicle(playerid,Bot1, 0);
    case 1: PutPlayerInVehicle(playerid,Bot2, 0);
    case 2: PutPlayerInVehicle(playerid,Bot3, 0);
    case 3: PutPlayerInVehicle(playerid,Bot4, 0);
    case 4: PutPlayerInVehicle(playerid,Bot5, 0);
    case 5: PutPlayerInVehicle(playerid,Bot6, 0);
    case 6: PutPlayerInVehicle(playerid,Bot7, 0);
    case 7: PutPlayerInVehicle(playerid,Bot8, 0);
    case 8: PutPlayerInVehicle(playerid,Bot9, 0);
    case 9: PutPlayerInVehicle(playerid,Bot10, 0);
    case 10: PutPlayerInVehicle(playerid,Bot11, 0);
    case 11: PutPlayerInVehicle(playerid,Bot12, 0);
    case 12: PutPlayerInVehicle(playerid,Bot13, 0);
    case 13: PutPlayerInVehicle(playerid,Bot14, 0);
    case 14: PutPlayerInVehicle(playerid,Bot15, 0);
    case 15: PutPlayerInVehicle(playerid,Bot16, 0);
    case 16: PutPlayerInVehicle(playerid,Bot17, 0);
    case 17: PutPlayerInVehicle(playerid,Bot18, 0);
    case 18: PutPlayerInVehicle(playerid,Bot19, 0);
    case 19: PutPlayerInVehicle(playerid,Bot20, 0);
    case 20: PutPlayerInVehicle(playerid,Bot21, 0);
    case 21: PutPlayerInVehicle(playerid,Bot22, 0);
    case 22: PutPlayerInVehicle(playerid,Bot23, 0);
    case 23: PutPlayerInVehicle(playerid,Bot24, 0);
    case 24: PutPlayerInVehicle(playerid,Bot25, 0);
    case 25: PutPlayerInVehicle(playerid,Bot26, 0);
    case 26: PutPlayerInVehicle(playerid,Bot27, 0);


    mfg

  • sie meint die pawn funktion hier im forum so sollte es aussehen


    switch(random(27))


    {


    case 0: PutPlayerInVehicle(playerid,Bot1, 0);


    case 1: PutPlayerInVehicle(playerid,Bot2, 0);


    case 2: PutPlayerInVehicle(playerid,Bot3, 0);


    case 3: PutPlayerInVehicle(playerid,Bot4, 0);


    case 4: PutPlayerInVehicle(playerid,Bot5, 0);


    case 5: PutPlayerInVehicle(playerid,Bot6, 0);


    case 6: PutPlayerInVehicle(playerid,Bot7, 0);


    case 7: PutPlayerInVehicle(playerid,Bot8, 0);


    case 8: PutPlayerInVehicle(playerid,Bot9, 0);


    case 9: PutPlayerInVehicle(playerid,Bot10, 0);


    case 10: PutPlayerInVehicle(playerid,Bot11, 0);


    case 11: PutPlayerInVehicle(playerid,Bot12, 0);


    case 12: PutPlayerInVehicle(playerid,Bot13, 0);


    case 13: PutPlayerInVehicle(playerid,Bot14, 0);


    case 14: PutPlayerInVehicle(playerid,Bot15, 0);


    case 15: PutPlayerInVehicle(playerid,Bot16, 0);


    case 16: PutPlayerInVehicle(playerid,Bot17, 0);


    case 17: PutPlayerInVehicle(playerid,Bot18, 0);


    case 18: PutPlayerInVehicle(playerid,Bot19, 0);


    case 19: PutPlayerInVehicle(playerid,Bot20, 0);


    case 20: PutPlayerInVehicle(playerid,Bot21, 0);


    case 21: PutPlayerInVehicle(playerid,Bot22, 0);


    case 22: PutPlayerInVehicle(playerid,Bot23, 0);


    case 23: PutPlayerInVehicle(playerid,Bot24, 0);


    case 24: PutPlayerInVehicle(playerid,Bot25, 0);


    case 25: PutPlayerInVehicle(playerid,Bot26, 0);


    case 26: PutPlayerInVehicle(playerid,Bot27, 0);

  • Schön und gut , kann mir wer aber meine Frage beantworten?


    Wie ich es so reinmachen kann das jede ID ein Fahrzeug bekommt.

  • Marcel was bei mir im Falle aber ganz unpassend ist.
    Da ich bei meinen Gamemode keine Commands brauche.


    Bei start des Gamemodes wird jeder in ein Fahrzeug zugeteilt.