Ronin Networking:

Ronin networking involves the following entities:

These entities are connected by abstract streams as appropriate. When a player logs in to the system, a PIC is created to minimize network traffic to the main database. The PIC checks out the player information from the PID for the lifetime of a session. When a battle begins, a BS is created on the machine of one of the participants. A BC and BUI is created on the machine of each participant. The BS constantly updates the BCs with battle events and also informs the PIC of important changes to player information (like when a character dies). The BCs keep up-to-date battle information, which is used by the BUIs to display the battle and allow input.

Old description: When a player begins Ronin using a Ronin client application, a connection is made with the Ronin server. Until a battle begins, the only communication is between the Ronin client and Ronin Server. These messages involve information about who is logged on, and allow the initiation of a battle. When a battle begins the players involved in the battle open a direct connection to each other. This connection is used for communicating battle commands and events. The connection between the Ronin client and Ronin server is not severed during this time, but is not used very much. It is used to update the server on the status of the characters involved in the battle.

Ronin Messages (subclassed from class RoninMessage):



General Description:

When a player begins playing Ronin a connection is immediately established with the server. The player logs in to the server by sending a LoginMessage to notify it of who is logging in. Before a player logs in the server will not send messages to the player. The player can ask who is logged on by sending a RequestPlayerListMessage, resulting in the transmission of a PlayerListMessage from the server. Using this information the player can request a battle with another player by sending an InvitePlayerMessage, which results in a NotifyInvitationMessage being sent by the server to the other player. To accept an invitation a player sends a AcceptInvitationMessage, which prompts the server to send a BeginBattleMessage, which contains enough information for the players to establish a separate connection and start a battle.

Message Formats (number of bytes - data description):

LoginMessage (later must be encrypted):

RequestPlayerListMessage: no data