Jump to content

Ads with CocoonJs + Phaser


mown
 Share

Recommended Posts

Hi everyone

am trying to implement ads in my game

i read all about this thing , i made mopub account , and i took the banner ad id and put it in compiler configuration (i have a premium account) , also integrated admob with mopub , and referenced both (cocoon.js , cocoon_ad.js latest version) in my game after all i wrote the following code :

 

Cocoon.Ad.banner.on("shown", function () {
            console.log("Banner shown!");
        });
        Cocoon.Ad.banner.on("ready", function () {
            console.log("Banner Ready!");
            Cocoon.Ad.setBannerLayout(Cocoon.Ad.BannerLayout.BOTTOM_CENTER);
            Cocoon.Ad.showBanner();
        });
        Cocoon.Ad.banner.on("hidden", function () {
            console.log("Banner hidden!");
        });
 
none of the "console.log" is triggered , could you please help guys
thanks a lot.
Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...