WebGL / KCP different host

This commit is contained in:
MrGadget1024 2023-03-27 00:15:36 -04:00
parent 247fc4ea77
commit 6430fc08ae
2 changed files with 9 additions and 2 deletions

View File

@ -249,6 +249,10 @@ PrefabInstance:
propertyPath: m_OnClick.m_PersistentCalls.m_Calls.Array.data[6].m_Arguments.m_ObjectArgumentAssemblyTypeName propertyPath: m_OnClick.m_PersistentCalls.m_Calls.Array.data[6].m_Arguments.m_ObjectArgumentAssemblyTypeName
value: UnityEngine.Object, UnityEngine value: UnityEngine.Object, UnityEngine
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 5678319891599719911, guid: 7cf6fcfd5a32c1545bc85a85bfa9c80b, type: 3}
propertyPath: m_Options.m_Options.Array.data[0].m_Text
value: mirror2.clevertech.net
objectReference: {fileID: 0}
- target: {fileID: 5678319891599719911, guid: 7cf6fcfd5a32c1545bc85a85bfa9c80b, type: 3} - target: {fileID: 5678319891599719911, guid: 7cf6fcfd5a32c1545bc85a85bfa9c80b, type: 3}
propertyPath: m_OnValueChanged.m_PersistentCalls.m_Calls.Array.data[0].m_Target propertyPath: m_OnValueChanged.m_PersistentCalls.m_Calls.Array.data[0].m_Target
value: value:

View File

@ -45,8 +45,11 @@ public void OnSelectServer(int server)
{ {
if (server == 0) if (server == 0)
{ {
#if UNITY_WEBGL
SetHostname("mirror.clevertech.net"); SetHostname("mirror.clevertech.net");
#else
SetHostname("mirror2.clevertech.net");
#endif
if (transport is SimpleWebTransport swt) if (transport is SimpleWebTransport swt)
{ {
swt.port = 7777; swt.port = 7777;
@ -84,7 +87,7 @@ public void OnSelectServer(int server)
} }
} }
#region Unity Callbacks #region Unity Callbacks
#if UNITY_SERVER #if UNITY_SERVER
public override void Start() public override void Start()