Clear all

Leaderboard scores not showing?

Active Member Registered

Hi, I'm just testing Combu on my server in a blank project with only the combu package added.

So far it's working great but I did notice that leaderboard scores are not showing on the server, they show in the Unity demo scene though.

Also, is there a quick way of clearing the scores, say every week or month?


Topic starter Posted : 12/06/2020 4:15 pm
Prominent Member Admin

You're right, I forgot to add the new userScope variable to the call of scores in that page.

For now you can edit /admin/leaderboards.php, at line 186 there should be a call to $leaderboard->LoadHighscore, change it with the following:

$scores = $leaderboard->LoadHighscore(LeaderBoard::HIGHSCORE_TOTAL, LeaderBoard::USERSCOPE_GLOBAL, FALSE, FALSE, 0, $limit, Utils::GetPageOffset($page, $limit), $count);


It should fix the issue, I'm already working on the next update that will bring a new optimization in the admin website by using Smarty template framework to better divide code logic from HTML presentation of the admin pages, but it'll take a good amount of time before releasing it.

About the question on auto-clearing leaderboards, there's no such feature, but you could create a simple PHP script to TRUNCATE or DELETE all records in the "LeaderBoard_User" table and add a scheduled task in your server to call it once per month/week. Usually the hosting providers gives a page to manage scheduled tasks on the customer area, else if you are on your own server then you can setup a task with cron on Linux or Scheduled Tasks on Windows.


Posted : 13/06/2020 12:45 pm