summaryrefslogtreecommitdiff
path: root/src/gui
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/popups/statuspopup.cpp2
-rw-r--r--src/gui/viewport.cpp25
-rw-r--r--src/gui/viewport.h12
-rw-r--r--src/gui/windows/statuswindow.cpp2
4 files changed, 22 insertions, 19 deletions
diff --git a/src/gui/popups/statuspopup.cpp b/src/gui/popups/statuspopup.cpp
index a1e0b502c..f2f934d1b 100644
--- a/src/gui/popups/statuspopup.cpp
+++ b/src/gui/popups/statuspopup.cpp
@@ -154,7 +154,7 @@ void StatusPopup::updateLabels() const
InputAction::SWITCH_QUICK_DROP);
setLabelText(7, player_node->getPickUpTypeString(),
InputAction::CHANGE_PICKUP_TYPE);
- setLabelText(8, LocalPlayer::getDebugPathString(),
+ setLabelText(8, LocalPlayer::getMapDrawTypeString(),
InputAction::PATHFIND);
setLabelText(9, player_node->getMagicAttackString(),
InputAction::SWITCH_MAGIC_ATTACK);
diff --git a/src/gui/viewport.cpp b/src/gui/viewport.cpp
index 225b88f30..1c0694ca3 100644
--- a/src/gui/viewport.cpp
+++ b/src/gui/viewport.cpp
@@ -79,7 +79,7 @@ Viewport::Viewport() :
mMousePressY(0),
mPixelViewX(0),
mPixelViewY(0),
- mShowDebugPath(MapType::NORMAL),
+ mMapDrawType(MapType::NORMAL),
mCameraMode(0),
mLocalWalkTime(-1),
mCameraRelativeX(0),
@@ -122,7 +122,7 @@ Viewport::~Viewport()
void Viewport::setMap(Map *const map)
{
if (mMap && map)
- map->setDebugFlags(mMap->getDebugFlags());
+ map->setDrawLayersFlags(mMap->getDrawLayersFlags());
mMap = map;
}
@@ -237,11 +237,14 @@ void Viewport::draw(Graphics *graphics)
// Draw tiles and sprites
mMap->draw(graphics, mPixelViewX, mPixelViewY);
- if (mShowDebugPath)
+ if (mMapDrawType != MapType::NORMAL)
{
- mMap->drawCollision(graphics, mPixelViewX,
- mPixelViewY, mShowDebugPath);
- if (mShowDebugPath == MapType::DEBUG)
+ if (mMapDrawType != MapType::SPECIAL4)
+ {
+ mMap->drawCollision(graphics, mPixelViewX,
+ mPixelViewY, mMapDrawType);
+ }
+ if (mMapDrawType == MapType::DEBUG)
drawDebugPath(graphics);
}
@@ -990,13 +993,13 @@ void Viewport::mouseMoved(MouseEvent &event A_UNUSED)
}
}
-void Viewport::toggleDebugPath()
+void Viewport::toggleMapDrawType()
{
- mShowDebugPath++;
- if (mShowDebugPath > MapType::BLACKWHITE)
- mShowDebugPath = MapType::NORMAL;
+ mMapDrawType++;
+ if (mMapDrawType > MapType::BLACKWHITE)
+ mMapDrawType = MapType::NORMAL;
if (mMap)
- mMap->setDebugFlags(mShowDebugPath);
+ mMap->setDrawLayersFlags(mMapDrawType);
}
void Viewport::toggleCameraMode()
diff --git a/src/gui/viewport.h b/src/gui/viewport.h
index d401a3af4..4a7abea93 100644
--- a/src/gui/viewport.h
+++ b/src/gui/viewport.h
@@ -96,7 +96,7 @@ class Viewport final : public WindowContainer,
* debug with all images and grid, debug with out big images
* and with out grid.
*/
- void toggleDebugPath();
+ void toggleMapDrawType();
void toggleCameraMode();
@@ -242,11 +242,11 @@ class Viewport final : public WindowContainer,
void scrollBy(const int x, const int y)
{ mPixelViewX += x; mPixelViewY += y; }
- int getDebugPath() const A_WARN_UNUSED
- { return mShowDebugPath; }
+ int getMapDrawType() const A_WARN_UNUSED
+ { return mMapDrawType; }
- void setDebugPath(const int n)
- { mShowDebugPath = n; }
+ void setMapDrawType(const int n)
+ { mMapDrawType = n; }
int getCameraMode() const A_WARN_UNUSED
{ return mCameraMode; }
@@ -344,7 +344,7 @@ class Viewport final : public WindowContainer,
int mMousePressY;
int mPixelViewX; /**< Current viewpoint in pixels. */
int mPixelViewY; /**< Current viewpoint in pixels. */
- int mShowDebugPath; /**< Show a path from player to pointer. */
+ int mMapDrawType; /**< Show a path from player to pointer. */
int mCameraMode; /**< Camera mode. */
int mLocalWalkTime; /**< Timestamp before the next walk can be sent. */
diff --git a/src/gui/windows/statuswindow.cpp b/src/gui/windows/statuswindow.cpp
index 4a4c82cf6..bf2e92e0b 100644
--- a/src/gui/windows/statuswindow.cpp
+++ b/src/gui/windows/statuswindow.cpp
@@ -654,7 +654,7 @@ void StatusWindow::updateStatusBar(ProgressBar *const bar,
player_node->getQuickDropCounterString()))
.append(translateLetter2(player_node->getPickUpTypeString()))
.append(" ").append(translateLetter2(
- LocalPlayer::getDebugPathString()))
+ LocalPlayer::getMapDrawTypeString()))
.append(" ").append(translateLetter2(
player_node->getImitationModeString()))
.append(translateLetter2(LocalPlayer::getCameraModeString()))