Jump to content

Recommended Posts

477688_405750279445296_209155250_o_zpsc3db31af.jpg

Description:

In this extraction example you pop smoke or throw an IR strobe then use radio 0-0-1 to call for an extraction helicopter. The extraction position is based around the position of the object that was thrown. Using Ruebes randomCirlcePositions the function will find the safest landing spot based on distance from other objects and the gradient slope. Keep in mind that the safest position could be several hundred meters away from the smoke. We dont want the helicopter to land on buildings or in trees.

After a safe position is found for landing the helicopter will spawn in, move to the position to land, and open its doors. The helicopter will then move to an already designated landing zone and drop off the group then return to its original spawn position and cleanup the helicopter, crew, and group.

Parameters:

/* 
   Filename: fn_extraction.sqf - Version 1.1 

   Author: cobra4v320 

   Description: 
   * Spawns a helicopter at a designated location.  
   * The helicopter moves to another designated location to pick up soldiers. 
   * Prior to the helicopter touching down it will open both of its doors. When it lifts off it will close its doors. 
   * The helicopter will then move to another designated location and drop off the soldiers. Prior to landing the doors will open.  
   * When the group gets out the doors will close and the helicopter will return to its spawn position to delete the crew, helicopter, and group. 

   Notes:  
   * Requires pre-placed helicopter pads or place the position over a pad that already exists on the map like Camp Rogain or Stratis Airbase 

   Parameter(s): 
   0: GROUP    - group the helicopter will pick up (group) 
   1: STARTPOS - spawn position - can be string or position (array) 
   2: ENDPOS   - drop off position - can be string or position (array) 
   3: HEIGHT   - (optional) the altitude where the HALO will start from (number) 
   4: CAPTIVE  - (optional) true to set the helicopter and crew captive (boolean) 
   5: DAMAGE   - (optional) true to allow the helicopter and crew to be damaged (boolean) 

   Example(s): 
   [group player, markerPos "spawnMrk", markerPos "dropOffMrk"] spawn COB_fnc_extraction 
   [group player, markerPos "spawnMrk", markerPos "dropOffMrk", 50, TRUE, FALSE] spawn COB_fnc_extraction 
*/ 

Function:

//Parameters 
private ["_group","_startPos","_endPos","_height","_captive","_damage"]; 
_group       = [_this, 0, grpNull, [grpNull, objNull]] call BIS_fnc_param; 
_startPos = [_this, 1, [], [[]]] call BIS_fnc_param; 
_endPos   = [_this, 2, [], [[]]] call BIS_fnc_param; 
_height   = [_this, 3, 50, [0]] call BIS_fnc_param; 
_captive  = [_this, 4, false, [false]] call BIS_fnc_param; 
_damage   = [_this, 5, true, [true]] call BIS_fnc_param; 

//Validate parameter count 
if ((count _this) < 3) exitWith {"[Extraction] function requires at least (3) parameters!" call BIS_fnc_error; false}; 

//Validate Parameters 
if (isNull _group) exitWith {"[Extraction] Group (0) parameter must not be null. Accepted: GROUP or OBJECT" call BIS_fnc_error; false}; 
if ((typeName _startPos) != (typeName [])) exitWith {"[Extraction] Position (1) should be an Array!" call BIS_fnc_error; false}; 
if ((count _startPos) < 2) exitWith {"[Extraction] Position (1) should contain at least 2 elements!" call BIS_fnc_error; false}; 
if ((typeName _endPos) != (typeName [])) exitWith {"[Extraction] Position (2) should be an Array!" call BIS_fnc_error; false}; 
if ((count _endPos) < 2) exitWith {"[Extraction] Position (2) should contain at least 2 elements!" call BIS_fnc_error; false}; 
if (_height < 30) exitWith {"[Extraction] height (3) should be at least 30!" call BIS_fnc_error; false}; 

