An OpenMW mod that lets you play the whole Elder Scrolls III: Morrowind as a top-down isometric game — with full online co-op or MMO modes.
C++
Local map with a controller: the slower pointer and the bigger door markers of the world map
pw-tfa25ea498f6cb
diff --git a/apps/openmw/mwgui/mapwindow.cpp b/apps/openmw/mwgui/mapwindow.cppindex e79f639..fc1ec12 100644--- a/apps/openmw/mwgui/mapwindow.cpp+++ b/apps/openmw/mwgui/mapwindow.cpp@@ -328,7 +328,7 @@ namespace MWGuiMarkerUserData data(mLocalMapRender);data.caption = name;MarkerWidget* markerWidget = mLocalMap->createWidget<MarkerWidget>(- "MarkerButton", getMarkerCoordinates(x, y, data, markerSize(8)), MyGUI::Align::Default);+ "MarkerButton", getMarkerCoordinates(x, y, data, doorMarkerSize()), MyGUI::Align::Default);markerWidget->setNormalColour(MyGUI::Colour::parse(MyGUI::LanguageManager::getInstance().replaceTags("#{fontcolour=normal}")));markerWidget->setHoverColour(@@ -522,7 +522,7 @@ namespace MWGuimNeedDoorMarkersUpdate = true;for (MyGUI::Widget* widget : currentDoorMarkersWidgets())- updateMarkerCoordinates(widget, 8);+ updateMarkerCoordinates(widget, doorMarkerSize());updateMagicMarkers();updateCustomMarkers();@@ -745,7 +745,7 @@ namespace MWGuidata = markerWidget->getUserData<MarkerUserData>();data->notes = std::move(destNotes);data->caption = marker.name;- markerWidget->setCoord(getMarkerCoordinates(marker.x, marker.y, *data, markerSize(8)));+ markerWidget->setCoord(getMarkerCoordinates(marker.x, marker.y, *data, doorMarkerSize()));markerWidget->setVisible(true);}@@ -755,7 +755,7 @@ namespace MWGui}for (MyGUI::Widget* widget : currentDoorMarkersWidgets())- updateMarkerCoordinates(widget, 8);+ updateMarkerCoordinates(widget, doorMarkerSize());}void LocalMapBase::updateMagicMarkers()@@ -852,7 +852,7 @@ namespace MWGuiMarkerUserData markerPos(mLocalMapRender);for (MyGUI::Widget* widget : currentDoorMarkersWidgets())- updateMarkerCoordinates(widget, markerSize(8));+ updateMarkerCoordinates(widget, doorMarkerSize());for (MyGUI::Widget* widget : mCustomMarkerWidgets){diff --git a/apps/openmw/mwgui/mapwindow.hpp b/apps/openmw/mwgui/mapwindow.hppindex 6cecd79..3219c22 100644--- a/apps/openmw/mwgui/mapwindow.hpp+++ b/apps/openmw/mwgui/mapwindow.hpp@@ -129,6 +129,8 @@ namespace MWGuibool mBigMarkers = false;int markerSize(int size) const { return mBigMarkers ? size + sBigMarkerExtra : size; }static constexpr int sBigMarkerExtra = 6;+ // The doors' squares on the local map: as big as the towns' on the world map (MapWindow::getMarkerSize)+ int doorMarkerSize() const { return mBigMarkers ? 12 + sBigMarkerExtra : 8; }// Stores markers that were placed by a player. May be shared between multiple map views.CustomMarkerCollection& mCustomMarkers;diff --git a/apps/openmw/mwgui/windowmanagerimp.cpp b/apps/openmw/mwgui/windowmanagerimp.cppindex 526dc92..4f10dad 100644--- a/apps/openmw/mwgui/windowmanagerimp.cpp+++ b/apps/openmw/mwgui/windowmanagerimp.cpp@@ -1970,8 +1970,9 @@ namespace MWGuifloat WindowManager::getControllerCursorSpeedScale(){- if (Settings::gui().mControllerMenus && Settings::map().mGlobal && getMode() == GM_Inventory- && getActiveControllerWindow() == mMap)+ // The pointer the stick moves goes slower over the maps (the local map and the world map alike), so it can+ // be put on a door or a town+ if (Settings::gui().mControllerMenus && getMode() == GM_Inventory && getActiveControllerWindow() == mMap)return 0.45f;return 1.f;}