#'Convert' in-scene placed to dynamically spawned

1 messages · Page 1 of 1 (latest)

oak jacinth
#

Im doing a game that has local and online coop, for the local, I spawn a prefab with a PlayerInput for each.
But if the user wants, they can host and other players may join, but when doing StartHost, if there's two players, it will fail due to "Player(Clone) tried to registered with ScenePlacedObjects which already contains the same GlobalObjectIdHash".

My idea would be simply spawning the player on the server start, but Unity apparently does this, but it won't accept the same prefab.

Is there any workaround or better ideas? Or do I need to destroy all players then spawn them after starting to host?

native river
#

The easiest way would be starting host from the very beginning and spawning the 2 local players manually. You can set the session to private if you don't want others joining

oak jacinth