RunUO 2.4 will be the latest release supporting the 2.0 .NET Framework.

Framework_4_0 preprocessors have been removed. ScriptCompiler will set Framework_4_0 as legacy.
This commit is contained in:
Mark Sturgill 2013-10-30 11:28:34 -07:00
parent 951f8b7d01
commit e67faba4d8
20 changed files with 43 additions and 623 deletions

View file

@ -1139,7 +1139,7 @@ namespace Server
return false;
Type type = typeof(T);
#if Framework_4_0
T tempVal;
if( type.IsEnum && Enum.TryParse( s, true, out tempVal ) )
@ -1152,19 +1152,6 @@ namespace Server
Console.WriteLine( "Could not parse {0} enum attribute '{1}' in element '{2}'", type, attribute, xml.Name );
return false;
}
#else
try
{
value = (T)Enum.Parse(type, s, true);
}
catch
{
Console.WriteLine( "Could not parse {0} enum attribute '{1}' in element '{2}'", type, attribute, xml.Name );
return false;
}
return true;
#endif
}
public static bool ReadMap( XmlElement xml, string attribute, ref Map value )