Reassigning custom animations

Inspired by Mocap Animations, I had a look at what it might take to reassign custom animations.

EE now extends the number of custom animations from 20 to 70, allowing

  • more animations
  • fewer phenotypes (hence less need to duplicate robes)

The new ReplaceObjectAnimation() function allows us to add animations with new names, and repurpose existing slots to use them, by object.

The ability to assign custom slots by script is great, for two reasons:

  • No need to override a standard animation (Mocap demo uses pause1, for example)
  • Hitherto, every custom animation pack defines custom1-20 differently

The only issue Iā€™ve found is that, since an animation has up to three parts, it may be necessary to override them all. For example,

    ReplaceObjectAnimation(oPC, "custom1start", "idle");
    ReplaceObjectAnimation(oPC, "custom1lp", sAnimationName);
    ReplaceObjectAnimation(oPC, "custom1end", "idle");
    AssignCommand(oPC, ActionPlayAnimation(ANIMATION_LOOPING_CUSTOM1));

where sAnimationName is the name of the animation.

This works for Mocap Animations. I think this must be because they have a middle section only (which is legal).

Before I post this finding to the Lexicon and the Wiki, Iā€™d welcome comments, as others know far more about this than me.

1 Like

Based on some of the feedback Iā€™ve gotten in the comments, Iā€™ve updated Mocap Animations to include a few idles that can be inserted in ā€˜custom1endā€™ or whichever animation slot is used.

4 Likes

I added this example to the Lexicon.

Hi Proleric

I want to add these animations from Mocap on the radial. Is this what you are doing here in this conversation?

If so do you have the 2da you can share so I can do this please. I really like these animations and they would be really nice to add on a radial format.

Is it possible to add your very cool animations to the radial?

I have other non-combat animations i got off the vault I use on radials. Is it possible you can also add this option as a download?

So yes, but not in the way that youre thinking.

You would basically have to add a feat to all classes thats something like ā€œCustom Animationsā€ that then has a bunch of sub-feats for each custom animation.

I intend to have this functionality in my next version of the Emote Command, but theres no given ETA for that. I want to try to find a way to do this dynamically (ie with scripts) instead of asking people to edit 2das (which is intimidating to many)

1 Like

Bummerā€¦i would not know how to do that feat thing.

I hope either you or palmweaver can do this soon and release this to the vault.

Thanks bud

Its on my todo list. What I want to do though is make it easy for someone who doesnā€™t really know scripting to add them dynamically. Like just put in somewheres what animations you want or whatnot. It will take some time to figure out - but! - the whole point of my waymark project is to add these things in ways most people can change stuff how they would like to.

That would be awesome.

Hopefully you get that done soon :slight_smile:

I hope you get ALL the non-combat animations in there. Like the climbing (spiderman like climb on the wall, the C.R.A.P. climb hand-over-hand up the rope), swimming, ride carpet, barrel riding, push-ups, crawling, Veiā€™s animations, etc). And they play nice with the combat animations.

1 Like

Swimming is one Iā€™ve been looking to do myself, but Iā€™m a scripter and not animator, and havenā€™t found an animation that someone else has done we can use yet, though if thereā€™s something I missed on the vault just let me know!

Climbing would be much harder to do, because the engine doesnā€™t actually have a good concept of multiple levels. Probably at best vaulting over obstacles.

There is swimming animations for NWN2 here:
https://neverwintervault.org/project/nwn2/hakpak/rws-swimming-beta
Maybe you could convert those to NWN:EE? Or does animations work very differently for NWN:EE compared NWN2 perhaps?
Iā€™ve also seen swimming animations on Mixamo:
https://www.mixamo.com/#/?page=1&query=swimming&type=Motion%2CMotionPack
Climbing animations can also be found on Mixamo.

I donā€™t have any knowledge of animation for NWN1 to know the answer to these questions or know how difficult it is to convert.

I do know swimming animations are out there - one of the PWs has them - but I donā€™t think itā€™s on the vault.

The limitation for climbing in NWN is more an engine limitation of the original game. You canā€™t have overhanging walk-meshes without doing some technical black magic.

Happy to add in vaulting/parkour stuff if we found appropriate animations though.

I made a combo hak which includes a swimming animation and many other interesting things; itā€™s working in my incomplete module that Iā€™m still nowhere near completing: you will need to use a script to assign the swimming animation. (I can copy and paste the script here if you wish.)
https://neverwintervault.org/project/nwn1/hakpak/assorted-combo-hak-cep-270-compatible-cep-2xx-compatible

If you only want the swimming without everything else Iā€™ve included in my hak here is the original:
https://neverwintervault.org/project/nwn1/hakpak/original-hakpak/swimming-pheno

1 Like

Hi Vivienne,

Thanks for replying. I like your stuff. You seem to know how to blend animations. I was wondering if you can blend my a_ba.mdl file I attached and my a_ba_non_combat

Once those workā€¦Iā€™d like to blend yours.

I have some of the animations in that link you provided already. All my animations work well together except my C.R.A.P. cimbing and the climbing as found in the a_ba (it has an animation of spider climb in it)

I got it from here. I see you do not have that in your animations
a_ba and a_ba_non_combat.zip (3.1 MB)

You can find the spider climb animation by "Failed Bardā€™ in this NWN vault entry

https://neverwintervault.org/project/nwn1/hakpak/custom-content-challenge-2012-nov-sea-air-land-travel

here is a sample video on Youtube to show you what it looks like

You see I need that animation blended into my a_ba_ non_combat.mdl I zipped attached

To tell you the truth I havenā€™t touched the mdl files of the animations, maybe just one but Iā€™ll have to look up which one it was.
Iā€™ve mostly merged the phenotype.2das. Luckily the .mdl creators had them on different lines in the 2das so it was easy to merge them and dump the .mdls and 2das into the hak.
I remember seeing the C.R.A.P. animations some time ago and thinking I should tackle this next and then I got distracted and forgot about it.
Hopefully once some ā€˜real lifeā€™ issues get sorted Iā€™ll see if I can help.

1 Like