Version: 2018.4
Receipt Verification
Best practice guides

User Attributes

Unity AnalyticsA data platform that provides analytics for your Unity game. More info
See in Glossary
offers the ability to track user demographics. This provides you with robust ways to filter your data to look at different user segments. This information is pulled from player information entered at signup or from third-party SDKs.

// Reference the __Unity Analytics__See Analytics [More info](UnityAnalytics.html)<span class="tooltipGlossaryLink">See in [Glossary](Glossary.html#UnityAnalytics)</span> SDK package
  using UnityEngine.Cloud.Analytics;

  // Use this call to designate the user gender
  UnityAnalytics.SetUserGender(Gender gender);

  // Use this call to designate the user birth year
  UnityAnalytics.SetUserBirthYear(int birthYear);
Input Parameters
Name Type Description
gender enum Gender of user can be Gender.Female, Gender.Male or Gender.Unknown.
birthYear int Birth year of user. Must be 4-digit year format only.

For example:

  Gender gender = Gender.Female;
  UnityAnalytics.SetUserGender(gender);

  int birthYear = 2014;
  UnityAnalytics.SetUserBirthYear(birthYear);
Receipt Verification
Best practice guides