Skip to content

Latest commit

 

History

History
42 lines (26 loc) · 1.98 KB

File metadata and controls

42 lines (26 loc) · 1.98 KB

Dominion Examples

Dominion comes with some documented sample apps to help adopt the solution.

Hello Dominion

The HelloDominion app, already presented in the home, is the example app to break the ice.

Here you find the documented source.

With Dominion already built in your local folder, you can run this example with the following commands:

java -jar dominion-ecs-examples/target/dominion-ecs-examples-0.9.0-SNAPSHOT.jar

Dark Entities

Here things start to get more interesting.

DarkEntities is a simple example app that could inspire a turn-based rogue-like game running on a terminal window.

Shows how to create a basic dominion of entities, components, and systems by creating and moving a camera with a light to illuminate and explore a random dungeon map. Implements a wise lighting system able to fork subsystems and distribute on worker threads to take advantage of multiple cores.

dark-entities

The main class implementation is straightforward and provides a comment on almost every line. It can be read from top to bottom.

With Dominion already built in your local folder, you can run this example with the following commands:

java -cp dominion-ecs-examples/target/dominion-ecs-examples-0.9.0-SNAPSHOT.jar dev.dominion.ecs.examples.dark.DarkEntities

Support Dominion

If you want to support Dominion project, consider giving it a Star ⭐️