TeamMidnightDust / MidnightControls

A Minecraft mod adding controller support and enhanced controls overall.
https://midnightdust.eu/midnightcontrols/
MIT License
185 stars 29 forks source link

Bug: "Cannot get payload sender when not in game" when used over Sunshine/Moonlight #299

Open Eusebius opened 2 months ago

Eusebius commented 2 months ago

Describe the bug When a MC instance is launched over Moonlight (Sunshine server, Moonlight on Android), it crashes at the first controller input with java.lang.IllegalStateException: Cannot get payload sender when not in game!. This does not happens when launched locally.

To Reproduce Steps to reproduce the behavior:

  1. Set up a MC instance in Prism launcher 8.4 (MC 1.20.6, JRE 21, Fabric Loader 0.15.11, MidnightControls 1.9.5)
  2. Install and setup a Sunshine server (v0.23.1).
  3. Install Moonlight 12.1 on an Android device, pair it with the Sunshine server.
  4. Connect an Xbox One controller to the Android device, via bluetooth.
  5. From Moonlight, remotely start Prism and launch the MC instance.
  6. At Minecraft main screen, touch your controller to navigage the main menu.
  7. Get an immediate MC crash (IllegalStateException: Cannot get payload sender when not in game!).

Expected behavior Input should be forwarded to MC, allowing navigation like when playing locally.

Screenshots

Prism Launcher version: 8.4 (official)

Launched instance in online mode

login.microsoftonline.com resolves to:
    [2603:1027:1:158::a, 2603:1026:3000:150::5, 2603:1027:1:158::2, 2603:1026:3000:150::c, 2603:1026:3000:148::e, 2603:1027:1:158::8, 2603:1026:3000:148::12, 2603:1026:3000:148::10, 40.126.31.69, 40.126.31.73, 20.190.159.4, 20.190.159.68, 20.190.159.75, 20.190.159.23, 20.190.159.0, 40.126.31.67]

session.minecraft.net resolves to:
    [2620:1ec:bdf::42, 13.107.246.42]

textures.minecraft.net resolves to:
    [2620:1ec:bdf::42, 13.107.246.42]

api.mojang.com resolves to:
    [2620:1ec:bdf::42, 13.107.246.42]

Minecraft folder is:
C:/Users/User/AppData/Roaming/PrismLauncher/instances/issue MWE/.minecraft

Java path is:
C:/Program Files/Java/jdk-21/bin/javaw.exe

Java is version 21.0.3, using 64 (amd64) architecture, from Oracle Corporation.

Main Class:
  net.fabricmc.loader.impl.launch.knot.KnotClient

Native path:
  C:/Users/User/AppData/Roaming/PrismLauncher/instances/issue MWE/natives

Traits:
traits FirstThreadOnMacOS
traits XR:Initial
traits feature:is_quick_play_multiplayer

