aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/src/OpenSimConsole.cs
diff options
context:
space:
mode:
authorlbsa712007-03-13 08:55:47 +0000
committerlbsa712007-03-13 08:55:47 +0000
commit0587158f9208ecf9f39a6dd0ef7cb7c5663a39f8 (patch)
treebf86015426ec54fa1f1b5902236670f752473497 /src/OpenSimConsole.cs
parent(no commit message) (diff)
downloadopensim-SC_OLD-0587158f9208ecf9f39a6dd0ef7cb7c5663a39f8.zip
opensim-SC_OLD-0587158f9208ecf9f39a6dd0ef7cb7c5663a39f8.tar.gz
opensim-SC_OLD-0587158f9208ecf9f39a6dd0ef7cb7c5663a39f8.tar.bz2
opensim-SC_OLD-0587158f9208ecf9f39a6dd0ef7cb7c5663a39f8.tar.xz
-- Trying to get trunk to run from first build
* Collected required dll's into /bin * Moved timer start for great justice * Added some Writes to Console, and a Status field * Added dumb NullPhysicsScene and NullPhysicsActor that kicks in if Physics Plugin not specified * Svn-ignored a shitload
Diffstat (limited to '')
-rw-r--r--src/OpenSimConsole.cs43
1 files changed, 26 insertions, 17 deletions
diff --git a/src/OpenSimConsole.cs b/src/OpenSimConsole.cs
index 11bc648..00a4cee 100644
--- a/src/OpenSimConsole.cs
+++ b/src/OpenSimConsole.cs
@@ -61,6 +61,7 @@ namespace OpenSim
61 ConsType = constype; 61 ConsType = constype;
62 switch(constype) { 62 switch(constype) {
63 case ConsoleType.Local: 63 case ConsoleType.Local:
64
64 Console.WriteLine("ServerConsole.cs - creating new local console"); 65 Console.WriteLine("ServerConsole.cs - creating new local console");
65 Console.WriteLine("Logs will be saved to current directory in opensim-console.log"); 66 Console.WriteLine("Logs will be saved to current directory in opensim-console.log");
66 Log=File.AppendText("opensim-console.log"); 67 Log=File.AppendText("opensim-console.log");
@@ -75,22 +76,30 @@ namespace OpenSim
75 default: 76 default:
76 Console.WriteLine("ServerConsole.cs - what are you smoking? that isn't a valid console type!"); 77 Console.WriteLine("ServerConsole.cs - what are you smoking? that isn't a valid console type!");
77 break; 78 break;
78 } 79 }
79 } 80 }
80 81
81 public override void Close() { 82 public override void Close() {
82 Log.WriteLine("OpenSim shutdown at " + DateTime.Now.ToString()); 83 Log.WriteLine("OpenSim shutdown at " + DateTime.Now.ToString());
83 Log.Close(); 84 Log.Close();
84 } 85 }
85 86
86 // You know what ReadLine() and WriteLine() do, right? And Read() and Write()? Right, you do actually know C#, right? Are you actually a programmer? Do you know english? Do you find my sense of humour in comments irritating? Good, glad you're still here 87 public override void Write(string format, params object[] args)
87 public override void WriteLine(string Line) { 88 {
88 Log.WriteLine(Line); 89 Log.Write(format, args);
89 Console.WriteLine(Line); 90 Console.Write(format, args);
90 return; 91 return;
91 } 92 }
92 93
93 public override string ReadLine() { 94 public override void WriteLine(string format, params object[] args)
95 {
96 Log.WriteLine(format, args);
97 Console.WriteLine(format, args);
98 return;
99 }
100
101 public override string ReadLine()
102 {
94 string TempStr=Console.ReadLine(); 103 string TempStr=Console.ReadLine();
95 Log.WriteLine(TempStr); 104 Log.WriteLine(TempStr);
96 return TempStr; 105 return TempStr;
@@ -102,12 +111,6 @@ namespace OpenSim
102 return TempInt; 111 return TempInt;
103 } 112 }
104 113
105 public override void Write(string Line) {
106 Console.Write(Line);
107 Log.Write(Line);
108 return;
109 }
110
111 // Displays a command prompt and waits for the user to enter a string, then returns that string 114 // Displays a command prompt and waits for the user to enter a string, then returns that string
112 public override string CmdPrompt(string prompt) { 115 public override string CmdPrompt(string prompt) {
113 this.Write(prompt); 116 this.Write(prompt);
@@ -196,7 +199,13 @@ namespace OpenSim
196 string[] cmdparams=(string[])tempstrarray; 199 string[] cmdparams=(string[])tempstrarray;
197 RunCmd(cmd,cmdparams); 200 RunCmd(cmd,cmdparams);
198 } 201 }
199 } 202
203
204 public override void SetStatus(string status)
205 {
206 Console.Write( status + "\r" );
207 }
208 }
200} 209}
201 210
202 211