Don't check for update on web
This commit is contained in:
@@ -62,6 +62,9 @@ public class LoadingMenu : MonoBehaviour
|
|||||||
}
|
}
|
||||||
|
|
||||||
async void CheckUpdate()
|
async void CheckUpdate()
|
||||||
|
{
|
||||||
|
string response;
|
||||||
|
if (Application.platform != RuntimePlatform.WebGLPlayer)
|
||||||
{
|
{
|
||||||
using UnityWebRequest request = UnityWebRequest.Get("https://berrydash.lncvrt.xyz/database/canLoadClient.php");
|
using UnityWebRequest request = UnityWebRequest.Get("https://berrydash.lncvrt.xyz/database/canLoadClient.php");
|
||||||
request.SetRequestHeader("User-Agent", "BerryDashClient");
|
request.SetRequestHeader("User-Agent", "BerryDashClient");
|
||||||
@@ -73,7 +76,12 @@ public class LoadingMenu : MonoBehaviour
|
|||||||
text.text = "Failed to check version";
|
text.text = "Failed to check version";
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
string response = request.downloadHandler.text;
|
response = request.downloadHandler.text;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
response = "1";
|
||||||
|
}
|
||||||
if (response == "1")
|
if (response == "1")
|
||||||
{
|
{
|
||||||
await SceneManager.LoadSceneAsync("MainMenu");
|
await SceneManager.LoadSceneAsync("MainMenu");
|
||||||
|
|||||||
Reference in New Issue
Block a user