Just trying out some thing with events, there changes/additions are likely to be temporary.
parent
e41b0feb58
commit
a19ec6fc54
|
@ -60,6 +60,14 @@ namespace OpenSim.Region.Environment.Scenes
|
||||||
|
|
||||||
public event RemoveScript OnRemoveScript;
|
public event RemoveScript OnRemoveScript;
|
||||||
|
|
||||||
|
public delegate void SceneGroupMoved(LLUUID groupID, LLVector3 delta);
|
||||||
|
|
||||||
|
public event SceneGroupMoved OnSceneGroupMove;
|
||||||
|
|
||||||
|
public delegate void SceneGroupGrabed(LLUUID groupID, LLVector3 offset);
|
||||||
|
|
||||||
|
public event SceneGroupGrabed OnSceneGroupGrab;
|
||||||
|
|
||||||
public void TriggerPermissionError(LLUUID user, string reason)
|
public void TriggerPermissionError(LLUUID user, string reason)
|
||||||
{
|
{
|
||||||
if (OnPermissionError != null)
|
if (OnPermissionError != null)
|
||||||
|
@ -153,5 +161,21 @@ namespace OpenSim.Region.Environment.Scenes
|
||||||
OnRemoveScript(localID, itemID);
|
OnRemoveScript(localID, itemID);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void TriggerGroupMove(LLUUID groupID, LLVector3 delta)
|
||||||
|
{
|
||||||
|
if (OnSceneGroupMove != null)
|
||||||
|
{
|
||||||
|
OnSceneGroupMove(groupID, delta);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public void TriggerGroupGrab(LLUUID groupID, LLVector3 offset)
|
||||||
|
{
|
||||||
|
if (OnSceneGroupGrab != null)
|
||||||
|
{
|
||||||
|
OnSceneGroupGrab(groupID, offset);
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -931,6 +931,8 @@ namespace OpenSim.Region.Environment.Scenes
|
||||||
{
|
{
|
||||||
AbsolutePosition = pos;
|
AbsolutePosition = pos;
|
||||||
ScheduleGroupForTerseUpdate();
|
ScheduleGroupForTerseUpdate();
|
||||||
|
|
||||||
|
m_scene.EventManager.TriggerGroupMove(this.UUID, pos);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
@ -1279,6 +1281,7 @@ namespace OpenSim.Region.Environment.Scenes
|
||||||
|
|
||||||
public virtual void OnGrabGroup(LLVector3 offsetPos, IClientAPI remoteClient)
|
public virtual void OnGrabGroup(LLVector3 offsetPos, IClientAPI remoteClient)
|
||||||
{
|
{
|
||||||
|
m_scene.EventManager.TriggerGroupGrab(this.UUID, offsetPos);
|
||||||
}
|
}
|
||||||
|
|
||||||
public void DeleteGroup()
|
public void DeleteGroup()
|
||||||
|
|
Loading…
Reference in New Issue