diff --git a/src/p_usdf.cpp b/src/p_usdf.cpp index e8ce5ca500..a64dc932fe 100644 --- a/src/p_usdf.cpp +++ b/src/p_usdf.cpp @@ -210,19 +210,16 @@ class USDFParser : public UDMFParserBase { switch(key) { + case NAME_Cost: case NAME_Require: case NAME_Exclude: - // Print a warning if the namespace is not ZDoom otherwise fall-through. [FishyClockwork] - if (namespace_bits != Zd) + // Require and Exclude are exclusive to namespace ZDoom. [FishyClockwork] + if (key == NAME_Cost || namespace_bits == Zd) { - sc.ScriptMessage("Detected \"%s\" block, ignoring. Require/Exclude are exclusive to namespace ZDoom.", key == NAME_Require ? "Require" : "Exclude"); - while (!sc.CheckToken('}')) sc.MustGetAnyToken(); // Skip this block + ParseCostRequireExclude(reply, key); break; } - - case NAME_Cost: - ParseCostRequireExclude(reply, key); - break; + // Intentional fall-through default: sc.UnGet();