Problema PD
#1

Buna seara.
Am cateva buguri la PD pe care nu stiu cum sa le rezolv. Nici nu stiu liniile care trebuie modifica. Problema sta in felul urmator: ca sa pot da /cuff , trebuie neaparat sa dau /tazer. Altfel nu merge. Dupa asta vine bugul cel mare si anume cand il arestez si dau /arrest nick bill ,etc. il trimite nu in celula dar in interiorul PDului si nici bani nu-i ia cat am scris acolo si ramane cuffed.

As vrea sa pot da /cuff fara sa dau /tazer si cand dau /arrest sa il trimita in celula si bani sa-i ia corespunzator.

Sper sa ma puteti ajuta ca ma dispera problema.

Mersi anticipat
Reply
#2

Vezi ca tcmai ti-am spart firewall si ti-am modificat eu GM, ia vezi acum merge?

Posteaza Scriptul
Reply
#3

Quote:

As vrea sa pot da /cuff fara sa dau /tazer si cand dau /arrest sa il trimita in celula si bani sa-i ia corespunzator.

Sper sa ma puteti ajuta ca ma dispera problema.


Ai vrea,dar.....nu te putem ajuta daca nu avem scriptul.... Uploadeaza Game-mod`ul si lasa linkul, sau posteaza aici comanda /arrest si comanda /cuff din game-mode.
Reply
#4

sper ca aici e buba

Code:
if(strcmp(cmd, "/arrest", true) == 0)
	{
	    if(IsPlayerConnected(playerid))
	   	{
			if(gTeam[playerid] == 2  || IsACop(playerid))
			{
				if(OnDuty[playerid] != 1 && PlayerInfo[playerid][pMember] == 1)
				{
				    SendClientMessage(playerid, COLOR_GREY, "{ffffff}you are not on duty!");
				    return 1;
				}
				if(!PlayerToPoint(6.0, playerid, 1526.8973,-1678.2036,5.8906))
				{// Jail spot
				    SendClientMessage(playerid, COLOR_GREY, "{ffffff}Nu esti langa inchisoare,nu poti aresta !");
				    return 1;
				}
				tmp = strtok(cmdtext, idx);
				if(!strlen(tmp))
				{
					SendClientMessage(playerid, COLOR_GRAD2, " {FFA500}[INFO]:{ffffff} /arrest [price] [time (minutes)] [bail (0=no 1=yes)] [bailprice]");
					return 1;
				}
				moneys = strval(tmp);
				if(moneys < 1 || moneys > 1000) { SendClientMessage(playerid, COLOR_GREY, "{ffffff}Pretul nu poate fi mai mic de 1$ sau mai mare de 1000$ !"); return 1; }
				tmp = strtok(cmdtext, idx);
				if(!strlen(tmp))
				{
					SendClientMessage(playerid, COLOR_GRAD2, " {FFA500}[INFO]:{ffffff} /arrest [price] [time (minutes)] [bail (0=no 1=yes)] [bailprice]");
					return 1;
				}
				new time = strval(tmp);
				if(time < 1 || time > 6000) { SendClientMessage(playerid, COLOR_GREY, "{ffffff}Secundele arestarii nu pot fi mai putine de 1, sau mai mare de 6000, !"); return 1; }
				tmp = strtok(cmdtext, idx);
				if(!strlen(tmp))
				{
					SendClientMessage(playerid, COLOR_GRAD2, " {FFA500}[INFO]:{ffffff} /arrest [price] [time (minutes)] [bail (0=no 1=yes)] [bailprice]");
					return 1;
				}
				new bail = strval(tmp);
				if(bail < 0 || bail > 1) { SendClientMessage(playerid, COLOR_GREY, "{ffffff}Bail nu poate fi mai putin de 0 sau mai mult de 1 !"); return 1; }
				tmp = strtok(cmdtext, idx);
				if(!strlen(tmp))
				{
					SendClientMessage(playerid, COLOR_GRAD2, " {FFA500}[INFO]:{ffffff} /arrest [price] [time (minutes)] [bail (0=no 1=yes)] [bailprice]");
					return 1;
				}
				new bailprice = strval(tmp);
				if(bailprice < 0 || bailprice > 1000) { SendClientMessage(playerid, COLOR_GREY, "{ffffff}Amenda nu poate fi mai mica de 0$ sau mai mare de 1000$ !"); return 1; }
				new suspect = GetClosestPlayer(playerid);
				if(IsPlayerConnected(suspect))
				{
					if(GetDistanceBetweenPlayers(playerid,suspect) < 5)
					{
						GetPlayerName(suspect, giveplayer, sizeof(giveplayer));
						GetPlayerName(playerid, sendername, sizeof(sendername));
						if(WantedLevel[suspect] < 1) return SendClientMessage(playerid, COLOR_GREY, "{ffffff}Playerul trebuie sa aiba macar level 1 wanted !");
						if(IsACop(suspect)) return SendClientMessage(playerid,COLOR_GREY,"Nu poti aresta politisti");
						format(string, sizeof(string), "* You arrested %s !", giveplayer);
						SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
						GivePlayerMoney(suspect, -moneys);
						format(string, sizeof(string), "arrested by %s ~n~    for $%d", sendername, moneys);
						GameTextForPlayer(suspect, string, 5000, 5);
						ResetPlayerWeapons(suspect);
						if(PlayerInfo[playerid][pMember]==1||PlayerInfo[playerid][pLeader]==1)
						{
							format(string, sizeof(string), "<< Ofiterul %s a arestat suspectul %s >>", sendername, giveplayer);
							OOCNews(COLOR_RED, string);
						}
						else if(PlayerInfo[playerid][pMember]==2||PlayerInfo[playerid][pLeader]==2)
						{
							format(string, sizeof(string), "<<Agentul FBI %s a arestat suspectul %s >>", sendername, giveplayer);
							OOCNews(COLOR_RED, string);
						}
						else if(PlayerInfo[playerid][pMember]==3||PlayerInfo[playerid][pLeader]==3)
						{
							format(string, sizeof(string), "<< Soldatul %s a arestat suspectul %s >>", sendername, giveplayer);
							OOCNews(COLOR_RED, string);
						}
						new rand;
      					SetPlayerInterior(suspect, 0 );
    				    rand = random(sizeof(gTurmaProg));
    				    SetPlayerPos(suspect, gTurmaProg[rand][0], gTurmaProg[rand][1], gTurmaProg[rand][2]);
            			SetPlayerWorldBounds(suspect,219.44728088379,69.380714416504,1005.0390625); //Ограждение прог. зоны
						PlayerInfo[suspect][pJailTime] = time;
						if(bail == 1)
						{
							JailPrice[suspect] = bailprice;
							format(string, sizeof(string), "Ai fost arestat pentur %d secunde. Cautiune: $%d", PlayerInfo[suspect][pJailTime], JailPrice[suspect]);
							SendClientMessage(suspect, COLOR_LIGHTBLUE, string);
						}
						else
						{
						    JailPrice[suspect] = 0;
							format(string, sizeof(string), "Ai fost arestat pentur %d secunde. Cautiune: 0", PlayerInfo[suspect][pJailTime]);
							SendClientMessage(suspect, COLOR_LIGHTBLUE, string);
						}
						PlayerInfo[suspect][pJailed] = 1;
				        PlayerInfo[suspect][pArrested] += 1;
						SetPlayerFree(suspect,playerid, "ai fost arestat");
						WantedPoints[suspect] = 0;
						WantedLevel[suspect] = 0;
						WantLawyer[suspect] = 1;
					}//distance
				}//not connected
				else
				{
				    SendClientMessage(playerid, COLOR_GREY, "{ffffff}Nu exista acest player");
				    return 1;
				}
			}
			else
			{
			    SendClientMessage(playerid, COLOR_GREY, "{ffffff}Nu esti Cop / FBI / National Guard !");
			    return 1;
			}
		}//not connected
		return 1;
si /cuff

Code:
if(strcmp(cmd, "/cuff", true) == 0) //By Raz0r
	{
	   if(IsPlayerConnected(playerid))
	   {
			if(gTeam[playerid] == 2 || IsACop(playerid))
			{
			    tmp = strtok(cmdtext, idx);
				if(!strlen(tmp)) {
					SendClientMessage(playerid, COLOR_WHITE, "USAGE: /cuff [Playerid/PartOfName]");
					return 1;
				}
				giveplayerid = ReturnUser(tmp);
			    if(IsPlayerConnected(giveplayerid))
				{
				   if(giveplayerid != INVALID_PLAYER_ID)
				   {
				       if(gTeam[giveplayerid] == 2 || IsACop(giveplayerid))
				       {
				           SendClientMessage(playerid, COLOR_GREY, "   You can't Cuff Cops !");
					       return 1;
				       }
				       if (ProxDetectorS(8.0, playerid, giveplayerid))
				       {
						   if(giveplayerid == playerid) { SendClientMessage(playerid, COLOR_GREY, "You cannot Cuff yourself!"); return 1; }
						   if(PlayerCuffed[giveplayerid] == 1 || GetPlayerSpecialAction(giveplayerid) == SPECIAL_ACTION_HANDSUP)
						   {
						       GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
							   GetPlayerName(playerid, sendername, sizeof(sendername));
						       format(string, sizeof(string), "* You were Cuffed by %s, till uncuff.", sendername);
							   SendClientMessage(giveplayerid, COLOR_LIGHTBLUE, string);
							   format(string, sizeof(string), "* You Cuffed %s, till uncuff.", giveplayer);
							   SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
							   format(string, sizeof(string), "* %s Hand Cuffs %s, so he wont go anywhere.", sendername ,giveplayer);
							   ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
							   GameTextForPlayer(giveplayerid, "~r~Cuffed", 2500, 3);
							   TogglePlayerControllable(giveplayerid, 0);
							   ApplyAnimation(giveplayerid,"ped","cower",1,1,0,0,0,0);
							   ApplyAnimation(giveplayerid,"ped","cower",1,1,0,0,0,0);
							   PlayerCuffed[giveplayerid] = 2;
							   PlayerCuffedTime[giveplayerid] = 9999;
						   }
                           else
				           {
					          SendClientMessage(playerid, COLOR_GREY, "   That player isn't Restrained !");
					          return 1;
				           }
				       }
				       else
				       {
				          SendClientMessage(playerid, COLOR_GREY, "   That player is not near you !");
				          return 1;
				       }
			       }
				}
				else
				{
				   SendClientMessage(playerid, COLOR_GREY, "   That player is Offline !");
				   return 1;
				}
			}
			else
			{
				SendClientMessage(playerid, COLOR_GREY, "   You are not a LVPD / FBI / LSPD!");
			}
	   }
	   return 1;
Reply
#5

Code:
if(strcmp(cmd, "/cuff", true) == 0) //By Raz0r
	{
	   if(IsPlayerConnected(playerid))
	   {
			if(gTeam[playerid] == 2 || IsACop(playerid))
			{
			    tmp = strtok(cmdtext, idx);
				if(!strlen(tmp)) {
					SendClientMessage(playerid, COLOR_WHITE, "USAGE: /cuff [Playerid/PartOfName]");
					return 1;
				}
				giveplayerid = ReturnUser(tmp);
			    if(IsPlayerConnected(giveplayerid))
				{
				   if(giveplayerid != INVALID_PLAYER_ID)
				   {
				       if(gTeam[giveplayerid] == 2 || IsACop(giveplayerid))
				       {
				           SendClientMessage(playerid, COLOR_GREY, "   You can't Cuff Cops !");
					       return 1;
				       }
				       if (ProxDetectorS(8.0, playerid, giveplayerid))
				       {
						   if(giveplayerid == playerid) { SendClientMessage(playerid, COLOR_GREY, "You cannot Cuff yourself!"); return 1; }
						       GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
							   GetPlayerName(playerid, sendername, sizeof(sendername));
						       format(string, sizeof(string), "* You were Cuffed by %s, till uncuff.", sendername);
							   SendClientMessage(giveplayerid, COLOR_LIGHTBLUE, string);
							   format(string, sizeof(string), "* You Cuffed %s, till uncuff.", giveplayer);
							   SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
							   format(string, sizeof(string), "* %s Hand Cuffs %s, so he wont go anywhere.", sendername ,giveplayer);
							   ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
							   GameTextForPlayer(giveplayerid, "~r~Cuffed", 2500, 3);
							   TogglePlayerControllable(giveplayerid, 0);
							   ApplyAnimation(giveplayerid,"ped","cower",1,1,0,0,0,0);
							   ApplyAnimation(giveplayerid,"ped","cower",1,1,0,0,0,0);
							   PlayerCuffed[giveplayerid] = 2;
							   PlayerCuffedTime[giveplayerid] = 9999;
				       }
				       else
				       {
				          SendClientMessage(playerid, COLOR_GREY, "   That player is not near you !");
				          return 1;
				       }
			       }
				}
				else
				{
				   SendClientMessage(playerid, COLOR_GREY, "   That player is Offline !");
				   return 1;
				}
			}
			else
			{
				SendClientMessage(playerid, COLOR_GREY, "   You are not a LVPD / FBI / LSPD!");
			}
	   }
	   return 1;
}

Code:
if(strcmp(cmd, "/arrest", true) == 0)
	{
	    if(IsPlayerConnected(playerid))
	   	{
			if(gTeam[playerid] == 2  || IsACop(playerid))
			{
				if(OnDuty[playerid] != 1 && PlayerInfo[playerid][pMember] == 1)
				{
				    SendClientMessage(playerid, COLOR_GREY, "{ffffff}you are not on duty!");
				    return 1;
				}
				if(!PlayerToPoint(6.0, playerid, 1526.8973,-1678.2036,5.8906))
				{// Jail spot
				    SendClientMessage(playerid, COLOR_GREY, "{ffffff}Nu esti langa inchisoare,nu poti aresta !");
				    return 1;
				}
				tmp = strtok(cmdtext, idx);
				if(!strlen(tmp))
				{
					SendClientMessage(playerid, COLOR_GRAD2, " {FFA500}[INFO]:{ffffff} /arrest [price] [time (minutes)] [bail (0=no 1=yes)] [bailprice]");
					return 1;
				}
				moneys = strval(tmp);
				if(moneys < 1 || moneys > 1000) { SendClientMessage(playerid, COLOR_GREY, "{ffffff}Pretul nu poate fi mai mic de 1$ sau mai mare de 1000$ !"); return 1; }
				tmp = strtok(cmdtext, idx);
				if(!strlen(tmp))
				{
					SendClientMessage(playerid, COLOR_GRAD2, " {FFA500}[INFO]:{ffffff} /arrest [price] [time (minutes)] [bail (0=no 1=yes)] [bailprice]");
					return 1;
				}
				new time = strval(tmp);
				if(time < 1 || time > 6000) { SendClientMessage(playerid, COLOR_GREY, "{ffffff}Secundele arestarii nu pot fi mai putine de 1, sau mai mare de 6000, !"); return 1; }
				tmp = strtok(cmdtext, idx);
				if(!strlen(tmp))
				{
					SendClientMessage(playerid, COLOR_GRAD2, " {FFA500}[INFO]:{ffffff} /arrest [price] [time (minutes)] [bail (0=no 1=yes)] [bailprice]");
					return 1;
				}
				new bail = strval(tmp);
				if(bail < 0 || bail > 1) { SendClientMessage(playerid, COLOR_GREY, "{ffffff}Bail nu poate fi mai putin de 0 sau mai mult de 1 !"); return 1; }
				tmp = strtok(cmdtext, idx);
				if(!strlen(tmp))
				{
					SendClientMessage(playerid, COLOR_GRAD2, " {FFA500}[INFO]:{ffffff} /arrest [price] [time (minutes)] [bail (0=no 1=yes)] [bailprice]");
					return 1;
				}
				new bailprice = strval(tmp);
				if(bailprice < 0 || bailprice > 1000) { SendClientMessage(playerid, COLOR_GREY, "{ffffff}Amenda nu poate fi mai mica de 0$ sau mai mare de 1000$ !"); return 1; }
				new suspect = GetClosestPlayer(playerid);
				if(IsPlayerConnected(suspect))
				{
					if(GetDistanceBetweenPlayers(playerid,suspect) < 5)
					{
						GetPlayerName(suspect, giveplayer, sizeof(giveplayer));
						GetPlayerName(playerid, sendername, sizeof(sendername));
						if(WantedLevel[suspect] < 1) return SendClientMessage(playerid, COLOR_GREY, "{ffffff}Playerul trebuie sa aiba macar level 1 wanted !");
						if(IsACop(suspect)) return SendClientMessage(playerid,COLOR_GREY,"Nu poti aresta politisti");
						format(string, sizeof(string), "* You arrested %s !", giveplayer);
						SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
						GivePlayerMoney(suspect, -moneys);
						new string2[256];
						format(string2,sizeof(string2), "Ai fost taxat cu %d $", moneys);
						SendClientMessage(suspect,COLOR_GRAD2,string2);
						format(string, sizeof(string), "arrested by %s ~n~    for $%d", sendername, moneys);
						GameTextForPlayer(suspect, string, 5000, 5);
						ResetPlayerWeapons(suspect);
						if(PlayerInfo[playerid][pMember]==1||PlayerInfo[playerid][pLeader]==1)
						{
							format(string, sizeof(string), "<< Ofiterul %s a arestat suspectul %s >>", sendername, giveplayer);
							OOCNews(COLOR_RED, string);
						}
						else if(PlayerInfo[playerid][pMember]==2||PlayerInfo[playerid][pLeader]==2)
						{
							format(string, sizeof(string), "<<Agentul FBI %s a arestat suspectul %s >>", sendername, giveplayer);
							OOCNews(COLOR_RED, string);
						}
						else if(PlayerInfo[playerid][pMember]==3||PlayerInfo[playerid][pLeader]==3)
						{
							format(string, sizeof(string), "<< Soldatul %s a arestat suspectul %s >>", sendername, giveplayer);
							OOCNews(COLOR_RED, string);
						}
						new rand;
      					SetPlayerInterior(suspect, 6 );
    				    rand = random(sizeof(gTurmaProg));
    				    SetPlayerPos(suspect,264.6288,77.5742,1001.0391);
            			SetPlayerWorldBounds(suspect,219.44728088379,69.380714416504,1005.0390625); //Оa~?a`?дa*нe`a* i"?оa~. зонu^
						PlayerInfo[suspect][pJailTime] = time;
						if(bail == 1)
						{
							JailPrice[suspect] = bailprice;
							format(string, sizeof(string), "Ai fost arestat pentru %d secunde. Cautiune: $%d", PlayerInfo[suspect][pJailTime], JailPrice[suspect]);
							SendClientMessage(suspect, COLOR_LIGHTBLUE, string);
						}
						else
						{
						    JailPrice[suspect] = 0;
							format(string, sizeof(string), "Ai fost arestat pentru %d secunde. Cautiune: 0", PlayerInfo[suspect][pJailTime]);
							SendClientMessage(suspect, COLOR_LIGHTBLUE, string);
						}
						PlayerInfo[suspect][pJailed] = 1;
				        PlayerInfo[suspect][pArrested] += 1;
						SetPlayerFree(suspect,playerid, "ai fost arestat");
						WantedPoints[suspect] = 0;
						WantedLevel[suspect] = 0;
						WantLawyer[suspect] = 1;
					}//distance
				}//not connected
				else
				{
				    SendClientMessage(playerid, COLOR_GREY, "{ffffff}Nu exista acest player");
				    return 1;
				}
			}
			else
			{
			    SendClientMessage(playerid, COLOR_GREY, "{ffffff}Nu esti Cop / FBI / National Guard !");
			    return 1;
			}
		}//not connected
		return 1;
}


Vezi ca,,,,,comenzile care le-ai dat tu,le-ai dat pana unde scrie "return 1;". Dupa "return 1;" mai este o acolada "}" cu un rand mai jos,care acea acoloada "inchide" comanda.

Dupa ce-l aresteaza,il baga in celula,si ii scrie playerului arestat in chat "Ai fost taxat cu %d $". Daca banii care ii scrie lui ca i-a luat sunt cat ai setat tu sa-i ia la /arrest,atunci e in regula !!
Reply
#6

pai lui ii arata, dar problema ca nu ii ia. de aratat arata corect, dar degeaba. iata codurile dupa return1;

/arrest
Code:
aici urmeaza deja comanda /contract deci am postat intreg codul sau lipseste in sursa
/cuff
Code:
urmeaza comanda /carcuff si scrie ca tre sa folosesc /cuff

return 1;
    }
    if(strcmp(cmd, "/carcuff", true) == 0)
nu cred ca are rost sa postez codul dupa return1; daca urmeaza alte comenzi
Reply
#7

LOOOL.. eu m-am referit la altceva =))

dupa return1; mai ai "}" ,care inchide comanda respectiva... tu cand ne-ai dat comenzile,ne-ai dat pana la return 1;,eu ti-am zis ca trebuie sa dai pana la "}" (unde se inchide comanda),ca sa nu te incurci cand o pui la loc modificata cum ti-o dam noi ..... la asta m-am referit...


Deci sa inteleg ca ,,, /cuff e in regula,, la /arrest te da in celula,dar nu ii ia banii...


Incearca: si vezi daca ii ia banii


Code:
if(strcmp(cmd, "/arrest", true) == 0)
    {
        if(IsPlayerConnected(playerid))
        {
            if(gTeam[playerid] == 2  || IsACop(playerid))
            {
                if(OnDuty[playerid] != 1 && PlayerInfo[playerid][pMember] == 1)
                {
                    SendClientMessage(playerid, COLOR_GREY, "{ffffff}you are not on duty!");
                    return 1;
                }
                if(!PlayerToPoint(6.0, playerid, 1526.8973,-1678.2036,5.8906))
                {// Jail spot
                    SendClientMessage(playerid, COLOR_GREY, "{ffffff}Nu esti langa inchisoare,nu poti aresta !");
                    return 1;
                }
                tmp = strtok(cmdtext, idx);
                if(!strlen(tmp))
                {
                    SendClientMessage(playerid, COLOR_GRAD2, " {FFA500}[INFO]:{ffffff} /arrest [price] [time (minutes)] [bail (0=no 1=yes)] [bailprice]");
                    return 1;
                }
                moneys = strval(tmp);
                if(moneys < 1 || moneys > 1000) { SendClientMessage(playerid, COLOR_GREY, "{ffffff}Pretul nu poate fi mai mic de 1$ sau mai mare de 1000$ !"); return 1; }
                tmp = strtok(cmdtext, idx);
                if(!strlen(tmp))
                {
                    SendClientMessage(playerid, COLOR_GRAD2, " {FFA500}[INFO]:{ffffff} /arrest [price] [time (minutes)] [bail (0=no 1=yes)] [bailprice]");
                    return 1;
                }
                new time = strval(tmp);
                if(time < 1 || time > 6000) { SendClientMessage(playerid, COLOR_GREY, "{ffffff}Secundele arestarii nu pot fi mai putine de 1, sau mai mare de 6000, !"); return 1; }
                tmp = strtok(cmdtext, idx);
                if(!strlen(tmp))
                {
                    SendClientMessage(playerid, COLOR_GRAD2, " {FFA500}[INFO]:{ffffff} /arrest [price] [time (minutes)] [bail (0=no 1=yes)] [bailprice]");
                    return 1;
                }
                new bail = strval(tmp);
                if(bail < 0 || bail > 1) { SendClientMessage(playerid, COLOR_GREY, "{ffffff}Bail nu poate fi mai putin de 0 sau mai mult de 1 !"); return 1; }
                tmp = strtok(cmdtext, idx);
                if(!strlen(tmp))
                {
                    SendClientMessage(playerid, COLOR_GRAD2, " {FFA500}[INFO]:{ffffff} /arrest [price] [time (minutes)] [bail (0=no 1=yes)] [bailprice]");
                    return 1;
                }
                new bailprice = strval(tmp);
                if(bailprice < 0 || bailprice > 1000) { SendClientMessage(playerid, COLOR_GREY, "{ffffff}Amenda nu poate fi mai mica de 0$ sau mai mare de 1000$ !"); return 1; }
                new suspect = GetClosestPlayer(playerid);
                if(IsPlayerConnected(suspect))
                {
                    if(GetDistanceBetweenPlayers(playerid,suspect) < 5)
                    {
                        GetPlayerName(suspect, giveplayer, sizeof(giveplayer));
                        GetPlayerName(playerid, sendername, sizeof(sendername));
                        if(WantedLevel[suspect] < 1) return SendClientMessage(playerid, COLOR_GREY, "{ffffff}Playerul trebuie sa aiba macar level 1 wanted !");
                        if(IsACop(suspect)) return SendClientMessage(playerid,COLOR_GREY,"Nu poti aresta politisti");
                        format(string, sizeof(string), "* You arrested %s !", giveplayer);
                        SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
                        GetPlayerMoney(suspect, moneys);
                        new string2[256];
                        format(string2,sizeof(string2), "Ai fost taxat cu %d $", moneys);
                        SendClientMessage(suspect,COLOR_GRAD2,string2);
                        format(string, sizeof(string), "arrested by %s ~n~    for $%d", sendername, moneys);
                        GameTextForPlayer(suspect, string, 5000, 5);
                        ResetPlayerWeapons(suspect);
                        if(PlayerInfo[playerid][pMember]==1||PlayerInfo[playerid][pLeader]==1)
                        {
                            format(string, sizeof(string), "<< Ofiterul %s a arestat suspectul %s >>", sendername, giveplayer);
                            OOCNews(COLOR_RED, string);
                        }
                        else if(PlayerInfo[playerid][pMember]==2||PlayerInfo[playerid][pLeader]==2)
                        {
                            format(string, sizeof(string), "<<Agentul FBI %s a arestat suspectul %s >>", sendername, giveplayer);
                            OOCNews(COLOR_RED, string);
                        }
                        else if(PlayerInfo[playerid][pMember]==3||PlayerInfo[playerid][pLeader]==3)
                        {
                            format(string, sizeof(string), "<< Soldatul %s a arestat suspectul %s >>", sendername, giveplayer);
                            OOCNews(COLOR_RED, string);
                        }
                        new rand;
                        SetPlayerInterior(suspect, 6 );
                        rand = random(sizeof(gTurmaProg));
                        SetPlayerPos(suspect,264.6288,77.5742,1001.0391);
                        SetPlayerWorldBounds(suspect,219.44728088379,69.380714416504,1005.0390625); //Оa~?a`?дa*нe`a* i"?оa~. зонu^
                        PlayerInfo[suspect][pJailTime] = time;
                        if(bail == 1)
                        {
                            JailPrice[suspect] = bailprice;
                            format(string, sizeof(string), "Ai fost arestat pentru %d secunde. Cautiune: $%d", PlayerInfo[suspect][pJailTime], JailPrice[suspect]);
                            SendClientMessage(suspect, COLOR_LIGHTBLUE, string);
                        }
                        else
                        {
                            JailPrice[suspect] = 0;
                            format(string, sizeof(string), "Ai fost arestat pentru %d secunde. Cautiune: 0", PlayerInfo[suspect][pJailTime]);
                            SendClientMessage(suspect, COLOR_LIGHTBLUE, string);
                        }
                        PlayerInfo[suspect][pJailed] = 1;
                        PlayerInfo[suspect][pArrested] += 1;
                        SetPlayerFree(suspect,playerid, "ai fost arestat");
                        WantedPoints[suspect] = 0;
                        WantedLevel[suspect] = 0;
                        WantLawyer[suspect] = 1;
                    }//distance
                }//not connected
                else
                {
                    SendClientMessage(playerid, COLOR_GREY, "{ffffff}Nu exista acest player");
                    return 1;
                }
            }
            else
            {
                SendClientMessage(playerid, COLOR_GREY, "{ffffff}Nu esti Cop / FBI / National Guard !");
                return 1;
            }
        }//not connected
        return 1;
}
Reply
#8

tot nu ii ia bani. acum cand vreau sa-i dau /uncuff imi zice ca nu sunt in national guard desi eu sunt
Reply
#9

da ii din cauza ca ii facut doar pt factiunea pd nu si pt fbi, ng sau ce factiuni de politii ai u
Reply
#10

ok, sa zicem. dar nici macar nu il baga in celula. normal ar fi sa apara acolo si sa-i dea timp in functe de wanted lvl, dar el apare inauntru la usa de la iesirea din LSPD si atat. daca n-ar fi cuffed, ar pleca imediat )
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)