Commit Graph

148 Commits

Author SHA1 Message Date
truelight 76bcaba601 (svn r6089) -Backport r6088: added -s (source) and -d (destination) to strgen (Darkvater) 2006-08-24 12:08:25 +00:00
rubidium d14ac4478d (svn r6086) -Fix: InteractiveRandom was not seeded properly resulting in the dedicated server always generating the same map. Thanks to the #openttdcoop team for detecting. 2006-08-24 10:19:59 +00:00
truelight 5fb6c9e1cc (svn r5974) -Codechange: added casts all around the place to make Windows 64bit happy (michi_cc) 2006-08-20 12:09:32 +00:00
truelight 10b842bddc (svn r5946) -Add: merged the TGP branch to mainline. TGP adds:
- New optional landscape generator (TerraGenesis Perlin)
  - Load heightmaps (either BMP or PNG)
  - Progress dialog while generating worlds (no longer a 'hanging' screen)
  - New dialogs for NewGame, Create Scenario and Play Heightmap
    - Easier to configure your landscape
    - More things to configure (tree-placer, ..)
  - Speedup of world generation
  - New console command 'restart': restart the map EXACTLY as it was when you
      first started it (needs a game made after or with this commit)
  - New console command 'getseed': get the seed of your map and share it with
      others (of course only works with generated maps)
  - Many new, world generation related, things
  - Many internal cleanups and rewrites
  Many tnx to those people who helped making this:
     Belugas, DaleStan, glx, KUDr, RichK67, Rubidium, and TrueLight (alfabetic)
  Many tnx to those who helped testing:
     Arnau, Bjarni, and tokai (alfabetic)
  And to all other people who helped testing and sending comments / bugs
  Stats: 673 lines changed, 3534 new lines, 79 new strings