//Object given instead of group 
if (typeName _group == "OBJECT") then { 
   if (_group isKindOf "MAN") then { 
       _group = group _group; 
   } else { 
       if (count crew _group < 1) exitWith { 
           "Vehicle given as GROUP has no crew" call BIS_fnc_error; 
       }; 
       if (!isNull group driver _group) then { 
           _group = group driver _group; 
       } else { 
           if (!isNull group gunner _group) then { 
               _group = group gunner _group; 
           } else { 
               _group = group ((crew _group) select 0); 
           }; 
       }; 
   }; 
}; 

//check for smoke, strobe, default is player position 
//TODO: check for flare 
_signalArray = [];   
_smoke = position player nearObjects ["SmokeShell", 50]; 
_strobe = position player nearObjects ["B_IRstrobe", 50]; 
_signalArray = _signalArray + _smoke;      
_signalArray = _signalArray + _strobe; 

private ["_signal","_signalPos"]; 
if (count _signalArray > 0) then { 
   _signal = _signalArray select 0; 
   _signalPos = position _signal; 
} else { 
   _signalPos = position player; 
}; 

//find safe landing position     
_safePos = []; 
_range = 35; 
_maxGrad = 0.1; 

while {((count _safePos) == 0)} do { 
   _safePos = [ 
       ["position", _signalPos], 
       ["number", 1], 
       ["objDistance", 9], 
       ["range", [0, _range]], 
       ["maxGradient", _maxGrad] 
   ] call RUBE_fnc_randomCirclePositions;  

  _range = _range * 1.25; 
  _maxGrad = _maxGrad + 0.01; 
}; 

//Create the helipad 
private "_extractPos"; 
_extractPos = createVehicle ["Land_HelipadEmpty_F", (_safePos select 0), [], 0, "NONE"]; 

//Create the helicopter based on groups side 
private "_heliContainer"; 
switch (side _group) do { 
   case blufor: 
   { 
       _heliContainer = [[_startPos select 0, _startPos select 1, _height], [_startPos, _extractPos] call BIS_fnc_dirTo, "B_Heli_Transport_01_F", blufor] call BIS_fnc_spawnVehicle; 
   }; 
   case opfor: 
   { 
       _heliContainer = [[_startPos select 0, _startPos select 1, _height], [_startPos, _extractPos] call BIS_fnc_dirTo, "O_Heli_Light_02_F", opfor] call BIS_fnc_spawnVehicle; 
   }; 
   case independent: 
   { 
       _heliContainer = [[_startPos select 0, _startPos select 1, _height], [_startPos, _extractPos] call BIS_fnc_dirTo , "I_Heli_light_03_F", independent] call BIS_fnc_spawnVehicle; 
   }; 
}; 

private ["_heli","_heliGroup"]; 
_heli = _heliContainer select 0; 
_heliGroup = _heliContainer select 2; 

//height & speed 
private "_dir"; 
_dir = direction _heli; 
_heli setVelocity [sin (_dir) * 50, cos (_dir) * 50, 0]; 
_heli flyInHeight _height; 

_heliGroup allowFleeing 0; 
_heli allowDamage _damage; 
_heli setCaptive _captive;  

//turn off collision lights 
[_heli] spawn { 
   private "_heli"; 
   _heli = _this select 0; 

   while {alive _heli} do {  
       _heli action ["collisionlightOff", _heli]; 
       sleep 0.01; 
   }; 
}; 

//Add the waypoints 
private "_wp1"; 
_wp1 = [_heliGroup, position _extractPos, "LOAD", "CARELESS", "YELLOW", "FULL", "FILE", 0, ["true", "_heli = vehicle this; _heli land 'GET IN'; {_heli animateDoor [_x,1]} forEach ['door_back_L','door_back_R','door_L','door_R']"], true] call COB_fnc_addWaypoint; 

