From 277362236c8372b8c3475cca3207c351a3362e38 Mon Sep 17 00:00:00 2001 From: Su5eD Date: Fri, 17 Nov 2023 23:04:12 +0100 Subject: [PATCH] Add amecs api forge port --- README.md | 6 + amecs-api/.github/workflows/push-main.yaml | 29 ++ amecs-api/.gitignore | 21 ++ amecs-api/.giup | 15 + amecs-api/LICENSE | 203 ++++++++++++ amecs-api/LICENSE_HEADER | 13 + amecs-api/README.md | 72 ++++ amecs-api/build.gradle | 132 ++++++++ amecs-api/gradle.properties | 18 + amecs-api/gradle/wrapper/gradle-wrapper.jar | Bin 0 -> 63721 bytes .../gradle/wrapper/gradle-wrapper.properties | 7 + amecs-api/gradlew | 249 ++++++++++++++ amecs-api/gradlew.bat | 92 ++++++ amecs-api/src/lombok.config | 1 + .../siphalor/amecs/api/AmecsKeyBinding.java | 101 ++++++ .../siphalor/amecs/api/KeyBindingUtils.java | 165 ++++++++++ .../de/siphalor/amecs/api/KeyModifier.java | 96 ++++++ .../de/siphalor/amecs/api/KeyModifiers.java | 308 ++++++++++++++++++ .../amecs/api/PriorityKeyBinding.java | 45 +++ .../amecs/api/input/InputEventHandler.java | 41 +++ .../amecs/api/input/InputHandlerManager.java | 60 ++++ .../java/de/siphalor/amecs/impl/AmecsAPI.java | 37 +++ .../amecs/impl/KeyBindingManager.java | 115 +++++++ .../impl/mixin/KeyMappingLookupAccessor.java | 34 ++ .../amecs/impl/mixin/MixinInputUtilType.java | 48 +++ .../amecs/impl/mixin/MixinKeyBinding.java | 51 +++ .../amecs/impl/mixin/MixinKeyboard.java | 45 +++ .../impl/mixin/MixinMinecraftClient.java | 38 +++ .../siphalor/amecs/impl/mixin/MixinMouse.java | 131 ++++++++ .../resources/META-INF/asm/mouseScrollHook.js | 35 ++ .../src/main/resources/META-INF/coremods.json | 3 + .../src/main/resources/META-INF/mods.toml | 28 ++ .../src/main/resources/amecsapi.accesswidener | 4 + .../src/main/resources/amecsapi.mixins.json | 18 + .../main/resources/assets/amecsapi/icon.png | Bin 0 -> 13257 bytes .../main/resources/assets/amecsapi/icon.svg | 113 +++++++ .../resources/assets/amecsapi/lang/de_de.json | 14 + .../resources/assets/amecsapi/lang/en_us.json | 16 + .../resources/assets/amecsapi/lang/et_ee.json | 1 + .../resources/assets/amecsapi/lang/fi_fi.json | 13 + .../resources/assets/amecsapi/lang/it_it.json | 13 + .../resources/assets/amecsapi/lang/ko_kr.json | 1 + .../resources/assets/amecsapi/lang/pt_br.json | 13 + .../resources/assets/amecsapi/lang/pt_pt.json | 13 + .../resources/assets/amecsapi/lang/ru_ru.json | 1 + .../resources/assets/amecsapi/lang/tr_tr.json | 1 + .../assets/amecsapi/lang/zh_hans.json | 1 + amecs-api/src/main/resources/pack.mcmeta | 6 + .../de/siphalor/amecs/testmod/ClientInit.java | 38 +++ .../amecs/testmod/TestPriorityKeybinding.java | 46 +++ .../src/testmod/resources/META-INF/mods.toml | 28 ++ .../assets/amecsapi-testmod/lang/en_us.json | 4 + amecs-api/src/testmod/resources/pack.mcmeta | 6 + build.gradle.kts | 1 + gradle.properties | 2 +- settings.gradle.kts | 3 +- 56 files changed, 2593 insertions(+), 2 deletions(-) create mode 100644 amecs-api/.github/workflows/push-main.yaml create mode 100644 amecs-api/.gitignore create mode 100644 amecs-api/.giup create mode 100644 amecs-api/LICENSE create mode 100644 amecs-api/LICENSE_HEADER create mode 100644 amecs-api/README.md create mode 100644 amecs-api/build.gradle create mode 100644 amecs-api/gradle.properties create mode 100644 amecs-api/gradle/wrapper/gradle-wrapper.jar create mode 100644 amecs-api/gradle/wrapper/gradle-wrapper.properties create mode 100644 amecs-api/gradlew create mode 100644 amecs-api/gradlew.bat create mode 100644 amecs-api/src/lombok.config create mode 100644 amecs-api/src/main/java/de/siphalor/amecs/api/AmecsKeyBinding.java create mode 100644 amecs-api/src/main/java/de/siphalor/amecs/api/KeyBindingUtils.java create mode 100644 amecs-api/src/main/java/de/siphalor/amecs/api/KeyModifier.java create mode 100644 amecs-api/src/main/java/de/siphalor/amecs/api/KeyModifiers.java create mode 100644 amecs-api/src/main/java/de/siphalor/amecs/api/PriorityKeyBinding.java create mode 100644 amecs-api/src/main/java/de/siphalor/amecs/api/input/InputEventHandler.java create mode 100644 amecs-api/src/main/java/de/siphalor/amecs/api/input/InputHandlerManager.java create mode 100644 amecs-api/src/main/java/de/siphalor/amecs/impl/AmecsAPI.java create mode 100644 amecs-api/src/main/java/de/siphalor/amecs/impl/KeyBindingManager.java create mode 100644 amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/KeyMappingLookupAccessor.java create mode 100644 amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/MixinInputUtilType.java create mode 100644 amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/MixinKeyBinding.java create mode 100644 amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/MixinKeyboard.java create mode 100644 amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/MixinMinecraftClient.java create mode 100644 amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/MixinMouse.java create mode 100644 amecs-api/src/main/resources/META-INF/asm/mouseScrollHook.js create mode 100644 amecs-api/src/main/resources/META-INF/coremods.json create mode 100644 amecs-api/src/main/resources/META-INF/mods.toml create mode 100644 amecs-api/src/main/resources/amecsapi.accesswidener create mode 100644 amecs-api/src/main/resources/amecsapi.mixins.json create mode 100644 amecs-api/src/main/resources/assets/amecsapi/icon.png create mode 100644 amecs-api/src/main/resources/assets/amecsapi/icon.svg create mode 100644 amecs-api/src/main/resources/assets/amecsapi/lang/de_de.json create mode 100644 amecs-api/src/main/resources/assets/amecsapi/lang/en_us.json create mode 100644 amecs-api/src/main/resources/assets/amecsapi/lang/et_ee.json create mode 100644 amecs-api/src/main/resources/assets/amecsapi/lang/fi_fi.json create mode 100644 amecs-api/src/main/resources/assets/amecsapi/lang/it_it.json create mode 100644 amecs-api/src/main/resources/assets/amecsapi/lang/ko_kr.json create mode 100644 amecs-api/src/main/resources/assets/amecsapi/lang/pt_br.json create mode 100644 amecs-api/src/main/resources/assets/amecsapi/lang/pt_pt.json create mode 100644 amecs-api/src/main/resources/assets/amecsapi/lang/ru_ru.json create mode 100644 amecs-api/src/main/resources/assets/amecsapi/lang/tr_tr.json create mode 100644 amecs-api/src/main/resources/assets/amecsapi/lang/zh_hans.json create mode 100644 amecs-api/src/main/resources/pack.mcmeta create mode 100644 amecs-api/src/testmod/java/de/siphalor/amecs/testmod/ClientInit.java create mode 100644 amecs-api/src/testmod/java/de/siphalor/amecs/testmod/TestPriorityKeybinding.java create mode 100644 amecs-api/src/testmod/resources/META-INF/mods.toml create mode 100644 amecs-api/src/testmod/resources/assets/amecsapi-testmod/lang/en_us.json create mode 100644 amecs-api/src/testmod/resources/pack.mcmeta diff --git a/README.md b/README.md index 4e93aec..5621920 100644 --- a/README.md +++ b/README.md @@ -73,6 +73,12 @@ However, this is too soon as it happens before blocks of Forge mods are register be created for Forge mod blocks. To fix this issue, we patch Continuity to move the block state map initialization from Fabric's client entrypoint to FML's client setup event, which is fired after registration has completed. +### Amecs API - Forge port + +A Forge port of the Fabric [Amecs API](https://github.com/Siphalor/amecs-api) +library, implemented alongside Forge's key modifier system. Allows for compatiblity with Fabric mods that require it, +but wouldn't otherwise be compatible due to the heavy forge mixin conflicts of the original version. + ## Get help If you're having trouble using Connector Extras or believe it is not functioning correctly, ask us diff --git a/amecs-api/.github/workflows/push-main.yaml b/amecs-api/.github/workflows/push-main.yaml new file mode 100644 index 0000000..1a95792 --- /dev/null +++ b/amecs-api/.github/workflows/push-main.yaml @@ -0,0 +1,29 @@ +on: + push: + branches: + - "1.15" + + +jobs: + auto-fix: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + with: + token: "${{ secrets.CUSTOMGHTOKEN }}" + + - name: Fix language file names + run: | + for lang in src/main/resources/assets/*/lang/*.json + do + rename=$(echo "$lang" | sed -e 's/\b\w\+\.json$/\L\0/' -e 's/\b\([a-z]\+\)\.json$/\/\1_\1.json/') + mv "$lang" "$rename" || true + done + + - name: Commit + uses: EndBug/add-and-commit@v9 + with: + add: 'src/main/resources/assets' + default_author: github_actions + message: Fix language file names diff --git a/amecs-api/.gitignore b/amecs-api/.gitignore new file mode 100644 index 0000000..66d25e7 --- /dev/null +++ b/amecs-api/.gitignore @@ -0,0 +1,21 @@ +#Gradle +.gradle/ +build/ +out/ +classes/ + +#IDEA +.idea/ +*.iml +*.ipr +*.iws + +#vscode +.settings/ +.vscode/ +bin/ +.classpath +.project + +#fabric +run/ \ No newline at end of file diff --git a/amecs-api/.giup b/amecs-api/.giup new file mode 100644 index 0000000..02dd328 --- /dev/null +++ b/amecs-api/.giup @@ -0,0 +1,15 @@ +{ + "merge-paths": [ + "1.15", + "1.15->1.14", + "1.15->1.16->1.17->1.18->1.19->1.19.3->1.19.4->1.20->unstable" + ], + "commands": [ + { + "title": "Build and publish", + "run": "./gradlew publish", + "nt": "gradlew publish" + }, + "git push" + ] +} diff --git a/amecs-api/LICENSE b/amecs-api/LICENSE new file mode 100644 index 0000000..6b0b127 --- /dev/null +++ b/amecs-api/LICENSE @@ -0,0 +1,203 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + diff --git a/amecs-api/LICENSE_HEADER b/amecs-api/LICENSE_HEADER new file mode 100644 index 0000000..901bcb1 --- /dev/null +++ b/amecs-api/LICENSE_HEADER @@ -0,0 +1,13 @@ +Copyright 2020-2023 Siphalor + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. diff --git a/amecs-api/README.md b/amecs-api/README.md new file mode 100644 index 0000000..16ff9a7 --- /dev/null +++ b/amecs-api/README.md @@ -0,0 +1,72 @@ +
+Logo + +# Amecs API (or Amecs' API) + +![supported Minecraft versions: 1.14 | 1.15 | 1.16 | 1.17 | 1.18 | 1.19](https://img.shields.io/badge/support%20for%20MC-1.14%20%7C%201.15%20%7C%201.16%20%7C%201.17%20%7C%201.18%20%7C%201.19-%2356AD56?style=for-the-badge) + +[![latest maven release](https://img.shields.io/maven-metadata/v?color=0f9fbc&metadataUrl=https%3A%2F%2Fmaven.siphalor.de%2Fde%2Fsiphalor%2Famecsapi-1.16%2Fmaven-metadata.xml&style=flat-square)](https://maven.siphalor.de/de/siphalor/amecsapi-1.16/) + +This library mod provides modifier keys for Minecraft keybindings as well as some related keybinding utilities + +**  +[Amecs](https://github.com/Siphalor/amecs) · +[Discord](https://discord.gg/6gaXmbj) + ** + +
+ +## Usage + If you're not a modder you're probably looking for [Amecs](https://github.com/Siphalor/amecs). + + If you **are** a modder then you can use Amecs with the following in your build.gradle: + + ```groovy +repositories { + maven { + url "https://maven.siphalor.de/" + name "Siphalor's Maven" + } +} + +// VERSION: Check the badge above for the latest version +// MINECRAFT_VERSION: The major Minecraft version you're developing for (e.g. 1.15 for 1.15.2) +dependencies { + include(modImplementation("de.siphalor:amecsapi-MINECRAFT_VERSION:VERSION")) +} +``` + +## Features + +If you want to see some example of how to use this library, you can take a look at the [testmod](./src/testmod/java/de/siphalor/amecs/testmod). + +### Modifier Keys + +Modifier keys can be set by the user for all keybindings, including Vanilla ones. + +If you want to define a keybinding that uses modifier keys for its default value, you can extend the [`AmecsKeyBinding`](./src/main/java/de/siphalor/amecs/api/AmecsKeyBinding.java) class. + +If you want to further integrate this library, check the [`KeyBindingUtils`](./src/main/java/de/siphalor/amecs/api/KeyBindingUtils.java) class. + +### Priority Keybindings + +Priority keybindings are keybindings that are executed before all other keybindings and are allowed to cancel further evaluation. +This has various use cases, for example: + +- Keybindings that work when not in-game +- Keybindings that work regardless if the chat or a GUI is open + +You can make use of priority keybindings by implementing the [`PriorityKeyBinding`](src/main/java/de/siphalor/amecs/api/PriorityKeyBinding.java) interface. + +Please always carefully check if your priority keybinding takes action in the right context. +For example, you oftentimes don't want to execute your priority keybinding when the chat is open. + +### Keybinding Descriptions + +Keybinding descriptions are a way to provide a description for a keybinding that are shown as a tooltip when hovering over the keybinding in the controls menu. + +You can add descriptions by defining translations for the keybinding's translation key with the suffix `.amecsapi.description`. + +## License + +This mod is licensed under [the Apache 2.0 license](./LICENSE). diff --git a/amecs-api/build.gradle b/amecs-api/build.gradle new file mode 100644 index 0000000..2fde242 --- /dev/null +++ b/amecs-api/build.gradle @@ -0,0 +1,132 @@ +plugins { + id 'dev.architectury.loom' + id 'maven-publish' + id 'org.cadixdev.licenser' version '0.6.1' +} + +sourceCompatibility = JavaVersion.VERSION_1_8 +targetCompatibility = JavaVersion.VERSION_1_8 + +archivesBaseName = project.archives_base_name +version = "$mod_version+mc$minecraft_version".toString() +group = project.maven_group + +sourceSets { + testmod { + compileClasspath += main.compileClasspath + runtimeClasspath += main.runtimeClasspath + } +} + +loom { + accessWidenerPath.set(file("src/main/resources/amecsapi.accesswidener")) + forge { + mixinConfig "amecsapi.mixins.json" + convertAccessWideners = true + } + mixin { + defaultRefmapName.set("refmap.amecsapi.json") + } + runs { + configureEach { + property "mixin.debug", "true" + property "mixin.debug.export.decompile", "false" + property "mixin.debug.verbose", "true" + property "mixin.dumpTargetOnFailure", "true" + property "mixin.checks", "true" + property "mixin.hotSwap", "true" + } + testmodClient { + client() + source sourceSets.testmod + } + } + loom.mods.register("amecsapi_testmod") { + sourceSet sourceSets.testmod + } +} + +repositories { + maven { + name "Siphalor's Maven" + url "https://maven.siphalor.de" + } + maven { + url "https://jitpack.io" + } + mavenLocal() +} + +dependencies { + //to change the versions see the gradle.properties file + forge "net.minecraftforge:forge:$forge_version" + mappings "net.fabricmc:yarn:${project.minecraft_version}+build.${project.yarn_mappings}:v2" + modImplementation "net.fabricmc:fabric-loader:${project.loader_version}" + + compileOnly(annotationProcessor("org.projectlombok:lombok:$lombok_version")) + testCompileOnly(testAnnotationProcessor("org.projectlombok:lombok:$lombok_version")) + + //modImplementation("de.siphalor:nmuk-${project.minecraft_major_version}:1.0.1+mc1.19.3") { + // exclude module: "amecsapi-${project.minecraft_major_version}" + //} + + modImplementation('dev.su5ed.sinytra.fabric-api:fabric-api-base:0.4.30+ef105b4977') + modImplementation('dev.su5ed.sinytra.fabric-api:fabric-key-binding-api-v1:1.0.36+561530ec77') + + testmodImplementation sourceSets.main.output +} + +license { + header = project.file('LICENSE_HEADER') + + include '**/*.java' +} + +processResources { + inputs.property "version", project.version + + afterEvaluate { + from(sourceSets.main.resources.srcDirs) { + include "fabric.mod.json" + expand "version": version + duplicatesStrategy DuplicatesStrategy.INCLUDE + } + } +} + +// ensure that the encoding is set to UTF-8, no matter what the system default is +// this fixes some edge cases with special characters not displaying correctly +// see http://yodaconditions.net/blog/fix-for-java-file-encoding-problems-with-gradle.html +tasks.withType(JavaCompile).configureEach { + options.encoding = "UTF-8" +} + +jar { + from "LICENSE" +} + +// configure the maven publication +publishing { + publications { + create("mavenJava", MavenPublication) { + artifactId = "${project.archives_base_name}-${project.minecraft_major_version}".toString() + + from components.java + java.withSourcesJar() + } + } + + // select the repositories you want to publish to + repositories { + if (project.hasProperty("siphalorMavenPassword")) { + maven { + name = "Siphalor" + url = "https://maven.siphalor.de/upload.php" + credentials { + username = siphalorMavenUser + password = siphalorMavenPassword + } + } + } + } +} diff --git a/amecs-api/gradle.properties b/amecs-api/gradle.properties new file mode 100644 index 0000000..d4eb817 --- /dev/null +++ b/amecs-api/gradle.properties @@ -0,0 +1,18 @@ +org.gradle.jvmargs = -Xmx1G + +#Fabric properties +minecraft_major_version = 1.20 +minecraft_version = 1.20-pre1 +yarn_mappings = 7 +loader_version = 0.14.19 + +#Mod properties +mod_version = 1.5.3 +maven_group = de.siphalor +archives_base_name = amecsapi + +# Dependencies +lombok_version = 1.18.28 +fabric_api_version = 0.80.3+1.20 +forge_version = 1.20.1-47.1.3 +loom.platform=forge \ No newline at end of file diff --git a/amecs-api/gradle/wrapper/gradle-wrapper.jar b/amecs-api/gradle/wrapper/gradle-wrapper.jar new file mode 100644 index 0000000000000000000000000000000000000000..7f93135c49b765f8051ef9d0a6055ff8e46073d8 GIT binary patch literal 63721 zcmb5Wb9gP!wgnp7wrv|bwr$&XvSZt}Z6`anZSUAlc9NHKf9JdJ;NJVr`=eI(_pMp0 zy1VAAG3FfAOI`{X1O)&90s;U4K;XLp008~hCjbEC_fbYfS%6kTR+JtXK>nW$ZR+`W ze|#J8f4A@M|F5BpfUJb5h>|j$jOe}0oE!`Zf6fM>CR?!y@zU(cL8NsKk`a z6tx5mAkdjD;J=LcJ;;Aw8p!v#ouk>mUDZF@ zK>yvw%+bKu+T{Nk@LZ;zkYy0HBKw06_IWcMHo*0HKpTsEFZhn5qCHH9j z)|XpN&{`!0a>Vl+PmdQc)Yg4A(AG-z!+@Q#eHr&g<9D?7E)_aEB?s_rx>UE9TUq|? z;(ggJt>9l?C|zoO@5)tu?EV0x_7T17q4fF-q3{yZ^ipUbKcRZ4Qftd!xO(#UGhb2y>?*@{xq%`(-`2T^vc=#< zx!+@4pRdk&*1ht2OWk^Z5IAQ0YTAXLkL{(D*$gENaD)7A%^XXrCchN&z2x+*>o2FwPFjWpeaL=!tzv#JOW#( z$B)Nel<+$bkH1KZv3&-}=SiG~w2sbDbAWarg%5>YbC|}*d9hBjBkR(@tyM0T)FO$# zPtRXukGPnOd)~z=?avu+4Co@wF}1T)-uh5jI<1$HLtyDrVak{gw`mcH@Q-@wg{v^c zRzu}hMKFHV<8w}o*yg6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zPr=ch{uuoHjtw7+_!L_2;knQ!DuDl0R`|%jr+}jFzXtrHIKc323?JO{l&;VF z*L1+}JU7%QJOg|5|Tc|D8fN zJORAg=_vsy{ak|o);@)Yh8Lkcg@$FG3k@ep36BRa^>~UmnRPziS>Z=`Jb2x*Q#`%A zU*i3&Vg?TluO@X0O;r2Jl6LKLUOVhSqg1*qOt^|8*c7 zo(298@+r$k_wQNGHv{|$tW(T8L+4_`FQ{kEW5Jgg{yf7ey4ss_(SNKfz(N9lx&a;< je(UuV8hP?p&}TPdm1I$XmG#(RzlD&B2izSj9sl%y5~4qc literal 0 HcmV?d00001 diff --git a/amecs-api/gradle/wrapper/gradle-wrapper.properties b/amecs-api/gradle/wrapper/gradle-wrapper.properties new file mode 100644 index 0000000..ac72c34 --- /dev/null +++ b/amecs-api/gradle/wrapper/gradle-wrapper.properties @@ -0,0 +1,7 @@ +distributionBase=GRADLE_USER_HOME +distributionPath=wrapper/dists +distributionUrl=https\://services.gradle.org/distributions/gradle-8.3-bin.zip +networkTimeout=10000 +validateDistributionUrl=true +zipStoreBase=GRADLE_USER_HOME +zipStorePath=wrapper/dists diff --git a/amecs-api/gradlew b/amecs-api/gradlew new file mode 100644 index 0000000..0adc8e1 --- /dev/null +++ b/amecs-api/gradlew @@ -0,0 +1,249 @@ +#!/bin/sh + +# +# Copyright © 2015-2021 the original authors. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +############################################################################## +# +# Gradle start up script for POSIX generated by Gradle. +# +# Important for running: +# +# (1) You need a POSIX-compliant shell to run this script. If your /bin/sh is +# noncompliant, but you have some other compliant shell such as ksh or +# bash, then to run this script, type that shell name before the whole +# command line, like: +# +# ksh Gradle +# +# Busybox and similar reduced shells will NOT work, because this script +# requires all of these POSIX shell features: +# * functions; +# * expansions «$var», «${var}», «${var:-default}», «${var+SET}», +# «${var#prefix}», «${var%suffix}», and «$( cmd )»; +# * compound commands having a testable exit status, especially «case»; +# * various built-in commands including «command», «set», and «ulimit». +# +# Important for patching: +# +# (2) This script targets any POSIX shell, so it avoids extensions provided +# by Bash, Ksh, etc; in particular arrays are avoided. +# +# The "traditional" practice of packing multiple parameters into a +# space-separated string is a well documented source of bugs and security +# problems, so this is (mostly) avoided, by progressively accumulating +# options in "$@", and eventually passing that to Java. +# +# Where the inherited environment variables (DEFAULT_JVM_OPTS, JAVA_OPTS, +# and GRADLE_OPTS) rely on word-splitting, this is performed explicitly; +# see the in-line comments for details. +# +# There are tweaks for specific operating systems such as AIX, CygWin, +# Darwin, MinGW, and NonStop. +# +# (3) This script is generated from the Groovy template +# https://github.com/gradle/gradle/blob/HEAD/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt +# within the Gradle project. +# +# You can find Gradle at https://github.com/gradle/gradle/. +# +############################################################################## + +# Attempt to set APP_HOME + +# Resolve links: $0 may be a link +app_path=$0 + +# Need this for daisy-chained symlinks. +while + APP_HOME=${app_path%"${app_path##*/}"} # leaves a trailing /; empty if no leading path + [ -h "$app_path" ] +do + ls=$( ls -ld "$app_path" ) + link=${ls#*' -> '} + case $link in #( + /*) app_path=$link ;; #( + *) app_path=$APP_HOME$link ;; + esac +done + +# This is normally unused +# shellcheck disable=SC2034 +APP_BASE_NAME=${0##*/} +# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036) +APP_HOME=$( cd "${APP_HOME:-./}" > /dev/null && pwd -P ) || exit + +# Use the maximum available, or set MAX_FD != -1 to use that value. +MAX_FD=maximum + +warn () { + echo "$*" +} >&2 + +die () { + echo + echo "$*" + echo + exit 1 +} >&2 + +# OS specific support (must be 'true' or 'false'). +cygwin=false +msys=false +darwin=false +nonstop=false +case "$( uname )" in #( + CYGWIN* ) cygwin=true ;; #( + Darwin* ) darwin=true ;; #( + MSYS* | MINGW* ) msys=true ;; #( + NONSTOP* ) nonstop=true ;; +esac + +CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar + + +# Determine the Java command to use to start the JVM. +if [ -n "$JAVA_HOME" ] ; then + if [ -x "$JAVA_HOME/jre/sh/java" ] ; then + # IBM's JDK on AIX uses strange locations for the executables + JAVACMD=$JAVA_HOME/jre/sh/java + else + JAVACMD=$JAVA_HOME/bin/java + fi + if [ ! -x "$JAVACMD" ] ; then + die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME + +Please set the JAVA_HOME variable in your environment to match the +location of your Java installation." + fi +else + JAVACMD=java + if ! command -v java >/dev/null 2>&1 + then + die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. + +Please set the JAVA_HOME variable in your environment to match the +location of your Java installation." + fi +fi + +# Increase the maximum file descriptors if we can. +if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then + case $MAX_FD in #( + max*) + # In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked. + # shellcheck disable=SC3045 + MAX_FD=$( ulimit -H -n ) || + warn "Could not query maximum file descriptor limit" + esac + case $MAX_FD in #( + '' | soft) :;; #( + *) + # In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked. + # shellcheck disable=SC3045 + ulimit -n "$MAX_FD" || + warn "Could not set maximum file descriptor limit to $MAX_FD" + esac +fi + +# Collect all arguments for the java command, stacking in reverse order: +# * args from the command line +# * the main class name +# * -classpath +# * -D...appname settings +# * --module-path (only if needed) +# * DEFAULT_JVM_OPTS, JAVA_OPTS, and GRADLE_OPTS environment variables. + +# For Cygwin or MSYS, switch paths to Windows format before running java +if "$cygwin" || "$msys" ; then + APP_HOME=$( cygpath --path --mixed "$APP_HOME" ) + CLASSPATH=$( cygpath --path --mixed "$CLASSPATH" ) + + JAVACMD=$( cygpath --unix "$JAVACMD" ) + + # Now convert the arguments - kludge to limit ourselves to /bin/sh + for arg do + if + case $arg in #( + -*) false ;; # don't mess with options #( + /?*) t=${arg#/} t=/${t%%/*} # looks like a POSIX filepath + [ -e "$t" ] ;; #( + *) false ;; + esac + then + arg=$( cygpath --path --ignore --mixed "$arg" ) + fi + # Roll the args list around exactly as many times as the number of + # args, so each arg winds up back in the position where it started, but + # possibly modified. + # + # NB: a `for` loop captures its iteration list before it begins, so + # changing the positional parameters here affects neither the number of + # iterations, nor the values presented in `arg`. + shift # remove old arg + set -- "$@" "$arg" # push replacement arg + done +fi + + +# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. +DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"' + +# Collect all arguments for the java command; +# * $DEFAULT_JVM_OPTS, $JAVA_OPTS, and $GRADLE_OPTS can contain fragments of +# shell script including quotes and variable substitutions, so put them in +# double quotes to make sure that they get re-expanded; and +# * put everything else in single quotes, so that it's not re-expanded. + +set -- \ + "-Dorg.gradle.appname=$APP_BASE_NAME" \ + -classpath "$CLASSPATH" \ + org.gradle.wrapper.GradleWrapperMain \ + "$@" + +# Stop when "xargs" is not available. +if ! command -v xargs >/dev/null 2>&1 +then + die "xargs is not available" +fi + +# Use "xargs" to parse quoted args. +# +# With -n1 it outputs one arg per line, with the quotes and backslashes removed. +# +# In Bash we could simply go: +# +# readarray ARGS < <( xargs -n1 <<<"$var" ) && +# set -- "${ARGS[@]}" "$@" +# +# but POSIX shell has neither arrays nor command substitution, so instead we +# post-process each arg (as a line of input to sed) to backslash-escape any +# character that might be a shell metacharacter, then use eval to reverse +# that process (while maintaining the separation between arguments), and wrap +# the whole thing up as a single "set" statement. +# +# This will of course break if any of these variables contains a newline or +# an unmatched quote. +# + +eval "set -- $( + printf '%s\n' "$DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS" | + xargs -n1 | + sed ' s~[^-[:alnum:]+,./:=@_]~\\&~g; ' | + tr '\n' ' ' + )" '"$@"' + +exec "$JAVACMD" "$@" diff --git a/amecs-api/gradlew.bat b/amecs-api/gradlew.bat new file mode 100644 index 0000000..93e3f59 --- /dev/null +++ b/amecs-api/gradlew.bat @@ -0,0 +1,92 @@ +@rem +@rem Copyright 2015 the original author or authors. +@rem +@rem Licensed under the Apache License, Version 2.0 (the "License"); +@rem you may not use this file except in compliance with the License. +@rem You may obtain a copy of the License at +@rem +@rem https://www.apache.org/licenses/LICENSE-2.0 +@rem +@rem Unless required by applicable law or agreed to in writing, software +@rem distributed under the License is distributed on an "AS IS" BASIS, +@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +@rem See the License for the specific language governing permissions and +@rem limitations under the License. +@rem + +@if "%DEBUG%"=="" @echo off +@rem ########################################################################## +@rem +@rem Gradle startup script for Windows +@rem +@rem ########################################################################## + +@rem Set local scope for the variables with windows NT shell +if "%OS%"=="Windows_NT" setlocal + +set DIRNAME=%~dp0 +if "%DIRNAME%"=="" set DIRNAME=. +@rem This is normally unused +set APP_BASE_NAME=%~n0 +set APP_HOME=%DIRNAME% + +@rem Resolve any "." and ".." in APP_HOME to make it shorter. +for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi + +@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. +set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m" + +@rem Find java.exe +if defined JAVA_HOME goto findJavaFromJavaHome + +set JAVA_EXE=java.exe +%JAVA_EXE% -version >NUL 2>&1 +if %ERRORLEVEL% equ 0 goto execute + +echo. +echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. +echo. +echo Please set the JAVA_HOME variable in your environment to match the +echo location of your Java installation. + +goto fail + +:findJavaFromJavaHome +set JAVA_HOME=%JAVA_HOME:"=% +set JAVA_EXE=%JAVA_HOME%/bin/java.exe + +if exist "%JAVA_EXE%" goto execute + +echo. +echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% +echo. +echo Please set the JAVA_HOME variable in your environment to match the +echo location of your Java installation. + +goto fail + +:execute +@rem Setup the command line + +set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar + + +@rem Execute Gradle +"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %* + +:end +@rem End local scope for the variables with windows NT shell +if %ERRORLEVEL% equ 0 goto mainEnd + +:fail +rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of +rem the _cmd.exe /c_ return code! +set EXIT_CODE=%ERRORLEVEL% +if %EXIT_CODE% equ 0 set EXIT_CODE=1 +if not ""=="%GRADLE_EXIT_CONSOLE%" exit %EXIT_CODE% +exit /b %EXIT_CODE% + +:mainEnd +if "%OS%"=="Windows_NT" endlocal + +:omega diff --git a/amecs-api/src/lombok.config b/amecs-api/src/lombok.config new file mode 100644 index 0000000..93c64ca --- /dev/null +++ b/amecs-api/src/lombok.config @@ -0,0 +1 @@ +lombok.log.custom.declaration = org.apache.logging.log4j.Logger org.apache.logging.log4j.LogManager.getLogger(TYPE) diff --git a/amecs-api/src/main/java/de/siphalor/amecs/api/AmecsKeyBinding.java b/amecs-api/src/main/java/de/siphalor/amecs/api/AmecsKeyBinding.java new file mode 100644 index 0000000..5ec415d --- /dev/null +++ b/amecs-api/src/main/java/de/siphalor/amecs/api/AmecsKeyBinding.java @@ -0,0 +1,101 @@ +/* + * Copyright 2020-2023 Siphalor + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package de.siphalor.amecs.api; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.option.KeyBinding; +import net.minecraft.client.util.InputUtil; +import net.minecraft.util.Identifier; +import net.minecraftforge.client.settings.KeyConflictContext; +import net.minecraftforge.client.settings.KeyModifier; + +/** + * A {@link net.minecraft.client.option.KeyBinding} base class to be used when you want to define modifiers keys as default + */ +@Environment(EnvType.CLIENT) +public class AmecsKeyBinding extends KeyBinding { + private final KeyModifiers defaultModifiers; + + /** + * Constructs a new amecs keybinding. And because how the vanilla key binding works. It is automatically registered. + *
+ * See {@link KeyBindingUtils#unregisterKeyBinding(KeyBinding)} for how to unregister it + * If you want to set the key's translationKey directly use {@link #AmecsKeyBinding(String, net.minecraft.client.util.InputUtil.Type, int, String, KeyModifiers)} instead + * + * @param id the id to use + * @param type the input type which triggers this keybinding + * @param code the default key code + * @param category the id of the category which should include this keybinding + * @param defaultModifiers the default modifiers + */ + public AmecsKeyBinding(Identifier id, InputUtil.Type type, int code, String category, KeyModifiers defaultModifiers) { + this("key." + id.getNamespace() + "." + id.getPath(), type, code, category, defaultModifiers); + } + + /** + * Constructs a new amecs keybinding. And because how the vanilla key binding works. It is automatically registered. + *
+ * See {@link KeyBindingUtils#unregisterKeyBinding(KeyBinding)} for how to unregister it + * + * @param id the id to use + * @param type the input type which triggers this keybinding + * @param code the default key code + * @param category the id of the category which should include this keybinding + * @param defaultModifiers the default modifiers + */ + public AmecsKeyBinding(String id, InputUtil.Type type, int code, String category, KeyModifiers defaultModifiers) { + super(id, KeyConflictContext.UNIVERSAL, defaultModifiers != null ? defaultModifiers.getFirst() : KeyModifier.NONE, type, code, category); + if (defaultModifiers == null || defaultModifiers == KeyModifiers.NO_MODIFIERS) { + defaultModifiers = new KeyModifiers(); // the modifiable version of: KeyModifiers.NO_MODIFIERS + } + this.defaultModifiers = defaultModifiers; + } + + @Override + public void setPressed(boolean pressed) { + super.setPressed(pressed); + if (pressed) { + onPressed(); + } else { + onReleased(); + } + } + + /** + * A convenience method which gets fired when the keybinding is used + */ + public void onPressed() { + } + + /** + * A convenience method which gets fired when the keybinding is stopped being used + */ + public void onReleased() { + } + + /** + * Resets this keybinding (triggered when the user clicks on the "Reset" button). + */ + public void resetKeyBinding() { + setKeyModifierAndCode(getDefaultKeyModifier(), getKey()); + } + + public KeyModifiers getDefaultModifiers() { + return defaultModifiers; + } +} diff --git a/amecs-api/src/main/java/de/siphalor/amecs/api/KeyBindingUtils.java b/amecs-api/src/main/java/de/siphalor/amecs/api/KeyBindingUtils.java new file mode 100644 index 0000000..cfcbe87 --- /dev/null +++ b/amecs-api/src/main/java/de/siphalor/amecs/api/KeyBindingUtils.java @@ -0,0 +1,165 @@ +/* + * Copyright 2020-2023 Siphalor + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package de.siphalor.amecs.api; + +import de.siphalor.amecs.impl.KeyBindingManager; +import lombok.CustomLog; +import lombok.Getter; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.option.KeyBinding; +import net.minecraft.client.util.InputUtil; +import net.minecraftforge.client.settings.KeyModifier; + +import java.lang.reflect.InvocationTargetException; +import java.lang.reflect.Method; +import java.util.Map; + +/** + * Utility methods and constants for Amecs and vanilla key bindings + */ +@SuppressWarnings("unused") +@Environment(EnvType.CLIENT) +@CustomLog +public class KeyBindingUtils { + public static final int MOUSE_SCROLL_UP = 512; + public static final int MOUSE_SCROLL_DOWN = 513; + + /** + * The last (y directional) scroll delta + */ + @Getter + private static double lastScrollAmount = 0; + private static Map idToKeyBindingMap; + + private KeyBindingUtils() {} + + /** + * Sets the last (y directional) scroll amount. For internal use only. + * + * @param lastScrollAmount the amount + */ + public static void setLastScrollAmount(double lastScrollAmount) { + KeyBindingUtils.lastScrollAmount = lastScrollAmount; + } + + /** + * Gets the key object for the scroll direction + * + * @param deltaY the vertical (y) scroll amount {@link #getLastScrollAmount} + * @return the key object + */ + public static InputUtil.Key getKeyFromScroll(double deltaY) { + return InputUtil.Type.MOUSE.createFromCode(deltaY > 0 ? KeyBindingUtils.MOUSE_SCROLL_UP : KeyBindingUtils.MOUSE_SCROLL_DOWN); + } + + /** + * Gets the "official" idToKeys map + * + * @return the map (use with care) + */ + public static Map getIdToKeyBindingMap() { + if (idToKeyBindingMap == null) { + try { + // reflections accessors should be initialized statically if they are static + // but in this case its fine because we only do this once because it is cached in a static field + + // noinspection JavaReflectionMemberAccess + Method method = KeyBinding.class.getDeclaredMethod("amecs$getIdToKeyBindingMap"); + method.setAccessible(true); + // noinspection unchecked + idToKeyBindingMap = (Map) method.invoke(null); + } catch (NoSuchMethodException | IllegalAccessException | InvocationTargetException e) { + log.error("Failed to get access to key bindings", e); + } + } + return idToKeyBindingMap; + } + + /** + * Unregisters a keybinding from input querying but is NOT removed from the controls GUI + *
+ * if you unregister a keybinding which is already in the controls GUI you can call {@link #registerHiddenKeyBinding(KeyBinding)} with this keybinding to undo this + *
+ *
+ * This is possible even after the game initialized + * + * @param keyBinding the keybinding + * @return whether the keyBinding was removed. It is not removed if it was not contained + */ + public static boolean unregisterKeyBinding(KeyBinding keyBinding) { + return unregisterKeyBinding(keyBinding.getTranslationKey()); + } + + /** + * Unregisters a keybinding with the given id + *
+ * for more details {@link #unregisterKeyBinding(KeyBinding)} + * + * @see #unregisterKeyBinding(KeyBinding) + * @param id the translation key + * @return whether the keyBinding was removed. It is not removed if it was not contained + */ + public static boolean unregisterKeyBinding(String id) { + return KeyBindingManager.unregister(id); + } + + /** + * Registers a keybinding for input querying but is NOT added to the controls GUI + *
+ * you can register a keybinding which is already in the controls GUI but was removed from input querying via {@link #unregisterKeyBinding(KeyBinding)} + *
+ *
+ * This is possible even after the game initialized + * + * @param keyBinding the keybinding + * @return whether the keybinding was added. It is not added if it is already contained + */ + public static boolean registerHiddenKeyBinding(KeyBinding keyBinding) { + return KeyBindingManager.register(keyBinding); + } + + /** + * Gets the key modifiers that are bound to the given key binding + * @param keyBinding the key binding + * @return the key modifiers + */ + public static KeyModifiers getBoundModifiers(KeyBinding keyBinding) { + return new KeyModifiers(keyBinding.getKeyModifier()); + } + + /** + * Gets the default modifiers of the given key binding. + * The returned value must not be modified! + * @param keyBinding the key binding + * @return a reference to the default modifiers + */ + public static KeyModifiers getDefaultModifiers(KeyBinding keyBinding) { + if (keyBinding instanceof AmecsKeyBinding) { + return ((AmecsKeyBinding) keyBinding).getDefaultModifiers(); + } + return KeyModifiers.NO_MODIFIERS; + } + + public static void resetBoundModifiers(KeyBinding keyBinding) { + if (keyBinding instanceof AmecsKeyBinding) { + ((AmecsKeyBinding) keyBinding).resetKeyBinding(); + } else { + keyBinding.setKeyModifierAndCode(KeyModifier.NONE, keyBinding.getKey()); + } + } +} diff --git a/amecs-api/src/main/java/de/siphalor/amecs/api/KeyModifier.java b/amecs-api/src/main/java/de/siphalor/amecs/api/KeyModifier.java new file mode 100644 index 0000000..ce25d74 --- /dev/null +++ b/amecs-api/src/main/java/de/siphalor/amecs/api/KeyModifier.java @@ -0,0 +1,96 @@ +/* + * Copyright 2020-2023 Siphalor + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package de.siphalor.amecs.api; + +import com.google.common.collect.BiMap; +import com.google.common.collect.ImmutableBiMap; +import de.siphalor.amecs.impl.AmecsAPI; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.util.InputUtil; +import org.apache.commons.lang3.ArrayUtils; + +import java.util.function.Function; +import java.util.stream.Collectors; +import java.util.stream.Stream; + +@SuppressWarnings("WeakerAccess") +@Environment(EnvType.CLIENT) +public enum KeyModifier { + // the order of the enums makes a difference when generating the shown name in the gui + // with this order the old text order is preserved. But now the id values do not increment nicely. But changing them would eliminate + // backward compatibility with the old save format + NONE("none", -1), + ALT("alt", 0, 342, 346), + SHIFT("shift", 2, 340, 344), + CONTROL("control", 1, 341, 345); + + // using this array for the values because it is faster than calling values() every time + public static final KeyModifier[] VALUES = KeyModifier.values(); + private static final BiMap FORGE_MAP = ImmutableBiMap.copyOf(Stream.of(VALUES) + .collect(Collectors.toMap(Function.identity(), m -> net.minecraftforge.client.settings.KeyModifier.valueFromString(m.name())))); + + public final String name; + public final int id; + // these keyCodes are all from Type: InputUtil.Type.KEYSYM + final int[] keyCodes; + + KeyModifier(String name, int id, int... keyCodes) { + this.name = name; + this.id = id; + this.keyCodes = keyCodes; + } + + public static KeyModifier fromKeyCode(int keyCode) { + for (KeyModifier keyModifier : VALUES) { + if (keyModifier == NONE) { + continue; + } + if (keyModifier.matches(keyCode)) { + return keyModifier; + } + } + return NONE; + } + + public static KeyModifier fromKey(InputUtil.Key key) { + if (key == null || key.getCategory() != InputUtil.Type.KEYSYM) { + return NONE; + } + return fromKeyCode(key.getCode()); + } + + public boolean matches(int keyCode) { + return ArrayUtils.contains(keyCodes, keyCode); + } + + public String getTranslationKey() { + return AmecsAPI.MOD_ID + ".modifier." + name; + } + + public static int getModifierCount() { + return VALUES.length - 1; // remove 1 for NONE + } + + public net.minecraftforge.client.settings.KeyModifier toForgeKeyModifier() { + return FORGE_MAP.getOrDefault(this, net.minecraftforge.client.settings.KeyModifier.NONE); + } + + public static KeyModifier fromForgeKeyModifier(net.minecraftforge.client.settings.KeyModifier modifier) { + return FORGE_MAP.inverse().getOrDefault(modifier, NONE); + } +} diff --git a/amecs-api/src/main/java/de/siphalor/amecs/api/KeyModifiers.java b/amecs-api/src/main/java/de/siphalor/amecs/api/KeyModifiers.java new file mode 100644 index 0000000..60b30a8 --- /dev/null +++ b/amecs-api/src/main/java/de/siphalor/amecs/api/KeyModifiers.java @@ -0,0 +1,308 @@ +/* + * Copyright 2020-2023 Siphalor + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package de.siphalor.amecs.api; + +import de.siphalor.amecs.impl.AmecsAPI; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.option.KeyBinding; +import net.minecraft.client.util.InputUtil; +import org.apache.commons.lang3.ArrayUtils; +import org.jetbrains.annotations.ApiStatus; + +import java.util.Arrays; + +/** + * Defines modifiers for a key binding + */ +@SuppressWarnings({"WeakerAccess", "UnusedReturnValue"}) +@Environment(EnvType.CLIENT) +public class KeyModifiers { + /** + * This field is for comparison ONLY. + *

+ * Trying to change the modifiers of it will fail with an {@link UnsupportedOperationException} + */ + public static final KeyModifiers NO_MODIFIERS = new FinalKeyModifiers(); + + private static class FinalKeyModifiers extends KeyModifiers { + private static final String EXCEPTION_MESSAGE = "You must not alter this Modifiers object"; + + @Override + public KeyModifiers setValue(boolean[] value) { + throw new UnsupportedOperationException(EXCEPTION_MESSAGE); + } + + @Override + public void set(KeyModifier keyModifier, boolean value) { + throw new UnsupportedOperationException(EXCEPTION_MESSAGE); + } + + @Override + public void unset() { + throw new UnsupportedOperationException(EXCEPTION_MESSAGE); + } + } + + public static KeyModifiers getCurrentlyPressed() { + return AmecsAPI.CURRENT_MODIFIERS; + } + + // using a boolean array here because it is faster and needs less space + private final boolean[] value; + + /** + * Constructs new object with no modifiers set + */ + public KeyModifiers() { + this(new boolean[KeyModifier.getModifierCount()]); + } + + /** + * FOR INTERNAL USE ONLY + *

+ * Constructs a new modifier object by a raw boolean array + * + * @param value the raw value with flags set + */ + @ApiStatus.Internal + public KeyModifiers(boolean[] value) { + if (value.length != KeyModifier.getModifierCount()) { + throw new IllegalArgumentException("value.length != KeyModifier.getModifierCount(): " + KeyModifier.getModifierCount()); + } + this.value = value; + } + + /** + * Constructs a new modifier object by all modifier bits + * + * @param alt sets whether the alt flag should be set + * @param control sets whether the control flag should be set + * @param shift sets whether the shift flag should be set + */ + public KeyModifiers(boolean alt, boolean control, boolean shift) { + this(); + setAlt(alt); + setControl(control); + setShift(shift); + } + + public KeyModifiers(net.minecraftforge.client.settings.KeyModifier modifier) { + this(); + setSingleModifier(modifier); + } + + /** + * Compares this object with the currently pressed keys + * + * @return whether the modifiers match in the current context + * @deprecated always performs an exact check against {@link #getCurrentlyPressed()}. + * Use {@link AmecsAPI#CURRENT_MODIFIERS} in combination with {@link #contains(KeyModifiers)} or {@link #equals(KeyModifiers)} instead. + */ + @Deprecated + public boolean isPressed() { + return equals(AmecsAPI.CURRENT_MODIFIERS); + } + + /** + * Returns whether the given modifiers are also set in this object. + * @param other the modifiers to check + * @return whether the given modifiers are also set in this object + */ + public boolean contains(KeyModifiers other) { + for (int i = 0; i < value.length; i++) { + if (other.value[i] && !this.value[i]) { + return false; + } + } + return true; + } + + /** + * FOR INTERNAL USE ONLY + *

+ * Sets the raw value + * + * @param value the value with flags set + */ + @ApiStatus.Internal + public KeyModifiers setValue(boolean[] value) { + int length = this.value.length; + if (value.length != length) { + throw new IllegalArgumentException("value != this.value.length: " + length); + } + System.arraycopy(value, 0, this.value, 0, length); + return this; + } + + /** + * FOR INTERNAL USE ONLY + *

+ * Gets the raw value + * + * @return the value with all flags set + */ + @ApiStatus.Internal + public boolean[] getValue() { + return value; + } + + /** + * FOR INTERNAL USE ONLY + *

+ * copies the modifiers of the other KeyModifiers object into this + */ + @ApiStatus.Internal + public void copyModifiers(KeyModifiers other) { + setValue(other.getValue()); + } + + /** + * Sets the alt flag + * + * @param value whether the alt flag should be activated or not + */ + public KeyModifiers setAlt(boolean value) { + set(KeyModifier.ALT, value); + return this; + } + + /** + * Gets the state of the alt flag + * + * @return whether the alt key needs to be pressed + */ + public boolean getAlt() { + return get(KeyModifier.ALT); + } + + /** + * Sets the control flag + * + * @param value whether the control flag should be activated or not + */ + public KeyModifiers setControl(boolean value) { + set(KeyModifier.CONTROL, value); + return this; + } + + /** + * Gets the state of the control flag + * + * @return whether the control key needs to be pressed + */ + public boolean getControl() { + return get(KeyModifier.CONTROL); + } + + /** + * Sets the shift flag + * + * @param value whether the shift flag should be activated or not + */ + public KeyModifiers setShift(boolean value) { + set(KeyModifier.SHIFT, value); + return this; + } + + /** + * Gets the state of the shift flag + * + * @return whether the shift key needs to be pressed + */ + public boolean getShift() { + return get(KeyModifier.SHIFT); + } + + public void set(KeyModifier keyModifier, boolean value) { + if (keyModifier != KeyModifier.NONE) { + this.value[keyModifier.id] = value; + } + } + + public boolean get(KeyModifier keyModifier) { + if (keyModifier == KeyModifier.NONE) { + return true; + } + return value[keyModifier.id]; + } + + /** + * Returns whether no flag is set + * + * @return value == 0 + */ + public boolean isUnset() { + return !ArrayUtils.contains(value, true); + } + + /** + * Clears all flags + */ + public void unset() { + Arrays.fill(value, false); + } + + /** + * Cleans up the flags by the key code present in the given key binding + * + * @param keyBinding the key binding from where to extract the key code + */ + public void cleanup(KeyBinding keyBinding) { + InputUtil.Key key = keyBinding.getKey(); + set(KeyModifier.fromKey(key), false); + } + + @Override + public boolean equals(Object obj) { + if (obj instanceof KeyModifiers) { + return equals((KeyModifiers) obj); + } + return false; + } + + /** + * Returns whether this object equals another one + * + * @param other another modifier object + * @return whether both values are equal + */ + public boolean equals(KeyModifiers other) { + return Arrays.equals(value, other.value); + } + + @Override + public String toString() { + return "KeyModifiers [alt=" + getAlt() + ", control=" + getControl() + ", shift=" + getShift() + "]"; + } + + public net.minecraftforge.client.settings.KeyModifier getFirst() { + for (KeyModifier modifier : KeyModifier.values()) { + if (modifier != KeyModifier.NONE && get(modifier)) { + return modifier.toForgeKeyModifier(); + } + } + return net.minecraftforge.client.settings.KeyModifier.NONE; + } + + public void setSingleModifier(net.minecraftforge.client.settings.KeyModifier modifier) { + unset(); + + KeyModifier amecsModifier = KeyModifier.fromForgeKeyModifier(modifier); + this.value[amecsModifier.id] = true; + } +} diff --git a/amecs-api/src/main/java/de/siphalor/amecs/api/PriorityKeyBinding.java b/amecs-api/src/main/java/de/siphalor/amecs/api/PriorityKeyBinding.java new file mode 100644 index 0000000..9f44472 --- /dev/null +++ b/amecs-api/src/main/java/de/siphalor/amecs/api/PriorityKeyBinding.java @@ -0,0 +1,45 @@ +/* + * Copyright 2020-2023 Siphalor + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package de.siphalor.amecs.api; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; + +/** + * An interface to be used on {@link net.minecraft.client.option.KeyBinding}s. + * This key binding triggers without further conditions before any other checks or conditions. + */ +@Environment(EnvType.CLIENT) +public interface PriorityKeyBinding { + /** + * This method gets triggered when this key binding matches on an input event.
+ * Since there are no other checks before the invocation you need to check yourself for possible open screens. + * + * @return Return true to cancel propagation of this event. Return false for normal evaluation. + */ + boolean onPressedPriority(); + + /** + * This method gets triggered when this key binding matches on an input release event.
+ * Since there are no other checks before the invocation you need to check yourself for possible open screens. + * + * @return Return true to cancel propagation of this event. Return false for normal evaluation. + */ + default boolean onReleasedPriority() { + return false; + } +} diff --git a/amecs-api/src/main/java/de/siphalor/amecs/api/input/InputEventHandler.java b/amecs-api/src/main/java/de/siphalor/amecs/api/input/InputEventHandler.java new file mode 100644 index 0000000..c67a8ac --- /dev/null +++ b/amecs-api/src/main/java/de/siphalor/amecs/api/input/InputEventHandler.java @@ -0,0 +1,41 @@ +/* + * Copyright 2020-2023 Siphalor + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package de.siphalor.amecs.api.input; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.MinecraftClient; + +/** + * This interface is used for input event handling and is (un-)registered in {@link InputHandlerManager} + * + * @see #handleInput + * @see InputHandlerManager + */ +@Environment(EnvType.CLIENT) +public interface InputEventHandler { + + /** + * This method is called from {@link InputHandlerManager#handleInputEvents(MinecraftClient)} + * + * @see InputHandlerManager#handleInputEvents(MinecraftClient) + * + * @param client + */ + public void handleInput(MinecraftClient client); + +} diff --git a/amecs-api/src/main/java/de/siphalor/amecs/api/input/InputHandlerManager.java b/amecs-api/src/main/java/de/siphalor/amecs/api/input/InputHandlerManager.java new file mode 100644 index 0000000..34309b0 --- /dev/null +++ b/amecs-api/src/main/java/de/siphalor/amecs/api/input/InputHandlerManager.java @@ -0,0 +1,60 @@ +/* + * Copyright 2020-2023 Siphalor + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package de.siphalor.amecs.api.input; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.MinecraftClient; +import org.jetbrains.annotations.ApiStatus; + +import java.util.LinkedHashSet; + +/** + * This class allows you to (un-)register {@link InputEventHandler}s + * + * @see InputEventHandler#handleInput(MinecraftClient) + * @see #handleInputEvents + */ +@Environment(EnvType.CLIENT) +public class InputHandlerManager { + + // all methods and fields in this class must be used from main thread only or manual synchronization is required + private static final LinkedHashSet INPUT_HANDLERS = new LinkedHashSet<>(); + + /** + * This method is called from MinecraftClient.handleInputEvents() + *
+ * It calls all registered InputEventHandler + * + * @param client + */ + @ApiStatus.Internal + public static void handleInputEvents(MinecraftClient client) { + for (InputEventHandler handler : INPUT_HANDLERS) { + handler.handleInput(client); + } + } + + public static boolean registerInputEventHandler(InputEventHandler handler) { + return INPUT_HANDLERS.add(handler); + } + + public static boolean removeInputEventHandler(InputEventHandler handler) { + return INPUT_HANDLERS.remove(handler); + } + +} diff --git a/amecs-api/src/main/java/de/siphalor/amecs/impl/AmecsAPI.java b/amecs-api/src/main/java/de/siphalor/amecs/impl/AmecsAPI.java new file mode 100644 index 0000000..d4dd894 --- /dev/null +++ b/amecs-api/src/main/java/de/siphalor/amecs/impl/AmecsAPI.java @@ -0,0 +1,37 @@ +/* + * Copyright 2020-2023 Siphalor + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package de.siphalor.amecs.impl; + +import de.siphalor.amecs.api.KeyModifiers; +import net.minecraftforge.fml.common.Mod; +import org.jetbrains.annotations.ApiStatus; + +@ApiStatus.Internal +@Mod(AmecsAPI.MOD_ID) +public class AmecsAPI { + public static final String MOD_ID = "amecsapi"; + public static final String MOD_NAME = "Amecs API"; + + public static final KeyModifiers CURRENT_MODIFIERS = new KeyModifiers(); + + // this is used by KTIG + public static boolean TRIGGER_KEYBINDING_ON_SCROLL = true; + + public static String makeKeyID(String keyName) { + return "key." + MOD_ID + "." + keyName; + } +} diff --git a/amecs-api/src/main/java/de/siphalor/amecs/impl/KeyBindingManager.java b/amecs-api/src/main/java/de/siphalor/amecs/impl/KeyBindingManager.java new file mode 100644 index 0000000..43c0ff0 --- /dev/null +++ b/amecs-api/src/main/java/de/siphalor/amecs/impl/KeyBindingManager.java @@ -0,0 +1,115 @@ +/* + * Copyright 2020-2023 Siphalor + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package de.siphalor.amecs.impl; + +import de.siphalor.amecs.api.PriorityKeyBinding; +import de.siphalor.amecs.impl.mixin.KeyMappingLookupAccessor; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.option.KeyBinding; +import net.minecraft.client.util.InputUtil; +import net.minecraftforge.client.settings.KeyMappingLookup; +import net.minecraftforge.client.settings.KeyModifier; +import net.minecraftforge.fml.util.ObfuscationReflectionHelper; +import org.jetbrains.annotations.ApiStatus; + +import java.util.*; +import java.util.stream.Collectors; +import java.util.stream.Stream; + +@Environment(EnvType.CLIENT) +@ApiStatus.Internal +public class KeyBindingManager { + private static final Map> PRIORITY_KEY_BINDINGS = new HashMap<>(); + + private KeyBindingManager() { + } + + /** + * Registers a key binding to Amecs API + * + * @param keyBinding the key binding to register + * @return whether the keyBinding was added. It is not added if it is already contained + */ + public static boolean register(KeyBinding keyBinding) { + if (keyBinding instanceof PriorityKeyBinding) { + PRIORITY_KEY_BINDINGS.computeIfAbsent(keyBinding.getKey(), k -> new ArrayList<>()).add(keyBinding); + return true; + } else { + KeyMappingLookup lookup = getKeyMappingLookup(); + EnumMap>> map = ((KeyMappingLookupAccessor) lookup).getMap(); + if (!map.get(keyBinding.getKeyModifier()).containsKey(keyBinding.getKey())) { + lookup.put(keyBinding.getKey(), keyBinding); + return true; + } + return false; + } + } + + /** + * Unregisters a key binding from Amecs API + * + * @param id the key binding to unregister + * @return whether the keyBinding was removed. It is not removed if it was not contained + */ + public static boolean unregister(String id) { + KeyMappingLookup lookup = getKeyMappingLookup(); + EnumMap>> map = ((KeyMappingLookupAccessor) lookup).getMap(); + for (Map> keyMap : map.values()) { + for (Collection keys : keyMap.values()) { + for (KeyBinding key : keys) { + if (key.getTranslationKey().equals(id)) { + keys.remove(key); + return true; + } + } + } + } + return false; + } + + public static Stream getMatchingKeyBindings(InputUtil.Key keyCode) { + List keyBindingList = PRIORITY_KEY_BINDINGS.get(keyCode); + if (keyBindingList == null) + return Stream.empty(); + Stream result = keyBindingList.stream().filter(KeyBindingManager::areExactModifiersPressed); + List keyBindings = result.collect(Collectors.toList()); + if (keyBindings.isEmpty()) + return keyBindingList.stream().filter(keyBinding -> keyBinding.getKeyModifier() == KeyModifier.NONE); + return keyBindings.stream(); + } + + private static boolean areExactModifiersPressed(KeyBinding keyBinding) { + return keyBinding.getKeyModifier() == KeyModifier.getActiveModifier(); + } + + public static boolean onKeyPressedPriority(InputUtil.Key keyCode) { + // because streams are lazily evaluated, this code only calls onPressedPriority so often until one returns true + Optional keyBindings = getMatchingKeyBindings(keyCode).filter(keyBinding -> ((PriorityKeyBinding) keyBinding).onPressedPriority()).findFirst(); + return keyBindings.isPresent(); + } + + public static boolean onKeyReleasedPriority(InputUtil.Key keyCode) { + // because streams are lazily evaluated, this code only calls onPressedPriority so often until one returns true + Optional keyBindings = getMatchingKeyBindings(keyCode).filter(keyBinding -> ((PriorityKeyBinding) keyBinding).onReleasedPriority()).findFirst(); + return keyBindings.isPresent(); + } + + public static KeyMappingLookup getKeyMappingLookup() { + return ObfuscationReflectionHelper.getPrivateValue(KeyBinding.class, null, "MAP"); + } +} diff --git a/amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/KeyMappingLookupAccessor.java b/amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/KeyMappingLookupAccessor.java new file mode 100644 index 0000000..9a5c91c --- /dev/null +++ b/amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/KeyMappingLookupAccessor.java @@ -0,0 +1,34 @@ +/* + * Copyright 2020-2023 Siphalor + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package de.siphalor.amecs.impl.mixin; + +import net.minecraft.client.option.KeyBinding; +import net.minecraft.client.util.InputUtil; +import net.minecraftforge.client.settings.KeyMappingLookup; +import net.minecraftforge.client.settings.KeyModifier; +import org.spongepowered.asm.mixin.Mixin; +import org.spongepowered.asm.mixin.gen.Accessor; + +import java.util.Collection; +import java.util.EnumMap; +import java.util.Map; + +@Mixin(KeyMappingLookup.class) +public interface KeyMappingLookupAccessor { + @Accessor + EnumMap>> getMap(); +} diff --git a/amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/MixinInputUtilType.java b/amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/MixinInputUtilType.java new file mode 100644 index 0000000..3984562 --- /dev/null +++ b/amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/MixinInputUtilType.java @@ -0,0 +1,48 @@ +/* + * Copyright 2020-2023 Siphalor + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package de.siphalor.amecs.impl.mixin; + +import de.siphalor.amecs.api.KeyBindingUtils; +import de.siphalor.amecs.impl.AmecsAPI; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.util.InputUtil; +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.Inject; +import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; + +@Environment(EnvType.CLIENT) +@Mixin(InputUtil.Type.class) +public abstract class MixinInputUtilType { + @SuppressWarnings("UnresolvedMixinReference") + @Inject(method = "", at = @At("RETURN")) + private static void onRegisterKeyCodes(CallbackInfo callbackInfo) { + createScrollKey("mouse.scroll.up", KeyBindingUtils.MOUSE_SCROLL_UP); + createScrollKey("mouse.scroll.down", KeyBindingUtils.MOUSE_SCROLL_DOWN); + } + + @Unique + private static void createScrollKey(String name, int keyCode) { + String keyName = AmecsAPI.makeKeyID(name); + InputUtil.Type.mapKey(InputUtil.Type.MOUSE, keyName, keyCode); + + // Legacy compatibility (amecsapi <1.3) + InputUtil.Key.KEYS.put("amecsapi.key." + name, InputUtil.fromTranslationKey(keyName)); + } +} diff --git a/amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/MixinKeyBinding.java b/amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/MixinKeyBinding.java new file mode 100644 index 0000000..f54e3ec --- /dev/null +++ b/amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/MixinKeyBinding.java @@ -0,0 +1,51 @@ +/* + * Copyright 2020-2023 Siphalor + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package de.siphalor.amecs.impl.mixin; + +import de.siphalor.amecs.api.PriorityKeyBinding; +import de.siphalor.amecs.impl.KeyBindingManager; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.option.KeyBinding; +import net.minecraft.client.util.InputUtil; +import net.minecraftforge.client.settings.IKeyConflictContext; +import net.minecraftforge.client.settings.KeyModifier; +import org.spongepowered.asm.mixin.Mixin; +import org.spongepowered.asm.mixin.injection.At; +import org.spongepowered.asm.mixin.injection.Inject; +import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; + +@SuppressWarnings("WeakerAccess") +@Environment(EnvType.CLIENT) +@Mixin(KeyBinding.class) +public abstract class MixinKeyBinding { + + @Inject(method = "(Ljava/lang/String;Lnet/minecraft/client/util/InputUtil$Type;ILjava/lang/String;)V", at = @At("RETURN")) + private void onConstructed(String id, InputUtil.Type type, int defaultCode, String category, CallbackInfo callbackInfo) { + if (this instanceof PriorityKeyBinding) { + KeyBindingManager.register((KeyBinding) (Object) this); + } + } + + @Inject(method = "(Ljava/lang/String;Lnet/minecraftforge/client/settings/IKeyConflictContext;Lnet/minecraftforge/client/settings/KeyModifier;Lnet/minecraft/client/util/InputUtil$Key;Ljava/lang/String;)V", at = @At("RETURN")) + private void onConstructedForge(String description, IKeyConflictContext keyConflictContext, KeyModifier keyModifier, InputUtil.Key keyCode, String category, CallbackInfo ci) { + if (this instanceof PriorityKeyBinding) { + KeyBindingManager.register((KeyBinding) (Object) this); + } + } + +} diff --git a/amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/MixinKeyboard.java b/amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/MixinKeyboard.java new file mode 100644 index 0000000..a1015cc --- /dev/null +++ b/amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/MixinKeyboard.java @@ -0,0 +1,45 @@ +/* + * Copyright 2020-2023 Siphalor + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package de.siphalor.amecs.impl.mixin; + +import de.siphalor.amecs.impl.KeyBindingManager; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.Keyboard; +import net.minecraft.client.util.InputUtil; +import org.spongepowered.asm.mixin.Mixin; +import org.spongepowered.asm.mixin.injection.At; +import org.spongepowered.asm.mixin.injection.Inject; +import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; + +@Environment(EnvType.CLIENT) +@Mixin(Keyboard.class) +public class MixinKeyboard { + + @Inject(method = "onKey", at = @At(value = "FIELD", target = "Lnet/minecraft/client/MinecraftClient;currentScreen:Lnet/minecraft/client/gui/screen/Screen;", ordinal = 0, shift = At.Shift.BEFORE), cancellable = true) + private void onKeyPriority(long window, int key, int scanCode, int action, int modifiers, CallbackInfo callbackInfo) { + if (action == 1) { + if (KeyBindingManager.onKeyPressedPriority(InputUtil.fromKeyCode(key, scanCode))) { + callbackInfo.cancel(); + } + } else if (action == 0) { + if (KeyBindingManager.onKeyReleasedPriority(InputUtil.fromKeyCode(key, scanCode))) { + callbackInfo.cancel(); + } + } + } +} diff --git a/amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/MixinMinecraftClient.java b/amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/MixinMinecraftClient.java new file mode 100644 index 0000000..e5d6a97 --- /dev/null +++ b/amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/MixinMinecraftClient.java @@ -0,0 +1,38 @@ +/* + * Copyright 2020-2023 Siphalor + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package de.siphalor.amecs.impl.mixin; + +import org.spongepowered.asm.mixin.Mixin; +import org.spongepowered.asm.mixin.injection.At; +import org.spongepowered.asm.mixin.injection.Inject; +import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; + +import de.siphalor.amecs.api.input.InputHandlerManager; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.MinecraftClient; + +@Environment(EnvType.CLIENT) +@Mixin(value = MinecraftClient.class, priority = 50) +public abstract class MixinMinecraftClient { + + @Inject(method = "handleInputEvents()V", at = @At(value = "HEAD")) + private void handleInputEvents(CallbackInfo ci) { + InputHandlerManager.handleInputEvents((MinecraftClient) (Object) this); + } + +} diff --git a/amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/MixinMouse.java b/amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/MixinMouse.java new file mode 100644 index 0000000..4a50ca7 --- /dev/null +++ b/amecs-api/src/main/java/de/siphalor/amecs/impl/mixin/MixinMouse.java @@ -0,0 +1,131 @@ +/* + * Copyright 2020-2023 Siphalor + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package de.siphalor.amecs.impl.mixin; + +import de.siphalor.amecs.api.KeyBindingUtils; +import de.siphalor.amecs.api.KeyModifier; +import de.siphalor.amecs.impl.AmecsAPI; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.MinecraftClient; +import net.minecraft.client.Mouse; +import net.minecraft.client.gui.screen.option.KeybindsScreen; +import net.minecraft.client.option.KeyBinding; +import net.minecraft.client.util.InputUtil; +import org.spongepowered.asm.mixin.Final; +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.Surrogate; +import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; +import org.spongepowered.asm.mixin.injection.callback.LocalCapture; + +// TODO: Fix the priority when Mixin 0.8 is a thing and try again (-> MaLiLib causes incompatibilities) +@Environment(EnvType.CLIENT) +@Mixin(value = Mouse.class, priority = -2000) +public class MixinMouse { + @Shadow + @Final + private MinecraftClient client; + + @Shadow + private double eventDeltaWheel; + + // If this method changes make sure to also change the corresponding code in KTIG + private void onScrollReceived(double deltaY, boolean manualDeltaWheel, int scrollAmount) { + if (manualDeltaWheel) { + // from minecraft but patched + // this code might be wrong when the vanilla mc code changes + if (eventDeltaWheel != 0.0D && Math.signum(deltaY) != Math.signum(eventDeltaWheel)) { + eventDeltaWheel = 0.0D; + } + + eventDeltaWheel += deltaY; + scrollAmount = (int) eventDeltaWheel; + if (scrollAmount == 0) { + return; + } + + eventDeltaWheel -= scrollAmount; + // -from minecraft + } + + InputUtil.Key keyCode = KeyBindingUtils.getKeyFromScroll(scrollAmount); + + KeyBinding.setKeyPressed(keyCode, true); + scrollAmount = Math.abs(scrollAmount); + + while (scrollAmount > 0) { + KeyBinding.onKeyPressed(keyCode); + scrollAmount--; + } + KeyBinding.setKeyPressed(keyCode, false); + + // default minecraft scroll logic is in HotbarScrollKeyBinding in amecs + } + + @SuppressWarnings("InvalidInjectorMethodSignature") + @Inject(method = "onMouseScroll", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/network/ClientPlayerEntity;isSpectator()Z", ordinal = 0), locals = LocalCapture.CAPTURE_FAILHARD) + private void isSpectator_onMouseScroll(long window, double rawX, double rawY, CallbackInfo callbackInfo, double offset, double deltaY, int scrollAmount) { + if (AmecsAPI.TRIGGER_KEYBINDING_ON_SCROLL) { + onScrollReceived(KeyBindingUtils.getLastScrollAmount(), false, scrollAmount); + } + } + + @Surrogate + private void isSpectator_onMouseScroll(long window, double rawX, double rawY, CallbackInfo callbackInfo, double offset, double deltaY, float scrollAmount) { + isSpectator_onMouseScroll(window, rawX, rawY, callbackInfo, offset, deltaY, (int) scrollAmount); + } + + // Invoked from ASM coremod hook + @SuppressWarnings("unused") + private boolean amecs$onMouseScrolledScreen(boolean handled) { + if (handled) { + return true; + } + + if (AmecsAPI.TRIGGER_KEYBINDING_ON_SCROLL) { + this.onScrollReceived(KeyBindingUtils.getLastScrollAmount(), true, 0); + } + return false; + } + + @Inject(method = "onMouseScroll", at = @At(value = "FIELD", target = "Lnet/minecraft/client/MinecraftClient;currentScreen:Lnet/minecraft/client/gui/screen/Screen;", ordinal = 0), locals = LocalCapture.CAPTURE_FAILHARD, cancellable = true) + private void onMouseScroll(long window, double rawX, double rawY, CallbackInfo callbackInfo, double offset, double deltaY) { + InputUtil.Key keyCode = KeyBindingUtils.getKeyFromScroll(deltaY); + + // check if we have scroll input for the options screen + if (client.currentScreen instanceof KeybindsScreen) { + KeyBinding focusedBinding = ((KeybindsScreen) client.currentScreen).selectedKeyBinding; + if (focusedBinding != null) { + if (!focusedBinding.isUnbound()) { + focusedBinding.setKeyModifierAndCode(KeyModifier.fromKey(focusedBinding.getKey()).toForgeKeyModifier(), focusedBinding.getKey()); + } + // This is a bit hacky, but the easiest way out + // If the selected binding != null, the mouse x and y will always be ignored - so no need to convert them + // The key code that InputUtil.MOUSE.createFromCode chooses is always one bigger than the input + client.currentScreen.mouseClicked(-1, -1, keyCode.getCode()); + // if we do we cancel the method because we do not want the current screen to get the scroll event + callbackInfo.cancel(); + return; + } + } + + KeyBindingUtils.setLastScrollAmount(deltaY); + } +} diff --git a/amecs-api/src/main/resources/META-INF/asm/mouseScrollHook.js b/amecs-api/src/main/resources/META-INF/asm/mouseScrollHook.js new file mode 100644 index 0000000..dd0f436 --- /dev/null +++ b/amecs-api/src/main/resources/META-INF/asm/mouseScrollHook.js @@ -0,0 +1,35 @@ +var ASMAPI = Java.type('net.minecraftforge.coremod.api.ASMAPI'); +var Opcodes = Java.type('org.objectweb.asm.Opcodes'); +var MethodInsnNode = Java.type('org.objectweb.asm.tree.MethodInsnNode'); +var InsnNode = Java.type('org.objectweb.asm.tree.InsnNode'); +var VarInsnNode = Java.type('org.objectweb.asm.tree.VarInsnNode'); + +function initializeCoreMod() { + return { + 'mouseScrollHook': { + 'target': { + 'type': 'METHOD', + 'class': 'net.minecraft.client.MouseHandler', + 'methodName': 'm_91526_', + 'methodDesc': '(JDD)V' + }, + 'transformer': function (node) { + var mappedMethodName = ASMAPI.mapMethod("m_6050_"); + for(var i = 0; i < node.instructions.size(); i++) { + var insn = node.instructions.get(i); + if (insn instanceof MethodInsnNode && insn.getOpcode() == Opcodes.INVOKEVIRTUAL && insn.owner == "net/minecraft/client/gui/screens/Screen" && insn.name == mappedMethodName) { + var list = ASMAPI.listOf( + new VarInsnNode(Opcodes.ALOAD, 0), + new InsnNode(Opcodes.DUP_X1), + new InsnNode(Opcodes.POP), + new MethodInsnNode(Opcodes.INVOKEVIRTUAL, "net/minecraft/client/MouseHandler", "amecs$onMouseScrolledScreen", "(Z)Z", false) + ); + node.instructions.insert(insn, list); + ASMAPI.log('DEBUG', 'Injected mouse scroll hook'); + } + } + return node; + } + } + } +} \ No newline at end of file diff --git a/amecs-api/src/main/resources/META-INF/coremods.json b/amecs-api/src/main/resources/META-INF/coremods.json new file mode 100644 index 0000000..804404b --- /dev/null +++ b/amecs-api/src/main/resources/META-INF/coremods.json @@ -0,0 +1,3 @@ +{ + "mouseScrollHook": "META-INF/asm/mouseScrollHook.js" +} \ No newline at end of file diff --git a/amecs-api/src/main/resources/META-INF/mods.toml b/amecs-api/src/main/resources/META-INF/mods.toml new file mode 100644 index 0000000..c8b5113 --- /dev/null +++ b/amecs-api/src/main/resources/META-INF/mods.toml @@ -0,0 +1,28 @@ +modLoader="javafml" +loaderVersion="[47,)" +license="Apache-2.0" +issueTrackerURL="https://github.com/Sinytra/ConnectorExtras/issues" + +[[mods]] +modId="amecsapi" +version="${file.jarVersion}" +displayName="Amecs API" +authors="Siphalor, Klotzi111" +displayURL="https://github.com/Sinytra/ConnectorExtras" +description=''' +The keybinding modifier API of Amecs +''' +logoFile="assets/amecsapi/icon.png" +displayTest = 'IGNORE_ALL_VERSION' +[[dependencies.amecsapi]] + modId="forge" + mandatory=true + versionRange="[47,)" + ordering="NONE" + side="BOTH" +[[dependencies.amecsapi]] + modId="minecraft" + mandatory=true + versionRange="[1.20.1,1.21)" + ordering="NONE" + side="BOTH" diff --git a/amecs-api/src/main/resources/amecsapi.accesswidener b/amecs-api/src/main/resources/amecsapi.accesswidener new file mode 100644 index 0000000..a26ba7c --- /dev/null +++ b/amecs-api/src/main/resources/amecsapi.accesswidener @@ -0,0 +1,4 @@ +accessWidener v1 named +accessible method net/minecraft/client/util/InputUtil$Type mapKey (Lnet/minecraft/client/util/InputUtil$Type;Ljava/lang/String;I)V + +accessible field net/minecraft/client/util/InputUtil$Key KEYS Ljava/util/Map; diff --git a/amecs-api/src/main/resources/amecsapi.mixins.json b/amecs-api/src/main/resources/amecsapi.mixins.json new file mode 100644 index 0000000..8a0d841 --- /dev/null +++ b/amecs-api/src/main/resources/amecsapi.mixins.json @@ -0,0 +1,18 @@ +{ + "required": true, + "package": "de.siphalor.amecs.impl.mixin", + "compatibilityLevel": "JAVA_8", + "mixins": [], + "client": [ + "KeyMappingLookupAccessor", + "MixinInputUtilType", + "MixinKeyBinding", + "MixinKeyboard", + "MixinMinecraftClient", + "MixinMouse" + ], + "server": [], + "injectors": { + "defaultRequire": 1 + } +} diff --git a/amecs-api/src/main/resources/assets/amecsapi/icon.png b/amecs-api/src/main/resources/assets/amecsapi/icon.png new file mode 100644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yE14gaBy4ztMCAuoyT2zq{H`2wPCX>@EXVXoD~w2ynm& zK!1=@<^uCk)XZ~H6il%l^A$aGq9|3dlj( zkjg+gEZYJEe7bv34$*d?oTS + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + diff --git a/amecs-api/src/main/resources/assets/amecsapi/lang/de_de.json b/amecs-api/src/main/resources/assets/amecsapi/lang/de_de.json new file mode 100644 index 0000000..48011d9 --- /dev/null +++ b/amecs-api/src/main/resources/assets/amecsapi/lang/de_de.json @@ -0,0 +1,14 @@ +{ + "key.amecsapi.mouse.scroll.up": "Mausrad auf", + "key.amecsapi.mouse.scroll.down": "Mausrad ab", + + "amecsapi.modifier.alt": "Alt", + "amecsapi.modifier.alt.short": "Alt", + "amecsapi.modifier.alt.tiny": "A", + "amecsapi.modifier.control": "Steuerung", + "amecsapi.modifier.control.short": "Strg", + "amecsapi.modifier.control.tiny": "S", + "amecsapi.modifier.shift": "Umschalt", + "amecsapi.modifier.shift.short": "Umst", + "amecsapi.modifier.shift.tiny": "U" +} diff --git a/amecs-api/src/main/resources/assets/amecsapi/lang/en_us.json b/amecs-api/src/main/resources/assets/amecsapi/lang/en_us.json new file mode 100644 index 0000000..367f7b7 --- /dev/null +++ b/amecs-api/src/main/resources/assets/amecsapi/lang/en_us.json @@ -0,0 +1,16 @@ +{ + "key.amecsapi.mouse.scroll.up": "Scroll Up", + "key.amecsapi.mouse.scroll.down": "Scroll Down", + "key.amecsapi.mouse.scroll.left": "Scroll Left", + "key.amecsapi.mouse.scroll.right": "Scroll Right", + + "amecsapi.modifier.alt": "Alt", + "amecsapi.modifier.alt.short": "Alt", + "amecsapi.modifier.alt.tiny": "A", + "amecsapi.modifier.control": "Control", + "amecsapi.modifier.control.short": "Ctrl", + "amecsapi.modifier.control.tiny": "C", + "amecsapi.modifier.shift": "Shift", + "amecsapi.modifier.shift.short": "Shft", + "amecsapi.modifier.shift.tiny": "S" +} diff --git a/amecs-api/src/main/resources/assets/amecsapi/lang/et_ee.json b/amecs-api/src/main/resources/assets/amecsapi/lang/et_ee.json new file mode 100644 index 0000000..0967ef4 --- /dev/null +++ b/amecs-api/src/main/resources/assets/amecsapi/lang/et_ee.json @@ -0,0 +1 @@ +{} diff --git a/amecs-api/src/main/resources/assets/amecsapi/lang/fi_fi.json b/amecs-api/src/main/resources/assets/amecsapi/lang/fi_fi.json new file mode 100644 index 0000000..d8a772d --- /dev/null +++ b/amecs-api/src/main/resources/assets/amecsapi/lang/fi_fi.json @@ -0,0 +1,13 @@ +{ + "amecsapi.modifier.alt.tiny": "A", + "amecsapi.modifier.control": "Control", + "amecsapi.modifier.control.short": "Ctrl", + "amecsapi.modifier.control.tiny": "C", + "amecsapi.modifier.shift": "Shift", + "amecsapi.modifier.shift.short": "Shft", + "amecsapi.modifier.shift.tiny": "S", + "amecsapi.modifier.alt": "Alt", + "amecsapi.modifier.alt.short": "Alt", + "key.amecsapi.mouse.scroll.up": "Selaa Ylös", + "key.amecsapi.mouse.scroll.down": "Selaa Alas" +} diff --git a/amecs-api/src/main/resources/assets/amecsapi/lang/it_it.json b/amecs-api/src/main/resources/assets/amecsapi/lang/it_it.json new file mode 100644 index 0000000..d707e0c --- /dev/null +++ b/amecs-api/src/main/resources/assets/amecsapi/lang/it_it.json @@ -0,0 +1,13 @@ +{ + "key.amecsapi.mouse.scroll.down": "Scorrere verso il basso", + "amecsapi.modifier.alt": "Alt", + "amecsapi.modifier.alt.short": "Alt", + "amecsapi.modifier.alt.tiny": "A", + "amecsapi.modifier.control.short": "Ctrl", + "amecsapi.modifier.control.tiny": "C", + "amecsapi.modifier.shift": "Maiuscolo", + "amecsapi.modifier.shift.short": "Maiusc", + "amecsapi.modifier.shift.tiny": "S", + "amecsapi.modifier.control": "Control", + "key.amecsapi.mouse.scroll.up": "Scorrere verso l'alto" +} diff --git a/amecs-api/src/main/resources/assets/amecsapi/lang/ko_kr.json b/amecs-api/src/main/resources/assets/amecsapi/lang/ko_kr.json new file mode 100644 index 0000000..0967ef4 --- /dev/null +++ b/amecs-api/src/main/resources/assets/amecsapi/lang/ko_kr.json @@ -0,0 +1 @@ +{} diff --git a/amecs-api/src/main/resources/assets/amecsapi/lang/pt_br.json b/amecs-api/src/main/resources/assets/amecsapi/lang/pt_br.json new file mode 100644 index 0000000..d149903 --- /dev/null +++ b/amecs-api/src/main/resources/assets/amecsapi/lang/pt_br.json @@ -0,0 +1,13 @@ +{ + "amecsapi.modifier.alt": "Alt", + "amecsapi.modifier.alt.short": "Alt", + "amecsapi.modifier.alt.tiny": "A", + "amecsapi.modifier.control": "Control", + "amecsapi.modifier.control.short": "Ctrl", + "amecsapi.modifier.control.tiny": "C", + "amecsapi.modifier.shift": "Shift", + "amecsapi.modifier.shift.short": "Shft", + "amecsapi.modifier.shift.tiny": "S", + "key.amecsapi.mouse.scroll.up": "Rolar para cima", + "key.amecsapi.mouse.scroll.down": "Rolar para baixo" +} diff --git a/amecs-api/src/main/resources/assets/amecsapi/lang/pt_pt.json b/amecs-api/src/main/resources/assets/amecsapi/lang/pt_pt.json new file mode 100644 index 0000000..19c6b30 --- /dev/null +++ b/amecs-api/src/main/resources/assets/amecsapi/lang/pt_pt.json @@ -0,0 +1,13 @@ +{ + "key.amecsapi.mouse.scroll.up": "Rolar para cima", + "key.amecsapi.mouse.scroll.down": "Rolar para baixo", + "amecsapi.modifier.alt": "Alt", + "amecsapi.modifier.alt.short": "Alt", + "amecsapi.modifier.alt.tiny": "A", + "amecsapi.modifier.control": "Control", + "amecsapi.modifier.control.short": "Ctrl", + "amecsapi.modifier.control.tiny": "C", + "amecsapi.modifier.shift": "Shift", + "amecsapi.modifier.shift.short": "Shft", + "amecsapi.modifier.shift.tiny": "S" +} diff --git a/amecs-api/src/main/resources/assets/amecsapi/lang/ru_ru.json b/amecs-api/src/main/resources/assets/amecsapi/lang/ru_ru.json new file mode 100644 index 0000000..0967ef4 --- /dev/null +++ b/amecs-api/src/main/resources/assets/amecsapi/lang/ru_ru.json @@ -0,0 +1 @@ +{} diff --git a/amecs-api/src/main/resources/assets/amecsapi/lang/tr_tr.json b/amecs-api/src/main/resources/assets/amecsapi/lang/tr_tr.json new file mode 100644 index 0000000..0967ef4 --- /dev/null +++ b/amecs-api/src/main/resources/assets/amecsapi/lang/tr_tr.json @@ -0,0 +1 @@ +{} diff --git a/amecs-api/src/main/resources/assets/amecsapi/lang/zh_hans.json b/amecs-api/src/main/resources/assets/amecsapi/lang/zh_hans.json new file mode 100644 index 0000000..0967ef4 --- /dev/null +++ b/amecs-api/src/main/resources/assets/amecsapi/lang/zh_hans.json @@ -0,0 +1 @@ +{} diff --git a/amecs-api/src/main/resources/pack.mcmeta b/amecs-api/src/main/resources/pack.mcmeta new file mode 100644 index 0000000..19dd0d0 --- /dev/null +++ b/amecs-api/src/main/resources/pack.mcmeta @@ -0,0 +1,6 @@ +{ + "pack": { + "description": "The default data for amecsapi", + "pack_format": 15 + } +} diff --git a/amecs-api/src/testmod/java/de/siphalor/amecs/testmod/ClientInit.java b/amecs-api/src/testmod/java/de/siphalor/amecs/testmod/ClientInit.java new file mode 100644 index 0000000..b80890d --- /dev/null +++ b/amecs-api/src/testmod/java/de/siphalor/amecs/testmod/ClientInit.java @@ -0,0 +1,38 @@ +/* + * Copyright 2020-2023 Siphalor + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package de.siphalor.amecs.testmod; + +import de.siphalor.amecs.api.KeyModifiers; +import net.fabricmc.fabric.api.client.keybinding.v1.KeyBindingHelper; +import net.minecraft.client.util.InputUtil; +import net.minecraft.util.Identifier; +import net.minecraftforge.fml.common.Mod; +import org.lwjgl.glfw.GLFW; + +@Mod("amecsapi_testmod") +public class ClientInit { + + public ClientInit() { + KeyBindingHelper.registerKeyBinding(new TestPriorityKeybinding(new Identifier("amecsapi-testmod", "priority"), InputUtil.Type.KEYSYM, GLFW.GLFW_KEY_Z, "key.categories.misc", new KeyModifiers(), () -> { + System.out.println("priority"); + return true; + }, () -> { + System.out.println("priority release"); + return true; + })); + } +} diff --git a/amecs-api/src/testmod/java/de/siphalor/amecs/testmod/TestPriorityKeybinding.java b/amecs-api/src/testmod/java/de/siphalor/amecs/testmod/TestPriorityKeybinding.java new file mode 100644 index 0000000..a58ab97 --- /dev/null +++ b/amecs-api/src/testmod/java/de/siphalor/amecs/testmod/TestPriorityKeybinding.java @@ -0,0 +1,46 @@ +/* + * Copyright 2020-2023 Siphalor + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package de.siphalor.amecs.testmod; + +import de.siphalor.amecs.api.AmecsKeyBinding; +import de.siphalor.amecs.api.KeyModifiers; +import de.siphalor.amecs.api.PriorityKeyBinding; +import net.minecraft.client.util.InputUtil; +import net.minecraft.util.Identifier; + +import java.util.function.BooleanSupplier; + +public class TestPriorityKeybinding extends AmecsKeyBinding implements PriorityKeyBinding { + private final BooleanSupplier action; + private final BooleanSupplier releaseAction; + + public TestPriorityKeybinding(Identifier id, InputUtil.Type type, int code, String category, KeyModifiers defaultModifiers, BooleanSupplier action, BooleanSupplier releaseAction) { + super(id, type, code, category, defaultModifiers); + this.action = action; + this.releaseAction = releaseAction; + } + + @Override + public boolean onPressedPriority() { + return action.getAsBoolean(); + } + + @Override + public boolean onReleasedPriority() { + return releaseAction.getAsBoolean(); + } +} diff --git a/amecs-api/src/testmod/resources/META-INF/mods.toml b/amecs-api/src/testmod/resources/META-INF/mods.toml new file mode 100644 index 0000000..b32902b --- /dev/null +++ b/amecs-api/src/testmod/resources/META-INF/mods.toml @@ -0,0 +1,28 @@ +modLoader="javafml" +loaderVersion="[47,)" +license="Apache-2.0" +issueTrackerURL="https://github.com/Sinytra/ConnectorExtras/issues" + +[[mods]] +modId="amecsapi_testmod" +version="${file.jarVersion}" +displayName="Amecs API Testmod" +authors="Siphalor, Klotzi111" +displayURL="https://github.com/Sinytra/ConnectorExtras" +description=''' +The keybinding modifier API of Amecs +''' +logoFile="assets/amecsapi/icon.png" +displayTest = 'IGNORE_ALL_VERSION' +[[dependencies.amecsapi_testmod]] + modId="forge" + mandatory=true + versionRange="[47,)" + ordering="NONE" + side="BOTH" +[[dependencies.amecsapi_testmod]] + modId="minecraft" + mandatory=true + versionRange="[1.20.1,1.21)" + ordering="NONE" + side="BOTH" diff --git a/amecs-api/src/testmod/resources/assets/amecsapi-testmod/lang/en_us.json b/amecs-api/src/testmod/resources/assets/amecsapi-testmod/lang/en_us.json new file mode 100644 index 0000000..b984baf --- /dev/null +++ b/amecs-api/src/testmod/resources/assets/amecsapi-testmod/lang/en_us.json @@ -0,0 +1,4 @@ +{ + "key.amecsapi-testmod.priority": "Priority Keybinding", + "key.amecsapi-testmod.priority.amecsapi.description": "A Keybinding that tests the priority execution using Amecs API.\nSupports line breaks." +} diff --git a/amecs-api/src/testmod/resources/pack.mcmeta b/amecs-api/src/testmod/resources/pack.mcmeta new file mode 100644 index 0000000..55edc9b --- /dev/null +++ b/amecs-api/src/testmod/resources/pack.mcmeta @@ -0,0 +1,6 @@ +{ + "pack": { + "description": "The default data for amecsapi_testmod", + "pack_format": 15 + } +} diff --git a/build.gradle.kts b/build.gradle.kts index 2e943b1..2ac95ca 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -88,6 +88,7 @@ dependencies { includeProject("geckolib-fabric-compat") includeProject("modmenu-bridge") includeProject("continuity-compat") + includeProject("amecs-api") // Misc modImplementation("curse.maven:mcpitanlibarch-682213:4723157") diff --git a/gradle.properties b/gradle.properties index 25e6a26..cead561 100644 --- a/gradle.properties +++ b/gradle.properties @@ -7,7 +7,7 @@ loom.platform=forge # Versions versionMc=1.20.1 versionForge=47.1.3 -versionConnectorExtras=1.5.1 +versionConnectorExtras=1.6.0 # Publishing curseForgeId=913445 diff --git a/settings.gradle.kts b/settings.gradle.kts index 921e924..f8ca94a 100644 --- a/settings.gradle.kts +++ b/settings.gradle.kts @@ -39,5 +39,6 @@ include( "terrablender-bridge", "geckolib-fabric-compat", "modmenu-bridge", - "continuity-compat" + "continuity-compat", + "amecs-api" )