• Welcome to Valhalla Legends Archive.
 

PHP Battle.net Stats Checker (Not sure what forum this belongs in).

Started by ProXie, April 24, 2005, 03:14 PM

Previous topic - Next topic

Adron

Looking at this, I don't see why you couldn't have done it all in php. All you'd need is a database behind it to track when you last connected to b.net (prevent connecting too often) and to cache the data for users and decide when you need to refresh your information.

MyndFyre

Quote from: Adron on April 26, 2005, 05:37 AM
Looking at this, I don't see why you couldn't have done it all in php. All you'd need is a database behind it to track when you last connected to b.net (prevent connecting too often) and to cache the data for users and decide when you need to refresh your information.

I agree.  Even with a list of 300, that shouldn't be an issue.

Suppose you made one connection and requested a profile every five seconds from that connection.  You're not going to flood from Battle.net; you can pull up 20 profiles per minute.  In total, you could get all 300 profiles inside of 15 minutes.
QuoteEvery generation of humans believed it had all the answers it needed, except for a few mysteries they assumed would be solved at any moment. And they all believed their ancestors were simplistic and deluded. What are the odds that you are the first generation of humans who will understand reality?

After 3 years, it's on the horizon.  The new JinxBot, and BN#, the managed Battle.net Client library.

Quote from: chyea on January 16, 2009, 05:05 PM
You've just located global warming.

ProXie

Originally, that would have been a good plan.  I'm hoping to rack up a database of thousands of users.  The project idea has pretty much evolved.


R.a.B.B.i.T

Quote from: MyndFyre on April 26, 2005, 10:19 AM
Quote from: Adron on April 26, 2005, 05:37 AM
Looking at this, I don't see why you couldn't have done it all in php. All you'd need is a database behind it to track when you last connected to b.net (prevent connecting too often) and to cache the data for users and decide when you need to refresh your information.

I agree.  Even with a list of 300, that shouldn't be an issue.

Suppose you made one connection and requested a profile every five seconds from that connection.  You're not going to flood from Battle.net; you can pull up 20 profiles per minute.  In total, you could get all 300 profiles inside of 15 minutes.
Sockets in PHP are a bit slower than in other languages.  Even sending 0x51 and 0x50 takes a few seconds each.  I'd say it would take ~45 minutes, after all, you do recieve a lot of data you need to parse.

MyndFyre

Quote from: ProXie on April 26, 2005, 02:09 PM
Originally, that would have been a good plan.  I'm hoping to rack up a database of thousands of users.  The project idea has pretty much evolved.

Then, rather than using PHP to handle the connections, write a simple client in C/VB/etc. and run it as a service.  Continually sending requests, you won't time out.  Go slowly enough,and you won't be flood banned.  Connect both parts to the same database; it shouldn't be particularly difficult.
QuoteEvery generation of humans believed it had all the answers it needed, except for a few mysteries they assumed would be solved at any moment. And they all believed their ancestors were simplistic and deluded. What are the odds that you are the first generation of humans who will understand reality?

After 3 years, it's on the horizon.  The new JinxBot, and BN#, the managed Battle.net Client library.

Quote from: chyea on January 16, 2009, 05:05 PM
You've just located global warming.

ProXie

Quote from: MyndFyre on April 26, 2005, 06:25 PM
Quote from: ProXie on April 26, 2005, 02:09 PM
Originally, that would have been a good plan.  I'm hoping to rack up a database of thousands of users.  The project idea has pretty much evolved.

Then, rather than using PHP to handle the connections, write a simple client in C/VB/etc. and run it as a service.  Continually sending requests, you won't time out.  Go slowly enough,and you won't be flood banned.  Connect both parts to the same database; it shouldn't be particularly difficult.
Thats 'almost' what I'm planning.  I'm working with someone to program a C bot that will run and 'crawl' certain channels to collect data.

MyndFyre

Quote from: ProXie on April 26, 2005, 09:55 PM
Quote from: MyndFyre on April 26, 2005, 06:25 PM
Quote from: ProXie on April 26, 2005, 02:09 PM
Originally, that would have been a good plan.  I'm hoping to rack up a database of thousands of users.  The project idea has pretty much evolved.

Then, rather than using PHP to handle the connections, write a simple client in C/VB/etc. and run it as a service.  Continually sending requests, you won't time out.  Go slowly enough,and you won't be flood banned.  Connect both parts to the same database; it shouldn't be particularly difficult.
Thats 'almost' what I'm planning.  I'm working with someone to program a C bot that will run and 'crawl' certain channels to collect data.
Might want to search on that too.  A channel crawler was already talked about before; the information they found might be useful.  :)
QuoteEvery generation of humans believed it had all the answers it needed, except for a few mysteries they assumed would be solved at any moment. And they all believed their ancestors were simplistic and deluded. What are the odds that you are the first generation of humans who will understand reality?

After 3 years, it's on the horizon.  The new JinxBot, and BN#, the managed Battle.net Client library.

Quote from: chyea on January 16, 2009, 05:05 PM
You've just located global warming.