Example games = Tekken, Virtua Fighter, Soul Calibur.
I got pretty much everything working for the camera, but I ran in to a wall, in preventing it from flipping to the other side when the characters switch place, like one jumping over the other.
Because I’m using a look at node, to get the camera to follow when the players circle each other. It causes the problem of having the camera flip suddenly / orbit 180 degrees on a cross over.
Some information I have on the set up so far.
Camera is a separate Blueprint.
Dummy in between the two characters, with a look at node aimed at player 2.
Another dummy set to the location of the middle dummy, with an offset to the right Vector, that changes depending on the distance / vector length between the fighters.
with that I get orbit while walking, and zoom.
Problem is, preventing the middle dummy from flipping on a cross over.
I was looking at the camera in Tekken Tag 2, and it flips around during special situations, like a throw, but Otherwise, it is always on the same side, like a 2D fighter.
Any ideas?
Found Solution
I’ve got it working now, for anybody else having trouble with this. The trick was using the Hud Blueprint, to get the players location in relation to the screen, not the 3D world.
I found that “project” the local position of the characters using a Hud blueprint, gave me the result I was looking for. I can’t seem to be able to break the alignment now, no matter how I move around the characters, so this may actually be it.
I have a bool in the Level BP, that changes depending on which character is further to the right in X actual screen space. That bool changes the rotation of a dummy between the characters that the camera is linked to.
Distance of the camera changes with the vector length between the characters.
The camera rotation for the flip counter is the same rotation as the default, but -180 for the yaw.
I’m using that same information to check which way the player is facing, and flip the controls for things like walking after a cross over.
With that I have a camera now that works just like a 2D game, and follows the characters while moving sideways.