waitUntil { {_x in _heli} count (units _group) == {alive _x} count (units _group) }; 
{_heli animateDoor [_x,0]} forEach ["door_back_L","door_back_R","door_L","door_R"]; 
_heli lock true; 
deleteVehicle _extractPos; 

private "_wp2"; 
_wp2 = [_heliGroup, _endPos, "UNLOAD", "CARELESS", "YELLOW", "FULL", "FILE", 0, ["true", "_heli = vehicle this; _heli land 'GET OUT'; {_heli animateDoor [_x,1]} forEach ['door_back_L','door_back_R','door_L','door_R']; _heli lock false"], true] call COB_fnc_addWaypoint; 

waitUntil { {_x in _heli} count (units _group) < 1 }; 
_heli lock true; 
{_heli animateDoor [_x,0]} forEach ["door_back_L","door_back_R","door_L","door_R"]; 
waitUntil { {_x distance _heli > 15} count (units _group) == {alive _x} count (units _group)}; 

private "_wp3"; 
_wp3 = [_heliGroup, _startPos , "MOVE", "CARELESS", "BLUE", "FULL", "FILE", 0, ["true", "_group = group this; _heli = vehicle this; _units = crew _heli; {deleteVehicle _x} forEach _units; deleteVehicle _heli; deleteGroup _group"], true] call COB_fnc_addWaypoint; 

//return value 
if (!isNull _heli) then { 
   ["[Extraction] function vehicle created."] call BIS_fnc_log;  
   true 
} else { 
   "[Extraction] function failed to create vehicle, make sure the wanted side center exists." call BIS_fnc_error;     
   false 
}; 

Change Log:

Version 1.1

  • Fixed - the function now checks for either smoke or IR strobe
  • Added - several more checks at the beginning and end of the function to ensure it is running properly

Version 1.0 - released

Future Updates

  • Add radio transmissions
  • Add a check for flares

Download:

mediaFire

Edited by cobra4v320
  • Like 1

Share this post


Link to post
Share on other sites

Thanks! I've been working on something similar but you've included some nice features.

Share this post


Link to post
Share on other sites

Working on adding sounds, the same sound from the modules/ supports/ transport.

Share this post


Link to post
Share on other sites

Some of you might find this useful. This will detect whether or not smoke or an IR strobe is nearby then give you its position. At some point I will add flares. If it doesnt detect either it defaults to the players position. It uses Ruebes randomcirclepositions which can be found in the first post. If anybody knows how to do this better or cleaner Im all ears.

_signalArray = [];  
_smoke = position player nearObjects ["SmokeShell", 50];
_strobe = position player nearObjects ["B_IRstrobe", 50];
_signalArray = _signalArray + _smoke;	 
_signalArray = _signalArray + _strobe;

private ["_signal","_signalPos"];
if (count _signalArray > 0) then {
_signal = _signalArray select 0;
_signalPos = position _signal;
} else {
_signalPos = position player;
};

_safePos = [];
_range = 35;
_maxGrad = 0.1;

while {((count _safePos) == 0)} do {
   _safePos = [
["position", _signalPos],
["number", 1],
["objDistance", 9],
["range", [0, _range]],
["maxGradient", _maxGrad]
   ] call RUBE_fnc_randomCirclePositions; 
  _range = _range * 1.25;
  _maxGrad = _maxGrad + 0.01;
};

private "_extractPos";
_extractPos = createVehicle ["Land_HelipadSquare_F", (_safePos select 0), [], 0, "NONE"];

---------- Post added at 09:32 ---------- Previous post was at 08:30 ----------

Here is the updated script that checks for smoke or an IR strobe. Still have to add in radio transmissions. The first post and example mission have been updated. Any feedback would be appreciated.

