2f107db...5202af9

This commit is contained in:
Joonas Rikkonen
2019-03-18 21:42:26 +02:00
parent 58c92888b7
commit 044fd3344b
395 changed files with 27417 additions and 19754 deletions
@@ -34,6 +34,7 @@ namespace Barotrauma
Decals,
NPCConversations,
Afflictions,
Buffs,
Tutorials,
UIStyle
}
@@ -99,6 +100,7 @@ namespace Barotrauma
}
public string SteamWorkshopUrl;
public DateTime? InstallTime;
public bool HideInWorkshopMenu
{
@@ -160,6 +162,10 @@ namespace Barotrauma
CorePackage = doc.Root.GetAttributeBool("corepackage", false);
SteamWorkshopUrl = doc.Root.GetAttributeString("steamworkshopurl", "");
GameVersion = new Version(doc.Root.GetAttributeString("gameversion", "0.0.0.0"));
if (doc.Root.Attribute("installtime") != null)
{
InstallTime = ToolBox.Epoch.ToDateTime(doc.Root.GetAttributeUInt("installtime", 0));
}
List<string> errorMsgs = new List<string>();
foreach (XElement subElement in doc.Root.Elements())
@@ -268,6 +274,11 @@ namespace Barotrauma
doc.Root.Add(new XAttribute("steamworkshopurl", SteamWorkshopUrl));
}
if (InstallTime != null)
{
doc.Root.Add(new XAttribute("installtime", ToolBox.Epoch.FromDateTime(InstallTime.Value)));
}
foreach (ContentFile file in Files)
{
doc.Root.Add(new XElement(file.Type.ToString(), new XAttribute("file", file.Path)));