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/dialogue/quest_sample.yaml

    r504 r570  
    3636              - "Give me a beer! (Cheater!)" 
    3737              - give_beer 
    38               - quest.hasQuest('beer') and not quest.hasFinishedQuest('beer') and not quest['beer'].isGoalValue("beer_gathered") 
     38              - quest.hasActiveQuest('beer') and not quest.hasFinishedQuest('beer') and not quest['beer'].isGoalValue("beer_gathered") 
    3939 
    4040            - 
    4141              - "I'm on it" 
    4242              - main_dialog 
    43               - quest.hasQuest('beer') and not quest.hasFinishedQuest('beer') 
    44                 #pc class should call this function (pc.hasQuest) 
     43              - quest.hasActiveQuest('beer') and not quest.hasFinishedQuest('beer') 
     44                #pc class should call this function (pc.hasActiveQuest) 
    4545 
    4646            - 
    4747              - "Sure, tell me all about it" 
    4848              - listen_more 
    49               - not quest.hasQuest('beer') and not quest.hasFinishedQuest('beer') 
     49              - not quest.hasActiveQuest('beer') and not quest.hasFinishedQuest('beer') 
    5050 
    5151            - 
     
    7171    quest_accept: 
    7272        - say: "All your beer are belong to us!" 
    73         - start_quest: "quests/beer.yaml" 
     73        - start_quest: beer 
    7474        - responses: 
    7575            - 
     
    9898    stop_quest: 
    9999        - say: "Jerk." 
    100         - delete_quest: 'beer' 
     100        - fail_quest: beer 
    101101        - responses: 
    102102            - 
Note: See TracChangeset for help on using the changeset viewer.