Libraries:
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-freetype-natives-windows-arm64/3.3.3/lwjgl-freetype-natives-windows-arm64-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-freetype-natives-windows-x86/3.3.3/lwjgl-freetype-natives-windows-x86-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-freetype-natives-windows/3.3.3/lwjgl-freetype-natives-windows-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-freetype/3.3.3/lwjgl-freetype-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-glfw-natives-windows-arm64/3.3.3/lwjgl-glfw-natives-windows-arm64-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-glfw-natives-windows-x86/3.3.3/lwjgl-glfw-natives-windows-x86-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-glfw-natives-windows/3.3.3/lwjgl-glfw-natives-windows-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-glfw/3.3.3/lwjgl-glfw-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-jemalloc-natives-windows-arm64/3.3.3/lwjgl-jemalloc-natives-windows-arm64-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-jemalloc-natives-windows-x86/3.3.3/lwjgl-jemalloc-natives-windows-x86-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-jemalloc-natives-windows/3.3.3/lwjgl-jemalloc-natives-windows-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-jemalloc/3.3.3/lwjgl-jemalloc-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-natives-windows-arm64/3.3.3/lwjgl-natives-windows-arm64-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-natives-windows-x86/3.3.3/lwjgl-natives-windows-x86-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-natives-windows/3.3.3/lwjgl-natives-windows-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-openal-natives-windows-arm64/3.3.3/lwjgl-openal-natives-windows-arm64-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-openal-natives-windows-x86/3.3.3/lwjgl-openal-natives-windows-x86-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-openal-natives-windows/3.3.3/lwjgl-openal-natives-windows-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-openal/3.3.3/lwjgl-openal-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-opengl-natives-windows-arm64/3.3.3/lwjgl-opengl-natives-windows-arm64-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-opengl-natives-windows-x86/3.3.3/lwjgl-opengl-natives-windows-x86-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-opengl-natives-windows/3.3.3/lwjgl-opengl-natives-windows-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-opengl/3.3.3/lwjgl-opengl-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-stb-natives-windows-arm64/3.3.3/lwjgl-stb-natives-windows-arm64-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-stb-natives-windows-x86/3.3.3/lwjgl-stb-natives-windows-x86-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-stb-natives-windows/3.3.3/lwjgl-stb-natives-windows-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-stb/3.3.3/lwjgl-stb-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-tinyfd-natives-windows-arm64/3.3.3/lwjgl-tinyfd-natives-windows-arm64-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-tinyfd-natives-windows-x86/3.3.3/lwjgl-tinyfd-natives-windows-x86-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-tinyfd-natives-windows/3.3.3/lwjgl-tinyfd-natives-windows-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl-tinyfd/3.3.3/lwjgl-tinyfd-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lwjgl/lwjgl/3.3.3/lwjgl-3.3.3.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/com/github/oshi/oshi-core/6.4.10/oshi-core-6.4.10.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/com/google/code/gson/gson/2.10.1/gson-2.10.1.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/com/google/guava/failureaccess/1.0.1/failureaccess-1.0.1.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/com/google/guava/guava/32.1.2-jre/guava-32.1.2-jre.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/com/ibm/icu/icu4j/73.2/icu4j-73.2.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/com/mojang/authlib/6.0.54/authlib-6.0.54.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/com/mojang/blocklist/1.0.10/blocklist-1.0.10.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/com/mojang/brigadier/1.2.9/brigadier-1.2.9.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/com/mojang/datafixerupper/7.0.14/datafixerupper-7.0.14.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/com/mojang/logging/1.2.7/logging-1.2.7.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/com/mojang/patchy/2.2.10/patchy-2.2.10.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/com/mojang/text2speech/1.17.9/text2speech-1.17.9.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/commons-codec/commons-codec/1.16.0/commons-codec-1.16.0.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/commons-io/commons-io/2.15.1/commons-io-2.15.1.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/commons-logging/commons-logging/1.2/commons-logging-1.2.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/io/netty/netty-buffer/4.1.97.Final/netty-buffer-4.1.97.Final.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/io/netty/netty-codec/4.1.97.Final/netty-codec-4.1.97.Final.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/io/netty/netty-common/4.1.97.Final/netty-common-4.1.97.Final.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/io/netty/netty-handler/4.1.97.Final/netty-handler-4.1.97.Final.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/io/netty/netty-resolver/4.1.97.Final/netty-resolver-4.1.97.Final.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/io/netty/netty-transport-classes-epoll/4.1.97.Final/netty-transport-classes-epoll-4.1.97.Final.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/io/netty/netty-transport-native-unix-common/4.1.97.Final/netty-transport-native-unix-common-4.1.97.Final.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/io/netty/netty-transport/4.1.97.Final/netty-transport-4.1.97.Final.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/it/unimi/dsi/fastutil/8.5.12/fastutil-8.5.12.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/net/java/dev/jna/jna-platform/5.14.0/jna-platform-5.14.0.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/net/java/dev/jna/jna/5.14.0/jna-5.14.0.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/net/sf/jopt-simple/jopt-simple/5.0.4/jopt-simple-5.0.4.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/apache/commons/commons-compress/1.26.0/commons-compress-1.26.0.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/apache/commons/commons-lang3/3.14.0/commons-lang3-3.14.0.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/apache/httpcomponents/httpclient/4.5.13/httpclient-4.5.13.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/apache/httpcomponents/httpcore/4.4.16/httpcore-4.4.16.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/apache/logging/log4j/log4j-api/2.22.1/log4j-api-2.22.1.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/apache/logging/log4j/log4j-core/2.22.1/log4j-core-2.22.1.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/apache/logging/log4j/log4j-slf4j2-impl/2.22.1/log4j-slf4j2-impl-2.22.1.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/jcraft/jorbis/0.0.17/jorbis-0.0.17.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/joml/joml/1.10.5/joml-1.10.5.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/lz4/lz4-java/1.8.0/lz4-java-1.8.0.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/slf4j/slf4j-api/2.0.9/slf4j-api-2.0.9.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/net/fabricmc/intermediary/1.20.6/intermediary-1.20.6.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/ow2/asm/asm/9.6/asm-9.6.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/ow2/asm/asm-analysis/9.6/asm-analysis-9.6.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/ow2/asm/asm-commons/9.6/asm-commons-9.6.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/ow2/asm/asm-tree/9.6/asm-tree-9.6.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/org/ow2/asm/asm-util/9.6/asm-util-9.6.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/net/fabricmc/sponge-mixin/0.13.3+mixin.0.8.5/sponge-mixin-0.13.3+mixin.0.8.5.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/net/fabricmc/fabric-loader/0.15.11/fabric-loader-0.15.11.jar
  C:/Users/User/AppData/Roaming/PrismLauncher/libraries/com/mojang/minecraft/1.20.6/minecraft-1.20.6-client.jar

Native libraries:

Mods:
  [✔] fabric-api-0.100.8+1.20.6
  [✔] midnightcontrols-1.9.5+1.20
  [✔] midnightlib-fabric-1.5.5
  [✘] packetfixer-fabric-1.4.1-1.20.5-to-1.20.6.jar (disabled)
  [✘] splitscreen-0.3.0+1.20.6-fabric.jar (disabled)

