(aebb26541) Added localizable connection names to all items (TODO: display in the connection panel interface, load from prefab if the value is not present in a sub or ItemAssembly file)
This commit is contained in:
@@ -12,6 +12,7 @@ namespace Barotrauma.Items.Components
|
||||
public const int MaxLinked = 5;
|
||||
|
||||
public readonly string Name;
|
||||
public readonly string DisplayName;
|
||||
|
||||
private Wire[] wires;
|
||||
public IEnumerable<Wire> Wires
|
||||
@@ -81,6 +82,11 @@ namespace Barotrauma.Items.Components
|
||||
IsOutput = (element.Name.ToString() == "output");
|
||||
Name = element.GetAttributeString("name", (IsOutput) ? "output" : "input");
|
||||
|
||||
DisplayName = element.Attributes("displayname") == null ?
|
||||
Name :
|
||||
TextManager.GetServerMessage(element.GetAttributeString("displayname", Name));
|
||||
|
||||
|
||||
IsPower = Name == "power_in" || Name == "power" || Name == "power_out";
|
||||
|
||||
effects = new List<StatusEffect>();
|
||||
|
||||
Reference in New Issue
Block a user