summaryrefslogtreecommitdiff
path: root/network_server.c
AgeCommit message (Collapse)Author
2006-06-27(svn r5391) Miscellaneous, mostly bracing and whitespace, nothing spectaculartron
2006-06-14(svn r5265) Replace a dozen bogus uses of strncmp() by strcmp()tron
2006-04-22(svn r4521) - Fix: be consistent about the size of the player-name in MP. ↵Darkvater
This hopefully fixes a crash on lesser OS's (eg Win98). Use ttd_strlcpy() to just copy over strings and properly terminate them because different implementations of snprintf() behave differently. Courtesy of TrueLight
2006-04-03(svn r4267) - Fix (r4241): also validate the error number that a client ↵Darkvater
receives from a server, and encapsulate this functionality into GetNetworkErrorMsg().
2006-04-02(svn r4243) Unbreak compilationtron
2006-04-02(svn r4241) - Fix: Perform validation on the error number that a server ↵peter1138
receives from a client. An invalid value may cause the server to terminate.
2006-03-21(svn r3997) - Default the patch-setting 'pause_on_join' to true.Darkvater
2006-03-02(svn r3726) - [6/6] Finalize conversion, finally save the patches struct.Darkvater
- Remove the temporary synchronisation in during the map-transfer as this is no longer needed - The saved patches work just like the saved gameoptions. You have a _patches and a _patches_newgame struct. The _patches_newgame struct contains the values from the configuration file and thus the defaults for new games. When a new game is started or an older game is loaded, the default values are copied over to _patches to be used. When you load a game that has PATS saved, the default values are also loaded, but immediately overwritten by the values from the savegame. This ensures that player-based values are always taken from your personal preferences. - The current implementation also changes the default values if you change player-based settings in the game. For example changing window_snap_radius in a certain game will also change it for all next OpenTTD sessions. - The savegame version has been increased to 22. - The last 6 orso patches close the following reports: [ 1366446 ] different names for patches: all patch settings have the same name as in the configuration file and are reachable from the console. [ 1288024 ] Strange string on OTTD initial screen: configuration (and this includes patches) inputs are validated and clamped to their minimum/maximum values. [ 1423198 ] Make "Signals on Drive side" player, not server, based: this is only visual so current setting is to save it with the savegame but not synchronise in multiplayer. [ 1208070 ] Patches and New GRF options saved: apart from newgrf this is done
2006-03-02(svn r3721) - [3/4] Present the game with a unified structure for the ↵Darkvater
configuration-ini, saveload, console and gui representations of the settings. From part 3 on, OpenTTD is once again compilable. - Code has been added to the saveload code to honour the SLF_SAVE_NO and SLF_NETWORK_NO flags. SLF_NETWORK_NO just reads in the the bytestream and then discards it because that setting is not synchronised. For this the function SlSkipBytes() has been reinstated - SAVEGAME_VERSION has been changed from a constant ENUM to a constant integer. This was done for the configuration-code to be able to tell which version of a CONDVAR type to handle. As said before, because settings can be saved to the savegame, they will become conditional at some point. The configuration code always has to read the 'most recent' version. - GameOptions are saved through the new structure. It is fully compatible with any old savegame...however it is better. Because of the move to this new format we can instruct the loader to skip certain variables. Autosave for example isn't synchronised anymore (in the network). The same goes for currency and kilometers :D. That is the only functionality change this patch is supposed to have if I have written it correctly. - NOTE! Patches are still not saved so for Multiplayer to work network_client.c and network_server.c needed slight modifications.
2006-02-01(svn r3511) More whitespace ([FS#46] by Rubidium)tron
2006-01-31(svn r3500) - Workaround the inaccurate count of spectators/companies that ↵Darkvater
can happen in certain border-cases. For now just dynamically get this value when requested so it is always right. To do properly all player/client creation/destruction needs a hook for networking.
2006-01-25(svn r3430) - You can of course not join when there are more companies than ↵Darkvater
the maximum set, not the other way around.
2006-01-25(svn r3427) - Feature: Allow seeing and setting the maximum amount of ↵Darkvater
companies and spectators for a server. This can be changed/viewed during runtime as well in the console.
2006-01-05(svn r3365) Staticise 36 functionstron
2005-11-18(svn r3218) -Feature: Multiheaded train engines will now stay in the same trainbjarni
This means that any user attempt to remove a rear engine will tell the user to move the front engine instead This fixes the assert when moving multiheaded engines (introduced in r3144) Note: to make old savegames use this feature, some engines might be turned around in order to link engines in pairs -Codechange: train subtype is now a bitmask This allows fast access to info like if it is a wagon or engine and if it is in front and so on Note: savegame version bump
2005-10-19(svn r3067) - Feature: allow unbanning players based on banlist-id (as well ↵Darkvater
as IP). - Feature: 'status' and 'clients' now show the IP of the players
2005-08-28(svn r2899) -Fix: Several format string vulnerabilities and buffer overflows ↵tron
in the network code
2005-08-07(svn r2828) Only command.c needs to know about _docommand_recursive, so make ↵tron
it static. Tell me if there's a problem, because i removed it from network_server.c, but afaict it should be ok
2005-07-29(svn r2755) Fix: Fix a desync issue with autoreplaceludde
2005-07-26(svn r2720) Remove unused declarations and definitionstron
2005-07-26(svn r2716) Do not use strncat()tron
2005-07-24(svn r2701) Insert Id tags into all source filestron
2005-07-22(svn r2673) Include functions.h directly, not globally via openttd.htron
2005-07-22(svn r2672) Move saving/loading related declarations to saveload.htron
2005-07-21(svn r2669) Shuffle some more stuff around to reduce dependenciestron
2005-07-16(svn r2591) Codechange: [network] Cleanup NetworkHandleCommandQueueludde
2005-07-16(svn r2589) Fix: [network] Fixed static variable that wasn't initialized. ↵ludde
Would stop the sync checking from working in some cases.
2005-07-16(svn r2588) Codechange: Remove PLAYER_SEED_RANDOMludde
2005-07-15(svn r2583) Move OS specific code out of misc.cludde
Added support for Mersenne Twister random number generator (not implemented in network yet) Wrap player randoms around #ifdef
2005-07-05(svn r2521) -Codechange: Removed trailing "\n"s from DEBUG statementscelestar
2005-06-21(svn r2468) -Codechange: Got rid of DEREF_PLAYER and replaced it by GetPlayercelestar
2005-05-17(svn r2339) - Fix: on a dedicated server, after the joining of a player, the ↵Darkvater
player was set to player 0 instead of remaining OWNER_SPECTATOR. Fix this, and allow the dedicated server to execute commands (so 'patch <value>') now works and not only when a client is connected.
2005-05-15(svn r2324) Introduce _cmd_text for passing strings with a command instead ↵tron
of abusing _decode_parameters as text buffer. This should prevent several possible buffer overruns and is a bit cleaner to use. As bonus it reduces the size of most command packets by 79 bytes.
2005-05-14(svn r2309) - CodeChange: Change all _iconsole_color_whatever into ↵Darkvater
_icolour_wtv (abbreviated). Besides the changed into proper english, yes this commit is pretty useless ;)
2005-05-14(svn r2308) - Fix: enforce server-only and/or offline commands by giving ↵Darkvater
them flags in the process table. This also fixes bug "[ 1190944 ] Many commands not checked for security" - CodeChange: move ValParamRailtype() to check rail type from command.h to vehicle.h where it is better suited.
2005-05-12(svn r2299) - Fix: add more verbose output to possible hack-attempt.Darkvater
- Btw, only 14 more commands are remaining, 88% done \o/
2005-05-02(svn r2256) - Fix: Trains cannot find a depot when they are in a tunnel. (glx)matthijs
- Add: GetVehicleTrackdir() helper function. - Codechange: Moved SortStruct from vehicle_gui.h to ttd.h, so the dependency from vehicle.h on vehicle_gui.h could be removed. - Codechange: Typedeffed the VehicleTypes struct so it can be used as the type for Vehicle.type instead of "byte". - Codechange: Removed prototype for VehicleSorter(), which had no implementation anymore and was never called.
2005-03-29(svn r2106) -Fix: improved the network-join algoritm, it is now a bit more ↵truelight
stable -Add: added 'pause_on_join' and 'max_join_time' for MP games, where you can auto-pause the game when a client wants to join the game. This to avoid connection losses because of big maps (200+ trains). (with tnx to #openttdcoop for the ideas and testing)
2005-02-06(svn r1821) Move generic string handling functions to string.[ch] and ↵tron
introduce stre{cpy,cat}, see string.h for their semantics
2005-02-06(svn r1813) Declare functions implemented in strings.c in their own shiny ↵tron
new header (though i think some of these function don't belong into strings.c)
2005-02-05(svn r1803) Move debugging stuff into files of it's owntron
2005-01-22(svn r1594) Convert all undefined parameter lists to (void) and add the ↵tron
appropriate warning flags in the Makefile
2005-01-19(svn r1568) made an enum of train subtypes to make the code more readablebjarni
2005-01-16(svn r1546) -Fix: possible buffer-overflow in networktruelight
2005-01-15(svn r1527) -Add: RCon (Remote Connection). A server can set:truelight
'set rcon_pw <password>' Which enables rcon. A client can now do: 'rcon <password> "<command>"' The command will be executed on the server. (guru3) -Fix: 'kick 1' did crash dedicated servers -Fix: server password is now correctly saved !!Warning!!: do not give your rcon password to people you do not thrust!
2005-01-15(svn r1518) -Fix: server issue where some company names were wrongdarkvater
-Fix: Highscore troubles; accessing members of deleted window
2005-01-14(svn r1510) -Add: Improved Network Lobby GUI: (bociusz)truelight
- Added green dot if company income is positive (else red dot) - Added lock icon if company is password protected
2005-01-10(svn r1465) -Fix: [1099101] starting year patch goes out of range. Clamped ↵darkvater
year between 1920-2090 as wel as adding defines for it.
2005-01-09(svn r1451) Fix some of the signed/unsigned comparison warningstron
2005-01-05(svn r1389) -Add: [Network] Added packet protection. No longer a client or ↵truelight
server reads beyond the size of the packet -Fix: [Network] A server no longer crashes when a client sends an invalid DoCommand, but drops the client instead.