Search Unity

Official Unity Analytics Data Privacy Plug-in Available Now in the Asset Store

Discussion in 'Unity Analytics' started by ap-unity, May 21, 2018.

  1. Swah

    Swah

    Joined:
    May 13, 2015
    Posts:
    23
    Thank you @coshea for being thorough on this. I have the same question, which I've been trying to get an answer to here and by email. To emphasize the reason this is a problem for kid app developers: we can't easily ask for consent, as kids cannot give consent and it's hard to ensure parents saw the consent form. So an opt-out form is not an option.
     
  2. coshea

    coshea

    Joined:
    Dec 20, 2012
    Posts:
    244
    So specific question regarding this plugin...

    The plugin fetches the optout status from playerprefs then the url and calls function SetOptOutStatus and sets the following:

    Code (csharp):
    1.  
    2. Analytics.enabled = Analytics.enabled && optOutStatus.analyticsEnabled;
    3.                
    4. Analytics.deviceStatsEnabled = Analytics.deviceStatsEnabled && optOutStatus.deviceStatsEnabled;
    5.                
    6. Analytics.limitUserTracking = Analytics.limitUserTracking || optOutStatus.limitUserTracking;
    7.               PerformanceReporting.enabled = PerformanceReporting.enabled && optOutStatus.performanceReportingEnabled;
    8.  
    From testing this, the only thing that changes if you opt out on the privacy page is limitUserTracking, correct?

    optOutStatus.analyticsEnabled and optOutStatus.performanceReportingEnabled are being pulled from the project settings (from online)?

    Under what situation would deviceStatsEnabled be true (or off)? This isn't the Player hardware stats is it.
     
  3. CarinaMclane

    CarinaMclane

    Joined:
    Mar 12, 2014
    Posts:
    23
    Hi!

    I'm trying to use this plugin for a client project, however I am unable to find the Data Privacy icon that is referred to in the documentation and in the wider Unity privacy policy.

    At https://docs.unity3d.com/Manual/UnityAnalyticsDataPrivacy.html the documentation says, for Method 2:

    However, this icon does not seem to exist in the asset I retrieved from the asset store.

    Is there an alternative place I could get this from?

    Thanks!
     
  4. ap-unity

    ap-unity

    Unity Technologies

    Joined:
    Aug 3, 2016
    Posts:
    1,085
    @CarinaMclane,

    Yes, it will be in the next version of the plug-in, which should be released soon.

    In the meantime, here is the icon:
     

    Attached Files:

  5. CarinaMclane

    CarinaMclane

    Joined:
    Mar 12, 2014
    Posts:
    23
    Fab, thank you!
     
  6. sadstorygr

    sadstorygr

    Joined:
    Jul 22, 2014
    Posts:
    5
    Hello ap-unity, I have a problem getting the following work.
    ////////////
    using UnityEngine.Analytics;
    ...{
    void OnOptOutStatus(bool optOut)
    {
    if (optOut)
    {
    Debug.Log("Player has opted-out of personal data collection.");
    }
    }
    DataPrivacy.FetchOptOutStatus(OnOptOutStatus);
    }
    ////////////////////
    Error: "The name DataPrivacy.FetchOptOutStatus does not exist in the current context" althought I use .Analytics, what can be the problem for this?
     
  7. ap-unity

    ap-unity

    Unity Technologies

    Joined:
    Aug 3, 2016
    Posts:
    1,085
    @sadstorygr

    Have you installed the latest version of the Data Privacy plug-in?
     
  8. sadstorygr

    sadstorygr

    Joined:
    Jul 22, 2014
    Posts:
    5
    Yes, I installed the plug-in today, the name is shown in blue in Visual Basics but still not recognized. Do I have to add the script to a gameobject inside my scene and get it as a component to run the line?
     
  9. Klednik

    Klednik

    Joined:
    Aug 4, 2017
    Posts:
    1
    Hello ap-unity. We use data privacy plugin in our game because of IAP and currently i working on performace improvement. One thing what i found and what really bother me is that every click on UI button call coroutines of DataPrivacy script. Actualy, we do not need data from analytics so my question is that is there some posibility to turn off mentioned behauvior of data privacy plug in?
     
  10. sadstorygr

    sadstorygr

    Joined:
    Jul 22, 2014
    Posts:
    5
    Ok, figured out my stupidity, I was running
    DataPrivacy.FetchOptOutStatus(OnOptOutStatus);
    outside a method. Working fine, thank you
     
  11. JamesArndt

    JamesArndt

    Joined:
    Dec 1, 2009
    Posts:
    2,594
    Okay so reading this I am understanding the following: If my game does not use any services, ads or analytics...so as the developer I am requesting no player data, and Unity themselves are the only ones pulling data for their own legitimate business interests, then I require no consent form for the user. It seems pretty clear in that body of text that the embedded Unity stats that Unity is taking from the user are covered by a legitimate business clause and therefore exempt from requiring consent.

    "With legitimate interests as a legal basis for its processing, Unity does not require consent."
     
  12. RealMTG

    RealMTG

    Joined:
    Jul 27, 2013
    Posts:
    220
    In 2018.3 it says the plugin should not be used and is included in analytics, but I can't figure out how to use it. Any guidance on how I can use it?
     
    JamesArndt likes this.
  13. iddqd

    iddqd

    Joined:
    Apr 14, 2012
    Posts:
    332
    So what do you do, when your app is using several services that collect data, let's say: Photon, Unity Analytics, Firebase, Gamesparks? (Let's assume they are 4 services that collect data)
    Would that mean 4 opt-out buttons?

    Thanks
     
  14. Raubi

    Raubi

    Joined:
    Apr 3, 2015
    Posts:
    1
    I've basically the same problem. Can not find anything in the Analytics Lib 3. Where did it go?
     
  15. ap-unity

    ap-unity

    Unity Technologies

    Joined:
    Aug 3, 2016
    Posts:
    1,085
    Yeah, the Data Privacy Asset Store plug-in was not designed to work with 2018.3, so you may run into errors when you import it.

    The Data Privacy plug-in will be embedded in the next version of the Analytics package, which will be available via Package Manager. It should be available soon.
     
    JamesArndt and RealMTG like this.
  16. Jelmersb

    Jelmersb

    Joined:
    Jul 12, 2016
    Posts:
    66
    Hi, I want(need*) to make my app opt-out of any personal data gathering by default, while still using remote settings and get some analytics. possible?

    * Or I'll have to switch off analytics sadly, orders from our security department..
     
  17. JCHach

    JCHach

    Joined:
    Dec 12, 2014
    Posts:
    5
    Hi,
    On november 2018, i publish a new version of my app with 2018.2 Unity version and on the day after, my DAU drop a lot... And i see people continue buying my in-app at same rate... So it seems that it's only Analytics that are blocked by something...

    So i found out the Data Privacy Plug-in etc... And integrate it, add the button somewhere in my UI. But, it seems that nothing change...

    So i install 2018.3 version, remove the imported Data Privacy Plug-in as it is included in Analytics now... But nothing change...

    Do i have to call something to make it work back ? I see on other post that when i click play on my project, i must get LOG that show the opt-out status but i don't get it...
     
    Last edited: Feb 8, 2019
  18. JeffDUnity3D

    JeffDUnity3D

    Unity Technologies

    Joined:
    May 2, 2017
    Posts:
    3,685
  19. sfjohansson

    sfjohansson

    Joined:
    Mar 12, 2013
    Posts:
    275
    Instead of having to open an external url would this simple piece of code take care of the users "privacy" for the unity services, ie Ads, Analytics and Performance Reporting:

    Code (CSharp):
    1. gdprMetaData.Set("consent", "false");
    2.         Advertisement.SetMetaData(gdprMetaData);
    3.  
    4. Analytics.limitUserTracking=true;
    That's pretty convenient to hook up to a button in-game..this assumes that all data collection done when enabled is fine to collect without the users consent.

    If that's not enough then disabling analytics and performance reporting completely is the next option.
     
    Last edited: Feb 15, 2019
  20. veugeljame

    veugeljame

    Joined:
    May 2, 2016
    Posts:
    9
    I'm currently using 2018.3 and can see that the Analytics Package is installed and enabled. I have hooked up Analytics to work but am unable to use the DataPrivacy class to show the external link.
     
  21. antifuzz

    antifuzz

    Joined:
    Feb 22, 2013
    Posts:
    70
    technicat and sameer-mirza like this.
  22. HiddenJason

    HiddenJason

    Joined:
    Apr 18, 2016
    Posts:
    3
    We're now getting automatically removed from Google Play because the privacy policy isn't being presented to the user at the time the Advertising ID is requested.

    We don't actually care about supporting Analytics, and it's only being dragged in through our use of UnityIAP. As the timing of the request for advertiser ID is nothing we can control, and that request is apparently not disabled by the "Disable HW Statistics" option, UnityIAP no longer appears to be viable on Google Play due to the forced inclusion of Analytics. Using an "opt-out" button / web page (per the Data Privacy plugin) is apparently not sufficient for Google's bots that are checking for this behavior.
     
    peterk1968 likes this.
  23. peterk1968

    peterk1968

    Joined:
    May 11, 2015
    Posts:
    44
    I've recently had an app get dinged off of the Google Play store due to a
    Android Advertising ID violation.
    I don't use any in app advertising but I am using Unity IAP and I think this is happening because Unity Analytics is grabbing that piece of info for some reason. Not sure why. I'm on Unity IAP v1.16 but have downloaded 1.22 (the latest) and the Changelog doesn't have any mention of that being changed.

    Now, I'm searching for the quickest/easiest way to get past this and one way is just to disclose that some data might get collected and allow the user to opt-out.

    The Google guidelines state that

    Your app must provide an in-app disclosure of your data collection and use. The in-app disclosure:
    • ......
    • Must be displayed in the normal usage of the app and not require the user to navigate into a menu or settings;
    ...so I'm a little hesitant to use this plug-in to deal with the issue. Expecting the user to push a Privacy Settings button - and I would definitely try to hide that on a Settings page away from game play - still violates their guidelines.

    Can someone confirm that using the plug-in is sufficient to move past this with Google.
     
    Last edited: Mar 19, 2019 at 11:31 PM
  24. ChirsGeorge

    ChirsGeorge

    Joined:
    Oct 3, 2018
    Posts:
    1
    Hi, I am running 2018.3.8f1 and I get an error in the PackageCache on WebGL builds only. I can build Standalone, WinStore, Android, and iOS with no issues; but WebGL keeps throwing this error

    Code (CSharp):
    1. Library/PackageCache/com.unity.analytics@3.2.2/DataPrivacy/DataPrivacyButton.cs(28,25): error CS0618: Warning as Error: 'UnityEngine.Application.ExternalEval(string)' is obsolete: 'Application.ExternalEval is deprecated. See https://docs.unity3d.com/Manual/webgl-interactingwithbrowserscripting.html for alternatives.'
    Any help would be appreciated.
     
  25. JeffDUnity3D

    JeffDUnity3D

    Unity Technologies

    Joined:
    May 2, 2017
    Posts:
    3,685
    I just built to WebGL using Unity 2018.3.4f1 with the Data Privacy Button included without error. It's a very basic project with the button added https://forum.unity.com/threads/sample-iap-project.529555/