mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-02-02 02:45:32 +00:00
set map window cell name
This commit is contained in:
parent
5b38b17baf
commit
fa68be2b19
3 changed files with 20 additions and 0 deletions
|
@ -401,3 +401,8 @@ const ESMS::ESMStore& WindowManager::getStore() const
|
||||||
{
|
{
|
||||||
return environment.mWorld->getStore();
|
return environment.mWorld->getStore();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void WindowManager::setCellName(const std::string& cellName)
|
||||||
|
{
|
||||||
|
map->setCellName(cellName);
|
||||||
|
}
|
||||||
|
|
|
@ -151,6 +151,8 @@ namespace MWGui
|
||||||
void updateSkillArea(); ///< update display of skills, factions, birth sign, reputation and bounty
|
void updateSkillArea(); ///< update display of skills, factions, birth sign, reputation and bounty
|
||||||
|
|
||||||
|
|
||||||
|
void setCellName(const std::string& cellName); ///< set the cell name to display in the map window
|
||||||
|
|
||||||
template<typename T>
|
template<typename T>
|
||||||
void removeDialog(T*& dialog); ///< Casts to OEngine::GUI::Layout and calls removeDialog, then resets pointer to nullptr.
|
void removeDialog(T*& dialog); ///< Casts to OEngine::GUI::Layout and calls removeDialog, then resets pointer to nullptr.
|
||||||
void removeDialog(OEngine::GUI::Layout* dialog); ///< Hides dialog and schedules dialog to be deleted.
|
void removeDialog(OEngine::GUI::Layout* dialog); ///< Hides dialog and schedules dialog to be deleted.
|
||||||
|
|
|
@ -6,6 +6,8 @@
|
||||||
|
|
||||||
#include "../mwsound/soundmanager.hpp"
|
#include "../mwsound/soundmanager.hpp"
|
||||||
|
|
||||||
|
#include "../mwgui/window_manager.hpp"
|
||||||
|
|
||||||
#include "ptr.hpp"
|
#include "ptr.hpp"
|
||||||
#include "environment.hpp"
|
#include "environment.hpp"
|
||||||
#include "player.hpp"
|
#include "player.hpp"
|
||||||
|
@ -118,6 +120,17 @@ namespace MWWorld
|
||||||
// TODO orientation
|
// TODO orientation
|
||||||
mEnvironment.mMechanicsManager->addActor (mWorld->getPlayer().getPlayer());
|
mEnvironment.mMechanicsManager->addActor (mWorld->getPlayer().getPlayer());
|
||||||
mEnvironment.mMechanicsManager->watchActor (mWorld->getPlayer().getPlayer());
|
mEnvironment.mMechanicsManager->watchActor (mWorld->getPlayer().getPlayer());
|
||||||
|
|
||||||
|
// set map window cell name
|
||||||
|
if (!(mCurrentCell->cell->data.flags & ESM::Cell::Interior))
|
||||||
|
{
|
||||||
|
if (mCurrentCell->cell->name != "")
|
||||||
|
mEnvironment.mWindowManager->setCellName( mCurrentCell->cell->name );
|
||||||
|
else
|
||||||
|
mEnvironment.mWindowManager->setCellName( mCurrentCell->cell->region );
|
||||||
|
}
|
||||||
|
else
|
||||||
|
mEnvironment.mWindowManager->setCellName( mCurrentCell->cell->name );
|
||||||
}
|
}
|
||||||
|
|
||||||
void Scene::changeCell (int X, int Y, const ESM::Position& position, bool adjustPlayerPos)
|
void Scene::changeCell (int X, int Y, const ESM::Position& position, bool adjustPlayerPos)
|
||||||
|
|
Loading…
Reference in a new issue