a few more changes on Multiregion control file load
parent
a6187db2a7
commit
b80cbf5060
|
@ -1150,7 +1150,7 @@ namespace OpenSim.Region.CoreModules.World.Archiver
|
||||||
|
|
||||||
m_log.InfoFormat("[ARCHIVER]: Loading OAR with version {0}", version);
|
m_log.InfoFormat("[ARCHIVER]: Loading OAR with version {0}", version);
|
||||||
}
|
}
|
||||||
if (xtr.Name.ToString() == "datetime")
|
else if (xtr.Name.ToString() == "datetime")
|
||||||
{
|
{
|
||||||
int value;
|
int value;
|
||||||
if (Int32.TryParse(xtr.ReadElementContentAsString(), out value))
|
if (Int32.TryParse(xtr.ReadElementContentAsString(), out value))
|
||||||
|
@ -1183,21 +1183,24 @@ namespace OpenSim.Region.CoreModules.World.Archiver
|
||||||
if (Vector3.TryParse(size, out value))
|
if (Vector3.TryParse(size, out value))
|
||||||
{
|
{
|
||||||
m_incomingRegionSize = value;
|
m_incomingRegionSize = value;
|
||||||
|
if(multiRegion)
|
||||||
dearchivedScenes.SetRegionSize(m_incomingRegionSize);
|
dearchivedScenes.SetRegionSize(m_incomingRegionSize);
|
||||||
m_log.DebugFormat("[ARCHIVER]: Found region_size info {0}", m_incomingRegionSize.ToString());
|
m_log.DebugFormat("[ARCHIVER]: Found region_size info {0}",
|
||||||
|
m_incomingRegionSize.ToString());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
dearchivedScenes.MultiRegionFormat = multiRegion;
|
dearchivedScenes.MultiRegionFormat = multiRegion;
|
||||||
if (!multiRegion && dearchivedScenes.GetScenesCount() == 0)
|
if (!multiRegion)
|
||||||
{
|
{
|
||||||
// Add the single scene
|
// Add the single scene
|
||||||
dearchivedScenes.StartRow();
|
dearchivedScenes.StartRow();
|
||||||
dearchivedScenes.StartRegion();
|
dearchivedScenes.StartRegion();
|
||||||
dearchivedScenes.SetRegionOriginalID(dearchivedScenes.DefaultOriginalID);
|
dearchivedScenes.SetRegionOriginalID(dearchivedScenes.DefaultOriginalID);
|
||||||
dearchivedScenes.SetRegionDirectory("");
|
dearchivedScenes.SetRegionDirectory("");
|
||||||
|
dearchivedScenes.SetRegionSize(m_incomingRegionSize);
|
||||||
}
|
}
|
||||||
|
|
||||||
ControlFileLoaded = true;
|
ControlFileLoaded = true;
|
||||||
|
|
|
@ -129,19 +129,26 @@ namespace OpenSim.Region.CoreModules.World.Archiver
|
||||||
public void SetRegionOriginalID(string id)
|
public void SetRegionOriginalID(string id)
|
||||||
{
|
{
|
||||||
m_curRegion = new RegionInfo();
|
m_curRegion = new RegionInfo();
|
||||||
m_curRegion.Location = new Point((int)m_curX, (int)m_curY);
|
int x = (int)((m_curX == null) ? 0 : m_curX);
|
||||||
|
int y = (int)((m_curY == null) ? 0 : m_curY);
|
||||||
|
|
||||||
|
m_curRegion.Location = new Point(x, y);
|
||||||
m_curRegion.OriginalID = id;
|
m_curRegion.OriginalID = id;
|
||||||
// 'curRegion' will be saved in 'm_directory2region' when SetRegionDir() is called
|
// 'curRegion' will be saved in 'm_directory2region' when SetRegionDir() is called
|
||||||
}
|
}
|
||||||
|
|
||||||
public void SetRegionDirectory(string directory)
|
public void SetRegionDirectory(string directory)
|
||||||
|
{
|
||||||
|
if(m_curRegion != null)
|
||||||
{
|
{
|
||||||
m_curRegion.Directory = directory;
|
m_curRegion.Directory = directory;
|
||||||
m_directory2region[directory] = m_curRegion;
|
m_directory2region[directory] = m_curRegion;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public void SetRegionSize(Vector3 size)
|
public void SetRegionSize(Vector3 size)
|
||||||
{
|
{
|
||||||
|
if(m_curRegion != null)
|
||||||
m_curRegion.RegionSize = size;
|
m_curRegion.RegionSize = size;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue