Last Update  YouTube Video Likes

New update v2.12 released!
What's new?

FAQ


How to create a leaderboard using this tool?

Press the "Create New Leaderboard" button and wait for the leaderboard to generate.


How to use a generated leaderboard?

  1. Copy and save the secret key of your leaderboard somewhere else in your system.
  2. Copy the public key of your leaderboard.
  3. Download the Unity package of the tool and drag it into your Unity project.

• Include this dependency in your script where you want to access your leaderboard:

using Dan.Main;

• To get the entries in your leaderboard, call this function:

LeaderboardCreator.GetLeaderboard(string publicKey, Action<Entry[]> callback)

If the function is called and the request is successful, the callback is called, an array of Entry objects is returned. An entry contains:

[System.Serializable]
public struct Entry
{
    public string Username { get; set; }
    public int Score { get; set; }
    public ulong Date { get; set; }
    public string Extra { get; set; } 
}

Notes:

  • Date - Unix timestamp of the last time the entry was uploaded/modified
  • Extra - Extra string of data, you can use this however you like depending on your game. But make sure that the length of the string does not go over 100, otherwise it will get truncated and not all your data will be saved.


• To upload a new entry into your leaderboard, call this function:

LeaderboardCreator.UploadNewEntry(string publicKey, string username, int score, Action<bool> callback)

• To upload a new entry, with an extra field, into your leaderboard, call this function:

LeaderboardCreator.UploadNewEntry(string publicKey, string username, int score, string extra, Action<bool> callback)

If you're not using Unity as an engine, do not worry, as you can still use your leaderboard anywhere.

• To get your leaderboard to send an HTTP GET request to this URL:

https://lcv2-server.danqzq.games/get?publicKey=PUBLIC_KEY

Replace PUBLIC_KEY with your leaderboard's public key.

• To upload a new entry to your leaderboard to send an HTTP POST request to this URL:

https://lcv2-server.danqzq.games/entry/upload

In your POST request, make sure to add the next forms:
- Form name: "publicKey", value: the public key of your leaderboard.
- Form name: "username", value: the player's username.
- Form name: "score", value: the player's highscore.
- Form name: "extra", value: extra data of the player (optional)


Where is the data of the leaderboards stored?

All of the data is stored in a cloud-based database.


How do I migrate my old leaderboard?

Click "Migrate Old Leaderboard", copy and paste your leaderboard's public key, and you will instead get a new leaderboard but with your old leaderboard's entries. Then you follow the updated steps on how to add your new leaderboard into your project.


What if I lost my secret key?

If you lose your leaderboard's secret key by accident but you still have your public key, contact me on Discord: @DAN#3389


Some games that use Leaderboard Creator:


Does your game also use Leaderboard Creator?

Click here to request its addition to the list!


Credits

Updated 11 days ago
StatusReleased
CategoryTool
PlatformsHTML5
Rating
Rated 5.0 out of 5 stars
(6 total ratings)
AuthorDanial Jumagaliyev
Made withUnity
Tagsleaderboard, leaderboard-creator, networking, online-leaderboard, Unity, Unreal Engine

Download

Download NowName your own price

Click download now to get access to the following files:

Leaderboard Creator V2.12 (Unity Package) 580 kB

Development log

Comments

Log in with itch.io to leave a comment.

Hello, when will the server be back online. Or am i missing out something

It should be online, maybe try connecting with a VPN?

(2 edits)

UNity's giving me an error: "The name "JsonConvert" does not exist in the current context. Also, is there any way to get just the "Rank" value or is that the Entry index?

(+1)

Oh, I forgot to mention that you need to import the Json converter from Newtonsoft: https://docs.unity3d.com/2019.4/Documentation/Manual/com.unity.nuget.newtonsoft-...

I might update the download file and include Newtonsoft.Json with the Unity package.

The rank is the entry index, I should've pointed out that the entries are returned in a descending order by score.

(1 edit)

Welp, I'm too noob and I can't figure out how to get Newtonsoft. Clicking your link takes me to a Unity Manual. Clicking that takes me to another one. Link there takes me to Json.Net. CLicking "Download" gives me two options that I can see, none of which I know what to do with, really. I go to Rider and there's an option there to install Newtonsoft.Json, which I did, but it doesn't fix the problem.

  1. Open the Package Manager window in your Unity project.
  2. Click the plus icon on click "Add package from git URL"
  3. Paste this in the URL field and then press Add:
com.unity.nuget.newtonsoft-json@3.0


Well that did the trick! And now I feel silly for forgetting about adding packages that way...

Hey, me again! I really don't want to bother other devs so I plugged away at this for several days but it I can't seem to get it to upload more than one entry in my leaderboard.

I have a script that only uploads an entry if no similar score exists. Every thing's fine if the leaderboard is empty. However, if there's already an entry, a new entry doesn't seem to get uploaded.

What happens is when I get a new score the script runs UploadNewEntry . I get a "successfully uploaded entry data" message. I then run GetLeaderboard to fetch the new entry. I get a "Successfully retrieved" message but no new entry actually appears.

When I clear the leaderboard and run the script again, the new entry appears but no new ones will.

OK. I think I found the issue. It won't upload a new value if the username is already in the leaderboard. I tested it here and in my script.

(1 edit)

Just to note, the score will only get uploaded and submitted if its higher than the previous one in the leaderboard.

Is there a way to remove entries?

At the moment there is not. However I am planning to update this application further down the line, and add a way to delete entries. In the meantime, you can send me your leaderboard details and the entry to delete if you want to delete and entry.

Hey, just wanted to let you know, I updated this tool. You can now migrate your old leaderboards (if you had any), to this new version of the tool and have more control over your leaderboards.

(+1)

Awesome !!! Just wondering, where is the data stored ?

(+1)

Thanks! The data is stored in a cloud database.