]> icculus.org git repositories - taylor/freespace2.git/blob - include/multilag.h
Initial revision
[taylor/freespace2.git] / include / multilag.h
1 /*
2  * $Logfile: /Freespace2/code/Network/multilag.h $
3  * $Revision$
4  * $Date$
5  * $Author$
6  *
7  * $Log$
8  * Revision 1.1  2002/05/03 03:28:12  root
9  * Initial revision
10  *
11  * 
12  * 5     6/07/99 9:51p Dave
13  * Consolidated all multiplayer ports into one.
14  * 
15  * 4     11/19/98 8:03a Dave
16  * Full support for D3-style reliable sockets. Revamped packet lag/loss
17  * system, made it receiver side and at the lowest possible level.
18  * 
19  * 3     11/05/98 5:55p Dave
20  * Big pass at reducing #includes
21  * 
22  * 2     10/07/98 10:53a Dave
23  * Initial checkin.
24  * 
25  * 1     10/07/98 10:50a Dave
26  * 
27  * 12    4/27/98 6:02p Dave
28  * Modify how missile scoring works. Fixed a team select ui bug. Speed up
29  * multi_lag system. Put in new main hall.
30  * 
31  * 11    4/04/98 8:42p Dave
32  * Tested and debugged UDP reliable socket layer. Modified lag system to
33  * take this into account. 
34  * 
35  * 10    4/01/98 11:19p Dave
36  * Put in auto-loading of xferred pilot pic files. Grey out background
37  * behind pinfo popup. Put a chatbox message in when players are kicked.
38  * Moved mission title down in briefing. Other ui fixes.
39  * 
40  * 9     3/14/98 2:48p Dave
41  * Cleaned up observer joining code. Put in support for file xfers to
42  * ingame joiners (observers or not). Revamped and reinstalled pseudo
43  * lag/loss system.
44  * 
45  * 8     1/15/98 6:12p Dave
46  * Fixed weapons loadout bugs with multiplayer respawning. Added
47  * multiplayer start screen. Fixed a few chatbox bugs.
48  * 
49  * 7     1/11/98 10:03p Allender
50  * removed <winsock.h> from headers which included it.  Made psnet_socket
51  * type which is defined just as SOCKET type is.
52  * 
53  * 6     12/29/97 5:21p Dave
54  * Put in object update sequencing for multiplayer.
55  * 
56  * 5     12/16/97 6:17p Dave
57  * Put in primary weapon support for multiplayer weapon select screen.
58  * 
59  * 4     12/10/97 4:46p Dave
60  * Added in more detailed support for multiplayer packet lag/loss. Fixed
61  * some multiplayer stuff. Added some controls to the standalone.
62  * 
63  * 3     12/01/97 4:59p Dave
64  * Synchronized multiplayer debris objects. Put in pilot popup in main
65  * hall. Optimized simulated multiplayer lag module. Fixed a potential
66  * file_xfer bug.
67  * 
68  * 2     11/28/97 5:06p Dave
69  * Put in facilities for simulating multiplayer lag.
70  * 
71  * 1     11/28/97 4:38p Dave
72  * Initial Revision
73  * 
74  * $NoKeywords: $
75  */
76
77 #ifndef _MULTI_LAG_HEADER_FILE
78 #define _MULTI_LAG_HEADER_FILE
79
80 #ifndef NDEBUG
81         // #define MULTI_USE_LAG                                                                
82 #endif
83
84 struct fd_set;
85 struct timeval;
86
87 // initialize multiplayer lagloss. in non-debug situations, this call does nothing
88 void multi_lag_init();
89
90 // shutdown multiplayer lag
91 void multi_lag_close();
92
93 // select for multi_lag
94 int multi_lag_select(int nfds, fd_set *readfds, fd_set *writefds, fd_set *except_fds, const timeval *timeout);
95
96 // recvfrom for multilag
97 int multi_lag_recvfrom(uint s, char *buf, int len, int flags, struct sockaddr *from, int *fromlen);
98
99 #endif
100