Backup command.
#6

Quote:
Originally Posted by DaniceMcHarley
Посмотреть сообщение
Well that's what I made but I am looking forward to update the checkpoint, I mean when the player moves the checkpoint will update at his position, how to do that?

Код:
CMD:backup(playerid,params[])
{
	if(pInfo[playerid][LSPD] >= 1)
	{
		new string[126],Float:x, Float:y, Float:z;
		format(string,sizeof(string),"[Dispatch]: %s is requesting backup at %s!",RemoveUnderScore(playerid),GetPlayerArea(playerid));
		SendCopMessage(COLOR_BLUE,string);
		GetPlayerPos(playerid,x,y,z);
		SetPlayerCheckpoint(playerid,x,y,z,5.0);
	}
}
Look for ShowPlayerMarkers under OnGameModeInit if its valid and change it to PLAYER_MARKERS_MODE_GLOBAL
if this isn't exits on your gamemode so just create it under OngameModeinit ShowPlayerMarkers(PLAYER_MARKERS_MODE_GLOBAL);
then put on your backup command:

Код:
new Float:slx, Float:sly, Float:slz;
GetPlayerPos(giveplayerid, slx, sly, slz);
SetPlayerMarkerForPlayer(playerid, giveplayerid, 0xFF0000AA); // 0xFF0000AA - whatever color you want - it will be keep tracking your target if he moves or changing positions.
Reply


Messages In This Thread
Backup command. - by DaniceMcHarley - 08.09.2013, 07:29
Re: Backup command. - by Admigo - 08.09.2013, 07:35
Re: Backup command. - by DaniceMcHarley - 08.09.2013, 07:38
Re: Backup command. - by DaniceMcHarley - 08.09.2013, 07:45
Re: Backup command. - by Fierro - 08.09.2013, 17:05
Re: Backup command. - by Lidor124 - 08.09.2013, 18:15

Forum Jump:


Users browsing this thread: 3 Guest(s)