All Projects → libktx → Ktx

libktx / Ktx

Licence: cc0-1.0
LibKTX: Kotlin extensions for LibGDX games and applications

Programming Languages

kotlin
9241 projects

Projects that are alternatives of or similar to Ktx

Korge
KorGE Game Engine. Multiplatform Kotlin Game Engine
Stars: ✭ 780 (-14.57%)
Mutual labels:  coroutines, kotlin-coroutines, game-engine
Terasology
Terasology - open source voxel world
Stars: ✭ 3,247 (+255.64%)
Mutual labels:  hacktoberfest, game-development, game-engine
Pixieditor
PixiEditor is a lightweight pixel art editor made with .NET 5
Stars: ✭ 210 (-77%)
Mutual labels:  hacktoberfest, game-development, graphics
Gosu
2D game development library for Ruby and C++
Stars: ✭ 1,762 (+92.99%)
Mutual labels:  hacktoberfest, game-development, game-engine
Vortice.windows
.NET standard bindings for DirectX, WIC, Direct2D1, XInput, XAudio and X3DAudio
Stars: ✭ 427 (-53.23%)
Mutual labels:  game-development, game-engine, graphics
Debroglie
DeBroglie is a C# library implementing the Wave Function Collapse algorithm with support for additional non-local constraints, and other useful features.
Stars: ✭ 190 (-79.19%)
Mutual labels:  hacktoberfest, game-development, graphics
Excalibur
🎮 An easy to use 2D HTML5 game engine written in TypeScript
Stars: ✭ 892 (-2.3%)
Mutual labels:  hacktoberfest, game-development, game-engine
Monogame
One framework for creating powerful cross-platform games.
Stars: ✭ 8,014 (+777.77%)
Mutual labels:  hacktoberfest, game-engine, graphics
Cpp 3d Game Tutorial Series
C++ 3D Game Tutorial Series is a YouTube tutorial series, whose purpose is to help all those who want to take their first steps in the game development from scratch.
Stars: ✭ 400 (-56.19%)
Mutual labels:  game-development, game-engine, graphics
Obengine
2D Game Engine with Lua Scripting made on top of SFML !
Stars: ✭ 335 (-63.31%)
Mutual labels:  hacktoberfest, game-development, game-engine
Gamedev4noobs
Olá, sejam bem-vindos ao repositório _gamedev4noobs_ do Estúdio Vaca Roxa. O propósito desse repositório, além de contribuir para o projeto 4noobs, é ensinar o básico do desenvolvimento de jogos para iniciantes. Apresentando boas práticas e insumos para criar games incríveis.
Stars: ✭ 122 (-86.64%)
Mutual labels:  hacktoberfest, game-development, game-engine
Handmade Math
A simple math library for games and computer graphics. Compatible with both C and C++.
Stars: ✭ 517 (-43.37%)
Mutual labels:  game-development, game-engine, graphics
Defold
Defold is a completely free to use game engine for development of desktop, mobile and web games.
Stars: ✭ 1,938 (+112.27%)
Mutual labels:  hacktoberfest, game-development, game-engine
Kotlin Coroutines Retrofit
Kotlin Coroutines await() extension for Retrofit Call
Stars: ✭ 812 (-11.06%)
Mutual labels:  async, coroutines, kotlin-coroutines
Evennia
Python MUD/MUX/MUSH/MU* development system
Stars: ✭ 1,309 (+43.37%)
Mutual labels:  hacktoberfest, game-development, game-engine
Destinationsol
Official continuation of Destination Sol, the great fun little arcade space shooter from http://sourceforge.net/projects/destinationsol/ Modules live at https://github.com/DestinationSol/
Stars: ✭ 214 (-76.56%)
Mutual labels:  hacktoberfest, game-development, libgdx
Sucle
Common Lisp Voxel Game Engine
Stars: ✭ 239 (-73.82%)
Mutual labels:  game-development, game-engine, graphics
Unityfx.async
Asynchronous operations (promises) for Unity3d.
Stars: ✭ 143 (-84.34%)
Mutual labels:  async, coroutines, game-development
Limonengine
3D FPS game engine with full dynamic lighting and shadows
Stars: ✭ 331 (-63.75%)
Mutual labels:  hacktoberfest, game-development, game-engine
Fheroes2
Free implementation of Heroes of Might and Magic II game engine
Stars: ✭ 471 (-48.41%)
Mutual labels:  hacktoberfest, game-development, game-engine

GitHub Build Kotlin LibGDX Maven Central

KTX

Kotlin extensions for LibGDX.

Introduction

KTX is a Kotlin game framework built on LibGDX. It aims to make LibGDX as Kotlin-friendly as possible without completely rewriting the API. It provides modular utilities and extensions for selected parts of LibGDX with poor native Kotlin support.

Examples of Kotlin language features used to improve usability, performance and readability of LibGDX include:

  • Operator overloads for collections and mathematical operations.
  • Extension methods with sensible default parameters.
  • Inline methods with reduced runtime overhead for various listeners, builders and loggers.
  • Nullable types which improve typing information of selected interfaces and functions.
  • Default interface methods for common interfaces, simplifying their implementations.
  • Type-safe builders for GUI, styling and physics engine.
  • Coroutines context providing concurrency utilities and non-blocking asset loading.
  • Reified types that simplify usage of methods normally consuming Class parameters.

See the Choosing KTX article for pros and cons of this framework.

Modules

