Jump to content
Sign in to follow this  
HateDread

Smooth, Unarmed Transition from On Back to Standing

Recommended Posts

Hey all,

As the title suggests, I'm trying to get a smooth animation transition from a player lying on their back, to standing. The problem is that I can't seem to find a way that's compatible with the lack of weapons.

I'm currently using AinjPpneMstpSnonWrflDnon_rolltoback, at mission start, so player begins on their back. On queue (as a result of an addaction), I want the player to stand. I tried using AinjPpneMstpSnonWrflDnon_rolltofront to get the player into a position from which he can normally stand, but the animation requires a weapon - in my attempts, the player is holding an invisible rifle.

Does anybody have any ideas?

Cheers,

- HateDread.

EDIT: Using the animation viewer ( ), I have managed to find some useful animations. (Namely AinjPpneMstpSnonWnonDnon_rolltofront instead of AinjPpneMstpSnonWrflDnon_rolltofront, etc.

Now I i'm wondering how to tell via script commands when the rolling to front is completed, so I can execute a stand. How does one determine when the animation is finished? Is it Animationstate? And if so, how does it determine the animation has ended? I thought the animation continues until told to stop?

Cheers.

Edited by HateDread

Share this post


Link to post
Share on other sites

Record yourself doing this and put it in as a video cutscene. Or just play some news footage of people standing up. Precise and fluid animations is not one of ArmA's strongpoints. :)

Animationstate is for stuff like "is the landing gear down" not "is whatever move completed".

Share this post


Link to post
Share on other sites

Now I i'm wondering how to tell via script commands when the rolling to front is completed, so I can execute a stand. How does one determine when the animation is finished? Is it Animationstate? And if so, how does it determine the animation has ended? I thought the animation continues until told to stop?

//...
_unit playMove "AinjPpneMstpSnonWrflDnon_rolltofront";
waitUntil {animationState _unit != "AinjPpneMstpSnonWrflDnon_rolltofront"};
//...

How do I tell the player has stood up? :)

// ...
_hasStoodUp =
{
    _unit = _this;
    _anim = toArray(toLower(animationState _unit));

    _return = false;
    if (count _anim > 7) then
    {
         _anim = toString([_anim select 4, _anim select 5, _anim select 6, _anim select 7]);
         if (_anim == "perc") then
         {
              _return = true;
         };
    };
    _return
};

waitUntil {_unit call _hasStoodUp};
// ...

Edited by Deadfast

Share this post


Link to post
Share on other sites

Deadfast, you're a digital god. Thank you.

Now my question is, what is the anim for 'standing' once lying on stomach via AmovPpneMstpSnonWnonDnon_healed. Is there a player playmove "stand" or something I can use?

Cheers.

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  

×