Commit Graph

186 Commits

Author SHA1 Message Date
rubidium 98f77876e6 (svn r9341) [0.5] -Backport from trunk (r8943, r8955, r8976, r8999, r9009):
- Fix: NewGRF support for vehicle variable 48 (r8943)
- Fix: crash on loading savegames with GRFs that do not have their GRF info/name set (r8955)
- Fix: reinitialize all engines after grf files have been reloaded/changed (r8976)
- Fix: do not select a disabled platform length/number of track count when going out of drag-drop mode (r8999)
- Fix: play the correct engine sound based on the engine type instead of the sprite (r9009)
2007-03-19 18:47:10 +00:00
Darkvater 93586cb6b6 (svn r8905) [0.5] -Update readme's, bugs, installers, changelogs etc. to prepare for 0.5.0.
[0.5] -Remove the limitation that games are refused to be loaded if no newgrf is present (was already like this in trunk/).
2007-02-26 00:19:31 +00:00
Darkvater 36134a7285 (svn r8871) [0.5] -Backport from trunk (r8689, r8794, r8802, r8808):
- Crash when an old savegame had buoys on the northern edge of the map (r8689)
 - It was possible to take over buoys by building a station next to them (r8794)
 - Adhere order types for ship order insertion to determine destination type (r8802)
 - Do not show the 'edit sign' window for spectators (r8808)
2007-02-24 01:14:54 +00:00
Darkvater edc2ac8bbf (svn r8870) [0.5] -Backport from trunk (r8684, r8709, r8738, r8777, r8828):
- Bool (uint32 in PPC) was written to as a uint8 (r8684)
 - Fix a problem where loading times for overhanging trains are miscomputed (r8709)
 - Load newer TTDP games (update coastal tiles) (r8738)
 - Cloning unaware of articulated locomotives that could refit without refitting the front unit (r8777)
 - Load station rectangle for all savegames, not only after version 27 (r8828)
