mirror of
https://github.com/zkldi/Tachi.git
synced 2026-10-07 06:18:03 +03:00
refactor: rename score-leaderboard to PB leaderboard
This commit is contained in:
@@ -41,7 +41,7 @@ export default function GPTLeaderboardsPage({ game, playtype }: GamePT) {
|
||||
</SelectButton>
|
||||
<SelectButton id="score" value={mode} setValue={setMode}>
|
||||
<Icon type="sort-numeric-up-alt" />
|
||||
Score Leaderboards
|
||||
PB Leaderboards
|
||||
</SelectButton>
|
||||
</div>
|
||||
</Col>
|
||||
@@ -53,7 +53,7 @@ export default function GPTLeaderboardsPage({ game, playtype }: GamePT) {
|
||||
<ScoreLeaderboard
|
||||
game={game}
|
||||
playtype={playtype}
|
||||
url={`/games/${game}/${playtype}/score-leaderboard`}
|
||||
url={`/games/${game}/${playtype}/pb-leaderboard`}
|
||||
/>
|
||||
)}
|
||||
</Col>
|
||||
|
||||
+2
-2
@@ -65,8 +65,8 @@ export default function RivalsComparePage({
|
||||
<ScoreLeaderboard
|
||||
game={game}
|
||||
playtype={playtype}
|
||||
refreshDeps={[`rivals-score-leaderboard-${settings.rivals.join(",")}`]}
|
||||
url={`/users/${reqUser.id}/games/${game}/${playtype}/rivals/score-leaderboard`}
|
||||
refreshDeps={[`rivals-pb-leaderboard-${settings.rivals.join(",")}`]}
|
||||
url={`/users/${reqUser.id}/games/${game}/${playtype}/rivals/pb-leaderboard`}
|
||||
/>
|
||||
</Route>
|
||||
|
||||
|
||||
@@ -507,9 +507,9 @@ GET /api/v1/games/bms/7K/tableID/insane
|
||||
|
||||
*****
|
||||
|
||||
## Retrieve the score leaderboard for this Game.
|
||||
## Retrieve the PB leaderboard for this Game.
|
||||
|
||||
`GET /api/v1/games/:game/:playtype/score-leaderboard`
|
||||
`GET /api/v1/games/:game/:playtype/pb-leaderboard`
|
||||
|
||||
### Parameters
|
||||
|
||||
@@ -522,7 +522,7 @@ GET /api/v1/games/bms/7K/tableID/insane
|
||||
|
||||
| Property | Type | Description |
|
||||
| :: | :: | :: |
|
||||
| `pbs` | Array<PBDocument> | The array of pbs part of the score leaderboard. |
|
||||
| `pbs` | Array<PBDocument> | The array of pbs part of the PB leaderboard. |
|
||||
| `songs` | Array<[SongDocument](../../schemas/song.md)> | The array of songs part of the PBs. |
|
||||
| `charts` | Array<[ChartDocument](../../schemas/chart.md)> | The array of charts part of the PBs. |
|
||||
| `users` | Array<[UserDocument](../../schemas/user.md)> | The array of users part of the PBs. |
|
||||
|
||||
@@ -153,9 +153,9 @@ router.get("/leaderboard", async (req, res) => {
|
||||
* @param alg - An alternative algorithm to use instead of the gpts default.
|
||||
* @param limit - How many scores to return.
|
||||
*
|
||||
* @name GET /api/v1/games/:game/:playtype/score-leaderboard
|
||||
* @name GET /api/v1/games/:game/:playtype/pb-leaderboard
|
||||
*/
|
||||
router.get("/score-leaderboard", async (req, res) => {
|
||||
router.get("/pb-leaderboard", async (req, res) => {
|
||||
const { game, playtype } = GetGPT(req);
|
||||
const gptConfig = GetGamePTConfig(game, playtype);
|
||||
|
||||
|
||||
+3
-3
@@ -103,7 +103,7 @@ router.get("/challengers", async (req, res) => {
|
||||
});
|
||||
|
||||
/**
|
||||
* Retrieve a "score leaderboard" for this user's set of rivals.
|
||||
* Retrieve a "PB leaderboard" for this user's set of rivals.
|
||||
*
|
||||
* This is - effectively - the best 100 scores from this set of users on the given
|
||||
* rating algorithm.
|
||||
@@ -111,9 +111,9 @@ router.get("/challengers", async (req, res) => {
|
||||
* @param alg - The score rating algorithm to sort on. Defaults to whatever the GPTConfig
|
||||
* default is.
|
||||
*
|
||||
* @name GET /api/v1/users/:userID/games/:game/:playtype/rivals/score-leaderboard
|
||||
* @name GET /api/v1/users/:userID/games/:game/:playtype/rivals/pb-leaderboard
|
||||
*/
|
||||
router.get("/score-leaderboard", async (req, res) => {
|
||||
router.get("/pb-leaderboard", async (req, res) => {
|
||||
const { user, game, playtype } = GetUGPT(req);
|
||||
const gptConfig = GetGamePTConfig(game, playtype);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user