mirror of
https://github.com/TeamMidnightDust/MidnightControls.git
synced 2025-12-13 15:25:08 +01:00
Compare commits
20 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
3863c45f26 | ||
|
|
0036baee3e | ||
|
|
5323b72268 | ||
|
|
fdb1024ee3 | ||
|
|
d48952fec9 | ||
|
|
9deab7228d | ||
|
|
b4d82a7230 | ||
|
|
36e241e438 | ||
|
|
bdbee99fe2 | ||
|
|
439cd0858e | ||
|
|
617648cf57 | ||
|
|
89914a1b6e | ||
|
|
c272fb457f | ||
|
|
308b41094f | ||
|
|
bf7209083a | ||
|
|
187844db2b | ||
|
|
24ced76d06 | ||
|
|
aa75a58a4d | ||
|
|
1f675622f0 | ||
|
|
2d902bbf3c |
28
build.gradle
28
build.gradle
@@ -1,5 +1,5 @@
|
|||||||
plugins {
|
plugins {
|
||||||
id 'fabric-loom' version '0.12-SNAPSHOT'
|
id 'fabric-loom' version '1.0-SNAPSHOT'
|
||||||
id 'java-library'
|
id 'java-library'
|
||||||
id 'maven-publish'
|
id 'maven-publish'
|
||||||
id 'com.github.johnrengelman.shadow' version '7.0.0'
|
id 'com.github.johnrengelman.shadow' version '7.0.0'
|
||||||
@@ -32,7 +32,7 @@ boolean isMCVersionNonRelease() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
String getMCVersionString() {
|
String getMCVersionString() {
|
||||||
if (isMCVersionNonRelease()) {
|
if (isMCVersionNonRelease() || project.minecraft_version == "1.19.3") {
|
||||||
return project.minecraft_version
|
return project.minecraft_version
|
||||||
}
|
}
|
||||||
def version = project.minecraft_version.split('\\.')
|
def version = project.minecraft_version.split('\\.')
|
||||||
@@ -102,7 +102,9 @@ dependencies {
|
|||||||
}
|
}
|
||||||
include 'org.aperlambda:lambdajcommon:1.8.1'
|
include 'org.aperlambda:lambdajcommon:1.8.1'
|
||||||
|
|
||||||
modImplementation "com.terraformersmc:modmenu:${project.modmenu_version}"
|
modCompileOnlyApi ("com.terraformersmc:modmenu:${project.modmenu_version}") {
|
||||||
|
exclude(group: "net.fabricmc.fabric-api")
|
||||||
|
}
|
||||||
|
|
||||||
// Compatibility mods
|
// Compatibility mods
|
||||||
|
|
||||||
@@ -110,15 +112,19 @@ dependencies {
|
|||||||
// modImplementation("maven.modrinth:ok-zoomer:${project.ok_zoomer_version}")
|
// modImplementation("maven.modrinth:ok-zoomer:${project.ok_zoomer_version}")
|
||||||
// modImplementation "io.github.ennuil:LibZoomer:${project.libzoomer_version}"
|
// modImplementation "io.github.ennuil:LibZoomer:${project.libzoomer_version}"
|
||||||
|
|
||||||
modImplementation "io.github.cottonmc:LibGui:${project.libgui_version}"
|
modCompileOnlyApi ("io.github.cottonmc:LibGui:${project.libgui_version}") {
|
||||||
modImplementation "org.quiltmc:quilt-json5:1.0.0"
|
exclude(group: "net.fabricmc.fabric-api")
|
||||||
|
}
|
||||||
|
modCompileOnlyApi "org.quiltmc:quilt-json5:1.0.0"
|
||||||
modCompileOnly "maven.modrinth:sodium:${project.sodium_version}"
|
modCompileOnly "maven.modrinth:sodium:${project.sodium_version}"
|
||||||
modImplementation("maven.modrinth:emi:${project.emi_version}")
|
modImplementation "maven.modrinth:emi:${project.emi_version}"
|
||||||
modImplementation "maven.modrinth:emotecraft:${project.emotecraft_version}"
|
modCompileOnlyApi "maven.modrinth:emotecraft:${project.emotecraft_version}"
|
||||||
modImplementation "io.github.kosmx:bendy-lib:${project.bendylib_version}"
|
modCompileOnlyApi "io.github.kosmx:bendy-lib:${project.bendylib_version}"
|
||||||
modImplementation "dev.isxander:yet-another-config-lib:${project.yacl_version}"
|
modImplementation ("dev.isxander:yet-another-config-lib:${project.yacl_version}") {
|
||||||
modImplementation "maven.modrinth:inventory-tabs-updated:${project.inventorytabs_version}"
|
exclude(group: "net.fabricmc.fabric-api")
|
||||||
modImplementation "maven.modrinth:bedrockify:${project.bedrockify_version}"
|
}
|
||||||
|
modCompileOnlyApi "maven.modrinth:inventory-tabs-updated:${project.inventorytabs_version}"
|
||||||
|
modCompileOnlyApi "maven.modrinth:bedrockify:${project.bedrockify_version}"
|
||||||
// Required for Inventory Tabs
|
// Required for Inventory Tabs
|
||||||
modApi("me.shedaniel.cloth:cloth-config-fabric:${project.clothconfig_version}") {
|
modApi("me.shedaniel.cloth:cloth-config-fabric:${project.clothconfig_version}") {
|
||||||
exclude(group: "net.fabricmc.fabric-api")
|
exclude(group: "net.fabricmc.fabric-api")
|
||||||
|
|||||||
@@ -4,29 +4,29 @@ org.gradle.jvmargs=-Xmx1G
|
|||||||
# Fabric Properties
|
# Fabric Properties
|
||||||
# check these on https://fabricmc.net/use
|
# check these on https://fabricmc.net/use
|
||||||
minecraft_version=1.19.2
|
minecraft_version=1.19.2
|
||||||
yarn_mappings=1.19.2+build.9
|
yarn_mappings=1.19.2+build.28
|
||||||
loader_version=0.14.9
|
loader_version=0.14.12
|
||||||
|
|
||||||
# Mod Properties
|
# Mod Properties
|
||||||
mod_version = 1.7.1
|
mod_version = 1.7.4
|
||||||
maven_group = eu.midnightdust
|
maven_group = eu.midnightdust
|
||||||
archives_base_name = midnightcontrols
|
archives_base_name = midnightcontrols
|
||||||
modrinth_id=bXX9h73M
|
modrinth_id=bXX9h73M
|
||||||
|
|
||||||
# Dependencies
|
# Dependencies
|
||||||
# currently not on the main fabric site, check on the maven: https://maven.fabricmc.net/net/fabricmc/fabric-api/fabric-api
|
# currently not on the main fabric site, check on the maven: https://maven.fabricmc.net/net/fabricmc/fabric-api/fabric-api
|
||||||
fabric_version=0.60.0+1.19.2
|
fabric_version=0.72.0+1.19.2
|
||||||
sodium_version=mc1.19.2-0.4.4
|
sodium_version=mc1.19.2-0.4.4
|
||||||
spruceui_version=4.0.0+1.19
|
spruceui_version=4.0.0+1.19
|
||||||
midnightlib_version=0.6.1
|
midnightlib_version=1.0.0-fabric
|
||||||
modmenu_version=4.0.6
|
modmenu_version=5.0.1
|
||||||
emotecraft_version=2.1.3-SNAPSHOT-build.29-MC1.19-fabric
|
emotecraft_version=2.1.3-SNAPSHOT-build.29-MC1.19-fabric
|
||||||
bendylib_version=2.0.+
|
bendylib_version=2.0.+
|
||||||
emi_version=0.4.0+1.19
|
emi_version=0.5.3+1.19.2
|
||||||
libgui_version=6.0.0+1.19
|
libgui_version=6.0.0+1.19
|
||||||
inventorytabs_version=inventorytabs-0.9.beta-1.19.x
|
inventorytabs_version=inventorytabs-0.9.beta-1.19.x
|
||||||
clothconfig_version=7.0.72
|
clothconfig_version=7.0.72
|
||||||
yacl_version=0.1.2
|
yacl_version=1.7.1
|
||||||
bedrockify_version=1.5+mc1.19.1-2
|
bedrockify_version=1.5+mc1.19.1-2
|
||||||
|
|
||||||
# Ok Zoomer and LibZoomer are temporarily disabled for the time being, as we are currently using Reflection at runtime instead in OkZoomerCompat due to there being two major, completely incompatible API versions.
|
# Ok Zoomer and LibZoomer are temporarily disabled for the time being, as we are currently using Reflection at runtime instead in OkZoomerCompat due to there being two major, completely incompatible API versions.
|
||||||
|
|||||||
@@ -173,9 +173,9 @@ public class MidnightControlsClient extends MidnightControls implements ClientMo
|
|||||||
voxelmapInitDone = true;
|
voxelmapInitDone = true;
|
||||||
}
|
}
|
||||||
if (lateInitDone) return;
|
if (lateInitDone) return;
|
||||||
if (KeyBindingRegistryImplAccessor.getModdedKeyBindings() == null || KeyBindingRegistryImplAccessor.getModdedKeyBindings().isEmpty()) return;
|
if (KeyBindingRegistryImplAccessor.getMODDED_KEY_BINDINGS() == null || KeyBindingRegistryImplAccessor.getMODDED_KEY_BINDINGS().isEmpty()) return;
|
||||||
for (int i = 0; i < KeyBindingRegistryImplAccessor.getModdedKeyBindings().size(); ++i) {
|
for (int i = 0; i < KeyBindingRegistryImplAccessor.getMODDED_KEY_BINDINGS().size(); ++i) {
|
||||||
KeyBinding keyBinding = KeyBindingRegistryImplAccessor.getModdedKeyBindings().get(i);
|
KeyBinding keyBinding = KeyBindingRegistryImplAccessor.getMODDED_KEY_BINDINGS().get(i);
|
||||||
if (!keyBinding.getTranslationKey().contains("midnightcontrols") && !keyBinding.getTranslationKey().contains("ok_zoomer") && !keyBinding.getTranslationKey().contains("okzoomer")) {
|
if (!keyBinding.getTranslationKey().contains("midnightcontrols") && !keyBinding.getTranslationKey().contains("ok_zoomer") && !keyBinding.getTranslationKey().contains("okzoomer")) {
|
||||||
category = null;
|
category = null;
|
||||||
InputManager.streamCategories().forEach(buttonCategory -> {
|
InputManager.streamCategories().forEach(buttonCategory -> {
|
||||||
|
|||||||
@@ -41,6 +41,7 @@ public class MidnightControlsConfig extends MidnightConfig {
|
|||||||
// HUD
|
// HUD
|
||||||
@Entry(name = "midnightcontrols.menu.hud_enable") public static boolean hudEnable = true;
|
@Entry(name = "midnightcontrols.menu.hud_enable") public static boolean hudEnable = true;
|
||||||
@Entry(name = "midnightcontrols.menu.hud_side") public static HudSide hudSide = HudSide.LEFT;
|
@Entry(name = "midnightcontrols.menu.hud_side") public static HudSide hudSide = HudSide.LEFT;
|
||||||
|
@Entry(name = "midnightcontrols.menu.move_chat") public static boolean moveChat = false;
|
||||||
// Gameplay
|
// Gameplay
|
||||||
@Entry(name = "midnightcontrols.menu.analog_movement") public static boolean analogMovement = true;
|
@Entry(name = "midnightcontrols.menu.analog_movement") public static boolean analogMovement = true;
|
||||||
@Entry(name = "midnightcontrols.menu.double_tap_to_sprint") public static boolean doubleTapToSprint = true;
|
@Entry(name = "midnightcontrols.menu.double_tap_to_sprint") public static boolean doubleTapToSprint = true;
|
||||||
@@ -61,6 +62,7 @@ public class MidnightControlsConfig extends MidnightConfig {
|
|||||||
@Entry(name = "midnightcontrols.menu.rotation_speed") public static double rotationSpeed = 40.0; //used for x-axis, name kept for compatability
|
@Entry(name = "midnightcontrols.menu.rotation_speed") public static double rotationSpeed = 40.0; //used for x-axis, name kept for compatability
|
||||||
@Entry(name = "midnightcontrols.menu.y_axis_rotation_speed") public static double yAxisRotationSpeed = rotationSpeed;
|
@Entry(name = "midnightcontrols.menu.y_axis_rotation_speed") public static double yAxisRotationSpeed = rotationSpeed;
|
||||||
@Entry(name = "midnightcontrols.menu.mouse_speed") public static double mouseSpeed = 25.0;
|
@Entry(name = "midnightcontrols.menu.mouse_speed") public static double mouseSpeed = 25.0;
|
||||||
|
@Entry(name = "midnightcontrols.menu.joystick_as_mouse") public static boolean joystickAsMouse = false;
|
||||||
@Entry(name = "midnightcontrols.menu.unfocused_input") public static boolean unfocusedInput = false;
|
@Entry(name = "midnightcontrols.menu.unfocused_input") public static boolean unfocusedInput = false;
|
||||||
@Entry(name = "midnightcontrols.menu.virtual_mouse") public static boolean virtualMouse = false;
|
@Entry(name = "midnightcontrols.menu.virtual_mouse") public static boolean virtualMouse = false;
|
||||||
@Entry(name = "midnightcontrols.menu.virtual_mouse.skin") public static VirtualMouseSkin virtualMouseSkin = VirtualMouseSkin.DEFAULT_LIGHT;
|
@Entry(name = "midnightcontrols.menu.virtual_mouse.skin") public static VirtualMouseSkin virtualMouseSkin = VirtualMouseSkin.DEFAULT_LIGHT;
|
||||||
@@ -350,7 +352,7 @@ public class MidnightControlsConfig extends MidnightConfig {
|
|||||||
else if (controller.contains("xbox") || controller.contains("afterglow")) return ControllerType.XBOX;
|
else if (controller.contains("xbox") || controller.contains("afterglow")) return ControllerType.XBOX;
|
||||||
else if (controller.contains("steam deck")) return ControllerType.STEAM_DECK;
|
else if (controller.contains("steam deck")) return ControllerType.STEAM_DECK;
|
||||||
else if (controller.contains("steam")) return ControllerType.STEAM_CONTROLLER;
|
else if (controller.contains("steam")) return ControllerType.STEAM_CONTROLLER;
|
||||||
else if (controller.contains("dualsense")) return ControllerType.DUALSENSE;
|
else if (controller.contains("dualsense") || controller.contains("ps5")) return ControllerType.DUALSENSE;
|
||||||
else if (controller.contains("dualshock") || controller.contains("ps4") || controller.contains("sony")) return ControllerType.DUALSHOCK;
|
else if (controller.contains("dualshock") || controller.contains("ps4") || controller.contains("sony")) return ControllerType.DUALSHOCK;
|
||||||
else if (controller.contains("switch") || controller.contains("joy-con") || controller.contains("wii") || controller.contains("nintendo")) return ControllerType.SWITCH;
|
else if (controller.contains("switch") || controller.contains("joy-con") || controller.contains("wii") || controller.contains("nintendo")) return ControllerType.SWITCH;
|
||||||
else if (controller.contains("ouya")) return ControllerType.OUYA;
|
else if (controller.contains("ouya")) return ControllerType.OUYA;
|
||||||
|
|||||||
@@ -13,10 +13,7 @@ import com.google.common.collect.ImmutableSet;
|
|||||||
import dev.lambdaurora.spruceui.widget.AbstractSpruceWidget;
|
import dev.lambdaurora.spruceui.widget.AbstractSpruceWidget;
|
||||||
import dev.lambdaurora.spruceui.widget.container.SpruceEntryListWidget;
|
import dev.lambdaurora.spruceui.widget.container.SpruceEntryListWidget;
|
||||||
import eu.midnightdust.midnightcontrols.MidnightControls;
|
import eu.midnightdust.midnightcontrols.MidnightControls;
|
||||||
import eu.midnightdust.midnightcontrols.client.compat.EmotecraftCompat;
|
import eu.midnightdust.midnightcontrols.client.compat.*;
|
||||||
import eu.midnightdust.midnightcontrols.client.compat.LibGuiCompat;
|
|
||||||
import eu.midnightdust.midnightcontrols.client.compat.MidnightControlsCompat;
|
|
||||||
import eu.midnightdust.midnightcontrols.client.compat.SodiumCompat;
|
|
||||||
import eu.midnightdust.midnightcontrols.client.controller.ButtonBinding;
|
import eu.midnightdust.midnightcontrols.client.controller.ButtonBinding;
|
||||||
import eu.midnightdust.midnightcontrols.client.controller.Controller;
|
import eu.midnightdust.midnightcontrols.client.controller.Controller;
|
||||||
import eu.midnightdust.midnightcontrols.client.controller.InputManager;
|
import eu.midnightdust.midnightcontrols.client.controller.InputManager;
|
||||||
@@ -695,6 +692,8 @@ public class MidnightInput {
|
|||||||
var childFocused = widget.getFocused();
|
var childFocused = widget.getFocused();
|
||||||
if (childFocused != null)
|
if (childFocused != null)
|
||||||
return this.handleAButton(screen, childFocused);
|
return this.handleAButton(screen, childFocused);
|
||||||
|
} else if (FabricLoader.getInstance().isModLoaded("yet-another-config-lib") && YACLCompat.handleAButton(screen, focused)) {
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@@ -711,6 +710,10 @@ public class MidnightInput {
|
|||||||
this.actionGuiCooldown = 5;
|
this.actionGuiCooldown = 5;
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
if (FabricLoader.getInstance().isModLoaded("yet-another-config-lib") && YACLCompat.handleLeftRight(screen, right)) {
|
||||||
|
this.actionGuiCooldown = 5;
|
||||||
|
return false;
|
||||||
|
}
|
||||||
var focused = screen.getFocused();
|
var focused = screen.getFocused();
|
||||||
if (focused != null)
|
if (focused != null)
|
||||||
if (this.handleRightLeftElement(focused, right))
|
if (this.handleRightLeftElement(focused, right))
|
||||||
@@ -858,7 +861,7 @@ public class MidnightInput {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public static boolean isScreenInteractive(@NotNull Screen screen) {
|
public static boolean isScreenInteractive(@NotNull Screen screen) {
|
||||||
return !(screen instanceof HandledScreen || MidnightControlsConfig.mouseScreens.stream().anyMatch(a -> screen.getClass().toString().contains(a))
|
return !(screen instanceof HandledScreen || MidnightControlsConfig.joystickAsMouse || MidnightControlsConfig.mouseScreens.stream().anyMatch(a -> screen.getClass().toString().contains(a))
|
||||||
|| (screen instanceof SpruceScreen && ((SpruceScreen) screen).requiresCursor())
|
|| (screen instanceof SpruceScreen && ((SpruceScreen) screen).requiresCursor())
|
||||||
|| MidnightControlsCompat.requireMouseOnScreen(screen));
|
|| MidnightControlsCompat.requireMouseOnScreen(screen));
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
package eu.midnightdust.midnightcontrols.client.compat;
|
package eu.midnightdust.midnightcontrols.client.compat;
|
||||||
|
|
||||||
import dev.emi.emi.EmiConfig;
|
import dev.emi.emi.config.EmiConfig;
|
||||||
import dev.emi.emi.screen.EmiScreen;
|
import dev.emi.emi.screen.EmiScreen;
|
||||||
import dev.emi.emi.screen.EmiScreenManager;
|
import dev.emi.emi.screen.EmiScreenManager;
|
||||||
import eu.midnightdust.midnightcontrols.client.MidnightControlsClient;
|
import eu.midnightdust.midnightcontrols.client.MidnightControlsClient;
|
||||||
@@ -14,9 +14,9 @@ import org.lwjgl.glfw.GLFW;
|
|||||||
|
|
||||||
public class EMICompat implements CompatHandler {
|
public class EMICompat implements CompatHandler {
|
||||||
public static boolean handleTabs(boolean direction) {
|
public static boolean handleTabs(boolean direction) {
|
||||||
if (isEMIEnabled() && MidnightControlsClient.get().input.actionGuiCooldown == 0 && EmiScreenManager.searchLeft != null && EmiScreenManager.searchRight != null) {
|
if (isEMIEnabled() && MidnightControlsClient.get().input.actionGuiCooldown == 0 && EmiScreenManager.getSearchPanel() != null && EmiScreenManager.getSearchPanel().pageLeft != null && EmiScreenManager.getSearchPanel().pageRight != null) {
|
||||||
if (direction) EmiScreenManager.searchRight.onPress();
|
if (direction) EmiScreenManager.getSearchPanel().pageRight.onPress();
|
||||||
else EmiScreenManager.searchLeft.onPress();
|
else EmiScreenManager.getSearchPanel().pageLeft.onPress();
|
||||||
MidnightControlsClient.get().input.actionGuiCooldown = 5;
|
MidnightControlsClient.get().input.actionGuiCooldown = 5;
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,56 @@
|
|||||||
|
package eu.midnightdust.midnightcontrols.client.compat;
|
||||||
|
|
||||||
|
import dev.isxander.yacl.gui.AbstractWidget;
|
||||||
|
import dev.isxander.yacl.gui.OptionListWidget;
|
||||||
|
import dev.isxander.yacl.gui.YACLScreen;
|
||||||
|
import dev.isxander.yacl.gui.controllers.ControllerWidget;
|
||||||
|
import dev.isxander.yacl.gui.controllers.slider.SliderControllerElement;
|
||||||
|
import net.minecraft.client.gui.Element;
|
||||||
|
import net.minecraft.client.gui.screen.Screen;
|
||||||
|
import org.lwjgl.glfw.GLFW;
|
||||||
|
|
||||||
|
public class YACLCompat {
|
||||||
|
public static boolean handleAButton(Screen screen, Element element) {
|
||||||
|
if (element instanceof AbstractWidget abstractWidget) {
|
||||||
|
// imitate ender key press
|
||||||
|
return abstractWidget.keyPressed(GLFW.GLFW_KEY_ENTER, 0, 0);
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static boolean handleLeftRight(Screen screen, boolean direction) {
|
||||||
|
if (screen instanceof YACLScreen yaclScreen) {
|
||||||
|
SliderControllerElement focusedSlider = yaclScreen.optionList.children().stream()
|
||||||
|
.filter(OptionListWidget.OptionEntry.class::isInstance)
|
||||||
|
.map(entry -> ((OptionListWidget.OptionEntry) entry).widget)
|
||||||
|
.filter(ControllerWidget.class::isInstance)
|
||||||
|
.map(ControllerWidget.class::cast)
|
||||||
|
.filter(SliderControllerElement.class::isInstance)
|
||||||
|
.map(SliderControllerElement.class::cast)
|
||||||
|
.filter(ControllerWidget::isHovered)
|
||||||
|
.findFirst()
|
||||||
|
.orElse(null);
|
||||||
|
|
||||||
|
if (focusedSlider == null)
|
||||||
|
return false;
|
||||||
|
|
||||||
|
focusedSlider.incrementValue(direction ? 1 : -1);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static boolean handleCategories(Screen screen, boolean direction) {
|
||||||
|
if (screen instanceof YACLScreen yaclScreen) {
|
||||||
|
int categoryIdx = yaclScreen.getCurrentCategoryIdx();
|
||||||
|
if (direction) categoryIdx++; else categoryIdx--;
|
||||||
|
if (categoryIdx < 0) categoryIdx = yaclScreen.config.categories().size() - 1;
|
||||||
|
if (categoryIdx >= yaclScreen.config.categories().size()) categoryIdx = 0;
|
||||||
|
|
||||||
|
yaclScreen.changeCategory(categoryIdx);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -92,9 +92,9 @@ public class ButtonBinding {
|
|||||||
.actions(InputHandlers::handleToggleSprint).onlyInGame().register();
|
.actions(InputHandlers::handleToggleSprint).onlyInGame().register();
|
||||||
public static final ButtonBinding SWAP_HANDS = new Builder("swap_hands").buttons(GLFW_GAMEPAD_BUTTON_X).onlyInGame().cooldown().register();
|
public static final ButtonBinding SWAP_HANDS = new Builder("swap_hands").buttons(GLFW_GAMEPAD_BUTTON_X).onlyInGame().cooldown().register();
|
||||||
public static final ButtonBinding TAB_LEFT = new Builder("tab_back").buttons(GLFW_GAMEPAD_BUTTON_LEFT_BUMPER)
|
public static final ButtonBinding TAB_LEFT = new Builder("tab_back").buttons(GLFW_GAMEPAD_BUTTON_LEFT_BUMPER)
|
||||||
.action(InputHandlers.handleHotbar(false)).filter(Predicates.or(InputHandlers::inInventory, InputHandlers::inAdvancements).or((client, binding) -> client.currentScreen != null && client.currentScreen.getClass().toString().contains("sodium"))).cooldown().register();
|
.action(InputHandlers.handleHotbar(false)).filter(Predicates.or(InputHandlers::inInventory, InputHandlers::inAdvancements).or((client, binding) -> client.currentScreen != null)).cooldown().register();
|
||||||
public static final ButtonBinding TAB_RIGHT = new Builder("tab_next").buttons(GLFW_GAMEPAD_BUTTON_RIGHT_BUMPER)
|
public static final ButtonBinding TAB_RIGHT = new Builder("tab_next").buttons(GLFW_GAMEPAD_BUTTON_RIGHT_BUMPER)
|
||||||
.action(InputHandlers.handleHotbar(true)).filter(Predicates.or(InputHandlers::inInventory, InputHandlers::inAdvancements).or((client, binding) -> client.currentScreen != null && client.currentScreen.getClass().toString().contains("sodium"))).cooldown().register();
|
.action(InputHandlers.handleHotbar(true)).filter(Predicates.or(InputHandlers::inInventory, InputHandlers::inAdvancements).or((client, binding) -> client.currentScreen != null)).cooldown().register();
|
||||||
public static final ButtonBinding PAGE_LEFT = new Builder("page_back").buttons(axisAsButton(GLFW_GAMEPAD_AXIS_LEFT_TRIGGER, true))
|
public static final ButtonBinding PAGE_LEFT = new Builder("page_back").buttons(axisAsButton(GLFW_GAMEPAD_AXIS_LEFT_TRIGGER, true))
|
||||||
.action(InputHandlers.handlePage(false)).filter(InputHandlers::inInventory).cooldown(30).register();
|
.action(InputHandlers.handlePage(false)).filter(InputHandlers::inInventory).cooldown(30).register();
|
||||||
public static final ButtonBinding PAGE_RIGHT = new Builder("page_next").buttons(axisAsButton(GLFW_GAMEPAD_AXIS_RIGHT_TRIGGER, true))
|
public static final ButtonBinding PAGE_RIGHT = new Builder("page_next").buttons(axisAsButton(GLFW_GAMEPAD_AXIS_RIGHT_TRIGGER, true))
|
||||||
|
|||||||
@@ -16,6 +16,7 @@ import eu.midnightdust.midnightcontrols.client.MidnightInput;
|
|||||||
import eu.midnightdust.midnightcontrols.client.compat.InventoryTabsCompat;
|
import eu.midnightdust.midnightcontrols.client.compat.InventoryTabsCompat;
|
||||||
import eu.midnightdust.midnightcontrols.client.compat.MidnightControlsCompat;
|
import eu.midnightdust.midnightcontrols.client.compat.MidnightControlsCompat;
|
||||||
import eu.midnightdust.midnightcontrols.client.compat.SodiumCompat;
|
import eu.midnightdust.midnightcontrols.client.compat.SodiumCompat;
|
||||||
|
import eu.midnightdust.midnightcontrols.client.compat.YACLCompat;
|
||||||
import eu.midnightdust.midnightcontrols.client.gui.RingScreen;
|
import eu.midnightdust.midnightcontrols.client.gui.RingScreen;
|
||||||
import eu.midnightdust.midnightcontrols.client.mixin.AdvancementsScreenAccessor;
|
import eu.midnightdust.midnightcontrols.client.mixin.AdvancementsScreenAccessor;
|
||||||
import eu.midnightdust.midnightcontrols.client.mixin.CreativeInventoryScreenAccessor;
|
import eu.midnightdust.midnightcontrols.client.mixin.CreativeInventoryScreenAccessor;
|
||||||
@@ -24,14 +25,11 @@ import eu.midnightdust.midnightcontrols.client.util.HandledScreenAccessor;
|
|||||||
import eu.midnightdust.midnightcontrols.client.util.MouseAccessor;
|
import eu.midnightdust.midnightcontrols.client.util.MouseAccessor;
|
||||||
import net.fabricmc.loader.api.FabricLoader;
|
import net.fabricmc.loader.api.FabricLoader;
|
||||||
import net.minecraft.client.MinecraftClient;
|
import net.minecraft.client.MinecraftClient;
|
||||||
import net.minecraft.client.gui.hud.SpectatorHud;
|
|
||||||
import net.minecraft.client.gui.hud.spectator.SpectatorMenu;
|
|
||||||
import net.minecraft.client.gui.screen.TitleScreen;
|
import net.minecraft.client.gui.screen.TitleScreen;
|
||||||
import net.minecraft.client.gui.screen.advancement.AdvancementsScreen;
|
import net.minecraft.client.gui.screen.advancement.AdvancementsScreen;
|
||||||
import net.minecraft.client.gui.screen.ingame.*;
|
import net.minecraft.client.gui.screen.ingame.*;
|
||||||
import net.minecraft.client.gui.screen.recipebook.RecipeBookWidget;
|
import net.minecraft.client.gui.screen.recipebook.RecipeBookWidget;
|
||||||
import net.minecraft.client.gui.widget.PressableWidget;
|
import net.minecraft.client.gui.widget.PressableWidget;
|
||||||
import net.minecraft.client.input.Input;
|
|
||||||
import net.minecraft.client.util.ScreenshotRecorder;
|
import net.minecraft.client.util.ScreenshotRecorder;
|
||||||
import net.minecraft.item.ItemGroup;
|
import net.minecraft.item.ItemGroup;
|
||||||
import net.minecraft.screen.slot.Slot;
|
import net.minecraft.screen.slot.Slot;
|
||||||
@@ -42,9 +40,9 @@ import org.jetbrains.annotations.NotNull;
|
|||||||
import org.lwjgl.glfw.GLFW;
|
import org.lwjgl.glfw.GLFW;
|
||||||
|
|
||||||
import java.util.Comparator;
|
import java.util.Comparator;
|
||||||
|
import java.util.List;
|
||||||
import java.util.Optional;
|
import java.util.Optional;
|
||||||
import java.util.function.Predicate;
|
import java.util.function.Predicate;
|
||||||
import java.util.stream.Collectors;
|
|
||||||
|
|
||||||
import static org.lwjgl.glfw.GLFW.*;
|
import static org.lwjgl.glfw.GLFW.*;
|
||||||
import static org.lwjgl.glfw.GLFW.GLFW_MOUSE_BUTTON_2;
|
import static org.lwjgl.glfw.GLFW.GLFW_MOUSE_BUTTON_2;
|
||||||
@@ -56,6 +54,7 @@ import static org.lwjgl.glfw.GLFW.GLFW_MOUSE_BUTTON_2;
|
|||||||
* @version 1.7.0
|
* @version 1.7.0
|
||||||
* @since 1.1.0
|
* @since 1.1.0
|
||||||
*/
|
*/
|
||||||
|
@SuppressWarnings("UnstableApiUsage")
|
||||||
public class InputHandlers {
|
public class InputHandlers {
|
||||||
private InputHandlers() {
|
private InputHandlers() {
|
||||||
}
|
}
|
||||||
@@ -133,7 +132,10 @@ public class InputHandlers {
|
|||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
} else {
|
} else {
|
||||||
if (FabricLoader.getInstance().isModLoaded("sodium")) SodiumCompat.handleTabs(client.currentScreen, next);
|
if (FabricLoader.getInstance().isModLoaded("sodium"))
|
||||||
|
SodiumCompat.handleTabs(client.currentScreen, next);
|
||||||
|
if (FabricLoader.getInstance().isModLoaded("yet-another-config-lib") && YACLCompat.handleCategories(client.currentScreen, next))
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
if (MidnightControlsCompat.isInventoryTabsPresent()) InventoryTabsCompat.handleInventoryTabs(client.currentScreen, next);
|
if (MidnightControlsCompat.isInventoryTabsPresent()) InventoryTabsCompat.handleInventoryTabs(client.currentScreen, next);
|
||||||
return false;
|
return false;
|
||||||
@@ -170,6 +172,7 @@ public class InputHandlers {
|
|||||||
} catch (Exception ignored) {}
|
} catch (Exception ignored) {}
|
||||||
}
|
}
|
||||||
if (MidnightControlsCompat.isInventoryTabsPresent()) InventoryTabsCompat.handleInventoryPage(client.currentScreen, next);
|
if (MidnightControlsCompat.isInventoryTabsPresent()) InventoryTabsCompat.handleInventoryPage(client.currentScreen, next);
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -57,8 +57,10 @@ public class MidnightControlsSettingsScreen extends SpruceScreen {
|
|||||||
private final SpruceOption rotationSpeedOption;
|
private final SpruceOption rotationSpeedOption;
|
||||||
private final SpruceOption yAxisRotationSpeedOption;
|
private final SpruceOption yAxisRotationSpeedOption;
|
||||||
private final SpruceOption mouseSpeedOption;
|
private final SpruceOption mouseSpeedOption;
|
||||||
|
private final SpruceOption joystickAsMouseOption;
|
||||||
private final SpruceOption virtualMouseOption;
|
private final SpruceOption virtualMouseOption;
|
||||||
private final SpruceOption resetOption;
|
private final SpruceOption resetOption;
|
||||||
|
private final SpruceOption advancedConfigOption;
|
||||||
// Gameplay options
|
// Gameplay options
|
||||||
private final SpruceOption analogMovementOption;
|
private final SpruceOption analogMovementOption;
|
||||||
private final SpruceOption doubleTapToSprintOption;
|
private final SpruceOption doubleTapToSprintOption;
|
||||||
@@ -75,6 +77,7 @@ public class MidnightControlsSettingsScreen extends SpruceScreen {
|
|||||||
private final SpruceOption virtualMouseSkinOption;
|
private final SpruceOption virtualMouseSkinOption;
|
||||||
private final SpruceOption hudEnableOption;
|
private final SpruceOption hudEnableOption;
|
||||||
private final SpruceOption hudSideOption;
|
private final SpruceOption hudSideOption;
|
||||||
|
private final SpruceOption moveChatOption;
|
||||||
// Controller options
|
// Controller options
|
||||||
private final SpruceOption controllerOption =
|
private final SpruceOption controllerOption =
|
||||||
new SpruceCyclingOption("midnightcontrols.menu.controller",
|
new SpruceCyclingOption("midnightcontrols.menu.controller",
|
||||||
@@ -184,12 +187,16 @@ public class MidnightControlsSettingsScreen extends SpruceScreen {
|
|||||||
this.mouseSpeedOption = new SpruceDoubleOption("midnightcontrols.menu.mouse_speed", 0.0, 150.0, .5f,
|
this.mouseSpeedOption = new SpruceDoubleOption("midnightcontrols.menu.mouse_speed", 0.0, 150.0, .5f,
|
||||||
() -> MidnightControlsConfig.mouseSpeed,
|
() -> MidnightControlsConfig.mouseSpeed,
|
||||||
value -> MidnightControlsConfig.mouseSpeed = value, option -> option.getDisplayText(Text.literal(String.valueOf(option.get()))),
|
value -> MidnightControlsConfig.mouseSpeed = value, option -> option.getDisplayText(Text.literal(String.valueOf(option.get()))),
|
||||||
Text.translatable("midnightcontrols.tooltip.mouse_speed"));
|
Text.translatable("midnightcontrols.tooltip.joystick_as_mouse"));
|
||||||
|
this.joystickAsMouseOption = new SpruceToggleBooleanOption("midnightcontrols.menu.joystick_as_mouse",
|
||||||
|
() -> MidnightControlsConfig.joystickAsMouse, value -> MidnightControlsConfig.joystickAsMouse = value,
|
||||||
|
Text.translatable("midnightcontrols.tooltip.joystick_as_mouse"));
|
||||||
this.resetOption = SpruceSimpleActionOption.reset(btn -> {
|
this.resetOption = SpruceSimpleActionOption.reset(btn -> {
|
||||||
MidnightControlsConfig.reset();
|
MidnightControlsConfig.reset();
|
||||||
var client = MinecraftClient.getInstance();
|
var client = MinecraftClient.getInstance();
|
||||||
this.init(client, client.getWindow().getScaledWidth(), client.getWindow().getScaledHeight());
|
this.init(client, client.getWindow().getScaledWidth(), client.getWindow().getScaledHeight());
|
||||||
});
|
});
|
||||||
|
this.advancedConfigOption = SpruceSimpleActionOption.of("midnightcontrols.midnightconfig.title", button -> client.setScreen(MidnightControlsConfig.getScreen(this, "midnightcontrols")));
|
||||||
// Gameplay options
|
// Gameplay options
|
||||||
this.analogMovementOption = new SpruceToggleBooleanOption("midnightcontrols.menu.analog_movement",
|
this.analogMovementOption = new SpruceToggleBooleanOption("midnightcontrols.menu.analog_movement",
|
||||||
() -> MidnightControlsConfig.analogMovement, value -> MidnightControlsConfig.analogMovement = value,
|
() -> MidnightControlsConfig.analogMovement, value -> MidnightControlsConfig.analogMovement = value,
|
||||||
@@ -232,6 +239,8 @@ public class MidnightControlsSettingsScreen extends SpruceScreen {
|
|||||||
amount -> MidnightControlsConfig.hudSide = MidnightControlsConfig.hudSide.next(),
|
amount -> MidnightControlsConfig.hudSide = MidnightControlsConfig.hudSide.next(),
|
||||||
option -> option.getDisplayText(MidnightControlsConfig.hudSide.getTranslatedText()),
|
option -> option.getDisplayText(MidnightControlsConfig.hudSide.getTranslatedText()),
|
||||||
Text.translatable("midnightcontrols.tooltip.hud_side"));
|
Text.translatable("midnightcontrols.tooltip.hud_side"));
|
||||||
|
this.moveChatOption = new SpruceToggleBooleanOption("midnightcontrols.menu.move_chat", () -> MidnightControlsConfig.moveChat,
|
||||||
|
value -> MidnightControlsConfig.moveChat = value, Text.translatable("midnightcontrols.tooltip.move_chat"));
|
||||||
// Controller options
|
// Controller options
|
||||||
this.toggleControllerProfileOption = new SpruceToggleBooleanOption("midnightcontrols.menu.separate_controller_profile", () -> MidnightControlsConfig.controllerBindingProfiles.containsKey(MidnightControlsConfig.getController().getGuid()), value -> {
|
this.toggleControllerProfileOption = new SpruceToggleBooleanOption("midnightcontrols.menu.separate_controller_profile", () -> MidnightControlsConfig.controllerBindingProfiles.containsKey(MidnightControlsConfig.getController().getGuid()), value -> {
|
||||||
if (value) {
|
if (value) {
|
||||||
@@ -290,8 +299,7 @@ public class MidnightControlsSettingsScreen extends SpruceScreen {
|
|||||||
this.buildTabs();
|
this.buildTabs();
|
||||||
|
|
||||||
this.addDrawableChild(this.resetOption.createWidget(Position.of(this.width / 2 - 155, this.height - 29), 150));
|
this.addDrawableChild(this.resetOption.createWidget(Position.of(this.width / 2 - 155, this.height - 29), 150));
|
||||||
this.addDrawableChild(new ButtonWidget(this.width / 2 - 155 + 160, this.height - 29, 150, 20, SpruceTexts.GUI_DONE,
|
this.addDrawableChild(new ButtonWidget(this.width / 2 - 155 + 160, this.height - 29, 150, 20, SpruceTexts.GUI_DONE, btn -> this.client.setScreen(this.parent)));
|
||||||
btn -> this.client.setScreen(this.parent)));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void buildTabs() {
|
public void buildTabs() {
|
||||||
@@ -329,6 +337,8 @@ public class MidnightControlsSettingsScreen extends SpruceScreen {
|
|||||||
list.addSingleOptionEntry(this.yAxisRotationSpeedOption);
|
list.addSingleOptionEntry(this.yAxisRotationSpeedOption);
|
||||||
list.addSingleOptionEntry(this.mouseSpeedOption);
|
list.addSingleOptionEntry(this.mouseSpeedOption);
|
||||||
list.addSingleOptionEntry(this.virtualMouseOption);
|
list.addSingleOptionEntry(this.virtualMouseOption);
|
||||||
|
list.addSingleOptionEntry(this.joystickAsMouseOption);
|
||||||
|
list.addSingleOptionEntry(this.advancedConfigOption);
|
||||||
return list;
|
return list;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -356,6 +366,7 @@ public class MidnightControlsSettingsScreen extends SpruceScreen {
|
|||||||
list.addSingleOptionEntry(new SpruceSeparatorOption("midnightcontrols.menu.title.hud", true, null));
|
list.addSingleOptionEntry(new SpruceSeparatorOption("midnightcontrols.menu.title.hud", true, null));
|
||||||
list.addSingleOptionEntry(this.hudEnableOption);
|
list.addSingleOptionEntry(this.hudEnableOption);
|
||||||
list.addSingleOptionEntry(this.hudSideOption);
|
list.addSingleOptionEntry(this.hudSideOption);
|
||||||
|
list.addSingleOptionEntry(this.moveChatOption);
|
||||||
return list;
|
return list;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -10,7 +10,6 @@
|
|||||||
package eu.midnightdust.midnightcontrols.client.gui;
|
package eu.midnightdust.midnightcontrols.client.gui;
|
||||||
|
|
||||||
import eu.midnightdust.midnightcontrols.client.MidnightControlsClient;
|
import eu.midnightdust.midnightcontrols.client.MidnightControlsClient;
|
||||||
import eu.midnightdust.midnightcontrols.client.ring.MidnightRing;
|
|
||||||
import eu.midnightdust.midnightcontrols.client.ring.RingButtonMode;
|
import eu.midnightdust.midnightcontrols.client.ring.RingButtonMode;
|
||||||
import eu.midnightdust.midnightcontrols.client.ring.RingPage;
|
import eu.midnightdust.midnightcontrols.client.ring.RingPage;
|
||||||
import net.minecraft.client.gui.screen.Screen;
|
import net.minecraft.client.gui.screen.Screen;
|
||||||
|
|||||||
@@ -0,0 +1,35 @@
|
|||||||
|
package eu.midnightdust.midnightcontrols.client.mixin;
|
||||||
|
|
||||||
|
import eu.midnightdust.midnightcontrols.client.MidnightControlsConfig;
|
||||||
|
import net.minecraft.client.gui.screen.ChatScreen;
|
||||||
|
import net.minecraft.client.gui.screen.Screen;
|
||||||
|
import net.minecraft.client.gui.widget.TextFieldWidget;
|
||||||
|
import net.minecraft.client.util.math.MatrixStack;
|
||||||
|
import net.minecraft.text.Text;
|
||||||
|
import org.spongepowered.asm.mixin.Mixin;
|
||||||
|
import org.spongepowered.asm.mixin.Shadow;
|
||||||
|
import org.spongepowered.asm.mixin.injection.At;
|
||||||
|
import org.spongepowered.asm.mixin.injection.Inject;
|
||||||
|
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
|
||||||
|
|
||||||
|
@Mixin(ChatScreen.class)
|
||||||
|
public abstract class ChatScreenMixin extends Screen {
|
||||||
|
@Shadow protected TextFieldWidget chatField;
|
||||||
|
|
||||||
|
protected ChatScreenMixin(Text title) {
|
||||||
|
super(title);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Inject(at = @At("TAIL"), method = "init")
|
||||||
|
private void midnightcontrols$moveInputField(CallbackInfo ci) {
|
||||||
|
if (MidnightControlsConfig.moveChat) chatField.y = 4;
|
||||||
|
}
|
||||||
|
@Inject(method = "render", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/gui/widget/TextFieldWidget;setTextFieldFocused(Z)V", shift = At.Shift.AFTER))
|
||||||
|
private void midnightcontrols$moveInputFieldBackground(MatrixStack matrices, int mouseX, int mouseY, float delta, CallbackInfo ci) {
|
||||||
|
if (MidnightControlsConfig.moveChat) matrices.translate(0f, -this.height + 16, 0f);
|
||||||
|
}
|
||||||
|
@Inject(method = "render", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/gui/widget/TextFieldWidget;render(Lnet/minecraft/client/util/math/MatrixStack;IIF)V", shift = At.Shift.BEFORE))
|
||||||
|
private void midnightcontrols$dontMoveOtherStuff(MatrixStack matrices, int mouseX, int mouseY, float delta, CallbackInfo ci) {
|
||||||
|
if (MidnightControlsConfig.moveChat) matrices.translate(0f, this.height - 16, 0f);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -11,16 +11,13 @@ package eu.midnightdust.midnightcontrols.client.mixin;
|
|||||||
|
|
||||||
import eu.midnightdust.lib.util.screen.TexturedOverlayButtonWidget;
|
import eu.midnightdust.lib.util.screen.TexturedOverlayButtonWidget;
|
||||||
import eu.midnightdust.midnightcontrols.client.gui.MidnightControlsSettingsScreen;
|
import eu.midnightdust.midnightcontrols.client.gui.MidnightControlsSettingsScreen;
|
||||||
import net.fabricmc.loader.api.FabricLoader;
|
|
||||||
import net.minecraft.client.gui.screen.Screen;
|
import net.minecraft.client.gui.screen.Screen;
|
||||||
import net.minecraft.client.gui.screen.option.ControlsOptionsScreen;
|
import net.minecraft.client.gui.screen.option.ControlsOptionsScreen;
|
||||||
import net.minecraft.client.gui.screen.option.GameOptionsScreen;
|
import net.minecraft.client.gui.screen.option.GameOptionsScreen;
|
||||||
import net.minecraft.client.gui.widget.ButtonWidget;
|
|
||||||
import net.minecraft.client.option.GameOptions;
|
import net.minecraft.client.option.GameOptions;
|
||||||
import net.minecraft.text.Text;
|
import net.minecraft.text.Text;
|
||||||
import net.minecraft.util.Identifier;
|
import net.minecraft.util.Identifier;
|
||||||
import org.spongepowered.asm.mixin.Mixin;
|
import org.spongepowered.asm.mixin.Mixin;
|
||||||
import org.spongepowered.asm.mixin.Unique;
|
|
||||||
import org.spongepowered.asm.mixin.injection.At;
|
import org.spongepowered.asm.mixin.injection.At;
|
||||||
import org.spongepowered.asm.mixin.injection.Inject;
|
import org.spongepowered.asm.mixin.injection.Inject;
|
||||||
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
|
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
|
||||||
@@ -30,27 +27,13 @@ import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
|
|||||||
*/
|
*/
|
||||||
@Mixin(ControlsOptionsScreen.class)
|
@Mixin(ControlsOptionsScreen.class)
|
||||||
public abstract class ControlsOptionsScreenMixin extends GameOptionsScreen {
|
public abstract class ControlsOptionsScreenMixin extends GameOptionsScreen {
|
||||||
@Unique private final boolean showAlternativeButton = FabricLoader.getInstance().isModLoaded("crawl");
|
|
||||||
public ControlsOptionsScreenMixin(Screen parent, GameOptions gameOptions, Text text) {
|
public ControlsOptionsScreenMixin(Screen parent, GameOptions gameOptions, Text text) {
|
||||||
super(parent, gameOptions, text);
|
super(parent, gameOptions, text);
|
||||||
}
|
}
|
||||||
@Inject(method = "init", at = @At(value = "INVOKE", ordinal = 1, shift = At.Shift.AFTER, target = "Lnet/minecraft/client/gui/screen/option/ControlsOptionsScreen;addDrawableChild(Lnet/minecraft/client/gui/Element;)Lnet/minecraft/client/gui/Element;"))
|
@Inject(method = "init", at = @At(value = "INVOKE", ordinal = 1, shift = At.Shift.AFTER, target = "Lnet/minecraft/client/gui/screen/option/ControlsOptionsScreen;addDrawableChild(Lnet/minecraft/client/gui/Element;)Lnet/minecraft/client/gui/Element;"))
|
||||||
private void addAlternativeControllerButton(CallbackInfo ci) {
|
private void addControllerButton(CallbackInfo ci) {
|
||||||
if (showAlternativeButton) {
|
|
||||||
this.addDrawableChild(new TexturedOverlayButtonWidget(this.width / 2 + 158, this.height / 6 - 12, 20, 20,0,0,20, new Identifier("midnightcontrols", "textures/gui/midnightcontrols_button.png"), 32, 64, (button) -> {
|
this.addDrawableChild(new TexturedOverlayButtonWidget(this.width / 2 + 158, this.height / 6 - 12, 20, 20,0,0,20, new Identifier("midnightcontrols", "textures/gui/midnightcontrols_button.png"), 32, 64, (button) -> {
|
||||||
this.client.setScreen(new MidnightControlsSettingsScreen(this, false));
|
this.client.setScreen(new MidnightControlsSettingsScreen(this, false));
|
||||||
}, Text.translatable("midnightcontrols.menu.title.controller")));
|
}, Text.translatable("midnightcontrols.menu.title.controller")));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@Inject(method = "init", at = @At(value = "INVOKE", ordinal = 4, shift = At.Shift.AFTER, target = "Lnet/minecraft/client/gui/screen/option/ControlsOptionsScreen;addDrawableChild(Lnet/minecraft/client/gui/Element;)Lnet/minecraft/client/gui/Element;"))
|
|
||||||
private void addControllerButton(CallbackInfo ci) {
|
|
||||||
if (!showAlternativeButton) {
|
|
||||||
int i = this.width / 2 - 155;
|
|
||||||
int j = i + 160;
|
|
||||||
int k = this.height / 6 - 12 + 48;
|
|
||||||
this.addDrawableChild(new ButtonWidget(j, k, 150, 20, Text.translatable("midnightcontrols.menu.title.controller").append("..."), (button) -> {
|
|
||||||
this.client.setScreen(new MidnightControlsSettingsScreen(this, false));
|
|
||||||
}));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|||||||
@@ -10,8 +10,10 @@ import java.util.List;
|
|||||||
|
|
||||||
@Mixin(value = KeyBindingRegistryImpl.class, remap = false)
|
@Mixin(value = KeyBindingRegistryImpl.class, remap = false)
|
||||||
public interface KeyBindingRegistryImplAccessor {
|
public interface KeyBindingRegistryImplAccessor {
|
||||||
|
|
||||||
@Accessor @Final
|
@Accessor @Final
|
||||||
static List<KeyBinding> getModdedKeyBindings() {
|
static List<KeyBinding> getMODDED_KEY_BINDINGS() {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -140,6 +140,7 @@
|
|||||||
"midnightcontrols.menu.hud_side": "HUD Side",
|
"midnightcontrols.menu.hud_side": "HUD Side",
|
||||||
"midnightcontrols.menu.invert_right_x_axis": "Invert Right X",
|
"midnightcontrols.menu.invert_right_x_axis": "Invert Right X",
|
||||||
"midnightcontrols.menu.invert_right_y_axis": "Invert Right Y",
|
"midnightcontrols.menu.invert_right_y_axis": "Invert Right Y",
|
||||||
|
"midnightcontrols.menu.joystick_as_mouse": "Always use left stick as mouse",
|
||||||
"midnightcontrols.menu.keyboard_controls": "Keyboard Controls...",
|
"midnightcontrols.menu.keyboard_controls": "Keyboard Controls...",
|
||||||
"midnightcontrols.menu.left_dead_zone": "Left Stick Dead Zone",
|
"midnightcontrols.menu.left_dead_zone": "Left Stick Dead Zone",
|
||||||
"midnightcontrols.menu.mappings.open_input_str": "Open Mappings File Editor",
|
"midnightcontrols.menu.mappings.open_input_str": "Open Mappings File Editor",
|
||||||
@@ -148,6 +149,7 @@
|
|||||||
"midnightcontrols.menu.max_right_x_value": "Right X Axis Max Value",
|
"midnightcontrols.menu.max_right_x_value": "Right X Axis Max Value",
|
||||||
"midnightcontrols.menu.max_right_y_value": "Right Y Axis Max Value",
|
"midnightcontrols.menu.max_right_y_value": "Right Y Axis Max Value",
|
||||||
"midnightcontrols.menu.mouse_speed": "Mouse Speed",
|
"midnightcontrols.menu.mouse_speed": "Mouse Speed",
|
||||||
|
"midnightcontrols.menu.move_chat": "Move chat input box to top",
|
||||||
"midnightcontrols.menu.reacharound.horizontal": "Front Block Placing",
|
"midnightcontrols.menu.reacharound.horizontal": "Front Block Placing",
|
||||||
"midnightcontrols.menu.reacharound.vertical": "Vertical Reacharound",
|
"midnightcontrols.menu.reacharound.vertical": "Vertical Reacharound",
|
||||||
"midnightcontrols.menu.reload_controller_mappings": "Reload Controller Mappings",
|
"midnightcontrols.menu.reload_controller_mappings": "Reload Controller Mappings",
|
||||||
@@ -181,12 +183,14 @@
|
|||||||
"midnightcontrols.tooltip.fly_drifting_vertical": "While flying, enables Vanilla vertical drifting/intertia.",
|
"midnightcontrols.tooltip.fly_drifting_vertical": "While flying, enables Vanilla vertical drifting/intertia.",
|
||||||
"midnightcontrols.tooltip.hud_enable": "Toggles the on-screen controller button indicator.",
|
"midnightcontrols.tooltip.hud_enable": "Toggles the on-screen controller button indicator.",
|
||||||
"midnightcontrols.tooltip.hud_side": "The position of the HUD.",
|
"midnightcontrols.tooltip.hud_side": "The position of the HUD.",
|
||||||
|
"midnightcontrols.tooltip.joystick_as_mouse": "Make the joystick behave like a mouse in every menu.",
|
||||||
"midnightcontrols.tooltip.left_dead_zone": "The dead zone for the controller's left analog stick.",
|
"midnightcontrols.tooltip.left_dead_zone": "The dead zone for the controller's left analog stick.",
|
||||||
"midnightcontrols.tooltip.max_left_x_value": "Changes what the mod considers the highest value for the left X axis. Useful if your axis does not use the full range and seems slow.",
|
"midnightcontrols.tooltip.max_left_x_value": "Changes what the mod considers the highest value for the left X axis. Useful if your axis does not use the full range and seems slow.",
|
||||||
"midnightcontrols.tooltip.max_left_y_value": "Changes what the mod considers the highest value for the left Y axis. Useful if your axis does not use the full range and seems slow.",
|
"midnightcontrols.tooltip.max_left_y_value": "Changes what the mod considers the highest value for the left Y axis. Useful if your axis does not use the full range and seems slow.",
|
||||||
"midnightcontrols.tooltip.max_right_x_value": "Changes what the mod considers the highest value for the right X axis. Useful if your axis does not use the full range and seems slow.",
|
"midnightcontrols.tooltip.max_right_x_value": "Changes what the mod considers the highest value for the right X axis. Useful if your axis does not use the full range and seems slow.",
|
||||||
"midnightcontrols.tooltip.max_right_y_value": "Changes what the mod considers the highest value for the right Y axis. Useful if your axis does not use the full range and seems slow.",
|
"midnightcontrols.tooltip.max_right_y_value": "Changes what the mod considers the highest value for the right Y axis. Useful if your axis does not use the full range and seems slow.",
|
||||||
"midnightcontrols.tooltip.mouse_speed": "The controller's emulated mouse speed.",
|
"midnightcontrols.tooltip.mouse_speed": "The controller's emulated mouse speed.",
|
||||||
|
"midnightcontrols.tooltip.move_chat": "Moves the chat input field to the top, for better input on devices with on-screen keyboards.",
|
||||||
"midnightcontrols.tooltip.reacharound.horizontal": "Enables front block placing, §cmight be considered cheating on some servers§r.",
|
"midnightcontrols.tooltip.reacharound.horizontal": "Enables front block placing, §cmight be considered cheating on some servers§r.",
|
||||||
"midnightcontrols.tooltip.reacharound.vertical": "Enables vertical reacharound, §cmight be considered cheating on some servers§r.",
|
"midnightcontrols.tooltip.reacharound.vertical": "Enables vertical reacharound, §cmight be considered cheating on some servers§r.",
|
||||||
"midnightcontrols.tooltip.reload_controller_mappings": "Reloads the controller mappings file.",
|
"midnightcontrols.tooltip.reload_controller_mappings": "Reloads the controller mappings file.",
|
||||||
|
|||||||
203
src/main/resources/assets/midnightcontrols/lang/it_it.json
Normal file
203
src/main/resources/assets/midnightcontrols/lang/it_it.json
Normal file
@@ -0,0 +1,203 @@
|
|||||||
|
{
|
||||||
|
"midnightcontrols.midnightconfig.title": "Configurazione Avanzata MidnightControls",
|
||||||
|
"midnightcontrols.midnightconfig.enum.VirtualMouseSkin.DEFAULT_LIGHT": "Default Chiaro",
|
||||||
|
"midnightcontrols.midnightconfig.enum.VirtualMouseSkin.DEFAULT_DARK": "Default Scuro",
|
||||||
|
"midnightcontrols.midnightconfig.enum.VirtualMouseSkin.SECOND_LIGHT": "Chiaro Secondario",
|
||||||
|
"midnightcontrols.midnightconfig.enum.VirtualMouseSkin.SECOND_DARK": "Scuro secondario",
|
||||||
|
"midnightcontrols.midnightconfig.enum.ControllerType.DEFAULT": "Default",
|
||||||
|
"midnightcontrols.midnightconfig.enum.ControllerType.DUALSHOCK": "DualShock",
|
||||||
|
"midnightcontrols.midnightconfig.enum.ControllerType.DUALSENSE": "DualSense",
|
||||||
|
"midnightcontrols.midnightconfig.enum.ControllerType.SWITCH": "Controller Switch/Wii",
|
||||||
|
"midnightcontrols.midnightconfig.enum.ControllerType.XBOX": "Controller Xbox One/Series",
|
||||||
|
"midnightcontrols.midnightconfig.enum.ControllerType.XBOX_360": "Controller Xbox 360",
|
||||||
|
"midnightcontrols.midnightconfig.enum.ControllerType.STEAM_CONTROLLER": "Controller Steam",
|
||||||
|
"midnightcontrols.midnightconfig.enum.ControllerType.STEAM_DECK": "Steam Deck",
|
||||||
|
"midnightcontrols.midnightconfig.enum.ControllerType.OUYA": "Controller OUYA",
|
||||||
|
"midnightcontrols.midnightconfig.enum.ControllerType.NUMBERED": "Controller Numerato",
|
||||||
|
"midnightcontrols.midnightconfig.enum.ControlsMode.DEFAULT": "Tastiera/Mouse",
|
||||||
|
"midnightcontrols.midnightconfig.enum.ControlsMode.CONTROLLER": "Controller",
|
||||||
|
"midnightcontrols.midnightconfig.enum.ControlsMode.TOUCHSCREEN": "Touchscreen (WIP)",
|
||||||
|
"midnightcontrols.midnightconfig.enum.HudSide.LEFT": "Sinistra",
|
||||||
|
"midnightcontrols.midnightconfig.enum.HudSide.RIGHT": "Destra",
|
||||||
|
"key.midnightcontrols.look_down": "Guarda in basso",
|
||||||
|
"key.midnightcontrols.look_left": "Guarda a sinistra",
|
||||||
|
"key.midnightcontrols.look_right": "Guarda a destra",
|
||||||
|
"key.midnightcontrols.look_up": "Guarda sopra",
|
||||||
|
"key.midnightcontrols.ring": "Apri Tasti non impostati",
|
||||||
|
"midnightcontrols.action.attack": "Attacca",
|
||||||
|
"midnightcontrols.action.back": "Indietro",
|
||||||
|
"midnightcontrols.action.chat": "Apri Chat",
|
||||||
|
"midnightcontrols.action.controls_ring": "Apri Tasti non impostati",
|
||||||
|
"midnightcontrols.action.debug_screen": "Apri HUD di Debug (F3)",
|
||||||
|
"midnightcontrols.action.drop_item": "Rilascia oggetto",
|
||||||
|
"midnightcontrols.action.exit": "Esci",
|
||||||
|
"midnightcontrols.action.forward": "Avanti",
|
||||||
|
"midnightcontrols.action.hit": "Colpisci",
|
||||||
|
"midnightcontrols.action.hotbar_left": "Hotbar sinistra",
|
||||||
|
"midnightcontrols.action.hotbar_right": "Hotbar destra",
|
||||||
|
"midnightcontrols.action.inventory": "Inventario",
|
||||||
|
"midnightcontrols.action.jump": "Salta",
|
||||||
|
"midnightcontrols.action.left": "Sinistra",
|
||||||
|
"midnightcontrols.action.pause_game": "Pausa il gioco",
|
||||||
|
"midnightcontrols.action.pick_block": "Prendi Blocco",
|
||||||
|
"midnightcontrols.action.pickup": "Raccogli",
|
||||||
|
"midnightcontrols.action.pickup_all": "Raccogli Tutto",
|
||||||
|
"midnightcontrols.action.place": "Piazza",
|
||||||
|
"midnightcontrols.action.player_list": "Lista Giocatori",
|
||||||
|
"midnightcontrols.action.quick_move": "Muovi veloce",
|
||||||
|
"midnightcontrols.action.right": "Destra",
|
||||||
|
"midnightcontrols.action.screenshot": "Fai uno Screenshot",
|
||||||
|
"midnightcontrols.action.slot_up": "Muovi slot sopra",
|
||||||
|
"midnightcontrols.action.slot_down": "Muovi slot sotto",
|
||||||
|
"midnightcontrols.action.slot_left": "Muovi slot a sinistra",
|
||||||
|
"midnightcontrols.action.slot_right": "Muovi slot a destra",
|
||||||
|
"midnightcontrols.action.sneak": "Accovaccia",
|
||||||
|
"midnightcontrols.action.sprint": "Corri",
|
||||||
|
"midnightcontrols.action.swap_hands": "Scambia le mani",
|
||||||
|
"midnightcontrols.action.toggle_perspective": "Cambia la prospettiva",
|
||||||
|
"midnightcontrols.action.toggle_smooth_camera": "Cambia Camera Cinematica",
|
||||||
|
"midnightcontrols.action.page_back": "Pagina precedente",
|
||||||
|
"midnightcontrols.action.page_next": "Pagina Successica",
|
||||||
|
"midnightcontrols.action.tab_back": "Tab Precedente",
|
||||||
|
"midnightcontrols.action.tab_next": "Tab Successiva",
|
||||||
|
"midnightcontrols.action.take": "Prendi Item",
|
||||||
|
"midnightcontrols.action.take_all": "Prendi Stack",
|
||||||
|
"midnightcontrols.action.use": "Usa",
|
||||||
|
"midnightcontrols.action.zoom": "Zoom",
|
||||||
|
"midnightcontrols.action.zoom_in": "Aumenta Zoom",
|
||||||
|
"midnightcontrols.action.zoom_out": "Diminuisci Zoom",
|
||||||
|
"midnightcontrols.action.zoom_reset": "Resetta Zoom",
|
||||||
|
"midnightcontrols.action.emi_page_left": "Pagina Precedente",
|
||||||
|
"midnightcontrols.action.emi_page_right": "Pagina Successiva",
|
||||||
|
"midnightcontrols.category.emi": "EMI",
|
||||||
|
"midnightcontrols.button.a": "A",
|
||||||
|
"midnightcontrols.button.b": "B",
|
||||||
|
"midnightcontrols.button.x": "X",
|
||||||
|
"midnightcontrols.button.y": "Y",
|
||||||
|
"midnightcontrols.button.left_bumper": "Bumper Destro",
|
||||||
|
"midnightcontrols.button.right_bumper": "Bumper Sinistro",
|
||||||
|
"midnightcontrols.button.back": "Indietro",
|
||||||
|
"midnightcontrols.button.start": "Avvia",
|
||||||
|
"midnightcontrols.button.guide": "Guida",
|
||||||
|
"midnightcontrols.button.left_thumb": "Pollice Sinistro",
|
||||||
|
"midnightcontrols.button.right_thumb": "Pollice Destro",
|
||||||
|
"midnightcontrols.button.dpad_up": "DPAD Sopra",
|
||||||
|
"midnightcontrols.button.dpad_right": "DPAD Destra",
|
||||||
|
"midnightcontrols.button.dpad_down": "DPAD Sotto",
|
||||||
|
"midnightcontrols.button.dpad_left": "DPAD Sinistra",
|
||||||
|
"midnightcontrols.button.l4": "L4",
|
||||||
|
"midnightcontrols.button.l5": "L5",
|
||||||
|
"midnightcontrols.button.r4": "R4",
|
||||||
|
"midnightcontrols.button.r5": "L5",
|
||||||
|
"midnightcontrols.axis.left_x+": "Sinistra X+",
|
||||||
|
"midnightcontrols.axis.left_y+": "Sinistra Y+",
|
||||||
|
"midnightcontrols.axis.right_x+": "Destra X+",
|
||||||
|
"midnightcontrols.axis.right_y+": "Destra Y+",
|
||||||
|
"midnightcontrols.axis.left_trigger": "Trigger Sinistro",
|
||||||
|
"midnightcontrols.axis.right_trigger": "Trigger Destro",
|
||||||
|
"midnightcontrols.axis.left_x-": "Sinistra X-",
|
||||||
|
"midnightcontrols.axis.left_y-": "Sinistra Y-",
|
||||||
|
"midnightcontrols.axis.right_x-": "Destra X-",
|
||||||
|
"midnightcontrols.axis.right_y-": "Destra Y-",
|
||||||
|
"midnightcontrols.button.unknown": "Sconosciuto",
|
||||||
|
"midnightcontrols.controller.tutorial.title": "Gioca il gioco con un Controller!",
|
||||||
|
"midnightcontrols.controller.tutorial.description": "Vai a %s -> %s -> %s",
|
||||||
|
"midnightcontrols.controller.connected": "Controller %d connesso.",
|
||||||
|
"midnightcontrols.controller.disconnected": "Controller %d disconnesso",
|
||||||
|
"midnightcontrols.controller.mappings.1": "Per configurare le mappature dei controller, per favore usa %s",
|
||||||
|
"midnightcontrols.controller.mappings.3": "e incolla le mappature nel file editor.",
|
||||||
|
"midnightcontrols.controller.mappings.error": "Errore durante il caricamento delle mappature",
|
||||||
|
"midnightcontrols.controller.mappings.error.write": "Errore durante la scrittura delle mappature su file",
|
||||||
|
"midnightcontrols.controller.mappings.updated": "Aggiornate le mappature!",
|
||||||
|
"midnightcontrols.controller_type.default": "Default",
|
||||||
|
"midnightcontrols.controller_type.dualshock": "DualShock",
|
||||||
|
"midnightcontrols.controller_type.dualsense": "DualSense",
|
||||||
|
"midnightcontrols.controller_type.switch": "Controller Switch/Wii",
|
||||||
|
"midnightcontrols.controller_type.xbox": "Controller Xbox One/Series",
|
||||||
|
"midnightcontrols.controller_type.xbox_360": "Controller Xbox 360",
|
||||||
|
"midnightcontrols.controller_type.steam_controller": "Controller Steam",
|
||||||
|
"midnightcontrols.controller_type.steam_deck": "Steam Deck",
|
||||||
|
"midnightcontrols.controller_type.ouya": "Controller OUYA",
|
||||||
|
"midnightcontrols.controller_type.numbered": "Controller Numerato",
|
||||||
|
"midnightcontrols.controls_mode.default": "Tastiera/Mouse",
|
||||||
|
"midnightcontrols.controls_mode.controller": "Controller",
|
||||||
|
"midnightcontrols.controls_mode.touchscreen": "Touchscreen (WIP)",
|
||||||
|
"midnightcontrols.hud_side.left": "Left",
|
||||||
|
"midnightcontrols.hud_side.right": "Destra",
|
||||||
|
"midnightcontrols.menu.analog_movement": "Movimento Analogo",
|
||||||
|
"midnightcontrols.menu.auto_switch_mode": "Modalità Cambio Automatico",
|
||||||
|
"midnightcontrols.menu.controller": "Controller",
|
||||||
|
"midnightcontrols.menu.controller2": "Controller Secondario",
|
||||||
|
"midnightcontrols.menu.controller_toggle_sneak": "Attiva/Disattiva Accovacciamento su Controller",
|
||||||
|
"midnightcontrols.menu.controller_toggle_sprint": "Attiva/Disattiva Correre su Controller",
|
||||||
|
"midnightcontrols.menu.controller_type": "Tipo di Controller",
|
||||||
|
"midnightcontrols.menu.controls_mode": "Modalità",
|
||||||
|
"midnightcontrols.menu.double_tap_to_sprint": "Doppio Tap per Sprintare",
|
||||||
|
"midnightcontrols.menu.fast_block_placing": "Veloce Piazzamento di Blocchi",
|
||||||
|
"midnightcontrols.menu.fly_drifting": "Drift in Volo",
|
||||||
|
"midnightcontrols.menu.fly_drifting_vertical": "Drift in Volo Verticale",
|
||||||
|
"midnightcontrols.menu.hud_enable": "Attiva HUD",
|
||||||
|
"midnightcontrols.menu.hud_side": "Lato HUD",
|
||||||
|
"midnightcontrols.menu.invert_right_x_axis": "Inverti Destro X",
|
||||||
|
"midnightcontrols.menu.invert_right_y_axis": "Inverti Destro Y",
|
||||||
|
"midnightcontrols.menu.keyboard_controls": "Controlli da Tastiera...",
|
||||||
|
"midnightcontrols.menu.left_dead_zone": "Zona Morta dello Stick Sinistro",
|
||||||
|
"midnightcontrols.menu.mappings.open_input_str": "Apri il File Editor delle Mappature",
|
||||||
|
"midnightcontrols.menu.max_left_x_value": "Asse X Sinistro Massimo Valore",
|
||||||
|
"midnightcontrols.menu.max_left_y_value": "Asse Y Sinistro Massimo Valore",
|
||||||
|
"midnightcontrols.menu.max_right_x_value": "Asse Destro X Massimo Valore",
|
||||||
|
"midnightcontrols.menu.max_right_y_value": "Asse Destro Y Massimo Valore",
|
||||||
|
"midnightcontrols.menu.mouse_speed": "Velocità Mouse",
|
||||||
|
"midnightcontrols.menu.reacharound.horizontal": "Piazza blocchi Davanti",
|
||||||
|
"midnightcontrols.menu.reacharound.vertical": "Reach Verticale",
|
||||||
|
"midnightcontrols.menu.reload_controller_mappings": "Ricarica Mappature del Controller",
|
||||||
|
"midnightcontrols.menu.right_dead_zone": "Zona Morta Stick Destro",
|
||||||
|
"midnightcontrols.menu.rotation_speed": "Velocità di rotazione dell'Asse X",
|
||||||
|
"midnightcontrols.menu.y_axis_rotation_speed": "Velocità di rotazione dell'Asse Y",
|
||||||
|
"midnightcontrols.menu.separate_controller_profile": "Profilo Controller Separato",
|
||||||
|
"midnightcontrols.menu.separator.controller": "Controller",
|
||||||
|
"midnightcontrols.menu.separator.general": "Generale",
|
||||||
|
"midnightcontrols.menu.title": "MidnightControls - Impostazioni",
|
||||||
|
"midnightcontrols.menu.title.controller": "Opzioni Controller",
|
||||||
|
"midnightcontrols.menu.title.controller_controls": "Tasti Controller",
|
||||||
|
"midnightcontrols.menu.title.gameplay": "Opzioni del Gameplay",
|
||||||
|
"midnightcontrols.menu.title.general": "Impostazioni Generali",
|
||||||
|
"midnightcontrols.menu.title.hud": "Opzioni della HUD",
|
||||||
|
"midnightcontrols.menu.title.mappings.string": "Editor di file delle Mappature",
|
||||||
|
"midnightcontrols.menu.title.visual": "Aspetto",
|
||||||
|
"midnightcontrols.menu.unfocused_input": "Input non a fuoco",
|
||||||
|
"midnightcontrols.menu.virtual_mouse": "Mouse Virtuale",
|
||||||
|
"midnightcontrols.menu.virtual_mouse.skin": "Aspetto Mouse Virtuale",
|
||||||
|
"midnightcontrols.narrator.unbound": "Disimpostato %s",
|
||||||
|
"midnightcontrols.not_bound": "Non Impostato",
|
||||||
|
"midnightcontrols.tooltip.analog_movement": "Quando possibile, attiva movimento analogo.",
|
||||||
|
"midnightcontrols.tooltip.auto_switch_mode": "Quando la modalità controlli dovrebbe passare a Controller automaticamente se uno è connesso",
|
||||||
|
"midnightcontrols.tooltip.controller2": "Secondo controller da usare, che permette (per esempio) Supporto dei Joy-Cons.",
|
||||||
|
"midnightcontrols.tooltip.controller_type": "Il tipo di controller che stai usando (usato per mostrare i pulsanti corretti)",
|
||||||
|
"midnightcontrols.tooltip.controls_mode": "Modalita controlli.",
|
||||||
|
"midnightcontrols.tooltip.double_tap_to_sprint": "Attiva quando il tasto \"Cammina Avanti\" fa correre il giocatore con doppio tap velocemente",
|
||||||
|
"midnightcontrols.tooltip.fast_block_placing": "Quando si vola in creativa, attiva il movimento veloce dei blocchi in base alla tua velocità. §cSu alcuni server potrebbe essere considerato un cheat.§r",
|
||||||
|
"midnightcontrols.tooltip.fly_drifting": "Quando si vola, attiva L'inerzia del Vanilla",
|
||||||
|
"midnightcontrols.tooltip.fly_drifting_vertical": "Quando si vola, attiva l'inerzia verticale Vanilla",
|
||||||
|
"midnightcontrols.tooltip.hud_enable": "Attiva gli indicatori dei pulsanti dei controller sullo schermo.",
|
||||||
|
"midnightcontrols.tooltip.hud_side": "La posizione della HUD",
|
||||||
|
"midnightcontrols.tooltip.left_dead_zone": "La zona morta per lo stick sinistro del controller.",
|
||||||
|
"midnightcontrols.tooltip.max_left_x_value": "Cambia cosa la mod considera il più alto valore per l'asse X sinistro. Utile se il tuo asse non usa il range massimo e sembra lento",
|
||||||
|
"midnightcontrols.tooltip.max_left_y_value": "Cambia cosa la mod considera il più alto valore per l'asse Y sinistro. Utile se il tuo asse non usa il range massimo e sembra lento",
|
||||||
|
"midnightcontrols.tooltip.max_right_x_value": "Cambia cosa la mod considera il più alto valore per l'asse X Destro. Utile se il tuo asse non usa il range massimo e sembra lento.",
|
||||||
|
"midnightcontrols.tooltip.max_right_y_value": "Cambia cosa la mod considera il più alto valore per l'asse Y Destro. Utile se il tuo asse non usa il range massimo e sembra lento.",
|
||||||
|
"midnightcontrols.tooltip.mouse_speed": "La velocità del controller emulato.",
|
||||||
|
"midnightcontrols.tooltip.reacharound.horizontal": "Attiva il piazzare blocchi davanti, Potrebbe essere considerato un cheat su alcuni server.",
|
||||||
|
"midnightcontrols.tooltip.reacharound.vertical": "Attiva il reach verticale, potrebbe essere considerato cheating su alcuni server",
|
||||||
|
"midnightcontrols.tooltip.reload_controller_mappings": "Riavvia il file dlle mappature del controller",
|
||||||
|
"midnightcontrols.tooltip.right_dead_zone": "La zona morta per lo stick destro del controller",
|
||||||
|
"midnightcontrols.tooltip.rotation_speed": "L'asse X della velocità di rotazione della camera im modalità controller",
|
||||||
|
"midnightcontrols.tooltip.y_axis_rotation_speed": "L'asse Y della velocità di rotazione della camera im modalità controller",
|
||||||
|
"midnightcontrols.tooltip.unfocused_input": "Permette imput dei controller quando la finestra non è messa a fuoco",
|
||||||
|
"midnightcontrols.tooltip.virtual_mouse": "Attiva il mouse virtuale, che può essere utile nello schermo diviso.",
|
||||||
|
"midnightcontrols.virtual_mouse.skin.default_light": "Chiaro Default",
|
||||||
|
"midnightcontrols.virtual_mouse.skin.default_dark": "Scuro Default",
|
||||||
|
"midnightcontrols.virtual_mouse.skin.second_light": "Chiaro Secondario",
|
||||||
|
"midnightcontrols.virtual_mouse.skin.second_dark": "Scuro Secondario",
|
||||||
|
"modmenu.descriptionTranslation.midnightcontrols": "Aggiunge supporto e controlli migliorati in generale. \\nProveniente da LambdaControls, che è stato rimosso."
|
||||||
|
}
|
||||||
152
src/main/resources/assets/midnightcontrols/lang/zh_tw.json
Normal file
152
src/main/resources/assets/midnightcontrols/lang/zh_tw.json
Normal file
@@ -0,0 +1,152 @@
|
|||||||
|
{
|
||||||
|
"key.midnightcontrols.look_down": "視角下移",
|
||||||
|
"key.midnightcontrols.look_left": "視角左移",
|
||||||
|
"key.midnightcontrols.look_right": "視角右移",
|
||||||
|
"key.midnightcontrols.look_up": "視角上移",
|
||||||
|
"key.midnightcontrols.ring": "顯示額外按鍵菜單",
|
||||||
|
"midnightcontrols.action.attack": "攻擊",
|
||||||
|
"midnightcontrols.action.back": "向後移動",
|
||||||
|
"midnightcontrols.action.chat": "打開聊天欄",
|
||||||
|
"midnightcontrols.action.drop_item": "丟棄所選物品",
|
||||||
|
"midnightcontrols.action.exit": "退出",
|
||||||
|
"midnightcontrols.action.forward": "向前移動",
|
||||||
|
"midnightcontrols.action.hit": "挖掘",
|
||||||
|
"midnightcontrols.action.hotbar_left": "向左循環選擇快捷欄",
|
||||||
|
"midnightcontrols.action.hotbar_right": "向右循環選擇快捷欄",
|
||||||
|
"midnightcontrols.action.inventory": "物品欄",
|
||||||
|
"midnightcontrols.action.jump": "跳躍",
|
||||||
|
"midnightcontrols.action.left": "向左移動",
|
||||||
|
"midnightcontrols.action.pause_game": "暫停遊戲",
|
||||||
|
"midnightcontrols.action.pick_block": "選取方塊",
|
||||||
|
"midnightcontrols.action.pickup": "拿取一個/拿取一半",
|
||||||
|
"midnightcontrols.action.pickup_all": "拿取一組/拿取全部",
|
||||||
|
"midnightcontrols.action.place": "放置方塊",
|
||||||
|
"midnightcontrols.action.player_list": "玩家列表",
|
||||||
|
"midnightcontrols.action.quick_move": "快速移動物品",
|
||||||
|
"midnightcontrols.action.right": "向右移動",
|
||||||
|
"midnightcontrols.action.screenshot": "截圖",
|
||||||
|
"midnightcontrols.action.sneak": "潛行",
|
||||||
|
"midnightcontrols.action.sprint": "疾跑",
|
||||||
|
"midnightcontrols.action.swap_hands": "與副手交換",
|
||||||
|
"midnightcontrols.action.toggle_perspective": "切換視角",
|
||||||
|
"midnightcontrols.action.toggle_smooth_camera": "切換電影視角",
|
||||||
|
"midnightcontrols.action.use": "使用物品/放置方塊",
|
||||||
|
"midnightcontrols.action.zoom": "視野縮放",
|
||||||
|
"midnightcontrols.action.zoom_in": "縮放時將視野推近",
|
||||||
|
"midnightcontrols.action.zoom_out": "縮放時將視野拉遠",
|
||||||
|
"midnightcontrols.action.zoom_reset": "縮放時重置縮放距離",
|
||||||
|
"midnightcontrols.button.a": "A",
|
||||||
|
"midnightcontrols.button.b": "B",
|
||||||
|
"midnightcontrols.button.x": "X",
|
||||||
|
"midnightcontrols.button.y": "Y",
|
||||||
|
"midnightcontrols.button.left_bumper": "LB 鍵",
|
||||||
|
"midnightcontrols.button.right_bumper": "RB 鍵",
|
||||||
|
"midnightcontrols.button.back": "選擇鍵",
|
||||||
|
"midnightcontrols.button.start": "開始鍵",
|
||||||
|
"midnightcontrols.button.guide": "功能鍵",
|
||||||
|
"midnightcontrols.button.left_thumb": "左搖桿(按壓)",
|
||||||
|
"midnightcontrols.button.right_thumb": "右搖桿(按壓)",
|
||||||
|
"midnightcontrols.button.dpad_up": "十字鍵上",
|
||||||
|
"midnightcontrols.button.dpad_right": "十字鍵右",
|
||||||
|
"midnightcontrols.button.dpad_down": "十字鍵下",
|
||||||
|
"midnightcontrols.button.dpad_left": "十字鍵左",
|
||||||
|
"midnightcontrols.axis.left_x+": "左搖桿右(X軸正向)",
|
||||||
|
"midnightcontrols.axis.left_y+": "左搖桿上(Y軸正向)",
|
||||||
|
"midnightcontrols.axis.right_x+": "右搖桿右(X軸正向)",
|
||||||
|
"midnightcontrols.axis.right_y+": "右搖桿上(Y軸正向)",
|
||||||
|
"midnightcontrols.axis.left_trigger": "左扳機鍵",
|
||||||
|
"midnightcontrols.axis.right_trigger": "右扳機鍵",
|
||||||
|
"midnightcontrols.axis.left_x-": "左搖桿左(X軸負向)",
|
||||||
|
"midnightcontrols.axis.left_y-": "左搖桿下(Y軸負向)",
|
||||||
|
"midnightcontrols.axis.right_x-": "右搖桿左(X軸負向)",
|
||||||
|
"midnightcontrols.axis.right_y-": "右搖桿下(Y軸負向)",
|
||||||
|
"midnightcontrols.button.unknown": "未知(%d)",
|
||||||
|
"midnightcontrols.controller.connected": "手把 %d 已連接。",
|
||||||
|
"midnightcontrols.controller.disconnected": "手把 %d 已斷開。",
|
||||||
|
"midnightcontrols.controller.mappings.1": "請使用 %s 配置手把按鍵映射",
|
||||||
|
"midnightcontrols.controller.mappings.3": "並將按鍵映射文件放入此路徑:`%s.minecraft/config/gamecontrollerdb.txt%s`。",
|
||||||
|
"midnightcontrols.controller.mappings.error": "發生錯誤,無法讀取按鍵映射文件。",
|
||||||
|
"midnightcontrols.controller.mappings.error.write": "發生錯誤,無法保存按鍵映射文件。",
|
||||||
|
"midnightcontrols.controller.mappings.updated": "按鍵映射已更新!",
|
||||||
|
"midnightcontrols.controller_type.default": "默認",
|
||||||
|
"midnightcontrols.controller_type.dualshock": "DualShock",
|
||||||
|
"midnightcontrols.controller_type.switch": "Switch",
|
||||||
|
"midnightcontrols.controller_type.xbox": "Xbox",
|
||||||
|
"midnightcontrols.controller_type.steam": "Steam",
|
||||||
|
"midnightcontrols.controller_type.ouya": "OUYA",
|
||||||
|
"midnightcontrols.controls_mode.default": "鍵鼠",
|
||||||
|
"midnightcontrols.controls_mode.controller": "手把",
|
||||||
|
"midnightcontrols.controls_mode.touchscreen": "觸摸屏",
|
||||||
|
"midnightcontrols.hud_side.left": "左側",
|
||||||
|
"midnightcontrols.hud_side.right": "右側",
|
||||||
|
"midnightcontrols.menu.analog_movement": "識別搖桿輸入的精確值",
|
||||||
|
"midnightcontrols.menu.auto_switch_mode": "自動切換模式",
|
||||||
|
"midnightcontrols.menu.controller": "手把",
|
||||||
|
"midnightcontrols.menu.controller2": "額外手把",
|
||||||
|
"midnightcontrols.menu.controller_type": "手把類型",
|
||||||
|
"midnightcontrols.menu.controls_mode": "模式",
|
||||||
|
"midnightcontrols.menu.fast_block_placing": "方塊快速放置",
|
||||||
|
"midnightcontrols.menu.fly_drifting": "水平方向飛行慣性",
|
||||||
|
"midnightcontrols.menu.fly_drifting_vertical": "垂直方向飛行慣性",
|
||||||
|
"midnightcontrols.menu.hud_enable": "啟用HUD",
|
||||||
|
"midnightcontrols.menu.hud_side": "HUD位置",
|
||||||
|
"midnightcontrols.menu.invert_right_x_axis": "反轉右搖桿X軸",
|
||||||
|
"midnightcontrols.menu.invert_right_y_axis": "反轉右搖桿Y軸",
|
||||||
|
"midnightcontrols.menu.keyboard_controls": "鍵盤控制…",
|
||||||
|
"midnightcontrols.menu.left_dead_zone": "左搖桿死區",
|
||||||
|
"midnightcontrols.menu.mappings.open_input_str": "編輯按鍵映射文件",
|
||||||
|
"midnightcontrols.menu.max_left_x_value": "左搖桿X軸最大值識別範圍",
|
||||||
|
"midnightcontrols.menu.max_left_y_value": "左搖桿Y軸最大值識別範圍",
|
||||||
|
"midnightcontrols.menu.max_right_x_value": "右搖桿X軸最大值識別範圍",
|
||||||
|
"midnightcontrols.menu.max_right_y_value": "右搖桿Y軸最大值識別範圍",
|
||||||
|
"midnightcontrols.menu.mouse_speed": "鼠標移動速度",
|
||||||
|
"midnightcontrols.menu.reacharound.horizontal": "水平方向方塊放置輔助",
|
||||||
|
"midnightcontrols.menu.reacharound.vertical": "垂直方向方塊放置輔助",
|
||||||
|
"midnightcontrols.menu.reload_controller_mappings": "重新加載手把按鍵映射",
|
||||||
|
"midnightcontrols.menu.right_dead_zone": "右搖桿死區",
|
||||||
|
"midnightcontrols.menu.rotation_speed": "鏡頭旋轉速度 (X)",
|
||||||
|
"midnightcontrols.menu.y_axis_rotation_speed": "鏡頭旋轉速度 (Y)",
|
||||||
|
"midnightcontrols.menu.separator.controller": "手把",
|
||||||
|
"midnightcontrols.menu.separator.general": "通用",
|
||||||
|
"midnightcontrols.menu.title": "midnightcontrols — 設置",
|
||||||
|
"midnightcontrols.menu.title.controller": "手把選項",
|
||||||
|
"midnightcontrols.menu.title.controller_controls": "手把控制",
|
||||||
|
"midnightcontrols.menu.title.gameplay": "遊戲內容選項",
|
||||||
|
"midnightcontrols.menu.title.general": "通用選項",
|
||||||
|
"midnightcontrols.menu.title.hud": "HUD選項",
|
||||||
|
"midnightcontrols.menu.title.mappings.string": "編輯按鍵映射文件",
|
||||||
|
"midnightcontrols.menu.title.visual": "界面選項",
|
||||||
|
"midnightcontrols.menu.unfocused_input": "非活動狀態輸入",
|
||||||
|
"midnightcontrols.menu.virtual_mouse": "虛擬鼠標",
|
||||||
|
"midnightcontrols.menu.virtual_mouse.skin": "虛擬鼠標指針樣式",
|
||||||
|
"midnightcontrols.narrator.unbound": "取消綁定 %s",
|
||||||
|
"midnightcontrols.not_bound": "未綁定",
|
||||||
|
"midnightcontrols.tooltip.analog_movement": "若遊戲機制允許,則可根據推動搖桿的力度與幅度決定移動的速度。",
|
||||||
|
"midnightcontrols.tooltip.auto_switch_mode": "如果已有手把連接,則自動切換為手把操作模式。",
|
||||||
|
"midnightcontrols.tooltip.controller2": "使用額外的手把,比如將一左一右的兩個 Joy-Con 合為一個功能完全的手把。",
|
||||||
|
"midnightcontrols.tooltip.controller_type": "選擇手把類型,以顯示對應的按鍵圖標。",
|
||||||
|
"midnightcontrols.tooltip.controls_mode": "操作模式",
|
||||||
|
"midnightcontrols.tooltip.fast_block_placing": "在創造模式中處於飛行狀態時,可以根據你飛行的速度快速放置方塊。\n§c在部分服務器可能會被認定為作弊。",
|
||||||
|
"midnightcontrols.tooltip.fly_drifting": "處於飛行狀態時,啟用原版的水平方向飛行慣性(緩停滑行)。",
|
||||||
|
"midnightcontrols.tooltip.fly_drifting_vertical": "處於飛行狀態時,啟用原版的垂直方向飛行慣性(緩停滑行)。",
|
||||||
|
"midnightcontrols.tooltip.hud_enable": "顯示手把按鍵操作提示。",
|
||||||
|
"midnightcontrols.tooltip.hud_side": "HUD的位置位於畫面的哪一側。",
|
||||||
|
"midnightcontrols.tooltip.left_dead_zone": "左搖桿配置的死區。\n死區決定搖桿要偏離中心位置多遠才能讓搖桿的輸入有效。",
|
||||||
|
"midnightcontrols.tooltip.max_left_x_value": "更改左搖桿X軸最大值的識別範圍。\n若感覺即便推滿搖桿也未達到最大的輸入值,導致在識別搖桿輸入的精確值的情況下,左右移動較為緩慢等問題,本項可能會有所幫助。",
|
||||||
|
"midnightcontrols.tooltip.max_left_y_value": "更改左搖桿Y軸最大值的識別範圍。\n若感覺即便推滿搖桿也未達到最大的輸入值,導致在識別搖桿輸入的精確值的情況下,前後移動較為緩慢等問題,本項可能會有所幫助。",
|
||||||
|
"midnightcontrols.tooltip.max_right_x_value": "更改右搖桿X軸最大值的識別範圍。\n若感覺即便推滿搖桿也未達到最大的輸入值,導致鏡頭左右旋轉較為緩慢等問題,本項可能會有所幫助。",
|
||||||
|
"midnightcontrols.tooltip.max_right_y_value": "更改右搖桿Y軸最大值的識別範圍。\n若感覺即便推滿搖桿也未達到最大的輸入值,導致鏡頭上下旋轉較為緩慢等問題,本項可能會有所幫助。",
|
||||||
|
"midnightcontrols.tooltip.mouse_speed": "手把模擬的鼠標的移動速度。",
|
||||||
|
"midnightcontrols.tooltip.reacharound.horizontal": "啟用水平方向方塊放置輔助,可在腳下方塊的前方放置方塊。\n§c在部分服務器可能會被認定為作弊。",
|
||||||
|
"midnightcontrols.tooltip.reacharound.vertical": "啟用垂直方向方塊放置輔助,可在腳下方塊的下方放置方塊。\n§c在部分服務器可能會被認定為作弊。",
|
||||||
|
"midnightcontrols.tooltip.reload_controller_mappings": "重新加載手把的按鍵映射文件。",
|
||||||
|
"midnightcontrols.tooltip.right_dead_zone": "右搖桿配置的死區。\n死區決定搖桿要偏離中心位置多遠才能讓搖桿的輸入有效。",
|
||||||
|
"midnightcontrols.tooltip.rotation_speed": "手把操作模式下的鏡頭旋轉速度。(X)",
|
||||||
|
"midnightcontrols.tooltip.y_axis_rotation_speed": "手把操作模式下的鏡頭旋轉速度。(Y)",
|
||||||
|
"midnightcontrols.tooltip.unfocused_input": "即使遊戲窗口處於非活動狀態,也允許手把進行按鍵輸入。",
|
||||||
|
"midnightcontrols.tooltip.virtual_mouse": "啟用虛擬鼠標,在分屏的情況下很有用。",
|
||||||
|
"midnightcontrols.virtual_mouse.skin.default_light": "默認樣式(白色)",
|
||||||
|
"midnightcontrols.virtual_mouse.skin.default_dark": "默認樣式(黑色)",
|
||||||
|
"midnightcontrols.virtual_mouse.skin.second_light": "額外樣式(白色)",
|
||||||
|
"midnightcontrols.virtual_mouse.skin.second_dark": "額外樣式(黑色)"
|
||||||
|
}
|
||||||
@@ -52,8 +52,8 @@
|
|||||||
],
|
],
|
||||||
"depends": {
|
"depends": {
|
||||||
"fabricloader": ">=0.11.3",
|
"fabricloader": ">=0.11.3",
|
||||||
"fabric": ">=0.36.0",
|
"fabric": ">=0.71.0",
|
||||||
"minecraft": ">=1.17",
|
"minecraft": "<1.19.3",
|
||||||
"spruceui": ">=3.2.0",
|
"spruceui": ">=3.2.0",
|
||||||
"java": ">=17"
|
"java": ">=17"
|
||||||
},
|
},
|
||||||
@@ -64,6 +64,7 @@
|
|||||||
"kontrolo": "*"
|
"kontrolo": "*"
|
||||||
},
|
},
|
||||||
"breaks": {
|
"breaks": {
|
||||||
|
"emi": "<0.5.0",
|
||||||
"lambdacontrols": "*",
|
"lambdacontrols": "*",
|
||||||
"modmenu": "<1.12.2"
|
"modmenu": "<1.12.2"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,6 +15,7 @@
|
|||||||
"KeyBindingMixin",
|
"KeyBindingMixin",
|
||||||
"MinecraftClientMixin",
|
"MinecraftClientMixin",
|
||||||
"MouseMixin",
|
"MouseMixin",
|
||||||
|
"ChatScreenMixin",
|
||||||
"RecipeBookWidgetAccessor",
|
"RecipeBookWidgetAccessor",
|
||||||
"WorldRendererMixin",
|
"WorldRendererMixin",
|
||||||
"KeyBindingRegistryImplAccessor",
|
"KeyBindingRegistryImplAccessor",
|
||||||
|
|||||||
Binary file not shown.
|
Before Width: | Height: | Size: 4.4 KiB After Width: | Height: | Size: 4.9 KiB |
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"pack": {
|
"pack": {
|
||||||
"pack_format": 9,
|
"pack_format": 12,
|
||||||
"description": "Makes controller tooltips use similar icons to Bedrock Edition"
|
"description": "Makes controller tooltips use similar icons to Bedrock Edition"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"pack": {
|
"pack": {
|
||||||
"pack_format": 9,
|
"pack_format": 12,
|
||||||
"description": "Makes controller icons look similar to Legacy Console Edit."
|
"description": "Makes controller icons look similar to Legacy Console Edit."
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user