hi i am trying to replicate the weapon currently the server and the client sees what the server is doing but the server does not see what the client is doing the weapon is not moving into the server view
Hi primillo_vk
The server cannot see what the client is doing. Think of them as separate entities.
You need to forward the inputs from the client to the server to move the gun and then get the updated position to replicat back down to the connected clients.
Hope this helps
Alex
Hi primillo_vk
I see you keep using “GetAllActorsOfClass” This is an extremely slow function and should be used lightly. If there is too much work on the server, it might not execute your event. You can force this by checking “Reliable” on the event itself.
Also you are passing a reference to the object from the client to the server. The object you are trying to send will be a different instance on the server so check to make sure the “out” reference is valid (the server knows what it is).
Make sure the actor is set to replicate properly.
Good luck
Alex

