Merge pull request #3687 from pchote/mapoptions

Lobby map option improvements.
This commit is contained in:
Matthias Mailänder
2013-08-17 02:42:23 -07:00
35 changed files with 749 additions and 162 deletions

View File

@@ -276,6 +276,13 @@ namespace OpenRA.FileFormats
return fieldType.GetConstructor(argTypes).Invoke(argValues);
}
else if (fieldType.IsGenericType && fieldType.GetGenericTypeDefinition() == typeof(Nullable<>))
{
var innerType = fieldType.GetGenericArguments().First();
var innerValue = GetValue("Nullable<T>", innerType, x);
return fieldType.GetConstructor(new []{ innerType }).Invoke(new []{ innerValue });
}
UnknownFieldAction("[Type] {0}".F(x), fieldType);
return null;
}

View File

@@ -39,7 +39,6 @@ namespace OpenRA.FileFormats
public bool LockTeam = false;
public int Team = 0;
public int InitialCash = 0;
public string[] Allies = {};
public string[] Enemies = {};