joshuaferrara / node-csgo

A node-steam plugin for Counter-Strike: Global Offensive.
MIT License
461 stars 82 forks source link

Sometimes PlayerProfileRequest return ranking: null #28

Open Roguyt opened 8 years ago

Roguyt commented 8 years ago

Sometimes, i don't know why it returns this

{ request_id: null,
  account_profiles:
   [ { account_id: 152304352,
       ongoingmatch: null,
       global_stats: null,
       penalty_seconds: null,
       penalty_reason: null,
       vac_banned: null,
       ranking: null,
       commendation: [Object],
       medals: [Object],
       my_current_event: null,
       my_current_event_teams: [],
       my_current_team: null,
       my_current_event_stages: [],
       survey_vote: null,
       activity: null,
       player_level: 20,
       player_cur_xp: 327680966,
       player_xp_bonus_flags: null } ] }

Any idea why i can't get the rank ? Ty

--- Want to back this issue? **[Post a bounty on it!](https://www.bountysource.com/issues/29532735-sometimes-playerprofilerequest-return-ranking-null?utm_campaign=plugin&utm_content=tracker%2F1253779&utm_medium=issues&utm_source=github)** We accept bounties via [Bountysource](https://www.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F1253779&utm_medium=issues&utm_source=github).
shaunidiot commented 8 years ago

Make sure they have CS:GO running.

Roguyt commented 8 years ago

Just checked again and still not work

joshuaferrara commented 8 years ago

I still don't know what could be causing this and I haven't done much research into this. It is recurring though as it's also been talked about in #25 and #16

Roguyt commented 8 years ago

So in fact you can't fix because you don't know what's the problem, np Thx Valve and your shitty api ^^ Thx you for your amazing job Josh !

taylorfinnell commented 8 years ago

ongoingmatch is null. Doesn't that mean they are not in a match? Isn't a requirement of the api that they be in a match?

Roguyt commented 8 years ago

It's normal, because i make a request to the player profile, the requirement of the api is that they have csgo opened.

joshuaferrara commented 8 years ago

@taylorfinnell Ranking and vac_banned should be available though.

@roguyt As long as they are friends with the bot and online in game it should work. I'll take a look at some of the other NodeJS based valve APIs (node-dota2, node-tf2) over the weekend and see if they've run into similar problems.

Roguyt commented 8 years ago

@joshuaferrara Okey thx bro ;)

joshuaferrara commented 8 years ago

@Roguyt #31 might provide some insight to your situation.

Raphash0w commented 8 years ago

I didnt understand... Is it possible to pick? Because its really important to us if its possible.

Can you guys help me, please?

Tjird commented 4 years ago

This can mean that you don't have the player as a friend or the player has no ranked history.

fredodiable commented 4 years ago

In fact if ranking is null, it just's because that player is not ranked yet (under ten wins)
else if that player has a rank, even an expired one, ranking property will be filled

L4rsS commented 2 years ago

I think Valve changed its API so you can only get current rank by players who are in your Steam friendslist.