mirror of
https://github.com/MineLittlePony/MineLittlePony.git
synced 2024-11-22 04:27:59 +01:00
Reload when the config is changed from the back
This commit is contained in:
parent
eb25692aef
commit
55bf4e209f
2 changed files with 6 additions and 1 deletions
|
@ -90,6 +90,7 @@ public class MineLittlePony implements ClientModInitializer {
|
|||
ScreenInitCallback.EVENT.register(this::onScreenInit);
|
||||
|
||||
config.load();
|
||||
config.onChangedExternally(c -> initialized = false);
|
||||
|
||||
Channel.bootstrap();
|
||||
ModelType.bootstrap();
|
||||
|
@ -101,6 +102,10 @@ public class MineLittlePony implements ClientModInitializer {
|
|||
if (!initialized) {
|
||||
initialized = true;
|
||||
renderDispatcher.initialise(client.getEntityRenderDispatcher(), false);
|
||||
|
||||
if (client.currentScreen instanceof PonySettingsScreen screen) {
|
||||
screen.init(client, screen.width, screen.height);
|
||||
}
|
||||
}
|
||||
|
||||
boolean inGame = client.world != null && client.player != null && client.currentScreen == null;
|
||||
|
|
|
@ -75,7 +75,7 @@ public class ArmourTextureResolver implements ArmourTextureLookup, IdentifiableR
|
|||
.filter(ArmourTexture::validate)
|
||||
.findFirst()
|
||||
.or(() -> {
|
||||
MineLittlePony.logger.warn("Could not identify correct texture to use for {}. Was none of: [" + System.lineSeparator() + "{}" + System.lineSeparator() + "]", id, options.stream()
|
||||
MineLittlePony.LOGGER.warn("Could not identify correct texture to use for {}. Was none of: [" + System.lineSeparator() + "{}" + System.lineSeparator() + "]", id, options.stream()
|
||||
.map(ArmourTexture::texture)
|
||||
.map(Identifier::toString)
|
||||
.collect(Collectors.joining("," + System.lineSeparator())));
|
||||
|
|
Loading…
Reference in a new issue