Quest System

Okay, so! Following what I decided about the intro, the next real step is to get the quest system going. The way it works is by a few structures:

ent_quest -- top level structure; contains an ent_task, as well as some information about the difficulty/etc. of the quest

ent_task -- virtual tree structure used to describe something the player has to do, what rewards are required, and what rewards are produced

ent_reward -- an item, piece of information, etc. for the player to get

So! Basically, to construct the quests, I first lay out all the rewards (rewards have a real-valued order, to help sort-out dependancies) throughout the game universe.

Once those are laid out, I produce a quest. The quest is generated to produce a given reward, and will look for rewards of lesser order to use as inputs when creating the task.

So, the player will always be able to get to rewards of a higher order, until they attain a peak reward and win the game.

The tricks are in:

1. ent_world -- has to lay out the rewards for the entire galaxy

2. ent_quest -- not really that tricky, just has to sub-initialize

3. ent_task -- quite tricky; has to produce clues (phrase narratives) for the task (in some logical way), as well as know how to initialize itself for any given reward.

4. ent_reward -- not really tricky at all

Stuff I need to be careful about:

-- if a reward is an input for more than one quest, it means that only ONE of those branches can be followed by the player (since completing that task will burn up the reward); i can counteract this by allowing rewards to only be used once over all the quests (i.e., a 1:1) or else MAYBE not burning up the reward (e.g., "Well, you can hold onto that, it might come in handy!" in a fetch quest)

-- some rewards are useless (no quests use them) and some are free (not produced by any quest, but readily available). Other rewards are given in multiple quantities, this is particularily sensible for cargo type rewards (e.g., to get 20.4 kg of plutonium for a given task, you my have to complete two quests for 10.2 kg each; the current system allows this)


◀ Back