Build 0.21.6.0 (1.0 pre-patch)
This commit is contained in:
@@ -1143,14 +1143,13 @@ namespace Barotrauma
|
||||
bool wrap = element.GetAttributeBool("wrap", true);
|
||||
Alignment alignment =
|
||||
element.GetAttributeEnum("alignment", text.Contains('\n') ? Alignment.Left : Alignment.Center);
|
||||
GUIFont font;
|
||||
if (!GUIStyle.Fonts.TryGetValue(element.GetAttributeIdentifier("font", "Font"), out font))
|
||||
if (!GUIStyle.Fonts.TryGetValue(element.GetAttributeIdentifier("font", "Font"), out GUIFont font))
|
||||
{
|
||||
font = GUIStyle.Font;
|
||||
}
|
||||
|
||||
var textBlock = new GUITextBlock(RectTransform.Load(element, parent),
|
||||
text, color, font, alignment, wrap: wrap, style: style)
|
||||
RichString.Rich(text), color, font, alignment, wrap: wrap, style: style)
|
||||
{
|
||||
TextScale = scale
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user