/[LeafOK_CVS]/pvpgn-1.7.4/src/common/udp_protocol.h
ViewVC logotype

Annotation of /pvpgn-1.7.4/src/common/udp_protocol.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (hide annotations)
Tue Jun 6 03:41:38 2006 UTC (19 years, 9 months ago) by sysadm
CVS Tags: pvpgn_1-7-4-0_MIL
Branch point for: GNU, MAIN
Content type: text/x-chdr
Initial revision

1 sysadm 1.1 /*
2     * Copyright (C) 1998 Mark Baysinger (mbaysing@ucsd.edu)
3     * Copyright (C) 1998,1999,2000,2001 Ross Combs (rocombs@cs.nmsu.edu)
4     *
5     * This program is free software; you can redistribute it and/or
6     * modify it under the terms of the GNU General Public License
7     * as published by the Free Software Foundation; either version 2
8     * of the License, or (at your option) any later version.
9     *
10     * This program is distributed in the hope that it will be useful,
11     * but WITHOUT ANY WARRANTY; without even the implied warranty of
12     * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13     * GNU General Public License for more details.
14     *
15     * You should have received a copy of the GNU General Public License
16     * along with this program; if not, write to the Free Software
17     * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
18     */
19     #ifndef INCLUDED_UDP_PROTOCOL_TYPES
20     #define INCLUDED_UDP_PROTOCOL_TYPES
21    
22     /*
23     * This file describes the UDP chat packets. The game packets aren't
24     * in here and would probably go in another file. The first 4 bytes
25     * seem to be a little-endian 32 bit integer id for the packet type.
26     * FIXME: add more UDP packet types
27     */
28     /******************************************************/
29     typedef struct
30     {
31     bn_int type;
32     } PACKED_ATTR() t_udp_header;
33     /******************************************************/
34    
35    
36     /******************************************************/
37     typedef struct
38     {
39     t_udp_header h;
40     } PACKED_ATTR() t_udp_generic;
41     /******************************************************/
42    
43    
44     /******************************************************/
45     /* client echos back with UDPOK packet */
46     /*
47     05 00 00 00 74 65 6E 62 ....tenb
48     */
49     #define SERVER_UDPTEST 0x00000005
50     typedef struct
51     {
52     t_udp_header h;
53     bn_int bnettag; /* 74 65 6E 62 */
54     } PACKED_ATTR() t_server_udptest;
55     /******************************************************/
56    
57    
58     /******************************************************/
59     /*
60     07 00 00 00 49 41 19 00 ....IA..
61    
62     07 00 00 00 11 60 1D 00 .....`..
63     */
64     #define CLIENT_UDPPING 0x00000007
65     typedef struct
66     {
67     t_udp_header h;
68     bn_int unknown1; /* time? */
69     } PACKED_ATTR() t_client_udpping;
70     /******************************************************/
71    
72    
73     /******************************************************/
74     /*
75     From Brood War 1.04
76     08 00 00 00 75 EC A0 28 ....u..(
77     */
78     #define CLIENT_SESSIONADDR1 0x00000008
79     typedef struct
80     {
81     t_udp_header h;
82     bn_int sessionkey;
83     } PACKED_ATTR() t_client_sessionaddr1;
84     /******************************************************/
85    
86    
87     /******************************************************/
88     /*
89     From Brood War 1.07
90     09 00 00 00 7A 11 07 ED 9D DF 01 00 ....z.......
91     */
92     #define CLIENT_SESSIONADDR2 0x00000009
93     typedef struct
94     {
95     t_udp_header h;
96     bn_int sessionkey;
97     bn_int sessionnum;
98     } PACKED_ATTR() t_client_sessionaddr2;
99     /******************************************************/
100    
101     #endif

webmaster@leafok.com
ViewVC Help
Powered by ViewVC 1.3.0-beta1