I know something like this has been suggested before but I think I have an idea for how to make it in an actually very straightforward way.
The GoalThe idea of this program would be to take FF4 and change it from a linear plot-based standard JRPG game into a randomly-generated dungeon crawler. You would (probably) have a scene at the beginning where you can select/configure your party, and from then on, it's floor after floor of randomly generated content. No plot to speak of, no characters joining and leaving, whoever you pick at the beginning is your team for the game, no idea what's coming up. Probably a final boss or something at the end; in fact we can even punctuate the dungeon at fixed intervals with certain boss fights (e.g. the fiends) or something.
Changing the code of the game to randomly generate dungeons would pose quite the task and I have no expertise in how to go about that whatsoever; rather, my solution is more akin to something like the FF6 randomizer where you input a seed and an FF4 rom and the program does some stuff, then outputs a changed rom that has all the randomizations done ahead of time. From the point of view of the user, it would be hard to distinguish the end result from something that was generated on the fly.
Generating DungeonsOk, so there are a couple of ways the layout of the maps could be generated. The two main categories would be:
- Fixed list: Essentially, we would create ahead of time hundreds of map layouts and the program would shuffle them and take the first X to be the floors of the dungeon (X being the number of total dungeon floors in the game).
- Dynamically generated: Basically we would implement some sort of standard technique for creating randomly generated dugneons using simply "floor" and "wall" tiles, then have filters that would be applied afterwards to "polish" off the dungeon, putting in corner tiles, caps, details like torches or stones, etc.
The advantages of the fixed list strategy are that it will be easy (trivial) to program, and the maps will definitely look natural as they were made by hand by a human. The advantages of the dynamically generated strategy are that it will be much more random (no matter how many fixed maps we make, they will eventually start to look familiar), and won't involve the drudgery of having to design hundreds and hundreds of maps by hand. Personally, after having experienced quite enough of the Lunar Ruins, I'm more inclined towards the latter.
In either case, the dungeon layouts at first will not contain chests. This is a separate step. After the map layouts have been generated by whatever method, then we litter them with chests in places where said chests can be accessed (no orphaned chests that are inaccessible). There are known and documented ways of doing this. During this process we will be careful to track the appropriate "treasure indexes" for the maps so nothing gets messed up in that regard. Save points would also be randomly littered throughout the dungeon in a similar manner.
Generating TreasureJust because the treasure is random doesn't mean it has to be possible to get, f.ex. a Crystal sword in the first chest. We can make a "smart" algorithm that populates the chests based on the dungeon level. For example, we can take, say, all the weapons in the game and assign them an index of how "powerful" they are relative to each other (or otherwise how early in the game it would be acceptable to receive such an item) manually beforehand. Then, when generating chest contents, it would only put a given weapon on a floor within a certain margin of its assigned index. So the Wooden Rod would only be possible to be found on the first few floors, say, whereas the Crystal sword would only be possible to be found on the final few floors.
Most consumables would be generated at pretty much any point in the dungeon, but we can apply a similar strategy for when it starts to generate Hi Potions or X Potions as opposed to regular Potions, or Cabins as opposed to Tents, etc. We can even undummy all the cool items and litter those throughout as well.
Generating ShopsIn a similar manner to chests and save points, NPCs can also be littered throughout the dungeon. We can have a variety of events to pick from, but I think certainly at first it would mostly just be shops. So you go up to the NPC and talk and up comes a shop. Shop contents can be generated in a similar manner to treasure. Alternatively, we could have a bunch of preset shops, and when it generates a shop in the dungeon, it will randomly pick one within an appropriate power level range.
NPCs could be made to do other things too, though. Fat chocobos might be something you encounter from time to time. What about summons you can optionally talk to and fight and if Rydia is in your party she'll learn them.
Other ChangesIt might be necessary (or prudent) to make some slight changes to the content of (presumably vanilla) "FF2" in the name of making all the characters viable from beginning to end. Dark Knight in particular won't be a very good character if the content is unchanged, or even if all we do is undummy everything. Deathbringer is pretty solid with its OHK ability but still, his HP growth makes him pretty squishy late game and he can't use any late game armor except I think Glass Mask and Adamant? Can he even use the ribbon? Cid might be able to get by with axes maybe but he'll be pretty meh, and let's not even get started on Edward. Then there's the Yang HP. Tellah will have to have some mechanism for learning his spells... and for casting them... and for not losing stats as he levels up... and then there are some characters that, if nothing is changed, would be pretty broken early on like Edge and FuSoYa (if he's even included).
Independent of all that, though, I do think the dummied items should be restored, and the commands I guess would depend on how we go about balancing the characters.
Anyway this is
all just a concept right now. Who knows if I'll have gumption to make it, especially after having basically abandoned FF4kster, but the thought struck me so I figured I should at least share the idea. That said, I feel like this is something I have much more in the way of existing skills to be able to do as opposed to making an overworld editor. Maybe it's something we can work on together?
Thoughts?