2 * Copyright (C) Volition, Inc. 1999. All rights reserved.
4 * All source code herein is the property of Volition, Inc. You may not sell
5 * or otherwise commercially exploit the source or things you created based on
10 * $Logfile: /Freespace2/code/Network/multilag.h $
16 * Revision 1.3 2002/06/16 05:20:01 relnev
17 * work around some gcc 3.1 weirdness
19 * Revision 1.2 2002/06/09 04:41:14 relnev
20 * added copyright header
22 * Revision 1.1.1.1 2002/05/03 03:28:12 root
26 * 5 6/07/99 9:51p Dave
27 * Consolidated all multiplayer ports into one.
29 * 4 11/19/98 8:03a Dave
30 * Full support for D3-style reliable sockets. Revamped packet lag/loss
31 * system, made it receiver side and at the lowest possible level.
33 * 3 11/05/98 5:55p Dave
34 * Big pass at reducing #includes
36 * 2 10/07/98 10:53a Dave
39 * 1 10/07/98 10:50a Dave
41 * 12 4/27/98 6:02p Dave
42 * Modify how missile scoring works. Fixed a team select ui bug. Speed up
43 * multi_lag system. Put in new main hall.
45 * 11 4/04/98 8:42p Dave
46 * Tested and debugged UDP reliable socket layer. Modified lag system to
47 * take this into account.
49 * 10 4/01/98 11:19p Dave
50 * Put in auto-loading of xferred pilot pic files. Grey out background
51 * behind pinfo popup. Put a chatbox message in when players are kicked.
52 * Moved mission title down in briefing. Other ui fixes.
54 * 9 3/14/98 2:48p Dave
55 * Cleaned up observer joining code. Put in support for file xfers to
56 * ingame joiners (observers or not). Revamped and reinstalled pseudo
59 * 8 1/15/98 6:12p Dave
60 * Fixed weapons loadout bugs with multiplayer respawning. Added
61 * multiplayer start screen. Fixed a few chatbox bugs.
63 * 7 1/11/98 10:03p Allender
64 * removed <winsock.h> from headers which included it. Made psnet_socket
65 * type which is defined just as SOCKET type is.
67 * 6 12/29/97 5:21p Dave
68 * Put in object update sequencing for multiplayer.
70 * 5 12/16/97 6:17p Dave
71 * Put in primary weapon support for multiplayer weapon select screen.
73 * 4 12/10/97 4:46p Dave
74 * Added in more detailed support for multiplayer packet lag/loss. Fixed
75 * some multiplayer stuff. Added some controls to the standalone.
77 * 3 12/01/97 4:59p Dave
78 * Synchronized multiplayer debris objects. Put in pilot popup in main
79 * hall. Optimized simulated multiplayer lag module. Fixed a potential
82 * 2 11/28/97 5:06p Dave
83 * Put in facilities for simulating multiplayer lag.
85 * 1 11/28/97 4:38p Dave
91 #ifndef _MULTI_LAG_HEADER_FILE
92 #define _MULTI_LAG_HEADER_FILE
95 // #define MULTI_USE_LAG
101 // initialize multiplayer lagloss. in non-debug situations, this call does nothing
102 void multi_lag_init();
104 // shutdown multiplayer lag
105 void multi_lag_close();
107 // select for multi_lag
108 int multi_lag_select(int nfds, fd_set *readfds, fd_set *writefds, fd_set *except_fds, const timeval *timeout);
110 // recvfrom for multilag
111 int multi_lag_recvfrom(uint s, char *buf, int len, int flags, struct sockaddr *from, int *fromlen);