Esempio n. 1
0
 internal WorldManager(DirectoryDataNode worldDirectory, DataVersion version)
 {
     Node        = worldDirectory;
     Version     = version;
     RegionFiles = Node.Get("region").Expanded().Nodes.Cast <RegionFileDataNode>().ToList();
 }
Esempio n. 2
0
 internal static WorldManager FromWorldDir(DirectoryDataNode worldDirectory)
 {
     var versionTag = worldDirectory.Get("level.dat")
                      .Get("Data")
                      .Get <TagCompoundDataNode>("Version");
     DataVersion v = versionTag is null ? (default) : (DataVersion)versionTag?.GetInt("Id");