[UNET] Transform is not synchronized from client

Hi! I had an issue.

If I move object at the server side, it moves at the client side.
When I move object at the client side, it DOES NOT move at the server side! What’s wrong?

Details:

  • Prefab has NetworkIdentity(LocalPlayerAuthority=true), NetworkTransform.
  • Script is derived from NetworkBehaviour.
  • Prefab is registered via Spawn Info

Server:

  1. NetworkServer.RegisterHandler(message A,…)
  2. networkManager.StartServer
  3. Handle message A: NetworkServer.Spawn(obj)

Client:

  1. testClient.Connect
  2. ClientScene.Ready
  3. sending message A to a server

Solution:
In order to be synchronized from the client side, it should:

  1. has NetworkIdentity component
  2. has LocalPlayerAuthority flag set to true