Fix a crash in LaunchArguments when switching mods
This commit is contained in:
@@ -23,6 +23,9 @@ namespace OpenRA
|
|||||||
|
|
||||||
public LaunchArguments(Arguments args)
|
public LaunchArguments(Arguments args)
|
||||||
{
|
{
|
||||||
|
if (args == null)
|
||||||
|
return;
|
||||||
|
|
||||||
foreach (var f in this.GetType().GetFields())
|
foreach (var f in this.GetType().GetFields())
|
||||||
if (args.Contains("Launch" + "." + f.Name))
|
if (args.Contains("Launch" + "." + f.Name))
|
||||||
FieldLoader.LoadField(this, f.Name, args.GetValue("Launch" + "." + f.Name, ""));
|
FieldLoader.LoadField(this, f.Name, args.GetValue("Launch" + "." + f.Name, ""));
|
||||||
|
|||||||
Reference in New Issue
Block a user