Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class chartBoostAdverts : MonoBehaviour
- {
- #if UNITY_ANDROID
- int ClickCounter = 0;
- void Start()
- {
- ClickCounter = PlayerPrefs.GetInt ("ClickCounter", 0);
- }
- public void showAdTrigger()
- {
- ClickCounter++;
- PlayerPrefs.SetInt ("ClickCounter", ClickCounter);
- if (ChartboostEventListener_HC._instance != null)
- {
- if (PlayerPrefs.GetInt ("CHARACTER_RemoveAds", 0) == 0) && if (ClickCounter >= 500)
- {
- ChartboostEventListener_HC._instance
- ChartboostAndroid.showInterstitial ("Default");
- ClickCounter = 0;
- }
- }
- #endif
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement