Well the best way, if you don't have your own custom animation made in Gmax, is to reuse an animation from an existing ingame weapon.
Here's what you're going to what to do (you didn't mention the weapon, so I'm just going to use the thompson as an example)
Say you weapon name is "
bigassgun," and it is an
AUTOMATIC weapon, right? The automatic is important, because if you have a singleshot weapon like the sniper rifles, then that is different.
So you use WinRFA 2.05 to unpack the original '42 "
animations.rfa." Within that folder(wherever you unpack it too) there is a test document called "
multiShotWeapons.inc" (inc format should open in notepad, if it doesn't then make sure it does by saying "always use this program") and open it up.
You will see a listing of all the weapons ingame and the basic formula is as follows:
Code: Select all
yourcustomweapon v_arg1 animationtocopyanduse 1.0 animationtocopyanduse 1.0
So you would put a line in there that says:
Code: Select all
AnimationStateMachine.copyState2 bigassgun v_arg1 thompson 1.0 thompson 1.0
I've forgotten why you have have to put the two weapon 1.0's in there, but I think it has something to do with the to copy the 3rd person animation. So now that you'd done that, and hopefully you have properly fixed your bigassgun's "
Objects.con" and had something to the effect of:
Code: Select all
ObjectTemplate.createSkeleton animations/thompson.ske
ObjectTemplate.useSkeletonPartAsMain Base
ObjectTemplate.create AnimatedBundle bigassgunComplex
ObjectTemplate.createSkeleton animations/thompson.ske
So now that you've done that, your gun will work ingame without crashing due to an animation error. However, your weapon, because it's copying an existing animation.ske, it will animate rather fast, especially when reloading. It'll look like you are Flash Gordon, lol.

So, we'll need to fix that. Meaning, it gets a little more complicated, but don't be scared.
Now you need to open up the text file within the animations folder called "
1pAnimationsTweaking.con." Again, it is a .con format, and that is simply a fancy way to say .txt, so you needed to open it up with notepad as the default program always. I assume you know how to do this, but I'm just imprinting it again for anyone else that wasn't listening or wants to mod and will read this, lol. So you open it up and... well, crap! I forgot that '42 has all the weapons jumbled together except for the DP and the Type 99 machine guns. Basically you'll see something like this:
Code: Select all
rem ---- Thompson
AnimationStateMachine.set1pAnimationSpeed Ub_StandThompson 0.1
AnimationStateMachine.set1pAnimationSpeed Ub_TurnThompson 0.1
AnimationStateMachine.set1pAnimationSpeed Ub_StandAimThompson 0.1
And it goes on like that for about 40 lines of code. So you need to copy each one of those animation speeds so that the game recognizes that the "
bigassgun" needs to play those animations at that speed for the player ingame. So change them to...you guessed it:
Code: Select all
rem ---- bigassgun
AnimationStateMachine.set1pAnimationSpeed Ub_Standbigassgun 0.1
AnimationStateMachine.set1pAnimationSpeed Ub_Turnbigassgun 0.1
AnimationStateMachine.set1pAnimationSpeed Ub_StandAimbigassgun 0.1
And boom your animation, that copies itself from the thompson.ske, will work normally ingame. The last thing you need to do is make sure the 3rd person animations are just as slowed down. They are located in the "
3pAnimationsTweaking.con" document.
Code: Select all
rem ---- thompson
AnimationStateMachine.set3pAnimationSpeed Ub_StandThompson 0.60
AnimationStateMachine.set3pAnimationSpeed Ub_TurnThompson 1.60
AnimationStateMachine.set3pAnimationSpeed Ub_StandAimThompson 0.80
And you change everything that says "
thompson" to "
bigassgun" and you're basically done.
One thing to note is that you can save a tremendous amount of work if you already have a properly scaled custom weapon, to take those .rs and .sm files and rename like thompson.rs and thompson.sm or whatever the weapon whose animations you want to use and put that in your mod's folder so that you can see what it'll look like ingame. That way if you don't like the way it looks or handles 1st person wise, then you've saved yourself all the trouble up above. I wish I had figured that out when I started out modding, but I tend to do things that hard way and the long way around, but it teaches me to understand how everything works down the road. But for newer blood, it helps to use the "
easier way, lol! I hope this helps you out. Let me know if you have any problem.