Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
?
Solved

Getting Server Information

Posted on 2003-03-13
14
Medium Priority
?
207 Views
Last Modified: 2010-03-19
Hey i want to know the commands or a tutorial that will help me figure out how to send udp or tcp/ip requests to half-life servers to request server information from. sorry i cant offer any more points im broke point wise and money is not something i like to spend
0
Comment
Question by:Rinale
14 Comments
 
LVL 7

Expert Comment

by:dansoto
ID: 8133505
what kind of information do you want from the servers?
0
 

Author Comment

by:Rinale
ID: 8133838
I downlaoded the half-life sdk and got the protocal file but im kinda clueless on winsock because ive never used it before but this is what i *think is the information i need to learn how to use.

==============
INFO
==============

game servers will answer the following messages:
Messages are sent to the server by sending 4 consecutive bytes of 255 (32-bit integer -1) and then the string command followed by a zero byte to terminate it

"ping"
     Server responds with the following packet:
     (int32)          -1
     (byte)          ASCII 'j' (general acknowledgement, A2A_ACK)
     (byte)          0

"info"
     Server responds with the following packet:
     (int32)          -1
     (byte)          ASCII 'C' (info response, S2A_INFO)
     (string)          net address of server
     (string)          name of the host / server
     (string)          name of the map
     (string)          game directory (i.e. valve/)
     (string)          Game description (e.g. "half-life multiplay")
     (byte)          active client count
     (byte)          maximum clients allowed
     (byte)          protocol version

"players"
     Server responds with the following packet:
     (int32)          -1
     (byte)          ASCII 'D' (players response, S2A_PLAYER)
     (byte)          active client count

     for each active client
          (byte)          client number / index
          (string)          player name
          (int32)          client's frag total
          (float32)          client's total time in-game

"rules"
     Server responds with the following packet:
     (int32)          -1
     (byte)          ASCII 'E' (rules response, S2A_RULES)
     (int16)          number of rules

     for each rule
          (string)          rule name
          (string)          rule value

0
 

Author Comment

by:Rinale
ID: 8133921
I downlaoded the half-life sdk and got the protocal file but im kinda clueless on winsock because ive never used it before but this is what i *think is the information i need to learn how to use.

==============
INFO
==============

game servers will answer the following messages:
Messages are sent to the server by sending 4 consecutive bytes of 255 (32-bit integer -1) and then the string command followed by a zero byte to terminate it

"ping"
     Server responds with the following packet:
     (int32)          -1
     (byte)          ASCII 'j' (general acknowledgement, A2A_ACK)
     (byte)          0

"info"
     Server responds with the following packet:
     (int32)          -1
     (byte)          ASCII 'C' (info response, S2A_INFO)
     (string)          net address of server
     (string)          name of the host / server
     (string)          name of the map
     (string)          game directory (i.e. valve/)
     (string)          Game description (e.g. "half-life multiplay")
     (byte)          active client count
     (byte)          maximum clients allowed
     (byte)          protocol version

"players"
     Server responds with the following packet:
     (int32)          -1
     (byte)          ASCII 'D' (players response, S2A_PLAYER)
     (byte)          active client count

     for each active client
          (byte)          client number / index
          (string)          player name
          (int32)          client's frag total
          (float32)          client's total time in-game

"rules"
     Server responds with the following packet:
     (int32)          -1
     (byte)          ASCII 'E' (rules response, S2A_RULES)
     (int16)          number of rules

     for each rule
          (string)          rule name
          (string)          rule value

0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 

Author Comment

by:Rinale
ID: 8133947
I downlaoded the half-life sdk and got the protocal file but im kinda clueless on winsock because ive never used it before but this is what i *think is the information i need to learn how to use.

==============
INFO
==============

game servers will answer the following messages:
Messages are sent to the server by sending 4 consecutive bytes of 255 (32-bit integer -1) and then the string command followed by a zero byte to terminate it

"ping"
     Server responds with the following packet:
     (int32)          -1
     (byte)          ASCII 'j' (general acknowledgement, A2A_ACK)
     (byte)          0

