jedan covek u jedan tim drug u drug tim

Započeo [IF] mariomako, Jun 30, 2010, 20:08:07 POSLE PODNE

prethodna tema - sledeća tema

0 članova i 4 gostiju pregledaju ovu temu.

zz, interesira me kako da napravim kada neko upise neku komandu primer /dm na toga igraca da mu dade nekoj skin i da mu stavi neku x,y,z a na tog sledecog da mu stavi drugu x,y,z i drugi skin??? znaci jedan tamo jedan tamo

Mislis... Da se spawnaju na random mjesta na radmom skinovima?



    O meni:
    Geek, gamer, i internet freak :) , bavim se web-designom, umjetnoscu, game developmentom.

    Mape:
    Tutoriali: [/list]

    ne misli ako si ikad igro cod mp kad kliknes auto asign da te prebaci u tim koji ima manje igraaaca npr, ja sam u timu A i neko upise /dm i njega prebaci u tim B kuzis ?


    Nez

    *

    evo ga :)

    za postaviti mu skin
    SetPlayerSkin(playerid, SkinID);

    da mu postavis poziciju :)
    SetPlayerPos(playerid, XXX.xxx,YYY.yyy,ZZZ.zzz);
    uozbiljite se :(

    Citat: Nez poslato Jul 01, 2010, 00:54:15 PRE PODNE
    evo ga :)

    za postaviti mu skin
    SetPlayerSkin(playerid, SkinID);

    da mu postavis poziciju :)
    SetPlayerPos(playerid, XXX.xxx,YYY.yyy,ZZZ.zzz);

    hah, nisam mislio kako mu se postavlja skin i x,y,z nego jednom kad upise /dm da mu stavi jedan skin i neku pozu a sledeci put kad upise da mu stavi drugu x,y,z i drug skin

    a ako je nemoguce tako onda kako da gi napravim random?

    EDIT: Zna neko ili ovo je nemoguce?
    Poslednja Izmena: Jul 01, 2010, 14:23:22 POSLE PODNE od Mario Velickovski

    sada cu da probam da pomognem ;)

    evo ovako ako uspe :)

    [code]if(strcmp(cmdtext, "/DM", true) == 0)
    {
           GetPlayerName(playerid, pName, sizeof(pName));
           format(string, sizeof(string), "TELE: %s je otisao na (/DM)", pName);
           SendClientMessageToAll(COLOR_YELLOW, string);
       ResetPlayerWeapons(playerid);
    new DM[128], playerName[MAX_PLAYER_NAME], RandomSpawn = random(1);
    GetPlayerName(playerid, playerName, MAX_PLAYER_NAME);
    DMZone[playerid] = 1;
    if (RandomSpawn == 0)
    {
    InCar[playerid] = false;
    SetPlayerPos(playerid, Pozicija);
                           SetPlayerSkin(playerid, Skin);                        
    SetPlayerFacingAngle(playerid, Angle);
    SetCameraBehindPlayer(playerid);
    }
    if (RandomSpawn == 1)
    {


    sad neznam dali ce uspeti :([/code]
    Poslednja Izmena: Jul 02, 2010, 11:48:32 PRE PODNE od [AdmTeam]_jovan

    Citat: [AdmTeam]_jovan poslato Jul 02, 2010, 10:37:21 PRE PODNE
    sada cu da probam da pomognem ;)

    evo ovako ako uspe :)

    [code]    if(strcmp(cmdtext, "/DM", true) == 0)
    {
            new string[128];
    GetPlayerName(playerid, pName, sizeof(pName));
            format(string, sizeof(string), "TELE: %s je otisao na (/DM)", pName);
            SendClientMessageToAll(COLOR_LIGHTGREEN, string);
        ResetPlayerWeapons(playerid);
    new DM[128], playerName[MAX_PLAYER_NAME], RandomSpawn = random(1);
    GetPlayerName(playerid, playerName, MAX_PLAYER_NAME);
    DMZone[playerid] = 1;
    if (RandomSpawn == 0)
    {
    InCar[playerid] = false;
    SetPlayerPos(playerid, 26.4734,1362.1244,9.1719);
        SetPlayerSkin(playerid, 1);
    SetCameraBehindPlayer(playerid);
    }
    if (RandomSpawn == 1)
    {
    InCar[playerid] = false;
    SetPlayerPos(playerid, 3.7642,1344.8734,9.1719);
        SetPlayerSkin(playerid, 2);
    SetCameraBehindPlayer(playerid);
    }
    return 1;
    }


    sad neznam dali ce uspeti :([/code]

    malo sam ga uredio i nalazi ove errore

        if(strcmp(cmdtext, "/DM", true) == 0)
    {
            new string[128];
    GetPlayerName(playerid, pName, sizeof(pName));
            format(string, sizeof(string), "TELE: %s je otisao na (/DM)", pName);
            SendClientMessageToAll(COLOR_LIGHTGREEN, string);
        ResetPlayerWeapons(playerid);
    new DM[128], playerName[MAX_PLAYER_NAME], RandomSpawn = random(1);
    GetPlayerName(playerid, playerName, MAX_PLAYER_NAME);
    DMZone[playerid] = 1;
    if (RandomSpawn == 0)
    {
    InCar[playerid] = false;
    SetPlayerPos(playerid, Pozicija);
        SetPlayerSkin(playerid, Skin);
    SetPlayerFacingAngle(playerid, Angle);
    SetCameraBehindPlayer(playerid);
    }
    if (RandomSpawn == 1)
    {
    InCar[playerid] = false;
    SetPlayerPos(playerid, Pozicija);
        SetPlayerSkin(playerid, Skin);
    SetPlayerFacingAngle(playerid, Angle);
    SetCameraBehindPlayer(playerid);
    }
    return 1;
    }


    E:\SAMP Server\PittBull Stunt\gamemodes\pitbull.pwn(99) : error 017: undefined symbol "DMZone"
    E:\SAMP Server\PittBull Stunt\gamemodes\pitbull.pwn(99) : warning 215: expression has no effect
    E:\SAMP Server\PittBull Stunt\gamemodes\pitbull.pwn(99) : error 001: expected token: ";", but found "]"
    E:\SAMP Server\PittBull Stunt\gamemodes\pitbull.pwn(99) : error 029: invalid expression, assumed zero
    E:\SAMP Server\PittBull Stunt\gamemodes\pitbull.pwn(99) : fatal error 107: too many error messages on one line


    EDIT:

        if(strcmp(cmdtext, "/DM", true) == 0)
    {
            new string[128];
    GetPlayerName(playerid, pName, sizeof(pName));
            format(string, sizeof(string), "TELE: %s je otisao na (/DM)", pName);
            SendClientMessageToAll(COLOR_LIGHTGREEN, string);
        ResetPlayerWeapons(playerid);
    new DM[128], playerName[MAX_PLAYER_NAME], RandomSpawn = random(1);
    GetPlayerName(playerid, playerName, MAX_PLAYER_NAME);
    DMZone[playerid] = 1;
    if (RandomSpawn == 0)
    {
    InCar[playerid] = false;
    SetPlayerPos(playerid, 26.4734,1362.1244,9.1719);
        SetPlayerSkin(playerid, 1);
    SetCameraBehindPlayer(playerid);
    }
    if (RandomSpawn == 1)
    {
    InCar[playerid] = false;
    SetPlayerPos(playerid, 3.7642,1344.8734,9.1719);
        SetPlayerSkin(playerid, 2);
    SetCameraBehindPlayer(playerid);
    }
    return 1;
    }
    Poslednja Izmena: Jul 02, 2010, 13:55:30 POSLE PODNE od Mario Velickovski

    nastoe

    zelis da ide prvi u tim A, a drugi koji napise u tim B, ili zelis da sami odaberu tim?

    Citat: à¸,,à¹"à¹"เภเรtгà¸,,t๏г poslato Jul 02, 2010, 13:57:33 POSLE PODNE
    zelis da ide prvi u tim A, a drugi koji napise u tim B, ili zelis da sami odaberu tim?

    prvi ko upise ide u tim a a drugi u tim b

    pa neznam napravi neku komandu za naprimer /dm i sada da ti izbaci ono kao kod N1n0-slava kod organizacije i tada samo napravi da imas timove po zelji i namesti oruzije koji tim zeli i boju i to sto treba sve evo ti link da nemoras da kopas ko zna gde http://balkan-samp.com/forum/index.php?topic=7408.0

    Citat: [AdmTeam]_jovan poslato Jul 02, 2010, 15:56:32 POSLE PODNE
    pa neznam napravi neku komandu za naprimer /dm i sada da ti izbaci ono kao kod N1n0-slava kod organizacije i tada samo napravi da imas timove po zelji i namesti oruzije koji tim zeli i boju i to sto treba sve evo ti link da nemoras da kopas ko zna gde http://balkan-samp.com/forum/index.php?topic=7408.0

    da, ali ja ocu ono da mi odbere tim a ne ja da biram ako ne nagem drugo care moracu da si sam igrac bira

    pa bolje ti ovako kao sto sam ti pokazao zato sto ovako kad si neznam de ce te spawn i koji ce ti skin dati bolje da ti biras i da se dogovoris sa drugim igracem pa kao da igrate CW(Clan Wars) Klansku kao na CS 1.6 :D :)

    Citat: [AdmTeam]_jovan poslato Jul 02, 2010, 19:44:41 POSLE PODNE
    pa bolje ti ovako kao sto sam ti pokazao zato sto ovako kad si neznam de ce te spawn i koji ce ti skin dati bolje da ti biras i da se dogovoris sa drugim igracem pa kao da igrate CW(Clan Wars) Klansku kao na CS 1.6 :D :)

    ma za to i mi treba i za CS_ITALY2 ali primer kada nebi bio neki admin online svi ugu primer u terroristi i sta bude propadne cela mapa niko nesmije dolazit u cajkane

    imam ideju

    mozes da napravis random grupe posto nemoze ako jedan udje u jednu a drugi koji ukuca u drugu, evo random spawn sa razlicitim skinovima

    if(strcmp(cmdtext, "/DM", true) == 0)
    {
           GetPlayerName(playerid, pName, sizeof(pName));
           format(string, sizeof(string), "TELEPORTI: %s je usao u Team DM arenu (/DM)", pName);
           SendClientMessageToAll(COLOR_YELLOW, string);
       ResetPlayerWeapons(playerid);
    new DM[128], playerName[MAX_PLAYER_NAME], RandomSpawn = random(4);
    GetPlayerName(playerid, playerName, MAX_PLAYER_NAME);
    DMZone[playerid] = 1;
    if (RandomSpawn == 0)
    {
    InCar[playerid] = false;
    SetPlayerPos(playerid, X,Y,Z);
    SetPlayerFacingAngle(playerid, Angle);
    SetCameraBehindPlayer(playerid);
    SetPlayerSkin(playerid, IDskina);
    }
    if (RandomSpawn == 1)
    {
    InCar[playerid] = false;
    SetPlayerPos(playerid, X,Y,Z);
    SetPlayerFacingAngle(playerid, Angle);
    SetCameraBehindPlayer(playerid);
    SetPlayerSkin(playerid, IDskina);
    }
    if (RandomSpawn == 2)
    {
    InCar[playerid] = false;
    SetPlayerPos(playerid, X,Y,Z);
    SetPlayerFacingAngle(playerid, Angle);
    SetCameraBehindPlayer(playerid);
    SetPlayerSkin(playerid, IDskina);
    }
    if (RandomSpawn == 3)
    {
    InCar[playerid] = false;
    SetPlayerPos(playerid, X,Y,Z);
    SetPlayerFacingAngle(playerid, Angle);
    SetCameraBehindPlayer(playerid);
    SetPlayerSkin(playerid, IDskina);
    }
    GivePlayerWeapon(playerid, IDoruzja, metkovi);
    SetPlayerInterior(playerid, 0);
    SendClientMessage(playerid, COLOR_BASIC, "Ti si usao na Team DM);
    SendClientMessage(playerid, COLOR_RED, "Zelimo tu lepo zabavu na Team DM");
    format(DM, sizeof(DM), "%s je teleportovan na /DM", playerName);
    for(new i=0; i<MAX_PLAYERS; i++)
    {
    if(IsPlayerConnected(i))
    {
    if(ReceiveInfo[i] == true)
    {
    SendClientMessage(i, COLOR_GREY, DM);
    }
    }
    }
    return 1;
    }


    tako bi bilo

    trebas da izmenis GivePlayerWeapon sto pise tamo i ako oces jos oruzja da budu samo pritisnes enter i
    GivePlayerWeapon(playerid, IDoruzja, metkovi);
    i trebas da izmenis pozicije, Angle i ID skina da stavis koji hoces

    stavio sam 4 spawna da bi bilo 2 random spawna za jedan tim i 2 random spawna za drugi tim

    nadam se da sam pomogao
    Poslednja Izmena: Jul 03, 2010, 03:20:23 PRE PODNE od Christian_Bojic

    Citat: Christian_Bojic poslato Jul 03, 2010, 03:14:43 PRE PODNE
    imam ideju

    mozes da napravis random grupe posto nemoze ako jedan udje u jednu a drugi koji ukuca u drugu, evo random spawn sa razlicitim skinovima

    if(strcmp(cmdtext, "/DM", true) == 0)
    {
           GetPlayerName(playerid, pName, sizeof(pName));
           format(string, sizeof(string), "TELEPORTI: %s je usao u Team DM arenu (/DM)", pName);
           SendClientMessageToAll(COLOR_YELLOW, string);
       ResetPlayerWeapons(playerid);
    new DM[128], playerName[MAX_PLAYER_NAME], RandomSpawn = random(4);
    GetPlayerName(playerid, playerName, MAX_PLAYER_NAME);
    DMZone[playerid] = 1;
    if (RandomSpawn == 0)
    {
    InCar[playerid] = false;
    SetPlayerPos(playerid, X,Y,Z);
    SetPlayerFacingAngle(playerid, Angle);
    SetCameraBehindPlayer(playerid);
    SetPlayerSkin(playerid, IDskina);
    }
    if (RandomSpawn == 1)
    {
    InCar[playerid] = false;
    SetPlayerPos(playerid, X,Y,Z);
    SetPlayerFacingAngle(playerid, Angle);
    SetCameraBehindPlayer(playerid);
    SetPlayerSkin(playerid, IDskina);
    }
    if (RandomSpawn == 2)
    {
    InCar[playerid] = false;
    SetPlayerPos(playerid, X,Y,Z);
    SetPlayerFacingAngle(playerid, Angle);
    SetCameraBehindPlayer(playerid);
    SetPlayerSkin(playerid, IDskina);
    }
    if (RandomSpawn == 3)
    {
    InCar[playerid] = false;
    SetPlayerPos(playerid, X,Y,Z);
    SetPlayerFacingAngle(playerid, Angle);
    SetCameraBehindPlayer(playerid);
    SetPlayerSkin(playerid, IDskina);
    }
    GivePlayerWeapon(playerid, IDoruzja, metkovi);
    SetPlayerInterior(playerid, 0);
    SendClientMessage(playerid, COLOR_BASIC, "Ti si usao na Team DM);
    SendClientMessage(playerid, COLOR_RED, "Zelimo tu lepo zabavu na Team DM");
    format(DM, sizeof(DM), "%s je teleportovan na /DM", playerName);
    for(new i=0; i<MAX_PLAYERS; i++)
    {
    if(IsPlayerConnected(i))
    {
    if(ReceiveInfo[i] == true)
    {
    SendClientMessage(i, COLOR_GREY, DM);
    }
    }
    }
    return 1;
    }


    tako bi bilo

    trebas da izmenis GivePlayerWeapon sto pise tamo i ako oces jos oruzja da budu samo pritisnes enter i
    GivePlayerWeapon(playerid, IDoruzja, metkovi);
    i trebas da izmenis pozicije, Angle i ID skina da stavis koji hoces

    stavio sam 4 spawna da bi bilo 2 random spawna za jedan tim i 2 random spawna za drugi tim

    nadam se da sam pomogao

    evo kako mi je izaslo

    if(strcmp(cmdtext, "/DM", true) == 0)
        {
    GetPlayerName(playerid, pName, sizeof(pName));
    format(string, sizeof(string), "%s je usao u Team DM arenu (/DM)", pName);
    SendClientMessageToAll(COLOR_YELLOW, string);
    ResetPlayerWeapons(playerid);
    new DM[128], playerName[MAX_PLAYER_NAME], RandomSpawn = random(4);
    GetPlayerName(playerid, playerName, MAX_PLAYER_NAME);
    DMZone[playerid] = 1;
    if (RandomSpawn == 0)
    {
    InCar[playerid] = false;
    SetPlayerPos(playerid, 26.4734,1362.1244,9.1719);
    SetCameraBehindPlayer(playerid);
    SetPlayerSkin(playerid, 2);
    }
    if (RandomSpawn == 1)
    {
    InCar[playerid] = false;
    SetPlayerPos(playerid, 3.7642,1344.8734,9.1719);
    SetCameraBehindPlayer(playerid);
    SetPlayerSkin(playerid, 1);
    }
    if (RandomSpawn == 2)
    {
    InCar[playerid] = false;
    SetPlayerPos(playerid, 26.4734,1362.1244,9.1719;
    SetCameraBehindPlayer(playerid);
    SetPlayerSkin(playerid, 2);
    }
    if (RandomSpawn == 3)
    {
    InCar[playerid] = false;
    SetPlayerPos(playerid, 3.7642,1344.8734,9.1719);
    SetCameraBehindPlayer(playerid);
    SetPlayerSkin(playerid, 1);
    }
    GivePlayerWeapon(playerid, 38, 999);
    SetPlayerInterior(playerid, 0);
    SendClientMessage(playerid, COLOR_BASIC, "Ti si usao na Team DM);
    SendClientMessage(playerid, COLOR_RED, "Zelimo tu lepo zabavu na Team DM");
    format(DM, sizeof(DM), "%s je teleportovan na /DM", playerName);
    for(new i=0; i<MAX_PLAYERS; i++)
    {
    if(IsPlayerConnected(i))
    {
    if(ReceiveInfo<i> == true)
    {
    SendClientMessage(i, COLOR_GREY, DM);
    }
    }
    }
    return 1;
    }


    ali nalazi mi sledece errore

    E:\SAMP Server\PittBull Stunt\gamemodes\pitbull.pwn(89) : error 029: invalid expression, assumed zero
    E:\SAMP Server\PittBull Stunt\gamemodes\pitbull.pwn(89) : warning 217: loose indentation
    E:\SAMP Server\PittBull Stunt\gamemodes\pitbull.pwn(89) : error 029: invalid expression, assumed zero
    E:\SAMP Server\PittBull Stunt\gamemodes\pitbull.pwn(89) : error 029: invalid expression, assumed zero
    E:\SAMP Server\PittBull Stunt\gamemodes\pitbull.pwn(89) : fatal error 107: too many error messages on one line


    i daj molimte vise ne postaj u CODE=C jel uvek mi nalazi loose identitation