Params:
  --username  --version 1.20.6 --gameDir C:/Users/User/AppData/Roaming/PrismLauncher/instances/issue MWE/.minecraft --assetsDir C:/Users/User/AppData/Roaming/PrismLauncher/assets --assetIndex 16 --uuid  --accessToken  --userType  --versionType release

Window size: 854 x 480

Launcher: standard

Java Arguments:
[-XX:HeapDumpPath=MojangTricksIntelDriversForPerformance_javaw.exe_minecraft.exe.heapdump, -Xms1024m, -Xmx12288m, -Duser.language=en]

Minecraft process ID: 9312

[12:42:57] [main/INFO]: Loading Minecraft 1.20.6 with Fabric Loader 0.15.11
[12:42:57] [main/INFO]: Loading 57 mods:
    - fabric-api 0.100.8+1.20.6
       |-- fabric-api-base 0.4.40+80f8cf51b0
       |-- fabric-api-lookup-api-v1 1.6.59+e9d2a72bb0
       |-- fabric-biome-api-v1 13.0.25+be5d88beb0
       |-- fabric-block-api-v1 1.0.20+6dfe4c9bb0
       |-- fabric-block-view-api-v2 1.0.8+80f8cf51b0
       |-- fabric-blockrenderlayer-v1 1.1.50+80f8cf51b0
       |-- fabric-client-tags-api-v1 1.1.12+7f945d5bb0
       |-- fabric-command-api-v1 1.2.45+f71b366fb0
       |-- fabric-command-api-v2 2.2.24+80f8cf51b0
       |-- fabric-commands-v0 0.2.62+df3654b3b0
       |-- fabric-content-registries-v0 8.0.6+b82b2392b0
       |-- fabric-convention-tags-v1 2.0.7+7f945d5bb0
       |-- fabric-convention-tags-v2 2.1.3+f4bfb622b0
       |-- fabric-crash-report-info-v1 0.2.27+80f8cf51b0
       |-- fabric-data-attachment-api-v1 1.1.17+2a2c66b6b0
       |-- fabric-data-generation-api-v1 19.2.5+a5d5299db0
       |-- fabric-dimensions-v1 2.1.68+94793913b0
       |-- fabric-entity-events-v1 1.6.8+e9d2a72bb0
       |-- fabric-events-interaction-v0 0.7.6+c5fc38b3b0
       |-- fabric-game-rule-api-v1 1.0.50+80f8cf51b0
       |-- fabric-item-api-v1 8.2.3+6e5bbc4ab0
       |-- fabric-item-group-api-v1 4.1.1+f4bfb622b0
       |-- fabric-key-binding-api-v1 1.0.45+80f8cf51b0
       |-- fabric-keybindings-v0 0.2.43+df3654b3b0
       |-- fabric-lifecycle-events-v1 2.3.4+c5fc38b3b0
       |-- fabric-loot-api-v2 3.0.6+97f703dab0
       |-- fabric-message-api-v1 6.0.11+a7dc0e41b0
       |-- fabric-model-loading-api-v1 1.0.12+80f8cf51b0
       |-- fabric-models-v0 0.4.11+9386d8a7b0
       |-- fabric-networking-api-v1 4.2.0+a916f7c5b0
       |-- fabric-object-builder-api-v1 15.1.5+c5fc38b3b0
       |-- fabric-particles-v1 4.0.0+c5fc38b3b0
       |-- fabric-recipe-api-v1 5.0.6+9c745bbbb0
       |-- fabric-registry-sync-v0 5.0.19+c7d49fa1b0
       |-- fabric-renderer-api-v1 3.3.0+81dac6a1b0
       |-- fabric-renderer-indigo 1.5.15+41791025b0
       |-- fabric-renderer-registries-v1 3.2.62+df3654b3b0
       |-- fabric-rendering-data-attachment-v1 0.3.46+73761d2eb0
       |-- fabric-rendering-fluids-v1 3.1.3+2c869dedb0
       |-- fabric-rendering-v0 1.1.65+df3654b3b0
       |-- fabric-rendering-v1 4.2.5+850ef40bb0
       |-- fabric-resource-conditions-api-v1 4.2.0+a5d5299db0
       |-- fabric-resource-loader-v0 1.1.1+f4bfb622b0
       |-- fabric-screen-api-v1 2.0.21+7b70ea8ab0
       |-- fabric-screen-handler-api-v1 1.3.76+8c7b71c2b0
       |-- fabric-sound-api-v1 1.0.21+c5fc38b3b0
       |-- fabric-transfer-api-v1 5.1.7+7fc4b352b0
       \-- fabric-transitive-access-wideners-v1 6.0.10+74e2f560b0
    - fabricloader 0.15.11
       \-- mixinextras 0.3.5
    - java 21
    - midnightcontrols 1.9.5+1.20
       |-- org_aperlambda_lambdajcommon 1.8.1
       \-- spruceui 5.0.3+1.20.4
    - midnightlib 1.5.5
    - minecraft 1.20.6
