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
smatz
2c38d3066f
(svn r11900) -Fix: set correctly crossing state after train reversal, train leaving crossing, train crash
...
Fixes several ways to leave crossing red forever or to leave it unbarred when there is a train on crossing
2008-01-17 17:57:39 +00:00
smatz
fc2895e8c2
(svn r11882) -Codechange: introduce MarkSingleVehicleDirty() and simplify the code at some places
2008-01-16 21:17:31 +00:00
smatz
3ad8b79550
(svn r11877) -Fix: another way to crash competitors' train in a station
...
-Codechange: increase the speed train is approaching line end/semaphore in non-diagonal direction a bit
2008-01-16 15:48:36 +00:00
smatz
70a9c544b8
(svn r11870) -Fix: slow down train when approaching tile we can't enter in more cases
...
(tunnel/bridge/depot from wrong direction, competitor's track, wrong railtype)
-Fix: do not make crossing red when we can't enter it in any case
2008-01-16 00:33:28 +00:00
rubidium
736640fd87
(svn r11866) -Codechange: swap OFB_* and OF_* so it conceptually in sync with other cases of *B_* vs *_* like VETSB_* and VETS_*.
2008-01-15 18:44:22 +00:00
smatz
81cad58c68
(svn r11864) -Codechange: pass owner whose signals we will update instead of complex detection later
2008-01-15 15:00:01 +00:00
smatz
c6de18c3db
(svn r11847) -Fix: do not affect the speed a train is entering a depot by trackbits behind it
2008-01-14 14:46:09 +00:00
smatz
a9f69f387d
(svn r11845) -Codechange: simplify train collision detection a bit
2008-01-13 23:53:33 +00:00
smatz
b3e28dc5ad
(svn r11835) -Fix: mark depot, viewports, vehicle lists and vehicle details dirty when a train crashes
2008-01-13 14:42:28 +00:00
rubidium
9c0c798dd8
(svn r11834) -Codechange: only include settings_type.h if needed.
2008-01-13 14:37:30 +00:00
smatz
86a6268f3e
(svn r11831) -Fix: call TrainConsistChanged() when removing crashed train part to be consistent with saveload process
2008-01-13 13:11:59 +00:00
rubidium
90acd52f22
(svn r11828) -Codechange: include table/* as the last includes and remove an unneeded include from openttd.h.
2008-01-13 01:21:35 +00:00
peter1138
0f7392bd61
(svn r11822) -Codechange: Replaced fixed size custom name array. Names are now attached to their object directly and there is
...
no limit to the amount of names.
-Fix: NewGRF engines could not be renamed.
2008-01-12 19:58:06 +00:00
smatz
74f9be8f2c
(svn r11821) -Fix (r11802): 'optimization assert' when removing crashed wagon in some cases
2008-01-12 19:33:25 +00:00
smatz
9c9b743242
(svn r11820) -Fix: invalidate depot window when removing crashed train
2008-01-12 19:24:58 +00:00
smatz
b18b7f6f22
(svn r11819) -Fix: do not access the Vehicle struct that has been already deleted when removing crashed train
2008-01-12 19:20:44 +00:00
rubidium
2fc62eab05
(svn r11818) -Codechange: split player.h into smaller pieces.
2008-01-12 14:10:35 +00:00
smatz
fa1f94e599
(svn r11812) -Codechange: introduce TrainExitDir() to simplify some functions
2008-01-11 15:10:59 +00:00
smatz
bc4ed3eafd
(svn r11802) -Fix [FS#716]: do not crash trains when leaving depot to a very long track
...
-Codechange: use dedicated pathfinder for signal updating, resulting in better performance and possible future improvements
2008-01-09 23:00:59 +00:00
rubidium
2d2e1e3863
(svn r11800) -Codechange: move some functions to a more logical location + some type safety.
2008-01-09 21:05:03 +00:00
rubidium
0365c1f33b
(svn r11793) -Codechange: pass the expense type via the CommandCost instead of a global variable. Patch by Noldo (FS#1114).
2008-01-09 16:55:48 +00:00
peter1138
0ae26a0312
(svn r11789) -Codechange: coding style for global variable names
2008-01-09 10:15:20 +00:00
rubidium
64d691bacc
(svn r11787) -Codechange: more header rewrites. This time related to viewport.h.
2008-01-09 09:45:45 +00:00
rubidium
e2f7ec1d3e
(svn r11775) -Codechange: move all autoreplace/autorenew functions to a single location.
2008-01-07 09:19:53 +00:00
rubidium
444e77d8bc
(svn r11774) -Change: do not include variables.h in a header when it is not needed.
2008-01-07 00:57:19 +00:00
smatz
f02cf9281b
(svn r11760) -Codechange: unify the way how other end of a tunnel/bridge is determined at some places
...
-Fix: adding road/tram to tram/road bridge was cheaper by one tile
2008-01-04 19:45:29 +00:00
peter1138
5c23778065
(svn r11741) -Feature: Add support for NewGRF's train 'tilt' flag. Trains with tilt capability (specific details are per NewGRF set) will be given a 20% speed limit bonus on curves.
2008-01-01 22:24:18 +00:00
peter1138
c96fcfc21b
(svn r11738) -Codechange: Refactor realistic acceleration's curve counting to use DirDiffs instead of local tables, and remove an unnecessary loop.
2008-01-01 18:12:17 +00:00
peter1138
e5f50b6fde
(svn r11733) -Fix: Max speed for entering stations overrode the max speed of curves
2008-01-01 14:15:28 +00:00
peter1138
a1b482973d
(svn r11732) -Fix (r4150): elrail merge gave elrail, monorail & maglev unintended speed bonuses for curves, as the bonus was based on the railtype index. The bonus is now specified by a property of the railtype.
2008-01-01 14:00:31 +00:00
peter1138
2194b15fdd
(svn r11731) -Fix [FS#1582]: Clear sprite override data before performing NewGRF wagon attach callback. This stopped
...
the callback working for autoreplace and when moving wagons from train to train in a depot.
-Fix (r11724): Don't check wagon attach callback for the chain when moving a single wagon.
2007-12-31 21:51:16 +00:00
rubidium
fe71089b0e
(svn r11724) -Fix: make it impossible (for users) to circumvent the length checking of the NewGRF 'allow wagon attach' callback by moving several wagons at a time.
2007-12-30 21:35:48 +00:00
rubidium
445a733eb6
(svn r11719) -Codechange: split sound.h in a header with types and one with functions.
2007-12-29 09:24:26 +00:00
smatz
c10d3da133
(svn r11707) -Fix: do not allow refitting flooded (destroyed) vehicles
2007-12-27 14:10:47 +00:00
rubidium
722613f7f3
(svn r11706) -Codechange: split vehicle.h and remove another bunch of useless includes.
2007-12-27 13:35:39 +00:00
smatz
ae3206cd97
(svn r11705) -Fix [FS#1557]: trains could have sprites with wrong direction when reversing, also was inconsistent with save/load process (possible desyncs)
2007-12-27 13:25:23 +00:00
rubidium
db73addb43
(svn r11702) -Codechange: move all date related stuff to date*.
2007-12-26 13:50:40 +00:00
rubidium
f82aeb82c5
(svn r11701) -Codechange: removal unnecessary inclusions of map.h (and split map.h).
2007-12-26 11:45:43 +00:00
rubidium
81bf9f8503
(svn r11692) -Codechange: move some functions from 'functions.h' to a more logical place and remove about 50% of the includes of 'functions.h'
2007-12-25 11:26:07 +00:00
rubidium
3074bca136
(svn r11680) -Codechange: refactor more out of openttd.h and functions.h.
2007-12-21 22:50:51 +00:00
rubidium
766551b0bc
(svn r11677) -Codechange: move price and command related types/functions to their respective places.
2007-12-21 21:50:46 +00:00
rubidium
8427b8bad2
(svn r11675) -Codechange: split the string types from the string functions.
2007-12-21 19:49:27 +00:00
rubidium
be923601bf
(svn r11669) -Codechange: refactor tile.h -> tile_type.h and tile_map.h
2007-12-19 23:26:02 +00:00
rubidium
0995194162
(svn r11661) -Codechange: some header reworks in order to try to reduce the compile time of OpenTTD by reduce the amount of circular-ish dependencies.
2007-12-18 19:52:14 +00:00
smatz
d56a690ba4
(svn r11649) -Codechange: some code can be simplified thanks to changes in r11642
2007-12-16 19:30:42 +00:00
smatz
926fe5c9e9
(svn r11644) -Codechange: merge some functions from tunnel_map.h and bridge_map.h into tunnelbridge_map.h
2007-12-16 15:38:51 +00:00
smatz
60f9bbd17e
(svn r11642) -Codechange: VehicleFromPos does check for v->tile == tile, so remove useless checks
2007-12-15 23:11:18 +00:00
smatz
57a83e7c76
(svn r11634) -Fix: update signals when deleting crashed train on a bridge, update even when train is rotated
2007-12-15 00:04:01 +00:00
smatz
d31506654c
(svn r11633) -Codechange: merge CheckTunnelEmpty and IsVehicleOnBridge into GetVehicleTunnelBridge
2007-12-14 23:21:20 +00:00
smatz
cd58045234
(svn r11623) -Fix [FS#1533] (r11619): assert when train is going over two crossings next to each other
2007-12-11 22:50:13 +00:00
smatz
3a62919ba3
(svn r11619) -Fix [FS#1531]: do not make crossing red behind depot the train is entering
2007-12-11 19:09:36 +00:00
glx
06c131b244
(svn r11567) -Fix [FS#1512] (r11011): break the chain before moving a vehicle after another in the same chain
2007-12-04 15:32:54 +00:00
skidd13
e36dba227b
(svn r11523) -Codechange: Move the CHANCE macros to core/random_func.cpp cause they depend on Random()
...
-Codechange: Convert the CHANCE macros to functions and rename them fitting to the naming style
2007-11-25 15:35:25 +00:00
skidd13
f92f3aec06
(svn r11485) -Codechange: Remove the doubled function ToggleBitT and rename the remaining to fit with the naming style
2007-11-20 14:11:19 +00:00
skidd13
3ae50673a3
(svn r11484) -Codechange: Remove the doubled function SetBitT and rename the remaining to fit with the naming style
2007-11-20 13:35:54 +00:00
skidd13
6801cceda1
(svn r11482) -Codechange: Remove the doubled function ClrBitT and rename the remaining to fit with the naming style
2007-11-19 21:32:20 +00:00
skidd13
c0a2c0c23e
(svn r11481) -Codechange: Rename the HASBIT function to fit with the naming style
2007-11-19 21:02:30 +00:00
skidd13
f4a5c80d71
(svn r11476) -Codechange: rename the function myabs to abs to get rid of an unneeded define
2007-11-19 18:58:04 +00:00
skidd13
98f66552be
(svn r11475) -Codechange: rename clamp and clampu to Clamp and ClampU to fit with the coding style
2007-11-19 18:38:10 +00:00
glx
9fcf6e7a43
(svn r11431) -Codechange: [NewGRF] Add support for changing rail vehicle user-defined bit mask (prop 25) via callback 36
2007-11-15 00:13:12 +00:00
truelight
b935a74782
(svn r11383) -Codechange: fixed all the mess around KillFirstBit (tnx to Rubidium and skidd13)
2007-11-04 23:06:39 +00:00
glx
6120d02751
(svn r11352) -Codechange: cache callback 2D result (vehicle color mapping) instead calling it every time the vehicle is drawn
2007-10-28 15:40:18 +00:00
maedhros
5712da734f
(svn r11333) -Fix: Train engines still had a value of 0.
2007-10-21 16:52:01 +00:00
rubidium
b4e7203b0a
(svn r11332) -Fix: vehicles getting a value of 0 on construction.
...
-Fix: assertion when selling vehicles.
2007-10-21 16:45:00 +00:00
rubidium
c8df832678
(svn r11230) -Fix [FS#1228]: one could construct trains out of crashed wagons and engines. Based on a patch by SmatZ.
2007-10-08 20:16:25 +00:00
rubidium
2e8f93a821
(svn r11229) -Fix [FS#1307]: one could sell vehicles that were crashed in a depot, which would still yield money.
2007-10-08 20:06:37 +00:00
rubidium
a28b307c95
(svn r11173) -Codechange: rename some callback enums so they are more uniform.
2007-09-26 17:33:32 +00:00
rubidium
26310769dd
(svn r11134) -Fix [FS#1238]: vehicles got removed twice from the group list when selling whole trains.
2007-09-21 17:56:55 +00:00
rubidium
f41c8ab3aa
(svn r11122) -Fix [FS#1234]: crash when building a NewGRF vehicle when the articulated build vehicle callback returneed a different value for the purchase window than the normal build. Thanks for Dalestan and _minime_ for pointers to possible causes.
2007-09-17 04:23:03 +00:00
rubidium
a18f3f25a9
(svn r11120) -Codechange: remove the arbitrary limit of 10 articulated parts for a vehicle.
2007-09-16 20:48:00 +00:00
rubidium
d651f6b9ed
(svn r11086) -Fix/Revert (r11053, r10984): "fixing" r11053 made the acceleration code use the wrong speed, which can be fixed by reverting a small piece of r10984.
2007-09-10 17:13:37 +00:00
rubidium
634aba16a7
(svn r11072) -Fix [FS#1045]: when a vehicle had a service order, the goto-depot button did not make it possible to stop the vehicle at that depot.
2007-09-09 17:42:59 +00:00
rubidium
c97804461e
(svn r11059) -Fix [FS#1182]: inconsistency between Rail<->ElRail conversions of different kinds of rail containing tiles (normal rail, stations, depots, etc). Patch by SmatZ.
2007-09-08 09:52:02 +00:00
rubidium
0db524e175
(svn r11048) -Fix [FS#1206]: several cases where (re)moving eninges on a train would corrupt the vehicle counts for the groups.
2007-09-05 21:05:12 +00:00
bjarni
7cd2aeb1c9
(svn r11045) -Codechange: added a function to tell if a vehicle is the rear part of a dualheaded train engine
2007-09-05 10:15:23 +00:00
rubidium
cadc470da5
(svn r11017) -Codechange: unify determining whether a vehicle needs/can be service a little more.
2007-08-31 17:13:39 +00:00
rubidium
732845440a
(svn r11011) -Fix [FS#1129]: GetFirstVehicleInChain did change the game state while being marked const.
...
-Codechange: do not brute force determine the first vehicle in the chain or previous vehicle, but do it by properly accounting the previous and first pointers when updating the next pointer. This gives a performance increase of about 15% when there are a lot of vehicles in the game.
2007-08-30 21:11:12 +00:00
rubidium
f830699971
(svn r11004) -Codechange: some reworks of the saveload mechanism to be able to save and load private and protected variables in the vehicle struct.
2007-08-30 13:09:44 +00:00
rubidium
235ad4ab6b
(svn r11003) -Codechange: replace Vehicle->next to Vehicle->Next() and Vehicle->SetNext() so we can trap instances that change a next pointer and (in the future) update the first/previous pointers based on that.
2007-08-30 13:03:56 +00:00
rubidium
dc80195754
(svn r10999) -Codechange: unify the way the running cost of a vehicle is determined. Patch by nycom.
2007-08-29 21:27:16 +00:00
rubidium
a6a9968d16
(svn r10997) -Codechange: unify the vehicle view window. Patch by PhilSophus.
2007-08-29 20:50:58 +00:00
rubidium
91d18ebd17
(svn r10984) -Codechange: unify the way one can get the current speed in the same forwat so we can display it.
2007-08-26 20:43:22 +00:00
rubidium
39f17c9de4
(svn r10983) -Codechange: use vehstatus & VS_CRASHED instead of some other "methods" custom to each vehicle to determine whether the vehicle is crashed.
2007-08-26 20:16:02 +00:00
bjarni
495bc4ecf4
(svn r10823) -Fix r8610 [FS#1097]: the autoreplace window vehicle count didn't always update correctly) (Matthias)
2007-08-07 23:07:10 +00:00
rubidium
b21f29c38f
(svn r10770) -Codechange: use the pool item class as super class for the vehicle struct.
...
-Codechange: do not force "special" vehicles to be allocated in the low 1024 vehicle slots and non "special" vehicles in the rest of the slots.
2007-08-03 19:36:00 +00:00
peter1138
9b9bca40b9
(svn r10734) -Fix [FS#1030]: Revert r10513) and add special cases for collision detection on bridges/tunnels.
2007-07-30 08:49:41 +00:00
rubidium
a67957866a
(svn r10697) -Codechange: give a more sensible names to some of the unkX variables.
2007-07-26 15:37:19 +00:00
rubidium
df009178d4
(svn r10587) -Codechange: move the string/dparam related stuff from variables.h to strings.h
2007-07-16 09:16:58 +00:00
rubidium
7cb7488836
(svn r10493) -Codechange: update some callback ID enums to reflect their changed usage, add a few and update the comments.
2007-07-09 19:38:12 +00:00
rubidium
4b70a97fde
(svn r10474) -Fix [FS#995]: wrong group count after train crash.
2007-07-08 09:29:28 +00:00
rubidium
ec137f60ed
(svn r10409) -Codechange: replace (Aircraft|RoadVeh|Ship|Train)_Tick with a Tick method in the Vehicle class.
2007-07-01 19:24:54 +00:00
rubidium
c0e341ee05
(svn r10408) -Codechange: make GetImage a class method of Vehicle instead of Get(Aircraft|RoadVeh|Ship|Train)Image.
2007-07-01 19:11:47 +00:00
rubidium
5c1aff5ce6
(svn r10381) -Fix [FS#951]: skipping an order made train reverse immediatelly. Patch by boekabart.
2007-06-28 22:03:34 +00:00
peter1138
85fb4eb94b
(svn r10363) -Fix [FS#911]: invalidating autoreplace windows didn't take account of vehicle group (Matthias Wolf)
2007-06-27 20:40:20 +00:00
peter1138
f8a5b61f4e
(svn r10344) -Fix (r10317): confusion between TRACK_n and TRACK_BIT_n stopped NW/SE slopes being picked up, and compare middle of tile against current z, not previous.
2007-06-26 20:03:17 +00:00
maedhros
9fce70ac21
(svn r10335) -Fix (r10331): Increment the current order index *after* using it in UpdateVehicleTimetable.
2007-06-25 23:14:13 +00:00
rubidium
e68892dcd4
(svn r10317) -Fix [FS#786]: acceleration not calculated properly when a train goes up a hill between tunnels.
2007-06-25 08:24:03 +00:00
truelight
872ba4e659
(svn r10288) -Fix [FS#202]: also age engines that aren't front-engines (based on a patch by kaan)
2007-06-22 22:42:18 +00:00