#
What is FastJ?FastJ is an open-source, Java-based 2D game engine and framework. Originally named the FastJ Engine, it aims to provide an easy-to-use, 2D game-making library.
#
DisclaimerThis project is still under heavy development. There is a very good chance bugs are still prevalent and untracked, as the engine is not fully covered by unit tests. Documentation is readily available, but may change over time. Feel free to help us out by contributing to the project!
#
Projected Feature ListFeature | Description | Support |
---|---|---|
2D Rendering | Rendering of 2D Polygons, Models, Lighting | โ |
Scene System | Scene-based Rendering, Scene Switching | โ |
Scriptable Behaviors | Control GameObject state | โ |
Desktop Support | Full Compatibility on Windows, Linux, and macOS | โ |
Audio Engine | Loading, Playing, and Controlling .wav, .au, .aiff files | โ |
Image Support | Image rendering, Sprite Animation | โ |
Animation Support | Interpolation, Tweening Framework | โญ |
UI System | Flexible UI System to replace Swing UI | โญ |
Particle Engine | Configurable and Customizable Particle Management | โญ |
Physics Engine | Custom 2D Physics Engine. | โ |
Asset Manager | Load, Unload, and Hot Reload Game Assets | โญ |
FastJ Model Creator | Create & Export 2D Models | โญ |
FastJ Editor | View, Run, Build, and Export FastJ programs from an editor | โ |
Web Support | Run FastJ Programs in a Web Browser | โ |
โ is complete and satisfactory.
โ is implemented and usable, but is missing certain features.
โญ is in progress.
โ is not yet implemented.
#
Get StartedThere are many different ways to learn FastJ -- check them out!
#
Template ProjectsUse a template project! It's the fastest way to jump into using FastJ.
Choose a programming language from the ones below. We suggest Java, as it has the most support:
However, Kotlin and Groovy are reasonable options as well:
- Kotlin: https://github.com/fastjengine/fastj-kotlin-template
- Groovy: https://github.com/fastjengine/fastj-groovy-template
#
TutorialsFastJ provides article tutorials on its website to accommodate as many types of developers as possible. From beginners to experts, the website tutorials are written to give enough information to satisfy anyone willing to learn!
#
Code ExamplesExplore FastJ's code examples to see the different ways FastJ can be used, and all of its features. These come with in-example explanations and easy plug-and-playability to give you the best chance at understanding how FastJ works.
#
API DocumentationCheck out FastJ's documentation to get a better understanding of the code FastJ provides to improve your game-making experience.
#
I'll add the dependency myself!Ok, ok, I hear ya. Just follow through with these instructions below.
#
Dependency ManagementThis library can be found in the following places:
- jitpack.io, as a dependency.
- Maven Central, as a dependency or as a jarfile.
- The Releases section of this repository.
When adding the dependency, make sure to replace [latest version here]
with the actual version (you'll find this in the jitpack.io or Maven Central link up above). The current latest version is 1.6.0.
A few common dependencies are provided below:
Gradle Build Script
Groovy:
repositories.maven { url('https://jitpack.io')} dependencies.implementation('com.github.fastjengine:FastJ:[latest version here]')
Kotlin:
repositories.maven { setUrl("https://jitpack.io")} dependencies.implementation("com.github.fastjengine:FastJ:[latest version here]")
Maven POM
<repository> <id>jitpack.io</id> <url>https://jitpack.io</url></repository> <dependency> <groupId>com.github.fastjengine</groupId> <artifactId>FastJ</artifactId> <version>[latest version here]</version></dependency>
You'll also want to make sure you add a dependency for a logging framework from SLF4J, since FastJ uses it for all its logging purposes. Take your pick!
#
Hello World Code (Java)import tech.fastj.engine.FastJEngine;import tech.fastj.graphics.display.FastJCanvas;import tech.fastj.systems.control.SimpleManager;
public class HelloFastJ extends SimpleManager {
@Override public void init(FastJCanvas canvas) {}
@Override public void update(FastJCanvas canvas) {}
public static void main(String[] args) { // Creates an empty window titled "Hello, FastJ!" FastJEngine.init("Hello, FastJ!", new Main()); FastJEngine.run(); }}
#
External Dependencies#
ContributingPlan on contributing to the repository? Awesome! We're glad to have you โค๏ธ
Please be sure to read over the contribution guidelines so that you can get started.
#
CommunityFastJ's community of developers is growing day by day!
- Join the FastJ Discord Server to get early-access to planned ideas and features, as well as join a welcoming community!
#
LicenseThis repository is licensed under the MIT License.