Saint Louis Software Banner

2D Game Engine

I made a 2D game engine in Java, using the JavaFX GUI framework for graphics. I wrote it using IntelliJ's IDEA CE IDE. It's approximately 2,000 lines of code right now. It's pretty simple right now, but I am planning on extending its capabilities in the future. It is not on my GitHub profile right now, but I will make it public at some point.

Here is another screenshot of it:

Here are some of the features:

  • Level selection screen
  • Collision detection
  • 2D graphics
  • Tile-based map
  • Directional sprites: the player has both a position and a direction
  • 4-way arrow key movement
  • Event objects you can interact with by pressing space
  • Debug mode
  • Noclip mode
  • Level editor
  • Background tiles, decoration tiles, and event tiles
  • Menu with player info
  • Functions for changing the map
  • Fixed 720p resolution
  • Multi-platform compatibility because it's Java

Planned features to add in the future:

  • Saving and loading as JSON
  • Combat events
  • Map change events (to have a multi-screen game level)
  • Refactoring the existing features to make it more efficient
  • Resizable window
  • Increased variety of objects
  • Adding more features to the player class
  • Audio
  • Function for NPC dialogue
  • Shop system

Sure, there are better game engines already out there that you can download and use to make with less effort. But that's not the point. This is a learning exercise. But in some cases, it does make sense to simply implement something that has already been made instead of reinventing the wheel. For example, JavaScript frameworks or web server software. Sometimes, software development feels less like making something from scratch, and more just gluing things together.

Check out my game engine on GitHub here.