mirror of
https://github.com/opensim/opensim.git
synced 2026-08-08 10:15:33 +08:00
Run-time script errors are now shown in-world. No line number though, might require script to be compiled with (slow) debug information.
This commit is contained in:
@@ -45,8 +45,8 @@ namespace OpenSim.Region.ScriptEngine.Common
|
||||
{
|
||||
// IMPORTANT: Types and MemberInfo-derived objects require a LOT of memory.
|
||||
// Instead use RuntimeTypeHandle, RuntimeFieldHandle and RunTimeHandle (IntPtr) instead!
|
||||
try
|
||||
{
|
||||
//try
|
||||
//{
|
||||
if (m_Running == false)
|
||||
{
|
||||
// Script is inactive, do not execute!
|
||||
@@ -68,7 +68,7 @@ namespace OpenSim.Region.ScriptEngine.Common
|
||||
MethodInfo mi = type.GetMethod(EventName);
|
||||
Events.Add(EventName, mi);
|
||||
}
|
||||
catch (Exception e)
|
||||
catch
|
||||
{
|
||||
// Event name not found, cache it as not found
|
||||
Events.Add(EventName, null);
|
||||
@@ -86,19 +86,21 @@ namespace OpenSim.Region.ScriptEngine.Common
|
||||
}
|
||||
|
||||
// Found
|
||||
try
|
||||
{
|
||||
//try
|
||||
//{
|
||||
// Invoke it
|
||||
ev.Invoke(m_Script, args);
|
||||
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
// TODO: Send to correct place
|
||||
Console.WriteLine("ScriptEngine Exception attempting to executing script function: " + e.ToString());
|
||||
}
|
||||
}
|
||||
catch { }
|
||||
//}
|
||||
//catch (Exception e)
|
||||
//{
|
||||
// // TODO: Send to correct place
|
||||
// Console.WriteLine("ScriptEngine Exception attempting to executing script function: " + e.ToString());
|
||||
//}
|
||||
|
||||
|
||||
//}
|
||||
//catch { }
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user