Fix deobfuscation check not working on Forge 1.18+

This commit is contained in:
embeddedt 2023-10-25 14:22:20 -04:00
parent c5a5b01bfb
commit b943dc1449

View File

@ -235,7 +235,7 @@ public class ModernFixEarlyConfig {
if(!ModernFixPlatformHooks.INSTANCE.isDevEnv())
return;
try {
if(ModernFixEarlyConfig.class.getResource("/net/minecraft/world/level/Level.class") == null) {
if(ModernFixEarlyConfig.class.getClassLoader().getResource("/net/minecraft/world/level/Level.class") == null) {
LOGGER.warn("We are in a non-Mojmap dev environment. Disabling blockstate cache patch");
this.options.get("mixin.perf.reduce_blockstate_cache_rebuilds").addModOverride(false, "[not mojmap]");
}