SA-MP Forums Archive
NPC Job - 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: NPC Job (/showthread.php?tid=613171)



NPC Job - HoangNam - 25.07.2016

Some servers dont use pickup and labeltext to joinjob. They use NPCs. NPCs do nothing. Stand and wear skin. When we click RMB (Rigth Mouse) with Y, we will see the dialog with joinjob, quitjob. Who have it, plz share 4 me. Sorry for my bad English.


Re: NPC Job - Threshold - 25.07.2016

These are not actually NPCs, they are called 'Actors'.

You can create an actor using CreateActor.

You can also use OnPlayerKeyStateChange to detect if a player is pressing 'KEY_YES' (default button 'Y'), and then use GetPlayerTargetActor to see if that player is also holding RMB (aiming / targeting) at an actor.