Jump to content
Sign in to follow this  
Rich_R

Arma 3 animations

Recommended Posts

I would like to create an Arma 3 video and use some of the in game animations to act out scenes.

I've poked around and found this command

[name, "ANIMATION NAME", "ASIS"] call BIS_fnc_ambientanim;

Basically this goes in the characters INIT or can be used in a trigger and the command works great, but only with these animations

https://community.bistudio.com/wiki/BIS_fnc_ambientAnim

If I want to use one of the other animations, such as those found in the animation viewer under cut scenes, the above command doesn't work. I've tried playmove and switch move but they don't appear to be working with the cutscene animations.

Help?

Share this post


Link to post
Share on other sites

BIS_fnc_ambientAnim is a great helper to create nice ambient scenes. However, it is not meant to be executed with a simple animation, it's working on pre-defined sets of animations. Depending on what cutscene animations you want to run you need to mess a bit with the unit before. Here are some unchanged snippets from my own projects:

Makes a unit play a random briefing animation.

_animation = ["Acts_A_M01_briefing", "Acts_A_M02_briefing", "Acts_A_M03_briefing", "Acts_A_M04_briefing"] call BIS_fnc_selectRandom;
IP_Commander switchMove _animation;

Makes player and AI walk together for ten seconds.

player switchMove "Acts_PercMwlkSlowWrflDf2";

IP_Buddy disableAI "MOVE";
IP_Buddy disableAI "ANIM";
IP_Buddy switchMove "Acts_PercMwlkSlowWrflDf2";

sleep 10;

player switchMove "AmovPercMstpSlowWrflDnon";
IP_Buddy switchMove "AmovPercMstpSlowWrflDnon";
IP_Buddy enableAI "MOVE";
IP_Buddy enableAI "ANIM";

Player and AI walking next to each other, talking (opening scene from one of BI's hub missions).

{IP_Guide disableAI _x} forEach ["AUTOTARGET", "MOVE", "TARGET"];
(group IP_Guide) setBehaviour "CARELESS";
(group IP_Guide) setCombatMode "BLUE";

sleep 0.5;

IP_Guide switchMove "acts_welcomeonhub01_aiwalk";
player switchMove "Acts_welcomeOnHUB01_PlayerWalk";

It's always a bit of tinkering with positions, disableAI and group behaviours. Mostly trial and error, not sure if you can automate that process somehow.

Share this post


Link to post
Share on other sites

hmmm... great post IndeedPete... Im going to have to fiddle with that

you can also use some of the commands in the editor using triggers

i have this setup at a checkpoint on a trigger thru the checkpoint

On act

L1 playmove "Acts_NavigatingChopper_Loop";

on deact

L1 playmove "Acts_NavigatingChopper_Out";

where obviously the unit is named L1 and the trigger is thru an animated gate... its not perfect and i usually tweak it but some of the commands do work...

its a trial by fire... in one of my missions i have the range officer doing a kata at a waypoint lol... quite amusing..

roff1 playMove "AmovPercMstpSnonWnonDnon_exerciseKata";

on waypoint where the roff1 is a range officer

sounds like IndeedPete's method allows more dynamic and immersive animations though :)

Share this post


Link to post
Share on other sites

Great feedback!

Tried Cosmic's method, and for the animations listed it worked. I couldn't get "Acts_welcomeOnHUB05_AIWalk_1" or "Acts_Abuse_Akhanteros" to work. I replaced the playmove with switchmove and they worked!

End of the day, I guess the animation works better in a trigger :)

Pete, are you applying yours by calling a script? I don't have much experience with those and tired to cobble it together, but couldn't get anything to work.

Share this post


Link to post
Share on other sites

@CosmicC10R: For testing reasons you don't have to set up triggers. Using the editor's debug console works as well. (Esc and then put some code in that big window, allows the same functionality as triggers.)

@Mustangdelta: Yes, these snippets are being called within scripts / more complex environments. I might even forgot something when copying them. As I said, it's snippets from bigger files. Provided you've named the units correctly, you can paste that code to a custom script.sqf and call it anywhere with:

nul = [] execVM "myAnimations.sqf"

Or for testing reasons:

[] spawn {
  // Pasted script without comments
};

This run from the debug console should also work.

Share this post


Link to post
Share on other sites

hey buddy 

 

BIS_fnc_ambientAnim is a great helper to create nice ambient scenes. However, it is not meant to be executed with a simple animation, it's working on pre-defined sets of animations. Depending on what cutscene animations you want to run you need to mess a bit with the unit before. Here are some unchanged snippets from my own projects:

Makes a unit play a random briefing animation.

_animation = ["Acts_A_M01_briefing", "Acts_A_M02_briefing", "Acts_A_M03_briefing", "Acts_A_M04_briefing"] call BIS_fnc_selectRandom;
IP_Commander switchMove _animation;
Makes player and AI walk together for ten seconds.
player switchMove "Acts_PercMwlkSlowWrflDf2";

IP_Buddy disableAI "MOVE";
IP_Buddy disableAI "ANIM";
IP_Buddy switchMove "Acts_PercMwlkSlowWrflDf2";

sleep 10;

player switchMove "AmovPercMstpSlowWrflDnon";
IP_Buddy switchMove "AmovPercMstpSlowWrflDnon";
IP_Buddy enableAI "MOVE";
IP_Buddy enableAI "ANIM";
Player and AI walking next to each other, talking (opening scene from one of BI's hub missions).
{IP_Guide disableAI _x} forEach ["AUTOTARGET", "MOVE", "TARGET"];
(group IP_Guide) setBehaviour "CARELESS";
(group IP_Guide) setCombatMode "BLUE";

sleep 0.5;

IP_Guide switchMove "acts_welcomeonhub01_aiwalk";
player switchMove "Acts_welcomeOnHUB01_PlayerWalk";
It's always a bit of tinkering with positions, disableAI and group behaviours. Mostly trial and error, not sure if you can automate that process somehow.

 

 

is this method worked also on MP mission on dedi server ? where should i put those script on the init in editor or on external file script .sqf i'm a little bit confused in this part , I just want to make some AI hanging around on base repairing stuff talking or heal injured soldier in my simpe co-op mission already tried BIS_fnc_ambientanim it didnt work on MP .

Share this post


Link to post
Share on other sites

hey buddy 

 

 

is this method worked also on MP mission on dedi server ? where should i put those script on the init in editor or on external file script .sqf i'm a little bit confused in this part , I just want to make some AI hanging around on base repairing stuff talking or heal injured soldier in my simpe co-op mission already tried BIS_fnc_ambientanim it didnt work on MP .

 

I'd try running stuff like this on the server. Keep in mind that my posted snippets do not loop automatically if that's what you're after.

Share this post


Link to post
Share on other sites

I'd try running stuff like this on the server. Keep in mind that my posted snippets do not loop automatically if that's what you're after.

 

I already found some example for looping animation and I'm good now but the problem is the AI with the animation script will disappear when second player join on server (JIP) and I have no clue how to fix this, some thread said that I need execute the script locally on all machines but I dont know how to do this , I tried put my script on initPlayerLocal.sqf, initServer.sqf, init.sqf and no result. I really lost in this part 

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  

×