mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-11-10 14:51:46 +00:00
Fixed broken dialogue customization in USDF parser
https://mantis.zdoom.org/view.php?id=539
This commit is contained in:
parent
dd30d2a045
commit
a27ab73f33
1 changed files with 9 additions and 4 deletions
|
@ -72,8 +72,13 @@ class USDFParser : public UDMFParserBase
|
|||
}
|
||||
type = cls;
|
||||
}
|
||||
if (type && type->IsDescendantOf(RUNTIME_CLASS(AInventory))) return type;
|
||||
return nullptr;
|
||||
return type;
|
||||
}
|
||||
|
||||
PClassActor *CheckInventoryActorType(const char *key)
|
||||
{
|
||||
PClassActor* const type = CheckActorType(key);
|
||||
return nullptr != type && type->IsDescendantOf(RUNTIME_CLASS(AInventory)) ? type : nullptr;
|
||||
}
|
||||
|
||||
//===========================================================================
|
||||
|
@ -94,7 +99,7 @@ class USDFParser : public UDMFParserBase
|
|||
switch(key)
|
||||
{
|
||||
case NAME_Item:
|
||||
check.Item = CheckActorType(key);
|
||||
check.Item = CheckInventoryActorType(key);
|
||||
break;
|
||||
|
||||
case NAME_Amount:
|
||||
|
@ -273,7 +278,7 @@ class USDFParser : public UDMFParserBase
|
|||
switch(key)
|
||||
{
|
||||
case NAME_Item:
|
||||
check.Item = CheckActorType(key);
|
||||
check.Item = CheckInventoryActorType(key);
|
||||
break;
|
||||
|
||||
case NAME_Count:
|
||||
|
|
Loading…
Reference in a new issue