Jonathan G Rennison
e9f5d80440
Trace restrict slots: Add support for slot operations at PBS end signal
2018-06-17 21:13:53 +01:00
Jonathan G Rennison
ba33754993
Merge branch 'save_ext' into tracerestrict-sx
...
# Conflicts:
# src/vehiclelist.cpp
2017-08-15 19:28:30 +01:00
frosch
a47fb85cd8
(svn r27893) -Codechange: Use fallthrough attribute. (LordAro)
2017-08-13 18:38:42 +00:00
frosch
dd3d824894
(svn r27885) -Cleanup (r27844): ESR_MAX_COST_EXCEEDED and ESR_PATH_TOO_LONG meant the same thing, but only one was used. Keep PATH_TOO_LONG since it has the better documentation.
2017-06-22 16:57:06 +00:00
peter1138
2e52de3406
(svn r27846) -Fix [FS#5926]: Infinite loop in pathfinder when checking safe waiting position from a waypoint.
2017-04-04 00:00:43 +00:00
peter1138
df5923d798
(svn r27845) -Change: (Yapf) Use FindDepotData struct to simplify depot finding code and remove need to return fake path distance. (juanjo)
2017-04-03 22:02:28 +00:00
peter1138
95acc016ba
(svn r27844) -Change: (Yapf) Treat max cost exceeded separately from path too long condition, as destination should not be considered in the former case.
2017-04-03 21:53:51 +00:00
peter1138
4b63778116
(svn r27843) -Change: (Yapf) Consider depot as destination before reversing path and applying penalty.
2017-04-03 21:37:01 +00:00
Jonathan G Rennison
b6e001f20e
Fix evaluation of PBS entry signal conditional after reserve through.
2017-02-27 15:02:52 +00:00
Jonathan G Rennison
f5e4d8e73a
Merge branch 'master' into tracerestrict
...
# Conflicts:
# src/rail_gui.cpp
# src/saveload/saveload.cpp
2017-01-17 19:20:46 +00:00
Jonathan G Rennison
3d6cbb76b4
Allow value of "PBS entry signal" conditional to be a rail depot.
2016-07-18 00:47:52 +01:00
Jonathan G Rennison
58817c26e0
Fix reservation through multiple reserve-through signals after a junction.
2016-07-11 22:02:33 +01:00
frosch
05a91106b8
(svn r27586) -Fix [FS#6410]: Automatic servicing of road vehicles compared path finder costs with tile distances, thus vehicles went to depots which were factor 100 too far away. (juanjo)
2016-05-29 14:14:52 +00:00
Jonathan G Rennison
1bb3024534
Fix unreserving through a green PBS signal not setting the state to red.
...
This also had the side effect of failed reservation attempts through
a reserve-through signal leaving the signal erroneously set to green.
2016-03-01 20:54:03 +00:00
Jonathan G Rennison
e2435c7169
Only run trace restrict programs if they contain relevant actions.
...
Only run in pathfinder case if deny or penalty are present.
Only run in is safe waiting tile case is reserve through is present.
Presence is determined at program validation time and cached in the
program structure.
Validator now checks for unknown non-conditional instructions.
2015-09-02 18:35:56 +01:00
Jonathan G Rennison
06a1d7c5c9
Add reserve through action to trace restrict programs.
...
This only changes the behaviour of PBS reservations which
would otherwise terminate at a PBS signal.
If the signal restriction sets the reserve through state,
the reservation continues through the signal, and the signal
is set to green.
2015-09-02 02:12:02 +01:00
Jonathan G Rennison
29c4f244f3
Merge branch 'master' into tracerestrict
...
Conflicts:
src/pathfinder/yapf/yapf_costrail.hpp
2015-08-15 00:28:14 +01:00
alberth
894f69e1fd
(svn r27363) -Codechange: Fix codestyle of one-line methods and header codestyle of derived structs.
2015-08-08 13:19:38 +00:00
alberth
48485a6a5a
(svn r27362) -Codechange: Codestyle fixes for reference var declarations, static cast type, operator methods.
2015-08-08 10:06:24 +00:00
Jonathan G Rennison
a0520b8937
Initial implementation of PBS entry signal condition variable.
...
TODO: see how the efficiency of this can be improved.
2015-08-03 20:28:42 +01:00
Jonathan G Rennison
5474ee3e40
Add entry direction condition variable.
2015-07-28 01:36:52 +01:00
Jonathan G Rennison
5f1b148cf9
Initial minimal working tracerestrict implementation.
...
This is a port of the tracerestrict/routing restrictions feature
from TTDPatch.
At present this implements if tests (train length only),
and pathfinder deny and penalty actions.
This requires the use of YAPF. Note that restrictions are only evaluated
within the YAPF lookahead distance.
2015-07-28 01:36:52 +01:00
frosch
86825a745c
(svn r27332) -Change: Enable YAPF cache debugging with desync debug level 2.
2015-07-12 17:06:02 +00:00
rubidium
2be4215f43
(svn r26482) -Codechange: add an include that allows us to undefine/redefine "unsafe" functions to prevent them from being used, and thus having to care about certain aspects of their return values
2014-04-23 20:13:33 +00:00
rubidium
fff7216d04
(svn r26117) -Cleanup: unneeded NULL check
2013-11-26 10:00:15 +00:00
rubidium
a6fae2c608
(svn r26058) -Fix: handle the return value of a number of functions better
2013-11-23 13:15:07 +00:00
rubidium
d89e93ff9a
(svn r25609) -Fix [FS#5216]: under certain circumstances a track type change would make the end-of-line-is-red setting ineffective
2013-07-14 09:21:46 +00:00
rubidium
f84b92a95d
(svn r25608) -Codechange: make EndSegmentReasonBits available in yapf_base.hpp
2013-07-14 09:20:34 +00:00
rubidium
ddfddffce9
(svn r24964) -Fix [FS#5416]: With YAPF the docking behaviour differed per direction; now favour docking in the direction you approached
2013-02-03 14:16:45 +00:00
peter1138
1e10e91fde
(svn r24905) -Feature(ish): Implement station randomisation triggers.
2013-01-11 07:39:25 +00:00
planetmaker
f00d9976f9
(svn r24900) -Fix [FS#5389]: Comments with typos (most fixes supplied by Eagle_rainbow)
2013-01-08 22:46:42 +00:00
frosch
5386558459
(svn r24481) -Feature [FS#5127]: Make the pathfinder decide whether ships shall leave depots towards north or south.
2012-08-18 11:37:47 +00:00
truebrain
aa1a0053b0
(svn r23640) -Fix: stop using FORCEINLINE (1/3rd of the instances were, the others were still regular inline), but make sure inline is always a 'forced' inline (I am looking at you MSVC)
2011-12-20 17:57:56 +00:00
michi_cc
0e96bd02c8
(svn r23564) -Fix [FS#4888]: Extending a path reservation starting at a partially reserved rail station could fail.
2011-12-17 02:02:28 +00:00
rubidium
bcb93b3b75
(svn r23093) -Codechange: add a default NULL for the Z of GetTileSlope and use it
2011-11-04 10:22:27 +00:00
rubidium
de980ef0f9
(svn r23091) -Codechange: rename some Get*Z functions to Get*PixelZ functions if they return the Z in pixels (like TilePixelHeight)
2011-11-04 10:18:13 +00:00
michi_cc
214e7bc51d
(svn r22801) -Feature: [YAPF] Take canal/ocean speed fraction of ships into account.
2011-08-21 14:13:22 +00:00
rubidium
eb2197f4c8
(svn r22410) -Document: some more bits ;)
2011-05-02 16:14:23 +00:00
smatz
57c2ca34d3
(svn r22350) -Change: make YAPF hash tables much smaller, it should improve performance significantly (about 15%)
2011-04-19 18:12:47 +00:00
smatz
5852b66c71
(svn r22348) -Codechange: split ship-specific part of yapf_node.hpp to yapf_node_ship.hpp
2011-04-19 15:00:11 +00:00
alberth
a14f4eb271
(svn r22144) -Codechange: Unify 'while (true)' to 'for (;;)'
2011-02-25 21:53:43 +00:00
rubidium
701bd8848a
(svn r22017) -Codechange: move MarkTileDirtyByTile to viewport_func.h
2011-02-07 22:29:47 +00:00
rubidium
bd921ed983
(svn r21996) -Fix [FS#4472]: [YAPF] Under some circumstances vehicles could be lost
2011-02-06 15:01:52 +00:00
rubidium
9759d57087
(svn r21815) -Fix [FS#3908]: [YAPF] Apply a pathfinder penalty for back of one-way path signals so those aren't preferred over other possibilities
2011-01-15 22:40:54 +00:00
terkhen
b6148914b0
(svn r21803) -Cleanup: Remove unnecessary semicolons.
2011-01-15 15:36:58 +00:00
smatz
61ad6990b9
(svn r21652) -Cleanup: one semicolon is enough
2010-12-28 14:22:51 +00:00
rubidium
6fd71624ef
(svn r21651) -Fix [FS#4338] (r21229): infinite loop in the road pathfinder due to bouncing around in an "one way" trap; two one ways pointing towards eachother making it impossible to leave
2010-12-27 22:32:47 +00:00
alberth
84c9201e0c
(svn r21594) -Codechange: Whitespace fixes in ifndef/define lines.
2010-12-22 11:24:38 +00:00
michi_cc
789dd1470f
(svn r21524) -Fix [FS#4302]: Do not apply the last signal red pathfinder penalty when the signal is a path signal.
2010-12-15 14:33:24 +00:00
terkhen
f69d280f14
(svn r21521) -Codechange: Unify some cached values that were present in both road vehicles and trains.
2010-12-14 21:33:53 +00:00