v1.2.6.0 (Winter Update)

This commit is contained in:
Regalis11
2023-12-14 16:11:27 +02:00
parent af8cc89fce
commit b91e85559d
375 changed files with 7771 additions and 2874 deletions
@@ -122,6 +122,9 @@ namespace Barotrauma
public OutpostModuleInfo OutpostModuleInfo { get; set; }
public BeaconStationInfo BeaconStationInfo { get; set; }
public WreckInfo WreckInfo { get; set; }
public ExtraSubmarineInfo GetExtraSubmarineInfo => BeaconStationInfo ?? WreckInfo as ExtraSubmarineInfo;
public bool IsOutpost => Type == SubmarineType.Outpost || Type == SubmarineType.OutpostModule;
@@ -320,10 +323,14 @@ namespace Barotrauma
{
OutpostModuleInfo = new OutpostModuleInfo(original.OutpostModuleInfo);
}
if (original.BeaconStationInfo != null)
else if (original.BeaconStationInfo != null)
{
BeaconStationInfo = new BeaconStationInfo(original.BeaconStationInfo);
}
else if (original.WreckInfo != null)
{
WreckInfo = new WreckInfo(original.WreckInfo);
}
#if CLIENT
PreviewImage = original.PreviewImage != null ? new Sprite(original.PreviewImage) : null;
#endif
@@ -410,6 +417,10 @@ namespace Barotrauma
{
BeaconStationInfo = new BeaconStationInfo(this, SubmarineElement);
}
else if (Type == SubmarineType.Wreck)
{
WreckInfo = new WreckInfo(this, SubmarineElement);
}
}
}
@@ -589,6 +600,11 @@ namespace Barotrauma
BeaconStationInfo.Save(newElement);
BeaconStationInfo = new BeaconStationInfo(this, newElement);
}
else if (Type == SubmarineType.Wreck)
{
WreckInfo.Save(newElement);
WreckInfo = new WreckInfo(this, newElement);
}
XDocument doc = new XDocument(newElement);
doc.Root.Add(new XAttribute("name", Name));