diff options
author | Andrei Karas <akaras@inbox.ru> | 2016-10-04 19:38:47 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2016-10-04 19:38:47 +0300 |
commit | 60745b8038b18d4b7b7198a03547676b92988426 (patch) | |
tree | 93170d1fe52baa08a640ddb56629424c698cc53b /src/resources/map/map.cpp | |
parent | b844884ba160f7a0204382cbbce4c98ecae1139b (diff) | |
download | mv-60745b8038b18d4b7b7198a03547676b92988426.tar.gz mv-60745b8038b18d4b7b7198a03547676b92988426.tar.bz2 mv-60745b8038b18d4b7b7198a03547676b92988426.tar.xz mv-60745b8038b18d4b7b7198a03547676b92988426.zip |
Move maplayerposition into enums directory.
Diffstat (limited to 'src/resources/map/map.cpp')
-rw-r--r-- | src/resources/map/map.cpp | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/src/resources/map/map.cpp b/src/resources/map/map.cpp index 2d6631aa5..f662bedac 100644 --- a/src/resources/map/map.cpp +++ b/src/resources/map/map.cpp @@ -352,7 +352,9 @@ void Map::draw(Graphics *restrict const graphics, static_cast<float>(scrollY)); // Draw backgrounds - drawAmbientLayers(graphics, BACKGROUND_LAYERS, mOverlayDetail); + drawAmbientLayers(graphics, + MapLayerPosition::BACKGROUND_LAYERS, + mOverlayDetail); if (mDrawLayersFlags == MapType::BLACKWHITE && userPalette) { @@ -521,7 +523,9 @@ void Map::draw(Graphics *restrict const graphics, } } - drawAmbientLayers(graphics, FOREGROUND_LAYERS, mOverlayDetail); + drawAmbientLayers(graphics, + MapLayerPosition::FOREGROUND_LAYERS, + mOverlayDetail); BLOCK_END("Map::draw") } @@ -639,12 +643,12 @@ void Map::updateAmbientLayers(const float scrollX, } void Map::drawAmbientLayers(Graphics *restrict const graphics, - const LayerType type, + const MapLayerPositionT type, const int detail) const restrict2 { BLOCK_START("Map::drawAmbientLayers") // Detail 0 = no ambient effects except background image - if (detail <= 0 && type != BACKGROUND_LAYERS) + if (detail <= 0 && type != MapLayerPosition::BACKGROUND_LAYERS) { BLOCK_END("Map::drawAmbientLayers") return; @@ -654,10 +658,10 @@ void Map::drawAmbientLayers(Graphics *restrict const graphics, const AmbientLayerVector *restrict layers = nullptr; switch (type) { - case FOREGROUND_LAYERS: + case MapLayerPosition::FOREGROUND_LAYERS: layers = &mForegrounds; break; - case BACKGROUND_LAYERS: + case MapLayerPosition::BACKGROUND_LAYERS: layers = &mBackgrounds; break; default: |