hi i want to create a simple game with online leaderboards that include players names and scores and players had UniqeID i have my own host and server but i dont know how to code online leaderboards. there was some videos and i look all of them but no one of them was complete and clear. i want to do some thing fundamental not easy way or use plugin for leaderboard. i want code a simple leaderboards and use my own host. all things i know is that i should create database and table but i dont know how to code it. please someone help me.
I just implemented leaderboard functionality into my game, so I can be of some help. Essentially, here's a high-level overview of what I did: Create your leaderboard on a BaaS solution (I picked Braincloud because it offers native support for gamification features and comes with a handy Unity SDK). Make your game authenticate with Brainclould - anonymously or through Facebook At defined points in the game, send the score back to the server for storage and pull the updated leaderboard from the server in the form of a JSON file Parse the JSON into the corresponding variables that then get displayed in the UI Note that how you choose to authenticate will determine what gets displayed in the leaderboard - for example, if you choose to go with anonymous identification, you'll find it impossible to associate a user's score with anything other than their device ID. For this reason, it's often better to link leaderboards with Facebook (then you can display the user's real-life name next to their score) or a dedicated authentication solution which stores their displayed username on the server. Hope it helps - if you choose to go with Braincloud, I can take a look at the code, too.