Esempio n. 1
0
 /// <summary>
 /// Function called when the player watches an ad to play the challenge.
 /// </summary>
 public void AdRewardInitChallenge()
 {
     // Activate the flag
     GetInstance()._adChallengeInit = true;
     // Calls AdManager to initiate Ad process
     AdManager.GetInstance().ShowRewardedVideo();
 }
Esempio n. 2
0
 /// <summary>
 /// Function called when the player presses the button in a normal Game to win coins
 /// for buying some hints later.
 /// </summary>
 public void AdRewardCoins()
 {
     // Set the flag true for later checking
     GetInstance()._adRewardCoins = true;
     // Call AdManager to initiate the ad
     AdManager.GetInstance().ShowRewardedVideo();
 }
Esempio n. 3
0
 /// <summary>
 /// Function called when the player presses the button in Challenge Victory screen.
 /// Gives them more coins after winning.
 /// </summary>
 public void AdRewardDoubleBounty()
 {
     // Activate the flag
     GetInstance()._adDoubleChallenge = true;
     // Call AdManager to initiate the ad
     AdManager.GetInstance().ShowRewardedVideo();
 }
Esempio n. 4
0
    public void GetMoreHints()
    {
        #if UNITY_EDITOR
        AddHints();
        #endif

        #if UNITY_ANDROID
        AdManager.GetInstance().DisplayRewardVideo();
        #endif
    }
Esempio n. 5
0
    private IEnumerator ShowNextLevel(float delay)
    {
        yield return(new WaitForSeconds(delay));

        AdManager.GetInstance().UpdateDelay();
        boardGrid.FillBoard(MarkType.Cross);
        levelsParameters.FillCurrentFigures();
        levelInfoPanel.UpdateLevelValue(DataStorage.GetCurrentLevel());
        figureSpawner.SpawnFigures(levelsParameters.CurrentFigures, DataStorage.CountOfFigures);
        levelInfoPanel.SetPanelEnabled(true);
        completeLines.HideLines();
    }
Esempio n. 6
0
    public void HandleGameOver()
    {
        if (gameOver)
        {
            return;
        }

        gameOver    = true;
        gameStarted = false;
        DestroyBalls();

        ScoreManager.GetInstance().HandleGameOver();
        AdManager.GetInstance().CheckAd();
    }
Esempio n. 7
0
 public void AdRewardInitChallenge()
 {
     GetInstance().adChallengeInit = true;
     AdManager.GetInstance().ShowRewardedVideo();
 }
Esempio n. 8
0
 public void AdRewardDoubleBounty()
 {
     GetInstance().adDoubleChallenge = true;
     AdManager.GetInstance().ShowRewardedVideo();
 }
Esempio n. 9
0
 public void AdRewardCoins()
 {
     GetInstance().adRewardCoins = true;
     AdManager.GetInstance().ShowRewardedVideo();
 }
Esempio n. 10
0
 public static void HandlePurchaseMade()
 {
     showAds = false;
     PlayerPrefs.SetInt(AdManager.GetInstance().hasMadePurchase, 1);
 }