/*
Filename: fn_extraction.sqf - Version 1.1

Author: cobra4v320

Description:
* Spawns a helicopter at a designated location. 
* The helicopter moves to another designated location to pick up soldiers.
* Prior to the helicopter touching down it will open both of its doors. When it lifts off it will close its doors.
* The helicopter will then move to another designated location and drop off the soldiers. Prior to landing the doors will open. 
* When the group gets out the doors will close and the helicopter will return to its spawn position to delete the crew, helicopter, and group.

Notes: 
* Requires pre-placed helicopter pads or place the position over a pad that already exists on the map like Camp Rogain or Stratis Airbase

Parameter(s):
0: GROUP    - group the helicopter will pick up (group)
1: STARTPOS - spawn position - can be string or position (array)
2: ENDPOS   - drop off position - can be string or position (array)
3: HEIGHT   - (optional) the altitude where the HALO will start from (number)
4: CAPTIVE  - (optional) true to set the helicopter and crew captive (boolean)
5: DAMAGE   - (optional) true to allow the helicopter and crew to be damaged (boolean)

Example(s):
[group player, markerPos "spawnMrk", markerPos "dropOffMrk"] spawn COB_fnc_extraction
[group player, markerPos "spawnMrk", markerPos "dropOffMrk", 50, TRUE, FALSE] spawn COB_fnc_extraction
*/

//Parameters
private ["_group","_startPos","_endPos","_height","_captive","_damage"];
_group 	  = [_this, 0, grpNull, [grpNull, objNull]] call BIS_fnc_param;
_startPos = [_this, 1, [], [[]]] call BIS_fnc_param;
_endPos   = [_this, 2, [], [[]]] call BIS_fnc_param;
_height   = [_this, 3, 50, [0]] call BIS_fnc_param;
_captive  = [_this, 4, false, [false]] call BIS_fnc_param;
_damage   = [_this, 5, true, [true]] call BIS_fnc_param;

//Validate parameter count
if ((count _this) < 3) exitWith {"[Extraction] function requires at least (3) parameters!" call BIS_fnc_error; false};

//Validate Parameters
if (isNull _group) exitWith {"[Extraction] Group (0) parameter must not be null. Accepted: GROUP or OBJECT" call BIS_fnc_error; false};
if ((typeName _startPos) != (typeName [])) exitWith {"[Extraction] Position (1) should be an Array!" call BIS_fnc_error; false};
if ((count _startPos) < 2) exitWith {"[Extraction] Position (1) should contain at least 2 elements!" call BIS_fnc_error; false};
if ((typeName _endPos) != (typeName [])) exitWith {"[Extraction] Position (2) should be an Array!" call BIS_fnc_error; false};
if ((count _endPos) < 2) exitWith {"[Extraction] Position (2) should contain at least 2 elements!" call BIS_fnc_error; false};
if (_height < 30) exitWith {"[Extraction] height (3) should be at least 30!" call BIS_fnc_error; false};

//Object given instead of group
if (typeName _group == "OBJECT") then {
if (_group isKindOf "MAN") then {
	_group = group _group;
} else {
	if (count crew _group < 1) exitWith {
		"Vehicle given as GROUP has no crew" call BIS_fnc_error;
	};
	if (!isNull group driver _group) then {
		_group = group driver _group;
	} else {
		if (!isNull group gunner _group) then {
			_group = group gunner _group;
		} else {
			_group = group ((crew _group) select 0);
		};
	};
};
};

//check for smoke, strobe, default is player position
//TODO: check for flare
_signalArray = [];  
_smoke = position player nearObjects ["SmokeShell", 50];
_strobe = position player nearObjects ["B_IRstrobe", 50];
_signalArray = _signalArray + _smoke;	 
_signalArray = _signalArray + _strobe;

private ["_signal","_signalPos"];
if (count _signalArray > 0) then {
_signal = _signalArray select 0;
_signalPos = position _signal;
} else {
_signalPos = position player;
};

//find safe landing position	
_safePos = [];
_range = 35;
_maxGrad = 0.1;

