rubidium
e78a235293
(svn r13960) -Codechange [YAPP]: Reserve a path when exiting a depot into a PBS block. (michi_cc)
2008-08-02 22:55:52 +00:00
rubidium
0b38276d5a
(svn r13959) -Codechange [YAPP]: Try to extend a train reservation as far as possible and only call into the pathfinder on track choices. (michi_cc)
2008-08-02 22:55:38 +00:00
rubidium
1415b19fad
(svn r13958) -Add [YAPP]: Implement look-ahead for trains so they extend their reservation before reaching the end. (michi_cc)
2008-08-02 22:55:23 +00:00
rubidium
c213ff35e5
(svn r13955) -Codechange [YAPP]: Try to extend the path of a stuck train so it is able to continue. (michi_cc)
2008-08-02 22:54:38 +00:00
rubidium
49967b9077
(svn r13954) -Codechange [YAPP]: On reserving a path that ends at the destination, the path could end at a non-safe tile. In this case, extend the reservation based on the next vehicle orders. (michi_cc)
2008-08-02 22:54:23 +00:00
rubidium
f6bdf23527
(svn r13953) -Add [YAPP]: Free track reservations of crashed trains. (michi_cc)
2008-08-02 22:54:07 +00:00
rubidium
2e2a6d4909
(svn r13952) -Add [YAPP]: Trains now reserve paths trough PBS signals. Bump savegame version. (michi_cc)
2008-08-02 22:53:51 +00:00
rubidium
21e4904eb3
(svn r13951) -Codechange [YAPP]: A train leaving a tile should unreserve the track it came from if it was reserved. (michi_cc)
2008-08-02 22:53:37 +00:00
rubidium
a31e86c778
(svn r13950) -Add [YAPP]: Trains can now also be in a 'stuck' state when waiting on a path reservation. (michi_cc)
2008-08-02 22:53:21 +00:00
rubidium
2b6978e48e
(svn r13912) -Codechange: remove some casts by returning the proper type instead of void*.
2008-08-01 15:07:31 +00:00
smatz
0a67e72df5
(svn r13911) -Fix (r13806): do not consider crashed train as waiting at signal, v->direction doesn't have to match track anyway
2008-08-01 13:25:19 +00:00
peter1138
93c279d6b4
(svn r13870) -Fix [FS#2167]: Callback 10 (visual effect and powered wagons setting) and powered wagons operation were not performed for articulated wagons.
2008-07-29 22:19:37 +00:00
smatz
c4c20c324f
(svn r13817) -Cleanup (r13816): no need to check for ENABLE_NETWORK, _networking is defined anyway
2008-07-24 16:23:55 +00:00
smatz
f1c0555d2e
(svn r13816) -Fix [FS#2150]: check for vehicle length changes outside a depot (callback 0x11) and give a warning about that
2008-07-24 15:19:26 +00:00
smatz
cf4aff4a86
(svn r13806) -Fix [FS#2162]: checking for train waiting at other side of two-way signal was broken
2008-07-23 18:23:12 +00:00
smatz
a47b118a80
(svn r13691) -Codechange: make it easier to determine whether a command is ran in the context of autoreplace or not
2008-07-09 20:55:47 +00:00
peter1138
7d877c0c05
(svn r13507) -Fix (r12856): first engine change should've been moved too
2008-06-13 13:28:55 +00:00
smatz
506cde94b6
(svn r13456) -Codechange: use AllocaM() macro instead of alloca() at most places
2008-06-10 21:59:22 +00:00
glx
b60a1326bf
(svn r13390) -Codechange: introduce usererror() for fatal but not openttd related errors. Now all error() will 'crash' openttd after showing the message in win32 releases (MSVC), creating a crash.log and crash.dmp (like the '!' hack used before). On the other hand, usererror() will just close the game. So use error() only when it can be helpful to debugging, else use usererror().
2008-06-05 20:54:52 +00:00
rubidium
e7a501100a
(svn r13325) -Codechange: split the client-side only settings from the settings stored in the savegame so there is no need to have a duplicate copy of it for new games.
2008-05-29 15:13:28 +00:00
rubidium
d289464d69
(svn r13255) -Codechange: move _opt to _settings.
2008-05-25 22:36:44 +00:00
rubidium
dc77647ea4
(svn r13251) -Codechange: rename _patches to _settings as that is more logic.
...
-Codechange: move all Settings into substructs of _settings in a way that they are logically grouped.
2008-05-25 19:17:03 +00:00
peter1138
42f78d2fc3
(svn r13205) -Codechange: Remove unnecessary code-style-buggering-up macro.
2008-05-21 12:06:05 +00:00
rubidium
3ee2556585
(svn r13165) -Codechange: replace some RebuildXXXList/ResortXXXList+InvalidateWindowXXX with InvalidateWindowXXXData.
2008-05-18 16:51:44 +00:00
rubidium
ad6e52080c
(svn r13140) -Codechange: move the gui-list-sorting out of window_gui.h so window_gui.h only needs to be included in *_gui.cpp.
2008-05-17 13:01:30 +00:00
rubidium
373343cef6
(svn r13100) -Codechange: reduce the amount of parameters passed via AddNewsMessage as there is (for each news message type) a tuple of 4 parameters that is the same for all calls.
2008-05-15 13:39:36 +00:00
smatz
2be223fc03
(svn r13090) -Codechange: add functions for direct conversion from DiagDirection to Track and Trackbits
2008-05-14 18:31:21 +00:00
smatz
9b8d16b7ff
(svn r13088) -Codechange: use SigSegState enum instead of bool variable (michi_cc)
2008-05-14 16:38:53 +00:00
peter1138
839070028e
(svn r13074) -Fix: For multiheaded engines, halve power and running cost when used instead of when loading, to allow callback values to work properly.
2008-05-13 20:39:57 +00:00
rubidium
8796331d83
(svn r12975) -Codechange: replace DeleteWindow(w) with delete w.
2008-05-06 21:28:30 +00:00
rubidium
1ce0b03bf0
(svn r12971) -Documentation: add @file in files that missed them and add something more than whitespace as description of files that don't have a description.
2008-05-06 15:11:33 +00:00
peter1138
45034bc522
(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.
2008-04-29 21:31:29 +00:00
peter1138
6ac8ced9af
(svn r12860) -Fix [FS#1947]: Train depart animation trigger was not called in some cases.
2008-04-24 07:44:21 +00:00
peter1138
7c8fe9791b
(svn r12856) -Fix: Taking r12377 further, ensure that prop 25 is set for all vehicles in the consist before other properties.
2008-04-23 21:55:24 +00:00
peter1138
a05e9b4c6b
(svn r12824) -Codechange: Standardise routines for drawing vehicle images, using correct types and less duplication.
2008-04-21 20:50:58 +00:00
rubidium
e947fde701
(svn r12819) -Codechange: handle more NewGRFs in the same way as TTDP does it, i.e. testing the low bits for 0xFF or 0 instead of all bits.
2008-04-21 14:33:33 +00:00
rubidium
bbe13a0623
(svn r12818) -Codechange: make callbacks 31 and 37 behave like they do in TTDP according to frosch's survey.
2008-04-21 13:45:03 +00:00
rubidium
8186344628
(svn r12804) -Codechange: move the effect vehicle handling out of vehicle.cpp
2008-04-20 11:12:07 +00:00
rubidium
40b19f3997
(svn r12803) -Cleanup: rename SpecialVehicle to EffectVehicle to have a uniform naming of the thing instead of using both names for the same thing.
2008-04-20 10:13:54 +00:00
peter1138
3b7558b89c
(svn r12798) -Feature: Add some support for NewGRF station animation. (Thanks to mart3p for samples and fixes)
2008-04-19 23:19:12 +00:00
rubidium
a63974547b
(svn r12795) -Fix [FS#1938]: vehicles could break down during loading and keep loading. The intention of the break down code is not to break down when having zero speed, therefor break downs now do not happen when loading.
2008-04-19 21:23:42 +00:00
rubidium
ca1f8fbe2e
(svn r12761) -Codechange: lots of minor whitespace coding style fixes around operators.
2008-04-18 04:37:06 +00:00
rubidium
6d063c3ad6
(svn r12754) -Codechange: split depot.h into depot_map.h, depot_func.h and depot_base.h and remove quite a lot of unneeded (before this) includes of depot.h.
2008-04-17 19:10:30 +00:00
smatz
ec588da9e8
(svn r12753) -Codechange: do not use IsDepotTypeTile() where simpler function can be used
2008-04-17 18:24:45 +00:00
smatz
966e476df8
(svn r12745) -Codechange: a bit of naming conventions, introduce Is*DepotTile()
2008-04-17 00:44:20 +00:00
glx
90bd1e45eb
(svn r12711) -Codechange: remove unneeded loops
2008-04-14 20:48:17 +00:00
rubidium
760a57867f
(svn r12698) -Codechange: skip orders to stations that do not have a train part anymore, just like is done for road vehicles and ships.
2008-04-14 07:08:43 +00:00
rubidium
daf5a2f1bc
(svn r12658) -Codechange: unify a vast portion of the CmdSend<VehicleType>ToDepot commands.
2008-04-11 08:40:10 +00:00
rubidium
aa8a5b2c39
(svn r12657) -Codechange: add 'FindClosestDepot' to the vehicle class.
2008-04-11 08:14:43 +00:00
frosch
b91781b715
(svn r12629) -Codechange: Split VehicleNeedsService() into Vehicle::NeedsServicing() and Vehicle::NeedsAutomaticServicing().
...
-Fix (r11052): Disable servicing by service-interval if a vehicle has depot orders.
2008-04-08 15:48:32 +00:00
rubidium
cf250390c5
(svn r12615) -Codechange: rename some enums related to depot orders to make it more clear that they are no loading/unloading flags. Also add more type strictness.
2008-04-07 19:18:56 +00:00
smatz
7dc63836ea
(svn r12605) -Cleanup: variable scope and coding style in train*
2008-04-07 12:36:50 +00:00
rubidium
53d101cc99
(svn r12593) -Codechange: hide Order's flags in most of the code.
2008-04-06 15:09:45 +00:00
rubidium
935b562074
(svn r12588) -Codechange: do not access the destination of an order directly.
2008-04-06 07:48:51 +00:00
rubidium
3b0e3d8d30
(svn r12584) -Codechange: do not access the order type directly.
2008-04-05 23:36:54 +00:00
rubidium
ed2acd6f3d
(svn r12580) -Codechange: merge some logical related to non-stop orders.
2008-04-05 15:30:15 +00:00
rubidium
ba0a9538cf
(svn r12578) -Codechange: merge the aircrafts ProcessOrder too into the 'unified' ProcessOrder.
2008-04-05 12:01:34 +00:00
rubidium
3fdddeac40
(svn r12575) -Codechange: unduplicate Process*Orders for trains, ships and road vehicles.
2008-04-05 10:55:50 +00:00
frosch
2de802567a
(svn r12532) -Cleanup: Replace two tables of magic values with already existing functions.
2008-04-01 14:47:57 +00:00
frosch
51155403a4
(svn r12531) -Codechange: Rename some variables for consistency.
2008-04-01 14:03:20 +00:00
rubidium
df1d9bd880
(svn r12490) -Codechange: rename engine.h to engine_func.h and remove unneeded inclusions of engine.h and/or replace them with engine_type.h.
2008-03-31 00:17:39 +00:00
rubidium
c51b81c247
(svn r12489) -Codechange: split station.h into station_base.h and station_func.h.
2008-03-31 00:06:17 +00:00
rubidium
b84b16cfcd
(svn r12488) -Codechange: split order.h into order_base.h and order_func.h.
2008-03-30 23:24:18 +00:00
bjarni
8837c7dcd5
(svn r12482) -Fix: [build train] we don't need to have a depot in order to just check the price of a rail vehicle so don't check for compatible rails on the tile either
...
also wagons will only need tracks they can drive on in order to be build so there is no reason to check for power in the depot
2008-03-28 22:59:43 +00:00
rubidium
2426f5342f
(svn r12459) -Codechange: split news.h into news_type.h and news_func.h.
2008-03-28 08:53:36 +00:00
smatz
3ab59da68a
(svn r12386) -Fix [FS#1841](r2428): train could break apart when reversed while partially in a depot
2008-03-19 20:50:19 +00:00
smatz
f45221f274
(svn r12384) -Fix (r2428): do not disconnect train when reversing, it may 'think' it is whole in a depot
2008-03-19 20:42:05 +00:00
glx
285a43037b
(svn r12380) -Fix: update train acceleration and max speed after setting cached value to ensure the correct max speed is used with disabled real acceleration
2008-03-17 22:13:00 +00:00
glx
cbcad325f9
(svn r12379) -Codechange: removed now redondant InvalidateWindow() calls
2008-03-17 22:04:15 +00:00
glx
187c7e19fe
(svn r12378) -Fix: refresh vehicle details window when cached values are updated
2008-03-17 21:50:53 +00:00
glx
08becf93e6
(svn r12377) -Fix [FS#1854]: set cached value for vehicle property 25 before other cached values
2008-03-17 21:49:14 +00:00
smatz
3d10ae7ec3
(svn r12369) -Fix (r1681): reset train speed limits when _patches.realistic_acceleration changes
2008-03-15 19:24:13 +00:00
smatz
1f13638d03
(svn r12368) -Codechange: use explicit body for loops and conditions and remove -Wno-empty-body from the configure script
2008-03-15 13:21:31 +00:00
peter1138
11c8050e3f
(svn r12332) -Fix (r12331): Invalidate cached data and update image after setting flag.
2008-03-03 21:42:37 +00:00
glx
d9d601b1ca
(svn r12331) -Feature: [NewGRF] vehicle variable FE bit 8
2008-03-03 20:56:30 +00:00
peter1138
f6e4dc4d8c
(svn r12209) -Fix: [NewGRF] Support using any base price for rail and road vehicles' running cost, and show running cost of wagons if they have it.
2008-02-21 19:09:10 +00:00
peter1138
0e997be11e
(svn r12205) -Codechange: rename RailVehicleInfo::running_cost_base to running_cost, inline with other vehicle types (It is the factor, not the base)
2008-02-20 20:56:54 +00:00
frosch
91297d4732
(svn r12203) -Fix (r12199): Make trains pay attention to signals again.
2008-02-20 19:37:46 +00:00
frosch
7f3d56041b
(svn r12199) -Codechange: Remove magic around the results of GetTileTrackStatus().
2008-02-20 17:49:50 +00:00
smatz
9bdb194b2a
(svn r12197) -Fix [FS#1788](r12134): show correct last year profit when the train had negative income
...
-Codechange: use GetDisplayProfitThisYear() to convert vehicle profit to readable form
2008-02-20 17:06:58 +00:00
smatz
7dbb21c69b
(svn r12194) -Codechange: apply coding style on enum TrainSubtype
2008-02-20 15:18:35 +00:00
smatz
0357c4306c
(svn r12189) -Codechange: mark some functions in train_cmd.cpp inline (called once or very short)
2008-02-20 12:07:22 +00:00
smatz
32d8ac2073
(svn r12188) -Codechange [FS#1782]: do not check twice for correct rail owner (patch by Vikthor)
2008-02-20 11:00:17 +00:00
smatz
4a329de942
(svn r12179) -Codechange: use GetCrossingRailTrack() and GetCrossingRailAxis() to improve code readability
2008-02-18 18:35:36 +00:00
smatz
97013cd8c4
(svn r12178) -Codechange: use the 'side' parameter in TrainController and TrainCheckIfLineEnds to simplify the code
2008-02-18 16:35:38 +00:00
smatz
fe48d0be21
(svn r12134) -Change: count the number of ticks a vehicle was running this day to calculate running cost
...
-Fix [FS#1739]: vehicle profit is now counted with 8bit fract, so it is now shown properly in the vehicle details window
2008-02-13 19:24:40 +00:00
smatz
391898b47a
(svn r12132) -Cleanup: convert pathfinder selection from if/else to switch/case at many places
2008-02-13 17:54:11 +00:00
smatz
4c5dde140b
(svn r12131) -Fix (r3374): with mammoth trains disabled, maximum train length was limited to 9
2008-02-13 16:49:25 +00:00
smatz
a3e3cd7d46
(svn r12129) -Change [FS#1759]: simplified patch settings for pathfinders (Yorick)
2008-02-13 14:21:36 +00:00
peter1138
3abf3e3fa4
(svn r12128) -Codechange: Replace last use of TrainPlayLeaveStationSound(v) with v->PlayLeaveStationSound(), and remove wrapper function.
2008-02-13 09:34:56 +00:00
frosch
f476d861d2
(svn r12085) -Fix(r12058): Road vehicles could get stuck, when NPF told them to reverse on junction tiles. (spotted by SmatZ)
2008-02-08 16:25:55 +00:00
belugas
7f5f48281c
(svn r12066) -Codechange: Rename GetBridge for the more common GetBridgeSpec
...
-Codechange: Remove direct access to the _bridge table in favor of the above mentioned GetBridgeSpec
-Codechange: Rationalize the use of Bridge type pointer
2008-02-05 05:21:02 +00:00
smatz
ebba0d7c71
(svn r12057) -Fix: slowdown train when approaching 90deg turn when 90deg turns are forbidden
2008-02-04 15:56:39 +00:00
glx
7ce12e50da
(svn r12037) -Codechange: replace OnNewDay_(Aircraft|RoadVeh|Ship|Train) with an OnNewDay method in the Vehicle class
2008-02-01 22:02:14 +00:00
smatz
f22b0127af
(svn r11996) -Fix [FS#1706]: update train statusbar when stopping from zero speed
2008-01-27 20:20:53 +00:00
smatz
8be486c27e
(svn r11960) -Cleanup: simplify some IsTunnel(Tile) / IsBridge(Tile) conditions
2008-01-23 14:51:36 +00:00
smatz
f05caedf7c
(svn r11922) -Codechange: use MaybeBarCrossingWithSound() to bar crossing with sound
2008-01-18 21:44:20 +00:00
smatz
dfb91c26ec
(svn r11916) -Codechange: use enums from VehicleViewWindowWidgets instead of constants
...
-Fix: refit button widget was not correctly updated
2008-01-18 13:02:47 +00:00
smatz
8dbf03e322
(svn r11910) -Fix: play 'ding-ding' crossing sound in more cases (except gameload and crossing construction)
...
-Fix: crossing sound is bound to tile, not to vehicle
2008-01-17 20:41:33 +00:00
smatz
b20d1eee6c
(svn r11908) -Fix: update crossing when merging a company, when building a crossing and after loading older savegame
2008-01-17 19:49:06 +00:00