summaryrefslogtreecommitdiff
path: root/src/vehicle.h
AgeCommit message (Collapse)Author
2007-02-06(svn r8610) -Codechange/Feature: rewrote the list handling in the ↵bjarni
autoreplace window -The user will notice the following changes: All vehicle types behaves in the same way Adding/removing an engine (new design and so on) can no longer result in the window selecting a new engine All valid replacements will be displayed since it looks at refitting options as well (this solves the missing ships with the newships GRF) Since you can't replace an engine into itself, the engine selected in the left list will no longer appear in the right list -The code changes: Instead of looping all engines all the time, each list generates a list like the build windows This ensures consistent list generation since only one function can loop all engines Unified code for all vehicle types It now use the lists to call the drawing code in the build vehicle window Works on selected EngineIDs instead of selected index in the list
2007-02-05(svn r8593) -Fix (FS#564): bridges do not get destroyed when the bridge head ↵rubidium
gets flooded and there is a vehicle on the bridge. Original patch by KeeperofTheSoul.
2007-01-31(svn r8501) -Fix (r7377) [FS#539]: Keep track of how much cargo has been ↵maedhros
paid for, so that cargo cannot be paid for more than once.
2007-01-28(svn r8448) -Codechange/Fix (r2993): Also update the helicopter's rotor when ↵Darkvater
loading the game. This can solve crashes when a game is loaded with missing GRF's
2007-01-27(svn r8428) -Codechange: Add proper names to aircraft subtypes instead of ↵Darkvater
magic numbers and add a function IsNormalAircraft() which tells us whether the aircraft is in fact some flying device or a rotor/shadow.
2007-01-22(svn r8349) -Codechange: replaced CMD_REFIT_VEH() and similar defines with ↵bjarni
real static inline functions
2007-01-22(svn r8341) -Codechange (r8336): added assert to VehTypeToIndex() to ensure ↵bjarni
valid vehicle types in the argument
2007-01-22(svn r8336) -Codechange: added function to translate vehicle types to ↵bjarni
0,1,2... for use for index to arrays Used this function to get rid of some switch-cases in build_vehicle_gui.cpp -Fix (r8335): ship build window didn't remember assending/decending sort setting
2007-01-21(svn r8327) -Codechange: though overloading, IsPlayerBuildableVehicleType() ↵bjarni
now works with the type given as a byte as well as a vehicle pointer
2007-01-21(svn r8296) -Fix: GenerateVehicleSortList() tried to put a TileIndex into an ↵bjarni
uint16 -Fix: CmdMassStartStopVehicle() tried to put a TileIndex into an uint16 Those two bugs were unrelated to each other and unrelated to r8295, even though that commit touched the code in question
2007-01-21(svn r8295) -Cleanup: merged arguments station, order and ↵bjarni
depot_airport_index for GenerateVehicleSortList() and BuildVehicleList() into one uint16 argument It turned out that all 3 arguments were the same at all the places those functions are called, so there was no point in having more than one
2007-01-21(svn r8294) -Fix: deleting a vehicle with shared orders, but no orders would ↵bjarni
fail to reset prev_shared and next_shared -As a result, vehicles in the game could end up having prev/next pointers to vehicles, that was no longer in the game
2007-01-15(svn r8144) -Fix: [FS#163] When a station is removed, vehicles do not get ↵celestar
excessive payment any longer, as the origin TILE is now stored as long as the origin STATION for the transported cargos. Basically this is only a temporary fix until cargopackets are implemented, but it fixes one of the oldest known bugs (Special Thanks to Darkvater for lots of testing)
2007-01-14(svn r8128) -Codechange: Split sprite and palette remap into separate 32 bit ↵peter1138
values. This lets us increase the sprite width from 14 to up to 29 bits, effectively nulling the old sprite limit. Table changes in next commit.
2007-01-13(svn r8110) -Codechange: direct Vehicle::current_order.type changes (to ↵KUDr
OT_LOADING and OT_LEAVESTATION) replaced by v->BeginLoading() and v->LeaveStation() calls. This should allow easy hooking of those state transitions in order to maintain vehicle loading queue.
2007-01-10(svn r8038) -Merge: the cpp branch. Effort of KUDr, Celestar, glx, Smoovius, ↵rubidium
stillunknown and pv2b.
2007-01-09(svn r8007) -Codechange: Change _vehicle_position_hash from VehicleID to ↵peter1138
Vehicle*. This removes the need for look ups by index. Also declare the array static.
2007-01-02(svn r7759) -Merge: makefile rewrite. This merge features:rubidium
- A proper ./configure, so everything needs to be configured only once, not for every make. - Usage of makedepend when available. This greatly reduces the time needed for generating the dependencies. - A generator for all project files. There is a single file with sources, which is used to generate Makefiles and the project files for MSVC. - Proper support for OSX universal binaries. - Object files for non-MSVC compiles are also placed in separate directories, making is faster to switch between debug and release compiles and it does not touch the directory with the source files. - Functionality to make a bundle of all needed files for for example a nightly or distribution of a binary with all needed GRFs and language files. Note: as this merge moves almost all files, it is recommended to make a backup of your working copy before updating your working copy.