Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
2
Question by Giantbean · Jun 21, 2019 at 12:57 AM · statistics

How do you track player gameplay statistics?

I am trying to figure out how to make a game manager for tracking statistics however when ever I search this topic it comes up with RPG attributes. Unfortunately "stats" and "attributes" have become completely conflated and I can't find any information on tracking actual statistics. So I need to be pointed in the right direction with any lingo that you forum pros may know of.

To clarify I'm not looking for Unity analytics and I don't want computer statistics such as frames per second. I'm looking for something more like an in game achievement however achievements are normally single events like "Reached the top of the mountain" or "reached XX meters high" which could update as new heights are reached. That's fine but I want to know the best way to capture more analytical data that could be displayed in a menu for both serious and fun little things. Think of the Statistics menu in an old spider-man game that told you how many steps you had taken, how many webs you had shot, and how many meters you had swung etc. Or the Statistics in Horizon Zero Dawn that has game progression and statistics menus (and yet searching the web for their statistics menu yields no results :\ ). They tell you how many people you killed, how many where head shots, how many side quests you completed, how many camp fires activated etc etc. Not Trophy's not achievements just player statistical data-points. Yes Anylitics is close to what i am looking for but I want to report these to the player rather then hide them and require a raw data export for me to view.

Have any of you done this? What suggestions would you have for someone researching how to accomplish this? Should I just hink of them as Achievements and Trophy's?

Thanks.

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by DanVioletSagmiller · Jun 21, 2019 at 06:10 AM

Analytics is the first thing I use to track this, as you can create custom metrics to follow, allowing the tracking of all of what it sounds like you want. But that does miss the requirement that it needs to be on the client machine. This would be similar to Experience in for an RPG game. It becomes a variables saved with the save game files. You could look into PlayerPrefs, and increment the values you want as you go. Then later on, you can retrieve them to use on the client only. Here is an example:

 public void IncrementStat(string statName)
 {
   // potentially insert line here to push this to analytics if you want to see it as well.  
   var val = PlayerPrefs.GetInt(statName);  // will default to zero if it doesn't exist.
   val++;
   PlayerPrefs.SetInt(statName, val);
 }

 public int GetStat(string statName)
 {
   return PlayerPrefs.GetInt(statName);
 }
Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Giantbean · Jun 21, 2019 at 02:37 PM 0
Share

Thank you for the answer. I thoughts playerPrefs may have been what I was missing but its too limited for the scope of my needs. Ins$$anonymous$$d it looks like I'm just going to have to program this from scratch into a json file (with a binary format for security) and continue to be mystified as to why the industry conflates attributes analytics and statistics. At least analytics are similar and attributes are used in stats; but most posts link statistics to attributes as the same thing; as if words had no meaning. I suppose its due to the similarity as an attribute defines the property of an object. however a stat is not the same as saying someones strength is x. A stat is a piece of data from a large quantity of numeric data such that x is x players strength and with many such data points we could deter$$anonymous$$e a mean strength of all players. This however becomes silly as no one cares what the average player strength attribute is but they may care about the average, $$anonymous$$ , max and mean of their own game play to understand player and $$anonymous$$m progress and deter$$anonymous$$e things like hit ratios when x shots where fired, x hit and x of x hit a bullseye. It may be subtle but to my $$anonymous$$d a stat and an RPG attribute are clearly different.

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

105 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Does anyone have figures which show the take-up ratio for new users hitting unity webplayers for the first time? 2 Answers

Creating Unity Statistics Plugin 0 Answers

Disabled Analytic and HW Statistic but Unity still use cdp.cloud.unity3d.com 1 Answer

Showing Full FPS 1 Answer

How to check webplayer draw calls, triangles and other statistics without Unity source project? 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges