I set up iAds
[lua]–this is a comment
local ads = require “ads”
local function adListener( event )
local msg = event.response
if event.isError then
– Failed to receive an ad, we print the error message returned from the library.
print(msg)
end
end
ads.init( “iads”, “myAppId”, adListener )–I put in “myAppID” my iOS bundle.
ads.show( “banner”, { x=0, y=0 } )
[/lua]
It works, but I would like to place admob when iAds si not available in a country.
—******************************************------------
[lua]
I put the admob , I would like to know if this code works.
local ads = require “ads”
local function adListener( event )
local msg = event.response
if event.isError then
– Failed to receive an ad, we print the error message returned from the library.
print(msg)
local provider = “admob”
local BannerAppID = “cfsfwffwfwfwfwfwfwfwfwfwfwfwfwf”
ads.init( “admob”, BannerAppID, adListener)
ads.show( “banner”, { appID= BannerAppID,x=0,y=0,testMode = false} )
end
end
ads.init( “iads”, “myAppId”, adListener )–I put in “myAppID” my iOS bundle.
ads.show( “banner”, { x=0, y=0 } )
[/lua]