while {((count _safePos) == 0)} do {
_safePos = [
	["position", _signalPos],
	["number", 1],
	["objDistance", 9],
	["range", [0, _range]],
	["maxGradient", _maxGrad]
] call RUBE_fnc_randomCirclePositions; 

  _range = _range * 1.25;
  _maxGrad = _maxGrad + 0.01;
};

//Create the helipad
private "_extractPos";
_extractPos = createVehicle ["Land_HelipadEmpty_F", (_safePos select 0), [], 0, "NONE"];

//Create the helicopter based on groups side
private "_heliContainer";
switch (side _group) do {
case blufor:
{
	_heliContainer = [[_startPos select 0, _startPos select 1, _height], [_startPos, _extractPos] call BIS_fnc_dirTo, "B_Heli_Transport_01_F", blufor] call BIS_fnc_spawnVehicle;
};
case opfor:
{
	_heliContainer = [[_startPos select 0, _startPos select 1, _height], [_startPos, _extractPos] call BIS_fnc_dirTo, "O_Heli_Light_02_F", opfor] call BIS_fnc_spawnVehicle;
};
case independent:
{
	_heliContainer = [[_startPos select 0, _startPos select 1, _height], [_startPos, _extractPos] call BIS_fnc_dirTo , "I_Heli_light_03_F", independent] call BIS_fnc_spawnVehicle;
};
};

private ["_heli","_heliGroup"];
_heli = _heliContainer select 0;
_heliGroup = _heliContainer select 2;

//height & speed
private "_dir";
_dir = direction _heli;
_heli setVelocity [sin (_dir) * 50, cos (_dir) * 50, 0];
_heli flyInHeight _height;

_heliGroup allowFleeing 0;
_heli allowDamage _damage;
_heli setCaptive _captive; 

//turn off collision lights
[_heli] spawn {
private "_heli";
_heli = _this select 0;

while {alive _heli} do { 
	_heli action ["collisionlightOff", _heli];
	sleep 0.01;
};
};

//Add the waypoints
private "_wp1";
_wp1 = [_heliGroup, position _extractPos, "LOAD", "CARELESS", "YELLOW", "FULL", "FILE", 0, ["true", "_heli = vehicle this; _heli land 'GET IN'; {_heli animateDoor [_x,1]} forEach ['door_back_L','door_back_R','door_L','door_R']"], true] call COB_fnc_addWaypoint;

waitUntil { {_x in _heli} count (units _group) == {alive _x} count (units _group) };
{_heli animateDoor [_x,0]} forEach ["door_back_L","door_back_R","door_L","door_R"];
_heli lock true;
deleteVehicle _extractPos;

private "_wp2";
_wp2 = [_heliGroup, _endPos, "UNLOAD", "CARELESS", "YELLOW", "FULL", "FILE", 0, ["true", "_heli = vehicle this; _heli land 'GET OUT'; {_heli animateDoor [_x,1]} forEach ['door_back_L','door_back_R','door_L','door_R']; _heli lock false"], true] call COB_fnc_addWaypoint;

waitUntil { {_x in _heli} count (units _group) < 1 };
_heli lock true;
{_heli animateDoor [_x,0]} forEach ["door_back_L","door_back_R","door_L","door_R"];
waitUntil { {_x distance _heli > 15} count (units _group) == {alive _x} count (units _group)};

private "_wp3";
_wp3 = [_heliGroup, _startPos , "MOVE", "CARELESS", "BLUE", "FULL", "FILE", 0, ["true", "_group = group this; _heli = vehicle this; _units = crew _heli; {deleteVehicle _x} forEach _units; deleteVehicle _heli; deleteGroup _group"], true] call COB_fnc_addWaypoint;

//return value
if (!isNull _heli) then {
["[Extraction] function vehicle created."] call BIS_fnc_log; 
true
} else {
"[Extraction] function failed to create vehicle, make sure the wanted side center exists." call BIS_fnc_error;	
false
};

