If I select one of the cubes in both the server and the client, the selected cube shows up as magenta. It doesn’t matter if I select the cube in the server or in the client, the cubes themselves will always show up as magenta and not green.
The docs mentioned the NetworkBehaviour.isLocalPlayer will return true if the object is represented by the player’s local machine. I am guessing the “local machine” part is referring to the instance of the Unity Player. If it represents the machine I am using, then the cubes should be colored in as green.
This is very confusing. If neither the server nor the client owns the cubes, when who owns it?
The only hint so far that I can try is to make the cube game objects react to the player’s inputs by using a mix of [ClientCallback], [SyncVar], and [Command]. It’s not pretty, and it’s very unstable.
If anyone else knows about spawned prefabs with no authorities on both the server and clients, please post here.
When I run that project, everything seems to be working correctly. The white cube is in the same place as the colored, cube, so you cant see the colored one. If you move the white cube (or spawn the players at different locations), you can see the colored cube.
The preview panel in the inspector shows the local player and authority status for objects:
Ah, that explains how I’m getting white cubes on both the server and the client. It’s kind of unexpected how there’s no Z-fighting, when both cubes are placed in the same position. And it brought out more questions. Don’t worry, I asked them about this here.
I guess you can close that bug report, seeing how this is resolved.
Also, I never knew you can inspect the Network Information in the Inspector on the cloned cubes.