[12:42:58] [main/INFO]: SpongePowered MIXIN Subsystem Version=0.8.5 Source=file:/C:/Users/User/AppData/Roaming/PrismLauncher/libraries/net/fabricmc/sponge-mixin/0.13.3+mixin.0.8.5/sponge-mixin-0.13.3+mixin.0.8.5.jar Service=Knot/Fabric Env=CLIENT
[12:42:58] [main/INFO]: Compatibility level set to JAVA_17
[12:42:59] [main/INFO]: Initializing MixinExtras via com.llamalad7.mixinextras.service.MixinExtrasServiceImpl(version=0.3.5).
[12:43:04] [Datafixer Bootstrap/INFO]: 222 Datafixer optimizations took 208 milliseconds
[12:43:06] [Render thread/INFO]: Environment: Environment[sessionHost=https://sessionserver.mojang.com, servicesHost=https://api.minecraftservices.com, name=PROD]
[12:43:06] [Render thread/INFO]: Setting user: ChaoticLawful35
[12:43:06] [Render thread/INFO]: [MidnightControls] Initializing MidnightControls...
[12:43:06] [Render thread/INFO]: [Indigo] Registering Indigo renderer!
[12:43:07] [Render thread/INFO]: Backend library: LWJGL version 3.3.3-snapshot
[12:43:08] [Render thread/INFO]: Reloading ResourceManager: vanilla, fabric, fabric-api, fabric-api-base, fabric-api-lookup-api-v1, fabric-biome-api-v1, fabric-block-api-v1, fabric-block-view-api-v2, fabric-blockrenderlayer-v1, fabric-client-tags-api-v1, fabric-command-api-v1, fabric-command-api-v2, fabric-commands-v0, fabric-content-registries-v0, fabric-convention-tags-v1, fabric-convention-tags-v2, fabric-crash-report-info-v1, fabric-data-attachment-api-v1, fabric-data-generation-api-v1, fabric-dimensions-v1, fabric-entity-events-v1, fabric-events-interaction-v0, fabric-game-rule-api-v1, fabric-item-api-v1, fabric-item-group-api-v1, fabric-key-binding-api-v1, fabric-keybindings-v0, fabric-lifecycle-events-v1, fabric-loot-api-v2, fabric-message-api-v1, fabric-model-loading-api-v1, fabric-models-v0, fabric-networking-api-v1, fabric-object-builder-api-v1, fabric-particles-v1, fabric-recipe-api-v1, fabric-registry-sync-v0, fabric-renderer-api-v1, fabric-renderer-indigo, fabric-renderer-registries-v1, fabric-rendering-data-attachment-v1, fabric-rendering-fluids-v1, fabric-rendering-v0, fabric-rendering-v1, fabric-resource-conditions-api-v1, fabric-resource-loader-v0, fabric-screen-api-v1, fabric-screen-handler-api-v1, fabric-sound-api-v1, fabric-transfer-api-v1, fabric-transitive-access-wideners-v1, fabricloader, midnightcontrols, midnightlib, spruceui
[12:43:08] [Worker-Main-4/INFO]: Found unifont_all_no_pua-15.1.04.hex, loading
[12:43:08] [Render thread/INFO]: [MidnightControls] Configuration loaded.
[12:43:08] [ForkJoinPool.commonPool-worker-1/INFO]: [MidnightControls] Updating controller mappings...
[12:43:08] [Worker-Main-9/INFO]: Found unifont_jp_patch-15.1.04.hex, loading
[12:43:09] [Render thread/WARN]: Missing sound for event: minecraft:item.goat_horn.play
[12:43:09] [Render thread/WARN]: Missing sound for event: minecraft:entity.goat.screaming.horn_break
[12:43:09] [Render thread/INFO]: OpenAL initialized on device OpenAL Soft on Haut-parleurs (Steam Streaming Speakers)
[12:43:09] [Render thread/INFO]: Sound engine started
[12:43:10] [Render thread/INFO]: Created: 1024x512x4 minecraft:textures/atlas/blocks.png-atlas
[12:43:10] [Render thread/INFO]: Created: 256x256x4 minecraft:textures/atlas/signs.png-atlas
[12:43:10] [Render thread/INFO]: Created: 512x512x4 minecraft:textures/atlas/shield_patterns.png-atlas
[12:43:10] [Render thread/INFO]: Created: 512x512x4 minecraft:textures/atlas/banner_patterns.png-atlas
[12:43:10] [Render thread/INFO]: Created: 1024x1024x4 minecraft:textures/atlas/armor_trims.png-atlas
[12:43:10] [Render thread/INFO]: Created: 128x64x4 minecraft:textures/atlas/decorated_pot.png-atlas
[12:43:10] [Render thread/INFO]: Created: 256x256x4 minecraft:textures/atlas/chest.png-atlas
[12:43:10] [Render thread/INFO]: Created: 512x256x4 minecraft:textures/atlas/shulker_boxes.png-atlas
[12:43:10] [Render thread/INFO]: Created: 512x256x4 minecraft:textures/atlas/beds.png-atlas
[12:43:10] [Render thread/INFO]: Created: 512x256x0 minecraft:textures/atlas/particles.png-atlas
[12:43:10] [Render thread/INFO]: Created: 256x256x0 minecraft:textures/atlas/paintings.png-atlas
[12:43:10] [Render thread/INFO]: Created: 256x128x0 minecraft:textures/atlas/mob_effects.png-atlas
[12:43:10] [Render thread/INFO]: Created: 64x64x0 minecraft:textures/atlas/map_decorations.png-atlas
[12:43:10] [Render thread/INFO]: Created: 1024x512x0 minecraft:textures/atlas/gui.png-atlas
[12:43:10] [Render thread/WARN]: Shader rendertype_entity_translucent_emissive could not find sampler named Sampler2 in the specified shader program.
[12:43:17] [Render thread/ERROR]: Unreported exception thrown!
java.lang.IllegalStateException: Cannot get payload sender when not in game!
    at net.fabricmc.fabric.api.client.networking.v1.ClientPlayNetworking.getSender(ClientPlayNetworking.java:230) ~[fabric-networking-api-v1-4.2.0+a916f7c5b0-621fd0e549dd4a66.jar:?]
    at eu.midnightdust.midnightcontrols.client.MidnightControlsClient.switchControlsMode(MidnightControlsClient.java:260) ~[midnightcontrols-1.9.5+1.20.jar:?]
    at eu.midnightdust.midnightcontrols.client.MidnightControlsClient.lambda$onMcInit$5(MidnightControlsClient.java:172) ~[midnightcontrols-1.9.5+1.20.jar:?]
    at org.lwjgl.glfw.GLFWJoystickCallbackI.callback(GLFWJoystickCallbackI.java:43) ~[lwjgl-glfw-3.3.3.jar:?]
    at org.lwjgl.system.JNI.invokeV(Native Method) ~[lwjgl-3.3.3.jar:?]
    at org.lwjgl.glfw.GLFW.glfwWaitEventsTimeout(GLFW.java:3509) ~[lwjgl-glfw-3.3.3.jar:?]
    at com.mojang.blaze3d.systems.RenderSystem.limitDisplayFPS(RenderSystem.java:236) ~[client-intermediary.jar:?]
    at net.minecraft.class_310.method_1523(class_310.java:1345) ~[client-intermediary.jar:?]
    at net.minecraft.class_310.method_1514(class_310.java:888) [client-intermediary.jar:?]
    at net.minecraft.client.main.Main.main(Main.java:265) [client-intermediary.jar:?]
    at net.fabricmc.loader.impl.game.minecraft.MinecraftGameProvider.launch(MinecraftGameProvider.java:470) [fabric-loader-0.15.11.jar:?]
    at net.fabricmc.loader.impl.launch.knot.Knot.launch(Knot.java:74) [fabric-loader-0.15.11.jar:?]
    at net.fabricmc.loader.impl.launch.knot.KnotClient.main(KnotClient.java:23) [fabric-loader-0.15.11.jar:?]
    at org.prismlauncher.launcher.impl.StandardLauncher.launch(StandardLauncher.java:100) [NewLaunch.jar:?]
    at org.prismlauncher.EntryPoint.listen(EntryPoint.java:129) [NewLaunch.jar:?]
    at org.prismlauncher.EntryPoint.main(EntryPoint.java:70) [NewLaunch.jar:?]
---- Minecraft Crash Report ----
// I let you down. Sorry :(

Time: 2024-08-07 12:43:17
Description: Unexpected error

java.lang.IllegalStateException: Cannot get payload sender when not in game!
    at net.fabricmc.fabric.api.client.networking.v1.ClientPlayNetworking.getSender(ClientPlayNetworking.java:230)
    at eu.midnightdust.midnightcontrols.client.MidnightControlsClient.switchControlsMode(MidnightControlsClient.java:260)
    at eu.midnightdust.midnightcontrols.client.MidnightControlsClient.lambda$onMcInit$5(MidnightControlsClient.java:172)
    at org.lwjgl.glfw.GLFWJoystickCallbackI.callback(GLFWJoystickCallbackI.java:43)
    at org.lwjgl.system.JNI.invokeV(Native Method)
    at org.lwjgl.glfw.GLFW.glfwWaitEventsTimeout(GLFW.java:3509)
    at com.mojang.blaze3d.systems.RenderSystem.limitDisplayFPS(RenderSystem.java:236)
    at net.minecraft.class_310.method_1523(class_310.java:1345)
    at net.minecraft.class_310.method_1514(class_310.java:888)
    at net.minecraft.client.main.Main.main(Main.java:265)
    at net.fabricmc.loader.impl.game.minecraft.MinecraftGameProvider.launch(MinecraftGameProvider.java:470)
    at net.fabricmc.loader.impl.launch.knot.Knot.launch(Knot.java:74)
    at net.fabricmc.loader.impl.launch.knot.KnotClient.main(KnotClient.java:23)
    at org.prismlauncher.launcher.impl.StandardLauncher.launch(StandardLauncher.java:100)
    at org.prismlauncher.EntryPoint.listen(EntryPoint.java:129)
    at org.prismlauncher.EntryPoint.main(EntryPoint.java:70)

A detailed walkthrough of the error, its code path and all known details is as follows:
---------------------------------------------------------------------------------------

-- Head --
Thread: Render thread
Stacktrace:
    at net.fabricmc.fabric.api.client.networking.v1.ClientPlayNetworking.getSender(ClientPlayNetworking.java:230)
    at eu.midnightdust.midnightcontrols.client.MidnightControlsClient.switchControlsMode(MidnightControlsClient.java:260)
    at eu.midnightdust.midnightcontrols.client.MidnightControlsClient.lambda$onMcInit$5(MidnightControlsClient.java:172)
    at org.lwjgl.glfw.GLFWJoystickCallbackI.callback(GLFWJoystickCallbackI.java:43)
    at org.lwjgl.system.JNI.invokeV(Native Method)
    at org.lwjgl.glfw.GLFW.glfwWaitEventsTimeout(GLFW.java:3509)

-- Uptime --
Details:
    JVM uptime: 20.908s
    Wall uptime: 11.388s
    High-res time: 10.409s
    Client ticks: 175 ticks / 8.750s
Stacktrace:
    at net.minecraft.class_310.method_1587(class_310.java:2548)
    at net.minecraft.class_310.method_54580(class_310.java:983)
    at net.minecraft.class_310.method_1514(class_310.java:911)
    at net.minecraft.client.main.Main.main(Main.java:265)
    at net.fabricmc.loader.impl.game.minecraft.MinecraftGameProvider.launch(MinecraftGameProvider.java:470)
    at net.fabricmc.loader.impl.launch.knot.Knot.launch(Knot.java:74)
    at net.fabricmc.loader.impl.launch.knot.KnotClient.main(KnotClient.java:23)
    at org.prismlauncher.launcher.impl.StandardLauncher.launch(StandardLauncher.java:100)
    at org.prismlauncher.EntryPoint.listen(EntryPoint.java:129)
    at org.prismlauncher.EntryPoint.main(EntryPoint.java:70)

-- Last reload --
Details:
    Reload number: 1
    Reload reason: initial
    Finished: Yes
    Packs: vanilla, fabric, fabric-api, fabric-api-base, fabric-api-lookup-api-v1, fabric-biome-api-v1, fabric-block-api-v1, fabric-block-view-api-v2, fabric-blockrenderlayer-v1, fabric-client-tags-api-v1, fabric-command-api-v1, fabric-command-api-v2, fabric-commands-v0, fabric-content-registries-v0, fabric-convention-tags-v1, fabric-convention-tags-v2, fabric-crash-report-info-v1, fabric-data-attachment-api-v1, fabric-data-generation-api-v1, fabric-dimensions-v1, fabric-entity-events-v1, fabric-events-interaction-v0, fabric-game-rule-api-v1, fabric-item-api-v1, fabric-item-group-api-v1, fabric-key-binding-api-v1, fabric-keybindings-v0, fabric-lifecycle-events-v1, fabric-loot-api-v2, fabric-message-api-v1, fabric-model-loading-api-v1, fabric-models-v0, fabric-networking-api-v1, fabric-object-builder-api-v1, fabric-particles-v1, fabric-recipe-api-v1, fabric-registry-sync-v0, fabric-renderer-api-v1, fabric-renderer-indigo, fabric-renderer-registries-v1, fabric-rendering-data-attachment-v1, fabric-rendering-fluids-v1, fabric-rendering-v0, fabric-rendering-v1, fabric-resource-conditions-api-v1, fabric-resource-loader-v0, fabric-screen-api-v1, fabric-screen-handler-api-v1, fabric-sound-api-v1, fabric-transfer-api-v1, fabric-transitive-access-wideners-v1, fabricloader, midnightcontrols, midnightlib, spruceui

-- System Details --
Details:
    Minecraft Version: 1.20.6
    Minecraft Version ID: 1.20.6
    Operating System: Windows 10 (amd64) version 10.0
    Java Version: 21.0.3, Oracle Corporation
    Java VM Version: Java HotSpot(TM) 64-Bit Server VM (mixed mode, sharing), Oracle Corporation
    Memory: 332201616 bytes (316 MiB) / 1073741824 bytes (1024 MiB) up to 12884901888 bytes (12288 MiB)
    CPUs: 12
    Processor Vendor: GenuineIntel
    Processor Name: Intel(R) Core(TM) i7-8700 CPU @ 3.20GHz
    Identifier: Intel64 Family 6 Model 158 Stepping 10
    Microarchitecture: Coffee Lake
    Frequency (GHz): 3.19
    Number of physical packages: 1
    Number of physical CPUs: 6
    Number of logical CPUs: 12
    Graphics card #0 name: Radeon (TM) RX 480 Graphics
    Graphics card #0 vendor: Advanced Micro Devices, Inc.
    Graphics card #0 VRAM (MB): 8192.00
    Graphics card #0 deviceId: VideoController1
    Graphics card #0 versionInfo: 31.0.14037.17019
    Memory slot #0 capacity (MB): 16384.00
    Memory slot #0 clockSpeed (GHz): 2.13
    Memory slot #0 type: DDR4
    Memory slot #1 capacity (MB): 8192.00
    Memory slot #1 clockSpeed (GHz): 2.13
    Memory slot #1 type: DDR4
    Memory slot #2 capacity (MB): 16384.00
    Memory slot #2 clockSpeed (GHz): 2.13
    Memory slot #2 type: DDR4
    Memory slot #3 capacity (MB): 8192.00
    Memory slot #3 clockSpeed (GHz): 2.13
    Memory slot #3 type: DDR4
    Virtual memory max (MB): 56274.59
    Virtual memory used (MB): 11743.92
    Swap memory total (MB): 7168.00
    Swap memory used (MB): 0.00
    JVM Flags: 3 total; -XX:HeapDumpPath=MojangTricksIntelDriversForPerformance_javaw.exe_minecraft.exe.heapdump -Xms1024m -Xmx12288m
    Fabric Mods: 
        fabric-api: Fabric API 0.100.8+1.20.6
            fabric-api-base: Fabric API Base 0.4.40+80f8cf51b0
            fabric-api-lookup-api-v1: Fabric API Lookup API (v1) 1.6.59+e9d2a72bb0
            fabric-biome-api-v1: Fabric Biome API (v1) 13.0.25+be5d88beb0
            fabric-block-api-v1: Fabric Block API (v1) 1.0.20+6dfe4c9bb0
            fabric-block-view-api-v2: Fabric BlockView API (v2) 1.0.8+80f8cf51b0
            fabric-blockrenderlayer-v1: Fabric BlockRenderLayer Registration (v1) 1.1.50+80f8cf51b0
            fabric-client-tags-api-v1: Fabric Client Tags 1.1.12+7f945d5bb0
            fabric-command-api-v1: Fabric Command API (v1) 1.2.45+f71b366fb0
            fabric-command-api-v2: Fabric Command API (v2) 2.2.24+80f8cf51b0
            fabric-commands-v0: Fabric Commands (v0) 0.2.62+df3654b3b0
            fabric-content-registries-v0: Fabric Content Registries (v0) 8.0.6+b82b2392b0
            fabric-convention-tags-v1: Fabric Convention Tags 2.0.7+7f945d5bb0
            fabric-convention-tags-v2: Fabric Convention Tags (v2) 2.1.3+f4bfb622b0
            fabric-crash-report-info-v1: Fabric Crash Report Info (v1) 0.2.27+80f8cf51b0
            fabric-data-attachment-api-v1: Fabric Data Attachment API (v1) 1.1.17+2a2c66b6b0
            fabric-data-generation-api-v1: Fabric Data Generation API (v1) 19.2.5+a5d5299db0
            fabric-dimensions-v1: Fabric Dimensions API (v1) 2.1.68+94793913b0
            fabric-entity-events-v1: Fabric Entity Events (v1) 1.6.8+e9d2a72bb0
            fabric-events-interaction-v0: Fabric Events Interaction (v0) 0.7.6+c5fc38b3b0
            fabric-game-rule-api-v1: Fabric Game Rule API (v1) 1.0.50+80f8cf51b0
            fabric-item-api-v1: Fabric Item API (v1) 8.2.3+6e5bbc4ab0
            fabric-item-group-api-v1: Fabric Item Group API (v1) 4.1.1+f4bfb622b0
            fabric-key-binding-api-v1: Fabric Key Binding API (v1) 1.0.45+80f8cf51b0
            fabric-keybindings-v0: Fabric Key Bindings (v0) 0.2.43+df3654b3b0
            fabric-lifecycle-events-v1: Fabric Lifecycle Events (v1) 2.3.4+c5fc38b3b0
            fabric-loot-api-v2: Fabric Loot API (v2) 3.0.6+97f703dab0
            fabric-message-api-v1: Fabric Message API (v1) 6.0.11+a7dc0e41b0
            fabric-model-loading-api-v1: Fabric Model Loading API (v1) 1.0.12+80f8cf51b0
            fabric-models-v0: Fabric Models (v0) 0.4.11+9386d8a7b0
            fabric-networking-api-v1: Fabric Networking API (v1) 4.2.0+a916f7c5b0
            fabric-object-builder-api-v1: Fabric Object Builder API (v1) 15.1.5+c5fc38b3b0
            fabric-particles-v1: Fabric Particles (v1) 4.0.0+c5fc38b3b0
            fabric-recipe-api-v1: Fabric Recipe API (v1) 5.0.6+9c745bbbb0
            fabric-registry-sync-v0: Fabric Registry Sync (v0) 5.0.19+c7d49fa1b0
            fabric-renderer-api-v1: Fabric Renderer API (v1) 3.3.0+81dac6a1b0
            fabric-renderer-indigo: Fabric Renderer - Indigo 1.5.15+41791025b0
            fabric-renderer-registries-v1: Fabric Renderer Registries (v1) 3.2.62+df3654b3b0
            fabric-rendering-data-attachment-v1: Fabric Rendering Data Attachment (v1) 0.3.46+73761d2eb0
            fabric-rendering-fluids-v1: Fabric Rendering Fluids (v1) 3.1.3+2c869dedb0
            fabric-rendering-v0: Fabric Rendering (v0) 1.1.65+df3654b3b0
            fabric-rendering-v1: Fabric Rendering (v1) 4.2.5+850ef40bb0
            fabric-resource-conditions-api-v1: Fabric Resource Conditions API (v1) 4.2.0+a5d5299db0
            fabric-resource-loader-v0: Fabric Resource Loader (v0) 1.1.1+f4bfb622b0
            fabric-screen-api-v1: Fabric Screen API (v1) 2.0.21+7b70ea8ab0
            fabric-screen-handler-api-v1: Fabric Screen Handler API (v1) 1.3.76+8c7b71c2b0
            fabric-sound-api-v1: Fabric Sound API (v1) 1.0.21+c5fc38b3b0
            fabric-transfer-api-v1: Fabric Transfer API (v1) 5.1.7+7fc4b352b0
            fabric-transitive-access-wideners-v1: Fabric Transitive Access Wideners (v1) 6.0.10+74e2f560b0
        fabricloader: Fabric Loader 0.15.11
            mixinextras: MixinExtras 0.3.5
        java: Java HotSpot(TM) 64-Bit Server VM 21
        midnightcontrols: MidnightControls 1.9.5+1.20
            org_aperlambda_lambdajcommon: lambdajcommon 1.8.1
            spruceui: SpruceUI 5.0.3+1.20.4
        midnightlib: MidnightLib 1.5.5
        minecraft: Minecraft 1.20.6
    Launched Version: 1.20.6
    Launcher name: PrismLauncher
    Backend library: LWJGL version 3.3.3-snapshot
    Backend API: Radeon (TM) RX 480 Graphics GL version 3.2.0 Core Profile Context 22.20.27.09.230424, ATI Technologies Inc.
    Window size: 1920x1080
    GL Caps: Using framebuffer using OpenGL 3.2
    GL debug messages: 
    Using VBOs: Yes
    Is Modded: Definitely; Client brand changed to 'fabric'
    Universe: 400921fb54442d18
    Type: Client (map_client.txt)
    Graphics mode: fancy
    Render Distance: 12/12 chunks
    Resource Packs: vanilla, fabric, fabric-api, fabric-api-base, fabric-api-lookup-api-v1, fabric-biome-api-v1, fabric-block-api-v1, fabric-block-view-api-v2, fabric-blockrenderlayer-v1, fabric-client-tags-api-v1, fabric-command-api-v1, fabric-command-api-v2, fabric-commands-v0, fabric-content-registries-v0, fabric-convention-tags-v1, fabric-convention-tags-v2, fabric-crash-report-info-v1, fabric-data-attachment-api-v1, fabric-data-generation-api-v1, fabric-dimensions-v1, fabric-entity-events-v1, fabric-events-interaction-v0, fabric-game-rule-api-v1, fabric-item-api-v1, fabric-item-group-api-v1, fabric-key-binding-api-v1, fabric-keybindings-v0, fabric-lifecycle-events-v1, fabric-loot-api-v2, fabric-message-api-v1, fabric-model-loading-api-v1, fabric-models-v0, fabric-networking-api-v1, fabric-object-builder-api-v1, fabric-particles-v1, fabric-recipe-api-v1, fabric-registry-sync-v0, fabric-renderer-api-v1, fabric-renderer-indigo, fabric-renderer-registries-v1, fabric-rendering-data-attachment-v1, fabric-rendering-fluids-v1, fabric-rendering-v0, fabric-rendering-v1, fabric-resource-conditions-api-v1, fabric-resource-loader-v0, fabric-screen-api-v1, fabric-screen-handler-api-v1, fabric-sound-api-v1, fabric-transfer-api-v1, fabric-transitive-access-wideners-v1, fabricloader, midnightcontrols, midnightlib, spruceui
    Current Language: fr_fr
    Locale: en_GB
    CPU: 12x Intel(R) Core(TM) i7-8700 CPU @ 3.20GHz
#@!@# Game crashed! Crash report saved to: #@!@# C:\Users\User\AppData\Roaming\PrismLauncher\instances\issue MWE\.minecraft\crash-reports\crash-2024-08-07_12.43.17-client.txt
Process exited with code -1.

Desktop (please complete the following information):

Additional context Crash reproduced on a different Android device but with the same controller. Crash doesn't happen when launching locally (everything works fine then). Found a reference to this exception only in this online crash dump.

Eusebius commented 2 months ago

I do not reproduce the issue with Midnight 1.9.4 and MC 1.20.4. Works for me...

Motschen commented 2 months ago

This is fixed in the latest preview version, along with a lot of other improvements: https://github.com/TeamMidnightDust/MidnightControls/releases/tag/v1.10.0-alpha.1