Skip to content

Releases: libgdx/gdx-liftoff

1.12.1.8 "Unicorn Warfare"

18 Apr 05:45
Compare
Choose a tag to compare

This release is small, but includes some tricky fixes for problems people faced recently.

The first is the larger fix: Android apps that use a default icon (any default icon, if it's reused between different developers' apps) can be suspended on Google Play Store for plagiarism, just by having the same icon as another app. It's arguably a good approach for Google, since they understandably don't want a finished product looking like a clone of another on their store. It's a problem for developers who are in an early stage of app development, though, and want to upload an alpha-quality build for feedback. To avoid at least most cases where an app could be duplicated, Liftoff now uses the project name and its root package to generate random colors and choose icons randomly, emitting Frankenstein-esque icons into your Android module. The colors are... rather bright. You will want to change the icon before submitting to anywhere public, which is part of the point. If you don't, it won't overlap, though, so there is an extra layer of safety.

The second fix is validation; as per #149 , using a main class name that was already used by libGDX could sometimes cause cyclic dependency issues. Now, all class names in libGDX (except for inner classes, which I don't think are involved) are considered invalid main class names for your code. Not only does this catch a possible compilation problem before it happens, this helps avoid confusion for people who try to help (i.e. if your class Game is not the Game class defined by libGDX, or you have a Stage class that is unrelated to the scene2d Stage).

There are some other small changes, like TeaVM versions now using stable releases, and the GdxWebSocket GWT dependency getting fixed. I hope this works well for you!

(Also, the JAR file is slightly larger because there are 1991 icon files present in the resources. Each one is very small, and the JAR format compresses them fairly well, but the size adds up! Only by about 2MB, but still...)

1.12.1.7 "The Amazing Shrinking Project Generator"

29 Mar 05:09
Compare
Choose a tag to compare

This release has a pretty wide variety of changes, most of them requested by users, so if something wasn't to your liking before, you can try this version! Changes include:

  • You can generate some more predefined samples purely from the command line now. gradlew sample --args="android_dev" will produce a sample that already has Box2D, Box2D-Lights, GDX-Freetype, ShapeDrawer, TenPatch, and Stripe added to it, without needing a GUI at all. There's also "gwt_dev" and "tea_dev".
  • There's a notification that replaces the Liftoff logo if your version is out-of-date. This will only do anything when the next version is released, since only 1.12.1.7 is currently able to respond to a more recent version being available.
  • The font is skinnier, which lets more of the description text be visible in third-party extensions.
  • More libraries! Gdx-UnBox2D, Apache Fury, Apache Commons Collections, gand, crux, cringe, tantrum... Also, SquidSquad should work out-of-the-box again, and InGameConsole (by StrongJoshua, initially) now works on GWT.
  • ProGuard config has improved.
  • iOS requirements are handled for upcoming changes in the App Store rules.
  • Annotation processors should work on GWT now.
  • Gradle has been updated to 8.7 .
  • Toolchains have been removed because a simpler way seems to work better.
  • MOE has been removed temporarily... We are waiting on a fix from the Gradle team that apparently is blocking MOE from working in Gradle's current version.
  • Lastly, the JAR is smaller! It turns out we didn't need to include audio libraries with gdx-liftoff, because it doesn't play any sounds or music.

I hope this release works for you!

1.12.1.6 "Double Jump"

08 Feb 06:48
Compare
Choose a tag to compare

This release has two big updates. Gradle has been updated to 8.6, which seems to be generally very compatible with the previously-used 8.5, so there isn't much to be concerned about there. There aren't many new features in 8.6, but there seem to be some good bug fixes.

