#Sync Client and Admin transforms

1 messages · Page 1 of 1 (latest)

sweet phoenix
#

Hi, I have a working pun solution in which I have clients and host in VR.
I'm trying to create a logic where if I click a button it would bring me (host) to guest position and one more button which can bring guest to my position.
Can someone kindly guide me to achieve this functionality?
Thank you in Advance
I have attached my script in which I have these two functions, but its not working

vestal perch
#

I don't use Photon, but in VR you normally want to move the VR Rig locally then have the network player follow it. I would use RPCs for that.

sweet phoenix
#

omg Thankyou

#

I will look into it

sweet phoenix
#

I'm trying it the same way but how do I identify them should I have separate prefabs for them?

vestal perch
#

The player object should be owned by the client. You should be able to get the player client id/user id

sweet phoenix
#

yes it says their id wwhen i check

#

on client side the local avatar says is mine, then their id

#

so I can use that id to teleport them to me?

#

all client id's in my app start with Guest_and then a unique number

#

so can I do something like move id startarting with Guest_ to my position or take me to their position?

vestal perch
#

The VR Rig should not be networked, so the local client will need to move itself. That's why an RPC would be needed if one player needs to move another player.

sweet phoenix
#

Thankyou

#

I managed to teleport guest to player, for player I still have some complications but I think I will figure it out