1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160
|
TEG protocol ChangeLog
----------------------
s: string
i: integer
b: bool (represented with '0' and '1')
'token' is between single quotes
Some tokens has a separator
*** version 6 ***
client server
-----------------------------
TypeofGame [MODIFIED]:
==========
Description:
TypeOfGame, also known is spanish as 'modalidad', was used previously
to tell the players, after sending the 'start' message, to tell the
rules of the game (actually not used), and if the server was set to
play with secret missions.
Now, it also sends 2 more variables: Fog of War, and Common mission.
Fog of war: set to true if Fog of war is activated
Common mission: set to true, if playing with common secret mission
of conquering 30 countries.
Also, now the client can request the TypeOfGame. Before, only the server
was sending this message after starting the game.
Implementation:
request: response:
'modalidad' 'modalidad=b1,b2,b3,i4'
b1= is true if playing with secret missions
b2= is true if playing the common secret mission
b3= is true if playin in Fog of War
i4= rules of the game. (Ignore this param)
NewRound [NEW]
==============
Description:
Informs the players that a new round it about to begin.
The client may request that info (after a reconnect)
The server will inform that automatically when a new round starts
Implementatation:
request: response:
'new_round' 'new_round=i1,i2'
i1=who starts the round
i2=the round number
LaunchRobot [NEW]
=================
Description:
Launchs a robot in the server. This helps a lot the speed
of the game. The robot will run with the translations of the
server and not of the client.
Implementation:
request:
'quiero_jugar_con_un_robot'
*** version 5 ***
client server
-----------------------------
Scores [NEW] ( to view the high scores )
======
request: response:
'scores' 'scores=s1,i2,s3,i4,b5\s1,i2,s3,i4,b5....'
s1= name
i2=color
s3=date
i4=score
b5=is human
the separator is '\' (and not '/')
Status [MODIFIED] ( to view the status of the players )
======
request: response:
'status' 'status=s1,i2,i3,i4,i5,i6,i7,i8,b9,b10,s11/...'
s1=name
i2=color
i3=score
i4=player number
i5=status
i6=total countries,
i7=total armies
i8=total cards
b9=started the turn ?
b10=am I human ?
s11=internet address
the separator is '/'
Message [MODIFIED] ( to send a message to all the players )
=======
request: response:
'msg="any chars but quotes"' idem
(The client MUST forbid quotes character in the
message)
Enum cards [NEW] (to know all the cards I have, usefull after a re-join)
==========
request: response:
'enum_cards' 'enum_cards=i1:b1,i2:b2,...'
i1=country number
b2=occupied or not (0 or 1)
Client version [NEW] (Send the server the client version)
==============
request:
'client_version=a description'
This message SHOULD be sent after the PVERSION (protocol version)
*** version 4 ***
client server
-----------------------------
Game in progress [NEW] (the server tells the client that a game is in progress)
================
request: response:
'game_in_progess'
Kick [NEW] (the server kicks a player)
====
request: response:
'kick=s1'
s1=name of the kicked player
Message [MODIFIED ??] ( to send a message to all the players )
=======
request: response:
'msg=COMPLETE???' idem
*** version 3 ***
TODO: Complete!
*** version 2 ***
TODO: Complete!
*** version 1 ***
TODO: Complete!
riq.
|