source: trunk/game/dialogue/quest_sample.yaml @ 504

Revision 504, 3.0 KB checked in by barra_parpg, 9 years ago (diff)

Patch by mvbarracuda:

  • Property svn:eol-style set to native
Line 
1#   This file is part of PARPG.
2
3#   PARPG is free software: you can redistribute it and/or modify
4#   it under the terms of the GNU General Public License as published by
5#   the Free Software Foundation, either version 3 of the License, or
6#   (at your option) any later version.
7
8#   PARPG is distributed in the hope that it will be useful,
9#   but WITHOUT ANY WARRANTY; without even the implied warranty of
10#   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
11#   GNU General Public License for more details.
12
13#   You should have received a copy of the GNU General Public License
14#   along with PARPG.  If not, see <http://www.gnu.org/licenses/>.
15
16---
17NPC:  NPC
18AVATAR: gui/icons/npc.png
19START: main_dialog
20
21SECTIONS:
22    main_dialog:
23        - say: "Things are tough around here, let me tell you our problems"
24        - responses:
25            -
26              - "Here's your beer"
27              - finish_quest
28              - quest['beer'].isGoalValue("beer_gathered") and not quest.hasFinishedQuest('beer')
29
30            -
31              - "No problem (finished quest)"
32              - main_dialog
33              - quest.hasFinishedQuest('beer')
34
35            -
36              - "Give me a beer! (Cheater!)"
37              - give_beer
38              - quest.hasQuest('beer') and not quest.hasFinishedQuest('beer') and not quest['beer'].isGoalValue("beer_gathered")
39
40            -
41              - "I'm on it"
42              - main_dialog
43              - quest.hasQuest('beer') and not quest.hasFinishedQuest('beer')
44                #pc class should call this function (pc.hasQuest)
45
46            -
47              - "Sure, tell me all about it"
48              - listen_more
49              - not quest.hasQuest('beer') and not quest.hasFinishedQuest('beer')
50
51            -
52              - "That sounds boring. Bye."
53              - end
54
55    listen_more:
56        - say: "Raiders stole our cattle, our well was poisoned, and the beer is all gone!"
57        - responses:
58            # Raiders quest
59            -
60              - "I help you"
61              - quest_accept
62
63            -
64              - "Good luck with that"
65              - end
66
67            -
68              - "Fear not, gentle villager. I will return shortly with the antidote."
69              - back listen_more
70
71    quest_accept:
72        - say: "All your beer are belong to us!"
73        - start_quest: "quests/beer.yaml"
74        - responses:
75            -
76              - "Right..."
77              - main_dialog
78
79    give_beer:
80        - say: "Here's your beer..."
81        - increase_value:
82            quest: 'beer'
83            variable: "beer_gathered"
84            value: 1
85        - responses:
86            -
87              - "Thanks."
88              - main_dialog
89
90    finish_quest:
91        - say: "This is the good stuff! *hik*"
92        - complete_quest: 'beer'
93        - responses:
94            -
95              - "Sigh"
96              - main_dialog
97
98    stop_quest:
99        - say: "Jerk."
100        - delete_quest: 'beer'
101        - responses:
102            -
103              - "That's how they call me!"
104              - main_dialog
Note: See TracBrowser for help on using the repository browser.