Ignore:
Timestamp:
06/29/10 17:09:38 (9 years ago)
Author:
beliar
Message:

Patch by Beliar.

  • Quest files are now read in and parsed at the start of the game. and the Quests stored in the quests property of quest_engine. This allows quest variables to be set even when the quest is not active.
  • replaced addQuest with activateQuest which now only accepts the quest_id as a parameter.
  • Removed deleteQuest and added failQuest instead
  • Added a function to restart a quest, this will reset quest_variables that have a "reset_value" property to this value.
  • Modified Dialogue and Quest files to work with the changes
  • Added "QuestsDirectory?" setting to the settings file. Please delete your old settings.xml and let the game recreate it.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/game/scripts/gamemodel.py

    r569 r570  
    1717 
    1818# there should be NO references to FIFE here! 
    19 import pickle 
    2019import sys 
    2120import os.path 
     
    2827from common.utils import parseBool 
    2928from inventory import Inventory 
     29from scripts.quest_engine import QuestEngine 
     30 
    3031try: 
    3132    import xml.etree.cElementTree as ElementTree 
     
    5556        self.savegame = None 
    5657        self.game_state = GameState() 
     58        self.game_state.quest_engine = QuestEngine(\ 
     59                                            settings.get("PARPG", 
     60                                                         "QuestsDirectory")) 
     61        self.game_state.quest_engine.readQuests() 
    5762        self.pc_run = 1 
    5863        self.target_position = None 
Note: See TracChangeset for help on using the changeset viewer.