splatsh
Member-
Content Count
123 -
Joined
-
Last visited
-
Medals
Everything posted by splatsh
-
Hi! I have this code that I run when my task is completed [C1,"HMMWV_M2"] call BIS_fnc_supplyDrop Then I get a new mission and so on... Now... if my HMMWV_M2 is destroyed by enemy Can I have something like the reinforcement code that is when you play SOM mission and your squad member got killed. Then you got a new squad member, right. How to make that happend with this HMMWV_M2? Any idea where I can look, and where to start?
-
How to make other group/unit leader
splatsh posted a topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
How to make chopper stand still and wait for "frank"/_group_2 ??? And when "frank" is inside chopper, then chopper go to waypoint "_waypoint_1" Now the chopper is unload the squad, then chopper fly away. frank and car is on there way to the chopper at that time, so I need to get the chopper to wait for him. How to? Here is my code so far. _this = createCenter west; _center_0 = _this; ////////////////////////////////////////////////////////////////////////////////////////////////////// // Create _vehicle_0 _this = createVehicle ["MH60S", [14649.822, 11875.108], [], 0, "FLY"]; _vehicle_0 = _this; _this setDir -73.528984; _this setVehicleVarName "heli"; heli = _this; ////////////////////////////////////////////////////////////////////////////////////////////////////// // Create Group_1 _group_1 = createGroup _center_0; _this = _group_1 createUnit ["USMC_Soldier_Pilot", [14649.822, 11875.108], [], 0, "FLY"]; _unit_1 = _this; _this setDir 182.9581; _this setVehicleVarName "pilot"; pilot = _this; _this setUnitAbility 0.60000002; if (true) then {_group_0 selectLeader _this;}; _this moveInDriver heli; _this = _group_1 createUnit ["USMC_Soldier_Pilot", [14649.822, 11875.108], [], 0, "FLY"]; _unit_1 = _this; _this setDir 182.9581; _this setVehicleVarName "pilot2"; pilot2 = _this; _this setUnitAbility 0.60000002; _this moveInCargo heli; _this = _group_1 createUnit ["USMC_Soldier_Pilot", [14649.822, 11875.108], [], 0, "FLY"]; _unit_2 = _this; _this setVehicleVarName "Gunner1"; Gunner1 = _this; _this setUnitAbility 0.60000002; _this moveInTurret [heli, [0]]; _this = _group_1 createUnit ["USMC_Soldier_Pilot", [14649.822, 11875.108], [], 0, "FLY"]; _unit_3 = _this; _this setVehicleVarName "Gunner2"; Gunner2 = _this; _this setUnitAbility 0.60000002; _this moveInTurret [heli, [1]]; ////////////////////////////////////////////////////////////////////////////////////////////////////// // Waypoint heli pilot team /_group_1 ////////////////////////////////////////////////////////////////////////////////////////////////////// _this = _group_1 addWaypoint [[12078.981, 12720.614], 0]; _this setWaypointType "TR UNLOAD"; _this setWaypointStatements ["true", "{unassignvehicle _x} foreach units Ohara;"]; _waypoint_0 = _this; _this = _group_1 addWaypoint [[14615.212, 12302.575, 0], 0]; _this setWaypointStatements ["true", "hint ""deleteVehicle heli"";"]; _waypoint_1 = _this; ////////////////////////////////////////////////////////////////////////////////////////////////////// // Create _vehicle_1 / M2 _this = createVehicle ["HMMWV_M2", [12737.207, 12256.813], [], 0, "CAN_COLLIDE"]; _vehicle_1 = _this; _this setDir 315.40115; _this setVehicleVarName "M2"; M2 = _this; ////////////////////////////////////////////////////////////////////////////////////////////////////// // Create _group_2 _group_2 = createGroup _center_0; _this = _group_2 createUnit ["FR_Light", [12738.283, 12255.289], [], 0, "CAN_COLLIDE"]; _unit_4 = _this; _this setVehicleVarName "frank"; frank = _unit_4; _this setUnitAbility 0.60000002; if (true) then {_group_2 selectLeader _this;}; ////////////////////////////////////////////////////////////////////////////////////////////////////// // Waypoint M2 team / _group_2 ////////////////////////////////////////////////////////////////////////////////////////////////////// _this = _group_2 addWaypoint [[12737.209, 12256.783], 0]; _this setWaypointType "GETIN NEAREST"; _waypoint_5 = _this; _this = _group_2 addWaypoint [[12696.206, 12299.229], 0]; _this setWaypointStatements ["true", ""]; _waypoint_6 = _this; _this = _group_2 addWaypoint [[12587.527, 12503.487, 0], 0]; _waypoint_7 = _this; _this = _group_2 addWaypoint [[12120.621, 12651.323, 0], 0]; _waypoint_8 = _this; _this = _group_2 addWaypoint [[12024.262, 12668.17, 0], 0]; _this setWaypointType "GETOUT"; _this setWaypointStatements ["true", "unassignVehicle frank;"]; _waypoint_9 = _this; _this = _group_2 addWaypoint [[12078.981, 12720.614], 0]; _this setWaypointType "GETIN NEAREST"; _this setWaypointStatements ["true", "frank assignAsCargo heli; [frank] orderGetIn true;"]; _waypoint_10 = _this; ////////////////////////////////////////////////////////////////////////////////////////////////////// // Create _group_3 _group_3 = createGroup _center_0; _this = _group_3 createUnit ["FR_OHara", [14649.822, 11875.108], [], 0, "CARGO"]; _unit_5 = _this; _this setVehicleVarName "Ohara"; Ohara = _unit_5; _this setUnitAbility 0.60000002; if (true) then {_group_3 selectLeader _this;}; _this moveInCargo [heli, 1]; _this = _group_3 createUnit ["FR_Miles", [14649.822, 11875.108], [], 0, "CARGO"]; _unit_6 = _this; _this setVehicleVarName "Miles"; Miles = _unit_6; _this setUnitAbility 0.60000002; _this moveInCargo [heli, 3]; _this = _group_3 createUnit ["FR_Rodriguez", [14649.822, 11875.108], [], 0, "CARGO"]; _unit_7 = _this; _this setVehicleVarName "Rodriguez"; Rodriguez = _unit_7; _this setUnitAbility 0.60000002; _this moveInCargo [heli, 2]; _this = _group_3 createUnit ["FR_Sykes", [14649.822, 11875.108], [], 0, "CARGO"]; _unit_8 = _this; _this setVehicleVarName "Sykes"; Sykes = _unit_8; _this setUnitAbility 0.60000002; _this moveInCargo [heli, 4]; ////////////////////////////////////////////////////////////////////////////////////////////////////// // Waypoint squad team / _group_3 ////////////////////////////////////////////////////////////////////////////////////////////////////// _this = _group_3 addWaypoint [[12048.579, 12682.741, 0], 0]; _this setWaypointStatements ["true", "[Ohara] join player; [Miles] join player; [Rodriguez] join player; [sykes] join player;"]; _waypoint_2 = _this; -
I am using some of this code: http://forums.bistudio.com/showthread.php?t=77397&highlight=BIS_fnc_supplyDrop By Tajin This is how my code look like now. _spawntype = "HMMWV_M2"; _bpos = C1 ModelToWorld [0,-12,-5.5]; _bomb = _spawntype createVehicle _bpos; _bomb setpos _bpos; _bomb setDir direction _bpos; _chute = "ParachuteMediumWest" createVehicle getpos _bomb; _chute setpos (_bomb ModelToWorld [0,0,3]); _bomb attachTo [_chute,[0,0,0]]; sleep 0.05; Ok, I have a C-130J named C1 on my map who is flying. When my code is in action, there is a spawn of a HMMWV_M2 and its moving towards the ground. But now Chute is there, I cant get this chute to spawn and attachTo the car. Whats wrong?
-
Problem with attachTo
splatsh replied to splatsh's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
_spawntype = "HMMWV_M2"; _bpos = C1 ModelToWorld [0,-12,-5.5]; _bomb = _spawntype createVehicle _bpos; _bomb setpos _bpos; _bomb setDir direction C1; _chute = "ParachuteMediumWest" createVehicle getpos _bomb; _chute setpos (_bomb ModelToWorld [0,0,3]); _bomb attachTo [_chute,[0,0,0]]; sleep 0.05; If u mean this? That did not work. =( -
This works In trigger activation: nul=[] execVM "test.sqf" // test.sqf _this setTriggerStatements ["C1 distance player<= 400;", "[C1,""HMMWV_Armored""] call BIS_fnc_supplyDrop;", ""]; But this wont work. Why? How can I make this to work right? nul=[HMMWV_Armored] execVM "test.sqf" // test.sqf _type = _this select 0; _this setTriggerStatements ["C1 distance player<= 400;", "[C1,""_type""] call BIS_fnc_supplyDrop;", ""]; I have try this to [C1,"_type"] and [C1,_type] But I cant get it to work.
-
setTriggerStatements problem
splatsh replied to splatsh's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Thanks, I will try that later. One more question This works _wpt1 setWaypointStatements ["true", "[medic] join player"]; with this _unit = _group_2 createUnit [_spawntype, _spawnPoint, [], 3, "FORM"]; _unit setVehicleVarName "medic"; medic = _unit; Why is this not working and how to get it to work _wpt1 setWaypointStatements ["true", "[_unit] join player"]; If I can get this to work, I dont need to name my units that I am spawning, it really should help me out if I could get them to join me without names. and I cant get deleteVehicle to work _wpt2 = _group_1 addWaypoint[_spawnPoint,50]; _wpt2 setwaypointtype "MOVE"; _wpt2 setWaypointStatements ["true", "deleteVehicle _vehicle_1"]; My chopper is moving to that _spawnPoint, but they dont delete it. How can I delete stuff when they have arrived to a move point? -
setTriggerStatements problem
splatsh replied to splatsh's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Sorry, still not working _this = createTrigger ["EmptyDetector", [0,0,0]]; _this setTriggerArea [0, 0, 0, true]; _this setTriggerActivation ["NONE", "PRESENT", false]; _this setTriggerStatements ["C1 distance player<= 400;", "[C1,_type] call BIS_fnc_supplyDrop;", ""]; _trigger_0 = _this; hint format ["%1",triggerStatements _trigger_0]; My hint is saying [C1, _type] when I use that. when I use _this setTriggerStatements ["C1 distance player<= 400;", "[C1, ""HMMWV_Armored""] call BIS_fnc_supplyDrop;", ""]; My hint is telling me the right stuff: [C1, HMMWV_Armored] So, I still got something wrong. -
Paradropping from a c130
splatsh replied to sparrow560's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
http://forums.bistudio.com/showthread.php?t=76545&highlight=paradrop -
3d editor... How too synchronize?
splatsh replied to Krutish's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
And the answer is? -
Is make AI pickup car with heli possible?
splatsh posted a topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
How to make a AI to pickup a car with heli and put it down at a place? -
Code split, not work, why? help
splatsh posted a topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Ok, I have this in one other thread, but that thread is about eject, and now my eject are working. But its not working as I would like it to. Check this. Working {unassignvehicle _x;} foreach units _leader; {_x action ["EJECT", _vcl_new];} foreach units _leader; NOT working { unassignvehicle _x; _x action ["EJECT", _vcl_new]; sleep 0.5; } foreach units _leader; I cant get this second code to work. Why cant I that? This code seems to work for others when using in it. But mine is not working, I cant get this sleep to work. Please help. -
I have one chopper named "heli" and in the heli is a soldier named "gunner" chopper is going to a waypoint and when heli is there the soldier is leaving the chopper _wpt0 = _group_0 addWaypoint[position base_heli_land,10]; _wpt0 setwaypointtype "MOVE"; _wpt0 setWaypointStatements ["heli distance heli_land<= 100", "unassignVehicle gunner;"]; and that is fine and working, now the chopper is standing still with engine running, and that is also good. Part 2: I have a vehivle and a driver. They have a waypoint to the same spot as the chopper are standing now. And here is what I want: I want that the chopper is waiting and waiting for the driver in the vehicle to come in the cargo at the chopper. I have a waypoint for the driver, and when done the driver is leave vehicle. _wpt3 = _group_2 addWaypoint[position base_heli_land,30]; _wpt3 setwaypointtype "MOVE"; _wpt3 setWaypointStatements ["true", "unassignVehicle driver;"]; Now, I want that driver is creating a waypoint to get in the chopper. and when driver is in the chopper, the chopper can leave the area. How can I do it?
-
Using timeout on detected by triggers, and deleting triggers.
splatsh replied to mechastalin's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
yeah, but how to set up a triggername in sqf code, can that be done? -
make save, make autosave, how to?
splatsh posted a topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Can I create that the game is saving at a trigger or by code in a sqf file? How does that code look like? (to make a save code) -
Need a bit of help with my first mission
splatsh replied to ltn.ghost's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
wrong post -
I can get out a squad from a chopper with this _waypoint1 = _group_0 addwaypoint[position eject1,250]; _waypoint1 setwaypointtype "MOVE"; _waypoint1 setWaypointStatements ["true", "{unassignvehicle _x;} foreach units ai; {_x action [""EJECT"", heli];} foreach units ai;"]; But the same code dont work with a Vodnik. _waypoint4 setWaypointStatements ["true", "{unassignvehicle _x;} foreach units a2; {_x action [""EJECT"", vodnik];} foreach units a2;"]; ai are the same as a2 and name of vehicle is vodnik instead of heli, same code, but my squad will not get out... how come? ---------- Post added at 09:28 PM ---------- Previous post was at 08:44 PM ---------- Answer: I have forgotten to add "_group_# = CreateGroup East;" at every groups. It works now
-
all new to this, help with script.
splatsh replied to splatsh's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Thanks, but the second one is not working, they dont eject =/ Working {unassignvehicle _x;} foreach units _leader; {_x action ["EJECT", _vcl_new];} foreach units _leader; NOT working { unassignvehicle _x; _x action ["EJECT", _vcl_new]; sleep 0.5; } foreach units _leader; -
all new to this, help with script.
splatsh posted a topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
I have read some, and I am trying to create some stuff. Here I am creating a chopper, and two pilots, and make them to get in. and this works for me. Pilots = CreateGroup East; _vcl_new = "Mi17_rockets_RU" createVehicle [(position start_heli select 0)+1, (position start_heli select 1)+1,0]; _vcl_new setVehicleVarName "heli"; _crewPilot0 = Pilots createUnit ["RU_Soldier_Crew", [(position start_pilot) select 0,(position start_pilot) select 1,0], [], 3, "FORM"]; _crewPilot1 = Pilots createUnit ["RU_Soldier_Crew", [(position start_pilot) select 0,(position start_pilot) select 1,0], [], 3, "FORM"]; _crewPilot0 moveinDriver _vcl_new; _crewPilot1 moveinCargo _vcl_new; Next step is to create a squad. This also works fine for me. GroupSquad1 = CreateGroup East; _leader = GroupSquad1 createUnit ["RU_Soldier_SL", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; _unit = GroupSquad1 createUnit ["RU_Soldier_MG", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; _unit = GroupSquad1 createUnit ["RU_Soldier_AT", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; _unit = GroupSquad1 createUnit ["RU_Soldier_LAT", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; _unit = GroupSquad1 createUnit ["RU_Soldier_Marksman", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; _unit = GroupSquad1 createUnit ["RU_Soldier_LAT", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; _unit = GroupSquad1 createUnit ["RU_Soldier_AR", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; _unit = GroupSquad1 createUnit ["RU_Soldier_GL", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; _leader = leader GroupSquad1; {_x moveInCargo _vcl_new} foreach units _leader; Now I will create some move for the chopper. This also works fine for me. _vcl_new move (position flyTo1); @_vcl_new distance flyTo1 < 130; _vcl_new move (position eject); @_vcl_new distance eject < 130; And now we are at the part where I get error. I want to eject my squad, I have this code for that _group = _this select 0; _vehicle = _this select 1; if ( (typename _group != "GROUP") or (typename _vehicle != "OBJECT") ) exitwith { hintSilent "Invalid Parameters parsed"; }; sleep 1; { unassignvehicle _x; _x action ["EJECT", _vehicle]; sleep 0.5; } foreach units _group; Now, I have try some out, like: _group = _leader; _vehicle = _vcl_new; And _group = GroupSquad1; _vehicle = heli; At the top of the eject code, instead of: _group = _this select 0; _vehicle = _this select 1; But I cant get it to work, my men will not eject. why? How can I do so they will eject? And please, its my first time here, and my first code and script of this game. I have no experience of arma or arma2 at all. and not there codes and so on. I was learning from this forum and from this site tonight: http://community.bistudio.com/wiki/Category:Scripting_Commands_ArmA2 thanks -
all new to this, help with script.
splatsh replied to splatsh's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
This work: {unassignvehicle _x} foreach units _leader; {_x action ["EJECT", _vcl_new]} foreach units _leader; This NOT work: { unassignvehicle _x; _x action ["EJECT", _vcl_new]; sleep 0.5 } foreach units _leader; Why? -
I use this in one other code I use to get a squad to a chopper, then eject and so on... _leader = _Grp1 createUnit ["RU_Soldier_SL", [(position _pos) select 0,(position _pos) select 1,0], [], 3, "FORM"]; Now, I want to get some more. How to put in this, where and how do I do it?: -Rank (CAPTAIN) -Skill (0.7) -Init (this addWeapon binocular)
-
You maybe can use Revive, and still use SecOps?
-
all new to this, help with script.
splatsh replied to splatsh's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
I have finaly got it to work ok. Maybe someone could optimize this, but it all works fine here now. I dont know if it work in MP or so. I got it working in editor/preview. // heli_eject.sqf **************** // Create Chopper and crew Pilots = CreateGroup East; _vcl_new = "Mi17_rockets_RU" createVehicle [(position start_heli select 0)+1, (position start_heli select 1)+1,0]; _vcl_new setVehicleVarName "heli"; _crewPilot0 = Pilots createUnit ["RU_Soldier_Crew", [(position start_pilot) select 0,(position start_pilot) select 1,0], [], 3, "FORM"]; _crewPilot1 = Pilots createUnit ["RU_Soldier_Crew", [(position start_pilot) select 0,(position start_pilot) select 1,0], [], 3, "FORM"]; // Move crew into chopper _crewPilot0 moveinDriver _vcl_new; _crewPilot1 moveinCargo _vcl_new; // Create Squad GroupSquad1 = CreateGroup East; _leader = GroupSquad1 createUnit ["RU_Soldier_SL", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; _unit = GroupSquad1 createUnit ["RU_Soldier_MG", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; _unit = GroupSquad1 createUnit ["RU_Soldier_AT", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; _unit = GroupSquad1 createUnit ["RU_Soldier_LAT", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; _unit = GroupSquad1 createUnit ["RU_Soldier_Marksman", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; _unit = GroupSquad1 createUnit ["RU_Soldier_LAT", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; _unit = GroupSquad1 createUnit ["RU_Soldier_AR", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; _unit = GroupSquad1 createUnit ["RU_Soldier_GL", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; _unit = GroupSquad1 createUnit ["RU_Soldier_Medic", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; // Make leader _leader = leader GroupSquad1; // Move squad inside chopper {_x moveInCargo _vcl_new} foreach units _leader; // Create waypoint for chopper _waypoint0 = Pilots addwaypoint[position eject1,10]; _vcl_new flyinHeight 150; _waypoint0 setWaypointSpeed "FULL" _waypoint0 setwaypointtype "MOVE"; _waypoint0 = Pilots addwaypoint[position heli_stop,10]; _waypoint0 setWaypointSpeed "FULL" _waypoint0 setwaypointtype "MOVE"; @_vcl_new distance eject1 < 200; // Make squad to eject the chopper {_x action ["EJECT", _vcl_new]} foreach units _leader; {unassignvehicle _x} foreach units _leader; // Create waypoint for squad _waypoint1 = GroupSquad1 addwaypoint[position eject1,500]; _waypoint1 setWaypointSpeed "LIMITED" _waypoint1 setwaypointtype "SAD"; // Create waypoint 2 for squad _waypoint2 = GroupSquad1 addwaypoint[position eject1,10]; _waypoint2 setWaypointSpeed "LIMITED" _waypoint2 setwaypointtype "DISMISS"; // Land the chopper @_vcl_new distance heli_stop < 200; {unassignvehicle _x} foreach units _crewPilot0; // Wait 60 seconds ~60 // Delete Chopper and crew deleteVehicle _vcl_new; deleteVehicle _crewPilot0; deleteVehicle _crewPilot1; EXIT got a trigger to set all of. And the best is that I can use the same trigger and the same code over and over. -
all new to this, help with script.
splatsh replied to splatsh's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
please dont answer me again... you dont think I have search, there is 2 pages with hit on searsh of the word eject, I was doing this over and over and over for 5 hours last night, and testing all things out, and searched this forum and tested things out. Then I desided to register and write all my code I got so far and ask in this forum... ---------- Post added at 10:47 AM ---------- Previous post was at 10:42 AM ---------- Well, I have not created them at all, I have read this forum and copy and paste, and try thing out, to learn some things... so none of these code are my. and thanks for this answer "wont work because a var with the "_" prefix is local in each script. In a new script, this _VCL_new and _leader is empty." Now I know that. But I have all code on the same page/file... strange? like this, this is my entire code and script: // heli_eject.sqf Pilots = CreateGroup East; _vcl_new = "Mi17_rockets_RU" createVehicle [(position start_heli select 0)+1, (position start_heli select 1)+1,0]; _vcl_new setVehicleVarName "heli"; _crewPilot0 = Pilots createUnit ["RU_Soldier_Crew", [(position start_pilot) select 0,(position start_pilot) select 1,0], [], 3, "FORM"]; _crewPilot1 = Pilots createUnit ["RU_Soldier_Crew", [(position start_pilot) select 0,(position start_pilot) select 1,0], [], 3, "FORM"]; _crewPilot0 moveinDriver _vcl_new; _crewPilot1 moveinCargo _vcl_new; GroupSquad1 = CreateGroup East; _leader = GroupSquad1 createUnit ["RU_Soldier_SL", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; _unit = GroupSquad1 createUnit ["RU_Soldier_MG", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; _unit = GroupSquad1 createUnit ["RU_Soldier_AT", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; _unit = GroupSquad1 createUnit ["RU_Soldier_LAT", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; _unit = GroupSquad1 createUnit ["RU_Soldier_Marksman", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; _unit = GroupSquad1 createUnit ["RU_Soldier_LAT", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; _unit = GroupSquad1 createUnit ["RU_Soldier_AR", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; _unit = GroupSquad1 createUnit ["RU_Soldier_GL", [(position start_soldier) select 0,(position start_soldier) select 1,0], [], 3, "FORM"]; _leader = leader GroupSquad1; {_x moveInCargo _vcl_new} foreach units _leader; sleep 1; _vcl_new move (position flyTo1); @_vcl_new distance flyTo1 < 130; _vcl_new move (position eject); @_vcl_new distance eject < 130; _group = _leader; _vehicle = _vcl_new; if ( (typename _group != "GROUP") or (typename _vehicle != "OBJECT") ) exitwith { hintSilent "Invalid Parameters parsed"; }; sleep 1; { unassignvehicle _x; _x action ["EJECT", _vehicle]; sleep 0.5; } foreach units _group; you see, I have all on the same page... but it still not working Done some update on the code... {_x action ["EJECT", _vcl_new]; sleep 0.5; } foreach units _leader; {unassignvehicle _x} foreach units _leader; now, that code will get down the chopper and let my squad out.. so unassignvehicle is working OK =) Now, can you help me with this code and get it to work fine. {_x action ["EJECT", _vcl_new]; sleep 0.5; } foreach units _leader;