summaryrefslogtreecommitdiff
path: root/yapf/yapf_base.hpp
diff options
context:
space:
mode:
authorKUDr <KUDr@openttd.org>2006-06-07 21:16:43 +0000
committerKUDr <KUDr@openttd.org>2006-06-07 21:16:43 +0000
commit68372f4c16825f2dad27d61184b37781d65a11a8 (patch)
treeec0d2f5e5f9b8c22f38e6f35337163991e2511ba /yapf/yapf_base.hpp
parent7fd88e57981e15cd8f2c11a2134e289dbe1b856e (diff)
downloadopenttd-68372f4c16825f2dad27d61184b37781d65a11a8.tar.xz
(svn r5162) - CodeChange: [YAPF] added flag "choice seen" into YAPF node for trains
Diffstat (limited to 'yapf/yapf_base.hpp')
-rw-r--r--yapf/yapf_base.hpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/yapf/yapf_base.hpp b/yapf/yapf_base.hpp
index e08422ed3..c5c50fe65 100644
--- a/yapf/yapf_base.hpp
+++ b/yapf/yapf_base.hpp
@@ -186,10 +186,11 @@ public:
/** add multiple nodes - direct children of the given node */
FORCEINLINE void AddMultipleNodes(Node* parent, TileIndex tile, TrackdirBits td_bits)
{
+ bool is_choice = (KillFirstBit2x64(td_bits) != 0);
for (TrackdirBits rtds = td_bits; rtds != TRACKDIR_BIT_NONE; rtds = (TrackdirBits)KillFirstBit2x64(rtds)) {
Trackdir td = (Trackdir)FindFirstBit2x64(rtds);
Node& n = Yapf().CreateNewNode();
- n.Set(parent, tile, td);
+ n.Set(parent, tile, td, is_choice);
Yapf().AddNewNode(n);
}
}