summaryrefslogtreecommitdiff
path: root/src/newgrf.cpp
diff options
context:
space:
mode:
authorbelugas <belugas@openttd.org>2007-02-16 01:35:18 +0000
committerbelugas <belugas@openttd.org>2007-02-16 01:35:18 +0000
commit4d988c35061147033b806d006d28dffc1f7a4be2 (patch)
treec09e02d43e74a7fd2a6e65723a7b894ae62cef8b /src/newgrf.cpp
parent2b307647da53672aa92463cd6b6b70e94ca2ef01 (diff)
downloadopenttd-4d988c35061147033b806d006d28dffc1f7a4be2.tar.xz
(svn r8753) -Regression (r8455): Do not unilateraly decide that this engine is a single-headed. Only do it if it previously had no power and that now there is. Or something...
Diffstat (limited to 'src/newgrf.cpp')
-rw-r--r--src/newgrf.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/newgrf.cpp b/src/newgrf.cpp
index de4a9c76f..e1ba368b7 100644
--- a/src/newgrf.cpp
+++ b/src/newgrf.cpp
@@ -215,7 +215,8 @@ static void dewagonize(int condition, int engine)
if (condition != 0) {
ei->unk2 &= ~0x80;
- rvi->railveh_type = RAILVEH_SINGLEHEAD;
+ if (rvi->railveh_type == RAILVEH_WAGON)
+ rvi->railveh_type = RAILVEH_SINGLEHEAD;
} else {
ei->unk2 |= 0x80;
rvi->railveh_type = RAILVEH_WAGON;