Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

 
Reply to this topicStart new topic
> [PHP] Status serwera CS
Siper
post
Post #1





Grupa: Zarejestrowani
Postów: 60
Pomógł: 1
Dołączył: 25.04.2009

Ostrzeżenie: (0%)
-----


http://forum.php.pl/index.php?showtopic=23...st&p=483266

Ten skrypt to jedyny jaki działa i można go fajnie zmodyfikować, ale mam pytanie, jak go przerobić aby pokazywał to w liście (no wiecie o co mi chodzi biggrin.gif )?


Znalazłem taki cos:

  1. // internal function to parse halflife verion 1 'info' packets
  2. function _parse_info_halflife1() {
  3. $this->raw = substr($this->raw, 5); // strip off response header bytes
  4. $this->data['int_ipport'] = $this->_getnullstr();
  5. list($this->data['int_ip'], $this->data['int_port']) = explode(':', $this->data['int_ipport']);
  6. $this->data['name'] = $this->_getnullstr();
  7. $this->data['map'] = $this->_getnullstr();
  8. $this->data['gamedir'] = $this->_getnullstr();
  9. $this->data['gamename'] = $this->_getnullstr();
  10. $this->data['totalplayers'] = $this->_getbyte();
  11. $this->data['maxplayers'] = $this->_getbyte();
  12. $this->data['protocol'] = $this->_getbyte(); // 47
  13. $this->data['servertype'] = $this->_getchar();
  14. $this->data['serveros'] = $this->_getchar();
  15. $this->data['serverlocked'] = $this->_getbyte();
  16. $this->data['modrunning'] = $this->_getbyte();
  17. $this->data['modurl'] = $this->data['modrunning'] ? $this->_getnullstr() : '';
  18. $this->data['modftp'] = $this->data['modrunning'] ? $this->_getnullstr() : '';
  19. $this->_getnullstr(); // depreciated string, ignore it
  20. $this->data['modver'] = $this->_getshort() . '.' . $this->_getshort();
  21. $this->data['modsize'] = $this->_getlong();
  22. $this->data['modserveronly'] = $this->_getbyte();
  23. $this->data['modclientdll'] = $this->_getbyte();
  24. return $this->data;
  25. }




Refresh...

Ten post edytował Siper 21.11.2009, 12:42:05
Go to the top of the page
+Quote Post
piotrooo89
post
Post #2


Newsman


Grupa: Moderatorzy
Postów: 4 005
Pomógł: 548
Dołączył: 7.04.2008
Skąd: Trzebinia/Kraków




chodzi Ci o select liste? skąd pobierasz te dane?


--------------------
Go to the top of the page
+Quote Post
Siper
post
Post #3





Grupa: Zarejestrowani
Postów: 60
Pomógł: 1
Dołączył: 25.04.2009

Ostrzeżenie: (0%)
-----


Chce użyć tego skryptu do Generowania grafiki ze statusem serwera.
a i skad pobieram dane, chodzi ci o 'include'?
Go to the top of the page
+Quote Post

Reply to this topicStart new topic
1 Użytkowników czyta ten temat (1 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Aktualny czas: 21.08.2025 - 12:10