Jump to content
Hautautujaaa

Player Group Heli Transport Unload (solved)

Recommended Posts

It's been a while since I have used Arma III editor. Have been toying around in the editor, setting up tasks and creating a template for scenario structure. 

 

For some reason I can't find reliable way to make AI pilot unload player group. I know that the Transport Unload waypoint only dismounts the player (when used for player group) and you have to command your squad to dismount, but 50-50 time the helicopter takes off before I can issue any commands. The result seems to be different every time, like completely random. This is what I have tried:

 

1) Creating Get Out waypoint for player group, with and without synchronization with the helicopter waypoint. 

2) Using commandGetOut and doGetOut in the Transport Unload waypoint activation field. 

3) Using !(_unit in _vehicle) in the condition field. 

 

What is the best and correct way to go about this? I thought I had it working, but for some bizarre reason after I created intro it broke down (maybe because I disable and re-enable simulation?) and now I can't get any kind of reliable results. 😆

 

(It seems to be working now after I rebooted the game, but I haven't tested it more than once. Disabled Advanced Rappelling that I had accidentally left activated. Hopefully that was the cause of the issues and the problem is now solved. I'll update this post. ) 

 

E: Nope, still not fixed. Tested it again and the pilot took off immediately. What a bizarre problem. 

 

E2: Honestly, what the f----- is this problem about. Everything I do works just as you would expect, but after running the scenario multiple times it breaks and won't start working again until I change something or reboot the game. 

 

E3: Solved. See comments below for possible solutions. 

Share this post


Link to post
Share on other sites

You can find a lot of topics and trials on forum. Have a look at Gunther's compilation (here at AI CAS, helicopters, Jet planes / helicopters) for this kind of challenge.

 

Just speaking about Vanilla (without any mod consideration, adding their own behaviors), you experience multiple situations along with:

- helicopter readiness on waypoint completion;

- driver behavior in calm/combat environment;

- presence of an helipad or, on the other hand obstacles/ terrain slope;

- state of helo/crew...

 

Even in a simple basic preview, you can have different results based on fsms for AIs behaviors.

The more unit, the more complex to fire fsm (for each unit) in due time.

 

Well, as rule of thumb, your pilot must be careless (or disableAi for "fsm", "autocombat", "target", "autotarget") , and your landing area clear (with invisible or visible helipad) before the condition for loading/disembarking group(s).

It literally took me months for scripting a taxi module allowing pick up/dropping units at sea, or in a combat area. That was the 2 important criteria to observe.

 

Share this post


Link to post
Share on other sites

Would this be something youre looking for?

 

moveOut P1; 

 

This should disembark the UNIT.  For example in my mission I have a trigger with a 5 second delay that Disembarks the unit from whatever vehicle they are in(in my case. The units disembark from a helicopter) P1 is just the Variable name of my character.  You can use it on multiple units. I also have

 

moveOut P1; moveOut P2;

Share this post


Link to post
Share on other sites

I have searched many hours already for an answer and will continue to do so. Decided to make a thread just in case someone has encountered a similar issue or alternatively let others know the solution if I ever happen to find one. However, thanks for the suggestion, I will look through Gunter's thread as well. 

 

Maybe I should have provided a bit more background information. The map is Virtual Reality and I'm using invisible helipad for the landing zone. There are no enemy units and the behavior mode is set to careless. The scenario is really just for testing purposes, because I don't want to start creating a full-blown scenario and run to these kinds of issues midway through. 

 

I'm running SOG Prairie Fire and the following mods: 

 

CBA_A3

3DEden Enhanced

Dynasound 2 (might be unnecessary though, considering SOGPF probably has new sounds for  almost everything) 

Enhanced Soundscape

LAMBS_Danger.fsm

LAMBS_Suppression

Suppress

ToH Characters

CUP Terrains - core (forgot to deactivate)

WW2 Objects (forgot to deactivate)

DEVGRU K-9 

C.A.S.T. v1.8.1 

S&S

Advanced AI Command 

 

I already tested running the scenario without mods that I could disable. In other words I ran it with CBA_A3, Eden Enhanced, S&S and ToH characters. The issue still persisted, so mods probably are not the cause of the issue. Unless the mods I had enabled previously saved code to the mission file, but I don't think that is possible... correct me if I'm wrong though. 

 

////

 

I don't recall having this issue before I created intro.sqs to test cutscenes. I used the BIS_fnc_cameraOld function. The helicopter starts in the air, but I have disabled simulation for the duration of the cutscene and using trigger to re-enable it. 

 

I also tested transport unload waypoint on a completely fresh scenario and it worked like expected – the player unit is ejected automatically, but the AI pilot waits on the ground until player orders his squad to disembark. However I really want to find the reason why the issue occurred so I can avoid or work around it in the future. At this point it seems more like an obscure bug than a mistake on my end. 🤔

Share this post


Link to post
Share on other sites
1 hour ago, DoctorBoingo said:

Would this be something youre looking for?

 

moveOut P1; 

 

This should disembark the UNIT.  For example in my mission I have a trigger with a 5 second delay that Disembarks the unit from whatever vehicle they are in(in my case. The units disembark from a helicopter) P1 is just the Variable name of my character.  You can use it on multiple units. I also have

 

moveOut P1; moveOut P2;

 

