You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
29 lines
661 B
29 lines
661 B
using System;
|
|
|
|
namespace Babushka.scripts.CSharp.Common.Savegame;
|
|
|
|
/// <summary>
|
|
/// Central structure for SaveData entries.
|
|
/// SceneName and ID are later combined and used as keys for the save system.
|
|
/// </summary>
|
|
[Serializable]
|
|
public class SaveData
|
|
{
|
|
// for future use in case the structure changes.
|
|
public const int VERSION = 1;
|
|
public int version { get; set; } = VERSION;
|
|
|
|
public bool IsVersionValid()
|
|
{
|
|
return VERSION == version;
|
|
}
|
|
|
|
public string SceneName;
|
|
public string Id;
|
|
public string JsonPayload;
|
|
|
|
public string ToString()
|
|
{
|
|
return SceneName + " " + Id + " " + JsonPayload;
|
|
}
|
|
} |