dont always regenerate uuid

This commit is contained in:
zimzaza4
2024-07-23 17:40:24 +08:00
parent b6e6a27c10
commit 274abe432a

View File

@@ -103,6 +103,7 @@ public class GeneratorMain {
}
File animationsFolder = new File(output, "animations");
File entityFolder = new File(output, "entity");
File modelsFolder = new File(output, "models/entity");
File texturesFolder = new File(output, "textures/entity");
File animationControllersFolder = new File(output, "animation_controllers");
@@ -111,17 +112,18 @@ public class GeneratorMain {
File manifestFile = new File(output, "manifest.json");
output.mkdirs();
Path path = manifestFile.toPath();
if (!path.toFile().exists()) {
if (!manifestFile.exists()) {
try {
Files.writeString(path,
Files.writeString(manifestFile.toPath(),
PackManifest.generate(), StandardCharsets.UTF_8);
} catch (IOException e) {
e.printStackTrace();
}
}
animationsFolder.mkdirs();
entityFolder.mkdirs();
modelsFolder.mkdirs();