From e9153e1d1aae50024d8cd05fe14a9bce34343a0e Mon Sep 17 00:00:00 2001
From: teravus
Date: Thu, 15 Nov 2012 10:05:16 -0500
Subject: Revert "Merge master into teravuswork", it should have been
avination, not master.
This reverts commit dfac269032300872c4d0dc507f4f9062d102b0f4, reversing
changes made to 619c39e5144f15aca129d6d999bcc5c34133ee64.
---
OpenSim/Region/Framework/Scenes/EventManager.cs | 521 +-----------------------
1 file changed, 16 insertions(+), 505 deletions(-)
(limited to 'OpenSim/Region/Framework/Scenes/EventManager.cs')
diff --git a/OpenSim/Region/Framework/Scenes/EventManager.cs b/OpenSim/Region/Framework/Scenes/EventManager.cs
index 5b1c9f4..4a19c3b 100644
--- a/OpenSim/Region/Framework/Scenes/EventManager.cs
+++ b/OpenSim/Region/Framework/Scenes/EventManager.cs
@@ -47,75 +47,30 @@ namespace OpenSim.Region.Framework.Scenes
public delegate void OnFrameDelegate();
- ///
- /// Triggered on each sim frame.
- ///
- ///
- /// This gets triggered in
- /// Core uses it for things like Sun, Wind & Clouds
- /// The MRM module also uses it.
- ///
public event OnFrameDelegate OnFrame;
public delegate void ClientMovement(ScenePresence client);
- ///
- /// Trigerred when an agent moves.
- ///
- ///
- /// This gets triggered in
- /// prior to
- ///
public event ClientMovement OnClientMovement;
public delegate void OnTerrainTaintedDelegate();
- ///
- /// Triggered if the terrain has been edited
- ///
- ///
- /// This gets triggered in
- /// after it determines that an update has been made.
- ///
public event OnTerrainTaintedDelegate OnTerrainTainted;
public delegate void OnTerrainTickDelegate();
- ///
- /// Triggered if the terrain has been edited
- ///
- ///
- /// This gets triggered in
- /// but is used by core solely to update the physics engine.
- ///
- public event OnTerrainTickDelegate OnTerrainTick;
-
public delegate void OnTerrainUpdateDelegate();
+ public event OnTerrainTickDelegate OnTerrainTick;
+
public event OnTerrainUpdateDelegate OnTerrainUpdate;
public delegate void OnBackupDelegate(ISimulationDataService datastore, bool forceBackup);
- ///
- /// Triggered when a region is backed up/persisted to storage
- ///
- ///
- /// This gets triggered in
- /// and is fired before the persistence occurs.
- ///
public event OnBackupDelegate OnBackup;
public delegate void OnClientConnectCoreDelegate(IClientCore client);
- ///
- /// Triggered when a new client connects to the scene.
- ///
- ///
- /// This gets triggered in ,
- /// which checks if an instance of
- /// also implements and as such,
- /// is not triggered by NPCs.
- ///
public event OnClientConnectCoreDelegate OnClientConnect;
public delegate void OnNewClientDelegate(IClientAPI client);
@@ -125,96 +80,33 @@ namespace OpenSim.Region.Framework.Scenes
///
///
/// This is triggered for both child and root agent client connections.
- ///
/// Triggered before OnClientLogin.
- ///
- /// This is triggered under per-agent lock. So if you want to perform any long-running operations, please
- /// do this on a separate thread.
///
public event OnNewClientDelegate OnNewClient;
///
/// Fired if the client entering this sim is doing so as a new login
///
- ///
- /// This is triggered under per-agent lock. So if you want to perform any long-running operations, please
- /// do this on a separate thread.
- ///
public event Action OnClientLogin;
public delegate void OnNewPresenceDelegate(ScenePresence presence);
- ///
- /// Triggered when a new presence is added to the scene
- ///
- ///
- /// Triggered in which is used by both
- /// users and NPCs
- ///
public event OnNewPresenceDelegate OnNewPresence;
public delegate void OnRemovePresenceDelegate(UUID agentId);
- ///
- /// Triggered when a presence is removed from the scene
- ///
- ///
- /// Triggered in which is used by both
- /// users and NPCs
- ///
- /// Triggered under per-agent lock. So if you want to perform any long-running operations, please
- /// do this on a separate thread.
- ///
public event OnRemovePresenceDelegate OnRemovePresence;
public delegate void OnParcelPrimCountUpdateDelegate();
- ///
- /// Triggered whenever the prim count may have been altered, or prior
- /// to an action that requires the current prim count to be accurate.
- ///
- ///
- /// Triggered by in
- /// ,
- /// ,
- /// ,
- /// ,
- /// ,
- /// ,
- ///
- ///
public event OnParcelPrimCountUpdateDelegate OnParcelPrimCountUpdate;
public delegate void OnParcelPrimCountAddDelegate(SceneObjectGroup obj);
- ///
- /// Triggered in response to for
- /// objects that actually contribute to parcel prim count.
- ///
- ///
- /// Triggered by in
- ///
- ///
public event OnParcelPrimCountAddDelegate OnParcelPrimCountAdd;
public delegate void OnPluginConsoleDelegate(string[] args);
- ///
- /// Triggered after
- /// has been called for all
- /// loaded via .
- /// Handlers for this event are typically used to parse the arguments
- /// from in order to process or
- /// filter the arguments and pass them onto
- ///
- ///
- /// Triggered by in
- /// via
- /// via
- /// via
- /// via
- ///
- ///
public event OnPluginConsoleDelegate OnPluginConsole;
///
@@ -229,28 +121,8 @@ namespace OpenSim.Region.Framework.Scenes
public delegate void OnSetRootAgentSceneDelegate(UUID agentID, Scene scene);
- ///
- /// Triggered before the grunt work for adding a root agent to a
- /// scene has been performed (resuming attachment scripts, physics,
- /// animations etc.)
- ///
- ///
- /// Triggered before
- /// by
- /// in
- /// via
- /// and
- ///
public event OnSetRootAgentSceneDelegate OnSetRootAgentScene;
- ///
- /// Triggered after parcel properties have been updated.
- ///
- ///
- /// Triggered by in
- /// ,
- ///
- ///
public event ParcelPropertiesUpdateRequest OnParcelPropertiesUpdateRequest;
///
@@ -265,45 +137,13 @@ namespace OpenSim.Region.Framework.Scenes
///
/// Fired when an object is touched/grabbed.
///
- ///
/// The originalID is the local ID of the part that was actually touched. The localID itself is always that of
/// the root part.
- /// Triggerd in response to
- /// via
- /// in
- ///
public event ObjectGrabDelegate OnObjectGrab;
public delegate void ObjectGrabDelegate(uint localID, uint originalID, Vector3 offsetPos, IClientAPI remoteClient, SurfaceTouchEventArgs surfaceArgs);
- ///
- /// Triggered when an object is being touched/grabbed continuously.
- ///
- ///
- /// Triggered in response to
- /// via
- /// in
- ///
public event ObjectGrabDelegate OnObjectGrabbing;
-
- ///
- /// Triggered when an object stops being touched/grabbed.
- ///
- ///
- /// Triggered in response to
- /// via
- /// in
- ///
public event ObjectDeGrabDelegate OnObjectDeGrab;
-
- ///
- /// Triggered when a script resets.
- ///
- ///
- /// Triggered by
- /// in
- /// via
- /// via
- ///
public event ScriptResetDelegate OnScriptReset;
public event OnPermissionErrorDelegate OnPermissionError;
@@ -313,105 +153,29 @@ namespace OpenSim.Region.Framework.Scenes
///
///
/// Occurs after OnNewScript.
- /// Triggered by
- /// in
///
public event NewRezScript OnRezScript;
public delegate void NewRezScript(uint localID, UUID itemID, string script, int startParam, bool postOnRez, string engine, int stateSource);
public delegate void RemoveScript(uint localID, UUID itemID);
-
- ///
- /// Triggered when a script is removed from an object.
- ///
- ///
- /// Triggered by
- /// in ,
- /// ,
- /// ,
- ///
- ///
public event RemoveScript OnRemoveScript;
public delegate void StartScript(uint localID, UUID itemID);
-
- ///
- /// Triggered when a script starts.
- ///
- ///
- /// Triggered by
- /// in
- /// via ,
- /// via
- ///
public event StartScript OnStartScript;
public delegate void StopScript(uint localID, UUID itemID);
-
- ///
- /// Triggered when a script stops.
- ///
- ///
- /// Triggered by ,
- /// in ,
- /// ,
- ///
- ///
public event StopScript OnStopScript;
public delegate bool SceneGroupMoved(UUID groupID, Vector3 delta);
-
- ///
- /// Triggered when an object is moved.
- ///
- ///
- /// Triggered by
- /// in ,
- ///
- ///
public event SceneGroupMoved OnSceneGroupMove;
public delegate void SceneGroupGrabed(UUID groupID, Vector3 offset, UUID userID);
-
- ///
- /// Triggered when an object is grabbed.
- ///
- ///
- /// Triggered by
- /// in
- /// via
- /// via
- /// via
- /// via
- ///
public event SceneGroupGrabed OnSceneGroupGrab;
public delegate bool SceneGroupSpinStarted(UUID groupID);
-
- ///
- /// Triggered when an object starts to spin.
- ///
- ///
- /// Triggered by
- /// in
- /// via
- /// via
- /// via
- ///
public event SceneGroupSpinStarted OnSceneGroupSpinStart;
public delegate bool SceneGroupSpun(UUID groupID, Quaternion rotation);
-
- ///
- /// Triggered when an object is being spun.
- ///
- ///
- /// Triggered by
- /// in
- /// via
- /// via
- /// via
- ///
public event SceneGroupSpun OnSceneGroupSpin;
public delegate void LandObjectAdded(ILandObject newParcel);
@@ -440,9 +204,6 @@ namespace OpenSim.Region.Framework.Scenes
///
///
/// At the point of firing, the scene still contains the client's scene presence.
- ///
- /// This is triggered under per-agent lock. So if you want to perform any long-running operations, please
- /// do this on a separate thread.
///
public event ClientClosed OnClientClosed;
@@ -453,9 +214,6 @@ namespace OpenSim.Region.Framework.Scenes
///
///
/// Occurs before OnRezScript
- /// Triggered by
- /// in ,
- ///
///
public event NewScript OnNewScript;
@@ -490,12 +248,6 @@ namespace OpenSim.Region.Framework.Scenes
///
///
/// Triggered after the scene receives a client's upload of an updated script and has stored it in an asset.
- /// Triggered by
- /// in
- /// via
- /// via
- /// via
- /// via
///
public event UpdateScript OnUpdateScript;
@@ -521,203 +273,48 @@ namespace OpenSim.Region.Framework.Scenes
}
///
- /// Triggered when some scene object properties change.
- ///
- ///
/// ScriptChangedEvent is fired when a scene object property that a script might be interested
/// in (such as color, scale or inventory) changes. Only enough information sent is for the LSL changed event.
/// This is not an indication that the script has changed (see OnUpdateScript for that).
/// This event is sent to a script to tell it that some property changed on
/// the object the script is in. See http://lslwiki.net/lslwiki/wakka.php?wakka=changed .
- /// Triggered by
- /// in ,
- ///
- ///
+ ///
public event ScriptChangedEvent OnScriptChangedEvent;
public delegate void ScriptChangedEvent(uint localID, uint change);
public delegate void ScriptControlEvent(UUID item, UUID avatarID, uint held, uint changed);
-
- ///
- /// Triggered when a script receives control input from an agent.
- ///
- ///
- /// Triggered by
- /// in
- /// via
- /// via
- /// via
- ///
public event ScriptControlEvent OnScriptControlEvent;
public delegate void ScriptAtTargetEvent(uint localID, uint handle, Vector3 targetpos, Vector3 atpos);
-
- ///
- /// Triggered when an object has arrived within a tolerance distance
- /// of a motion target.
- ///
- ///
- /// Triggered by
- /// in
- /// via ,
- /// via
- ///
public event ScriptAtTargetEvent OnScriptAtTargetEvent;
public delegate void ScriptNotAtTargetEvent(uint localID);
-
- ///
- /// Triggered when an object has a motion target but has not arrived
- /// within a tolerance distance.
- ///
- ///
- /// Triggered by
- /// in
- /// via ,
- /// via
- ///
public event ScriptNotAtTargetEvent OnScriptNotAtTargetEvent;
public delegate void ScriptAtRotTargetEvent(uint localID, uint handle, Quaternion targetrot, Quaternion atrot);
-
- ///
- /// Triggered when an object has arrived within a tolerance rotation
- /// of a rotation target.
- ///
- ///
- /// Triggered by
- /// in
- /// via ,
- /// via
- ///
public event ScriptAtRotTargetEvent OnScriptAtRotTargetEvent;
public delegate void ScriptNotAtRotTargetEvent(uint localID);
-
- ///
- /// Triggered when an object has a rotation target but has not arrived
- /// within a tolerance rotation.
- ///
- ///
- /// Triggered by
- /// in
- /// via ,
- /// via
- ///
public event ScriptNotAtRotTargetEvent OnScriptNotAtRotTargetEvent;
public delegate void ScriptColliding(uint localID, ColliderArgs colliders);
-
- ///
- /// Triggered when a physical collision has started between a prim
- /// and something other than the region terrain.
- ///
- ///
- /// Triggered by
- /// in
- /// via
- /// via
- /// via
- ///
public event ScriptColliding OnScriptColliderStart;
-
- ///
- /// Triggered when something that previously collided with a prim has
- /// not stopped colliding with it.
- ///
- ///
- ///
- /// Triggered by
- /// in
- /// via
- /// via
- /// via
- ///
public event ScriptColliding OnScriptColliding;
-
- ///
- /// Triggered when something that previously collided with a prim has
- /// stopped colliding with it.
- ///
- ///
- /// Triggered by
- /// in
- /// via
- /// via
- /// via
- ///
public event ScriptColliding OnScriptCollidingEnd;
-
- ///
- /// Triggered when a physical collision has started between an object
- /// and the region terrain.
- ///
- ///
- /// Triggered by
- /// in
- /// via
- /// via
- /// via
- ///
public event ScriptColliding OnScriptLandColliderStart;
-
- ///
- /// Triggered when an object that previously collided with the region
- /// terrain has not yet stopped colliding with it.
- ///
- ///
- /// Triggered by
- /// in
- /// via
- /// via
- /// via
- ///
public event ScriptColliding OnScriptLandColliding;
-
- ///
- /// Triggered when an object that previously collided with the region
- /// terrain has stopped colliding with it.
- ///
- ///
- /// Triggered by
- /// in
- /// via
- /// via
- /// via
- ///
public event ScriptColliding OnScriptLandColliderEnd;
public delegate void OnMakeChildAgentDelegate(ScenePresence presence);
-
- ///
- /// Triggered when an agent has been made a child agent of a scene.
- ///
- ///
- /// Triggered by
- /// in
- /// via ,
- /// ,
- ///
- ///
public event OnMakeChildAgentDelegate OnMakeChildAgent;
public delegate void OnSaveNewWindlightProfileDelegate();
public delegate void OnSendNewWindlightProfileTargetedDelegate(RegionLightShareData wl, UUID user);
///
- /// Triggered after the grunt work for adding a root agent to a
- /// scene has been performed (resuming attachment scripts, physics,
- /// animations etc.)
- ///
- ///
/// This event is on the critical path for transferring an avatar from one region to another. Try and do
/// as little work on this event as possible, or do work asynchronously.
- /// Triggered after
- /// by
- /// in
- /// via
- /// and
- ///
+ ///
public event Action OnMakeRootAgent;
public event OnSendNewWindlightProfileTargetedDelegate OnSendNewWindlightProfileTargeted;
@@ -743,17 +340,9 @@ namespace OpenSim.Region.Framework.Scenes
public event AvatarKillData OnAvatarKilled;
public delegate void AvatarKillData(uint KillerLocalID, ScenePresence avatar);
- /*
- public delegate void ScriptTimerEvent(uint localID, double timerinterval);
- ///
- /// Used to be triggered when the LSL timer event fires.
- ///
- ///
- /// Triggered by
- /// via
- ///
- public event ScriptTimerEvent OnScriptTimerEvent;
- */
+// public delegate void ScriptTimerEvent(uint localID, double timerinterval);
+
+// public event ScriptTimerEvent OnScriptTimerEvent;
public delegate void EstateToolsSunUpdate(ulong regionHandle, bool FixedTime, bool EstateSun, float LindenHour);
public delegate void GetScriptRunning(IClientAPI controllingClient, UUID objectID, UUID itemID);
@@ -763,27 +352,12 @@ namespace OpenSim.Region.Framework.Scenes
///
/// Triggered when an object is added to the scene.
///
- ///
- /// Triggered by
- /// in ,
- /// ,
- ///
- ///
public event Action OnObjectAddedToScene;
///
- /// Delegate for
- ///
- /// The object being removed from the scene
- public delegate void ObjectBeingRemovedFromScene(SceneObjectGroup obj);
-
- ///
/// Triggered when an object is removed from the scene.
///
- ///
- /// Triggered by
- /// in
- ///
+ public delegate void ObjectBeingRemovedFromScene(SceneObjectGroup obj);
public event ObjectBeingRemovedFromScene OnObjectBeingRemovedFromScene;
public delegate void NoticeNoLandDataFromStorage();
@@ -799,20 +373,6 @@ namespace OpenSim.Region.Framework.Scenes
public event RequestParcelPrimCountUpdate OnRequestParcelPrimCountUpdate;
public delegate void ParcelPrimCountTainted();
-
- ///
- /// Triggered when the parcel prim count has been altered.
- ///
- ///
- /// Triggered by in
- /// ,
- /// ,
- /// ,
- /// ,
- /// ,
- /// ,
- ///
- ///
public event ParcelPrimCountTainted OnParcelPrimCountTainted;
public event GetScriptRunning OnGetScriptRunning;
@@ -876,7 +436,7 @@ namespace OpenSim.Region.Framework.Scenes
/// the scripts may not have started yet
/// Message is non empty string if there were problems loading the oar file
///
- public delegate void OarFileLoaded(Guid guid, List loadedScenes, string message);
+ public delegate void OarFileLoaded(Guid guid, string message);
public event OarFileLoaded OnOarFileLoaded;
///
@@ -929,13 +489,10 @@ namespace OpenSim.Region.Framework.Scenes
///
///
/// True if the duplicate will immediately be in the scene, false otherwise
- ///
- /// Triggered in
- ///
public event SceneObjectPartCopyDelegate OnSceneObjectPartCopy;
public delegate void SceneObjectPartCopyDelegate(SceneObjectPart copy, SceneObjectPart original, bool userExposed);
- public delegate void SceneObjectPartUpdated(SceneObjectPart sop, bool full);
+ public delegate void SceneObjectPartUpdated(SceneObjectPart sop);
public event SceneObjectPartUpdated OnSceneObjectPartUpdated;
public delegate void ScenePresenceUpdated(ScenePresence sp);
@@ -973,28 +530,9 @@ namespace OpenSim.Region.Framework.Scenes
public event PrimsLoaded OnPrimsLoaded;
public delegate void TeleportStart(IClientAPI client, GridRegion destination, GridRegion finalDestination, uint teleportFlags, bool gridLogout);
-
- ///
- /// Triggered when a teleport starts
- ///
- ///
- /// Triggered by
- /// in
- /// and
- /// via
- ///
public event TeleportStart OnTeleportStart;
public delegate void TeleportFail(IClientAPI client, bool gridLogout);
-
- ///
- /// Trigered when a teleport fails.
- ///
- ///
- /// Triggered by
- /// in
- /// via
- ///
public event TeleportFail OnTeleportFail;
public class MoneyTransferArgs : EventArgs
@@ -1002,9 +540,7 @@ namespace OpenSim.Region.Framework.Scenes
public UUID sender;
public UUID receiver;
- ///
- /// Always false. The SL protocol sucks.
- ///
+ // Always false. The SL protocol sucks.
public bool authenticated = false;
public int amount;
@@ -1061,29 +597,8 @@ namespace OpenSim.Region.Framework.Scenes
public delegate void LandBuy(Object sender, LandBuyArgs e);
- ///
- /// Triggered when an attempt to transfer grid currency occurs
- ///
- ///
- /// Triggered in
- /// via
- /// via
- /// via
- ///
public event MoneyTransferEvent OnMoneyTransfer;
-
- ///
- /// Triggered after after
- ///
public event LandBuy OnLandBuy;
-
- ///
- /// Triggered to allow or prevent a real estate transaction
- ///
- ///
- /// Triggered in
- ///
- ///
public event LandBuy OnValidateLandBuy;
public void TriggerOnAttach(uint localID, UUID itemID, UUID avatarID)
@@ -2520,11 +2035,7 @@ namespace OpenSim.Region.Framework.Scenes
}
}
- ///
- /// this lets us keep track of nasty script events like timer, etc.
- ///
- ///
- ///
+ // this lets us keep track of nasty script events like timer, etc.
public void TriggerTimerEvent(uint objLocalID, double Interval)
{
throw new NotImplementedException("TriggerTimerEvent was thought to be not used anymore and the registration for the event from scene object part has been commented out due to a memory leak");
@@ -2586,7 +2097,7 @@ namespace OpenSim.Region.Framework.Scenes
return 6;
}
- public void TriggerOarFileLoaded(Guid requestId, List loadedScenes, string message)
+ public void TriggerOarFileLoaded(Guid requestId, string message)
{
OarFileLoaded handlerOarFileLoaded = OnOarFileLoaded;
if (handlerOarFileLoaded != null)
@@ -2595,7 +2106,7 @@ namespace OpenSim.Region.Framework.Scenes
{
try
{
- d(requestId, loadedScenes, message);
+ d(requestId, message);
}
catch (Exception e)
{
@@ -2880,7 +2391,7 @@ namespace OpenSim.Region.Framework.Scenes
}
}
- public void TriggerSceneObjectPartUpdated(SceneObjectPart sop, bool full)
+ public void TriggerSceneObjectPartUpdated(SceneObjectPart sop)
{
SceneObjectPartUpdated handler = OnSceneObjectPartUpdated;
if (handler != null)
@@ -2889,7 +2400,7 @@ namespace OpenSim.Region.Framework.Scenes
{
try
{
- d(sop, full);
+ d(sop);
}
catch (Exception e)
{
--
cgit v1.1