1. osu! forums
  2. osu!
  3. Development

show more
posted

comentarinformal wrote:

Before I spam it with requests that might not exist, is there anything to get user's information?
(Also, is there anything to login users from this page in other places?)
"spamming" with requests is considered "evil" use. you may be banned from the api and/or osu! for doing so. the api is not provided to retrieve a full set of information. it is provided to do lookups when necessary.
posted
I'd like to know beatmap's mode on get_beatmaps request.
Isn't it possible?
posted
Minor gripe: Please return integers as such.
posted
All requests and bugs should be filed on github: https://github.com/peppy/osu-api/issues
posted
Any rate limits?
posted
See doc.
posted
With this now open, is getting data from http://osu.ppy.sh/pages/include/profile ... id&m=$mode will be still possible or it may becaume unavaillable ?
(Lazy to change my PHP code *o*)
posted
Please switch to using the API. Please please please. That page you are using will no doubt change in the future and cause you more grief than if you spend a bit of time and make your code use the new API.
posted
I guess I'll update my userbar too when I find some time.

Before I apply and pick a name that cannot be changed, is the API key going to be global to my osu! account or is it set up in a way that I can have a second API key if I make another app/tool ?
posted
For now it's one per account.
posted

Damnae wrote:

I guess I'll update my userbar too when I find some time.

Before I apply and pick a name that cannot be changed, is the API key going to be global to my osu! account or is it set up in a way that I can have a second API key if I make another app/tool ?
I registered it for osu!userbar, but I also use it for my "Big ugly white signature", they are not on the same webserver, but it works fine :)
I belive only you and peppy can see the name you used, too.

(Yes I took my lazyness off, it was not that long to update ^^)
posted
@Repflez: I tried using your API-powered signature and I get something weird.



Since I only aim for SS, I have 100% Accuracy all the time, and the Accuracy display is weird.

(I now know that despite having all-SS records, the note hit count for getting 50s and 100s are still counted all the time :P)
posted

Winshley wrote:

@Repflez: I tried using your API-powered signature and I get something weird.



Since I only aim for SS, I have 100% Accuracy all the time, and the Accuracy display is weird.

(I now know that despite having all-SS records, the note hit count for getting 50s and 100s are still counted all the time :P)
So that's what the CountX values mean. Thanks for that. I already went and changed the accuracy to show a centered "100% Accuracy" if it's 100. Forget that. I ditched the bar on it and used the extra space for showing the PP.

(I love how the 300 count ended overlaping the border)
posted

Repflez wrote:

So that's what the CountX values mean. Thanks for that.
Yeah. At first I thought that there was something wrong with the API showing 50s and 100s despite having 100% Accuracy, until I actually calculated all 300s + 100s + 50s = "Total Hits" on our profile. :P

About the 300 overlap though, it does need some fix:


When you reached 10 millions of 300 hits, the last number is cut off. Cookiezi has 17 millions of 300 hits.

And an extra:

I'm not sure how the level bar breaking happens though... I was thinking that it probably because I don't have any ranked score on osu!mania? :?
posted

Winshley wrote:

When you reached 10 millions of 300 hits, the last number is cut off. Cookiezi has 17 millions of 300 hits.
I plan to change that to the Total Hit Count once I finish with some things with the API interface that the image uses.

Winshley wrote:

I'm not sure how the level bar breaking happens though... I was thinking that it probably because I don't have any ranked score on osu!mania? :?
The API says that you "full" stats in osu!mania:
Array
(
[0] => Array
(
[user_id] => 864895
[username] => Winshley
[count300] => 7164
[count100] => 23
[count50] => 12
[playcount] => 338
[ranked_score] => 0
[total_score] => 144063600
[pp_rank] => 0
[level] => 28.0984
[pp_raw] => 0
[accuracy] => 0
[country] => ID
)

)


Probably the stats didn't got cleared after the score clear when the mode went gold so the API returns what it has. I'll go raise an issue to peppy when I have the time. issue #9

About the bar... Yeah, that's a bug. The formula to calculate the width of the bar is flawed:
number_format(substr(unround_number($user[level],true),0,3)*0.264,0)
That means: The first 3 decimals of $user[level] * 0.264 and the result gets rounded.

In your case is making this operation: 98 * 0.264 which is returning a width of 26 (The actual result is 25.872 but I round it) and it expects to be at least 71 for some reason and since the result is lower, the entire bar went backwards. I blame ImageFilledRectangle for that bug.
posted

Still loads to do though :>


EDIT:

Available online for all you people at http://availu.net/osu/
Don't mind the ugly generator looks, still working on stylizing it.
posted
@Avail: you are currently doing *no* caching. That means every time that image is displayed, it is consuming huge resources on your server (and doing an underlying API call to osu!). best work on that if you plan on letting many people use it :p.
posted
I'm curious... in osu!mania, what are count300, count100, and count50 based from? Is it MAX, 300, and 200 respectively? If so, how to get the remaining hits though (e.g: 100 and 50)?
posted

peppy wrote:

@Avail: you are currently doing *no* caching. That means every time that image is displayed, it is consuming huge resources on your server (and doing an underlying API call to osu!). best work on that if you plan on letting many people use it :p.
I plan on adding caching, if I ever learn how to.
posted
If you really have no idea how to do caching then I highly recommend that you at least use this: t/141331
show more
Please sign in to reply.