Jump to content

[TOPIC: topicViewTemplate]
[GLOBAL: userSmallPhoto]
Photo

Applovin banner and how to set childDirectedTreatment
Started by Android123 Jun 12 2018 10:03 AM

10 replies to this topic
applovin ads banner setchilddirectedtreatment sethasuserconsent gdpr
[TOPIC CONTROLS]
[/TOPIC CONTROLS]
[modOptionsDropdown]
[/modOptionsDropdown]
[reputationFilter]
[TOPIC: post.html]
#1

Android123

[GLOBAL: userInfoPane.html]
Android123
  • Observer

  • 21 posts
  • Corona SDK

Hello, I create a game for Android and I use Applovin ads. Once the game starts, I want to show text like this "By agreeing, you confirm that you are over the age of 16 and would like a personalized ad experience". Then I would like to set childDirectedTreatment to false, but I did not find an example for this. Is this the correct way

local function adListener( event )
    if ( event.phase == "init" ) then  -- Successful initialization
        -- Set user consent
        applovin.setHasUserConsent( true )
    end
end


-- init
applovin.init( adListener, { sdkKey=sdkKey, verboseLogging=false, testMode=true } )
 
Also, I want to ask in which case we should set childDirectedTreatment to false/true? I am not sure about this.
 
By the way, if I put applovin banner in main menu, 
function scene:show( event )


    if event.phase == "did" then
        applovin.show( "banner", {yAlign="top"} )
    end


end
 
Then, if "play button" button is pressed, I try to hide banner 
applovin.hide( "banner") 
and it gives me this error in simulator attempt to call field 'hide' (a nil value)
 
I can load and show interstitial ads in the same file.


[TOPIC: post.html]
#2

roaminggamer

[GLOBAL: userInfoPane.html]
roaminggamer
  • Corona Geek

  • 6,969 posts
  • Corona SDK

1. Dialog - If you want to show a dialog with a question use: 

https://docs.coronalabs.com/api/library/native/showAlert.html

 

For example, in my 'Bird Climb - Skinning & Modding Template' I have an option to show this dialog:

gdp_dialog.png

 

 

2. childDirectedTreatment - If your app is COPPA compliant you set it to 'true'

 

**UPDATE** Does not apply.  OP was asking about AppLovin which does not support a COPPA setting.

 

3.  Ads in Simulator - You cannot (by default) test Ads in the simulator.  Only on device.  Note: My aforementioned template has a 'fake ads' module that lets one test ads basic behaviors in the simulator.  I will be releasing the fake ads module in the future, but it is not ready for general consumption right now.

bird_climb_shop%2Bfakeads.png


Edited by roaminggamer, 12 June 2018 - 12:57 PM.

  • agramonte likes this

[TOPIC: post.html]
#3

agramonte

[GLOBAL: userInfoPane.html]
agramonte
  • Contributor

  • 757 posts
  • Corona SDK

1. Where do you see the "childDirectedTreatment" in the documentation? Do you mean:

applovin.setHasUserConsent( hasUserConsent )

2. Are you redefining applovin anywhere? Is the definition you expect to use still in scope. Try adding the applovin def right above the request to hide. From what little code you provided I don't believe your previous definition would still be in scope.

local applovin = require( "plugin.applovin" )
applovin.hide("banner")


[TOPIC: post.html]
#4

agramonte

[GLOBAL: userInfoPane.html]
agramonte
  • Contributor

  • 757 posts
  • Corona SDK

@roming do you have a video of this new template?



[TOPIC: post.html]
#5

Android123

[GLOBAL: userInfoPane.html]
Android123
  • Observer

  • 21 posts
  • Corona SDK

I know we cannot see ads in simulator, but I can put load and show functions in menu to "load" or "show" interstital and video ads, at least it does not show error message, but if I want to hide banner it gives me error, and game stops.

 

COPPA

I do not collect any data (exept using Applovin) and users must confirm they are over the age of 16. The game is ok, anyone can play it, but it does not target children as its primary audience. So, should I set childDirectedTreatment to false or true:)

I do not understand this thing, 

 

Edit: I see childDirectedTreatment in Appodeal documentation, so just asking, I do not want to miss something.



[TOPIC: post.html]
#6

agramonte

[GLOBAL: userInfoPane.html]
agramonte
  • Contributor

  • 757 posts
  • Corona SDK

Appodeal? or Applovin? What provider are you using?

 

Here is applovin:

 

https://docs.coronalabs.com/plugin/applovin/index.html

 

Here is appodeal:

 

https://docs.coronalabs.com/plugin/appodeal/index.html



[TOPIC: post.html]
#7

Android123

[GLOBAL: userInfoPane.html]
Android123
  • Observer

  • 21 posts
  • Corona SDK

I use Appodeal for one game and I want to use Applovin for another game. So, I see childDirectedTreatment in Appodeal documentation and I wonder is there any way to set this if I use Applovin, or it is enough to use this

applovin.setHasUserConsent( true )


[TOPIC: post.html]
#8

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 24,527 posts
  • Corona Staff

Just because one plugin has an API call like .setHasUserConsent() doesn't mean another plugin has the same API call. Applovin uses this API call. Appodeal passes a true/false value on it's .init() call.

 

Also I don't think you need to worry about childDirectedTreatment. The default is to show ads that show for everyone. By setting childDirectedTreatment to true, you only get COPPA compliant kids ads if your app is specific to 13 and under. 

 

Rob



[TOPIC: post.html]
#9

roaminggamer

[GLOBAL: userInfoPane.html]
roaminggamer
  • Corona Geek

  • 6,969 posts
  • Corona SDK

Ah yes.  I assumed you were asking about a feature that the AppLovin plugin provides. 

 

I was just working with both Appodeal and Applovin so I know what the COPPA flag is, but I didn't bother to confirm you were taking about the correct plugin.



[TOPIC: post.html]
#10

Android123

[GLOBAL: userInfoPane.html]
Android123
  • Observer

  • 21 posts
  • Corona SDK

Thank you everyone.



[TOPIC: post.html]
#11

agramonte

[GLOBAL: userInfoPane.html]
agramonte
  • Contributor

  • 757 posts
  • Corona SDK

@android you set the under 16 in the control panel in Applovin for the app. If you are using the free version of the plugin, you will need to contact corona to make sure they make the same change to the impressions that they take.

 

The hasConsentFlag is also not necessary to set. In the Applovin control panel, you can set the consent is always false for EU persons.




[topic_controls]
[/topic_controls]

Also tagged with one or more of these keywords: applovin, ads, banner, setchilddirectedtreatment, sethasuserconsent, gdpr