Overview
- Download repository zip of our template.
- Update your project's Gradle script & configs with those from the templates. If you can't figure Gradle out, ask AI.
- Update your template class path (check blossom readme).
- Check following notable changes compare with Forge.
Things that may need to be fixed
- Don't try to add URL to AppClassLoader by casting it, just call
Launch.classLoader.addURL(); - Many
javaxclasses are now moved tojakarta. If you can't find an old class, try to write it another way first before contact us. - Calling
new ScriptEngineManager(null)may crash the game, please call it withLaunch.classLoader - Java 8 consider some invalid UUIDs as valid, just regenerate them.
sun.reflect.Reflectionwas gone, useThread.currentThread().getStackTrace()to get caller.- ASM visitors should use
Opcodes.ASM9now. - Setting or getting a final field with reflection is impossible now, use AT or
ReflectionHackery. - We forked an improved Mixin, check template for how to use it. Old ways still works though.
- DO NOT call
org.lwjglxclasses, they are meant to be used in runtime. - Guava changed some methods, you may need to add an extra
Runnable::runas parameter - Don't set your Fastutil set's load factor to 1, or it will crash
Port a 2.11 Scala mods to 3
- Use scala branch of the template.
- Check this page and set your Scala version to latest 2.12.x
- It should compile. Now follow the compiler warnings to add explicit converts.
- Switch to latest 2.13.x, also make sure it compiles.
- Now you can switch to latest 3.x and use rewrite flags to update whole code base. Check this and this for example.
Port Kotlin mods
Just use new Forgelin instead of the old one. Kotlin is more friendly in cross-version source code compatibility.
