Jump to content
Sign in to follow this  
tyrspawn

Plane script refuses to work, no idea why

Recommended Posts

_plane = [[getPos ingress select 0, getPos ingress select 1, (getPos ingress select 2) + 1000], 360, "An2_2_TK_CIV_EP1", CIVILIAN] call bis_fnc_spawnvehicle; 
transportPlane = _plane select 0;
_planeGroup = _plane select 2;

transportPlane flyInHeight 1000;
_planeGroup setBehaviour "CARELESS";
wp1 = _planeGroup addwaypoint [(getpos dropoff), 5];
wp1 setwaypointtype "MOVE";

ingress is a game logic where the plane is supposed to fly in from, dropoff is a game logic where i want it to fly to.

It simply doesn't work.

The plane spawns in, then it just flies in a circle around its spawn position. After 2 hours of pulling my hair out over this, I am asking for help.

Share this post


Link to post
Share on other sites

_plane = [[getPos ingress select 0, getPos ingress select 1, (getPos ingress select 2) + 1000], 360, "An2_2_TK_CIV_EP1", CIVILIAN] call bis_fnc_spawnvehicle; 
transportPlane = _plane select 0;
_planeGroup = _plane select 2;

transportPlane flyInHeight 1000;
_planeGroup setBehaviour "CARELESS";
wp1 = _planeGroup addwaypoint [(getpos dropoff), 5];
wp1 setwaypointtype "MOVE";

       _pilot = driver transportPlane;
       _pilot domove (getWPPos wp1);

I added 2 lines at bottom this should work, also using flyinheight 1000 is problematic for AI, if still same isse with my extra lines in script try lowering flyinheight.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×