mirror of
https://github.com/MirrorNetworking/Mirror.git
synced 2024-11-18 02:50:32 +00:00
fix(Telepathy): Use compiler symbols in Available (#3667)
* fix(Telepathy): Use compiler symbols in Available * Added Comments
This commit is contained in:
parent
2885752890
commit
98dcffb701
@ -75,11 +75,15 @@ void Awake()
|
||||
Debug.Log("TelepathyTransport initialized!");
|
||||
}
|
||||
|
||||
public override bool Available()
|
||||
{
|
||||
// C#'s built in TCP sockets run everywhere except on WebGL
|
||||
return Application.platform != RuntimePlatform.WebGLPlayer;
|
||||
}
|
||||
// Do not change this back to using Application.platform
|
||||
// because that doesn't work in the Editor!
|
||||
public override bool Available() =>
|
||||
#if UNITY_WEBGL
|
||||
false;
|
||||
#else
|
||||
true;
|
||||
#endif
|
||||
|
||||
// client
|
||||
private void CreateClient()
|
||||
|
Loading…
Reference in New Issue
Block a user