Edited by cobra4v320

Share this post


Link to post
Share on other sites

Hello Cobra. Thank you for this nice coding.

I have a problem that i hope you can help me with. I simply can't get the heli to spawn at the placed marker. I have placed markers (spawnMrk and dropOffMrk), changed the parameters and even replaced the heli with one from my selected faction (yes i have tried with the default). I think i have changed the required lines, but it simply wont spawn the heli after i have thrown a smokegrenade and used the radio.

Here is the things i have changed:

//Parameters
private ["_group","_startPos","_endPos","_height","_captive","_damage"];
_group 	  = [_this, 0, group player, [group player, objNull]] call BIS_fnc_param;
_startPos = [_this, 1, [markerPos "spawnMrk"], [[]]] call BIS_fnc_param;
_endPos   = [_this, 2, [markerPos "dropOffMrk"], [[]]] call BIS_fnc_param;
_height   = [_this, 3, 50, [0]] call BIS_fnc_param;
_captive  = [_this, 4, false, [false]] call BIS_fnc_param;
_damage   = [_this, 5, true, [true]] call BIS_fnc_param;

..

//Create the helicopter based on groups side
private "_heliContainer";
switch (side _group) do {
case blufor:
{
	_heliContainer = [[_startPos select 0, _startPos select 1, _height], [_startPos, _extractPos] call BIS_fnc_dirTo, "B_mas_mar_Heli_Transport_01_F", blufor] call BIS_fnc_spawnVehicle;
};

//Heli is changed to a USMC version

Im sure i have somehow ruined this, but i hope you can help :)

/Sorner

Share this post


Link to post
Share on other sites

Nice update Cobra. like the idea for next of the flare. thanks again for this script. I use it in all of my missions

Share this post


Link to post
Share on other sites
Hello Cobra. Thank you for this nice coding.

I have a problem that i hope you can help me with. I simply can't get the heli to spawn at the placed marker. I have placed markers (spawnMrk and dropOffMrk), changed the parameters and even replaced the heli with one from my selected faction (yes i have tried with the default). I think i have changed the required lines, but it simply wont spawn the heli after i have thrown a smokegrenade and used the radio.

Here is the things i have changed:

//Parameters
private ["_group","_startPos","_endPos","_height","_captive","_damage"];
_group 	  = [_this, 0, group player, [group player, objNull]] call BIS_fnc_param;
_startPos = [_this, 1, [markerPos "spawnMrk"], [[]]] call BIS_fnc_param;
_endPos   = [_this, 2, [markerPos "dropOffMrk"], [[]]] call BIS_fnc_param;
_height   = [_this, 3, 50, [0]] call BIS_fnc_param;
_captive  = [_this, 4, false, [false]] call BIS_fnc_param;
_damage   = [_this, 5, true, [true]] call BIS_fnc_param;

..

//Create the helicopter based on groups side
private "_heliContainer";
switch (side _group) do {
case blufor:
{
	_heliContainer = [[_startPos select 0, _startPos select 1, _height], [_startPos, _extractPos] call BIS_fnc_dirTo, "B_mas_mar_Heli_Transport_01_F", blufor] call BIS_fnc_spawnVehicle;
};

//Heli is changed to a USMC version

Im sure i have somehow ruined this, but i hope you can help :)

/Sorner

You dont change the parameters in the function you would change them when spawning the function. Placing the new helicopter like you did is fine.

Change these lines back to what they were:

_startPos   = [_this, 1, [0,0,0], [[]]] call BIS_fnc_param;
_endPos   = [_this, 2, [0,0,0], [[]]] call BIS_fnc_param;

You spawn the function like this:

0 = [group player, markerPos "spawnMrk", markerPos "dropOffMrk"] spawn COB_fnc_extraction

Share this post


Link to post
Share on other sites

Hi cobra, I have some problem!

when I use script in singleplayer or on local server, it work very fine.

