Commit Graph

19 Commits (71642d464bdd28ffc07eca9293043fa45f0fa659)

Author SHA1 Message Date
peter1138 35e9ca52aa (svn r7074) -Fix (r7073): stupid debugs 18 years ago
peter1138 a387b09fc9 (svn r7073) -Feature: Add cargo refit support to both AIs for road vehicles 18 years ago
peter1138 6f1550b652 (svn r7072) -Fix (r7070): Go up, not down, through the engines. And replace the comment too... 18 years ago
peter1138 6aa0c247c8 (svn r7070) -Codechange: Make the AI choose road vehicles based on a rating (currently max speed * capacity) instead of either the cost or the index of the vheicle. 18 years ago
peter1138 e10ba5fdc5 (svn r7057) -Codechange: Remove hardcoded lists of road vehicles for each cargo type in favour of just checking the cargo type of each vehicle. 18 years ago
Darkvater 6b44b88e9f (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.
18 years ago
Darkvater 7e4d0f112e (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 772fbda3e3 (svn r5391) Miscellaneous, mostly bracing and whitespace, nothing spectacular 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
tron 36e31fa41f (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 d9e968e759 (svn r4943) uint tile -> TileIndex tile, byte player -> PlayerID player 18 years ago
tron 7ad49df54c (svn r4941) Replace some ints and magic numbers by proper types and enums 18 years ago
celestar c442586676 (svn r4154) -Moved MAX_BRIDGES in bridge.h and made it an enum. This makes two drops ... 19 years ago
tron 8cfcdaa733 (svn r3783) Replace further ints and magic numbers by Direction, DiagDirection and friends 19 years ago
tron 7692556c62 (svn r3613) Some more const, indentation, whitespace and similar stuff 19 years ago
truelight af6fe3949b (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 9d0e7b6458 (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
19 years ago
tron 181d586a7c (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 620f36acb6 (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