From 6f92baf0b50cdb53224dbf8d9a9f69c048ccaf1d Mon Sep 17 00:00:00 2001 From: nossr50 Date: Tue, 5 Nov 2024 17:15:06 -0800 Subject: [PATCH] 2.2.025 --- Changelog.txt | 3 +++ pom.xml | 2 +- .../nossr50/config/experience/ExperienceConfig.java | 9 ++------- 3 files changed, 6 insertions(+), 8 deletions(-) diff --git a/Changelog.txt b/Changelog.txt index bdf8cffa22..dae17e73b0 100644 --- a/Changelog.txt +++ b/Changelog.txt @@ -1,3 +1,6 @@ +Version 2.2.025 + Fixed NullPointerException spam when processing XP for child skills + Version 2.2.024 Fixed errors when Fishing or using Shake ability Significant optimizations made to reading new chunks for mcMMO diff --git a/pom.xml b/pom.xml index 107c074879..a97c47a41f 100644 --- a/pom.xml +++ b/pom.xml @@ -2,7 +2,7 @@ 4.0.0 com.gmail.nossr50.mcMMO mcMMO - 2.2.024 + 2.2.025 mcMMO https://github.com/mcMMO-Dev/mcMMO diff --git a/src/main/java/com/gmail/nossr50/config/experience/ExperienceConfig.java b/src/main/java/com/gmail/nossr50/config/experience/ExperienceConfig.java index 3575eecff1..5b38cdef06 100644 --- a/src/main/java/com/gmail/nossr50/config/experience/ExperienceConfig.java +++ b/src/main/java/com/gmail/nossr50/config/experience/ExperienceConfig.java @@ -19,7 +19,6 @@ import java.util.List; import java.util.Map; -import static com.gmail.nossr50.util.skills.SkillTools.isChildSkill; import static com.gmail.nossr50.util.text.ConfigStringUtils.getConfigEntityTypeString; import static com.gmail.nossr50.util.text.ConfigStringUtils.getMaterialConfigString; @@ -36,12 +35,8 @@ public static ExperienceConfig getInstance() { if (instance == null) { instance = new ExperienceConfig(); for (PrimarySkillType skill : PrimarySkillType.values()) { - // Skip child skills - if (isChildSkill(skill)) { - continue; - } - final Map experienceMap = new HashMap<>(); + instance.blockExperienceMap.put(skill, experienceMap); for (Material material : Material.values()) { int xp = instance.getConfigXp(skill, material); @@ -49,7 +44,7 @@ public static ExperienceConfig getInstance() { experienceMap.put(material, xp); } } - instance.blockExperienceMap.put(skill, experienceMap); + } }