forked from mirror/OpenTTD
Codechange: Deduplicate ResolveReal() for resolvers that don't use real sprite groups.
This may change behaviour when multiple loading/loaded stages are provided, as the various copies checked in different orders, however only one result is expected in these cases anyway.
This commit is contained in:
@@ -58,13 +58,6 @@
|
||||
return UINT_MAX;
|
||||
}
|
||||
|
||||
/* virtual */ const SpriteGroup *RailTypeResolverObject::ResolveReal(const RealSpriteGroup *group) const
|
||||
{
|
||||
if (!group->loading.empty()) return group->loading[0];
|
||||
if (!group->loaded.empty()) return group->loaded[0];
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
GrfSpecFeature RailTypeResolverObject::GetFeature() const
|
||||
{
|
||||
return GSF_RAILTYPES;
|
||||
|
Reference in New Issue
Block a user