SA-MP Forums Archive
/stop Command - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: /stop Command (/showthread.php?tid=349217)



/stop Command - Stereotype - 08.06.2012

How to make

Code:
if (gTeam[giveplayerid] != 2)
and if player enter /stopcar

to print in radius of 30


Police Officer says : Stop you'r car and show you'r licences (/sl)



EDIT Done

Code:
if(strcmp("/stopcar", cmdtext, true, 10) == 0)
	{
		if(PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pLeader] == 1 || PlayerInfo[playerid][pMember] == 2 || PlayerInfo[playerid][pLeader] == 2 || PlayerInfo[playerid][pMember] == 3 || PlayerInfo[playerid][pLeader] == 3)
		{
 			new string[256];
		    new sendername[MAX_PLAYER_NAME];
			GetPlayerName(playerid, sendername, sizeof(sendername));
			format(string, sizeof(string), "*Policajac %s vam naredjuje da zaustavite auto.", sendername);
			ProxDetector(45.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
		}
		else
		{
		    SendClientMessage(playerid, WHITE, "("COL_RED"Greska{FFFFFF}!) Niste clan Drzavnih Agencija!");
		}
		return 1;
	}