The content package a submarine was saved with is included in the submarine preview, added a warning when attempting to start a campaign using a sub with a mismatching content package
This commit is contained in:
@@ -87,6 +87,8 @@ namespace Barotrauma
|
||||
|
||||
public int RecommendedCrewSizeMin = 1, RecommendedCrewSizeMax = 2;
|
||||
public string RecommendedCrewExperience;
|
||||
|
||||
public string ContentPackage;
|
||||
|
||||
//properties ----------------------------------------------------
|
||||
|
||||
@@ -284,6 +286,7 @@ namespace Barotrauma
|
||||
RecommendedCrewSizeMin = doc.Root.GetAttributeInt("recommendedcrewsizemin", 0);
|
||||
RecommendedCrewSizeMax = doc.Root.GetAttributeInt("recommendedcrewsizemax", 0);
|
||||
RecommendedCrewExperience = doc.Root.GetAttributeString("recommendedcrewexperience", "Unknown");
|
||||
ContentPackage = doc.Root.GetAttributeString("contentpackage", "Unknown");
|
||||
|
||||
#if CLIENT
|
||||
string previewImageData = doc.Root.GetAttributeString("previewimage", "");
|
||||
@@ -1198,6 +1201,7 @@ namespace Barotrauma
|
||||
element.Add(new XAttribute("recommendedcrewsizemin", RecommendedCrewSizeMin));
|
||||
element.Add(new XAttribute("recommendedcrewsizemax", RecommendedCrewSizeMax));
|
||||
element.Add(new XAttribute("recommendedcrewexperience", RecommendedCrewExperience ?? ""));
|
||||
element.Add(new XAttribute("contentpackage", ContentPackage ?? ""));
|
||||
|
||||
foreach (MapEntity e in MapEntity.mapEntityList)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user