Commit Graph

448 Commits

Author SHA1 Message Date
peter1138 1bea18b440 (svn r9352) -Codechange: Use cargo class to determine if an aircraft should carry mail 2007-03-19 20:54:13 +00:00
peter1138 457930c483 (svn r9322) -Codechange: Use cargo class to count crash/flood victims 2007-03-19 12:40:51 +00:00
richk f44cbfe1fe (svn r9299) -Fix (FS#675,FS#660): Small micro-movements on airports (of <4 pixels) caused odd aircraft movements. On oilrigs, this caused a full crash as movement would take helicopter out of airport/station tile.
Corrected by maneuvering aircraft directly over these tiny movements, rather than relying on movement by changing facing.
2007-03-18 21:44:00 +00:00
peter1138 92486ac980 (svn r9259) -Codechange: NUM_CARGO isn't a valid cargo type... 2007-03-16 21:42:11 +00:00
bjarni c2b7d0192d (svn r9072) -Codechange: [Orders] added methods to orders to free them and check if they are in use 2007-03-08 21:39:34 +00:00
rubidium ce919e8c71 (svn r9068) -Codechange: capitalize the VEH_Train etc. enums to match the coding style (and rest of the code). 2007-03-08 16:27:54 +00:00
rubidium 36bb92ae24 (svn r9050) -Codechange: Foo(void) -> Foo() 2007-03-07 11:47:46 +00:00
bjarni f61f1962c5 (svn r9040) -Codechange: the build window and CmdBuildAircraft() now shares the code to figure out if an aircraft is buildable in the hangar in question
This should help ensuring that the build command and the list are consistent in what aircraft are buildable
2007-03-06 22:11:58 +00:00
celestar f621608f7d (svn r8973) -Feature/Codechange: Changed the internal unit for aircraft velocities to from 8mph to 1km/h (peter1138), also give aircraft realsitic velocities (so that 1km/h is 1km/h independent of vehicle type) (peter1138). Introduce a flag to reduce aircraft speed in holding patterns to some realistic velocity. Use this flag for the city airport for the time being and make use of the different entry points for this airport type. 2007-03-02 12:01:24 +00:00
maedhros 469fbc912c (svn r8946) -Feature: [NewGRF] Add support for vehicle variables 0xFE and 0xFF bit 10,
which is set when a vehicle was built during the exclusive testing phase.
2007-02-28 17:59:05 +00:00
maedhros aadd8a4b44 (svn r8945) -Codechange: Rename v->load_status to v->vehicle_flags so it can be used for more than just the gradual loading status. 2007-02-28 17:18:36 +00:00
rubidium 8877ef7478 (svn r8921) -Fix (FS#654): several issues related to removing all orders from an aircraft and removing the airport it was heading:
- the aircraft would go to (0, 0) and circle there. Clicking the 'eye' to jump to the aircraft in the main window could cause a segmentation fault.
 - when rebuilding an airport with the StationID of the old airport could crash as the FTA state of the aircraft is higher than the number of states of the new airport, causing a crash of all clients and the server when assertions are enabled.
 - when rebuilding an airport with the StationID of the old airport can bring the aircraft in a state where is keeps circling the airport.
To solve these issues all aircraft without a valid order will try to go to the nearest hangar it can safely get to (large jets do not land on small airports). If there is no hangar to go to, the airplane crashes (out of fuel).
2007-02-27 16:18:31 +00:00
tron 1ce43c1a37 (svn r8897) -Fix
Change the signature of GetNewVehiclePos():
-void GetNewVehiclePos(const Vehicle *v, GetNewVehiclePosResult *gp);
+GetNewVehiclePosResult GetNewVehiclePos(const Vehicle *v);
2007-02-25 10:49:13 +00:00
belugas 6d199fcdb7 (svn r8859) -Cleanup: doxygen changes. Mostly @files missing tags and a few comments style. 2007-02-23 11:50:43 +00:00
belugas a723770836 (svn r8853) -Cleanup: doxygen changes. Correct forgotten c files to cpp files with the @file tag as well as a few general comments style 2007-02-23 01:48:53 +00:00
tron 0b536291e2 (svn r8835) -Fix
Remove dead code
2007-02-21 20:05:05 +00:00
tron b3d93e3aa2 (svn r8834) -Fix
Do not pass something to a function it better could figure out by itself
2007-02-21 19:49:18 +00:00
tron 41d526415c (svn r8822) -Fix
Variable scope, const
2007-02-20 06:39:09 +00:00
tron cf5949f59d (svn r8763) -Fix
Don't do bogus initialisations and prefer simpler code
2007-02-16 20:03:17 +00:00
celestar a8e88ae7cc (svn r8759) -Feature: Allow airports to have up to 4 entry points depending on approach direction. Note: they're not yet used, but will be soon 2007-02-16 12:10:19 +00:00
tron 87e03c7aa8 (svn r8755) -Fix
Abbreviate GetAirport(st->airport_type) to st->Airport()
2007-02-16 09:38:43 +00:00
KUDr 72cdfb6352 (svn r8750) -Fix (r8747): PLANES defined in wingdi.h caused compilation error under Win32. Changed to AIRPLANES 2007-02-15 22:00:04 +00:00
tron 0697701b33 (svn r8748) -Fix
-Codechange: Do not hardcode the airports with a short airstrip anymore, but make it a flag in AirportFTAClass
2007-02-15 20:35:45 +00:00
tron 5231f5669d (svn r8747) -Fix
-Codechange: Make the encoding of accepted aircraft types of airports a bit more sensible and move the enum into struct AirportFTAClass
2007-02-15 20:16:33 +00:00
tron f6b917f609 (svn r8743) -Fix
-Codechange: Add a Z adjustment attribute for helicopter pads to AirportFTAClass to get rid of some special cases for oilrigs and heliports
2007-02-15 07:43:06 +00:00
celestar 39b73119ca (svn r8733) -Fix(r8705): Forgot to change some more places where airport blocks are stored 2007-02-14 12:00:43 +00:00
celestar 8eab3964b4 (svn r8707) -Codechange: Turn IsValidStation into a method of Station 2007-02-13 15:42:52 +00:00
bjarni 0c8078ae29 (svn r8661) -Fix: [depot windows] Enlarge the blocks in the depot window if a sprite is too big to fit (ships and aircraft only)
-Codechange: depot windows default now makes a 1x1 matrix and resize the window by block size*number of blocks
   This will make less vehicle type specific code and easier to read resizing based on sprite sizes
2007-02-10 13:37:32 +00:00
tron eab0379264 (svn r8618) -Fix
Remove redundant assignments. The function call just before already does it
2007-02-07 13:46:28 +00:00
tron 9ad50fff33 (svn r8617) -Fix
Fix harmless typo: s/,/;/
2007-02-07 08:36:53 +00:00
celestar 3dc645ce0a (svn r8611) -Fix: Moved the aircraft speed limiting into UpdateAircraftSpeed and enummed some speed limits. This should give a more steady display in the status bar during taxiing 2007-02-06 15:38:23 +00:00
bjarni 80125fd934 (svn r8610) -Codechange/Feature: rewrote the list handling in the 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-06 11:11:12 +00:00
tron 1a3b4b7394 (svn r8559) -Fix
-Codechange: Put the airport movement data into struct AirportFTAClass
2007-02-03 13:03:11 +00:00
tron c326ff3795 (svn r8550) -Fix
Building a vehicle does not involve allocating orders, so do not check whether orders could be allocated
2007-02-03 09:05:43 +00:00
tron 981833751a (svn r8549) -Fix
Do not check whether the end of the depot array has been reached when building an aircraft. This cannot happen, just assert it really does not happen
2007-02-03 08:30:22 +00:00
tron c3d971c855 (svn r8548) -Fix
Remove redundant second retrieval of the AircraftVehicleInfo when building an aircraft
2007-02-03 07:54:13 +00:00
tron feab2ace94 (svn r8547) -Fix
Remove redundant second retrieval of the station and airport when building an aircraft
2007-02-03 07:47:00 +00:00
celestar 6f01ba5ad9 (svn r8534) -Feature/Codechange: Provide aircraft with vertical separation depending on their altitude and velocity 2007-02-02 15:04:59 +00:00
tron ce12ae7420 (svn r8498) -Fix
-Codechange: Move the update of the oil rig airport type to the recently (r8485) added loop
2007-01-31 21:38:09 +00:00
peter1138 60ddc05925 (svn r8434) -Fix (r8430): Missing braces caused compilation failure for some (most?) compilers... 2007-01-27 22:28:28 +00:00
tron 430e64c848 (svn r8430) -Fix
Replace the rather obscure control flow for handling aircraft/ship/train orders by something remotly comprehensible (see r3584)
2007-01-27 16:45:16 +00:00
Darkvater 50ca901b40 (svn r8428) -Codechange: Add proper names to aircraft subtypes instead of 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-27 12:29:55 +00:00
truelight bb8f3a1dff (svn r8305) -Codechange: defining 'static const' in a header is a bit weird.
Above that, wince-gcc gave "unused variable" on every file which included airport.h... pretty annoying ;)
2007-01-21 14:15:38 +00:00
peter1138 92d418b031 (svn r8128) -Codechange: Split sprite and palette remap into separate 32 bit 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-14 19:57:49 +00:00
KUDr 9bfb3f08d9 (svn r8110) -Codechange: direct Vehicle::current_order.type changes (to 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-13 18:55:54 +00:00
celestar 2ac0410767 (svn r8055) -Codechange: Replace the different max, dmax, maxu whatever macros by a simple template function max(), that requires two arguments of the same type. While I'm at it change a variable called "max" to "maxval" in a function that calls max(). 2007-01-11 11:05:01 +00:00
rubidium f35ed4bbc2 (svn r8038) -Merge: the cpp branch. Effort of KUDr, Celestar, glx, Smoovius, stillunknown and pv2b. 2007-01-10 18:56:51 +00:00
rubidium 344f70e1af (svn r8034) -Fix (r8033): aircraft_cmd.c was not renamed. 2007-01-10 18:24:48 +00:00
Renamed from src/aircraft_cmd.c (Browse further)