Skip to content

Releases: libktx/ktx

KTX 1.12.1-rc2

25 Aug 07:29
Compare
Choose a tag to compare

Maintenance release with some minor improvements and dependency updates. The last planned release to officially support Kotlin 1.


  • [UPDATE] Updated to Kotlin 1.9.25.
  • [UPDATE] Updated to Kotlin Coroutines 1.8.1.
  • [UPDATE] Updated to Gradle 7.6.4.
  • [UPDATE] Updated to Dokka 1.9.20.
  • [MISC] JDK 11 or newer is now required to build the KTX project.
  • [CHANGE] (ktx-assets) The pool factory method now attempts to reset Poolable objects with the default discard lambda to match the default libGDX pool behavior. Pass a custom function to override it.
  • [FEATURE] (ktx-math) Added component deconstructing operators for 2D shapes:
    • Rectangle: x, y, width, height
    • Ellipse: x, y, width, height
    • Circle: x, y, radius
    • Polygon: x, y
    • Polyline: x, y
  • [CHANGE] (ktx-scene2d) image factory method can now be called without parameters or with null to create an Image without a Drawable.
  • [FEATURE] (ktx-tiled) Added use extension method to BatchTiledMapRenderer that automatically calls beginRender() and endRender().

KTX 1.12.1-rc1

04 Nov 11:58
Compare
Choose a tag to compare

The first release to support libGDX 1.12.1.


  • [UPDATE] Updated to libGDX 1.12.1.
  • [UPDATE] Updated to Kotlin 1.9.20.
  • [UPDATE] Updated to Kotlin Coroutines 1.7.3.
  • [UPDATE] Updated to VisUI 1.5.3.
  • [UPDATE] Updated to Dokka 1.9.10.
  • [FEATURE] (ktx-math) New extension and factory functions were introduced to Vector4, offering similar utilities to the other vectors.
    • vec4 factory methods allow creating new Vector4 instances with default and named parameters.
    • +=, -=, *=, /= mutating operators are now supported.
    • +, - (including unary -), ++, --, *, / operators are now supported, returning new instances of vectors as a result.
    • Vectors are now comparable by length, adding support for <, >, <=, >= operators.
    • Vector4 instances can now be deconstructed into 4 four values (X, Y, Z, W) using extension component methods.
    • dot infix function allows calculating the dot product of 2 vectors.

Known issues:

  • (ktx-assets) Pools created via the pool factory method do not reset the discarded objects by default, which is inconsistent with the libGDX pool behavior. To replicate this, pass a discard lambda parameter calling reset on the discarded objects that implement the Poolable interface.

KTX 1.12.0-rc1

23 Jul 22:22
Compare
Choose a tag to compare

The first release to officially support libGDX 1.12.0 and Kotlin 1.9.0.


  • [UPDATE] Updated to libGDX 1.12.0.
  • [UPDATE] Updated to Kotlin 1.9.0.
  • [UPDATE] Updated to Kotlin Coroutines 1.7.2.
  • [UPDATE] Updated to VisUI 1.5.2.
  • [UPDATE] Updated to Dokka 1.8.20.
  • [MISC] KTX project should now work locally under JDK 17, including the test suite.
  • [FEATURE] (ktx-app) KtxInputAdapter now supports the touchCancelled event handling. By default, it calls the touchUp method for consistency with the previous libGDX versions.

KTX 1.11.0-rc6

04 Jun 08:37
Compare
Choose a tag to compare

The first KTX release to support the gdxAI library with a new module: ktx-ai. Includes notable updates to core dependencies.


  • [UPDATE] Updated to Kotlin 1.8.21.
  • [UPDATE] Updated to Kotlin Coroutines 1.7.1.
  • [UPDATE] Updated to Gradle 7.6.1.
  • [UPDATE] Updated to Dokka 1.8.10.
  • [FEATURE] (ktx-ai) new KTX module with utilities and type-safe builders for gdxAI.
    • Type aliases to avoid name clashes with common libraries:
      • GdxAiSequence<E> for com.badlogic.gdx.ai.btree.branch.Sequence<E>
      • GdxAiSelector<E> for com.badlogic.gdx.ai.btree.branch.Selector<E>
      • GdxAiRandom<E> for com.badlogic.gdx.ai.btree.decorator.Random<E>
    • Extension functions for building behavior trees:
      • add
      • behaviorTree
      • dynamicGuardSelector
      • parallel
      • randomSelector
      • randomSequence
      • selector
      • sequence
      • alwaysFail
      • alwaysSucceed
      • include
      • invert
      • random
      • repeat
      • semaphoreGuard
      • untilFail
      • untilSuccess
      • failureLeaf
      • successLeaf
      • waitLeaf

KTX 1.11.0-rc5

24 Feb 13:00
Compare
Choose a tag to compare

A maintenance release with a bug fix in ktx-assets-async for older Android devices.


  • [UPDATE] Updated to Kotlin 1.8.10.
  • [FIX] (ktx-assets-async) AssetStorage no longer uses ConcurrentHashMap.getOrDefault method unsupported on older Android devices.

KTX 1.11.0-rc4

26 Jan 13:17
Compare
Choose a tag to compare

