[solved] LeaderBoard wont show because of members amount

hello guys
today i come with new problem :slight_smile:
i try to use firebase leader board , so i use this tutorial :

to prevent any mistake i downloaded zip file from here :

at first it was very good but now , my members are more than 600 person and leader board cant show them to me and game preview will be freeze and stop working

i try this :
i try to use limit amount of documents , i set it to 10 , not worked
i use only leader board file as i linked above , its not working too , because amount of users

is there any solution?

Are you trying to display the 600 scores?
Anyway, we cannot provide any solution unless we have all the details of the problem.
Expected result VS actual result, and relevant screenshots of game and events.
If the preview freezes, you can also open the console (ctrl-shift-i) to check for information.

1 Like

hello dear @Gruk
i use this sample and its not working , if is that possible check it please

here is game events

i want to show 40 person of top highscores , but nothing show up and just freeze in this screen

Did it work when there were only few scores?
You need to use the callback to know what is going on, this:

1 Like

thank you dear @Gruk , i solve it with Status to get problem

but is there something else
looks like every score that g develop send to leaderboard , its save as a string , so problem is , when i want to order documents by highscore list will not be correct, what do you suggest for this?

as you see score 911 should be at first but its third , also 635 and 422
and if is there anyway to remove people without name , that leaderboard show their name “0”

Add a condition to check the name before displaying it, or force people to enter a name before allowing score upload.
Why store the score as a string if you want a number? :person_shrugging:

1 Like

i add a field while registering to enter their name
but i don’t know how to upload score as a number to firebase , would you please guide me?

You can check in Firestore if your number is stored as a string or number, numbers don’t have quotes:
Aside from that, it’s simply a matter of using a number variable instead of a string variable.


i try many way but any number i upload to firebase will be a string

would you please tell me how to upload number using firebase update field?

I have a variable structure containing the name and score, and I send the variable structure using “update a document” or “add a document”, depending on whether a score is already saved for that player.

1 Like

worked perfectly
thank you bro @Gruk <3

Nice, good job! :+1:

1 Like