SDPistol tazer
#1

Why i do /tazer that players not in tazer

here code
Код:
	if(strcmp(cmd, "/tazer", true) ==0)
 	{
	    if(IsPlayerConnected(playerid))
	    {
			if(PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pMember] == 2 || PlayerInfo[playerid][pMember] == 3 ||  PlayerInfo[playerid][pMember] == 5 || PlayerInfo[playerid][pMember] == 7)
			{
			    /*new x_job[20];
			    x_job = strtok(cmdtext, idx);
			    if(!strlen(x_job))
			    {
				    SendClientMessage(playerid, COLOR_GREY, "USAGE: /tazer [get/putaway]");
				    return 1;
			    }
			    tmp = strtok(cmdtext, idx);*/
                if(TazerHolster[playerid] == 1)
                {
                    if(PlayerInfo[playerid][pGun2] == 24) PlayerHadDeagle[playerid] = 1;
                    GivePlayerGun(playerid, 23);
                    PlayerHasTazer[playerid] = 1;
                    TazerHolster[playerid] = 0;
                    format(string, sizeof(string), "* %s unholsters his tazer.", PlayerName(playerid));
					ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
                }
                else if(TazerHolster[playerid] == 0)
                {
                    if(PlayerHasTazer[playerid] == 0) return SendClientMessage(playerid,COLOR_GREY,"You don't have a tazer out!");
                    TakeWeapon(playerid, 23);
                    if(PlayerHadDeagle[playerid] == 1) GivePlayerGun(playerid, 24);
                    PlayerHasTazer[playerid] = 0;
                    PlayerHadDeagle[playerid] = 0;
                    TazerHolster[playerid] = 1;
                    format(string, sizeof(string), "* %s holsters his tazer back.", PlayerName(playerid));
					ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
                }
			}
			else
			{
				SendClientMessage(playerid, COLOR_GREY, "   You are not a Cop / FBI / SASP / NG / SS !");
			}
		}
	    return 1;
	}
Reply
#2

any? please help me long ago i fixed this..
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)