… | |
… | |
101 | ST_GET_PARTY_PASSWORD, |
101 | ST_GET_PARTY_PASSWORD, |
102 | }; |
102 | }; |
103 | |
103 | |
104 | // a handler for a specific type of packet |
104 | // a handler for a specific type of packet |
105 | enum { |
105 | enum { |
106 | PF_PLAYER = 0x01, // must have valid player / will by synchronised |
106 | PF_PLAYER = 0x01, // must have valid player / will by synchronised |
107 | PF_PLAYING = 0x02, // must be in playing state |
107 | PF_PLAYING = 0x02, // must be in playing state |
108 | PF_COMMAND0 = 0x04, // command starts at offset 0 |
108 | PF_COMMAND = 0x04, // is a suer command |
109 | PF_COMMAND6 = 0x08, // command starts at offset 6 |
|
|
110 | }; |
109 | }; |
111 | |
110 | |
112 | // face types. bit 0 means "has meta info prepended" |
111 | // face types. bit 0 means "has meta info prepended" |
113 | enum { |
112 | enum { |
114 | FT_FACE = 0 * 2 + 0, // faces (images) |
113 | FT_IMAGE = 0 * 2 + 0, // images |
115 | FT_MUSIC = 1 * 2 + 1, // background music |
114 | FT_MUSIC = 1 * 2 + 1, // background music |
116 | FT_SOUND = 2 * 2 + 1, // effects |
115 | FT_SOUND = 2 * 2 + 1, // effects |
117 | FT_RSRC = 3 * 2 + 0, // generic data files |
116 | FT_RSRC = 3 * 2 + 0, // generic data files |
118 | FT_NUM, |
117 | FT_NUM, |
119 | }; |
118 | }; |
… | |
… | |
187 | bool ACC (RW, force_newmap); // force a newmap before next map update |
186 | bool ACC (RW, force_newmap); // force a newmap before next map update |
188 | uint16 ACC (RW, look_position); /* start of drawing of look window */ |
187 | uint16 ACC (RW, look_position); /* start of drawing of look window */ |
189 | uint16 ACC (RW, mss); // likely tcp maximum segment size |
188 | uint16 ACC (RW, mss); // likely tcp maximum segment size |
190 | uint8 ACC (RW, mapx), ACC (RW, mapy); /* How large a map the client wants */ |
189 | uint8 ACC (RW, mapx), ACC (RW, mapy); /* How large a map the client wants */ |
191 | uint8 ACC (RW, itemcmd); /* What version of the 'item' protocol command to use */ |
190 | uint8 ACC (RW, itemcmd); /* What version of the 'item' protocol command to use */ |
192 | uint8 ACC (RW, faceset); // CF+ selected faceset |
191 | uint8 ACC (RW, tileset); // selected tileset |
193 | uint8 ACC (RW, ws_version); // websocket protocol versio for framing |
192 | uint8 ACC (RW, ws_version); // websocket protocol versio for framing |
194 | |
193 | |
195 | maptile_ptr ACC (RW, current_map); // CF+ last/current player map |
194 | maptile_ptr ACC (RW, current_map); // last/current player map |
196 | region_ptr ACC (RW, current_region); // CF+ last/current player region |
195 | region_ptr ACC (RW, current_region); // last/current player region |
197 | int ACC (RW, current_x), ACC (RW, current_y); // CF+ last/current map position |
196 | int ACC (RW, current_x), ACC (RW, current_y); // CF+ last/current map position |
198 | |
197 | |
199 | tstamp ACC (RW, last_send); // last data send on socket. |
198 | tstamp ACC (RW, last_send); // last data send on socket. |
200 | |
199 | |
201 | float ACC (RW, socket_timeout); /* after how many seconds of no ack do we declare dead */ |
200 | float ACC (RW, socket_timeout); /* after how many seconds of no ack do we declare dead */ |