Hi all,
I’m trying to unlock the mystery that is getting a nice third person setup that has player always aiming center screen. What I’m going for is a GTA 5 setup, where the player always aims at shoots crosshair whether its 1 foot in front of him or a mile.
The way I have been trying to approach this fails, but this is what im attempting to do:
Trace from camera forward *10000.
if i hit something, find the look at rotation between player location and impact, then set that rotation on my character.
if fail to hit, same as above but use the *10000 as the look at target
my character either looks 90 degrees towards center or spasms wildly.
I’m looking to do this only in blueprint - any help is appreciated!
i feel like im possibly missing some foundational approach to this, im just trying to get an over the shoulder, but always have player facing center screen/ always make gun when it fires face directly to the center screen.
Sounds to me like you pretty much got it! What I could add is perhaps an invisible backboard that would pick up any traces that go into the sky. Then it will always trace center screen, at whatever your cursor is touching. For the backboard I just make a giant box around my map of invisible plates.
And instead of setting your actor rotation, use the results for the spawn transform, for your projectile.
Heres what my set rotation looks like in my character blueprint. I played with different make rot from axes, everything spasms my character out. I have a blendspace for aiming in my animblueprint,
not sure if its causing or adding to the problem.