Trying To Set a Knockback based on Angle Hit But It only Goes Backwards?

Hey guys I am trying to set up a knock back using launch character. The problem is that when I use the array element derived from overlapping character, it only sends the character backwards, no matter what I angle I hit the enemy from. After the simulation, I also get some errors. Some help would be greatly appreciated


In the error, click the last thing mentioned on the right, that is where the error is occuring.

It’s very hard to debug code when we can only see a tiny bit of it :wink:

first, just plug that into an isValid from the array element to make that error go away.

second, rather than the unit vector node, use find lookAtRotation > Get Forward Vector > and then multiply that by how much force you want him to get knocked back.

however, in both systems its using the locations of the weapon and the player, so that will most likely always push the player forward.

wed need to see how youre handling hitting the character.

if youre using a line sphere or box trace from the weapon, you can get the location pin, add it to the normal pin, then do Find Look at rotation from the location pin to that addition, and multiply it by the force (but still add to the Z to make him go up a bit)

if youre using event hit in the character being hit by the weapon (not hit for a component, for the actor itself) you can do the same thing described above but with the hit location and hit normal pins.

if youre using a component overlap event in the character being hit by the weapon (NOT the actor itself, for a component) you can drag out the sweep result pin, break it, and then do the step described above.

hope that helps!