Beiträge von SHORE

    public SetPlayerColor(playerid)
    {
    if (PlayerInfo[playerid][pMember] == 0 || PlayerInfo[playerid][pLeader] == 0) //Zivi
    {
    SetPlayerColor(playerid,COLOR_WHITE);
    }
    if (PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pLeader] == 1)// LS Police spawn
    {
    SetPlayerColor(playerid,NB);
    }
    if (PlayerInfo[playerid][pMember] == 2 || PlayerInfo[playerid][pLeader] == 2) //SF Police spawn
    {
    SetPlayerColor(playerid,NB);
    }
    if (PlayerInfo[playerid][pMember] == 3 || PlayerInfo[playerid][pLeader] == 3)//Army spawn
    {
    SetPlayerColor(playerid,COLOR_GREEN);
    return 1;
    }
    if (PlayerInfo[playerid][pMember] == 4 || PlayerInfo[playerid][pLeader] == 4)//Sanitäter spawn
    {
    SetPlayerColor(playerid,COLOR_RED);
    }
    if (PlayerInfo[playerid][pMember] == 5 || PlayerInfo[playerid][pLeader] == 5)//LaCosaNostra spawn
    {
    SetPlayerColor(playerid,COLOR_ORANGE);
    }
    if (PlayerInfo[playerid][pLeader] == 6 || PlayerInfo[playerid][pMember] == 6)//Yakuza spawn
    {
    SetPlayerColor(playerid,COLOR_PURPLE);
    }
    if(PlayerInfo[playerid][pLeader] == 7)//Präsident spawn
    {
    SetPlayerColor(playerid,COLOR_BLACK);
    }
    if(PlayerInfo[playerid][pMember] == 7)//Bodyguard spawn
    {
    SetPlayerColor(playerid,COLOR_BLACK);
    }
    if (PlayerInfo[playerid][pMember] == 8 || PlayerInfo[playerid][pLeader] == 8) //Hitman spawn
    {
    SetPlayerColor(playerid,COLOR_DARKRED);
    }
    if (PlayerInfo[playerid][pMember] == 9 || PlayerInfo[playerid][pLeader] == 9) //News spawn
    {
    SetPlayerColor(playerid,COLOR_LIME);
    }
    if (PlayerInfo[playerid][pMember] == 10 || PlayerInfo[playerid][pLeader] == 10) //Taxi spawn
    {
    SetPlayerColor(playerid,COLOR_YELLOW);
    }
    if (PlayerInfo[playerid][pMember] == 12 || PlayerInfo[playerid][pLeader] == 12) //LS.Bikers Spawn
    {
    SetPlayerColor(playerid,COLOR_GREY);
    }
    if (PlayerInfo[playerid][pMember] == 13 || PlayerInfo[playerid][pLeader] == 13) //GROOVE STREET FAMILIY
    {
    SetPlayerColor(playerid,COLOR_LIGHTGREEN);
    }
    if (PlayerInfo[playerid][pMember] == 14 || PlayerInfo[playerid][pLeader] == 14) //BALLAS GANG
    {
    SetPlayerColor(playerid,COLOR_PURPLE);
    }
    if (PlayerInfo[playerid][pMember] == 15 || PlayerInfo[playerid][pLeader] == 15) //Fast and Furious
    {
    SetPlayerColor(playerid,COLOR_LIGHTRED);
    }
    if (PlayerInfo[playerid][pMember] == 16 || PlayerInfo[playerid][pLeader] == 16) //Los Santos Vagos
    {
    SetPlayerColor(playerid,COLOR_YELLOW);
    }
    if (PlayerInfo[playerid][pMember] == 17 || PlayerInfo[playerid][pLeader] == 17) //Varios Los Aztecas
    {
    SetPlayerColor(playerid,COLOR_YELLOW);
    }
    if (PlayerInfo[playerid][pMember] == 18 || PlayerInfo[playerid][pLeader] == 18) //San Fierro Rifa
    {
    SetPlayerColor(playerid,COLOR_GREENYELLOW);
    }
    if (PlayerInfo[playerid][pMember] == 19 || PlayerInfo[playerid][pLeader] == 19) //W C Customs
    {
    SetPlayerColor(playerid,COLOR_LIGHTRED);
    }
    if (PlayerInfo[playerid][pMember] == 20 || PlayerInfo[playerid][pLeader] == 20) //Terroristen
    {
    SetPlayerColor(playerid,COLOR_YELLOW);
    }
    if (PlayerInfo[playerid][pMember] == 21) //FBI Agenten spawn
    {
    SetPlayerColor(playerid,STEALTH_BLUE);
    }
    if (PlayerInfo[playerid][pLeader] == 21) //FBI Leader spawn
    {
    SetPlayerColor(playerid,STEALTH_BLUE);
    }
    if (PlayerInfo[playerid][pMember] == 22 || PlayerInfo[playerid][pLeader] == 22) //Feuerwehr spawn
    {
    SetPlayerColor(playerid,COLOR_LIGHTRED);
    }
    if (PlayerInfo[playerid][pMember] == 23 || PlayerInfo[playerid][pLeader] == 23) //Russenmafia spawn
    {
    SetPlayerColor(playerid,COLOR_GREY);
    }
    if (PlayerInfo[playerid][pMember] == 24 || PlayerInfo[playerid][pLeader] == 24) //Oamt spawn
    {
    SetPlayerColor(playerid,COLOR_LIGHTBLUE);
    }
    if (PlayerInfo[playerid][pMember] == 25 || PlayerInfo[playerid][pLeader] == 25) //S.W.A.T. spawn
    {
    SetPlayerColor(playerid,NB);
    }
    }




    Wenn der Spieler Spawnt setzt du das
    SetPlayerColor(playerid);

    public OnPlayerRequestClass(playerid, classid)
    {
    PlayerPlaySound(playerid, 1183, 0.0, 0.0, 10.0);
    gPlayerClass[playerid] = classid;
    switch (classid)
    }
    case 0,1,2:
    {
    SetPlayerColor(playerid,0x8EEE7DFF);
    SetPlayerVirtualWorld(playerid,1);
    SetPlayerInterior(playerid,0);
    SetPlayerPos(playerid, 2239.9063,-1641.9432,15.5267);
    SetPlayerFacingAngle(playerid, 151.7758);
    SetPlayerCameraPos(playerid, 2237.3972,-1646.6178,16.3376);
    SetPlayerCameraLookAt(playerid, 2239.9063,-1641.9432,15.5267);
    GameTextForPlayer(playerid, "~g~~h~Grove", 500, 3);
    ApplyAnimation(playerid,"DANCING","dance_loop",4.1,1,1,1,0,0,1);
    gTeam[playerid] = TEAM_GROVE;
    }
    case 3,4,5:
    {
    SetPlayerColor(playerid,0xBC1BE4FF);
    SetPlayerVirtualWorld(playerid,1);
    SetPlayerInterior(playerid,0);
    SetPlayerPos(playerid, 2444.6553,-1364.2625,24.0000);
    SetPlayerFacingAngle(playerid,237.9365);
    SetPlayerCameraPos(playerid, 2449.0635,-1367.0236,24.5825);
    SetPlayerCameraLookAt(playerid, 2444.6553,-1364.2625,24.0000);
    GameTextForPlayer(playerid, "~p~Ballas", 500, 3);
    ApplyAnimation(playerid,"DANCING","dance_loop",4.1,1,1,1,0,0,1);
    gTeam[playerid] = TEAM_BALLAS;
    }
    case 6,7,8:
    {
    SetPlayerColor(playerid,0x23BCDCFF);
    SetPlayerVirtualWorld(playerid,1);
    SetPlayerInterior(playerid,0);
    SetPlayerPos(playerid, 2924.9727,-1563.8043,11.0469);
    SetPlayerFacingAngle(playerid,86.8798);
    SetPlayerCameraPos(playerid, 2920.7109,-1563.5922,12.0877);
    SetPlayerCameraLookAt(playerid, 2924.9727,-1563.8043,11.0469);
    GameTextForPlayer(playerid, "~b~~h~Aztecas", 500, 3);
    ApplyAnimation(playerid,"DANCING","dance_loop",4.1,1,1,1,0,0,1);
    gTeam[playerid] = TEAM_AZTECAS;
    }
    case 9,10,11:
    {
    SetPlayerColor(playerid,0x391CE3FF);
    SetPlayerVirtualWorld(playerid,1);
    SetPlayerInterior(playerid,0);
    SetPlayerPos(playerid, 1511.6647,-1661.5663,13.5469);
    SetPlayerFacingAngle(playerid,294.1803);
    SetPlayerCameraPos(playerid, 1514.9290,-1660.1001,14.3447);
    SetPlayerCameraLookAt(playerid, 1511.6647,-1661.5663,13.5469);
    GameTextForPlayer(playerid, "~b~Law Enforcement", 500, 3);
    ApplyAnimation(playerid,"DANCING","dance_loop",4.1,1,1,1,0,0,1);
    gTeam[playerid] = TEAM_PD;
    }
    case 12:
    {
    SetPlayerColor(playerid,0xFF8000FF);
    SetPlayerVirtualWorld(playerid,1);
    SetPlayerInterior(playerid,0);
    SetPlayerPos(playerid, 2730.8486,-2435.0906,17.5937);
    SetPlayerFacingAngle(playerid,275.0464);
    SetPlayerCameraPos(playerid, 2740.0576,-2432.1721,20.8492);
    SetPlayerCameraLookAt(playerid, 2730.8486,-2435.0906,17.5937);
    GameTextForPlayer(playerid, "~g~Military", 500, 3);
    ApplyAnimation(playerid,"DANCING","dance_loop",4.1,1,1,1,0,0,1);
    gTeam[playerid] = TEAM_MILITARY;
    }
    case 13,14,15:
    {
    SetPlayerColor(playerid,0xFF9DFFFF);
    SetPlayerVirtualWorld(playerid,1);
    SetPlayerInterior(playerid,0);
    SetPlayerPos(playerid, 681.2793,-1257.7128,13.5791);
    SetPlayerFacingAngle(playerid,107.2843);
    SetPlayerCameraPos(playerid, 677.6121,-1258.8541,14.2270);
    SetPlayerCameraLookAt(playerid, 681.2793,-1257.7128,13.5791);
    GameTextForPlayer(playerid, "~p~~h~Triads", 500, 3);
    ApplyAnimation(playerid,"DANCING","dance_loop",4.1,1,1,1,0,0,1);
    gTeam[playerid] = TEAM_TRIADS;
    }
    return 1;
    }


    ganz am anfang und am ende waren Klammerfehler ;)

    damit erstellst und löschst du die Fahrzeuge für den Spieler


    new PlayerCar[MAX_PLAYERS];


    public OnPlayerDisconnect(playerid, reason)
    {
    PlayerCar[playerid] = 0;
    DestroyVehicle(PlayerCar[playerid]);
    return 1;
    }


    public OnPlayerSpawn(playerid)
    {
    new Float:X, Float:Y, Float:Z, Float:Angle;
    GetPlayerPos(playerid, X,Y,Z);
    GetPlayerFacingAngle(playerid, Angle);
    PlayerCar[playerid] = CreateVehicle(411, X, Y, Z, Angle, -1, -1, 60);
    return 1;
    }



    Ich versteh nicht so ganz was du mit dem Namen meinst :?:

    for(new i = 0; i < 18; i++)
    {
    new Text3D:3dtext = Create3DTextLabel("Text",0x00FF01,00.00,00.00,00.00,40.0,0);


    Attach3DTextLabelToVehicle( 3dtext, CopCar[i], 0.0, 0.0, 2.0);
    }



    das musst du löschen



    Das funktioniert aber trotzdem nicht, geht nur mit CreateVehicle.. also musst dir was anderes überlegen



    einfach unter deine fahrzeuge wo die erstellt werden


    new carid;
    for(new i = 0; i < sizeof(CopCar); i++)
    {
    if(carid == CopCar[i])
    {
    new Text3D:CopCar3D = Create3DTextLabel("Cop Car",0x0066CCFF,30.0,30.0,5.0,30.0,0);
    Attach3DTextLabelToVehicle(CopCar3D , CopCar[i], 0.0, 0.0, 0.0);
    return 1;
    }
    }

    Das ist recht einfach zu realisieren. Einfach InGame einen PickUp erstellen und dann eben angeben, was dann passiert. Das muss eben dynamisch gecodet sein. Aber in der Umsetzung recht einfach.

    Dann machs ihm doch, er wünscht es sich doch sonst würde er es nicht unter Scriptwünsche Posten.

    Naja ist eigendlich nicht schwer zu verstehen, wenn er die Position speichern soll machst du einfach


    SavePlayerPos(playerid);


    das selbe beim porten


    TeleToSavedPlayerPos(playerid);

    Zu 1.
    Das einfach unter
    public OnPlayerRequestClass(playerid, classid)


    if(classid == 0 || classid == 1 || classid == 2)
    {
    GameTextForPlayer(playerid, "~g~ Team Grove", 2000, 6);
    }
    if(classid == 3 || classid == 4 || classid == 5)
    {
    GameTextForPlayer(playerid, "~g~ Team Ballas", 2000, 6);
    }
    if(classid == 6 || classid == 7 || classid == 8)
    {
    GameTextForPlayer(playerid, "~g~ Team Vagos", 2000, 6);
    }
    if(classid == 9 || classid == 10 || classid == 11)
    {
    GameTextForPlayer(playerid, "~g~ Team Police", 2000, 6);
    }




    Zu 2.
    GetPlayerSkin(playerid);

    Hier ne nette Funktion die die momentane Position des Spielers Speichert, und eine Funktion die den Spieler zur gespeicherten Position teleportiert.



    new Float:CordSave[MAX_PLAYERS][3];


    stock SavePlayerPos(playerid)
    {
    GetPlayerPos(playerid, CordSave[playerid][0],CordSave[playerid][1],CordSave[playerid][2]);
    }


    stock TeleToSavedPlayerPos(playerid)
    {
    if (GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
    {
    new vehicle = GetPlayerVehicleID(playerid);
    SetVehiclePos(vehicle, CordSave[playerid][0],CordSave[playerid][1],CordSave[playerid][2]);
    }
    else
    {
    SetPlayerPos(playerid, CordSave[playerid][0],CordSave[playerid][1],CordSave[playerid][2]);
    }
    }

    new TutorialTime[MAX_PLAYERS];


    SetTimer("Tutorial", 1001, 1);


    public Tutorial()
    {
    for(new i = 0; i < MAX_PLAYERS; i++)
    {
    if(TutorialTime[i] >= 1)
    {
    TutorialTime[i] += 1;
    if(TutorialTime[i] == 2){
    SendClientMessageToAll(0x00FF00FF,"Step 1");}
    if(TutorialTime[i] == 20){
    SendClientMessageToAll(0x00FF00FF,"Step 2");}
    if(TutorialTime[i] == 40){
    SendClientMessageToAll(0x00FF00FF,"Step 3");}
    if(TutorialTime[i] == 60){
    SendClientMessageToAll(0x00FF00FF,"Step 4");}
    if(TutorialTime[i] == 80){
    TutorialTime[i] = 0;
    }
    }
    }
    }


    Wenn der Spieler ins Tutorial soll setzt du ihm einfach diese Variable
    TutorialTime[playerid] = 1;