aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Tools/pCampBot/pCampBot.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Tools/pCampBot/pCampBot.cs')
-rw-r--r--OpenSim/Tools/pCampBot/pCampBot.cs14
1 files changed, 13 insertions, 1 deletions
diff --git a/OpenSim/Tools/pCampBot/pCampBot.cs b/OpenSim/Tools/pCampBot/pCampBot.cs
index a69fbf0..cae96e1 100644
--- a/OpenSim/Tools/pCampBot/pCampBot.cs
+++ b/OpenSim/Tools/pCampBot/pCampBot.cs
@@ -26,6 +26,8 @@
26 */ 26 */
27 27
28using System; 28using System;
29using System.Reflection;
30using log4net;
29using Nini.Config; 31using Nini.Config;
30using OpenSim.Framework; 32using OpenSim.Framework;
31using OpenSim.Framework.Console; 33using OpenSim.Framework.Console;
@@ -44,6 +46,8 @@ namespace pCampBot
44 46
45 public class pCampBot 47 public class pCampBot
46 { 48 {
49 private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
50
47 [STAThread] 51 [STAThread]
48 public static void Main(string[] args) 52 public static void Main(string[] args)
49 { 53 {
@@ -60,9 +64,17 @@ namespace pCampBot
60 64
61 //startup specified number of bots. 1 is the default 65 //startup specified number of bots. 1 is the default
62 bm.dobotStartup(botcount, config); 66 bm.dobotStartup(botcount, config);
67
63 while (true) 68 while (true)
64 { 69 {
65 MainConsole.Instance.Prompt(); 70 try
71 {
72 MainConsole.Instance.Prompt();
73 }
74 catch (Exception e)
75 {
76 m_log.ErrorFormat("Command error: {0}", e);
77 }
66 } 78 }
67 } 79 }
68 } 80 }