private bool CheckPossibleOpenBox(Box box) { bool possible = false; switch (box.CostMethod) { case Box.CostType.Coins: possible = TitlePanelManager.TryTakeCoins(box.Cost); break; case Box.CostType.Gems: possible = TitlePanelManager.TryTakeGems(box.Cost); break; case Box.CostType.Free: possible = true; break; case Box.CostType.ADS: possible = ADSManager.IsRewardedAdReady(); break; } return(possible); }
private bool IsADSReady() { bool Ready = ADSManager.IsRewardedAdReady(); CoinsShowADSButton.Interactable = Ready; GemsShowADSButton.Interactable = Ready; TicketsShowADSButton.Interactable = Ready; return(Ready); }