Jump to content



Photo

Question about retrieving concurrent player numbers for games


  • Please log in to reply
9 replies to this topic

#1 Alladaskill17

Alladaskill17

    Neowinian Senior

  • 5,398 posts
  • Joined: 21-July 05

Posted 29 March 2013 - 22:29

First off, I have no programming knowledge whatsoever. Second, I am aware of steam stats and its "top 100" etc. I am curious as to how sites like BF3stats[dot]net work, with APIs? But I am honestly not sure what that means, and was EA/DICE just nice enough to open up the ability to pull concurrent players numbers for each platform?

I am curious because I'd love to regularly be able to retrieve concurrent play numbers, by platform, for multiple shooters, Crysis 3 as an example since I know on Xbox 360 the player count is constantly ~1000, but I do not want to have to load up a game to look at these types of numbers.

Another game that does display concurrent player #s per game type is Halo 4, via waypoint, but I really just want to understand how sites like BF3stats[dot]net get their information and is it up to the developers to allow access to the numbers regarding the player base.

Example of what I am referring to about Battlefield 3 and its per platform online player information:
Posted Image

Any information is greatly appreciated, just want increased understanding of how to acquire the stats and if its left up to the dev to allow access or what :)


#2 articuno1au

articuno1au

    Neowinian Senior

  • 4,455 posts
  • Joined: 20-March 11
  • Location: Brisbane, Australia

Posted 29 March 2013 - 23:17

APIs are programming interfaces opened by a service.

In this case you would access the BF3 API, and use the GetPlayers (or whatever) method.

You can only do what BF3 chooses to expose through their API, so you're limited by them :)

You'd be looking for Crysis 3 Server APIs to get info :)

#3 OP Alladaskill17

Alladaskill17

    Neowinian Senior

  • 5,398 posts
  • Joined: 21-July 05

Posted 31 March 2013 - 00:39

APIs are programming interfaces opened by a service.

In this case you would access the BF3 API, and use the GetPlayers (or whatever) method.

You can only do what BF3 chooses to expose through their API, so you're limited by them :)

You'd be looking for Crysis 3 Server APIs to get info :)

Thank you for the reply :) I am curious, if you or anyone knows (while I search through BF3stats source code) how I could use these API's to display player count via an HTML document for my personal homepage, simply for my curiosity.

onlinestats
URL: http://api.bf3stats.com/[Platform]/onlinestats/
[Platform] must be global
POST parameters:
none
Return parameters:
status can contain ok, nodata or error
ok online data is available
nodata data is not available
error is only returned if status is error with one of following error codes:
invalid_platform
pc count of online players on PC
360 count of online players on 360
ps3 count of online players on PS3
The data is refreshed every 10 seconds.

And for Crysis 3; which is the same except pointing to crysis3s[dot]com.

#4 articuno1au

articuno1au

    Neowinian Senior

  • 4,455 posts
  • Joined: 20-March 11
  • Location: Brisbane, Australia

Posted 31 March 2013 - 00:44

I take it you've found this already: http://crysis3s.com/api

Well, you can use Javascript to do it.

Personally I do this kind of thing in ASP, so I won't be much help to you here unfortunately.

You're looking for HTTP Post with Javascript


There ought be examples you can use :)

#5 OP Alladaskill17

Alladaskill17

    Neowinian Senior

  • 5,398 posts
  • Joined: 21-July 05

Posted 31 March 2013 - 00:48

I take it you've found this already: http://crysis3s.com/api

Well, you can use Javascript to do it.

Personally I do this kind of thing in ASP, so I won't be much help to you here unfortunately.

You're looking for HTTP Post with Javascript


There ought be examples you can use :)

Yes I had found the site just had no knowledge on how to use the information provided lol I'll try googling "http post + javascript", any other suggestions?

#6 articuno1au

articuno1au

    Neowinian Senior

  • 4,455 posts
  • Joined: 20-March 11
  • Location: Brisbane, Australia

Posted 31 March 2013 - 00:51

Well, that's quite literally what I did :p

Only other suggestion I have is write a proof of concept page, don't try and integrate it into your site to begin with >.<

You'll have to get the post response, then push the data into a text box >.<

#7 OP Alladaskill17

Alladaskill17

    Neowinian Senior

  • 5,398 posts
  • Joined: 21-July 05

Posted 31 March 2013 - 00:55

I have quite a lot to learn before I can add this stuff to my homepage lol

#8 articuno1au

articuno1au

    Neowinian Senior

  • 4,455 posts
  • Joined: 20-March 11
  • Location: Brisbane, Australia

Posted 31 March 2013 - 01:00

Javascript is definitely something you'll like. You can do just about anything with it >.<

I'll save you some pain here too. Take a look at jQuery: http://api.jquery.com/jQuery.post/

It's a set of javascript libraries that are thoroughly awesome. Can lead you to stuff like: http://jqueryui.com/

#9 OP Alladaskill17

Alladaskill17

    Neowinian Senior

  • 5,398 posts
  • Joined: 21-July 05

Posted 31 March 2013 - 01:30

Javascript is definitely something you'll like. You can do just about anything with it >.<

I'll save you some pain here too. Take a look at jQuery: http://api.jquery.com/jQuery.post/

It's a set of javascript libraries that are thoroughly awesome. Can lead you to stuff like: http://jqueryui.com/

You're the man/women! I will definitely look at the links and hopefully learn something haha

#10 articuno1au

articuno1au

    Neowinian Senior

  • 4,455 posts
  • Joined: 20-March 11
  • Location: Brisbane, Australia

Posted 31 March 2013 - 01:42

Enjoy, most of the people here can help you out, so come back if you have questions >.<



Click here to login or here to register to remove this ad, it's free!