Mage City was my first foray into the Elm world and aimed to recreate the aesthetic and some gameplay elements of 90's Nintendo RPG action games like Secret of Mana. This project is no longer maintained and I keep it only for historical purposes.
If you are into Elm game development I've written Sunny Land which, I believe, is a much better introduction to the topic.
Clone the repo and run:
elm-package install
Elm will ask for confirmation and download all the necessary packages. Then run:
elm-reactor
and point your browser to http://localhost:8000/index.html
.
The following features have been implemented:
- Terrain rendering on the GPU, with support with multiple layers
- Basic WebGL shaders for most common use-cases like static textured quads and animated quads
- Obstacle detection, currently used to block player on map bounds
- Keyboard input
- Player walk movements
- Game assets loading (textures only)
- Game entities (initially just collectable items and triggers)
- Text rendering
- Player inventory
- Dialog system
- Non-playing characters (NPC)
- Enemies and simple AI
- Weapons and player melee attack
- Mouse input
- Pathfinding
- Background music and sound effects
Levels in Mage City have been designed using the open-source Tiled level editor and converted in Elm data structures using the elmify
command line utility.
- Mage City and Forest tile sets by Daniel "Hyptosis" Harris
- Player sprites by Penelope Williams
- NPC sprites by Anthony Angelo Alvarez
Mage City contains portions of:
- Florian Zinggeler's Game.TwoD and Game.Resources
- Nicolas Fernandez's Collision2D