Commit Graph

34 Commits (ba60e4ac3428f20f74e635ea9ac1f729e1aa16a9)

Author SHA1 Message Date
Darkvater b2110cbaed (svn r6780) -Codechange: Remove GPMI leftovers (-b impersonisation of AI in MP). 18 years ago
Darkvater 80814dbb1d (svn r6406) -Codechange: Rename TileOffsByDir to TileOffsByDiagDir because it accepts
DiagDirections, and add TileOffsByDir that handles Directions.
-Codechange: Make the treeloop use TileOffsByDir().
18 years ago
tron 1c21c645ae (svn r6353) -Codechange: Make DestinationID a typedef of uin16, which is as large as any type of destinataion (StationID, DepotID, WaypointID) it can hold
DestinationID being a union of these types is just hassle without benefit and cannot be handled correctly everywhere because of local lack of information
18 years ago
truelight db8dfcd6e9 (svn r6142) -Codechange: added WaypointID (sorry DV, couldn't splits it anymore)
-Codechange: introduced DestinationID, which is in fact an union of several types
  Used in Order struct, so no longer StationID is abused for all targets.
  Hangars are a big exception, as they use a station-id with GOTO_DEPOT (go figure)
18 years ago
truelight 5fd9aeb12b (svn r6055) -Codechange: added GetXXXArraySize, which returns HighestID + 1 (or, will do that).
It isn't the best name, but we couldn't find any better.
  This unifies the pool-system even more.
18 years ago
truelight 0461d89612 (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 243872b4fd (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
tron 2b27073156 (svn r5391) Miscellaneous, mostly bracing and whitespace, nothing spectacular 18 years ago
tron 0a72639c2d (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
tron 479317b1eb (svn r5098) Do some manual CSE and replace a few magic numbers to improve the readability of the trolly AI 18 years ago
tron a87004e453 (svn r5097) -Fix: The trolly AI used information from the wrong industry when calculating the amount of to be transported goods 18 years ago
tron 877c7e34a5 (svn r5092) -Fix: There was a gross race condition in the AI code which made it pretty random if the AI could give a new vehicle its orders 18 years ago
tron 7dff47b7f0 (svn r5091) Remove duplicate code (same check twice) 18 years ago
tron 5783d57ec0 (svn r4941) Replace some ints and magic numbers by proper types and enums 18 years ago
rubidium e5bd292dab (svn r4789) - Codechange: rename RoadType to RoadTileType and ROAD_{NORMAL,CROSSING,DEPOT} to ROAD_TILE_* for consistency 18 years ago
tron 8ef2c13c65 (svn r4553) int and magic numbers -> Slope and DiagDirection 18 years ago
celestar 22f82bba2e (svn r4463) -Codechange. Include vehicle.h directly instead of implicitly via station.h in a number of source files 18 years ago
celestar 446493149c (svn r4215) -Codechange: Renamed *RoadStation* functions to *RoadStop* and moved them to station_map.h to keep consistency 19 years ago
Darkvater d5909f901a (svn r4128) - CodeChange: Add proper semantics for CargoID for such variables instead of using the general byte-type. 19 years ago
tron cda8934a55 (svn r4120) Use the new station functions where appropriate 19 years ago
tron 9be713f1ae (svn r4079) Add GetSation{Index,ByTile}() to get the station index resp. the station from a tile 19 years ago
tron 929fae7b68 (svn r3816) Use existing accessors 19 years ago
tron fbe939b31f (svn r3783) Replace further ints and magic numbers by Direction, DiagDirection and friends 19 years ago
tron 2d3c28f2b3 (svn r3776) Replace many ints and magic numbers by Direction, DiagDirection and friends 19 years ago
tron cc4f5b4e6f (svn r3763) Adapt to the new 'map accessors go in foo_map.h'-scheme 19 years ago
tron 6a74cb2787 (svn r3660) Convert further road bits and type references to the functions/enums 19 years ago
tron 4b46883751 (svn r3644) Don't use FindLandscapeHeightByTile() when it's overkill - often it was just a complicated way of writing GetTileSlope(tile, NULL) 19 years ago
Darkvater 56998926e7 (svn r3294) - Fix: use INVALID_STRING_ID instead of -1.
- Fix: savegames only give back one message, show this by ignoring the first argument. Perhaps make the message more verbose in the future by adding STR_ equivalents next to the already existing debug messages.
19 years ago
peter1138 809b03c81a (svn r3282) - Codechange: Replace tests against CMD_ERROR with CmdFailed() 19 years ago
truelight 6a4ba84320 (svn r3226) -Fix: GPMI implementation had minor glitches
-Fix: the AI speed control is done by the AI-core, individual AIs don't have to do it (so, AIs were delayed twice ;)
-Add: Support for AI-network-clients (an AI, connecting to a remote server)
-Fix: minor AI-core problems
19 years ago
truelight 31f218fdf9 (svn r3224) -Add: Allow the NewAI to work in Multiplayer Games (switchable via patch
settings, off by defaut). An other step to AIScripts.
      WARNING: this is still highly experimental and has known bugs!
19 years ago
tron 833032adc0 (svn r3177) GB, CLRBIT, HASBIT, TOGGLEBIT 19 years ago
tron 47137cefb7 (svn r3078) Some more stuff, which piled up:
- const, whitespace, indentation, bracing, GB/SB, pointless casts
- use the trinary operator where appropriate
- data types (uint[] -> AcceptedCargo, ...)
- if cascade -> switch
- if (ptr) -> if (ptr != NULL)
- DeMorgan's Law
- Fix some comments
- 0 -> '\0', change magic numbers to symbolic constants
19 years ago
truelight d05f504c01 (svn r2907) -Codechange: splitted the AIs to their own directory. AINew becomes 'trolly', AIOld becomes 'default', both in their own dir in the 'ai' dir. More AIs to come. 19 years ago