2006-08-19 10:00:30 +00:00
truelight 83d56d6d79 (svn r5944) -Merge TGP (r5578, r5579, r5724, r5726): -Feature: filter for textboxes to only
allow certain patterns (like numbers only)
2006-08-19 09:31:22 +00:00
Darkvater 581476b7d2 (svn r5836) - Silence a warning on mingw. Thanks glx. 2006-08-10 17:28:13 +00:00
Darkvater 4ccdb04cd3 (svn r5831) - Fix (r5765): regression regarding windows filetimes. st->st_mtime's type time_t is only 64bit on windows64, so we need to convert it. 2006-08-10 09:10:41 +00:00
Darkvater adcaf779c4 (svn r5801) - Codechange: The exception dialog showed the last modification-date of win32.c instead of the last compilation-date. Use __DATE__ __TIME__ instead of __TIMESTAMP__; only affected windows not built with mingw/cygwin. 2006-08-07 11:31:27 +00:00
Darkvater 2a776775e5 (svn r5769) - Fix (r5762): fix some mistakes in the opendir code and filesize calculation. Thanks to Tron for noticing (and fixing). 2006-08-05 10:30:43 +00:00
Darkvater a9251d2d02 (svn r5767) - Cleanup: Improve upon the header file mess regarding fios. Move all relevant types from hal.h into fios.h, eliminate the unneccessary passing of a global variable, and extern variables in header files (declare in fios.c and misc_gui.c 2006-08-05 00:59:45 +00:00
Darkvater 198f6caf20 (svn r5766) - Cleanup: Unify FiosBrowseTo and FiosGetDescText 2006-08-05 00:53:09 +00:00
Darkvater 525a0ad4c0 (svn r5765) - Codechange: Fully unify the OS-specific FiosGet...List functions into fios.c, as well as FiosGetSavegameList and FiosGetScenarioList functions with the help of some callbacks. 2006-08-05 00:47:32 +00:00
Darkvater ee7b3de2f5 (svn r5764) - Cleanup: - Cleanup: Move the now unified FiosAlloc, compare_FiosItems, FiosFreeSavegameList, FiosMakeSavegameName, FiosDelete and FileExists to newly created file fios.c where it belongs.
- Fix: forgot to remove GetLanguageList from functions.h in previous commit
2006-08-05 00:16:24 +00:00
Darkvater b5e3718ac4 (svn r5763) - Cleanup: Move the now unified GetLanguageList and comparator function to strings.c where it belongs. 2006-08-04 23:45:20 +00:00
Darkvater 4de30befae (svn r5762) - Codechange: Implementation of POSIX-style opendir/readdir/closedir functions for windows using FindFirstFile/FindNextFile/FindClose.
- Add new header file fios.h that will be the place for all FIOS (game-list) types.
2006-08-04 23:41:13 +00:00
Darkvater 5bcaef5d86 (svn r5698) - Fix [r5697]: don't remove ctype include for win32.c; needed for toupper...ugh 2006-08-01 19:24:29 +00:00
Darkvater c5a3632929 (svn r5697) -Fix [r5684]: tolower() was undefined for certain architectures, strangly VS2003 didn't complain, VS2005 did. Thanks glx 2006-08-01 19:19:39 +00:00
belugas 2f6c73f098 (svn r5393) CodeChange : Little typo correction. Nothing spectacular. Only broke in MSVC 2006-06-28 03:29:14 +00:00
tron 2b27073156 (svn r5391) Miscellaneous, mostly bracing and whitespace, nothing spectacular 2006-06-27 21:25:53 +00:00
glx afee99ad06 (svn r4807) - Fix: win32 compilation was broken by r4802 2006-05-09 15:36:48 +00:00
Darkvater a665462cc1 (svn r4560) - Fix: (r3008) Remove VS2005 undefined vsnprintf() as it doesn't exist in the windows libraries (only _vsnprintf). This caused the bad function to be called that could result in non-properly terminated strings. Thanks for noticing Tron. 2006-04-23 22:28:26 +00:00
Darkvater b68b9b149a (svn r4301) - Fix: the maxlength parameter of Textbuf is supposed to be the size of the buffer (so length of string + '\0'), but in the code it was a mix of both. It didn't cause any problems though, only an occasionaly one-less character than allowed. (thanks Tron for noticing) 2006-04-06 19:11:41 +00:00
orudge fa467d2f58 (svn r4203) - Fix compilation on mingw32 (stdint.h not included) 2006-03-31 15:34:22 +00:00
Darkvater a91c52e169 (svn r4125) - Feature: Add a general TIC() TOC() mechanism using rdtsc or something similar on non-i386 architectures to performance-tune (critical) code. Some systems are probably missing, but those can be added later. 2006-03-26 21:15:09 +00:00
Darkvater 4125aa21f8 (svn r4124) - CodeChange: remove windows-specific code from initializing the random generator. There was no need for it. 2006-03-26 21:13:16 +00:00
Darkvater 9b5d8a9921 (svn r4105) - Feature: Add proper ISO-8859-15 <> LOCALCODE conversion. As the mess that is makefile can't properly support it at the moment, it is only available for MACOSX. Windows doesn't need FS conversion and I have no idea about OS/2 so it's disabled for them.
- CodeChange: Change the function GetCurrentLocale(). It returns the locale from some default environment-variables, plus a custom one defined as parameter. If all fail, it tries $LANG.
2006-03-25 09:22:10 +00:00
Darkvater 7656bf8075 (svn r4001) - Add length parameter to FiosMakeSavegameName() and use this function for creating the full path instead of home-brewn snprintf. 2006-03-21 22:08:15 +00:00
Darkvater 873768c2d2 (svn r3872) - [win32] Show the revision in crash.txt and enable the button to show the crash text in the crash-window 2006-03-14 21:31:51 +00:00
tron 84fb96fe85 (svn r3511) More whitespace ([FS#46] by Rubidium) 2006-02-01 07:36:15 +00:00
peter1138 9fd6b1009e (svn r3496) - Validate filename titles before they get displayed. This avoids crashes with UTF-8 encoded or bad filenames by replacing undisplayable characters with a '?' 2006-01-31 12:08:49 +00:00
Darkvater c8a2c7ae94 (svn r3442) - Fix: Only windows has stricmp. So define strcasecmp to stricmp when using MSVC 2006-01-26 17:32:49 +00:00
peter1138 592aee1e27 (svn r3309) Cygwin doesn't define _MSC_VER; check it exists before basing decisions on its value. 2005-12-16 22:01:38 +00:00
tron f7abff5f96 (svn r3181) -Bracing
-Indentation
-Whitespace
-DeMorgan's Law
-Test with NULL or 0 for non-booleans
-'\0' instead of 0 for chars
-Remove redundantly redundant comments (like DoFoo(); // Do foo)
-Join multiple short lines with a single statement
-Split single lines with multiple statements
-Avoid assignments in if
2005-11-14 19:48:04 +00:00
tron 1c867927a3 (svn r3163) Include header for toupper() 2005-11-10 17:21:05 +00:00
Darkvater 9bbf8ea9d0 (svn r3097) - Fix (regression): unix has a trailing slash after the paths, windows does not, no idea why os2 has. Way to go consistency :s. So anyways, just strip trailing slash 2005-10-28 00:18:57 +00:00
Darkvater f561993112 (svn r3096) - Feature: 'HOME' icon to saveload dialogs that jumps to the default save/load directory based on the dialog (added icon to openttd.grf, introduced FIOS_TYPE_DIRECT that allows arbitrary directory jumping).
- Fix: on Win32 capitalize the drive-letter in the saveload dialog windows when it is first opened.
2005-10-28 00:09:59 +00:00
Darkvater be984d9bcc (svn r3061) - CodeChange: revert r3056, r3057 and add a simpler fix to satisfy the needs of the absolute strict (eg. root directory is C:\ not C:) 2005-10-18 20:18:05 +00:00
Darkvater d4463b4b95 (svn r3057) - (Post)Fix: fix backslash occurence in all cases, also when going to root directory through 'parent directory', and of course don't show parent dir in root. 2005-10-17 22:49:15 +00:00
Darkvater 6bf4e4af3c (svn r3056) - Fix: Problem on Win98 and lower when if you go to the root directory of a drive (eg. C:\) you were stuck there indefinitely and couldn't change any directories or see any files 2005-10-17 22:24:32 +00:00
tron 23ecc82ad3 (svn r3055) Give the savegame/scenarion sort order flags symbolic names 2005-10-17 19:57:00 +00:00
Darkvater a3d40a29fc (svn r3008) [ 1247535 ] Native Support for Win64 (compile&run only) (michi_cc)
Fix warning in graph_gui.c with const problem
2005-10-02 22:39:56 +00:00
tron c2c865e4b9 (svn r2984) Use adequate types, this should aid portability a bit 2005-09-25 09:04:59 +00:00
Darkvater e9401f09a7 (svn r2954) - Force assertion message to be output to a messagebox instead to the console which MinGW32 had the habit of doing. Using undocumented (in mingw) __set_error_mode() function. 2005-09-15 21:59:07 +00:00
tron bdd5d4ebb1 (svn r2864) Code simplification and diff reduction 2005-08-13 21:35:31 +00:00
tron bdff0fa2d2 (svn r2860) Fix some issues in the savegame/scenario list code:
-Fix: Sort the directories when making a scenario list
-Fix: Sort the directories when making a savegame list on Windows
-Fix: On OS/2 show the trailing \ if the current directory is a root directory
-Regression: On OS/2 the savegame list showed the scenario directory or crashed (probably introduced in r2609)
The rest is diff reduction between the 3 variants
2005-08-12 06:37:48 +00:00
tron 4696ef802a (svn r2809) Implement more generic threading functions, which allow more than one thread 2005-08-05 09:15:41 +00:00
tron a86e9689df (svn r2807) Fix two major bugs in the threaded save code:
- Do not dereference a local variable which no longer exists; this lead to random crashes when saving
- (Win32) Do not close a handle before it is used last
There are still many major problems (race conditions and resulting memory corruption/crashes) left
2005-08-05 08:24:12 +00:00
tron fc5e2d4861 (svn r2775) Deleting a file can fail, display an error message when it happens 2005-08-01 00:14:22 +00:00
tron 2ff85cdc56 (svn r2729) Fix #include 2005-07-27 20:08:52 +00:00
tron 5821529859 (svn r2728) -Fix/Feature: Change the driver probing algorithm
Instead of trying to start a single driver and bailing out if that fails, try to initialise one by one and use the first one which succeeds.
This should fix problems on machines with no sound card, where -s null had to be specified manually.
2005-07-27 19:57:12 +00:00