* Rewired Touch to route to group/part (Still triggering EventManager as well)
parent
4ce0c0794a
commit
3c7161d128
|
@ -516,6 +516,20 @@ namespace OpenSim.Region.Environment.Scenes
|
|||
public virtual void ProcessObjectGrab(uint localID, LLVector3 offsetPos, IClientAPI remoteClient)
|
||||
{
|
||||
EventManager.TriggerObjectGrab(localID, offsetPos, remoteClient);
|
||||
|
||||
foreach (EntityBase ent in Entities.Values)
|
||||
{
|
||||
if (ent is SceneObjectGroup)
|
||||
{
|
||||
SceneObjectGroup obj = ent as SceneObjectGroup;
|
||||
|
||||
if( obj.HasChildPrim( localID ) )
|
||||
{
|
||||
obj.ObjectGrabHandler(localID, offsetPos, remoteClient);
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -133,8 +133,10 @@ namespace OpenSim.Region.Environment.Scenes
|
|||
public void TriggerObjectGrab(uint localID, LLVector3 offsetPos, IClientAPI remoteClient)
|
||||
{
|
||||
if (OnObjectGrab != null)
|
||||
{
|
||||
OnObjectGrab(localID, offsetPos, remoteClient);
|
||||
}
|
||||
}
|
||||
|
||||
public void TriggerRezScript(uint localID, LLUUID itemID, string script)
|
||||
{
|
||||
|
|
|
@ -41,27 +41,6 @@ namespace SimpleApp
|
|||
this.CreateTerrainTexture();
|
||||
}
|
||||
|
||||
public override void ProcessObjectGrab(uint localID, LLVector3 offsetPos, IClientAPI remoteClient)
|
||||
{
|
||||
foreach (EntityBase ent in Entities.Values)
|
||||
{
|
||||
if (ent is SceneObjectGroup)
|
||||
{
|
||||
SceneObjectGroup obj = ent as SceneObjectGroup;
|
||||
|
||||
if( obj.HasChildPrim( localID ) )
|
||||
{
|
||||
obj.ObjectGrabHandler(localID, offsetPos, remoteClient);
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
base.ProcessObjectGrab(localID, offsetPos, remoteClient);
|
||||
}
|
||||
|
||||
#region IWorld Members
|
||||
|
||||
override public void AddNewClient(IClientAPI client, bool child)
|
||||
{
|
||||
SubscribeToClientEvents(client);
|
||||
|
@ -79,7 +58,5 @@ namespace SimpleApp
|
|||
|
||||
client.SendRegionHandshake(m_regInfo);
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
|
|
|
@ -52,9 +52,9 @@ namespace OpenSim.Region.ScriptEngine.DotNetEngine
|
|||
|
||||
// Hook up a test event to our test form
|
||||
myScriptEngine.Log.Verbose("ScriptEngine", "Hooking up to server events");
|
||||
myScriptEngine.World.EventManager.OnObjectGrab += new OpenSim.Region.Environment.Scenes.EventManager.ObjectGrabDelegate(touch_start);
|
||||
myScriptEngine.World.EventManager.OnRezScript += new OpenSim.Region.Environment.Scenes.EventManager.NewRezScript(OnRezScript);
|
||||
myScriptEngine.World.EventManager.OnRemoveScript += new OpenSim.Region.Environment.Scenes.EventManager.RemoveScript(OnRemoveScript);
|
||||
myScriptEngine.World.EventManager.OnObjectGrab += touch_start;
|
||||
myScriptEngine.World.EventManager.OnRezScript += OnRezScript;
|
||||
myScriptEngine.World.EventManager.OnRemoveScript += OnRemoveScript;
|
||||
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue