How can a client spawn a prefab with isLocalPlayer

I want a client to make the server spawn an object. So far so good.

But I want that object to have isLocalPlayer set to true on the client. How can I do that?

Am I really missing something so simple or is this a problem no one knows the answer to?

As far as I can tell, only the ONE object linked as the Player object (in the NetworkManager) returns true on isLocalPlayer.

Bump!
Is there any workaround?
In short, how would I go about to have a spawned object do local stuff only on the client that spawned it?

isLocalPlayer is just for the player object. What you want is SpawnWithClientAuthority.

https://docs.unity3d.com/ScriptReference/Networking.NetworkServer.SpawnWithClientAuthority.html

1 Like

Awesome! This was exactly what I was looking for, and probably op too!