Quint Card online--Network message transmission

Source: Internet
Author: User

Event

Player-to-server format

Server-and player format

Allow players to play cards

Ready

(the server can continue to play cards before the message is issued)

Allow servers to send letters to each other

Ready

(one inning) game started

Hand=int

Ready or later (ready on behalf of the receiver player to play the card, later to indicate that it is the hand)

Cards (except for the following three types of cards)

Int (that is, the number of this card)

Int

Card (function card: horn)

38000

Horn=int (line number of the place horn)

38000,int

(int is the horn line number)

Card (function card: Scarecrow)

39000

Scarecrow=int,int

(Place the Scarecrow's line number, the row is replaced by the card number)

39000,int,int

(Place the Scarecrow's line number, the row is replaced by the card number)

Card (function card: Doctor)

Int

Int

Int

...

(Keep out of cards until the risen card is no longer a doctor)

Int

Int

Int

...

(Keep out of cards until you make ready)

Update the number of your own hands in the other client

Hand=int

Hand=int

Abandon This council

GiveUp

GiveUp

Player notifies the server of the end of this Council

End

Player notifies the server that the game is over and tells the winner

Matchset,w or L or D

(Win, negative, flat)

The server notifies the player that the game is over

Matchset

The message format of this communication is not well set, redundancy is too much, later time should be improved.

Quint Card online--Network message transmission

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.