void RefreshView(bool isEnabled) { if (isEnabled && fullscreenAdsModel.IsAdReady(AdPlacement.Currency)) { bool isDoubleModeEnabled = false; switch ((GameGroups.GameGroupGameType)GameGroups.GameCtrl.instance.SelectGameNumber) { case GameGroups.GameGroupGameType.Cat: isDoubleModeEnabled = configService.GetConfig <Cat.CurrencyBonusConfig>().IsDoubleModeEnabled; break; case GameGroups.GameGroupGameType.Gun: isDoubleModeEnabled = configService.GetConfig <Gun.CurrencyBonusConfig>().IsDoubleModeEnabled; break; case GameGroups.GameGroupGameType.Orbit: isDoubleModeEnabled = configService.GetConfig <Orbit.CurrencyBonusConfig>().IsDoubleModeEnabled; break; case GameGroups.GameGroupGameType.Slame: isDoubleModeEnabled = configService.GetConfig <Slame.CurrencyBonusConfig>().IsDoubleModeEnabled; break; } var collectedAmount = isDoubleModeEnabled ? gameplayStatistics.AddedGameplayCurrency : 0; ShowView(currencyBonus.Amount, collectedAmount); } else { View.Hide(); } }
public bool IsAdReady(AdPlacement placement) { if (placement.IsInterstitial() && !AreAdsEnabled) { return(true); } if (placement.IsRewarded() && !AreRewardedAdsEnabled) { return(true); } return(fullscreenAdsModel.IsAdReady(placement)); }
public override void Execute() { if (!continueTimer.IsOn) { return; } if (fullscreenAdsModel.IsAdReady(AdPlacement.Continue)) { continueTimer.TryStartTimer(); } else { gameEnd.Dispatch(); } }
public bool IsCustomRewardAdReady() { return(fullscreenAdsModel.IsAdReady(AdPlacement.Custom)); }
bool TryShowContinueButton() { return(ShouldShowContinue() && fullscreenAdsModel.IsAdReady(AdPlacement.Continue) && continueTimer.TryStartTimer()); }