Compare commits

..

3 commits

4 changed files with 14 additions and 9 deletions

View file

@ -1,6 +1,6 @@
buildscript { buildscript {
repositories { repositories {
maven { url = 'https://files.minecraftforge.net/maven' } maven { url = 'https://maven.minecraftforge.net' }
mavenCentral() mavenCentral()
} }
dependencies { dependencies {

View file

@ -4,15 +4,15 @@ org.gradle.daemon=false
author=thetadev author=thetadev
modid=constructionwand modid=constructionwand
mcversion=1.18 mcversion=1.18.1
forgeversion=38.0.16 forgeversion=39.0.0
mcp_channel=official mcp_channel=official
mcp_mappings=1.18 mcp_mappings=1.18.1
# Source: https://maven.blamejared.com/vazkii/botania/Botania/ # Source: https://maven.blamejared.com/vazkii/botania/Botania/
# botania=1.16.2-405 # botania=1.16.2-405
# Source: https://dvs1.progwml6.com/files/maven/mezz/jei/ # Source: https://dvs1.progwml6.com/files/maven/mezz/jei/
jei_version=jei-1.18:9.0.0.40 jei_version=jei-1.18.1:9.1.0.41
version_major=2 version_major=2
version_minor=5 version_minor=6

View file

@ -1,6 +1,7 @@
package thetadev.constructionwand.client; package thetadev.constructionwand.client;
import com.mojang.blaze3d.vertex.PoseStack; import com.mojang.blaze3d.vertex.PoseStack;
import net.minecraft.client.Minecraft;
import net.minecraft.client.gui.components.Button; import net.minecraft.client.gui.components.Button;
import net.minecraft.client.gui.screens.Screen; import net.minecraft.client.gui.screens.Screen;
import net.minecraft.network.chat.Component; import net.minecraft.network.chat.Component;
@ -53,9 +54,13 @@ public class ScreenWand extends Screen
} }
@Override @Override
public boolean charTyped(char character, int code) { public boolean keyPressed(int keyCode, int scanCode, int modifiers) {
if(character == 'e') onClose(); if (Minecraft.getInstance().options.keyInventory.matches(keyCode, scanCode)) {
return super.charTyped(character, code); this.onClose();
return true;
} else {
return super.keyPressed(keyCode, scanCode, modifiers);
}
} }
private void createButton(int cx, int cy, IOption<?> option) { private void createButton(int cx, int cy, IOption<?> option) {

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.5 KiB