[Pomoc]Steal gun

Započeo Nikola_Soprano, Jun 11, 2013, 15:18:56 POSLE PODNE

prethodna tema - sledeća tema

0 članova i 2 gostiju pregledaju ovu temu.

Skripta koju koristim: Moja editovana
Detaljan opis problema: Problem, ne radi mi komanda /steal gun , kako mogu da je namestim
Dio skripte: else if(strcmp(x_nr,"oruzije",true) == 0)
{
    tmp = strtok(cmdtext, idx);
if(!strlen(tmp)) {
SendClientMessage(playerid, COLOR_LIGHTRED, "[Koriscenje]: {FFFFFF}/steal gun [ID Igraca/Deo imena]");
return 1;
}
giveplayerid = ReturnUser(tmp);
if(IsPlayerConnected(giveplayerid))
{
if(PlayerTied[giveplayerid] != 1)
      {
      SendClientMessage(playerid, COLOR_LIGHTRED, "[ODBIJENO] {FFFFFF}Igrac mora biti prvo vezan ! ");
      return 1;
}
    if(giveplayerid != INVALID_PLAYER_ID)
    {
        if (ProxDetectorS(3.0, playerid, giveplayerid))
{
    GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
GetPlayerName(playerid, sendername, sizeof(sendername));
    if(giveplayerid == playerid) { SendClientMessage(playerid, COLOR_LIGHTRED, "[ODBIJENO] {FFFFFF}Ne mozete ukrasti sebi!"); return 1; }
        format(string, sizeof(string), "* Ukrali ste %s-u oruzije.", giveplayer);
        SendClientMessage(playerid, COLOR_WHITE, string);
        format(string, sizeof(string), "* %s vam je ukrao oruzije.", sendername);
        SendClientMessage(giveplayerid, COLOR_LIGHTRED, string);
format(string, sizeof(string), "* %s je ukrao oruzije %s-u.", sendername ,giveplayer);
ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
        SafeJBC_ResetPlayerWeapons(giveplayerid);
        PlayerInfo[giveplayerid][pGun1] = 0; PlayerInfo[giveplayerid][pAmmo1] = 0;
        PlayerInfo[giveplayerid][pGun2] = 0; PlayerInfo[giveplayerid][pAmmo2] = 0;
        PlayerInfo[giveplayerid][pGun3] = 0; PlayerInfo[giveplayerid][pAmmo3] = 0;
        PlayerInfo[giveplayerid][pGun4] = 0; PlayerInfo[giveplayerid][pAmmo4] = 0;
        }
        else
{
    SendClientMessage(playerid, COLOR_GREY, "{FFFFFF}[{F81414}BSL-RP{FFFFFF}] Igrac nije blizu vas!");
    return 1;
}
    }
}
else
{
    SendClientMessage(playerid, COLOR_GREY, "{FFFFFF}[{F81414}BSL-RP{FFFFFF}] Igrac je offline!");
    return 1;
}

Neke slike/video za lakse dobivanje pomoci(neobavezno): /

Kako mislis ne radi,mislis na to sto kada ukrades ne dodje kradljivcu?




Balkan Ulice RPG opis servera: Click



-Tutorial za mijesanje ID-ova na vozilima: Click

pise nepoznato ime za kradju....

Citat: Nikola_Soprano poslato Jun 11, 2013, 15:48:21 POSLE PODNE
pise nepoznato ime za kradju....

jesi slucajno probo /steal oruzije

a ne /steal gun
Other Dimension RolePlay | Uskoro
Ukoliko zelite pomoci u razvoju servera, mozete se meni javit na PP/PM!

Probaj else if(strcmp(x_nr,"oruzije",true) == 0)
{
    tmp = strtok(cmdtext, idx);
if(!strlen(tmp)) {
SendClientMessage(playerid, COLOR_WHITE, "Koriscenje: /steal gun [ID Igraca/Dio Imena]");
return 1;
}
giveplayerid = ReturnUser(tmp);
if(IsPlayerConnected(giveplayerid))
{
if(PlayerTied[giveplayerid] != 1)
      {
      SendClientMessage(playerid, COLOR_GREY, "   Igrac mora biti prvo vezan ! ");
      return 1;
}
    if(giveplayerid != INVALID_PLAYER_ID)
    {
        if (ProxDetectorS(3.0, playerid, giveplayerid))
{
    GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
GetPlayerName(playerid, sendername, sizeof(sendername));
    if(giveplayerid == playerid) { SendClientMessage(playerid, COLOR_GREY, "[ODBIJENO] {FFFFFF}    Ne mozete ukrasti sebi!"); return 1; }
        format(string, sizeof(string), "* Ukrali ste %s-u oruzije.", giveplayer);
        SendClientMessage(playerid, COLOR_WHITE, string);
        format(string, sizeof(string), "* %s vam je ukrao oruzije.", sendername);
        SendClientMessage(giveplayerid, COLOR_WHITE, string);
format(string, sizeof(string), "* %s je ukrao oruzije %s-u.", sendername ,giveplayer);
ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
        SafeResetPlayerWeapons(giveplayerid);
        PlayerInfo[giveplayerid][pGun1] = 0; PlayerInfo[giveplayerid][pAmmo1] = 0;
        PlayerInfo[giveplayerid][pGun2] = 0; PlayerInfo[giveplayerid][pAmmo2] = 0;
        PlayerInfo[giveplayerid][pGun3] = 0; PlayerInfo[giveplayerid][pAmmo3] = 0;
        PlayerInfo[giveplayerid][pGun4] = 0; PlayerInfo[giveplayerid][pAmmo4] = 0;
        }
        else
{
    SendClientMessage(playerid, COLOR_GREY, "{FFFFFF}[{F81414}BSL-RP{FFFFFF}]  Taj igrac nije blizu vas!");
    return 1;
}
    }
}
else
{
    SendClientMessage(playerid, COLOR_GREY, "{FFFFFF}[{F81414}BSL-RP{FFFFFF}]   Igrac je offline!");
    return 1;
}
}

boco pre bih rekao da je crazyness u pravu :)

Citat: Crazyn3ss poslato Jun 11, 2013, 16:13:11 POSLE PODNE
Citat: Nikola_Soprano poslato Jun 11, 2013, 15:48:21 POSLE PODNE
pise nepoznato ime za kradju....

jesi slucajno probo /steal oruzije

a ne /steal gun
Jesam, nego sam ovo na brzinu napisao....