Jonathan G Rennison
22caac6529
Add game setting to limit train lookahead to signal aspect
...
In realistic braking mode when multi-aspect signalling enabled by GRF
2022-06-19 12:44:15 +01:00
Jonathan G Rennison
99ee4b13ce
Realistic braking: Cache train overall z position
...
Refresh cache at a variable rate depending on train length and
weight distribution
2022-06-03 00:41:41 +01:00
Jonathan G Rennison
6d877b5e70
Reduce redundant calls to get current max speed for trains and RVs
...
Between ShowVisualEffect() and UpdateSpeed()
2022-06-01 20:05:45 +01:00
Jonathan G Rennison
502980ba61
Support railtype-dependant GRF train speed limits with realistic braking
...
See: #389
2022-05-24 21:50:38 +01:00
Jonathan G Rennison
92142e5684
Add routing restriction action to make exempt from speed adaptation
2022-03-06 22:39:53 +00:00
Jonathan G Rennison
e5a421b65a
Merge branch 'master' into jgrpp
...
# Conflicts:
# src/economy.cpp
# src/linkgraph/refresh.cpp
# src/order_cmd.cpp
# src/saveload/vehicle_sl.cpp
# src/station.cpp
# src/station_base.h
# src/timetable_cmd.cpp
# src/timetable_gui.cpp
# src/vehicle.cpp
# src/vehicle_base.h
# src/vehicle_cmd.cpp
2022-03-04 18:17:44 +00:00
Jonathan G Rennison
909b20ee68
Implement train speed adaptation on signalled tunnels/bridges
...
See: #373
2022-02-21 18:57:50 +00:00
Niels Martin Hansen
e68bf58989
Codechange: Use anonymous union for vehicle orders/old orders list
2022-02-15 20:01:10 +01:00
Jonathan G Rennison
beb6d01fe8
Improve handling of conditional order waiting loops
...
Do not leave station/depot/waypoint at all if conditional order
loop would result in re-starting waiting/loading
Only actually leave and update timetable at end of loop
Rate-limit loop checks regardless of timetabled wait time
2022-01-19 00:10:49 +00:00
Jonathan G Rennison
904ff6757d
Add slot support to road vehicles, ships and aircraft
2022-01-19 00:10:49 +00:00
Jonathan G Rennison
543433218c
Ensure that timetable and scheduled dispatch windows redrawn as required
...
Reduce inefficient window and shared order list iteration
2022-01-15 00:21:31 +00:00
Jonathan G Rennison
a4ea155d33
Merge PR #357 into jgrpp
2022-01-11 20:44:47 +00:00
Yourself
7823c81597
Add: Through load speed limit setting
2022-01-08 22:27:43 -07:00
Yourself
aa7413a89f
Fix: Require non-zero capacity for refit cargo type
2022-01-06 15:42:22 -07:00
Jonathan G Rennison
30817c3915
Fix VRF_BEYOND_PLATFORM_END not being cleared when switching order
2022-01-03 12:47:44 +00:00
Jonathan G Rennison
f40191b3c0
Add hysteresis to depot search max penalty in missing depot order mode
...
See: #345
2021-12-27 17:21:00 +00:00
Michael Lutz
41fa16f325
Codechange: Don't use globals for return values from vehicle command procs.
2021-12-16 22:28:32 +01:00
Michael Lutz
13528bfcd0
Codechange: Un-bitstuff all remaining commands.
2021-12-16 22:28:32 +01:00
Michael Lutz
21675ec7e2
Codechange: Un-bitstuff vehicle/engine commands.
2021-12-16 22:28:32 +01:00
Michael Lutz
4f3ea3907e
Codechange: Un-bitstuff commands taking a ClientID (i.e. CMD_CLIENT_ID).
2021-12-16 22:28:32 +01:00
Michael Lutz
0f64ee5ce1
Codechange: Template DoCommandP to automagically reflect the parameters of the command proc.
...
When finished, this will allow each command handler to take individually
different parameters, obliviating the need for bit-packing.
2021-12-16 22:28:32 +01:00
Michael Lutz
e740c24eb7
Codechange: Template DoCommand to automagically reflect the parameters of the command proc.
...
When finished, this will allow each command handler to take individually
different parameters, obliviating the need for bit-packing.
2021-12-16 22:28:32 +01:00
Michael Lutz
7048e1522f
Codechange: Move flags in CommandProc in front of the command arguments.
2021-12-16 22:28:32 +01:00
Michael Lutz
33ca4f2b99
Codechange: Let the compile generate the master command table out of templated command traits.
...
This is using a non-intrusive type-traits like templated system, which
allows compile-time validation that the command table and the command
enum match up.
2021-12-16 22:28:32 +01:00
Michael Lutz
549caca39c
Codechange: Move command arguments to the back of the networked command function calls.
2021-12-16 22:28:32 +01:00
Michael Lutz
b6933a2ebd
Codechange: Move command arguments to the back of the DoCommand function call.
2021-12-16 22:28:32 +01:00
Jonathan G Rennison
ba65a5bab5
Run most "daily" vehicle tasks at a fixed frequency at day lengths >= 8
...
This includes: running costs, track sharing costs, breakdown checks,
servicing checks, order checks
2021-11-27 15:51:49 +00:00
Jonathan G Rennison
5723c317f7
Fix trains with non-front parts needing repair not being serviced
2021-11-20 12:43:38 +00:00
Jonathan G Rennison
4db14ccd18
Fix 71c39dc
: Incorrect handling of order without non-stop flag
...
See: #337
2021-11-20 12:14:01 +00:00
Jonathan G Rennison
4ccbb11440
Only show level crossing overlay sprites on outsides of multi-track crossings
...
When using both adjacent crossings and safer crossings
2021-11-20 01:42:54 +00:00
Jonathan G Rennison
551560537f
Ensure that adjacent level crossings cannot leave map if there are no void tiles
2021-11-20 01:27:41 +00:00
Jonathan G Rennison
af2c51e3d4
Merge branch 'running-costs-exploration' into jgrpp
2021-11-19 23:18:17 +00:00
Jonathan G Rennison
71c39dc8c2
If train next order is for same station when leaving, do not leave
...
Just start loading again without moving instead
2021-11-19 00:53:01 +00:00
Jonathan G Rennison
f22a5685c3
Divide cost instead of cost_factor in running costs division
...
This is to prevent 0 running costs for cheap vehicles when
cost_factor would be < 1
2021-11-18 23:55:48 +00:00
Jonathan G Rennison
bb8e4eb18a
Adjust stopped/depot detection for running costs division
...
Fix v/this use in Train::GetRunningCost
2021-11-18 23:41:12 +00:00
reldred
904ff346c2
Initial commit to allow configuring running costs as a fraction (1/1 default thru 1/4) independently for both vehicles stopped in depots (doesn't work for planes, I'm not smart enuff), or vehicles that are stationary.
2021-11-18 12:47:23 +10:30
Jonathan G Rennison
76ad272f3b
Fix reservation loop with single-vehicle trains and signalled tunnel/bridges
2021-11-14 00:00:22 +00:00
Jonathan G Rennison
74bfe4e6d2
Allow placing routing restrictions on tunnel/bridge entrance/exit signals
...
No reserve through support
2021-11-13 22:28:14 +00:00
Jonathan G Rennison
1ee59c8333
Fix pending speed restrictions not being applied on signalled tunnel/bridges
...
Distance remaining was not decremented
2021-11-13 21:24:31 +00:00
Jonathan G Rennison
8c8c0e250a
Fix exit signal state when unable to leave signalled custom bridge head
...
When the exit direction is different to the bridge direction.
2021-11-13 20:37:18 +00:00
Jonathan G Rennison
e661a07425
Fix train not stuck action clearing wait counter when in depot/tunnel/bridge
2021-11-13 18:15:57 +00:00
Jonathan G Rennison
48977853a4
Simplify some rail/signalled tunnel/bridge tile checks
2021-11-13 17:26:07 +00:00
Jonathan G Rennison
dad007e16a
Fix spelling of TRPRF_SPEED_RESTRICTION_SET
2021-11-13 02:00:37 +00:00
Jonathan G Rennison
3308edf792
Try to extend reservation when passing sighting distance of non-end signal
2021-11-12 01:02:29 +00:00
Jonathan G Rennison
2a2b988424
Fix premature reservation end after reversing station found
...
ChooseTrainTrackLookAheadStateFlags/TrainReservationLookAheadFlags mixup
2021-11-12 00:03:09 +00:00
Jonathan G Rennison
2b1993ee4d
Fix crash with wrong-way running on multi-aspect signalled tunnel/bridge
...
When using the ignore signals buttons and updating middle signal states
2021-11-11 18:06:35 +00:00
Jonathan G Rennison
3cff5e53e4
Add train cached_curve_speed_mod to VENC, cache checks and debug window
2021-11-02 22:37:34 +00:00
Jonathan G Rennison
faf32200cf
Merge tag '12.0-beta1' into jgrpp-beta
...
# Conflicts:
# CMakeLists.txt
# bin/ai/CMakeLists.txt
# bin/game/CMakeLists.txt
# src/build_vehicle_gui.cpp
# src/console_cmds.cpp
# src/core/overflowsafe_type.hpp
# src/fios.cpp
# src/lang/english.txt
# src/lang/german.txt
# src/lang/korean.txt
# src/lang/polish.txt
# src/network/core/game_info.cpp
# src/network/core/game_info.h
# src/network/core/tcp_game.cpp
# src/network/core/tcp_game.h
# src/network/network.cpp
# src/network/network_client.cpp
# src/network/network_client.h
# src/network/network_coordinator.cpp
# src/network/network_gui.cpp
# src/network/network_server.cpp
# src/network/network_server.h
# src/newgrf_engine.cpp
# src/openttd.cpp
# src/rev.cpp.in
# src/settings_type.h
# src/train.h
# src/train_cmd.cpp
2021-11-02 17:51:38 +00:00
Jonathan G Rennison
f54d69a60a
Merge branch 'master' into jgrpp-beta
...
# Conflicts:
# src/economy.cpp
# src/elrail.cpp
# src/graph_gui.cpp
# src/linkgraph/linkgraph_gui.cpp
# src/network/core/game_info.cpp
# src/newgrf_station.cpp
# src/saveload/saveload.cpp
# src/settings.cpp
# src/station_cmd.cpp
# src/station_gui.cpp
# src/strings_func.h
# src/table/settings/network_settings.ini
# src/table/settings/settings.ini
2021-11-01 21:18:24 +00:00
Jonathan G Rennison
61cc60099a
Merge branch 'jgrpp' into jgrpp-beta
...
# Conflicts:
# src/network/core/packet.cpp
# src/network/core/udp.cpp
2021-10-29 22:22:54 +01:00