forked from mirror/openmw-tes3mp
Replace "sys::default" with ESM::CellId::sDefaultWorldspace
This commit is contained in:
parent
96757a3b7c
commit
b9b73d7b12
9 changed files with 16 additions and 10 deletions
|
@ -2,6 +2,8 @@
|
|||
|
||||
#include <stdexcept>
|
||||
|
||||
#include <components/esm/cellid.hpp>
|
||||
|
||||
#include "collectionbase.hpp"
|
||||
#include "columnbase.hpp"
|
||||
|
||||
|
@ -259,7 +261,7 @@ std::pair<CSMWorld::UniversalId, std::string> CSMWorld::IdTable::view (int row)
|
|||
return std::make_pair (UniversalId::Type_None, "");
|
||||
|
||||
if (id[0]=='#')
|
||||
id = "sys::default";
|
||||
id = ESM::CellId::sDefaultWorldspace;
|
||||
|
||||
return std::make_pair (UniversalId (UniversalId::Type_Scene, id), hint);
|
||||
}
|
||||
|
|
|
@ -303,7 +303,7 @@ void CSVWorld::RegionMap::view()
|
|||
hint << cellId;
|
||||
}
|
||||
|
||||
emit editRequest (CSMWorld::UniversalId (CSMWorld::UniversalId::Type_Scene, "sys::default"),
|
||||
emit editRequest (CSMWorld::UniversalId (CSMWorld::UniversalId::Type_Scene, ESM::CellId::sDefaultWorldspace),
|
||||
hint.str());
|
||||
}
|
||||
|
||||
|
|
|
@ -38,7 +38,7 @@ CSVWorld::SceneSubView::SceneSubView (const CSMWorld::UniversalId& id, CSMDoc::D
|
|||
CSVRender::WorldspaceWidget* worldspaceWidget = NULL;
|
||||
widgetType whatWidget;
|
||||
|
||||
if (id.getId()=="sys::default")
|
||||
if (id.getId()==ESM::CellId::sDefaultWorldspace)
|
||||
{
|
||||
whatWidget = widget_Paged;
|
||||
|
||||
|
@ -160,7 +160,7 @@ void CSVWorld::SceneSubView::cellSelectionChanged (const CSMWorld::UniversalId&
|
|||
|
||||
void CSVWorld::SceneSubView::cellSelectionChanged (const CSMWorld::CellSelection& selection)
|
||||
{
|
||||
setUniversalId(CSMWorld::UniversalId(CSMWorld::UniversalId::Type_Scene, "sys::default"));
|
||||
setUniversalId(CSMWorld::UniversalId(CSMWorld::UniversalId::Type_Scene, ESM::CellId::sDefaultWorldspace));
|
||||
int size = selection.getSize();
|
||||
|
||||
std::ostringstream stream;
|
||||
|
|
|
@ -322,7 +322,7 @@ namespace MWGui
|
|||
{
|
||||
ESM::CellId cellId;
|
||||
cellId.mPaged = !mInterior;
|
||||
cellId.mWorldspace = (mInterior ? mPrefix : "sys::default");
|
||||
cellId.mWorldspace = (mInterior ? mPrefix : ESM::CellId::sDefaultWorldspace);
|
||||
cellId.mIndex.mX = mCurX+dX;
|
||||
cellId.mIndex.mY = mCurY+dY;
|
||||
|
||||
|
@ -738,7 +738,7 @@ namespace MWGui
|
|||
mEditingMarker.mCell.mWorldspace = LocalMapBase::mPrefix;
|
||||
else
|
||||
{
|
||||
mEditingMarker.mCell.mWorldspace = "sys::default";
|
||||
mEditingMarker.mCell.mWorldspace = ESM::CellId::sDefaultWorldspace;
|
||||
mEditingMarker.mCell.mIndex.mX = x;
|
||||
mEditingMarker.mCell.mIndex.mY = y;
|
||||
}
|
||||
|
@ -848,7 +848,7 @@ namespace MWGui
|
|||
ESM::CellId cellId;
|
||||
cellId.mIndex.mX = x;
|
||||
cellId.mIndex.mY = y;
|
||||
cellId.mWorldspace = "sys::default";
|
||||
cellId.mWorldspace = ESM::CellId::sDefaultWorldspace;
|
||||
cellId.mPaged = true;
|
||||
CustomMarkerCollection::RangeType markers = mCustomMarkers.getMarkers(cellId);
|
||||
std::vector<std::string> destNotes;
|
||||
|
|
|
@ -105,7 +105,7 @@ MWWorld::CellStore *MWWorld::Cells::getExterior (int x, int y)
|
|||
{
|
||||
// Cell isn't predefined. Make one on the fly.
|
||||
ESM::Cell record;
|
||||
record.mCellId.mWorldspace = "sys::default";
|
||||
record.mCellId.mWorldspace = ESM::CellId::sDefaultWorldspace;
|
||||
record.mCellId.mPaged = true;
|
||||
record.mCellId.mIndex.mX = x;
|
||||
record.mCellId.mIndex.mY = y;
|
||||
|
|
|
@ -972,7 +972,7 @@ namespace MWWorld
|
|||
{
|
||||
mPhysics->clearQueuedMovement();
|
||||
|
||||
if (changeEvent && mCurrentWorldSpace != "sys::default") // FIXME
|
||||
if (changeEvent && mCurrentWorldSpace != ESM::CellId::sDefaultWorldspace)
|
||||
{
|
||||
// changed worldspace
|
||||
mProjectileManager->clear();
|
||||
|
|
|
@ -3,6 +3,8 @@
|
|||
#include "esmreader.hpp"
|
||||
#include "esmwriter.hpp"
|
||||
|
||||
const std::string ESM::CellId::sDefaultWorldspace = "sys::default";
|
||||
|
||||
void ESM::CellId::load (ESMReader &esm)
|
||||
{
|
||||
mWorldspace = esm.getHNString ("SPAC");
|
||||
|
|
|
@ -20,6 +20,8 @@ namespace ESM
|
|||
CellIndex mIndex;
|
||||
bool mPaged;
|
||||
|
||||
static const std::string sDefaultWorldspace;
|
||||
|
||||
void load (ESMReader &esm);
|
||||
void save (ESMWriter &esm) const;
|
||||
};
|
||||
|
|
|
@ -96,7 +96,7 @@ namespace ESM
|
|||
|
||||
if (mCellId.mPaged)
|
||||
{
|
||||
mCellId.mWorldspace = "sys::default";
|
||||
mCellId.mWorldspace = ESM::CellId::sDefaultWorldspace;
|
||||
mCellId.mIndex.mX = mData.mX;
|
||||
mCellId.mIndex.mY = mData.mY;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue