diff --git a/OpenRA.Game/FieldLoader.cs b/OpenRA.Game/FieldLoader.cs index a186a678e7..63b99f3988 100644 --- a/OpenRA.Game/FieldLoader.cs +++ b/OpenRA.Game/FieldLoader.cs @@ -438,11 +438,15 @@ namespace OpenRA static object ParseYesNo(string p, Type fieldType, string field) { + if (string.IsNullOrEmpty(p)) + return InvalidValueAction(p, fieldType, field); + p = p.ToLowerInvariant(); if (p == "yes") return true; if (p == "true") return true; if (p == "no") return false; if (p == "false") return false; + return InvalidValueAction(p, fieldType, field); }