openplanet-nl/tmio

Leaderboardposition in Campaign Overview

Opened this issue · 5 comments

Hello,

would it be possible to add your Leaderboard Position in the Overview of a Campaign as a little QOL change?
Maybe directly under the Personal Best time?

image

Thanks!

As mentioned on Discord, I think this would require a separate request for each map in a campaign to get the position via the score/surround API - obviously that could be cached but it doesn't really scale well since the cache would be per user (and users would expect it to be up to date when opening the page).

But maybe I'm missing some way to achieve this - @codecat you got an idea by any chance?

Yeah I agree, I don't really know of any good way to do it. If we did a request for every map & every player, Nadeo will complain at us pretty quickly :P

I don't know how this works in the background, but the information is already there when you are on the leaderboard of a map.
Isn't it possible to somehow "copy" that over to the overview?

I'm probably thinking too simple
image

It's available there because it's requested by the page during load - but that's always one map at a time. If we have to request 25 different maps every time someone just looks at a campaign, it increases the server load quite a bit.

Ooh, ok ok, that makes sense.
Thanks for explaining