ppy / osu-api

Public API for accessing osu! related data.
320 stars 16 forks source link

Add diff_flashlight #322

Open uzervlad opened 2 years ago

uzervlad commented 2 years ago

As there is a new strain skill, it should be added to the API

peppy commented 2 years ago

Is this not exposed by the v2 API already? If so, I don't think we will be exposing new attributes here.

uzervlad commented 2 years ago

No, v2 doesn't return any information about separate skills.

peppy commented 2 years ago

That's a bit of an oversight. We'll need to add that eventually, but I'll see that this is added to the v1 API in the mean time.

peppy commented 2 years ago

Before I add this, what is the use case for using this?

uzervlad commented 2 years ago

Just PP calculation. I don't think it can be used for anything else. It's too hard to write and debug star rating calculation on my own, so I use values from API

peppy commented 2 years ago

Hmm, we already have tools which you can run to produce these locally, have you tried using those? I think that would be more efficient in most cases.

I'm just asking because I think 99% of use cases won't use this attribute and adding it bloats the response and the lookup overhead, potentially for no reason.

TheEZIC commented 2 years ago

I also need this, because I use it in my front-end only extension to calculate PP github repository google extension store page I can't use v2 API. I don't remember exactly why, but the issue was related to converted beatmaps.

uzervlad commented 2 years ago

Hmm, we already have tools which you can run to produce these locally, have you tried using those?

Yes, I have, a rewrite of my bot uses lazer to calculate star rating and PP. But the current version is relying on values from API. Actually, while writing this I realized that it shouldn't be too hard to connect lazer with the existing codebase.

@TheEZIC's use case, on the other hand, probably can't rely on any external tools, so if your only concerns are bloat and lookup overhead, you could add a query parameter for showing all difficulty attributes.