mirror of
https://git.do.srb2.org/STJr/UltimateZoneBuilder.git
synced 2024-11-23 20:32:34 +00:00
Improved category matching for DECORATE things into the Things list
This commit is contained in:
parent
52f9feedf9
commit
995b87b574
1 changed files with 9 additions and 1 deletions
|
@ -1148,10 +1148,18 @@ namespace CodeImp.DoomBuilder.Data
|
|||
else
|
||||
{
|
||||
// Find the category to put the actor in
|
||||
// First search by Title, then search by Name
|
||||
ThingCategory cat = null;
|
||||
foreach(ThingCategory c in thingcategories)
|
||||
{
|
||||
if(c.Name == catname) cat = c;
|
||||
if(c.Title.ToLowerInvariant() == catname) cat = c;
|
||||
}
|
||||
if(cat == null)
|
||||
{
|
||||
foreach(ThingCategory c in thingcategories)
|
||||
{
|
||||
if(c.Name.ToLowerInvariant() == catname) cat = c;
|
||||
}
|
||||
}
|
||||
|
||||
// Make the category if needed
|
||||
|
|
Loading…
Reference in a new issue