but when I upload the mission to my team's dedicated server, it can't work.

the heli can't spawn after I call script.

Do you have this problem?

Edited by a8325811

Share this post


Link to post
Share on other sites

HI, Just wondering, does it work on dedicated server.

Edited by Lightspeed_aust

Share this post


Link to post
Share on other sites

Hi! Nice script!

Can you help me to set this so, there can be only one chopper in air at a time?

Share this post


Link to post
Share on other sites

Soon enough you guys can do it with the aircraft in the pic ;)

  • Like 1

Share this post


Link to post
Share on other sites

I found one of your earlier scripts, and was able to figure out how to call it based on the Information in the other threads. However, this script does not seem to work. For some reason, you can't assign a local variable in an "if" Statement.

I do not know if this is a new Problem, or what, but the helo could never find the pick up Location (because the waypoint could not be created).

I corrected one of your older scripts, and I may try to correct this one as well. If you could explain what is going on, that would help too.

Thanks

I tried calling the script from a Trigger and from the Player unit Init field. Neither worked. How exactly do you call the script?

Thanks for the help and the great script!!

Edited by RASmith1030

Share this post


Link to post
Share on other sites

Quick question - has anyone managed to get this script working in MP? Just tried it with an isserver in the trigger and the helo just disappears after a couple of seconds.

Share this post


Link to post
Share on other sites

Hello!

I was wondering if this was MP compatible and if there was anyway to use a helicopter placed instead of calling one in and then removing it. A persistant helicopter that would stay and base intil called then rtb once its job was complete?

Thanks!

Share this post


Link to post
Share on other sites

Just checking to see if anyone has managed to run this on a dedicated server?

It's a really good script, that works fantastic in single or hosted MP, it's a bit of a shame really that it doesen't work on dedicated.

Share this post


Link to post
Share on other sites

Once I get my dedicated box up and running I will be doing some testing hopefully get this working on a dedicated. No promises though  :D

  • Like 1

Share this post


Link to post
Share on other sites

I'm trying this on the vietnam map, I can spawn the Helicopter but as soon as it spawned it is climbing where it spawns in and does nothing after that. I tried smoke and default behaviour. I changed the heli to a huey but that shouldn't change anything right? It seems that there is something wrong with updating the position or spawing the helipad?

 

Edit: figured it out, high foliage and object heavy maps need to set way smaller distances in the rube function.

Share this post


Link to post
Share on other sites

Hi. This may be a daft question but do I put the markers down on the map and place that script to a file calledfn_extraction.sqf in the mission folder? I'm relatively new to all this and the only way I'm learning is by coming to forums like this or youtube videos.

Share this post


Link to post
Share on other sites

Hi. This may be a daft question but do I put the markers down on the map and place that script to a file calledfn_extraction.sqf in the mission folder? I'm relatively new to all this and the only way I'm learning is by coming to forums like this or youtube videos.

 

The script comes with an example mission, maybe that help you understand how it works.

Share this post


Link to post
Share on other sites

This is fantastic!

thank you very much, however I would like to make a small change...

 

how much work would it take to remove the check to ensure the entire group is in the helo before it takes off and returns to base?

as in: the player is separated from his group, calls for extraction for himself only.

 

I installed it, incorporated it, it works great, even changed the helo to a RHS UH60, but modifying that might be beyond me.

 

i suspect it's related to:

 

waitUntil { {_x in _heli} count (units _group) == {alive _x} count (units _group) };

 

and its a matter of removing that check, however that simply caused the extraction helicopter to momentarily appear and then immediately disappear before even landing

Share this post


Link to post
Share on other sites
waitUntil { {_x in _heli} count (units _group) == {(alive _x) && ((_x distance _heli) < 200)} count (units _group) };

Changing it to that should check to make sure all alive group members within 200m of the helicopter are in the helicopter before taking off.

  • Like 1

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

×