mirror of
https://github.com/opensim/opensim.git
synced 2026-05-16 03:36:04 +08:00
Formatting cleanup, minor refactoring, svn properties.
This commit is contained in:
@@ -37,25 +37,25 @@ namespace OpenSim.Region.ScriptEngine.XEngine.Script
|
||||
public static Assembly OnAssemblyResolve(object sender,
|
||||
ResolveEventArgs args)
|
||||
{
|
||||
if(!(sender is System.AppDomain))
|
||||
if (!(sender is System.AppDomain))
|
||||
return null;
|
||||
|
||||
AppDomain myDomain = (AppDomain)sender;
|
||||
string dirName = myDomain.FriendlyName;
|
||||
|
||||
string[] pathList=new string[] {"bin", "ScriptEngines",
|
||||
Path.Combine("ScriptEngines", dirName)};
|
||||
string[] pathList = new string[] {"bin", "ScriptEngines",
|
||||
Path.Combine("ScriptEngines", dirName)};
|
||||
|
||||
string assemblyName = args.Name;
|
||||
if(assemblyName.IndexOf(",") != -1)
|
||||
assemblyName=args.Name.Substring(0, args.Name.IndexOf(","));
|
||||
if (assemblyName.IndexOf(",") != -1)
|
||||
assemblyName = args.Name.Substring(0, args.Name.IndexOf(","));
|
||||
|
||||
foreach (string s in pathList)
|
||||
{
|
||||
string path=Path.Combine(Directory.GetCurrentDirectory(),
|
||||
string path = Path.Combine(Directory.GetCurrentDirectory(),
|
||||
Path.Combine(s, assemblyName))+".dll";
|
||||
|
||||
if(File.Exists(path))
|
||||
if (File.Exists(path))
|
||||
return Assembly.LoadFrom(path);
|
||||
}
|
||||
|
||||
|
||||
@@ -106,7 +106,7 @@ namespace OpenSim.Region.ScriptEngine.XEngine.Script
|
||||
{
|
||||
foreach (KeyValuePair<string, object> var in vars)
|
||||
{
|
||||
if(m_Fields.ContainsKey(var.Key))
|
||||
if (m_Fields.ContainsKey(var.Key))
|
||||
{
|
||||
m_Fields[var.Key].SetValue(this, var.Value);
|
||||
}
|
||||
|
||||
@@ -1212,8 +1212,8 @@ namespace OpenSim.Region.ScriptEngine.XEngine.Script
|
||||
|
||||
public LSLInteger(Object o)
|
||||
{
|
||||
if(!(o is Int32))
|
||||
value=0;
|
||||
if (!(o is Int32))
|
||||
value = 0;
|
||||
else
|
||||
value = (int)o;
|
||||
}
|
||||
@@ -1327,11 +1327,11 @@ namespace OpenSim.Region.ScriptEngine.XEngine.Script
|
||||
|
||||
public override bool Equals(object o)
|
||||
{
|
||||
if(o is Int32)
|
||||
if (o is Int32)
|
||||
{
|
||||
return value == (Int32)o;
|
||||
}
|
||||
if(o is LSLInteger)
|
||||
if (o is LSLInteger)
|
||||
{
|
||||
return value == ((LSLInteger)o).value;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user