Commit Graph

50 Commits (eca73a810c19ed5cfb3f24cb5560d0735e19ea00)

Author SHA1 Message Date
PeterN 3dbd6475fe
Codechange: Use C++ features for train wagon overrides. (#9141)
This removes the need for C-style array management and allows use of iterators to perform wagon override lookups.
3 years ago
TechGeekNZ 16e5f610f7 Cleanup: Correct typographic errors in code comments. 4 years ago
Michael Lutz 63ccb36ef3 Codechange: Use std::string for most of the user-settable custom names. 4 years ago
Jonathan G Rennison 150dfba95b Codechange: Remove std::function from Pool iteration wrapper
Add a separate template wrapper for filtered iteration
4 years ago
glx 1f6b3a37f9 Codechange: Replace FOR_ALL_ENGINES with range-based for loops 5 years ago
S. D. Cloudt 13cc8a0cee Cleanup: Removed SVN headers 5 years ago
Charles Pigott 5b34c8019f Codechange: Remove Company/OwnerByte types 5 years ago
Charles Pigott 69a6c494bf Codechange: Set VehicleType's base type to byte instead of using VehicleTypeByte 5 years ago
Henry Wilson 7c8e7c6b6e Codechange: Use null pointer literal instead of the NULL macro 5 years ago
Henry Wilson c01a2e2a81 Codechange: Removed SmallVector completely 5 years ago
alberth ad88588481 (svn r27797) -Add: Display aircraft type in its vehicle window (patch by Samu) 7 years ago
alberth f72ad87540 (svn r26802) -Add: Command to set visibility of an engine for a company (based on patch by Juanjo). 10 years ago
planetmaker c24374f99c (svn r24900) -Fix [FS#5389]: Comments with typos (most fixes supplied by Eagle_rainbow) 12 years ago
frosch 0e4b212c45 (svn r24810) -Fix: Make engine preview offers more robust wrt. changes in the company ranking. 12 years ago
rubidium e40eb8177a (svn r23735) -Codechange: remove ~50 includes from headers that weren't needed 13 years ago
truebrain 1c9bec1999 (svn r23640) -Fix: stop using FORCEINLINE (1/3rd of the instances were, the others were still regular inline), but make sure inline is always a 'forced' inline (I am looking at you MSVC) 13 years ago
michi_cc def8e7215b (svn r23504) -Feature: Aircraft range. 13 years ago
frosch 0fbad47371 (svn r23176) -Codechange: Deduplicate code between Engine::DetermineCapacity() and Engine::GetDisplayDefaultCapacity(). 13 years ago
frosch 026317bb44 (svn r23173) -Codechange: Rename GetVehicleCapacity() to Engine::DetermineCapacity(). 13 years ago
frosch acc3c75951 (svn r23075) -Codechange: Add GetGRF() and GetGRFID() methods to Engine and Vehicle to simplify code. 13 years ago
alberth bb4d832146 (svn r22239) -Doc: Further engine doxyment additions. 13 years ago
frosch faa2a26ae1 (svn r21986) -Codechange: Add helper function to test whether an engine is still associated to a GRF. 14 years ago
frosch 915e339d0f (svn r21975) -Add: console command to reset the engine pool. It removes the traces of engines which are no longer associated to a NewGRF, and can be used to e.g. 'fix' scenarios which were screwed up by the author. You can only use it when there are no vehicles in the game though. 14 years ago
alberth f65a9a5515 (svn r21593) -Codechange: endif comment correcttions. 14 years ago
terkhen d6959dcc6b (svn r21517) -Codechange: Add IsGroundVehicle function to the Engine class. 14 years ago
rubidium 29b489a055 (svn r20437) -Codechange: lets Engines use GRFFilePropsBase as well 14 years ago
rubidium 82fc28f77f (svn r18809) -Codechange/Cleanup: remove unneeded headers from some files, if a header require a header make it include that header 15 years ago
frosch 67cae40ec1 (svn r17926) -Fix (r9352): Make the decision whether aircraft carry mail consistent. Now always the cargo class decides. 15 years ago
rubidium 7fbc33dae1 (svn r17248) -Fix: add GPL license notice where appropriate 15 years ago
frosch 8bd029015e (svn r17209) -Codechange: Move cargo_type from (Rail|Road|Ship)VehicleInfo to EngineInfo. 15 years ago
rubidium 35aabc1d4c (svn r16586) -Codechange: don't store lifelength in the savegame; it can easily be calculated, it isn't used often and now changing extend_vehicle_life in game has some effect. 15 years ago
rubidium 512b021e26 (svn r16581) -Codechange: unify the access to Engine::lifelength. 15 years ago
rubidium 4b05617c42 (svn r16580) -Codechange: rename Engine::image_index to original_image_index to not confuse it with image_index from *VehInfo. 15 years ago
smatz 56a7b70591 (svn r16380) -Codechange: rename pool.hpp to pool_type.hpp 15 years ago
smatz 62a7948af0 (svn r16378) -Codechange: replace OldPool with simpler Pool. Compilation time, binary size and run time (with asserts disabled) should be improved 15 years ago
smatz 04723b240e (svn r16377) -Codechange: unify FOR_ALL_* macros, use separate index variable instead of var->index 15 years ago
smatz 70aab8bf04 (svn r16354) -Codechange: use 'new' pool accessors and methods for Engine too 15 years ago
smatz ed1e54bd84 (svn r16326) -Codechange: replace GetPoolItemPoolSize() by PoolItem::GetPoolSize() 15 years ago
smatz 6221d74644 (svn r16325) -Codechange: replace GetPoolItem(index) by PoolItem::Get(index) 15 years ago
frosch 6dd04a9a78 (svn r15763) -Codechange/Fix: Add Engine::GetDisplayDefaultCapacity() and use it everywhere, so CB 36 is also used everywhere. 15 years ago
frosch 987e72f4f2 (svn r15645) -Fix (r12924)[FS#2612]: Add an EngineOverrideManager to give the term 'compatible newgrf' again some sense and to not crash because of trivial changes. 15 years ago
frosch d3850e101c (svn r15541) -Revert (r15399): 'v->cargo_type' is also used in other places, which cannot accept CT_INVALID.
-Codechange: Add Engine::GetDefaultCargoType() and Engine::CanCarryCargo() and use them.
-Fix [FS#2617]: When articulated parts have no available default cargo, use the cargo type of the first part for livery selection.
-Change: To decide whether a vehicle is refittable do not test its current capacity for being zero, but always use the 'capacity property'.
  Note: The property is used unmodifed without calling CB 15/36. By setting it to a non-zero value and returning zero in the callback vehicles can be refitted to/from zero capacity for e.g. livery effects.
  Note: It is intentional that you cannot control refittability by CB 36.
16 years ago
rubidium a5f30dd553 (svn r15521) -Codechange: add helper function to get the display tractive effort of a vehicle. 16 years ago
frosch c28c4c1986 (svn r15306) -Codechange: Deduplicate code by adding Engine::GetDisplayMaxSpeed(), GetPower() and GetDisplayWeight(). (and using them) 16 years ago
glx c1cf3934fa (svn r15263) -Codechange: added Engine::GetCost() to remove some code duplication. 16 years ago
glx e8b5f49861 (svn r15261) -Add: added Engine::GetRunningCost() to remove some code duplication. Also stops AIs decrementing vehicle counter of first company 16 years ago
rubidium 3b798599b6 (svn r14421) -Codechange: rename all player variables/types to company *or* client so it is immediatelly clear which one you are working with. 16 years ago
peter1138 7cdd6ef33c (svn r13825) -Revert (r13821 partially): preview_player_rank wasn't a PlayerByte value in r12143, and still isn't a PlayerByte value. 16 years ago
rubidium 1a4ac3ee5c (svn r13821) -Codechange: replace some uint8/bytes with more specificly named typedefs and replace a few magic numbers. 16 years ago
peter1138 a00371c8db (svn r12924) -Feature: Introducing the so called 'engine pool' which primarily removes the fixed engine type limits and also happens to allow (with the patch option 'dynamic_engines') multiple NewGRF vehicle sets to coexist. 16 years ago