MRM Scripting Changes
* Renames MiniRegionModule to MRMModule to make it more distinct from the actual Mini Region Module[s] executed in Scene. * Renames MiniRegionModuleBase to MRMBase for convenience. MRM's need to be adjusted to inherit from MRMBase.0.6.4-rc1
parent
0e7e2eba14
commit
65990de390
|
@ -1,6 +1,6 @@
|
||||||
namespace OpenSim.Region.OptionalModules.Scripting.Minimodule
|
namespace OpenSim.Region.OptionalModules.Scripting.Minimodule
|
||||||
{
|
{
|
||||||
public abstract class MiniModuleBase
|
public abstract class MRMBase
|
||||||
{
|
{
|
||||||
private IWorld m_world;
|
private IWorld m_world;
|
||||||
private IHost m_host;
|
private IHost m_host;
|
|
@ -13,12 +13,12 @@ using OpenSim.Region.Framework.Scenes;
|
||||||
|
|
||||||
namespace OpenSim.Region.OptionalModules.Scripting.Minimodule
|
namespace OpenSim.Region.OptionalModules.Scripting.Minimodule
|
||||||
{
|
{
|
||||||
public class MiniModule : IRegionModule
|
public class MRMModule : IRegionModule
|
||||||
{
|
{
|
||||||
private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
|
private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
|
||||||
private Scene m_scene;
|
private Scene m_scene;
|
||||||
|
|
||||||
private readonly Dictionary<UUID,MiniModuleBase> m_scripts = new Dictionary<UUID, MiniModuleBase>();
|
private readonly Dictionary<UUID,MRMBase> m_scripts = new Dictionary<UUID, MRMBase>();
|
||||||
|
|
||||||
private static readonly CSharpCodeProvider CScodeProvider = new CSharpCodeProvider();
|
private static readonly CSharpCodeProvider CScodeProvider = new CSharpCodeProvider();
|
||||||
|
|
||||||
|
@ -51,7 +51,7 @@ namespace OpenSim.Region.OptionalModules.Scripting.Minimodule
|
||||||
IWorld m_world = new World(m_scene);
|
IWorld m_world = new World(m_scene);
|
||||||
IHost m_host = new Host(new SOPObject(m_scene, localID));
|
IHost m_host = new Host(new SOPObject(m_scene, localID));
|
||||||
|
|
||||||
MiniModuleBase mmb = (MiniModuleBase) AppDomain.CurrentDomain.CreateInstanceFromAndUnwrap(
|
MRMBase mmb = (MRMBase) AppDomain.CurrentDomain.CreateInstanceFromAndUnwrap(
|
||||||
CompileFromDotNetText(script, itemID.ToString()),
|
CompileFromDotNetText(script, itemID.ToString()),
|
||||||
"OpenSim.MiniModule");
|
"OpenSim.MiniModule");
|
||||||
m_log.Info("[MRM] Created MRM Instance");
|
m_log.Info("[MRM] Created MRM Instance");
|
||||||
|
@ -70,7 +70,7 @@ namespace OpenSim.Region.OptionalModules.Scripting.Minimodule
|
||||||
|
|
||||||
public void Close()
|
public void Close()
|
||||||
{
|
{
|
||||||
foreach (KeyValuePair<UUID, MiniModuleBase> pair in m_scripts)
|
foreach (KeyValuePair<UUID, MRMBase> pair in m_scripts)
|
||||||
{
|
{
|
||||||
pair.Value.Stop();
|
pair.Value.Stop();
|
||||||
}
|
}
|
||||||
|
@ -78,7 +78,7 @@ namespace OpenSim.Region.OptionalModules.Scripting.Minimodule
|
||||||
|
|
||||||
public string Name
|
public string Name
|
||||||
{
|
{
|
||||||
get { return "MiniScriptModule"; }
|
get { return "MiniRegionModule"; }
|
||||||
}
|
}
|
||||||
|
|
||||||
public bool IsSharedModule
|
public bool IsSharedModule
|
|
@ -86,8 +86,8 @@ namespace OpenSim.Region.OptionalModules.Scripting.Minimodule
|
||||||
|
|
||||||
public Vector3 Scale
|
public Vector3 Scale
|
||||||
{
|
{
|
||||||
get { throw new System.NotImplementedException(); }
|
get { return GetSOP().Scale; }
|
||||||
set { throw new System.NotImplementedException(); }
|
set { GetSOP().Scale = value; }
|
||||||
}
|
}
|
||||||
|
|
||||||
public Quaternion Rotation
|
public Quaternion Rotation
|
||||||
|
|
Loading…
Reference in New Issue