opekope2 / OptiGUI

Blazing fast custom GUI textures on Fabric and Quilt with built-in OptiFine custom GUI resource pack support
https://opekope2.dev/OptiGUI/
MIT License
23 stars 9 forks source link

[CRASH] Kotlin update crashes OptiGUI #80

Closed Madis0 closed 1 year ago

Madis0 commented 1 year ago

Loader and its version

Fabric Loader 0.14.24

OptiGUI version

2.1.6

Steps to reproduce

  1. Have OptiGUI
  2. Update Fabric Language Kotlin to 1.10.11

Game logs

https://mclo.gs/xgogMt1

Anything else

The instance is Fabulously Optimized 5.5.0-beta.3, but the presence of other mods is currently irrelevant here. Works on Fabric Language Kotlin 1.10.10.

scarlettekk commented 1 year ago

Issue also occurs with Fabric Language Kotlin 1.10.11

opekope2 commented 1 year ago

For some reason, OptiGUI is loaded with the default language adapter before FLK 1.10.11, and it works, but on 1.10.11, it is loaded with the Kotlin adapter, which has a bug; top level function references don't work. After looking at the git blame, it never worked. I don't know what got changed that now the Kotlin adapter gets loaded instead of the default one. I'll open an issue in the Kotlin adapter repo about this.

Loading with FLK 1.9.0:

image

Loading with FLK 1.10.11:

image

Update: this rabbit hole goes deeper than I thought. Caused by a Kotlin Reflection change.

MeeniMc commented 1 year ago

Workaround: roll back to Fabric Kotlin 1.10.10.

modmuss50 commented 1 year ago

This is now fixed in Fabric Kotlin 1.10.12.