DarkflameServer
DarkflameServer copied to clipboard
BUG: Racing doesn't update leaderboards (missing code)
Make sure you've done the following:
-
[X] I have checked that this issue has not already been reported.
-
[X] I have validated that this issue is not a syntax error of either MySQL or SQLite.
-
[X] I have pulled the latest version of the main branch of DarkflameServer and have confirmed that the issue exists there.
Issue Description
Problem:
Racing doesn't update leaderboards
Solution/root of problem:
From my look into the code, it looks like the code for updating the leaderboards is not implemented in the racing code. https://github.com/DarkflameUniverse/DarkflameServer/blob/ad52facef71e1349057512237ccbd0b157af19f9/dGame/dComponents/RacingControlComponent.cpp#L860
Looking at other minigames with functioning leaderboards, they all call StopActivity
https://github.com/DarkflameUniverse/DarkflameServer/blob/02bf5937dc2b22cad2d0e2e330c928235fd72c13/dScripts/BaseSurvivalServer.cpp#L380
which in turn calls SaveScore
.
https://github.com/DarkflameUniverse/DarkflameServer/blob/0531365cb55d8954c240b8f0096ece0d1fe6bf1e/dScripts/ActivityManager.cpp#L76
I can't seem to find anything similar to that in the racing code.
Reproduction steps
- Complete a race on any track
- Notice score doesn't get pushed to leaderboard
Expected Behavior
Leaderboards should be updated when a race is finished
Environment
Google Cloud Debian 11