How to shoot precisely forward from characters weapon (3rdPS)

Hello,

I cant solve this problem… I want to create a 3rd person shooter with camera from perspective, but i dont know how to make character shoot precisely forward from weapon…

i cant use line trace with camera aim, and if i use arrow component from weapon for spawning actor(bullets), idle animation makes character shooting imprecisely because animation moves with weapon and also with arrow component…

Could someone help me please? I think i need something like stop animation on hands(and then use arrow component) but i dont know how to do that, or something another…

To shoot precisely forward from the weapon, you would put a Socket onto the weapon and position it where you want it to start the shot from, make sure the “X” axis is pointing in the correct direction for the shot to be fired (for your ease of mind and sanity). Then you would just spawn the projectile or line trace from that socket position and forward at whatever trajectory you want.

Keep in mind, this will shoot it precisely forward from the weapon itself. So wherever the weapon is pointed at, the shot will fire towards. That includes idle animations, running and jumping animations, all sorts of animated movements that have the possibility of affecting where the shots go. To prevent that from happening, you can use Anim Notifications that tell the blueprints when to fire the shot.

You may want to look at some 3rd-person shooter tutorials for aim offsets to get some ideas on how you want yours to go.