Users browsing this thread: 1 Guest(s)
Coding a 2D JRPG?

#1
 
Status
None
One of my long time goals was to write a simple, modular 2D JRPG engine in C; and then write modules to handle assets, scripting, and mechanics similar to my favorite FF games. After that I would write scripts to rip the assets from said games and format them for use in my engine.

Does this seem like the right way to do a clone? There is a lot of potential for engine reuse between FF 1 through 6, though combat and menu sub-modules would differ.

I don't have things set up to do this right now, but it is in my 2 to 4 year planning horizon. I just want your thoughts on it, and to see if it makes for interesting discussion. I'm especially interested in discussion of how these games are structured.
 
Quote  

#2
Posts: 3,969
Threads: 279
Thanks Received: 236
Thanks Given: 57
Joined: Oct 2011
Reputation: 65
Status
Tissue-aware
I've been pondering with the idea myself for some time now, I'll probably start one after University in about 2 years. Have you considered C++ and SDL 2? I've done a platformer for school and used that and it was easy to use. This guy also has great examples.

You could also use Unity or Unreal Engine but I've never used them. I guess you want to stay away from Game Maker and RPG Maker. If you plan on coding all your tools too it will increase significantly your workload but for certain things there are existing tools versatile enough, like Tiled.

I bought this book last year, I did not yet had the chance to go through it but if you want it send me a pm: https://howtomakeanrpg.com/

It's an interesting project you'll learn a lot from. I would personally mimic the FF4-FF5-FF6 style. If you plan on ripping music and GFX, then you got the assets question almost solved.
  Find
Quote  

#3
 
Status
None
I don't know anything about C game or gui libraries, I'll figure it out as I need to. I don't want to use a very complicated library, but I do want something that is maintained, Linux native, and portable to at least Windows 7.

I don't want to use an existing engine, and given the simplicity of 2D (with possible exceptions for parallax scrolling), I don't think I will need one.

I don't need tools to edit assets and data, they already exist for the games themselves. That said I should make them easy to modify. Maybe store them in simple format. Plain text, possibly SQL databases, upscaled PNGs for image assets, maybe a way to convert midi scores + instruments into lossless audio.

The actual battle and event scripting modules I'll probably convert them to bytecodes that the scripting modules can interpret. Should make it very easy to debug. Maybe add an option to "compile" these event scripts so the interpretor can skip some steps. I want this to be very tight, something that can fit in a 2 MB level 2 cache.

I would reuse parts of the modules as much as possible, with sub modules you can switch out for thing unique to each game. Thus you could hack the FF5 job system to FF6 with far less effort than it would take for assembly language. Same deal with extending the scripting systems, upscaling art assets, improving music, and so on.

So ideally you could use the existing FF rom hacking tools and export your changes (or rip soneone elses rom hack), you could rip it all out and start from scratch using PC specific tools like GIMP/Audacity (the scripting would just be plain text), or both.

Parallax scrolling might require its own tool, depends on what the interpretors allow and if its easy to preview in-game.

What do you think of this method?
 
Quote  

#4
Posts: 3,969
Threads: 279
Thanks Received: 236
Thanks Given: 57
Joined: Oct 2011
Reputation: 65
Status
Tissue-aware
(11-06-2018, 10:09 PM)MysticLord Wrote: I don't know anything about C game or gui libraries, I'll figure it out as I need to. I don't want to use a very complicated library, but I do want something that is maintained, Linux native, and portable to at least Windows 7.

SDL 2 is cross-platform and vastly used for I/O, sound and graphics.

(11-06-2018, 10:09 PM)MysticLord Wrote: I would reuse parts of the modules as much as possible, with sub modules you can switch out for thing unique to each game. Thus you could hack the FF5 job system to FF6 with far less effort than it would take for assembly language. Same deal with extending the scripting systems, upscaling art assets, improving music, and so on.

This is a good approach.

