aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Environment/Modules
diff options
context:
space:
mode:
authorJustin Clarke Casey2008-12-22 19:09:09 +0000
committerJustin Clarke Casey2008-12-22 19:09:09 +0000
commiteda69e81efe262f42af0ac479c11cdbc0626464d (patch)
tree34c6991a0fbb536fa206acfc01e0a61ea55d43f1 /OpenSim/Region/Environment/Modules
parent* attempt at adding ODEPlugin testing part duex. This may cause the build t... (diff)
downloadopensim-SC_OLD-eda69e81efe262f42af0ac479c11cdbc0626464d.zip
opensim-SC_OLD-eda69e81efe262f42af0ac479c11cdbc0626464d.tar.gz
opensim-SC_OLD-eda69e81efe262f42af0ac479c11cdbc0626464d.tar.bz2
opensim-SC_OLD-eda69e81efe262f42af0ac479c11cdbc0626464d.tar.xz
* refactor: Make gestures module register its own events too
Diffstat (limited to 'OpenSim/Region/Environment/Modules')
-rw-r--r--OpenSim/Region/Environment/Modules/Avatar/Gestures/GesturesModule.cs9
1 files changed, 9 insertions, 0 deletions
diff --git a/OpenSim/Region/Environment/Modules/Avatar/Gestures/GesturesModule.cs b/OpenSim/Region/Environment/Modules/Avatar/Gestures/GesturesModule.cs
index a86fceb..62b7e35 100644
--- a/OpenSim/Region/Environment/Modules/Avatar/Gestures/GesturesModule.cs
+++ b/OpenSim/Region/Environment/Modules/Avatar/Gestures/GesturesModule.cs
@@ -46,6 +46,9 @@ namespace OpenSim.Region.Environment.Modules.Avatar.Gestures
46 public void Initialise(Scene scene, IConfigSource source) 46 public void Initialise(Scene scene, IConfigSource source)
47 { 47 {
48 m_scene = scene; 48 m_scene = scene;
49
50 m_scene.EventManager.OnNewClient += OnNewClient;
51
49 m_scene.RegisterModuleInterface<IGesturesModule>(this); 52 m_scene.RegisterModuleInterface<IGesturesModule>(this);
50 } 53 }
51 54
@@ -54,6 +57,12 @@ namespace OpenSim.Region.Environment.Modules.Avatar.Gestures
54 public string Name { get { return "Gestures Module"; } } 57 public string Name { get { return "Gestures Module"; } }
55 public bool IsSharedModule { get { return false; } } 58 public bool IsSharedModule { get { return false; } }
56 59
60 private void OnNewClient(IClientAPI client)
61 {
62 client.OnActivateGesture += ActivateGesture;
63 client.OnDeactivateGesture += DeactivateGesture;
64 }
65
57 public virtual void ActivateGesture(IClientAPI client, UUID assetId, UUID gestureId) 66 public virtual void ActivateGesture(IClientAPI client, UUID assetId, UUID gestureId)
58 { 67 {
59 CachedUserInfo userInfo = m_scene.CommsManager.UserProfileCacheService.GetUserDetails(client.AgentId); 68 CachedUserInfo userInfo = m_scene.CommsManager.UserProfileCacheService.GetUserDetails(client.AgentId);