A lot of aspiring developers tell me that they want to program a JRPG-style game, with little to no programming experience. Within the past few months, I’ve had several potential students ask me about developing a game like Pokemon or Fire Emblem for a semester-long project in a high school programming class.
My advice might seem contradictory, given that I’m teaching people how to do exactly what those students asked me about, but I always caution students about taking on such a task. RPGs are one of the most complicated game genres to program, especially at the level that students and new developers ask me about. They’re generally not interested in doing a small, simple text-based RPG, they’re looking to make games with very complicated systems. One student recently approached me about making an MMO (massively multiplayer online) like World of Warcraft!
It’s not that I don’t think it’s possible for newer developers to make an RPG, even working solo. My aim is to get them to really think about and understand what such as project actually entails. Then if they’re still interested, I want them to understand that it will probably take them much longer than they thought, with many detours and bumps along the way.
What really goes into making an RPG? Simply drawing and moving objects on the screen isn’t too hard, relatively speaking, but there’s a lot of numbers and systems in the back of most RPGs. Let’s look at some common RPG features:
- Inventory system: Collecting, displaying, and using items; assigning different inventories to each character (in some games); inventory limits and weights
- Dialog system: Displaying dialog; presenting branching options; storing text for different characters at different times
- Locations: Overworld vs. dungeon/town navigation; creating, storing and loading maps for each location; keeping a list of possible enemies in each location; connecting maps and rooms to each other
- Playable characters: Current list of equipped items; learn spells and abilities; character stats; experience tables and leveling up
- Battle system: Deciding which enemy configurations to fight; randomly determining when an encounter should occur; time and action gauges; turn-based input; branching options for each player action; enemy AI; magic/action points; distributing experience points; determining random item drops; determining amount of damage dealt and blocked
- Save system: Multiple save files; system timer; persistent rooms; writing to and loading from files
- Art and visuals: Designing and displaying GUI; assigning sprites to each visible object; laying out maps; battle and character animations; menu layout; fonts; text display
- Sound and music: Location-specific music; battle sound effects; making sure that sounds are balanced; figuring out space limitations
- Story: Different optional story arcs; non-sequential stories; changing character dialogue and other information based on what’s happened in the story or optional party members; coming up with the story ideas themselves
- Party system: Keeping track of different playable characters at once; figuring out who is in the front or in the back; switching party members
I didn’t even talk about things like multiple endings, or open-world exploration, or mini-games and puzzles. Some RPGs might have additional elements.
The thing about these types of games, is that they can be so immense, that it’s often hard for a first-timer to tackle. You can use a specific engine (such as RPG Maker), which will take care of a lot of features for you, but even then it’s still good to know some programming skills so that you can do custom scripts.
I wrote in my last post about planning before coding, and hopefully you can see how it would help to write down your design ideas first for a game like this.
At the same time, I understand that writing a design document for a game this size is pretty daunting, especially if you’ve never done so before. When I worked on a professional software development team, we spent lots of time, as a development team and with stakeholders, getting the project requirements right and then condensing them into a reference document. And of course, features and requirements change throughout the project. So this is another reason why a game like an RPG can be daunting, even for experienced developers.
So it probably would take you longer than you might initially think to develop an RPG. If we can break down some of the different features into smaller pieces, so that you can understand how they work, and how to apply what you’re learning in programming class to actual game development, then you’ll hopefully have an easier time putting all the pieces back into a whole game.
From looking at the list of common features (which, as we said, is by no means complete), you might be seeing how some of the concepts you’ve learned in computer science class might apply. For example:
- Random number generation: Battle damage (we generally don’t want the same amount of damage inflicted each time an attack is used); frequency of random battle encounters; rate of item drops
- Arrays and lists: Party system (a list of playable characters); dialogue options; possible item drops; inventory lists
- Maps, trees, and dictionaries: Inventory system
- File IO (input/output): Saving and loading files; loading and displaying image files
- Classes and objects: Player objects; enemy objects; item objects
- Inheritance, polymorphism, abstract classes and interfaces: Different types of enemies; different types of objects or weapons; playable character specializations
- If/else and switch statements (conditionals): Branching dialogue options; random chances of battle encounters or item drops; determining results from status ailments or effects; checking if certain items are equipped
- Loops: Determining if a battle is still on going (while there are still enemies left and at least one party member is still alive)
- Strings: Dialogue; substituting custom character or item names
- Recursion: Sorting lists (such as inventory lists); path-finding (using AI to figure out the best path from Point A to Point B)
So, yes, making an RPG is a challenging project, and can be quite the task even for experienced developers. But it is possible, if we take an organized, systematic approach. I can show you how you can take on this challenge. If you’re interested, I’ve started a page dedicated to how to program RPGs.
I am also putting together a self-paced online course about programming role-playing games (RPGs) in Java, with a mixture of free and paid content. We are asking for feedback and contact info, if you’re interested in enrolling. To send feedback and be notified about when the class is ready, please fill out this form.