Network messages

From PSwiki
Jump to navigation Jump to search

MSGTYPE_PING

MSGTYPE_AUTHENTICATE

Handled by the psAuthenticationMessage class. This message only goes from the client to the server. It sends:

  • account name
  • password
  • client version

MSGTYPE_PREAUTHENTICATE

Handled by the psPreAuthenticationMessage class. The message only goes from the client to the server. It is a message to see if we have any chance of being allowed to log on with our client. It sends:

  • client version number.

MSGTYPE_PREAUTHAPPROVED

Handled by the psPreAuthApprovedMessage class. This message only goes from the server to the client. It is used to let the client know that it will be allowed to login. It sends

  • client number assigned to this client.

MSGTYPE_AUTHAPPROVED

Handled by the psAuthApprovedMessage class. This message only goes from server to client. It verifies that the account details where correct and sends character details.

It includes the following data:

  • Client number
  • Player ID
  • Number of characters
  • For each character that account has
    • Full name of character


MSGTYPE_AUTHREJECTED

Handled by the psAuthRejectedMessage class. This message only goes from client to server. It notifies that the client could not be connected. It includes:

  • Reason why client was rejected.


MSGTYPE_DISCONNECT

Handled by the psDisconnectMessage class. This message can be sent by both the client or the server. This is sent by the client to inform that the client is disconnecting. It's also sent by the server to disconnect a client ( for example, on a server shutdown ).

From Client data

  • None

From Server data

  • Reason for disconnection.

MSGTYPE_CHAR_INFO

MSGTYPE_CHAT

This is handled by the psChatMessage class. It can be sent by either the client or the server. When the client is sending it, it is data chat data that the client has said being sent. When the server sends it, it is is data that other players have said being sent to that client.

From Client Data

  • The person the chat is for ( in case of /tells )
  • The text that was said
  • The type of chat it was (one of)
    • CHAT_SAY
    • CHAT_ME
    • CHAT_MY
    • CHAT_GROUP
    • CHAT_GUILD
    • CHAT_TELL
    • CHAT_PET_ACTION
    • CHAT_AUCTION
    • CHAT_SHOUT
    • CHAT_REPORT
    • CHAT_NPC

From Server Data

  • The person that is speaking
  • The text that was said
  • The type of chat it was (one of)
    • CHAT_SAY
    • CHAT_ME
    • CHAT_MY
    • CHAT_GROUP
    • CHAT_GUILD
    • CHAT_TELL
    • CHAT_PET_ACTION
    • CHAT_AUCTION
    • CHAT_SHOUT
    • CHAT_REPORT
    • CHAT_NPC

MSGTYPE_GUILDCMD

Handled by the psGuildCmdMessage class. This message is from the client to the server only. This sends

  • A data command string.

When message is parsed it will use the first word in the data string as the guild command. Current commands are:

  • /newguild
  • /endguild
  • /guildname
  • /guildpoints
  • /guildinvite
  • /guildremove
  • /allianceinvite
  • /confirmguildjoin
  • /guildlevel
  • /guildmembers
  • /guildpromote
  • /guildsecret
  • /guildweb
  • /guildmotd
  • /newalliance
  • /allianceremove
  • /allianceleader
  • /endalliance
  • /allianceleave
  • /guildinfo
  • /guildwar
  • /guildyield