File tree Expand file tree Collapse file tree 1 file changed +14
-2
lines changed
src/main/java/com/falsepattern/lib/internal Expand file tree Collapse file tree 1 file changed +14
-2
lines changed Original file line number Diff line number Diff line change 2323
2424import lombok .AccessLevel ;
2525import lombok .NoArgsConstructor ;
26+ import lombok .val ;
2627import org .apache .logging .log4j .LogManager ;
2728import org .apache .logging .log4j .Logger ;
2829
29- import net .minecraft .launchwrapper .Launch ;
30+ import net .minecraft .launchwrapper .LaunchClassLoader ;
31+
32+ import java .io .IOException ;
3033
3134@ NoArgsConstructor (access = AccessLevel .PRIVATE )
3235public final class Share {
3336 public static final Logger LOG = LogManager .getLogger (Tags .MODNAME );
3437
35- public static final boolean DEV_ENV = (boolean ) Launch .blackboard .get ("fml.deobfuscatedEnvironment" );
38+ public static final boolean DEV_ENV ;
39+
40+ static {
41+ try {
42+ val bs = ((LaunchClassLoader ) Share .class .getClassLoader ()).getClassBytes ("net.minecraft.world.World" );
43+ DEV_ENV = bs != null ;
44+ } catch (IOException e ) {
45+ throw new RuntimeException (e );
46+ }
47+ }
3648}
You can’t perform that action at this time.
0 commit comments