private void Start() { log("Start"); //ChocolateUnityBridge.SetAdRequestTestMode(true, "xxxxxxxx"); //OPTIONAL TEST MODE //appInfo is mandatory. However, ads can still be fetched. ChocolateUnityBridge.setAppInfo("MyAppName", "MyPublisherName", "MyDomainName", "PublisherDomain", "MyPlayStoreUrl", "My IAB Category"); //OPTIONAL: Ad Request User Parameters //ChocolateUnityBridge.SetAdRequestUserParams(18, "", "M", "Single", "Asian", "", "", "", "", ""); ChocolateUnityBridge.initWithAPIKey("XqjhRR"); //Our test key. Replace with yours in production. ChocolateUnityBridge.setInterstitialAdListener(this); ChocolateUnityBridge.setRewardAdListener(this); }
void SetupListener() { // ChocolateUnityBridge.setupWithListener("Canvas"); ChocolateUnityBridge.setInterstitialAdListener(this); ChocolateUnityBridge.setRewardAdListener(this); listenerSetup = true; //Debug.Log("Listener info:"); //Debug.Log("" + this.ToString() + " | " + // this.name + " | " + // this.tag + " | " + // this.gameObject.ToString() + " | " + // this.gameObject.tag); }