mirror of
https://github.com/OpenMW/openmw.git
synced 2025-02-04 16:45:34 +00:00
Minor efficiency fix
This commit is contained in:
parent
f6509fe53e
commit
17e3069896
1 changed files with 3 additions and 2 deletions
|
@ -465,8 +465,9 @@ namespace ESMTerrain
|
|||
Terrain::LayerInfo Storage::getLayerInfo(const std::string& texture)
|
||||
{
|
||||
// Already have this cached?
|
||||
if (mLayerInfoMap.find(texture) != mLayerInfoMap.end())
|
||||
return mLayerInfoMap[texture];
|
||||
std::map<std::string, Terrain::LayerInfo>::iterator found = mLayerInfoMap.find(texture);
|
||||
if (found != mLayerInfoMap.end())
|
||||
return found->second;
|
||||
|
||||
Terrain::LayerInfo info;
|
||||
info.mParallax = false;
|
||||
|
|
Loading…
Reference in a new issue