FirstPerson & ThirdPerson Attack Animations

MisterStroodle
Sat, 16 Oct 2021 19:29:47 +0000
Character & Animation

I am working on a 1v1, multiplayer fighting game project. It is an arena fighter, where both players wield swords, and then duke it out until one is left alive. I intend for the game to be in first person, similar to games like Chivalry and Mordhau, but with a drastically more simple combat system - you can attack, you can block, no direction input stuff or raycasting for sword swings etc.

Anyway, I decided pretty early on that I wanted to achieve “true first person” in this project, as a milestone goal for myself. The way I intended to achieve this was by following [TorQueMoD’s UE4 TruER FirstPerson Tutorial][1], since it was similar to what I wanted to achieve. This leads me to my current character blueprint setup.

It looks messy but let me explain. It starts with a FirstPersonBlueprint, which contains all the input logic for the first person arms. This is followed by my “BodyMesh” an Unreal Mannequin that has had it’s head and arms removed (this is the mesh the player sees when looking down at themselves). After that we have the ThirdPerson Mesh, which is invisible to the player, but visible to other clients. Lastly, but less importantly is the ShadowMesh, which is invisible for everyone, but generates a more accurate shadow for the player. This is all set up as such.

For the most part, this works and looks pretty good. I throw an AnimationBP on the TPMesh along with a blendspace, and I have a pretty convincing TrueFirstPerson. Issues arise however when I start getting into the more complicated animations. As previously mentioned, I have a FirstPerson blueprint already set up. To be exact, it’s [Hammerhead’s First Person Longsword][4]. Additionally, I also have a package of third person character animations, [Kubold’s Animset Pro][5]. What I’m trying to do is so that when the player does the attack input (mouse0), the third person model plays the corresponding animation. I’ve experimented trying to use animation montages to achieve this effect, but I feel like I’m missing some critical, fundamental knowledge about how animation works in Unreal in order to get it working properly. What I’m hoping is that someone has attempted or succeeded in achieving something similar, and might have some advice or guidance for how I can get mine working.

TL;DR I have first person and a third person mesh. I want to set up my blueprint, so that when the player inputs an attack, the first person mesh and third person mesh play synced animations, and I have no idea how to do that.

1 post - 1 participant