Commit Graph

89 Commits (5a86b502c2f553096f88d7f84241e0f3e581fcb2)

Author SHA1 Message Date
truelight f16d3f2b8b (svn r6050) -Codechange: mass-renamed SignStruct -> Sign and ss -> si. Now functions and variables all match eachother 18 years ago
truelight 505566da5c (svn r6047) -Codechange: FOR_ALL now _only_ loops valid items, and skips invalid ones
-Codechange: use IsValidXXX where ever possible
  Note: both changes to prepare for new pool system, which needs those changes.
  For every pool there are 2 ugly lines, which will be removed when done
  implementing new pool system.
  Based on FS#13 by blathijs, partly implemented.
18 years ago
rubidium 6fb092aa7a (svn r5999) -Feature: change the original date format to a 32 bits format based at the year 0.
The game date subsystem now allows someone to start in the year 0 and continue
up to the year 5 000 000. However, you currently cannot build anything before 
1920 as there is no newgrf support for dates before 1920 or after 2090 yet.
18 years ago
truelight 73cd71db04 (svn r5974) -Codechange: added casts all around the place to make Windows 64bit happy (michi_cc) 18 years ago
rubidium c55962f8a2 (svn r5916) -Cleanup: use MIN_YEAR/MAX_YEAR for the year boundaries and BASE_YEAR when comparing _cur_year with a 'full' year.
-Cleanup: replace some magic '1920' values with BASE_YEAR.
18 years ago
rubidium 9fc837ad85 (svn r5887) -Cleanup: move date related functions, defines and variables to date.[ch]
-Cleanup: fix whitespace related coding style issues in date.[ch]
-Cleanup: make original comments doxygen compatible and remove/change outdated comments
18 years ago
Darkvater bd458586a0 (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. 18 years ago
tron a2362674e3 (svn r5210) Many small changes which piled up: const, unsigned, variable scope, CSE for readability, DeMorgan, if cascades -> switch, whitespace, parentheses, bracing, misc. 18 years ago
peter1138 d955b49e1b (svn r4917) - NewGRF: remove _custom_sprites_base, now used only to rejig vehicle images from ttd games, as we redetermine all vehicle images after game load anyway. 18 years ago
rubidium 3dae1a9bba (svn r4788) - Codechange: RAILTYPE_{NORMAL,ELECTRIC,...} and RAIL_TYPE_{NORMAL,SIGNAL,...} have nearly the same name, rename RAIL_TYPE_* to RAIL_TILE_* of extra clarity 18 years ago
Darkvater 0a0b8f22aa (svn r4529) - Codechange: Use proper naming for hex numbers in debug prints eg. 0xF3A6. Use fixed lengths where applicable (newgrf). Unfortunately '%#X' is unusable since it gives 0XFF3 and '%#x' gives 0xff3 while we want 0xFF3 :P 18 years ago
Darkvater 3d409cc986 (svn r4528) - Fix: fix idiotic gcc warning 18 years ago
Darkvater f144f1dc8d (svn r4526) - CodeChange: do some more cleanup, mainly changing the OldChunkTypes from full bitmasks into segmented values like in SaveLoad. 18 years ago
Darkvater 645990bf86 (svn r4525) - Codechange: Do a little cleanup; also fix a typo while here: _old_vehicle_multipler should be _old_vehicle_multiplier 18 years ago
celestar 277f8cbda2 (svn r4466) -Fix: (FS#71) Game no longer crashes when the last vehicle serving a station has been deleted.
-Negative side effect: upon loading old games, stations whose last vehicle was a station have (temporarily) lower ratings.
   -Positive side effect: station.h no longer includes vehicle.h (breaks the station.h->vehicle.h->rail.h chain)
18 years ago
tron 613104ba00 (svn r4432) Make use of map access functions 18 years ago
celestar 8cbe98a3fd (svn r4259) -[multistop] Fix/Feature/Codechange:
1) Improved the road vehicle allocation (aka slotting) for multistop. Stops can now accept unlimited, er... 256, vehicles.
2) Removed the "wait for stop" feature, because it did not work in practise.
3) Slotting now ignores unreachable stations. Uses NPF at the moment because the old pathfinder cannot do it (yet)
4) Now matter how many vehicles approach a station, they will always be distributed evenly over existing stops.
5) Hopefully the last fundamental change to multistop
19 years ago
Darkvater 921a4d8a13 (svn r4129) - CodeChange: Add proper bool type for is_ai as well...it is a bool type. 19 years ago
peter1138 67bc818bbe (svn r4126) - Feature: A new multi-lingual multi-measuring-unit system:
- Replace miles/kilometres game option with a general measuring units option.
  - Add {POWER}, {WEIGHT}, {WEIGHT_S} and {VOLUME_S} (_S for short) tags to the language/string system.
  - Add SI as option for measuring units.
  Language file updates to use the system will come soon.
