diff options
author | frosch <frosch@openttd.org> | 2011-05-14 13:12:47 +0000 |
---|---|---|
committer | frosch <frosch@openttd.org> | 2011-05-14 13:12:47 +0000 |
commit | 20e86fd5ea07b2ae0082f48ddb54d4da10b9d486 (patch) | |
tree | 4aac07bd4be853a5a091a9d2d31e1fbf212d2d25 /src/station_cmd.cpp | |
parent | fdd2f8447eb2a6fedb42180f5dc5367a14c0f2bf (diff) | |
download | openttd-20e86fd5ea07b2ae0082f48ddb54d4da10b9d486.tar.xz |
(svn r22454) -Codechange: Deduplicate GetCustomStationGroundRelocation() into GetCustomStationRelocation() and only call it if actually needed.
Diffstat (limited to 'src/station_cmd.cpp')
-rw-r--r-- | src/station_cmd.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/station_cmd.cpp b/src/station_cmd.cpp index 57abbb8ae..9f4048769 100644 --- a/src/station_cmd.cpp +++ b/src/station_cmd.cpp @@ -2678,7 +2678,12 @@ draw_default_foundation: } } else { if (HasBit(image, SPRITE_MODIFIER_CUSTOM_SPRITE)) { - image += GetCustomStationGroundRelocation(statspec, st, ti->tile); + if (HasBit(statspec->flags, SSF_SEPARATE_GROUND)) { + /* Use separate action 1-2-3 chain for ground sprite */ + image += GetCustomStationRelocation(statspec, st, ti->tile, 1); + } else { + image += relocation; + } image += custom_ground_offset; } else { image += total_offset; |