aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/ScriptManager.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/ScriptManager.cs')
-rw-r--r--OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/ScriptManager.cs49
1 files changed, 23 insertions, 26 deletions
diff --git a/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/ScriptManager.cs b/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/ScriptManager.cs
index 684d133..b50c184 100644
--- a/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/ScriptManager.cs
+++ b/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/ScriptManager.cs
@@ -169,15 +169,12 @@ namespace OpenSim.Region.ScriptEngine.Common.ScriptEngineBase
169 // Abort load/unload thread 169 // Abort load/unload thread
170 try 170 try
171 { 171 {
172 PleaseShutdown = true; 172 //PleaseShutdown = true;
173 Thread.Sleep(100); 173 //Thread.Sleep(100);
174 if (scriptLoadUnloadThread != null) 174 if (scriptLoadUnloadThread != null && scriptLoadUnloadThread.IsAlive == true)
175 { 175 {
176 if (scriptLoadUnloadThread.IsAlive == true) 176 scriptLoadUnloadThread.Abort();
177 { 177 //scriptLoadUnloadThread.Join();
178 scriptLoadUnloadThread.Abort();
179 scriptLoadUnloadThread.Join();
180 }
181 } 178 }
182 } 179 }
183 catch 180 catch
@@ -282,7 +279,7 @@ namespace OpenSim.Region.ScriptEngine.Common.ScriptEngineBase
282 279
283 public abstract void _StartScript(uint localID, LLUUID itemID, string Script); 280 public abstract void _StartScript(uint localID, LLUUID itemID, string Script);
284 public abstract void _StopScript(uint localID, LLUUID itemID); 281 public abstract void _StopScript(uint localID, LLUUID itemID);
285 282
286 283
287 #endregion 284 #endregion
288 285
@@ -297,10 +294,10 @@ namespace OpenSim.Region.ScriptEngine.Common.ScriptEngineBase
297 /// <param name="args">Arguments to pass to function</param> 294 /// <param name="args">Arguments to pass to function</param>
298 internal void ExecuteEvent(uint localID, LLUUID itemID, string FunctionName, EventQueueManager.Queue_llDetectParams_Struct qParams, object[] args) 295 internal void ExecuteEvent(uint localID, LLUUID itemID, string FunctionName, EventQueueManager.Queue_llDetectParams_Struct qParams, object[] args)
299 { 296 {
300//cfk 2-7-08 dont need this right now and the default Linux build has DEBUG defined 297 //cfk 2-7-08 dont need this right now and the default Linux build has DEBUG defined
301///#if DEBUG 298 ///#if DEBUG
302/// Console.WriteLine("ScriptEngine: Inside ExecuteEvent for event " + FunctionName); 299 /// Console.WriteLine("ScriptEngine: Inside ExecuteEvent for event " + FunctionName);
303///#endif 300 ///#endif
304 // Execute a function in the script 301 // Execute a function in the script
305 //m_scriptEngine.Log.Info("[" + ScriptEngineName + "]: Executing Function localID: " + localID + ", itemID: " + itemID + ", FunctionName: " + FunctionName); 302 //m_scriptEngine.Log.Info("[" + ScriptEngineName + "]: Executing Function localID: " + localID + ", itemID: " + itemID + ", FunctionName: " + FunctionName);
306 //ScriptBaseInterface Script = (ScriptBaseInterface)GetScript(localID, itemID); 303 //ScriptBaseInterface Script = (ScriptBaseInterface)GetScript(localID, itemID);
@@ -309,10 +306,10 @@ namespace OpenSim.Region.ScriptEngine.Common.ScriptEngineBase
309 { 306 {
310 return; 307 return;
311 } 308 }
312//cfk 2-7-08 dont need this right now and the default Linux build has DEBUG defined 309 //cfk 2-7-08 dont need this right now and the default Linux build has DEBUG defined
313///#if DEBUG 310 ///#if DEBUG
314/// Console.WriteLine("ScriptEngine: Executing event: " + FunctionName); 311 /// Console.WriteLine("ScriptEngine: Executing event: " + FunctionName);
315///#endif 312 ///#endif
316 // Must be done in correct AppDomain, so leaving it up to the script itself 313 // Must be done in correct AppDomain, so leaving it up to the script itself
317 Script.llDetectParams = qParams; 314 Script.llDetectParams = qParams;
318 Script.Exec.ExecuteEvent(FunctionName, args); 315 Script.Exec.ExecuteEvent(FunctionName, args);
@@ -418,15 +415,15 @@ namespace OpenSim.Region.ScriptEngine.Common.ScriptEngineBase
418 415
419 #endregion 416 #endregion
420 417
421 /// <summary> 418 ///// <summary>
422 /// If set to true then threads and stuff should try to make a graceful exit 419 ///// If set to true then threads and stuff should try to make a graceful exit
423 /// </summary> 420 ///// </summary>
424 public bool PleaseShutdown 421 //public bool PleaseShutdown
425 { 422 //{
426 get { return _PleaseShutdown; } 423 // get { return _PleaseShutdown; }
427 set { _PleaseShutdown = value; } 424 // set { _PleaseShutdown = value; }
428 } 425 //}
429 private bool _PleaseShutdown = false; 426 //private bool _PleaseShutdown = false;
430 427
431 } 428 }
432} 429}