KTX was designed to be modular from day one - in fact, some of these libraries are just a single Kotlin file. You can include selected KTX modules based on the needs of your application.

Module Dependency name Description
actors ktx-actors Scene2D GUI extensions for stages, actors, actions and event listeners.
app ktx-app ApplicationListener implementations and general application utilities.
ashley ktx-ashley Ashley entity-component-system utilities.
assets ktx-assets Resources management utilities.
assets-async ktx-assets-async Non-blocking asset loading using coroutines.
async ktx-async Coroutines context based on LibGDX threading model.
box2d ktx-box2d Box2D physics engine utilities.
collections ktx-collections Extensions for LibGDX custom collections.
freetype ktx-freetype FreeType fonts loading utilities.
freetype-async ktx-freetype-async Non-blocking FreeType fonts loading using coroutines.
graphics ktx-graphics Utilities related to rendering tools and graphics.
i18n ktx-i18n Internationalization API utilities.
inject ktx-inject A dependency injection system with low overhead and no reflection usage.
json ktx-json Utilities for LibGDX JSON serialization API.
log ktx-log Minimal runtime overhead cross-platform logging using inlined functions.
math ktx-math Operator functions for LibGDX math API and general math utilities.
preferences ktx-preferences Improved API for accessing and saving preferences.
scene2d ktx-scene2d Type-safe Kotlin builders for Scene2D GUI.
style ktx-style Type-safe Kotlin builders for Scene2D widget styles extending Skin API.
tiled ktx-tiled Utilities for Tiled maps.
vis ktx-vis Type-safe Kotlin builders for VisUI.
vis-style ktx-vis-style Type-safe Kotlin builders for VisUI widget styles.

Installation

KTX modules are uploaded to Maven Central and are fully compatible with the Gradle build tool, which is used in LibGDX projects by default.

All libraries follow the same naming schema:

compile "io.github.libktx:$module:$ktxVersion"

Replace $module with the name of the selected KTX library (see table above).

For example, including the app module with the ktx-app identifier would require the following changes in your build.gradle file:

ext {
  // Update this version to match the latest KTX release:
  ktxVersion = '1.9.14-b1'
}

dependencies {
  compile "io.github.libktx:ktx-app:$ktxVersion"
}

You can find the latest KTX version on Maven Central:

  • Maven Central

As a side note, defining ktxVersion as a property in ext is not necessary, as versions can be set directly in the dependencies section. However, extracting the dependencies versions is a good practice, especially if they can be reused throughout the build files. This will speed up updating of your project if you include multiple KTX modules.

KTX modules should generally be added to the dependencies of the shared core module of your LibGDX application.

Versioning

KTX versions match the LibGDX versions that they were compiled against. $ktxVersion will usually match your LibGDX version, but it might end with -b postfix if it is a beta release or -SNAPSHOT if you are using the development branch.

For example, the first official beta release with the current group ID io.github.libktx was compiled against LibGDX 1.9.6 and since it was the second beta release, its version was 1.9.6-b2. The corresponding snapshot release of this version was 1.9.6-SNAPSHOT.

You can browse through our official releases on Maven and on GitHub.

Unfortunately, LibGDX does not follow the semantic versioning guidelines. Both minor and patch versions can introduce breaking changes. Please read the LibGDX and KTX change logs before updating.

Although KTX is still in late beta, the official beta releases are stable enough for production use. All modules are thoroughly tested with unit tests.

Latest changes

The master branch is the default branch of the repository. However, it represents the last stable release of KTX. The latest changes can be found on the develop branch.

You do not have to compile the sources manually to use the latest features. The preview snapshot releases are uploaded to the https://oss.sonatype.org/content/repositories/snapshots/ repository. To use them in your application, add the following Maven repository and modify the prefix of ktxVersion to -SNAPSHOT:

repositories {
  // Include your default repositories here.
  maven { url 'https://oss.sonatype.org/content/repositories/snapshots/' }
}

ext {
  // Update this version to match the latest LibGDX release:
  ktxVersion = '1.9.14-SNAPSHOT'
}

The latest snapshot version name can be found on the develop branch.

Even the snapshots should be more or less stable, as the libraries are not pushed to Maven Central unless they pass their extensive test suites.

Documentation

Official guides

Each module contains a README.md file with a list of all features or a guide with some code snippets. Browse through the directories in the root folder to find out more about each library.

Source documentation

All public classes and functions are also documented with standard Kotlin KDocs. You can access the documentation by:

  • Viewing the generated Dokka files hosted on the the project website.
  • Reading the sources directly.
  • Using the doc archive in GitHub releases with generated Dokka files.

Links

KTX wiki lists some useful resources that can help you get started.

Note that most official guides and examples in this repository assume that the reader is at least a bit familiar with the LibGDX API. If you are just getting to know the framework, it might be helpful to go through the official LibGDX wiki.

android-ktx

Note that android-ktx is a separate project with official Android utilities. The "KTX" name was chosen long before the Android project was announced.

Contribution

Suggestions, questions, typo fixes, documentation improvements and code contributions are always welcome. If you would like to contribute, please read the contribution guideline and browse through the active issues. Don't hesitate to create issues just to ask a question or make a request for any kind of improvement.

The develop is the active development branch. When creating pull requests, make sure to choose develop as the target branch.

You can check the list of the contributors via GitHub insights and on the contributors list.

Licensing

This project is dedicated to public domain.

Working from sources

See this section of the contribution guideline to get started.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].