Make it possible to disable the bakes module in the way it is described in config comments

melanie
Melanie Thielker 2017-01-05 18:53:02 +00:00
parent a0c9f84994
commit e88e2945e9
1 changed files with 10 additions and 1 deletions

View File

@ -53,6 +53,7 @@ namespace OpenSim.Region.CoreModules.Avatar.BakedTextures
private UTF8Encoding enc = new UTF8Encoding();
private string m_URL = String.Empty;
private static XmlSerializer m_serializer = new XmlSerializer(typeof(AssetBase));
private static bool m_enabled = false;
private static IServiceAuth m_Auth;
@ -63,11 +64,19 @@ namespace OpenSim.Region.CoreModules.Avatar.BakedTextures
return;
m_URL = config.GetString("URL", String.Empty);
if (m_URL == String.Empty)
return;
m_enabled = true;
m_Auth = ServiceAuth.Create(configSource, "XBakes");
}
public void AddRegion(Scene scene)
{
if (!m_enabled)
return;
// m_log.InfoFormat("[XBakes]: Enabled for region {0}", scene.RegionInfo.RegionName);
m_Scene = scene;