Control NPCs using Paths? - 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: Control NPCs using Paths? (
/showthread.php?tid=351532)
Control NPCs using Paths? -
Programie - 16.06.2012
Hi,
is there a way to control NPCs using the San Andreas paths (e.g. by using
Gamer_Z's GPS Plugins)?
I want to make some public driving services like taxis. If you enter the car you should be able to select a target where the taxi should drive to.
Some ideas?
Re: Control NPCs using Paths? -
WillyP - 16.06.2012
I'm sure I saw a FS with NPC's following the San Andreas nodes, almost asif you're in singleplayer as everything was re-created with NPC's. However I can't find it :/ But you probably could do this
Re: Control NPCs using Paths? -
Programie - 16.06.2012
My first idea was to control the NPC from the gamemode using SetPlayerPos. But that doesn't work...
Another way: SetVehiclePos (Will try it now).
//EDIT: The problem is, I can get the NPC to enter the vehicle using PutPlayerInVehicle. And SetVehicleVelocity only works with occupied vehicles...
Maybe we just need such a feature in the next SA-MP release.