Help script /rob /ar nearest player
#1

Het Guys
pls can someone make me a /rob and /arrest nearest player Script
i'm using sscanf and zcmd
thanks
Reply
#2

Can we get some info on what variables you're using that would affect these commands? Such as how you're detecting wanted levels or how much money you want people to do be able to rob.
Reply
#3

This section is for help dude not for people to write you scripts.
Reply
#4

https://sampforum.blast.hk/showthread.php?tid=41161
Reply
#5

This ~!WAS NOT!~ tested but should work correctly.

If a player is in range of 4 meters within another player it'll cuff him, otherwise it'll write that no one's there.

CODE:


Код:
CMD:arrest(playerid, params[])
{
	new Float:x, Float:y, Float:z;
	for(new i = 0; i < MAX_PLAYERS; i++)
	{
		GetPlayerPos(playerid, x, y, z);

		if(IsPlayerInRangeOfPoint(i, 4,x, y, z))
		{
			SetPlayerSpecialAction(i, SPECIAL_ACTION_CUFFED);
		    SetPlayerAttachedObject(i, 0, 19418, 6, -0.027999, 0.051999, -0.030000, -18.699926, 0.000000, 104.199928, 1.489999, 3.036000, 1.957999);
		    EditAttachedObject(i, 0);
		}
		else
		{
			SendClientMessage(playerid, -1, "There's no one around you!");
		}
	}
	return 1;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)