use mirror in a mod unity code example
Example: how to use mirror for unity
NetworkServer.ReplacePlayerForConnection(conn, gameplayerInstance.gameObject);
NetworkServer.ReplacePlayerForConnection(conn, gameplayerInstance.gameObject);