diff --git a/OpenSim/Region/CoreModules/Agent/Capabilities/CapabilitiesModule.cs b/OpenSim/Region/CoreModules/Agent/Capabilities/CapabilitiesModule.cs index dbd510422f..eba077ed2e 100644 --- a/OpenSim/Region/CoreModules/Agent/Capabilities/CapabilitiesModule.cs +++ b/OpenSim/Region/CoreModules/Agent/Capabilities/CapabilitiesModule.cs @@ -38,7 +38,7 @@ using Caps=OpenSim.Framework.Communications.Capabilities.Caps; namespace OpenSim.Region.CoreModules.Agent.Capabilities { - public class CapabilitiesModule : IRegionModule, ICapabilitiesModule + public class CapabilitiesModule : INonSharedRegionModule, ICapabilitiesModule { private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); @@ -53,16 +53,33 @@ namespace OpenSim.Region.CoreModules.Agent.Capabilities protected Dictionary> childrenSeeds = new Dictionary>(); - public void Initialise(Scene scene, IConfigSource source) + public void Initialise(IConfigSource source) + { + } + + public void AddRegion(Scene scene) { m_scene = scene; m_scene.RegisterModuleInterface(this); } + + public void RegionLoaded(Scene scene) + { + } + + public void RemoveRegion(Scene scene) + { + m_scene.UnregisterModuleInterface(this); + } public void PostInitialise() {} + public void Close() {} - public string Name { get { return "Capabilities Module"; } } - public bool IsSharedModule { get { return false; } } + + public string Name + { + get { return "Capabilities Module"; } + } public void AddCapsHandler(UUID agentId) { @@ -86,7 +103,7 @@ namespace OpenSim.Region.CoreModules.Agent.Capabilities Caps caps = new Caps( - m_scene.AssetService, m_scene.CommsManager.HttpServer, m_scene.RegionInfo.ExternalHostName, + m_scene.AssetService, m_scene.CommsManager.HttpServer, m_scene.RegionInfo.ExternalHostName, m_scene.CommsManager.HttpServer.Port, capsObjectPath, agentId, m_scene.DumpAssetsToFile, m_scene.RegionInfo.RegionName); diff --git a/OpenSim/Region/CoreModules/Resources/CoreModulePlugin.addin.xml b/OpenSim/Region/CoreModules/Resources/CoreModulePlugin.addin.xml index 6c80598e20..b71b7ee4be 100644 --- a/OpenSim/Region/CoreModules/Resources/CoreModulePlugin.addin.xml +++ b/OpenSim/Region/CoreModules/Resources/CoreModulePlugin.addin.xml @@ -8,6 +8,7 @@ + diff --git a/OpenSim/Tests/Common/Setup/SceneSetupHelpers.cs b/OpenSim/Tests/Common/Setup/SceneSetupHelpers.cs index 413a2b946f..6de5a021e0 100644 --- a/OpenSim/Tests/Common/Setup/SceneSetupHelpers.cs +++ b/OpenSim/Tests/Common/Setup/SceneSetupHelpers.cs @@ -117,9 +117,10 @@ namespace OpenSim.Tests.Common.Setup TestScene testScene = new TestScene( regInfo, acm, cm, scs, sm, null, false, false, false, configSource, null); - IRegionModule capsModule = new CapabilitiesModule(); - capsModule.Initialise(testScene, new IniConfigSource()); - testScene.AddModule(capsModule.Name, capsModule); + INonSharedRegionModule capsModule = new CapabilitiesModule(); + capsModule.Initialise(new IniConfigSource()); + testScene.AddRegionModule(capsModule.Name, capsModule); + capsModule.AddRegion(testScene); IRegionModule godsModule = new GodsModule(); godsModule.Initialise(testScene, new IniConfigSource());