mirror of
https://gitgud.io/AbstractConcept/rimworld-animation-studio.git
synced 2024-08-15 00:43:27 +00:00
Squashed commit of the following:
commitaf4dab5546
Author: AbstractConcept <abstract.concept@mail.com> Date: Mon Oct 31 19:58:41 2022 -0500 Code refactor commite14a12f2ab
Author: AbstractConcept <abstract.concept@mail.com> Date: Mon Oct 31 00:44:53 2022 -0500 Code refactor commit5ca7e486f8
Author: AbstractConcept <abstract.concept@mail.com> Date: Fri Oct 28 19:52:58 2022 -0500 Code refactor commita55ba7b95b
Author: AbstractConcept <abstract.concept@mail.com> Date: Fri Oct 28 00:28:51 2022 -0500 Code refactor commit757badf4f6
Author: AbstractConcept <abstract.concept@mail.com> Date: Thu Oct 27 00:56:04 2022 -0500 Code refactor
This commit is contained in:
parent
cd4711a8e5
commit
bb2cc29393
603 changed files with 9200 additions and 7528 deletions
|
@ -13,14 +13,11 @@ namespace RimWorldAnimationStudio
|
|||
{
|
||||
public static T ReadXML<T>(string path)
|
||||
{
|
||||
//Debug.Log("Reading data from " + path);
|
||||
|
||||
using (StreamReader stringReader = new StreamReader(path))
|
||||
{
|
||||
XmlSerializer serializer = new XmlSerializer(typeof(T));
|
||||
var data = (T)serializer.Deserialize(stringReader);
|
||||
|
||||
//Debug.Log("Read successful");
|
||||
return data;
|
||||
}
|
||||
}
|
||||
|
@ -30,8 +27,6 @@ namespace RimWorldAnimationStudio
|
|||
if (obj == null || path == null || path == "")
|
||||
{ return; }
|
||||
|
||||
//Debug.Log("Saving data to " + path);
|
||||
|
||||
XmlSerializer writer = new XmlSerializer(typeof(T));
|
||||
XmlSerializerNamespaces nameSpaces = new XmlSerializerNamespaces();
|
||||
nameSpaces.Add("", "");
|
||||
|
@ -39,8 +34,6 @@ namespace RimWorldAnimationStudio
|
|||
FileStream file = File.Create(path);
|
||||
writer.Serialize(file, obj, nameSpaces);
|
||||
file.Close();
|
||||
|
||||
//Debug.Log("Saving successful");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue