Working on 1st RPG, how to handle quests etc.

Started by
1 comment, last by gabars 6 years, 10 months ago

Hi, I started working on my 1st (2D) RPG (using C++ and SFML). In the past, I've only worked on platformers or what I call fixed-view (i.e. Asteroids, Pac-man, Pong). I'm wondering how you integrate quests, characters, etc. into the game? So far the best idea I've come up with is to have a directory for quests and keep all quests or quest lines in separate files.

Maybe a .xml file that would contain a tree of quests that could refer to other quests like


<questline name="L1">
    <quest name="Q1">
        ...
        <unlock>L1:Q2</unlock>
    </quest>
    <quest name="Q2">
...

But what about the NPCs? I want them to be there whether the quest is active or not, I want quests to have the ability to kill them, change their location, dialogues etc. Basically, I want the implementation to be as flexible as possible so I don't cock-block myself later. Any input would be appreciated (ideas, projects on GitHub I could snoop on, books that aren't too expensive, anything really...)

Advertisement

How did you get enemies into your pacman like game? How did you spawn and move asteroids in your asteroids like game? There are literally a plethora of ways to do it. Most will work. Honestly just code. If you have to rip it out later all the better as a learning experience. You honestly learn the least from looking at other peoples solutions compared to writing your own and realizing it's wrong. You're still at the learning stage, take advantage of learn all you can from your own mistakes.

"Those who would give up essential liberty to purchase a little temporary safety deserve neither liberty nor safety." --Benjamin Franklin

In pac-man the ghosts all spawned in the center and asteroids was all random generation. I had a wave system that increased the number of asteroids that could be on screen at the same time, and they spawned in a random location, with random velocity.

I have no experience "scripting" a game and the reason I'm asking is because I don't know where to start. I'm all about learning from my own mistakes, but I'm sure some inspiration can't hurt.

This topic is closed to new replies.

Advertisement