mirror of
https://github.com/MirrorNetworking/Mirror.git
synced 2024-11-18 19:10:32 +00:00
Call SetupLocalConnection after SetupServer to prepare for local connection removal, where a real connection can only connect to the server after it was started, not before.
This commit is contained in:
parent
07a85309e0
commit
23b5b50155
@ -400,6 +400,7 @@ public void StartClient(Uri uri)
|
|||||||
public virtual void StartHost()
|
public virtual void StartHost()
|
||||||
{
|
{
|
||||||
OnStartHost();
|
OnStartHost();
|
||||||
|
SetupServer();
|
||||||
|
|
||||||
// SetupLocalConnection needs to be called BEFORE SpawnObjects:
|
// SetupLocalConnection needs to be called BEFORE SpawnObjects:
|
||||||
// https://github.com/vis2k/Mirror/pull/1249/
|
// https://github.com/vis2k/Mirror/pull/1249/
|
||||||
@ -427,8 +428,6 @@ public virtual void StartHost()
|
|||||||
// isn't called in host mode!
|
// isn't called in host mode!
|
||||||
NetworkClient.SetupLocalConnection();
|
NetworkClient.SetupLocalConnection();
|
||||||
|
|
||||||
SetupServer();
|
|
||||||
|
|
||||||
// scene change needed? then change scene and spawn afterwards.
|
// scene change needed? then change scene and spawn afterwards.
|
||||||
if (IsServerOnlineSceneChangeNeeded())
|
if (IsServerOnlineSceneChangeNeeded())
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user