Commit Graph

37 Commits

Author SHA1 Message Date
peter1138 4591fb5b0d (svn r9806) -Codechange: [NewGRF] Add callback 36 support for purchase cost, for all vehicle types. 2007-05-07 13:26:10 +00:00
rubidium abbaa1691e (svn r9794) -Codechange: refactor the question whether a vehicle can be loaded into LoadUnloadVehicle instead of duplicating it for each vehicle. 2007-05-06 14:59:01 +00:00
rubidium 981bf52bdd (svn r9770) -Codechange: perform the payment of cargo when loading/unloading, but when arriving at the station. 2007-05-02 18:29:11 +00:00
rubidium a4e045a3fb (svn r9760) -Codechange: remove the need for saving some vehicle variables. 2007-05-01 16:35:14 +00:00
rubidium ec9ac99d01 (svn r9755) -Codechange: refactor some more of the begin loading stuff. 2007-04-29 22:33:51 +00:00
rubidium 202009522c (svn r9754) -Codechange: make classes for all vehicle types, so we can make nicer/better maintainable code, i.e. virtual methods instead of switches. 2007-04-29 21:24:08 +00:00
rubidium 6440440f12 (svn r9752) -Codechange: remove some duplication related to BeginLoading. 2007-04-29 18:21:24 +00:00
maedhros 02e770ff2c (svn r9742) -Fix (r9689) [FS#739]: Fix cloning with refit costs again, hopefully for good this time. 2007-04-29 08:43:00 +00:00
maedhros 034f3591cf (svn r9685) -Fix (r9683): Call v->LeaveStation() when a vehicle in a station is sent to a depot. 2007-04-20 11:39:01 +00:00
rubidium 80c259f64f (svn r9672) -Cleanup: lots of coding style fixes around operands. 2007-04-18 22:10:36 +00:00
peter1138 41cf2fa69b (svn r9671) -Codechange: Implement NewGRF callback 36, which allows changing of various properties which were previously static. Vehicle max speed and train power/te/running costs are adjustable. 2007-04-18 18:37:40 +00:00
maedhros ccaaa7d33a (svn r9609) -Codechange: Move some function prototypes out of functions.h and into landscape.h, and add a few where they didn't exist. 2007-04-12 13:07:15 +00:00
belugas dfe5533db6 (svn r9556) -Documentation: doxygen and comment-style changes. 'R', 'S'.. The end of the preliminary work is near 2007-04-04 01:35:16 +00:00
maedhros eae03e0f72 (svn r9543) -Fix [FS#691]: Split up STR_ENGINE_NOT_BUILDABLE into four strings so it can be
translated properly and remove "buildable", since it isn't actually a word.
2007-04-02 11:35:08 +00:00
belugas 06d3669bb5 (svn r9400) -Codechange: Use some more representative enum names for landscape types. 2007-03-22 03:42:43 +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 24c4d5b06d (svn r9051) -Codechange: typedef [enum|struct] Y {} X; -> [enum|struct] X {}; 2007-03-07 12:11:48 +00:00
rubidium 36bb92ae24 (svn r9050) -Codechange: Foo(void) -> Foo() 2007-03-07 11:47:46 +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
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
tron 696b895b77 (svn r8896) -Fix
Most (i.e. 13 of 15) callers of GetNewVehiclePos() do not care for the return and the others can figure it out by inspecting the information returned in struct GetNewVehiclePosResult.
Therefore remove the return value.
2007-02-25 10:25:25 +00:00
rubidium d1d1d170f3 (svn r8703) -Codechange/cleanup: some magic numbers -> enums and other small coding style changes to the ShipController and TrainController. 2007-02-13 11:29:20 +00:00
rubidium 4ec7eb2201 (svn r8701) -Codechange: replace magic numbers with enums for u.rail.track. 2007-02-13 10:46:45 +00:00
rubidium a419f4aeda (svn r8698) -Codechange: enumify the returns of VehicleEnterTile 2007-02-13 10:26:53 +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
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 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
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
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
KUDr dbe11fb9c7 (svn r8052) - Codechange: RemoveFirstTrack() and RemoveFirstTrackdir() now accept pointer to TrackBits/TrackdirBits instead of reference. 2007-01-11 10:34:42 +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
KUDr e373ea7096 (svn r8033) [cpp] - Prepare for merge from branches/cpp (all .c files renamed to .cpp) 2007-01-10 18:12:09 +00:00
Renamed from src/ship_cmd.c (Browse further)