OFPEC Forum
Editors Depot - Mission Editing and Scripting => ArmA - Editing/Scripting General => Topic started by: HedgeHog on 13 Oct 2008, 23:41:26
-
If I want to make some units reach the player's position (wherever he is), which command should I use?
I want a chopper to pursue the player and to fire on him wherever he is, so that's more difficult to hide yourself because the enemy will chase you everywhere.
Basically, i need the same function used by the command domove getmarkerpos "pos", but with the player position instead of the markers.
I hope I managed to explain what I need.
Thank you in advance! :D
-
Then just use getPos vehicle player instead of getMarkerPos
-
What's the right syntax?
This domove getpos vehicle or what? I keep getting error messages. :dunno:
-
// Pursue.sqf
// res = [my_heli]execVM "pursue.sqf";
_pursuer = _this select 0;
while {alive _pursuer} do
{
_pursuer doMove (getPos vehicle player);
if ((_pursuer distance (vehicle player)) < 1000) then
{
(group driver _pursuer) reveal (vehicle player);
};
Sleep 10;
};