VR Repliactaion

I have a problem with my VR hands controllers! where the hands of the Simulated proxy and autonomous proxy on client side are both controlled by the controllers of the client at same time. meanwhile on sever side everything looks okay.
want to precise, I have separate blueprints for Left and Right hand (replicated), then spawn on begin play in character Bp (on server) and attached to Origin component.

im not sure if this is the issue, but has authority does not mean it’s the server. it could mean that the actor was spawned in the client. people tend to use it because “it smells similar” but then get into issues like this.
isServer or netrole is a better check.

also attaching an actor is a weird way of doing this, but also somewhat clever way to solve the replication.
can you share more of your code? it might well be that the way you’re doing it has a logical bug.

if you do a search you’ll find many posts in this forum about how to best replicate vr components. you should give it a read.
https://forums.unrealengine.com/search?q=replicate%20vr

Hi @nande thanks for replying! I noticed that when I turn off Replicate in Hand BP, and spawn it normally on begin play (without using authority), every thing look normal but this time characters does not spawn on same location in server and client side. eg owning client player(autonomous proxy) might spawn at the first player start location but on server it spawn on second player start Location and vice versa. please any idea ?

that’s seems totally expectable.
i can’t really explain in short with my limited time.
i’m not sure disabling replication is the best solution.

i can’t recall if attaching to an actor is replicated or not. but i think it is.
anyway what i usually do is replicate the hand positions myself.
i don’t think attaching is necessary.
i think you’d need to fix your logic for spawing and attaching.
can you please share more of your code?

1 Like

I finally abandoned the idea of spawning the hand actor so now i use the default Template style and it worked.
the reason I create Hand class independently is because it gives me more control as i can implement some logic directly in the hand actor.
as for the code what part should i share? as i drop already an image of how i spawn and attach on begin play. i enabled replicates in the Hand blueprint. even though the other way round finally worked, i will be glad if i understood what the issue with the first solution is actually.

Yeah spawning an actor for the hand is not ideal to me.

Hard to say what the issue is.
I dont know if its worthy to try to fix hhe old code.