Closed Sturmlilie closed 4 years ago
So, this crashes:
@Environment(EnvType.CLIENT)
static final Identifier[] STATE_LOCATIONS = new Identifier[]{
Textures.LOCATION_OVERLAY_MODULE_EXECUTION_IDLE,
Textures.LOCATION_OVERLAY_MODULE_EXECUTION_ERROR,
Textures.LOCATION_OVERLAY_MODULE_EXECUTION_RUNNING,
Textures.LOCATION_OVERLAY_MODULE_EXECUTION_WAITING
};
and this
static final Identifier[] STATE_LOCATIONS = new Identifier[]{
@Environment(EnvType.CLIENT)
Textures.LOCATION_OVERLAY_MODULE_EXECUTION_IDLE,
@Environment(EnvType.CLIENT)
Textures.LOCATION_OVERLAY_MODULE_EXECUTION_ERROR,
@Environment(EnvType.CLIENT)
Textures.LOCATION_OVERLAY_MODULE_EXECUTION_RUNNING,
@Environment(EnvType.CLIENT)
Textures.LOCATION_OVERLAY_MODULE_EXECUTION_WAITING
};
doesn't compile. Regarding the DisplayModule: That was not an array type variable. So I'm kinda out of options, if you know another way I'd be all ear :shrug:
Right you are. The latest docs even make this clear (the ones my 1.15 dev env downloads doesn't, hence my expectations). Thanks for checking!
In that case I'd agree this is the most readable solution. A lambda that checks net.fabricmc.loader.api.FabricLoader.getInstance().getEnvironmentType()
looks pretty noisy.
Fixes crash on dedicated server.
Git bisect saves lives.
(Also could you make a new CurseForge release while at it? :>)