prod v8
This commit is contained in:
@@ -4,7 +4,7 @@ using UnityEngine;
|
||||
|
||||
public class CheckUpdates : MonoBehaviour
|
||||
{
|
||||
public static int ClientVersion = 1;
|
||||
public static int ClientVersion = 3;
|
||||
public static int ServerVersion;
|
||||
|
||||
public static bool EverythingOkay => ClientVersion == ServerVersion;
|
||||
@@ -39,7 +39,7 @@ public class CheckUpdates : MonoBehaviour
|
||||
ServerVersion = int.Parse(req.text);
|
||||
if(ServerVersion <= 0){
|
||||
LoadingScreen.LoadLevel("maintaince");
|
||||
}else if(ServerVersion != ClientVersion){
|
||||
}else if(ServerVersion > ClientVersion){
|
||||
LoadingScreen.LoadLevel("update");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -134,15 +134,15 @@ public static class DataManager{
|
||||
}
|
||||
Debug.Log("Success parsing userdata");
|
||||
|
||||
PlayerPrefs.SetString("username", username);
|
||||
PlayerPrefs.SetString("password", username);
|
||||
PlayerPrefs.SetString("username", username + "#0");
|
||||
PlayerPrefs.SetString("password", username+ "#0");
|
||||
PlayerPrefs.Save();
|
||||
}catch(Exception e){
|
||||
Debug.Log("Error parsing userdata");
|
||||
}
|
||||
}else{
|
||||
if(request.downloadHandler.text == "0"){
|
||||
userData = new UserData(){username = username};
|
||||
userData = new UserData(){username = username+ "#0"};
|
||||
}else{
|
||||
MessageBox.ShowMessage("Error logging in, Server said\n" +request.downloadHandler.text);
|
||||
return;
|
||||
|
||||
@@ -31,7 +31,9 @@ public class Helpers{
|
||||
if(hours>0){output+=$"{hours}H ";}
|
||||
if(mins>0){output+=$"{mins}m ";}
|
||||
if(showSeconds){output+=$"{seconds}s";}
|
||||
|
||||
if(output.Length <= 0){
|
||||
output = time + " seconds";
|
||||
}
|
||||
return output;
|
||||
}
|
||||
}
|
||||
@@ -14,12 +14,38 @@ public class LoginManager : MonoBehaviour
|
||||
void Awake(){
|
||||
loadingPanel.SetActive(true);
|
||||
|
||||
// PlayGamesPlatform.Activate();
|
||||
// LoginGooglePlayGames();
|
||||
configuration = new GoogleSignInConfiguration {
|
||||
WebClientId = "656661869871-klbj2ujfiucqic4uugb0d2t3p3vbe4jp.apps.googleusercontent.com",
|
||||
RequestIdToken = true,
|
||||
WebClientId = "143863534373-b4f6l0esj5jr7kl2m66bkd0je21fsp7s.apps.googleusercontent.com",
|
||||
RequestIdToken = false,
|
||||
RequestEmail=true,
|
||||
};
|
||||
}
|
||||
// public void LoginGooglePlayGames()
|
||||
// {
|
||||
// PlayGamesPlatform.Instance.Authenticate((success) =>
|
||||
// {
|
||||
// if (success == SignInStatus.Success)
|
||||
// {
|
||||
// Debug.Log("Login with Google Play games successful.");
|
||||
// PlayGamesPlatform.Instance.Get
|
||||
// PlayGamesPlatform.Instance.RequestServerSideAccess(true, code =>
|
||||
// {
|
||||
// Debug.Log("Authorization code: " + code);
|
||||
// // Token = code;
|
||||
// StartCoroutine(DoneLogin(task.Result.Email));
|
||||
|
||||
// // This token serves as an example to be used for SignInWithGooglePlayGames
|
||||
// });
|
||||
// }
|
||||
// else
|
||||
// {
|
||||
// MessageBox.ShowMessage("Failed to retrieve Google play games authorization code", "Error Auth");
|
||||
// Debug.Log("Login Unsuccessful");
|
||||
// }
|
||||
// });
|
||||
// }
|
||||
|
||||
async void Start(){
|
||||
// DataManager.GoogleLogin("sewmina7d@gmail.com");
|
||||
|
||||
@@ -130,7 +130,7 @@ public class PlayerController : MonoBehaviour
|
||||
GameOverUI.Activate();
|
||||
|
||||
AdCounter++;
|
||||
if(AdCounter > 1){
|
||||
if(AdCounter > 1 || DataManager.userData.faucet_id > 0){
|
||||
AdCounter =0;
|
||||
|
||||
AdsManager.instance.ShowIntAd();
|
||||
|
||||
Reference in New Issue
Block a user