However, GWT has been updated to 2.11.0, which does several things differently. Naturally, Liftoff tries to make the update as smooth as possible, so the main pain point (some libraries depend on an older GWT version, sometimes by depending on an older libGDX GWT backend version, and the old GWT version doesn't get replaced by the GWT 2.11.0 dependency) is addressed for dependencies you select from the official or third-party extensions list. The list of affected extensions, if you are updating from an earlier project, is a little large: Box2D, GWT-Controllers, Artemis-ODB, GDX-Facebook, GDX-ControllerUtils, Guacamole, and Basis Universal, at the least. You can see the Troubleshooting.md entry about updating to 1.12.1.6 if you encounter trouble.

The reason you'd want to use GWT 2.11.0 is mostly that it supports a lot more of the Java 11 standard library, not just language features. As long as the previously mentioned pain point isn't a problem, and you are only depending on the latest GWT, there don't seem to be many other issues.

OK, that's about it, other than a lot of dependency default updates and some security-related updates to Liftoff dependencies. Enjoy!

1.12.1.5 "Chain-chain-chain"

09 Jan 12:41
Compare
Choose a tag to compare

This release fixes toolchains where they were broken before (in Kotlin projects), and expands their use to Java projects as well. Toolchain support means Gradle will download a JDK (usually from Eclipse Adoptium, which was called AdoptOpenJDK) of the correct version if you don't already have one installed with that version, and will use that JDK for everything in the build. They may become optional soon if people encounter issues with toolchains at their core, but they should really help coordinate multiple-user or multiple-machine projects. Other things:

  • The "legacy desktop" platform is now called lwjgl2, to match the style of lwjgl3. I don't know how often it gets used, though.
  • The dist task works again, and is equivalent to jar for LWJGL3 and other desktop-based projects. Thanks again, @lyze237 !
  • Fleks ECS is updated to 2.6, thanks @Quillraven !
  • Kotlin has been updated to 1.9.22, and some effort has been put into making the launchers act better. It turns out they may just need to be launched once, fail once, and will work normally after that...?
  • A security warning with a dependency, mvnrepository-client, was resolved in the same way a previous security warning with that dependency was: with a fixed custom fork that gets built on JitPack.
  • There are some additions to the Troubleshooting document, also.

OK, get out there and start lifting off!

1.12.1.4 "Christmas Native-Tea Scene"

15 Dec 04:53
Compare
Choose a tag to compare

This release includes some significant fixes for Graal Native Image support, which was broken in 1.12.1.3 (by some comments in JSON, of all things, as well as some other issues). It also updates the GDX TeaVM backend to 1.0.0-b8 and provides the option to separately update TeaVM itself to a higher version than what the backend defaults to. There are also a few other important changes. Debugging LWJGL3 apps in IDEA on a Mac is possible again; thanks to Discord user fdreger for figuring out the solution. You can set IDEA to run your project using the IDE rather than Gradle, which can help in various situations; thanks to Discord user Ma for the helpful configuration used. The Gradle Plugin Portal was missing from the buildscript section, which may have caused problems when a plugin wasn't also in Maven Central. The generated assets.txt file is now ignored from Git repos by default; thanks @lyze237 for this one. Overall, not really any new features, just lots of bugs squashed.

1.12.1.3 "Drunken Master Mode"

05 Dec 05:26
Compare
Choose a tag to compare

Java 21! Finally, you can run Gradle using JDK 21, the current LTS version, using a project generated by gdx-liftoff! The actual language features and APIs of Java 21 won't be available unless you target desktop only, but the main thing is that you can download the latest Java and run the latest Liftoff without mysterious build errors! This is made possible by Gradle 8.5, released a few days ago. There are also some small but important changes for Android projects, in particular the update to SDK 34 for new projects (because the Google Play Store requires or will require a recent target SDK version to submit an app). The frequently-mentioned solution for listing internal files, written up by @lyze237 here, is now included by default as a task run on compilation in Lifttoff projects, with some small updates for recent Gradle changes. An assets.txt file was already generated for GWT projects, but for some reason not for any others.

Other features here are mostly related to the improving Graal Native Image support. All resources in the assets/ folder now get gathered into a monstrous regular expression behind-the-scenes, and that is used to let Graal Native Image access all the filenames in your assets, but not much more as a resource. This keeps file sizes down, since it doesn't let in any (well, not many) files from outside your project that are part of Graal. Common file names might be picked up as duplicates, but either Graal or Gradle seems to not be able to tell that forward slashes are valid in paths on all major OSes, and insists on using backslashes in some places. That means that only the file names can be used, and not their paths, which is unfortunate.

OK, good luck and have fun!

1.12.1.2 "Graaltered States"

20 Nov 09:06
Compare
Choose a tag to compare

This release only changes about 3 lines of generated projects, but it fixes a strange and frustrating bug. In projects generated with 1.12.1.1, when Graal is enabled, you can only successfully run an LWJGL3 project once until you make some change in the source code. Later runs would just complete immediately and say the run task was "up-to-date." I don't know what caused this, but it seems like some Gradle plugin, somewhere in nativeimage.gradle . Thankfully, 1.12.1.2 (this release) has an easy fix. It makes the run task never be considered "up-to-date," so when you tell it to run, it runs! This didn't ever affect projects that had Graal disabled, and it didn't seem to affect other platforms. It is unclear if run configurations were affected at all. If you want to update a 1.12.1.1 project in-place, it isn't hard at all; in lwjgl3/nativeimage.gradle, change the first few lines from the old:

project(":lwjgl3") {
  apply plugin: "org.graalvm.buildtools.native"

to the new:

project(":lwjgl3") {
  apply plugin: "org.graalvm.buildtools.native"
  run {
    doNotTrackState("Running the app should not be affected by Graal.")
  }

OK, I hope this quick bugfix is helpful!

1.12.1.1 "Graaling On Hands And Knees"

20 Nov 06:54
Compare
Choose a tag to compare

This release allows Graal Native Image generation in LWJGL3 projects, largely thanks to @Berstanio for making a library for Graal support and PRing changes here. If you have a supported extension selected (one of box2d, bullet, controllers, or freetype), then the Graal Native Image support library will also be added as a dependency. Graal support is disabled by default, so you don't need to download any Graal tools if you don't want them. If you want to enable Graal support, set enableGraalNative=true in gradle.properties (changing it from false), then reload/sync/refresh the project. To run the lwjgl3:nativeCompile task that creates a native executable, there are some extra steps. On Windows, you need a recent Visual Studio (Community, probably) installed, and you might need to run Gradle commands through Visual Studio's "x64 Native Tools Command Prompt" rather than the normal command prompt. On all systems, you will need a good amount of free RAM; 4GB of available memory seems to be enough to build small-to-medium apps. The end result of all of this is a medium-sized .exe file (on Windows) or some other native executable (on other platforms); this .exe doesn't need any JVM installed to run, and also compresses down to a tiny size if you zip it for releases. Decompiling a Graal native image is also significantly harder than a JAR or APK, though far from impossible.

This release also has some improvements to TeaVM, thanks to @HydrolienF ; now you can use up to at least version 17 with TeaVM, though the minimum is still 11. There are some other extension updates, too. Enjoy your adventures through the land of Graal!

1.12.1.0 "Good To Be Back"

03 Nov 09:17
Compare
Choose a tag to compare

A new libGDX release, 1.12.1 ! So, a new gdx-liftoff release, 1.12.1.0 ! There aren't many new features here on the Liftoff side, but there are some fixes. TeaVM got some good attention from @Drareeg , which should mean the build works out of the box on TeaVM. Fleks, the Kotlin ECS, is now available as a third-party extension (just like Artemis-ODB and much like Ashley, which is "official"). Several dependencies had their default versons updated, sometimes by a lot. @metaphore has been working on gdx-basis-universal, and sent a helpful PR to update the version for that here. The gdx-backends project was updated, so we're using the latest version of the GWT backend. Other than that, we're using libGDX 1.12.1 before anyone else, hooray! Just remember that there may be some things that haven't been fully tested, in libGDX or gdx-liftoff, so please send in issue reports if you encounter any bugs in Liftoff. Thanks!

1.12.0.5 "Upgrades and Apples"

18 Oct 06:18
Compare
Choose a tag to compare

This release updates to Gradle 8.4, which gets us nearly nothing other than some security fixes, but those are important too. Likely more important is the fix in StartupHelper when running Liftoff or generated LWJGL3 projects on macOS. A snippet of code recently added to crykn/Guacamole, which is the original source of StartupHelper, was meant to help run on GraalVM Native Image, but the check was flipped incorrectly (both here and in Guacamole). That made Macs essentially unable to start Liftoff or apps that used StartupHelper since about Liftoff 1.12.0.2 .

If you are concerned that you might have a problematic StartupHelper in your project (which may have never been tested on a Mac), just make sure the section that mentions Graal in it looks like this (the correct way for Java):

        // There is no need for -XstartOnFirstThread on Graal native image
        if (!System.getProperty("org.graalvm.nativeimage.imagecode", "").isEmpty()) {
            return false;
        }

The important part is the ! at the start of the if statement, which was missing before. In Kotlin, StartupHelper uses isNotEmpty() instead of isEmpty(), so it doesn't use ! at the start. Here's a correct way for Kotlin:

            // There is no need for -XstartOnFirstThread on Graal native image
            if (System.getProperty("org.graalvm.nativeimage.imagecode", "").isNotEmpty()) {
                return false
            }

New projects will use the corrected StartupHelper class, much like Liftoff itself does.

The GWT Plugin and RoboVM versions were also updated, to 1.1.29 and 2.3.20, respectively.

As always, I hope this release has fewer bugs than the last one!