11-26-2019, 04:39 AM
Not sure if this is the right forum, but I would like to post this somewhere.
The past month or so I have been working on a game engine for retro 2D games, in order to easily create this new game I have been working on, which uses Tilengine.
I have to say, the experience is extremely fun, and this is a great way to learn C++ even with the lack of documentation for Tilengine (which upped the challenge, but it taught me a lot more than if there was more documentation).
I don't really have much beyond a demo that scrolls through a scene and plays music, but it took a lot to get there, and I basically made my own system from scratch for handling objects, layers, cameras, etc.
The best part of this project is that it uses LUA for a scripting system so you can create the game without having to compile the engine ever again, and it makes it extremely easy for anyone to make their own retro 2D game, because it abstracts everything to a level where you don't have to worry about anything besides making the game.
This engine though, is really rough around the edges, there is still a lot to implement and clean up, and things I need to work on to make it usable, which is why I wont be releasing any of the builds for it yet, but I would love to eventually do that and even possibly make it open source similar to Tilengine, but that is still a long ways off.
Here is a picture of the game so far (all pixel art created by me and a friend):
Here is the LUA code it took to make that happen (not using Tilengine LUA bindings):
I already have this running on a Raspberry Pi, and I plan on adding other features like integration with some sprite editors, as well as integration with a LUA IDE.
One problem I had, since I am using SDL2 for windowing and sound, was getting the CRT effect to work. I made a post earlier which megamarc kindly replied to about how to get it working, but I had to copy a lot of code from Tilengine's source files and it ended up being very clunky and unstable (which is my fault, I'm not the most experienced with SDL2), and it would have been way easier if it were a standalone module of some sort. Other than that I recommend Tilengine 100% if you can get over the learning curve!
Thanks for checking this out!
The past month or so I have been working on a game engine for retro 2D games, in order to easily create this new game I have been working on, which uses Tilengine.
I have to say, the experience is extremely fun, and this is a great way to learn C++ even with the lack of documentation for Tilengine (which upped the challenge, but it taught me a lot more than if there was more documentation).
I don't really have much beyond a demo that scrolls through a scene and plays music, but it took a lot to get there, and I basically made my own system from scratch for handling objects, layers, cameras, etc.
The best part of this project is that it uses LUA for a scripting system so you can create the game without having to compile the engine ever again, and it makes it extremely easy for anyone to make their own retro 2D game, because it abstracts everything to a level where you don't have to worry about anything besides making the game.
This engine though, is really rough around the edges, there is still a lot to implement and clean up, and things I need to work on to make it usable, which is why I wont be releasing any of the builds for it yet, but I would love to eventually do that and even possibly make it open source similar to Tilengine, but that is still a long ways off.
Here is a picture of the game so far (all pixel art created by me and a friend):
Here is the LUA code it took to make that happen (not using Tilengine LUA bindings):
Code:
function startup ()
-- Play theme song (looped by default)
playMusic("theme", "game_theme.ogg")
-- Add image as background layer on X: 0 Y: 0 that is immovable
addImage("logo", "menu_logo.png", 0, 0, "immovable")
-- Add image on background layer on X: 0 Y: 0 Distance: 0 (Moves with foreground)
addImage("ground", "menu_ground.png", 0, 0, 0)
-- Add image on background layer on X: 0 Y: 0 Distance: 8 (Moves slowly with background)
addImage("water", "menu_water.png", 0, 0, 8)
addImage("sand", "menu_sand.png", 0, 0, 10)
addImage("grass", "menu_grass.png", 0, 0, 12)
addImage("mountains", "menu_mountains.png", 0, 0, 14)
addImage("mountainsBG", "menu_mountainsbg.png", 0, 0, 16)
addImage("moonBG", "menu_moon.png", 0, 0, "immovable")
addImage("starsBG", "menu_starsbg.png", 0, 0, 500)
addImage("spaceBG", "menu_spacebg.png", 0, 0, 1000)
end
function update ()
moveCameraLeft(20)
end
I already have this running on a Raspberry Pi, and I plan on adding other features like integration with some sprite editors, as well as integration with a LUA IDE.
One problem I had, since I am using SDL2 for windowing and sound, was getting the CRT effect to work. I made a post earlier which megamarc kindly replied to about how to get it working, but I had to copy a lot of code from Tilengine's source files and it ended up being very clunky and unstable (which is my fault, I'm not the most experienced with SDL2), and it would have been way easier if it were a standalone module of some sort. Other than that I recommend Tilengine 100% if you can get over the learning curve!
Thanks for checking this out!