A maintenance release with support for Kotlin 1.8.0 and notable documentation improvements.


  • [UPDATE] Updated to Kotlin 1.8.0.
  • [UPDATE] Updated to VisUI 1.5.1.
  • [MISC] Project README now includes installation instructions for new projects using gdx-liftoff.
  • [MISC] Sample KTX projects are now generated by gdx-liftoff on every release.
  • [MISC] Removed migration guides from ktx-scene2d and ktx-vis README files. If you are migrating from an old KTX version, please refer to the 1.11.0-rc3 tag.
  • [FEATURE] (ktx-assets-async) AssetStorage.silenceAssetManagerWarnings property was added, allowing to silence logging on non-fatal AssetLoader issues.
  • [FEATURE] (ktx-assets-async) AssetManagerWrapper warnings caused by AssetLoader issues were extended and improved.

Known issues:

  • [BUG] (ktx-assets-async) AssetStorage might work incorrectly on older Android devices due to access to unsupported Java APIs (ConcurrentHashMap.getOrDefault).

KTX 1.11.0-rc3

02 Dec 09:22
Compare
Choose a tag to compare

The first stable release to support a new KTX module: ktx-artemis.


  • [UPDATE] Updated to Kotlin 1.7.22.
  • [UPDATE] Updated to Dokka 1.7.20.
  • [FEATURE] (ktx-ashley) Added tagFor<Component> utility functions that automatically create a mapper for a flag component. These properties can be used to check for Component presence within the Entity, as well as automatically add and remove Component instances upon property modification.
  • [FEATURE] (ktx-artemis) new KTX module with Artemis-odb entity component system utilities: ktx-artemis.
    • ArchetypeBuilder.add and ArchetypeBuilder.remove extension methods for adding and removing components from an ArchetypeBuilder.
    • oneOf, allOf, exclude DSL and extension methods for Aspect.Builder.
    • EntityEdit.plusAssign operator function for adding components.
    • EntityEdit.with builder function for adding components to an entity.
    • EntityEdit.remove extension function for removing components from an entity.
    • EntityTransmuterFactory.add and EntityTransmuterFactory.remove extension functions for adding and removing components from an EntityTransmuterFactory.
    • ComponentMapper.contains operator function to check if an entity has a component.
    • World.edit extension builder function to edit an entity.
    • World.entity extension builder function to create and edit an entity.
    • World.get operator function for retrieving a system which returns null if it doesn't exist.
    • World.getSystem extension function for retrieving a system which throws an exception if it doesn't exist.
    • World.mapperFor extension function for retrieving a ComponentMapper instance.
  • [FEATURE] (ktx-assets-async) AssetStorage now stores a basic path-to-type map, which allows it to support more AssetManager methods called by some AssetLoader implementations. These include:
    • AssetManager.contains(String)
    • AssetManager.get(String)
    • AssetManager.get(String, Boolean)
    • AssetManager.get(String, Class, Boolean)
    • AssetManager.getAssetType(String)
    • AssetManager.isLoaded(String)
    • AssetManager.unload(String)
    • AssetManager.getDependencies(String)
    • AssetManager.getReferenceCount(String)

Known issues:

  • [BUG] (ktx-assets-async) AssetStorage might work incorrectly on older Android devices due to access to unsupported Java APIs (ConcurrentHashMap.getOrDefault).

KTX 1.11.0-rc2

28 Jul 21:30
Compare
Choose a tag to compare

Maintenance release with support for Kotlin 1.7 and Dokka 1.7, as well as several new utilities.


  • [UPDATE] Updated to Kotlin 1.7.10.
  • [UPDATE] Updated to Kotlin Coroutines 1.6.4.
  • [UPDATE] Updated to Dokka 1.7.10.
  • [MISC] New Dokka theme is available on the documentation website.
  • [FEATURE] (ktx-actors) Added Actor.onEnter, Actor.onExit, Actor.onEnterEvent and Actor.onExitEvent extension methods that attach ClickListener instances listening for enter and exit events.
  • [FEATURE] (ktx-ashley) Added ComponentDelegate and OptionalComponentDelegate that allow accessing component via Entity extension properties.
  • [FEATURE] (ktx-ashley) Added propertyFor<Component> and optionalPropertyFor<Component> utility functions that automatically create a mapper for the component delegates.

KTX 1.11.0-rc1

22 May 07:45
Compare
Choose a tag to compare

The first stable release to support libGDX 1.11.0.


  • [UPDATE] Updated to libGDX 1.11.0.
  • [MISC] Gradle dependencies changed from compile-only to API scope.
  • [FEATURE] (ktx-app) Added gdxError utility that throws a GdxRuntimeException.
  • [FIX] (ktx-assets-async) Fixed a niche bug with AsyncAssetManager which could lead to missed custom user callbacks after attempting to load the same asset concurrently with loadAsync.

KTX 1.10.0-rc2

24 Apr 14:14
Compare
Choose a tag to compare

A maintenance release with notable changes to the ktx-ashley and ktx-script modules.


  • [UPDATE] Updated to Kotlin 1.6.21.
  • [UPDATE] Updated to Kotlin Coroutines 1.6.1.
  • [FEATURE] (ktx-ashley) Added utilities for working with Ashley's EntityListener interface:
    • EntityAdditionListener: an interface extending EntityListener that only requires implementation of the entityAdded method.
    • EntityRemovalListener: an interface extending EntityListener that only requires implementation of the entityRemoved method.
    • Engine.onEntityAdded and Engine.onEntityRemoved extension methods that create entity listeners from lambdas.
    • Wrappers for Engine.onEntityAdded and Engine.onEntityRemoved for IteratingSystem, IntervalIteratingSystem
      and SortedIteratingSystem that use system's Family and Engine automatically.
  • [FEATURE] (ktx-script) Added KotlinScriptEngine.evaluateOn methods that can execute scripts with a custom receiver.
  • [CHANGE] (ktx-script) Generic libGDX and Java exceptions replaced with a custom ScriptEngineException.