aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework/Scenes/EventManager.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/EventManager.cs')
-rw-r--r--OpenSim/Region/Framework/Scenes/EventManager.cs24
1 files changed, 24 insertions, 0 deletions
diff --git a/OpenSim/Region/Framework/Scenes/EventManager.cs b/OpenSim/Region/Framework/Scenes/EventManager.cs
index 6ff2a6f..605ee32 100644
--- a/OpenSim/Region/Framework/Scenes/EventManager.cs
+++ b/OpenSim/Region/Framework/Scenes/EventManager.cs
@@ -55,8 +55,12 @@ namespace OpenSim.Region.Framework.Scenes
55 55
56 public delegate void OnTerrainTickDelegate(); 56 public delegate void OnTerrainTickDelegate();
57 57
58 public delegate void OnTerrainUpdateDelegate();
59
58 public event OnTerrainTickDelegate OnTerrainTick; 60 public event OnTerrainTickDelegate OnTerrainTick;
59 61
62 public event OnTerrainUpdateDelegate OnTerrainUpdate;
63
60 public delegate void OnBackupDelegate(ISimulationDataService datastore, bool forceBackup); 64 public delegate void OnBackupDelegate(ISimulationDataService datastore, bool forceBackup);
61 65
62 public event OnBackupDelegate OnBackup; 66 public event OnBackupDelegate OnBackup;
@@ -867,6 +871,26 @@ namespace OpenSim.Region.Framework.Scenes
867 } 871 }
868 } 872 }
869 } 873 }
874 public void TriggerTerrainUpdate()
875 {
876 OnTerrainUpdateDelegate handlerTerrainUpdate = OnTerrainUpdate;
877 if (handlerTerrainUpdate != null)
878 {
879 foreach (OnTerrainUpdateDelegate d in handlerTerrainUpdate.GetInvocationList())
880 {
881 try
882 {
883 d();
884 }
885 catch (Exception e)
886 {
887 m_log.ErrorFormat(
888 "[EVENT MANAGER]: Delegate for TriggerTerrainUpdate failed - continuing. {0} {1}",
889 e.Message, e.StackTrace);
890 }
891 }
892 }
893 }
870 894
871 public void TriggerTerrainTick() 895 public void TriggerTerrainTick()
872 { 896 {