(11-06-2018, 10:09 PM)MysticLord Wrote: So ideally you could use the existing FF rom hacking tools and export your changes (or rip soneone elses rom hack), you could rip it all out and start from scratch using PC specific tools like GIMP/Audacity (the scripting would just be plain text), or both.

They all not all open source sadly so some impossible to modify. I would personally not use the ROM as a base because everything would need to be coded in the ROM specific formats for data and modification and you would need to code an export format for everything that is more suitable for your game. For my project I was thinking just coding an editor for data and scripting languages and use just one format for each thing. Using a ROM as a base seems to doubling the workload to create editors. Maybe some export features for graphics but that would be it as far as using the ROM would be.
  Find
Quote  

#5
 
Status
None
The format I use for data storage would by necessity be different from that of the rom, both because it's simpler and easier to expand. If it is 1 for 1 with every bit it isn't easy to expand, and it's hard to work with. If it exports scripts to a text file as mnemonics or method calls with parameters as appropriate, it is very easy to expand and work with. The games scripting systems and data layouts become a minimum standard, as I don't see anyone taking a mod from this engine to a rom, but I do see people doing the reverse. There are a lot of good mods out there that change data, scripts, and assets.

Exporting data from a rom is very easy, even if it's compressed or part of a disc image file system. I wouldn't hardcode addresses, instead I would abstract it to data/asset descriptors in CSV files. If a hack or translation or regional difference moves data/assets around, you just locate them then change that entry in the text.

Once you extract data, assets, and scripting from your favorite rom hack/mod, they are already in easy to edit forms. SQL for data, plain text for scripts, png for images, lossless audio for audio, lossless video for video. I'm not sure what the most cutting edge thing for animated soundless images is, are there rplacements for GIF?
 
Quote  

#6
Posts: 3,969
Threads: 279
Thanks Received: 236
Thanks Given: 57
Joined: Oct 2011
Reputation: 65
Status
Tissue-aware
Unless you make an animation engine or scripting language for animations, GIFs are the way to go but I could be wrong.
  Find
Quote  

#7
 
Status
None
I looked it up and there are a few specs and implementations for animated pngs.
 
Quote  

#8
Posts: 17
Threads: 2
Thanks Received: 0
Thanks Given: 0
Joined: Dec 2014
Reputation: 2
Status
None
(11-05-2018, 02:39 PM)MysticLord Wrote: One of my long time goals was to write a simple, modular 2D JRPG engine in C; and then write modules to handle assets, scripting, and mechanics similar to my favorite FF games. After that I would write scripts to rip the assets from said games and format them for use in my engine.

Does this seem like the right way to do a clone? There is a lot of potential for engine reuse between FF 1 through 6, though combat and menu sub-modules would differ.

I don't have things set up to do this right now, but it is in my 2 to 4 year planning horizon. I just want your thoughts on it, and to see if it makes for interesting discussion. I'm especially interested in discussion of how these games are structured.

If I understood correctly what you want, I think it sounds similar to what I'm doing. But I'm using GameMaker and it's based on replicating things from scratch instead of figuring out ways of using existing routines from other games.

I started out creating a very flexible menu/combat system modeled after FF6, then I started adapting different FF characters into it. So far I've gotten FF1 (a white mage), FF7(Cloud) and I'm working on FF15 (Noctis). Also got Terra in it. 


I'm a coding rookie and this is my first big project. It's probably because of my inexperience that I'd say man this thing moves away from being simple fast. When I first started I had these neat systems to handle menus, targetting, processing commands, character stats, etc. Then as I replicated stuff from other games kept coming across edge case after edge case, things that required turning my systems upside down.

It's coming and getting close to a demo release. The ultimate goal is adapting every main character from the series as they are and some memorable dungeons and bosses from each game. But I think about all that and it's exhausting. I've been working on this on and off for three or four years maybe? I guess putting everything together would be a year, and all I've got to show for is one boss (Kefka), and four characters with a handful of spells. 

