Jump to content
ruff

How to make the helicopter check all my group is in the helicopter

Recommended Posts

Hi this used to be alot easier in OFP, but i want the helicopter to check that all members in my group is inside the helicopter. whats the code i put in the condition field?

 

Very simple. 

Share this post


Link to post
Share on other sites

I think this should work:

player in vehiclename && group player in vehiclename

Share this post


Link to post
Share on other sites

thanks but it didnt work.

 

Shouldnt it call my groups name instead of group player?

Share this post


Link to post
Share on other sites

thanks but it didnt work.

 

Shouldnt it call my groups name instead of group player?

group player means the group your player is in. If you named your group then try that name.

  • Like 1

Share this post


Link to post
Share on other sites


{_x in _heli} count (units group player) == {(alive _x)} count (units group player)

  • Like 1

Share this post


Link to post
Share on other sites

Will try it again! Thanks!

Share this post


Link to post
Share on other sites

can also the command unitReady if you issue them a move/board order i think.

  • Like 1

Share this post


Link to post
Share on other sites
{_x in _heli} count (units group player) == {(alive _x)} count (units group player)

this worked perfect. How bout if the opposite where it checks if my group is no longer inside the helicopter?

Share this post


Link to post
Share on other sites

 

I think this should work:

player in vehiclename && group player in vehiclename

hi Alex this didnt work but thanks anyway. It came up with an error. Kylania's code did for future reference. How the long road of making missions again. 

Share this post


Link to post
Share on other sites

this worked perfect. How bout if the opposite where it checks if my group is no longer inside the helicopter?

{!(_x in _heli)} count (units group player) == {(alive _x)} count (units group player)

Share this post


Link to post
Share on other sites

thank you!

Share this post


Link to post
Share on other sites

I would check that way:

({_x in crew heli} count group player == 0)  //  all group member left vehicle
({!(_x in crew heli)} count group player == 0) // all group member r inside heli
Edited by sarogahtyp

Share this post


Link to post
Share on other sites

My group would be just cargo though as I'm using the heli as transport and the heli has its own. Wouldn't be crew for when you are flying the heli with a crew? Or it doesn't matter?

Share this post


Link to post
Share on other sites

My group would be just cargo though as I'm using the heli as transport and the heli has its own. Wouldn't be crew for when you are flying the heli with a crew? Or it doesn't matter?

Doesn't quite make sense what you are saying mate but here is what I think the answer would be to what you asked. It doesn't matter what position of the helicopter your group soldiers are in, it checks if the group is at all inside the helicopter without caring about what position they have taken. So yes if you have a group of 6 and 3 take cargo positions, 2 take gunner positions and 1 takes the pilot position, the condition still turns true.

  • Like 1

Share this post


Link to post
Share on other sites

My group would be just cargo though as I'm using the heli as transport and the heli has its own. Wouldn't be crew for when you are flying the heli with a crew? Or it doesn't matter?

 

crew

Return Value:

Array - An array with all units in the vehicle is returned.

  • Like 1

Share this post


Link to post
Share on other sites

Thanks guys.

My main purpose was the chopper to land so my group can jump inside and not leave till my whole group was inside.

I know Kylania's coding worked so I'm all good. Will try the other ones suggested!

This community is awesome even now after all those years starting from OFP

  • Like 1

Share this post


Link to post
Share on other sites

Hey, sorry for highjacking this thread, but I got a similar issue.
I have group of civilians (around 50) that need to get evac. I got the helicopters to loop from evac point to safety, but since I got all civilians in one group, I can't just let them enter as a group.
Is there any easy way to a) not just make another group from the bigger group of civilians enter the helicopters and b ) get the capacity of the heli for the group size.

And another OT question: when can I open an own thread, cause I have a difficult problem and I don't see a thread "For people who can't open threads yet."

Share this post


Link to post
Share on other sites

Thank you, i really didnt see the "cargo" option on emptyPositions.

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

×