"info"
     Server responds with the following packet:
     (int32)          -1
     (byte)          ASCII 'C' (info response, S2A_INFO)
     (string)          net address of server
     (string)          name of the host / server
     (string)          name of the map
     (string)          game directory (i.e. valve/)
     (string)          Game description (e.g. "half-life multiplay")
     (byte)          active client count
     (byte)          maximum clients allowed
     (byte)          protocol version

"players"
     Server responds with the following packet:
     (int32)          -1
     (byte)          ASCII 'D' (players response, S2A_PLAYER)
     (byte)          active client count

     for each active client
          (byte)          client number / index
          (string)          player name
          (int32)          client's frag total
          (float32)          client's total time in-game

"rules"
     Server responds with the following packet:
     (int32)          -1
     (byte)          ASCII 'E' (rules response, S2A_RULES)
     (int16)          number of rules

     for each rule
          (string)          rule name
          (string)          rule value

0
 

Author Comment

by:Rinale
ID: 8133996
I downlaoded the half-life sdk and got the protocal file but im kinda clueless on winsock because ive never used it before but this is what i *think is the information i need to learn how to use.

==============
INFO
==============

game servers will answer the following messages:
Messages are sent to the server by sending 4 consecutive bytes of 255 (32-bit integer -1) and then the string command followed by a zero byte to terminate it

"ping"
     Server responds with the following packet:
     (int32)          -1
     (byte)          ASCII 'j' (general acknowledgement, A2A_ACK)
     (byte)          0

"info"
     Server responds with the following packet:
     (int32)          -1
     (byte)          ASCII 'C' (info response, S2A_INFO)
     (string)          net address of server
     (string)          name of the host / server
     (string)          name of the map
     (string)          game directory (i.e. valve/)
     (string)          Game description (e.g. "half-life multiplay")
     (byte)          active client count
     (byte)          maximum clients allowed
     (byte)          protocol version

"players"
     Server responds with the following packet:
     (int32)          -1
     (byte)          ASCII 'D' (players response, S2A_PLAYER)
     (byte)          active client count

     for each active client
          (byte)          client number / index
          (string)          player name
          (int32)          client's frag total
          (float32)          client's total time in-game

"rules"
     Server responds with the following packet:
     (int32)          -1
     (byte)          ASCII 'E' (rules response, S2A_RULES)
     (int16)          number of rules

     for each rule
          (string)          rule name
          (string)          rule value

0
 
LVL 15

Expert Comment

by:WalkaboutTigger
ID: 8134482
Don't hit refresh on these pages.

The SDK has some sample code with it.  Have you looked at the samples yet?  What is it you're trying to do?

Walkabout
0
 

Author Comment

by:Rinale
ID: 8137715
That was everything that came with the file protocol thing so i didnt have any examples except for that to look off of thats why i came here to ask the question.
0
 
LVL 7

Expert Comment

by:dansoto
ID: 8137824
Here is a link that should explain everything you need to know about using these commands in the console...and then some.

http://half-life.gamehelp.com/console/index.html

Let me know if this helps..

- dan soto -
0
 

Author Comment

by:Rinale
ID: 8137912
oh yeah what im trying to do is ping the server for its information
0
 

Author Comment

by:Rinale
ID: 8137988
 I already know the commands for console (and then some) im trying to do this completely outside of hl.exe (dos or vb) vb using winsock or dos using ping or connect or whatever you need to use.
0
 
LVL 7

Expert Comment

by:dansoto
ID: 8138004
ahh.. sorry...
0
 

Author Comment

by:Rinale
ID: 8140068
np
0
 

Author Comment

by:Rinale
ID: 8144170
hey could you guys please delete this question i solved it and there is no point for it to still be around
0
 

Accepted Solution

by:
SpideyMod earned 0 total points
ID: 8147663
PAQ'd and all 50 points refunded.

SpideyMod
Community Support Moderator @Experts Exchange
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This program is used to assist in finding and resolving common problems with wireless connections.
Unable to change the program that handles the scan event from a network attached Canon/Brother printer/scanner. This means you'll always have to choose which program handles this action, e.g. ControlCenter4 (in the case of a Brother).
Monitoring a network: how to monitor network services and why? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the philosophy behind service monitoring and why a handshake validation is critical in network monitoring. Software utilized …
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…

580 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question