mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-09-24 04:11:50 -04:00
Account for view distance changes
This commit is contained in:
parent
50601b7733
commit
423261b721
@ -216,7 +216,6 @@ namespace MWGui
|
|||||||
mLocalMap = widget;
|
mLocalMap = widget;
|
||||||
mCompass = compass;
|
mCompass = compass;
|
||||||
mGrid = createRect({ 0, 0 }, cellDistance);
|
mGrid = createRect({ 0, 0 }, cellDistance);
|
||||||
mExtCellDistance = cellDistance;
|
|
||||||
|
|
||||||
const int mapWidgetSize = Settings::map().mLocalMapWidgetSize;
|
const int mapWidgetSize = Settings::map().mLocalMapWidgetSize;
|
||||||
setCanvasSize(mLocalMap, mGrid, mapWidgetSize);
|
setCanvasSize(mLocalMap, mGrid, mapWidgetSize);
|
||||||
@ -398,7 +397,7 @@ namespace MWGui
|
|||||||
if (mActiveCell && mActiveCell->isExterior())
|
if (mActiveCell && mActiveCell->isExterior())
|
||||||
previousActiveGrid
|
previousActiveGrid
|
||||||
= createRect({ mActiveCell->getGridX(), mActiveCell->getGridY() }, Constants::CellGridRadius);
|
= createRect({ mActiveCell->getGridX(), mActiveCell->getGridY() }, Constants::CellGridRadius);
|
||||||
mGrid = createRect({ x, y }, mExtCellDistance);
|
mGrid = createRect({ x, y }, getLocalViewingDistance());
|
||||||
const MyGUI::IntRect activeGrid = createRect({ x, y }, Constants::CellGridRadius);
|
const MyGUI::IntRect activeGrid = createRect({ x, y }, Constants::CellGridRadius);
|
||||||
|
|
||||||
mExteriorDoorMarkerWidgets.clear();
|
mExteriorDoorMarkerWidgets.clear();
|
||||||
|
@ -184,7 +184,6 @@ namespace MWGui
|
|||||||
MWGui::LocalMapBase::MapEntry& addMapEntry();
|
MWGui::LocalMapBase::MapEntry& addMapEntry();
|
||||||
|
|
||||||
MyGUI::IntRect mGrid{ -1, -1, 1, 1 };
|
MyGUI::IntRect mGrid{ -1, -1, 1, 1 };
|
||||||
int mExtCellDistance = 0;
|
|
||||||
float mMarkerUpdateTimer = 0.f;
|
float mMarkerUpdateTimer = 0.f;
|
||||||
|
|
||||||
float mLastDirectionX = 0.f;
|
float mLastDirectionX = 0.f;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user