Jump to content
M0RG

Soldiers marching home

Recommended Posts

Im trying to create a ArmA III super-epic movie, but i can't cuz' im total greenhorn. I stuck at first scene - im trying to make scene where soldiers are marching on the road in few columns. I was trying to spawn an infantry squad (i set it to "safe" etc.) then i set formation to column. Well... They were walking but not straight. They decided to walk on the roadside (i wanted them to walk straight in the middle of the road) and their march wasn't perfect also - instead of straight walking, sometimes they were making turns and other strange moves. So i decided to record few paths so they could march like soldiers on a parade. Everything is OK, but... They are moving without using their legs. It looks like they're skateboarding on invisible skateboard. Any ideas? How can i fix that? Or maybe you have easier solutions...

Share this post


Link to post
Share on other sites

Could try setting them to "AWARE" instead or just have the unit's play the walking animation while disabling their ability to do other animations.  Something like this:

Bob playMove "WalkingAnimationClassnameGoesHere";

Bob disableAI "ANIM";

  • Like 1

Share this post


Link to post
Share on other sites

It works! The second option which includes animations is the best solution. I've already tried to use walking animation, but AI did only 5 steps maybe and then they stopped moving. I thought that looping the animation might work, but i didn't know how to do that. The solution came with your 

17 minutes ago, phronk said:

Bob disableAI "ANIM";

Now the AIs are walking straight and they aren't stopping!

Share this post


Link to post
Share on other sites

It literally takes 30 seconds in editor

1. Add units grouped together
2. Click on group icon select

MdKhO2g.jpg

 

You can have Column or File formation, doesn't make a difference both look like column

3. Add waypoint
4. Profit

  • Like 1

Share this post


Link to post
Share on other sites

I've done it many times, but they were walking on the side of the road and their movement was irregular. Withous commands I couldn't make something like this

?interpolation=lanczos-none&output-forma

Share this post


Link to post
Share on other sites
_classes = [
	"B_Soldier_F",
	"B_Soldier_A_F",
	"B_soldier_AAR_F",
	"B_support_AMG_F",
	"B_support_AMort_F",
	"B_soldier_AAT_F",
	"B_soldier_AR_F",
	"B_medic_F",
	"B_crew_F",
	"B_Deck_Crew_F",
	"B_engineer_F",
	"B_engineer_F"
];
_pos = getPos player;
_units = [];

for "_i" from 1 to 8 do 
{
	for "_j" from 1 to 4 do
	{
		_unit = createGroup west createUnit [selectRandom _classes, _pos vectorAdd [_i*2 + (0.2 - random 0.4), _j*4, 0], [], 0, "CAN_COLLIDE"];
		_unit forcewalk true;
		_units pushBack _unit;
	};
};

_units spawn
{
	{
		sleep random 0.01;
		_x playmove "amovpercmwlkslowwrfldf_ver2"; 
		_x addEventHandler ["AnimDone", {_this select 0 playMove "amovpercmwlkslowwrfldf_ver2"}];
	}
	forEach (_this call BIS_fnc_arrayShuffle);
};

 

  • Like 1

Share this post


Link to post
Share on other sites
12 hours ago, killzone_kid said:

 

where do I need to paste it? init?

Share this post


Link to post
Share on other sites

@M0RG You mentioned the second idea working, the one with the disable AI and its animation but I have found no such luck with it. What exactly did you do?

 

Quote

I've done it many times, but they were walking on the side of the road and their movement was irregular. Withous commands I couldn't make something like this

?interpolation=lanczos-none&output-forma

1

 

 

Share this post


Link to post
Share on other sites

self-snipped

Edited by Stinger913
putting picture in aforementioned comment

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

×