From 594c7c3eb13695304c755ec1bc65c5f239754222 Mon Sep 17 00:00:00 2001 From: Adam Frisby Date: Tue, 21 Apr 2009 04:55:53 +0000 Subject: * Implements Extensions to MRM. This allows Region Modules to insert new classes into OpenSim MRM's. * Example in region module: Scene.GetModuleInterface.RegisterExtension(this); * In the MRM: //@DEPENDS:MyExtensionModule.dll ... Host.Extensions.DoStuff(); --- OpenSim/Region/OptionalModules/Scripting/Minimodule/Host.cs | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'OpenSim/Region/OptionalModules/Scripting/Minimodule/Host.cs') diff --git a/OpenSim/Region/OptionalModules/Scripting/Minimodule/Host.cs b/OpenSim/Region/OptionalModules/Scripting/Minimodule/Host.cs index b7f67dd..94796e4 100644 --- a/OpenSim/Region/OptionalModules/Scripting/Minimodule/Host.cs +++ b/OpenSim/Region/OptionalModules/Scripting/Minimodule/Host.cs @@ -28,6 +28,7 @@ using System.Reflection; using log4net; using OpenSim.Region.Framework.Scenes; +using OpenSim.Region.OptionalModules.Scripting.Minimodule.Interfaces; namespace OpenSim.Region.OptionalModules.Scripting.Minimodule { @@ -36,11 +37,13 @@ namespace OpenSim.Region.OptionalModules.Scripting.Minimodule private readonly IObject m_obj; private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); private readonly IGraphics m_graphics; + private readonly IExtension m_extend; //private Scene m_scene; - public Host(IObject m_obj, Scene m_scene) + public Host(IObject m_obj, Scene m_scene, IExtension m_extend) { this.m_obj = m_obj; + this.m_extend = m_extend; //this.m_scene = m_scene; m_graphics = new Graphics(m_scene); @@ -60,5 +63,10 @@ namespace OpenSim.Region.OptionalModules.Scripting.Minimodule { get { return m_graphics; } } + + public IExtension Extensions + { + get { return m_extend; } + } } } -- cgit v1.1