That might be it, will test asap and let you know. Thanks 😉

 

E: It kind of worked, but I found a solution that in this case is simpler and easier to setup – just separate player from the group and make him join again with a trigger after the landing. That way the AI pilot will wait the AI units to dismount normally. 

 

The problem was that I couldn't make the AI pilot wait on the ground no matter what. The moment the player was out, it would took off and hover on top of the landing zone. That kind of was the issue with the moveOut command as well. 

  • Like 1

Share this post


Link to post
Share on other sites

I throw in an old script good guy Ghost once made. It's pretty easy to use and works most of the time.

You need two empty helipads and a name for your helicopter:

 

"helo1" is the name of the helicopter
"pad1" is where the cargo unloads

"pad2" is where the helicopter is flying to after (and then is deleted)
 

// nul=[helo1,pad1,pad2] execVM "scripts\heloinsert.sqf";

_helo = _this select 0;
_lz = getPos (_this select 1);
_exfil = getPos (_this select 2);

_helo doMove _lz;
_helo setBehaviour "CARELESS";
_helo setCombatMode "STEALTH";
_helo disableAI "TARGET";
_helo disableAI "AUTOTARGET";
_helo disableAI "WEAPONAIM";
_helo disableAI "AUTOCOMBAT";
_helo setCaptive true;

while {alive _helo} do
{
  sleep 5;
  waitUntil {unitReady _helo};
  _helo lock false;
  _helo land "get out";
  waitUntil {getPos _helo select 2 < 1};
  {unassignVehicle (_x); doGetOut _x} forEach units (crew _helo select 4);
  if (true) exitWith {};
};

sleep 10;
_helo doMove _exfil;
_helo enableAI "TARGET";
_helo enableAI "AUTOTARGET";
_helo enableAI "WEAPONAIM";
_helo enableAI "AUTOCOMBAT";
waitUntil {_helo distance _exfil < 150};
{deleteVehicle _x} forEach crew _helo; deleteVehicle _helo;

 

  • Like 1

Share this post


Link to post
Share on other sites
9 hours ago, Hautautujaaa said:

I'm running

 

SOG Prairie Fire and the following mods: 

CBA_A3

3DEden Enhanced

Dynasound 2 (might be unnecessary though, considering SOGPF probably has new sounds for  almost everything) 

Enhanced Soundscape

LAMBS_Danger.fsm

LAMBS_Suppression

Suppress

ToH Characters

CUP Terrains - core (forgot to deactivate)

WW2 Objects (forgot to deactivate)

DEVGRU K-9 

C.A.S.T. v1.8.1 

S&S

Advanced AI Command

 

 

I also tested transport unload waypoint on a completely fresh scenario and it worked like expected – the player unit is ejected automatically, but the AI pilot waits on the ground until player orders his squad to disembark. However I really want to find the reason why the issue occurred so I can avoid or work around it in the future. At this point it seems more like an obscure bug than a mistake on my end. 🤔

 

If you don't want a unit to be ejected but reasonably disembarked , use doGetOut  instead of moveOut
As you noticed, you have a lot of mods and some of them afford FSM behavior among scripts...

As already explained, the pilot (driver) must become a little bit "stupid" (On Arma that means also without unwanted initiative...). You can try the disableAi command as Wolle mentioned. personally I add "fsm" also.

Share this post


Link to post
Share on other sites
3 hours ago, pierremgi said:

 

If you don't want a unit to be ejected but reasonably disembarked , use doGetOut  instead of moveOut
As you noticed, you have a lot of mods and some of them afford FSM behavior among scripts...

As already explained, the pilot (driver) must become a little bit "stupid" (On Arma that means also without unwanted initiative...). You can try the disableAi command as Wolle mentioned. personally I add "fsm" also.

 

Thanks for the effort, I really mean that, but it seems you did not pay much attention: 

 

"Using commandGetOut and doGetOut in the Transport Unload waypoint activation field. "

 

Neither of them worked, probably because there are checks in place for AI at what height and speed they can dismount the vehicle. The problem was that the AI pilot would eject the player first automatically, then take off immediately and hover above the landing zone. MoveOut worked because it just splurts out the units no matter what. To eject units one by one you can use this  _unit action ["Eject", _vehicle _unit] 

 

However neither of those really fixed the problem – the AI pilot randomly failing to check if the units in player group are still in the vehicle before taking off. 

 

"I already tested running the scenario without mods that I could disable. In other words I ran it with CBA_A3, Eden Enhanced, S&S and ToH characters."

 

None of those should alter FSM behavior at all. 

 

/////

 

That said, I already found a solution that works in my case just fine. See the posts above. I forgot to update the title but it should be updated now. 

 

Also thanks for W0lle for the Ghost's script. It is useful to have more options. 

 

Share this post


Link to post
Share on other sites

No problem. Your solution is fine, probably adapted to your other mods, even if probably not the unique.

As we are on forum, even if you need a adapted solution, it's always interesting to make difference between general case and specific issue. 

It's up to you thinking there is no other possibility than moveOut / eject the units... in your context. I just say, perhaps you missed something, and in most of cases doGetOut is fine (especially in vanilla/ non modded behavior context). If you need something else, and if you want, upload a little (vanilla) test and forumers  could try to push a little bit to a more immersive solution.

 

First part of the video.

 

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

×