DECORATE parser: let's not use LANGUAGE keywords as actor titles.

This commit is contained in:
MaxED 2014-10-28 21:50:34 +00:00
parent 5eba596a02
commit eba7dabf18

View file

@ -269,13 +269,17 @@ namespace CodeImp.DoomBuilder.Config
// Set the title
if(actor.HasPropertyWithValue("$title"))
title = actor.GetPropertyAllValues("$title");
else if(actor.HasPropertyWithValue("tag"))
title = actor.GetPropertyAllValues("tag");
else if(string.IsNullOrEmpty(title))
title = actor.ClassName;
else if (actor.HasPropertyWithValue("tag"))
{
string tag = actor.GetPropertyAllValues("tag");
if(!tag.StartsWith("\"$")) title = tag; //mxd. Don't use LANGUAGE keywords.
}
if(string.IsNullOrEmpty(title)) title = actor.ClassName;
//mxd. Color override?
if (actor.HasPropertyWithValue("$color")) {
if (actor.HasPropertyWithValue("$color"))
{
int ci = actor.GetPropertyValueInt("$color", 0);
color = (ci == 0 || ci > 19 ? 18 : ci) ;
}