how can i modify photonTransformView script to sync only x axis ?

Options
Hi Everyone, can someone provide me with the customized photon transform view script which will sync only x axis? let me know if it is possible ?
The reason i want this that i have a side view of the cars and i want the user car to be infront, the cars only move x axis, so i only need to sync them and i want to change the z index according the player number, so the player car will be always in front

Answers

  • vadim
    Options
    HI,

    Use script with OnPhotonSerializeView for custom synchronization.
    Apply this script on prefab and set it as observed component. See Demo Synchronization for a sample.