MCPcopy Create free account
hub / github.com/Garten/sourcecraft / getMinecraftPath

Method getMinecraftPath

src/minecraft/Minecraft.java:37–48  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

35 public static final String PLAYERS_FOLDER = "players";
36
37 public static File getMinecraftPath() {
38 String minecraftPathString = Periphery.CONFIG.getMinecraftPathString();
39 if (minecraftPathString == null) {
40 return getNewMinecraftPath();
41 }
42 File minecraftPath = new File(minecraftPathString);
43 if (!minecraftPath.exists() || !(Config.verifyMinecraftDirectory(minecraftPath))) {
44 return getNewMinecraftPath();
45 }
46 Loggger.log("valid minecraft path: " + Periphery.CONFIG.getMinecraftPathString());
47 return minecraftPath;
48 }
49
50 private static File getNewMinecraftPath() {
51 File minecraftPath;

Callers 2

initSetupMethod · 0.95
getSavesFolderMethod · 0.45

Calls 4

getNewMinecraftPathMethod · 0.95
logMethod · 0.95

Tested by

no test coverage detected