Multiple Variation of Weapon Switches

Hi guys,
I’m trying set a weapon switching mechanism for my character, but I noticed I have too many combinations for weapon wielding:
I can have a 1 handed weapon in 1 hand, and either another one in the other hand, or a shield, or he can have a 2 handed weapon, or a ranged weapon, or a wand (or 2) or a wand with a shield or a book etc. (You see where this is going).
I was thinking of having a general locomotion state and just blend poses for each hand (or more) according to the weapon the character has, but I can’t find a good tutorial for that (tried layered blend per bone with a 1 key animation for the hand pose but it only work with a montage and can’t be used in the animBP).
Anyone knows of a better way?

Hello, @T4l_R

I can see your post I give you my best, please see below and follow step-by-step information.
Creating a versatile weapon-switching mechanism for a character with numerous combinations can indeed be complex. Your idea of having a general locomotion state and blending poses for each hand based on the equipped weapon is a sound approach.
Here are some steps you can consider:

  • Separate the character’s body parts in animations, allowing for independent animation of hands, torso, and legs. This way, you can mix and match different weapon animations with the general locomotion.
  • Utilize animation layering in your animation blueprint (AnimBP) to blend different animations for different body parts. For example, you can have a base layer for locomotion and an upper body layer for weapon animations.
  • Use state machines within your AnimBP to manage different weapon states and transitions between them.
  • Assign weapons as separate skeletal meshes and dynamically parent them to the hand bones. This allows for easier swapping and animation.
  • For actions like equipping or switching weapons, use animation montages that can be played on top of your base animations.

For tutorials, consider looking into resources that cover modular character design, animation layering, and state machines in depth.

Remember, the key is to keep your system flexible and scalable to accommodate all the different weapon combinations.

I hope my suggestion is helpful for you. If you want any more information please tell me I am happy to help you.

1 Like

Hi @ryan1969manus
First of all, thanks for the detailed answer.
What you wrote was what I was thinking of doing in cases of using different weapon animations (like attack, defend, skill etc.). However, my dilemma was for a situation like an idle/locomotion state; I’m trying to avoid using a different locomotion state for every different weapon combination, which was why I was thinking of blending a pose for every type of weapon to the existing locomotion (for example creating a pose for holding a shield in 1 hand).
Using the layer blend helps with animation montages (which again, helps with specific animations like attacking), but I don’t know how it’ll help me with an idle/locomotion state.
Unless I misunderstood what you wrote, do you have an idea how to approach it?

Hello, @T4l_R

Certainly! To blend weapon-specific poses with existing locomotion, use layered animations. Set up an AnimMontage for each weapon animation and blend the upper body (weapon poses) with the lower body (movement) using the “Layered Blend by Bone” technique in your Animation Blueprint. This allows you to maintain consistent locomotion while dynamically adding weapon poses. :video_game::rocket:

Best Regard,
ryan1969manus California Care