mirror of
https://github.com/MineLittlePony/MineLittlePony.git
synced 2025-02-13 16:24:23 +01:00
You can now access the MineLP settings from the main menu (F3)
This commit is contained in:
parent
0d5656685c
commit
fed90010e0
1 changed files with 27 additions and 19 deletions
|
@ -9,6 +9,7 @@ import com.minelittlepony.settings.PonyConfig;
|
|||
|
||||
import net.minecraft.ChatFormat;
|
||||
import net.minecraft.client.MinecraftClient;
|
||||
import net.minecraft.client.gui.MainMenuScreen;
|
||||
import net.minecraft.client.options.KeyBinding;
|
||||
import net.minecraft.client.render.entity.EntityRenderDispatcher;
|
||||
import net.minecraft.client.util.InputUtil;
|
||||
|
@ -63,10 +64,18 @@ public class MineLPClient extends MineLittlePony {
|
|||
}
|
||||
|
||||
public void onTick(MinecraftClient minecraft, boolean inGame) {
|
||||
if (inGame && minecraft.currentScreen == null) {
|
||||
if (keyBinding.isPressed()) {
|
||||
|
||||
inGame &= minecraft.currentScreen == null;
|
||||
|
||||
boolean mainMenu = minecraft.currentScreen instanceof MainMenuScreen;
|
||||
|
||||
if (!inGame && mainMenu) {
|
||||
KeyBinding.updatePressedStates();
|
||||
}
|
||||
|
||||
if ((mainMenu || inGame) && keyBinding.isPressed()) {
|
||||
minecraft.openScreen(new GuiHost(new GuiPonySettings()));
|
||||
} else {
|
||||
} else if (inGame) {
|
||||
long handle = minecraft.window.getHandle();
|
||||
|
||||
if ((SystemUtil.getMeasuringTimeMs() % 10) == 0) {
|
||||
|
@ -87,7 +96,6 @@ public class MineLPClient extends MineLittlePony {
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
PonySkullRenderer.resolve();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue