diff options
author | tron <tron@openttd.org> | 2004-11-14 17:16:26 +0000 |
---|---|---|
committer | tron <tron@openttd.org> | 2004-11-14 17:16:26 +0000 |
commit | a348f74c65495651424975bb8ad0ffe1704b7013 (patch) | |
tree | c68d9540588d742754c81265e9202b990a08ab26 | |
parent | ea48b0d05c16333d4964526d2a14b72f5f8cc9ba (diff) | |
download | openttd-a348f74c65495651424975bb8ad0ffe1704b7013.tar.xz |
(svn r604) -Fix: [ 999669 ] Wrong trees (toyland's) in sub-tropical landscape style
Tree generation code sometimes set the non-existent growth state 7
This could also become manifest in snow covered trees below the swnow line in arctic climate and similar effects
-rw-r--r-- | tree_cmd.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tree_cmd.c b/tree_cmd.c index f2e3db69d..76e89b892 100644 --- a/tree_cmd.c +++ b/tree_cmd.c @@ -36,7 +36,7 @@ static void PlaceTree(uint tile, uint32 r, byte m5_or) if (tree >= 0) { m5 = (byte)(r >> 16); - if(m5==7) m5--; + if ((m5 & 0x7) == 7) m5--; // there is no growth state 7 _map5[tile] = m5 & 0x07; // growth state; _map5[tile] |= m5 & 0xC0; // amount of trees |