19 years ago
tron a90e46bf03 (svn r3981) More work for the rail accessing functions and enums 19 years ago
celestar 480ea7c671 (svn r3939) -Fix: No longer assume that the number of slots is 2. It was not a problem up to now, but it's not The Right Thing (TM) to do either 19 years ago
peter1138 fca5823238 (svn r3805) - [FS#62] Fix doxygen comments to refer to the correct parameter. (sulai) 19 years ago
tron 7692556c62 (svn r3613) Some more const, indentation, whitespace and similar stuff 19 years ago
peter1138 95ce125633 (svn r3612) - RoadStop->slot[] stores a vehicle index. Adjust its type and use INVALID_VEHICLE instead of nonsense INVALID_SLOT. 19 years ago
peter1138 30429dc4fb (svn r3589) - Rename u.road.unk2 to u.road.blocked_ctr 19 years ago
tron 9712d6f639 (svn r3510) Fiddle with whitespace and parentheses 19 years ago
Darkvater 4014e36aec (svn r3472) - [PBS] Remove from trunk. Anyone interested can still find it in branch/pbs. This reverts revisions r3158, r3140, r3075, r2977, r2674, r2625, r2621, r2529, r2528, r2525, r2524, r2519, r2517, r2516, r2507, r2499. (in conjunction with Tron)
- The only change is that the nsignalsw.grf file is kept and that existing nightlies with PBS signals get those signals converted to combo-signals.
19 years ago
peter1138 28668bc30b (svn r3362) Fix issue with loading old (TTD) savegames:
- move call to convert from old to new train subtypes.
 - ensure AI is started for AI players.
19 years ago
tron 9822b4d755 (svn r3297) Staticise 19 years ago
tron ef7fb8b515 (svn r3205) Some more uses for GB/SB 19 years ago
tron 8980891b09 (svn r3024) -Codechange: Another batch of replacements of int/uint/int16/byte/-1 with proper types and constants 19 years ago
tron 6ba9c65fc6 (svn r2979) Avoid unnecessary recursion 19 years ago
tron acbccd03ff (svn r2978) Make a global variable local 19 years ago
tron 8b74a95d36 (svn r2886) Rename the "owner" attribute to "m1", because when it stores an owner it is accessed by [GS]etOwner anyway and when it doesn't store an owner, but arbitrary data, accessing a field called "owner" is confusing. 19 years ago
tron 647cbd6bdd (svn r2701) Insert Id tags into all source files 19 years ago
tron 54cbd01825 (svn r2673) Include functions.h directly, not globally via openttd.h 19 years ago
celestar 7bce410f61 (svn r2657) -Codechange: The available railtypes per player are now a bitmask, so
that railtypes do not be in ascending order of appearance. Allows easier
implementation or more railtypes
19 years ago
tron f09638ad3d (svn r2650) Convert many explicit shifts+ands to extract bits to invocations of GB - should be a bit nicer to read 19 years ago
Darkvater cda6efd919 (svn r2609) - Feature: remove extension from savegames/scenarios when browsing the folders. 19 years ago
ludde f868fb0811 (svn r2600) Fix: [vehicles] Fix problem with vehicle loop not distributing the calls evenly over the day. 19 years ago
tron a4bf608d40 (svn r2558) Change the internal map format from 7 arrays to one array of structs, this doesn't change the saved format for now. It's a stepping stone for further changes. 19 years ago
Darkvater 4ae02ddbad (svn r2528) - Fix: TTDPatch games had garbage in _map3[hi]&0xF0 which interfered with OpenTTD PBS functionality; fixed in oldloader
- Fix: TTD AI internals are still a puzzle and the AI in state 'SellVehicle' doesn't have a valid vehicle, so change the state to something harmless. Both fixed make sure that Megarail TTD scenario works
19 years ago
celestar 354058341b (svn r2468) -Codechange: Got rid of DEREF_PLAYER and replaced it by GetPlayer 19 years ago
tron d2364f1d51 (svn r2432) Use GetEngine() instead of DEREF_ENGINE() or even _engines[] 19 years ago
Darkvater ba8c649fac (svn r2397) - CodeChange: rename all "ttd" files to "openttd" files. 19 years ago
truelight 49d69f6fa3 (svn r2041) -Fix: not all vehicles did get a day_proc call (because of rounding errors) 20 years ago
tron 5cb74cb049 (svn r1900) Simplify a piece of code in the oldloader 20 years ago
truelight 034dac2c85 (svn r1844) -Fix: small protection in oldloader.c, and put the savegame on pause by default 20 years ago
tron 6984d6cd31 (svn r1832) Next byte -> char iteration: custom names 20 years ago
truelight 29faa0095a (svn r1830) -Codechange: small stuff to make the file more beautiful (tnx Tron) 20 years ago