Something wrong with the way blueprints handle negative x&y?

Hello!

Seems like either I am doing something wrong in an unexplainable way (be sure to give it a shot, though :3), or there is something messy with the way blueprints do their vector maths.

Take a look at this blueprint:

(note: I use a lot of “supposed position”; but it’s not a variable in the blueprint :3)
Do you see any way it would generate end point being set to meters away from their “supposed position”, if the player is facing apprx. towards negative y? Especially, when the effect is scalable by you being in an extreme angle compared to object you are shooting at. The debug arrows appear left from their “supposed position”. The effect is also visible in negative x, but nowhere near as clearly. From neg. y I have literally been able to shoot all around the target (the cross hair on practically every vertice of the target) without hitting a single time :confused:

*Hope we get this resolved,

You have your multiply and add out of order when setting your End vector. You’re adding “Range” to Forward Vector (offsetting the forward vector by “Range”), then multiplying that by the World Location. Instead, multiply the Forward Vector by “Range” (forward vector is a 0.0-1.0 vector), then add that to World Location.

Thank you! I’m not very good at vector maths, am I :stuck_out_tongue: Well, I don’t have to use my original fix (Every weapon has an endpoint spawned at distance of the weapons range, that endpoint is parented to first person camera, and world loc of that endpoint works as a endpoint), and this one makes creating new weapons slightly easier :slight_smile:

*Thank you for finally getting me out of this trouble, very appreciated