void Start() { GameControll.isGameOver = false; GameControll.isPause = false; keo1.SetActive(false); keo2.SetActive(false); //panelGameOver.SetActive(false); //panelPause.SetActive(false); txtStart = GameObject.Find("txtStart").GetComponent <UnityEngine.UI.Text>(); target.SetActive(false); txtStart.text = ""; if (isrestart) { StartCoroutine(start(0f)); } else { StartCoroutine(start(1.45f)); } if (GoogleAdmob.bannerView != null) { GoogleAdmob.bannerView.Hide(); } if (GoogleAdmob.interstitial != null) { GoogleAdmob.ShowInterstitial(); } }
public void Pause() { if (gameState == GameStates.Pause) { gameState = GameStates.Playing; } else { if (GoogleAdmob.interstitial.IsLoaded()) { GoogleAdmob.ShowInterstitial(); } gameState = GameStates.Pause; } //Debug.Log("Broadcast requested, No of Subscribers = " + subscribers.Count); foreach (var subscriber in subscribers) { subscriber(); } }
void Start() { AudioControl.DPlayMusicInstance("Nhac menu", true, true); if (GoogleAdmob.interstitial.IsLoaded()) { GoogleAdmob.ShowInterstitial(); } GoogleAdmob.RequestBanner(); #if UNITY_ANDROID && !UNITY_EDITOR if (CheckPackage.check()) { Debug.Log("---------------APP HACK CMNR--------------------"); MobilePlugin.getInstance().ShowToast("HACK CMNR"); Application.Quit(); } else { //MobilePlugin.getInstance().ShowToast("-------------APP KO HACK------------"); } #endif }