Jump to content
Sign in to follow this  
mons00n

Grouped vehicle ordering

Recommended Posts

How does Arma determine the ordering of grouped vehicles? I'm trying to throw together a simple convoy with ~6 vehicles in the following order:

A B C D E F G

however, once I add a gunner to vehicle B the ordering changes to:

A C D E F G B

which throws off the entire convoy because B's speed is faster than the transport vehicles (F & G). I tried ranking the driver ranks to match the intended ordering, but that seems to have little impact. Any ideas? (I'm trying to stay away from actual convoy scripts for a few reasons specific to this mission).

Share this post


Link to post
Share on other sites
How does Arma determine the ordering of grouped vehicles? I'm trying to throw together a simple convoy with ~6 vehicles in the following order:

however, once I add a gunner to vehicle B the ordering changes to:

which throws off the entire convoy because B's speed is faster than the transport vehicles (F & G). I tried ranking the driver ranks to match the intended ordering, but that seems to have little impact. Any ideas? (I'm trying to stay away from actual convoy scripts for a few reasons specific to this mission).

The way the game assigns things is pretty much completely random. Theres no logic to how the group is ordered other than rank (even that glitches out usually) so you end up with a nice big mess. You could try reordering the units by kicking them all out of a group then reassigning them in a specific order.

Something like this:

//my unit names: unit A is SL
myGroup = group unitA;
myUnits = [unitA,unitB,unitC,unitD];
//the group could get mismatched after a while (unitB,unitC,unitD,unitA) for example
{_x join grpNull;} foreach myUnits;
//regroup them.
{_x join myGroup;} foreach myUnits;
//it should rejoin them to the group in the order that they're in in that array of myUnits.

Share this post


Link to post
Share on other sites

You need to rank them and try to keep them in column and spaced good. Group them all to commander and lower the ranks in order, spaced and in nice column, behavior to safe to stay on road. that works for me. Norrins has a nice convoy script to use as well.

Share this post


Link to post
Share on other sites
The way the game assigns things is pretty much completely random. Theres no logic to how the group is ordered other than rank (even that glitches out usually) so you end up with a nice big mess. You could try reordering the units by kicking them all out of a group then reassigning them in a specific order.

Something like this:

//my unit names: unit A is SL
myGroup = group unitA;
myUnits = [unitA,unitB,unitC,unitD];
//the group could get mismatched after a while (unitB,unitC,unitD,unitA) for example
{_x join grpNull;} foreach myUnits;
//regroup them.
{_x join myGroup;} foreach myUnits;
//it should rejoin them to the group in the order that they're in in that array of myUnits.

This seems to have done it! I'm moving the units into each empty vehicle so I had to change things a little, but here is my current working solution:

if(!isServer) exitWith{};

//array of vehicles (minus c6)
_cars = [c1,c2,c3,c4,c5];

//ungroup
{
(crew _x) join grpNull;
}forEach _cars;
[d6] join grpNull;  //driver of c6

//wait for the signal
waitUntil{launchConvoy};

//create group in order
convoy = createGroup EAST;
{
(crew _x) join convoy;
}forEach _cars;
[d6] join convoy;  //driver of c6

//add waypoints
_wp = convoy addWaypoint[getMarkerPos "convoy_switch",5];
_wp setWaypointBehaviour "SAFE";
_wp setWaypointSpeed "NORMAL";
_wp setWaypointFormation "COLUMN";
_wp setWaypointType "MOVE";

Which nullifies everyone's group and waits for a bool to be True, then groups them and sets their waypoint. If I group them immediately their formation goes crazy and it takes them forever to recover, but if I group them just before assigning their waypoint they do a much better job at sticking to the road.

Is the soldier linked to the squad?

Yea I had all of them linked to the squad (otherwise they wouldn't move). But I think adding the gunner in a different order was screwing with the ordering as austin_medic mentioned.

You need to rank them and try to keep them in column and spaced good. Group them all to commander and lower the ranks in order, spaced and in nice column, behavior to safe to stay on road. that works for me. Norrins has a nice convoy script to use as well.

I notcied that spacing plays a huge role, especially with armor. I'd love to use Norrin's script but the convoy in my mission has dynamic waypoints depending on what the user does (blocks road etc) so I didn't feel like reverse engineering Norrin's work right now =)

Thanks for everyone's help and suggestions!

Share this post


Link to post
Share on other sites

If you are willing to dive into BIS campaign pbos, in mission C_m02 they used fsm scripts (vehicleFlow.fsm and convoyFlow.fsm) to maintain convoy order, spacing, and speed. Works better than any other script I've seen out there. Worked with any combination of vehicles and allows you to set a speed limit as well as convoy order.

Share this post


Link to post
Share on other sites
If you are willing to dive into BIS campaign pbos, in mission C_m02 they used fsm scripts (vehicleFlow.fsm and convoyFlow.fsm) to maintain convoy order, spacing, and speed. Works better than any other script I've seen out there. Worked with any combination of vehicles and allows you to set a speed limit as well as convoy order.

I'll have to take a look thanks for the heads up!

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  

×