refactor: Actually use MaptileStaticFile in RegionInfo rather than having both a public field and a get property

This commit is contained in:
Justin Clark-Casey (justincc)
2014-03-26 20:58:58 +00:00
parent 7a4c5b067d
commit b0bae62c30
2 changed files with 16 additions and 14 deletions

View File

@@ -91,7 +91,7 @@ namespace OpenSim.Region.CoreModules.World.LegacyMap
if (generateMaptiles)
{
if (String.IsNullOrEmpty(m_scene.RegionInfo.m_maptileStaticFile))
if (String.IsNullOrEmpty(m_scene.RegionInfo.MaptileStaticFile))
{
if (textureTerrain)
{
@@ -122,15 +122,21 @@ namespace OpenSim.Region.CoreModules.World.LegacyMap
{
try
{
mapbmp = new Bitmap(m_scene.RegionInfo.m_maptileStaticFile);
mapbmp = new Bitmap(m_scene.RegionInfo.MaptileStaticFile);
}
catch (Exception e)
{
m_log.ErrorFormat("[MAPTILE]: Failed to load Static map image texture file: {0} for {1}", m_scene.RegionInfo.m_maptileStaticFile, m_scene.Name);
m_log.ErrorFormat(
"[MAPTILE]: Failed to load Static map image texture file: {0} for {1}",
m_scene.RegionInfo.MaptileStaticFile, m_scene.Name);
//mapbmp = new Bitmap((int)m_scene.Heightmap.Width, (int)m_scene.Heightmap.Height, System.Drawing.Imaging.PixelFormat.Format24bppRgb);
mapbmp = null;
}
if (mapbmp != null) m_log.DebugFormat("[MAPTILE]: Static map image texture file {0} found for {1}", m_scene.RegionInfo.m_maptileStaticFile, m_scene.Name);
if (mapbmp != null)
m_log.DebugFormat(
"[MAPTILE]: Static map image texture file {0} found for {1}",
m_scene.RegionInfo.MaptileStaticFile, m_scene.Name);
}
}
else