An open API service indexing awesome lists of open source software.

https://github.com/daanvanyperen/libgdx-artemis-quickstart

Quickstart template for libgdx artemis projects!
https://github.com/daanvanyperen/libgdx-artemis-quickstart

artemis-odb artemis-odb-contrib gamedev java libgdx quickstart template

Last synced: about 2 months ago
JSON representation

Quickstart template for libgdx artemis projects!

Awesome Lists containing this project

README

        

libgdx-artemis-quickstart
=========================

[![Build Status](https://travis-ci.org/DaanVanYperen/libgdx-artemis-quickstart.svg)](https://travis-ci.org/DaanVanYperen/libgdx-artemis-quickstart)

Quickstart for libgdx artemis-odb based games.

Preconfigured for artemis-odb advanced features. Contains
minimal game scaffold.s

### When to use this

If you want artemis-odb with weaving, (optionally) fluid entities and
LibGDX's gradle, a fork will get you up and running quickly.

I use this as my quickstart for jam games. You are welcome
to use it for whatever you need.

### Where to start

Edit `net.mostlyoriginal.game.screen.GameScreen` and start editing!

### Platform cheat sheet

| Platform | [odb weaving](https://github.com/junkdog/artemis-odb/wiki/Bytecode-weaving) | [entity factory](https://github.com/junkdog/artemis-odb/wiki/EntityFactory) | quickstart
|-----------------|----------|----------------|--------------------
| Desktop | ✓ | ✓ | `gradlew desktop:run`
| Android | ✓ | ✓ | `gradlew android:installDebug android:run`, launch emulator first.
| iOS | ✓ | ✓ | `gradlew ios:launchIPhoneSimulator`
| HTML5/GWT | - | ✓ | `gradlew html:superDev`, browse to `http://localhost:8080/index.html`

✓ supported, - not supported

### Library Versions

LibGDX 1.9.9, artemis-odb 2.2.0, artemis-odb-contrib 2.4.0

Alter library versions and enable gdx modules in /build.gradle

### Weaving

Weaving and fluid interface creation are part of the core build step.

Gradle plugin requires Gradle 4.6+!
### Generating component/system matrix

`gradlew generateMatrix`

### GWT build speed

GWT default build speed is horribly slow (10-20 minutes).

Because of this, `enableClosureCompiler` is disabled by default. Re-enable
it in `html/build.gradle` to shrink your game a bit at the cost of 300%
compile time.

To speed up your builds further you can chose to limit the target browsers
by adding a tag to `GdxDefinition.gwt.xml`.
``

### GWT and Reflection

GWT lacks reflection so the build process creates a reflection cache.

To use `@Wire` make sure your components, managers and systems are
placed under the premade component, manager and system packages.

There are TWO reflection caches, one for LibGDX, one for Artemis-ODB.
Artemis reflection cache errors are prefixed with `artemis-odb`.

```