It's tiring ripping stuff, replicating animations, coming across edge cases that laugh at all your assumptions. I learned a lot doing this but it's coming to a point where I'm thinking "shouldn't I be working on my OWN game instead of doing something that's going to get me a cease and desist letter?". 

I could use some help though, if the helper doesn't mind a) using gamemaker 2 and b) learning all the code I've created.
  Find
Quote  

#9
 
Status
None
My advice for you is to still work on it part time and enroll at a community college (NOT A UNIVERSITY) that has a lot of CS and CIS classes available. Look up the Chemeketa CC CS/CIS course catalogs for good examples. Lane CC and Portland CC are also good examples.

You should be able to get Pell Grants to pay for all the fees without getting loans, as long as you don't get student housing. If they say you must, tell them you won't, to deal with it, and to stfu. They push it because it's how they actually make money.

Never go into debt.

All you need is 1 or 2 years of someone forcing you to bust your butt and learn to really grasp programming. After that you can teach yourself.

Go for a technical degree, an associates of applied science or a 1 year certificate of completion.

Take these core classes:
CS 160, 161, 162 (intro to cs 1, 2, 3)
Data Structures 1, 2
SQL Relational Databases
HTML and CSS aka Web Dev 1
JavaScript aka Web Dev 2

After that take as many classes in one language as you can. C, C++, C#, and Java are good candidates for mastery.

After this get a job as a software developer and work on your side projects in your free time. You will get very fast and smart after about 1 year of continuous programming after school. Things that took you months or years will take weeks, what took weeks will be a weekend.

You could probably finish this project in a summer after you master programming.

My real goals are to master C, implement compression schemes, and implement various media formats and scripting systems in an extensible way. This project is how I intend to do it.
 
Quote  

#10
Posts: 17
Threads: 2
Thanks Received: 0
Thanks Given: 0
Joined: Dec 2014
Reputation: 2
Status
None
(01-19-2019, 12:10 PM)MysticLord Wrote: My advice for you is to still work on it part time and enroll at a community college (NOT A UNIVERSITY) that has a lot of CS and CIS classes available. Look up the Chemeketa CC CS/CIS course catalogs for good examples. Lane CC and Portland CC are also good examples.

You should be able to get Pell Grants to pay for all the fees without getting loans, as long as you don't get student housing. If they say you must, tell them you won't,  to deal with it, and to stfu. They push it because it's how they actually make money.

Never go into debt.

All you need is 1 or 2 years of someone forcing you to bust your butt and learn to really grasp programming. After that you can teach yourself.

Go for a technical degree, an associates of applied science or a 1 year certificate of completion.

Take these core classes:
CS 160, 161, 162 (intro to cs 1, 2, 3)
Data Structures 1, 2
SQL Relational Databases
HTML and CSS aka Web Dev 1
JavaScript aka Web Dev 2

After that take as many classes in one language as you can. C, C++, C#, and Java are good candidates for mastery.

After this get a job as a software developer and work on your side projects in your free time. You will get very fast and smart after about 1 year of continuous programming after school. Things that took you months or years will take weeks, what took weeks will be a weekend.

You could probably finish this project in a summer after you master programming.

My real goals are to master C, implement compression schemes, and implement various media formats and scripting systems in an extensible way. This project is how I intend to do it.

Thanks for the well crafted advice. I'm past that point in my life though. Currently holding a job and learning to code on my own as a past time. I had tried C# before and XNA but things took off when I started with GM. Seeing things done fast was very motivating. Once I'm done with this thing I'm thinking of doing something of my own. Small, simple, release it, see how it goes. Then maybe start branching out into C#+Unity or Python for non-game purposes.

Anyway, if you ever want to exchange design ideas on how to mix up all FF games into one hit me up. The other half of the fun in this project has been playing armchair designer.
  Find
Quote  



Forum Jump:

Users browsing this thread: 1 Guest(s)


Theme by Madsiur2017Custom Graphics by JamesWhite