make asset checker default inactive

master
Christopher 2020-06-28 16:15:29 +02:00
parent 789d658f4a
commit 334039f22c
1 changed files with 21 additions and 10 deletions

View File

@ -22,7 +22,10 @@ namespace OpenSim.Modules.TextureFetcher
private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
Scene m_scene = null;
private IConfigSource m_config;
List<UUID> m_textureBlackList = new List<UUID>();
bool m_checkTexture = false;
public string Name
{
@ -43,7 +46,12 @@ namespace OpenSim.Modules.TextureFetcher
public void Initialise(IConfigSource source)
{
m_config = source;
if (m_config.Configs["Startup"] != null)
{
m_checkTexture = m_config.Configs["Startup"].GetBoolean("TextureFetcherCheckAssets", m_checkTexture);
}
}
public Type ReplaceableInterface
@ -140,6 +148,8 @@ namespace OpenSim.Modules.TextureFetcher
}
//Remove not existing textures
if(m_checkTexture == true)
{
String[] _assetIDs = new string[allTextures.Count];
for (int i = 0; i < allTextures.Count; i++)
_assetIDs[i] = allTextures[i].ToString();
@ -151,6 +161,7 @@ namespace OpenSim.Modules.TextureFetcher
m_textureBlackList.Add(allTextures[i]);
allTextures[i] = UUID.Zero;
}
}
//Convert texture uuid list to inventar items.
foreach (UUID texture in allTextures)