From: Kurt Taylor <krtaylor@us.ibm.com>
Attached is a patch for Mantis 25 - this fixes the problem of not having a touch_start happen for all prims in a linked group. So, with this, large builds can now have a single script in the base prim and it will run when any prim in the linked build is touched. The problem was that the objectgrab event was not being propagated to all the prims in the group.ThreadPoolClientBranch
parent
598c5a95d9
commit
7b4fb3b8bc
|
@ -148,7 +148,6 @@ namespace OpenSim.Region.Environment.Scenes
|
|||
|
||||
public virtual void ProcessObjectGrab(uint localID, LLVector3 offsetPos, IClientAPI remoteClient)
|
||||
{
|
||||
EventManager.TriggerObjectGrab(localID, offsetPos, remoteClient);
|
||||
|
||||
List<EntityBase> EntitieList = GetEntities();
|
||||
|
||||
|
@ -158,9 +157,21 @@ namespace OpenSim.Region.Environment.Scenes
|
|||
{
|
||||
SceneObjectGroup obj = ent as SceneObjectGroup;
|
||||
|
||||
// Is this prim part of the group
|
||||
if (obj.HasChildPrim(localID))
|
||||
{
|
||||
// Currently only grab/touch for the single prim
|
||||
// the client handles rez correctly
|
||||
obj.ObjectGrabHandler(localID, offsetPos, remoteClient);
|
||||
|
||||
// trigger event, one for each prim part in the group
|
||||
// so that a touch to a non-root prim in a group will still
|
||||
// trigger a touch_start for a script in the root prim
|
||||
foreach (SceneObjectPart part in obj.Children.Values)
|
||||
{
|
||||
EventManager.TriggerObjectGrab(part.LocalID, part.OffsetPosition, remoteClient);
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue