I've started working in a quest system for my game, but I stumble in a zone where I have to many, if/else conditions to handle a quest, whether you have X and Y item in your inventory, whether you have already talk with a NPC, or whether some other quest stage is a given value and so on.
This end ups making the code very unclean, hard to fix and extend.
I'm wondering what's a good way to handle this.
I've read that keeping your quest as XML file is a good practice, but I've never worked with XML before(I know what they are, but I'm unfamiliar with how to properly make one)
I made a template quest to handle fetch/talk quests in a CSV file. Which looks something like this:
But I'm not that I'll end-up shooting my own foot with this custom system.
The branches of a quest can depend on items, previous quests, npc status, player status... So, what's a good way to deal with this?
EDIT:
This is not a duplicate of this question since the answers for this question are either using XML (which I said I don't have the know-how) or use multiple if/else conditions, which is my start problem.