Development Log for Magic Pixel, a game maker using Love2d

Showcase your libraries, tools and other projects that help your fellow love users.
Post Reply
pauljessup
Party member
Posts: 355
Joined: Wed Jul 03, 2013 4:06 am

Development Log for Magic Pixel, a game maker using Love2d

Post by pauljessup »

Something I'm thinking about, and running it here in case anyone has any ideas/improvements/crits/etc, since this is still in the super meta planning stage. I was messing around with GB Studio, esp the latest version that extends a lot of what it does and adds a more robust event system. Now, in my last few games and engines I've been coding I've been moving more towards a scene based structure, even before messing around with GB Studio. It just felt like a natural, simple way to help me build games.

And I was thinking, after messing around with GB Studio, you could probably easily create a front end that is a scene stack and an object stack (objects being anything really that interactable in game). Each scene then has it's own object stack that pulls from the global object stack, basically you create global objects, and then instantiate them in scenes. Could also have a variable stack for global and scene specific variables, etc for ease of loading/saving game states and editing/accessing them from the IDE itself.

Then, each object, scene, etc has a lua file that run at certain points using hooks. For example, each object can have an update function, draw function, etc. Each scene would also have an update function, draw function, etc. There could be modules that could be attached that would simplify sprite animation, so if the walk_sprite module is loaded and attached to the main player object, they don't have to actually edit the draw routine (unless it does something funky).

The same could be done with adding a Tiled module and attaching it to a scene, and it would then used TIled maps for the background art. I've seen a lot of visual editors created these days with Electron (GB Studio, Yarn, etc) so it might be a good idea to go that route (esp since I do development for web apps at my dayjob).

Of course, there would need to be an engine built that could parse the output of this. Could easily be done with something like Love, I think, with the meta game content stored in JSON files and then loaded into the love environment. This could allow this to be very abstract, and in the future allow for importing of the meta code into other game engines that support it, etc.

Just an idea I'm tooling around with. At this point I want to keep it very meta, and make it as extensible as possible, which needs to be done on the ground floor. After all, the minute any coding gets done the game starts edging away from extensibility and edging towards a more rigid vision...

Anyway, any thoughts, improvements, possible future issues that you think I'm ignoring?
Last edited by pauljessup on Wed Dec 01, 2021 2:50 am, edited 1 time in total.
User avatar
milon
Party member
Posts: 472
Joined: Thu Jan 18, 2018 9:14 pm

Re: Some thoughts on a GB Studio style development environment for Love and Lua...

Post by milon »

