aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/IRCStackModule.cs
diff options
context:
space:
mode:
authorJeff Ames2009-05-31 16:26:18 +0000
committerJeff Ames2009-05-31 16:26:18 +0000
commitdb2c4ab94cc40bf16910806fd4fe0d9a2b7cbd8f (patch)
tree59640d71ec7a7dcae97e261ba3197df0d5e688e3 /OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/IRCStackModule.cs
parent* Adds MRM scripting commands, World.Objects.Create(Vector3 position) and Wor... (diff)
downloadopensim-SC-db2c4ab94cc40bf16910806fd4fe0d9a2b7cbd8f.zip
opensim-SC-db2c4ab94cc40bf16910806fd4fe0d9a2b7cbd8f.tar.gz
opensim-SC-db2c4ab94cc40bf16910806fd4fe0d9a2b7cbd8f.tar.bz2
opensim-SC-db2c4ab94cc40bf16910806fd4fe0d9a2b7cbd8f.tar.xz
Update svn properties.
Diffstat (limited to 'OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/IRCStackModule.cs')
-rw-r--r--OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/IRCStackModule.cs132
1 files changed, 66 insertions, 66 deletions
diff --git a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/IRCStackModule.cs b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/IRCStackModule.cs
index 5c8bfc6..808f1f9 100644
--- a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/IRCStackModule.cs
+++ b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/IRCStackModule.cs
@@ -1,66 +1,66 @@
1using System.Net; 1using System.Net;
2using System.Reflection; 2using System.Reflection;
3using log4net; 3using log4net;
4using Nini.Config; 4using Nini.Config;
5using OpenSim.Region.Framework.Interfaces; 5using OpenSim.Region.Framework.Interfaces;
6using OpenSim.Region.Framework.Scenes; 6using OpenSim.Region.Framework.Scenes;
7using OpenSim.Region.OptionalModules.Agent.InternetRelayClientView.Server; 7using OpenSim.Region.OptionalModules.Agent.InternetRelayClientView.Server;
8 8
9namespace OpenSim.Region.OptionalModules.Agent.InternetRelayClientView 9namespace OpenSim.Region.OptionalModules.Agent.InternetRelayClientView
10{ 10{
11 public class IRCStackModule : IRegionModule 11 public class IRCStackModule : IRegionModule
12 { 12 {
13 private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); 13 private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
14 14
15 private IRCServer m_server; 15 private IRCServer m_server;
16 private Scene m_scene; 16 private Scene m_scene;
17 17
18 #region Implementation of IRegionModule 18 #region Implementation of IRegionModule
19 19
20 public void Initialise(Scene scene, IConfigSource source) 20 public void Initialise(Scene scene, IConfigSource source)
21 { 21 {
22 if (null != source.Configs["IRCd"] && 22 if (null != source.Configs["IRCd"] &&
23 source.Configs["IRCd"].GetBoolean("Enabled",false)) 23 source.Configs["IRCd"].GetBoolean("Enabled",false))
24 { 24 {
25 m_scene = scene; 25 m_scene = scene;
26 m_server = new IRCServer(IPAddress.Parse("0.0.0.0"), 6666, scene); 26 m_server = new IRCServer(IPAddress.Parse("0.0.0.0"), 6666, scene);
27 m_server.OnNewIRCClient += m_server_OnNewIRCClient; 27 m_server.OnNewIRCClient += m_server_OnNewIRCClient;
28 } 28 }
29 } 29 }
30 30
31 void m_server_OnNewIRCClient(IRCClientView user) 31 void m_server_OnNewIRCClient(IRCClientView user)
32 { 32 {
33 user.OnIRCReady += user_OnIRCReady; 33 user.OnIRCReady += user_OnIRCReady;
34 } 34 }
35 35
36 void user_OnIRCReady(IRCClientView cv) 36 void user_OnIRCReady(IRCClientView cv)
37 { 37 {
38 m_log.Info("[IRCd] Adding user..."); 38 m_log.Info("[IRCd] Adding user...");
39 m_scene.ClientManager.Add(cv.CircuitCode, cv); 39 m_scene.ClientManager.Add(cv.CircuitCode, cv);
40 cv.Start(); 40 cv.Start();
41 m_log.Info("[IRCd] Added user to Scene"); 41 m_log.Info("[IRCd] Added user to Scene");
42 } 42 }
43 43
44 public void PostInitialise() 44 public void PostInitialise()
45 { 45 {
46 46
47 } 47 }
48 48
49 public void Close() 49 public void Close()
50 { 50 {
51 51
52 } 52 }
53 53
54 public string Name 54 public string Name
55 { 55 {
56 get { return "IRCClientStackModule"; } 56 get { return "IRCClientStackModule"; }
57 } 57 }
58 58
59 public bool IsSharedModule 59 public bool IsSharedModule
60 { 60 {
61 get { return false; } 61 get { return false; }
62 } 62 }
63 63
64 #endregion 64 #endregion
65 } 65 }
66} 66}