2007-02-24 01:02:15 +00:00
rubidium 4e3652f337 (svn r8625) [0.5] -Backport from trunk (8253, 8273, 8497, 8520 + 8542):
-Codechange: Be more strict about language generation and fail any languages not having the mandatory ##name, ##ownname and ##isocode pragma's.
-Fix: return value from clamp was ignored 
-Codechange: Increase the size of the sound/video/music-drivers to 32 bytes (instead of 16) so their actual parameters can be passed. Sound has for example 'bufsize' and 'hz'.
-Fix/Feature: requery gameservers that did not respond to their first query.
2007-02-08 10:19:03 +00:00
rubidium 1584e061eb (svn r8624) [0.5] -Backport from trunk (8239, 8240, 8315):
-Regression (r7278): Help window was empty for UNICODE builds 
-Fix (r8013): Put the output of -h to stdout and not to stderr (through ShowInfo) 
-Fix: use ShowInfo over fprintf(stderr, as Windows doesn't always have a stderr visible/available
2007-02-08 10:04:57 +00:00
Darkvater 6c3b245d88 (svn r8182) -Backport from trunk (r8137, r8147, r8157):
- (FS#551) roadstop->num_vehicles was wrong for old savegames loaded for MP (r8137)
 - v->leave_depot_instantly was not always reset correctly (r8147)
 - moving cargo during auto replaces did not update the cached vehicle weight for trains properly (r8157)
 *NOTE* This fixes several desync issues. Big props to Rubidium for finding, debugging
 and fixing them!
2007-01-17 01:23:50 +00:00
Darkvater ac3b1883ed (svn r8180) -Backport from trunk (r8093, r8094, r8105, r8106, (r8107), r8111, r8165):
- Show the activated status of the GRF after pressing apply in window (r8094)
 - Add the ability to load savegames without matching grf's.
   *NOTE*: currently this feature is different from trunk in behaviour as it does NOT
   allow you to load savegames with MISSING grfs only compatible (matching GRFID, non-
   matching MD5SUM).
2007-01-17 01:17:44 +00:00
Darkvater 40245ce496 (svn r8179) -Backport from trunk (r8065, r8101, r8119, r8123, r8140, r8150):
- The station list does now remember the sort settings (r8065)
 - Uninitializing windows calls WE_DESTROY to free dynamic memory used (r8101, r8119)
 - (FS#538) Findfirstbit returns first bit (bouys now numbered 1..9) (r8123)
 - FS#54) Combat helicopter shoots from right position, (r8140)
 - Submarine disaster did not move around (r8158)
2007-01-17 01:02:51 +00:00
Darkvater 25059d28df (svn r8172) -Backport from trunk (r8013, r8134):
- Show error messages about our own data files as ShowInfo(F) and output console error to stderr and not stdout.
2007-01-17 00:05:51 +00:00
Darkvater f3424f51bc (svn r7671) -Backport from trunk (r7560, r7561, r7566):
- No new company could join if 8 clients were connected in less than 8 companies (r7560).
 - [FS#431] internal and visible settings of autorenew could go out of sync (r8561).
 - Server told clients to start syncing from a bad position, causing asserts/crashes (r7566).
2006-12-30 23:20:00 +00:00
Darkvater 652e834ee7 (svn r7664) -Backport from trunk (r7587, r7588, r7600, r7605, r7626, r7629):
- [OSX] universal binary docs, makefile (r7587, r7588, r7626).
 - General documentation update (r7600, r7605).
 - openttd -h showed outdated help for '-n' switch (r7629).
2006-12-30 23:00:52 +00:00
Darkvater 9b9add65c3 (svn r7523) -Feature: Add the possibility to change the newgrf configuration of a running game.
This is only possible in SP (or in the intro menu). During game play you will
 get a confirmation window when applying the changes as some actions can crash
 OpenTTD and/or make your current game unplayable.
2006-12-21 10:29:16 +00:00
Darkvater 39eff474d3 (svn r7521) -Codechange: Rename UpdateAllWaypointCustomGraphics to AfterLoadWaypoints to be more conforming with other such functions. 2006-12-21 00:13:56 +00:00
glx 64bf2432bb (svn r7506) -Codechange: [NewGRF] Add action 7/9/D variable 0x81 (current year) 2006-12-18 15:34:12 +00:00
Darkvater 75c053453d (svn r7470) -Codechange: Leave elrails enabled after loading old (pre-optional) and very old (pre-elrails) games. Let the user manually disable if if undesired. 2006-12-10 15:21:48 +00:00
peter1138 df1684b0d9 (svn r7469) -Fix (r7348): NewGRF settings weren't loaded in cases. 2006-12-10 12:12:26 +00:00
Darkvater f87c8834e2 (svn r7449) -Codechange: Rename _path to _paths as it is technically more correct, but mainly because
it interferes with OS/2 symbol in libc (psmedley)
2006-12-09 10:56:12 +00:00
peter1138 bd66cc5756 (svn r7348) -Feature: Initial support for saving NewGRF settings with savegames. Back up your savegames... 2006-12-04 08:30:04 +00:00
Darkvater 9b4d3ff4b8 (svn r7312) -Fix: When loading a game from a dedicated server the local player global variable was
wrongly set to 0. In theory this allowed a dedicated server to also play. I see no
 history for this bug, but it has been there since the introduction of the dedicated
 server probably. Thanks peter1138 for bringing it to my attention and thanks myself
 for rewriting the code so this bug could surface ;p
2006-11-30 22:23:11 +00:00
Darkvater 7c945bf828 (svn r7280) -Codechange: Replace some sprintf() functions with the safer snprintf() functions 2006-11-28 20:55:16 +00:00
peter1138 9253387001 (svn r7273) -Fix (r7250): Initialise game palette before driver initialisation. This fixes a 'black screen' problem with fullscreen with the win32 video driver. 2006-11-28 14:32:24 +00:00
peter1138 c079c83eb6 (svn r7250) -Codechange: Shuffle sprite loading and character width caching around a bit. This reduces the number of times the sprites are loaded from 5 to 2, just for the intro game. 2006-11-24 18:39:22 +00:00
KUDr f2cda44d2e (svn r7195) -Feature: [FS#297, optional elrails] New patches/vehicles option 'disable electrified railways'.
(original patch by maedhros, ideas: peter1138, Darkvater, Rubidium, Patrick, Eddi|zuHause, ..)
2006-11-17 19:31:44 +00:00
peter1138 1a4f1c8177 (svn r7182) -Feature: Merge utf8 branch. This brings us support for Unicode/UTF-8 and the option for fonts rendered by FreeType. Language changes to come. 2006-11-16 22:05:33 +00:00
tron 2a53bcf2b0 (svn r7065) Use simple assignment instead of memcpy() 2006-11-05 08:24:52 +00:00
Darkvater ac2b6f39b1 (svn r7048) -Cleanup: DEBUG doesn't need a newline character, use DEBUG instead of printf and the
verb is build/built/built not build/*/build or build/*/builded.
2006-11-03 01:18:40 +00:00
tron e397b721cd (svn r6986) Use the pool macros for the Town pool 2006-10-28 11:55:29 +00:00
tron f51d2a3311 (svn r6983) Use the pool macros for the Station pool 2006-10-28 11:48:21 +00:00
tron 470a054c06 (svn r6982) Use the pool macros for the Sign pool 2006-10-28 11:43:56 +00:00
tron c61e0963e0 (svn r6980) Use the pool macros for the Order pool 2006-10-28 11:37:26 +00:00
tron 4cb479e083 (svn r6979) Use the pool macros for the Industry pool 2006-10-28 11:32:45 +00:00
tron 953344fdcc (svn r6975) Use the pool macros for the Vehicle pool 2006-10-28 10:55:59 +00:00
Darkvater ee27bb497c (svn r6884) -Codechange: Add strict bounds checking in string formatting system.
The last parameter should point to the end of the buffer (eg lastof(buf))
 Courtesy of Tron.
2006-10-21 23:31:34 +00:00
Darkvater e97d801d92 (svn r6816) -Codechange: Some coding style, variable localization, const correctness.
-Codechange: 'quited' is not a word, use has_quit instead for NetworkClientState
2006-10-17 23:34:12 +00:00
Darkvater fbc724c6cb (svn r6814) -Codechange: For network games ci->client_playas was always p->index + 1. To
correctly handle this ci->client_playas - 1 was used all over the code making
 it pretty confusing at times. Use proper one-on-one values now. Special handling
 is only needed for user-output to not to confuse users.
2006-10-17 22:16:46 +00:00
Darkvater d5baf25923 (svn r6787) -Codechange: Use PLAYER_NEW_COMPANY as a player identifier wishing to become a
new player instead of a 0.
2006-10-15 23:48:34 +00:00
Darkvater b2110cbaed (svn r6780) -Codechange: Remove GPMI leftovers (-b impersonisation of AI in MP). 2006-10-15 17:01:19 +00:00
Darkvater 6b6d908308 (svn r6776) -Codechange: Use IsValidPlayer() function to determine of a PlayerID is an
actual playable player (< MAX_PLAYERS) or not.
2006-10-14 22:31:18 +00:00
Darkvater dad5d5dd72 (svn r6774) -Codechange: Rename the badly named OWNER_SPECTATOR to PLAYER_SPECTATOR and
put it into player.h where it belongs (instead of map.h)
2006-10-14 15:49:43 +00:00
Darkvater 1436bbbc84 (svn r6766) -Codechange: Move _openttd_revision[] into the functions that use it instead of global 2006-10-13 15:52:22 +00:00
Darkvater cad526ef36 (svn r6754) -Codechange: Remove some #idef ENABLE_NETWORK specific defines. With networking
disabled hardcode _networking/_network_available to zero and let the compiler
 handle all optimizations.
2006-10-12 14:59:27 +00:00
Darkvater 15bf48acfd (svn r6753) -Codechange: Move some function declerations from functions.h into network.h
and let NetworkDisconnect handle all shutdown related operations.
2006-10-12 14:48:36 +00:00
bjarni ea63050d5f (svn r6624) -Feature: added ability to add refit commands to vehicle orders (can only be done in goto depot orders)
Example: make a train transport iron ore from A to B, then it visits a depot and refits to steel
     It then transport steel back to A or near A if there is a factory and then it visits another depot to refit to iron ore again

   This is controlled in the orders. If a goto depot order is lightlighted, then "Unload" changes to "Refit"
   Control click "Refit" removes the refit part of the order (as the tooltip says)
   The player will still pay the normal refit costs

   Known issues:
      If a vehicle is not in a depot, then the refit window will fail to tell refitted cargo capacity
      Refit costs in the refit window can sometimes print 0 when it should not because the refit calculation is unaware that the vehicle will be refitted in between

   Warning: autoreplace got a protection against replacing something so you get a new cargo type, but it can fail here. In the iron ore/steel example, it can see that
      the vehicle carries iron ore and the new one can be refitted to iron ore, then it will replace. It will not check to see that it's valid for steel as well.
      This is something to look into in the future
2006-10-03 14:52:39 +00:00
peter1138 f469d3fe76 (svn r6544) - Codechange: Rename CmdReplaceVehicle to CmdSetAutoReplace, to reflect what it does. 2006-09-28 07:02:55 +00:00
peter1138 88d5472fe8 (svn r6455) - Feature: Add 2cc (two company colours) livery schemes. This replaces the original colour selection window and bumps the saveload version. Liveries are supported for all vehicles, not just those with 2cc support. Thanks to lakie for GUI inspiration. 2006-09-15 12:27:00 +00:00
bjarni 00a08601c9 (svn r6424) -Codechange: [autoreplace] removed a loop though all vehicles from each time the window is redrawn
To do this, the player struct contains an array, that contains the count of each engine type that the player owns
   Those arrays are updated each time a vehicle is build or deleted and is calculated on load (it's not saved)
   It's possible to access the arrays outside of the autoreplace GUI, so feel free to read from them in other patches as well
2006-09-08 10:47:39 +00:00
rubidium 63687763e9 (svn r6381) -Cleanup: make the '/* */' comments that span multiple lines more uniform.
-Cleanup: whitespace alignment of a few tables.
2006-09-04 20:40:33 +00:00
rubidium a7cfb80c40 (svn r6380) -Codechange: unify all ways to quit OTTD.
This means that in the intro menu the 'Quit' button immediatelly quits
  and the 'Quit' in the menu of the normal game and scenario editor
  immediatelly quits when the 'autosave_on_exit' patch is turned on.
  This is the same way as the OS/window manager initiated quits, like
  alt-F4 and the 'x' in the (OS/window manager drawn) title bar of OTTD.
2006-09-04 17:30:30 +00:00
rubidium 38ace9deef (svn r6366) -Fix (FS#324): when opening a scenario, the date was set 1920 years into the future. 2006-09-03 22:21:12 +00:00