From 09227ef450b36dd92f940e0dfba29726e928a56b Mon Sep 17 00:00:00 2001 From: Jonathan G Rennison Date: Thu, 15 Oct 2015 02:08:27 +0100 Subject: [PATCH] Fix CFollowTrackT::Follow returning EC_NO_WAY instead of EC_RAIL_TYPE. This can result in YAPF desyncs as this then ends up in the cache as a ESRB_DEAD_END instead of a ESRB_RAIL_TYPE, which is problematic when some vehicles can use the rail type but some cannot. --- src/pathfinder/follow_track.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pathfinder/follow_track.hpp b/src/pathfinder/follow_track.hpp index 57b5750757..5d3b5b0778 100644 --- a/src/pathfinder/follow_track.hpp +++ b/src/pathfinder/follow_track.hpp @@ -145,7 +145,7 @@ struct CFollowTrackT * missing road bit, or inability to connect the * different bits due to slopes. */ if (IsRoadTT() && !IsTram() && TryReverse()) return true; - m_err = EC_NO_WAY; + if (m_new_td_bits == TRACKDIR_BIT_NONE) m_err = EC_NO_WAY; return false; } if (!Allow90degTurns()) {