Posted June 3, 20214 yr After trying to read JSON file form resources by Gson gson = new Gson(); Reader reader = Files.newBufferedReader(Paths.get("src/resources/assets/civitas/abilities/abilities.json")); List<String> abilities = Arrays.asList(gson.fromJson(reader, String[].class)); reader.close(); I always get the same message in the Minecraft screen: "Errors in currently selected datapacks prevented world from loading" and in the console: "java.nio.file.NoSuchFileException: src/resources/assets/civitas/abilities/abilities.json" I have also tryed with the path "assets/civitas/abilities/abilities.json" and others, but didn't work. The files on my resources directory are: resources |. data |. |. civitas |. assets |. |. civitas |. |. |. abilities |. |. |. |. abilities.json |. META-INF |. |. mods.toml |. pack.mcmeta Thank you for your help in advance 😊
June 3, 20214 yr Author Thank you a lot for the solution and the advice!! Do you know anywhere were I could learn to use those classes?
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.