25.12.2010, 22:22
Well Started to go back to some NPCs today and was wondering how to get the ID of a NPC.
This was posted on one of my old topics on the same thing (3 or 4 months ago). I figured how to get it then just now I forgot. Any type help appreciated.
pawn Code:
public OnPlayerUpdate(playerid)
{
new Float:x,Float:y,Float:z;
GetPlayerPos(YOUR_NPC_ID,x,y,z);
if(IsPlayerInRangeOfPoint(playerid,3.0,x,y,z))
{
SendClientMessage(playerid,0xFFFFFFFF,"NPC Says: hello, Im NPC, what can I do for you?");
}
return 1;
}