(f0d812055) v0.9.9.0

This commit is contained in:
Joonas Rikkonen
2020-04-23 19:19:37 +03:00
parent b647059b93
commit ac37a3b0e4
391 changed files with 15054 additions and 5420 deletions
@@ -255,6 +255,13 @@ namespace Barotrauma
private set;
}
//if true and the item has trigger areas defined, players can only highlight the item when the cursor is on the trigger
[Serialize(false, false)]
public bool RequireCursorInsideTrigger
{
get;
private set;
}
//should the camera focus on the item when selected
[Serialize(false, false)]
@@ -307,6 +314,20 @@ namespace Barotrauma
private set;
}
[Serialize(false, false)]
public bool DamagedByRepairTools
{
get;
private set;
}
[Serialize(false, false)]
public bool DamagedByMonsters
{
get;
private set;
}
[Serialize(false, false)]
public bool FireProof
{
@@ -535,6 +556,8 @@ namespace Barotrauma
}
Category = category;
var parentType = element.Parent?.GetAttributeString("itemtype", "") ?? string.Empty;
//nameidentifier can be used to make multiple items use the same names and descriptions
string nameIdentifier = element.GetAttributeString("nameidentifier", "");
@@ -566,7 +589,15 @@ namespace Barotrauma
identifier = GenerateLegacyIdentifier(originalName);
}
}
if (string.Equals(parentType, "wrecked", StringComparison.OrdinalIgnoreCase))
{
if (!string.IsNullOrEmpty(name))
{
name = TextManager.GetWithVariable("wreckeditemformat", "[name]", name);
}
}
if (string.IsNullOrEmpty(name))
{
DebugConsole.ThrowError($"Unnamed item ({identifier})in {filePath}!");
@@ -810,7 +841,7 @@ namespace Barotrauma
public PriceInfo GetPrice(Location location)
{
if (prices == null || !prices.ContainsKey(location.Type.Identifier.ToLowerInvariant())) return null;
if (prices == null || !prices.ContainsKey(location.Type.Identifier.ToLowerInvariant())) { return null; }
return prices[location.Type.Identifier.ToLowerInvariant()];
}