Sounds like a cool idea! To clarify (and correct me if I'm wrong), you're talking about creating a scene-based platform that simplifies game creation. The engine that reads the JSON source files would be written in Lua/Love, and therefore can run on any system with Love installed. What would the output be? Another .love file, an HTML app, something else, all of the above?
Any code samples/ideas by me should be considered Public Domain (no attribution needed) license unless otherwise stated.
pauljessup
Party member
Posts: 355
Joined: Wed Jul 03, 2013 4:06 am

Re: Some thoughts on a GB Studio style development environment for Love and Lua...

Post by pauljessup »

Yes, that's it exactly! The engine would be in Love2d and Lua, and could be packaged with a *build* command or tested out via a menu (similar to how it's done in most IDE's, and also how GB Studio does it). I would probably use boon for building- it would run the command line when you chose the item from the menu, so that it would combine all of the new files and the engine into a single .love or an OS version like a Mac app or the windows executable.
pauljessup
Party member
Posts: 355
Joined: Wed Jul 03, 2013 4:06 am

Re: Some thoughts on a GB Studio style development environment for Love and Lua...

Post by pauljessup »

Like, you use the IDE, you create your game in this simplified, visual manner (much like how Godot, GB Studio, RPGMaker, etc do).

Basically, the work flow as I see it-
User goes to "create new project" in the IDE. In the back end, it copies the engine made in love2d and all the necessary directories and renames it to the project name. Then, when you save the project it saves all the json files in this new project directory (as well as any images, tile maps, music, assets, etc). When you click "run" on this project it then just uses Love2d on the command line to launch that directory in Love2d.The engine would then load those specific json files, tiles, assets, etc. When you "build" it, boon will generate the .love file, the windows files, and the mac os files and/or linux files.

Let me know if that makes sense! I hope I explained that right. I see it very clearly in my head
User avatar
milon
Party member
Posts: 472
Joined: Thu Jan 18, 2018 9:14 pm

Re: Some thoughts on a GB Studio style development environment for Love and Lua...

Post by milon »

Yeah, that makes sense. A visual game builder for love that can output a .love or exe or Mac app. (Or maybe HTML5.) Sounds like a worthwhile project!

Do you picture this being used by amateurs, professionals, or both? Just curious.
Any code samples/ideas by me should be considered Public Domain (no attribution needed) license unless otherwise stated.
pauljessup
Party member
Posts: 355
Joined: Wed Jul 03, 2013 4:06 am

Re: Some thoughts on a GB Studio style development environment for Love and Lua...

Post by pauljessup »

I see both, at least hopefully? I think that will depend on how versatile I can make it...and how easy it will be to modify and add stuff onto (for experienced developers), and balancing that with an easy cost of entry for newbies, and how much they can do without boiling down to code
pauljessup
Party member
Posts: 355
Joined: Wed Jul 03, 2013 4:06 am

Re: Some thoughts on a GB Studio style development environment for Love and Lua...

Post by pauljessup »

Started work on the engine, which will be the basis that everything else builds off of. I decided to go with lua tables rather than json...they're just as easy to generate from code as json is, so why add another layer ontop of that?

Anyway! So far, it's going exceedingly well. It's going to be open source, probably MIT License or Apache, I'm not sure which yet. The plugin system already works wonders, the basic scene architecture and loading background layers and sprite objects works like a charm, and the ability to override code, etc is working great too. Need to add collision matrixes and some other basic things like debug interface as well. Hmmm. After that I'll begin on the visual editor, which will be the really hard part.

Nice thing is, the plugin architecture makes it easily extensible, so adding in let's say platforming abilities with gravity will just be installing and enabling the plugin. Same with an RPG battle system, or an item management system, etc. I think this will be key...having it be easy to extend, be open source, yet also easy to use for new users...

The engine will probably focus on making Hi Bit style games...which, yanno, rock.
pauljessup
Party member
Posts: 355
Joined: Wed Jul 03, 2013 4:06 am

Re: Some thoughts on a GB Studio style development environment for Love and Lua...

Post by pauljessup »

Oh, Green Ninja is the tentative title. I'll get it up on github once I finalize the name...I think I might have a better one to use, we'll see.
pauljessup
Party member
Posts: 355
Joined: Wed Jul 03, 2013 4:06 am

Re: Some thoughts on a GB Studio style development environment for Love and Lua...

Post by pauljessup »

After some thinking, I realized that there are a lot of open source generic game dev engines (Godot, GDevelop, etc), and I figured it might be better if I focued this into a niche. I was thinking- a hi bit pixel art JRPG engine. Something like RPGMaker, but open source and free and built on Love2d and Lua. Something extensible through plugins...

I'm not going to be able to use Electron for the IDE...Mac Sierra is having some issues with NPM at the moment (shame, I know how to do Javascript like the back of my hand)...instead I'll turn to GTK+ and Glade for cross platform IDE. I think I'll use TileD as the level editor, though I was going back and forth on using that or using something custom made (benefits and drawback to each, obv). But TileD is such a great tool, and being able to set it up right with this should be fairly simple using Projects and template maps.

Oh, still messing around with names.
User avatar
Hugues Ross
Citizen
Posts: 85
Joined: Fri Oct 22, 2021 9:18 pm
Location: Quebec
Contact:

Re: Some thoughts on a GB Studio style development environment for Love and Lua...

Post by Hugues Ross »

I was thinking- a hi bit pixel art JRPG engine. Something like RPGMaker, but open source and free and built on Love2d and Lua. Something extensible through plugins...
As someone interested in getting back into RPG dev this sounds like a neat direction to go in! It's something I attempted a couple years back (albeit not with love), but never got very far with. I'd be interested in seeing where this goes if you decide to go through with it, and maybe take it for a spin myself.
Post Reply

Who is online

Users browsing this forum: No registered users and 17 guests