So this problem is bothering me these days…
I’m trying to implement a basic melee attack using line trace, if the trace hits an object it will apply damage to the object.
On the server side, line traces always follow the direction the player’s camera is looking at…No problem at all, so if the player (as the listen server) is aiming down at the ground and attack the hit object would be the floor, that’s nice.
But on the client, no matter what direction I aim at the line traces would always be calculated by the server as horizontal lines, being that even if I stand in front of a character and aim at the ground and press attack, the hit object would be not the floor but the character…
Here’s what the problem looks like, left being the server and right being the client, you can see that the client is aiming at the ground but still the line trace is horizontal
Below are the setups in my blueprint
If I change the event ‘setAtkButtonDown’ from run on server to run on owning client, the trace works for client but of course it cannot apply damage…


