(ad567dea) v0.9.7.1
This commit is contained in:
@@ -152,7 +152,7 @@ namespace Barotrauma
|
||||
public void Save(XElement element)
|
||||
{
|
||||
element.Add(
|
||||
new XAttribute("items", JoinedIdentifiers),
|
||||
new XAttribute("identifiers", JoinedIdentifiers),
|
||||
new XAttribute("type", type.ToString()),
|
||||
new XAttribute("optional", IsOptional),
|
||||
new XAttribute("ignoreineditor", IgnoreInEditor));
|
||||
@@ -219,10 +219,7 @@ namespace Barotrauma
|
||||
string typeStr = element.GetAttributeString("type", "");
|
||||
if (string.IsNullOrEmpty(typeStr))
|
||||
{
|
||||
if (element.Name.ToString().Equals("containable", StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
typeStr = "Contained";
|
||||
}
|
||||
if (element.Name.ToString().ToLowerInvariant() == "containable") typeStr = "Contained";
|
||||
}
|
||||
if (!Enum.TryParse(typeStr, true, out ri.type))
|
||||
{
|
||||
@@ -249,7 +246,7 @@ namespace Barotrauma
|
||||
|
||||
foreach (XElement subElement in element.Elements())
|
||||
{
|
||||
if (!subElement.Name.ToString().Equals("statuseffect", StringComparison.OrdinalIgnoreCase)) { continue; }
|
||||
if (subElement.Name.ToString().ToLowerInvariant() != "statuseffect") continue;
|
||||
ri.statusEffects.Add(StatusEffect.Load(subElement, parentDebugName));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user