;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
[@main]
#IF
Check [259] 1
Check [260] 0
#ACT
FormatStr "FLD_QUEST ='Anne' and FLD_CHARACTER='%s'" %USERNAME
ReadValueSql "TBL_StingQuests" %A9 "FLD_Stage" @AnneQuestStage
Break

#ELSEACT
Goto   @CheckComplete

[@CheckComplete]
#IF
Check [260] 1
#SAY
You have done all I require of you, thanks\\
<[ Exit ]/@exit>\\\
#ELSESAY
Lo lo, It's so nice to speak to you. I was \
wondering if you will be able to help me collect\
some rare ingredients for a potion that I am \
attempting to make.\\
<[ Yes of course, tell me more ]/@main>\
<[ Not today, i'm washing my hair ]/@exit>\\\
#ELSEACT
Set   [259] 1
break

[@AnneQuestStage()]
#IF
#ACT
Mov   D1   %ARG(1)

#IF
Equal  D1  0
#ACT
Goto @AnneQuest0
Break

#IF
Equal  D1  1
#ACT
Goto @AnneQuest1
Break

#IF
Equal  D1  2
#ACT
Goto @AnneQuest2
Break

#IF
Equal  D1  3
#ACT
Goto @AnneQuest3
Break

#IF
Equal  D1  4
#ACT
Goto @AnneQuest4
Break

#IF
Equal  D1  5
#ACT
Goto @AnneQuest5
Break

#IF
Equal  D1  6
#ACT
Goto @AnneQuest6
Break


;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; Part 0
[@AnneQuest0]
#SAY
First you have to kill the {FCOLOR/10}ForestYeti{FCOLOR/12} \
and he will give you my first ingredient, a \
{FCOLOR/10}RedPotion{FCOLOR/12}.  Return it to me straight\
away and I will tell you how to get my second \
ingredient\\
<[ I will find it for you ]/@AnneQuest0_1>\
<[ Not my thing sorry ]/@exit>\\
#ACT
Break

[@AnneQuest0_1]
#SAY
Cool, this is a good start\\
<[ Exit ]/@exit>\
#ACT
Mov  A0  %USERNAME
Mov  A1  "Anne"
Mov  D0  1
FormatStr "'%s','%s',%s" %A0 %A1 %D0
Mov A8 %A9
FormatStr "FLD_CHARACTER='%s' and FLD_QUEST='%s'" %A0 %A1
WriteValueSql "TBL_StingQuests" %A9 "FLD_CHARACTER,FLD_QUEST,FLD_STAGE" %A8

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; Part 1
[@AnneQuest1]
#SAY
Have you got my {FCOLOR/10}RedPotion{FCOLOR/12} of the {FCOLOR/10}ForestYeti{FCOLOR/12}?\\
<[ Getting it now.. ]/@exit>\\
#ACT
Break

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; Part 2
[@AnneQuest2]

#IF
CheckItem  RedPotion 1
#SAY
Thankyou, I will add that to the cauldron \
straight away.  Now to get the second ingredient, \
a {FCOLOR/10}BluePotion{FCOLOR/12}, you have to kill a {FCOLOR/10}ZumaArcher{FCOLOR/12}\
and return the ingredient to me straight away\
<[ ZumaArcher you say? Dead easy! ]/@exit>\
#ACT
Take  RedPotion  1
Mov  A0  %USERNAME
Mov  A1  "Anne"
Mov  D0  3
FormatStr "FLD_STAGE=%s" %D0
Mov A8 %A9
FormatStr "FLD_CHARACTER='%s' and FLD_QUEST='%s'" %A0 %A1
UpdateValueSql "TBL_StingQuests" %A9 %A8
Break

#ELSESAY
Where is my {FCOLOR/10}RedPotion{FCOLOR/12}\\
<[ Getting it now.. ]/@exit>\\


;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; Part 3
[@AnneQuest3]
#SAY
I really need that {FCOLOR/10}BluePotion{FCOLOR/12}, off that \
{FCOLOR/10}ZumaArcher{FCOLOR/12}\\
<[ OK, np's ]/@exit>\
#ACT
Break

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; Part 4
[@AnneQuest4]

#IF
CheckItem  BluePotion 1
#SAY
Thankyou, that has been added, the potion is \
nearly complete all that is left to do, is for \
you to kill a {FCOLOR/10}BlackCaptain{FCOLOR/12} and return\
the third ingredient (a {FCOLOR/10}GreenPotion{FCOLOR/12}) to me, \
and I will reward you for your help.\\
<[ OK ]/@exit>\
#ACT
Take  BluePotion  1
Mov  A0  %USERNAME
Mov  A1  "Anne"
Mov  D0  5
FormatStr "FLD_STAGE=%s" %D0
Mov A8 %A9
FormatStr "FLD_CHARACTER='%s' and FLD_QUEST='%s'" %A0 %A1
UpdateValueSql "TBL_StingQuests" %A9 %A8
Break

#ELSESAY
Where is my {FCOLOR/10}BluePotion{FCOLOR/12}\\
<[ Getting it now.. ]/@exit>\\

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; Part 5
[@AnneQuest5]
#SAY
Can you hurry with that {FCOLOR/10}GreenPotion{FCOLOR/12}, I know that\
{FCOLOR/10}BlackCaptain{FCOLOR/12} is hard but I need it!\\
<[ Yeah Yeah Yeah ]/@exit>\
#ACT
Break

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; Part 6
[@AnneQuest6]

#IF
CheckItem  GreenPotion 1
#SAY
Thankyou, my potion is now complete, in return \
for your help here is your reward, the potion I\
have been working on...\\
<[ OK ]/@exit>\
#ACT
Take  GreenPotion  1
Give BlueDrug 40
Mov  A0  %USERNAME
Mov  A1  "Anne"
Mov  D0  7
FormatStr "FLD_STAGE=%s" %D0
Mov A8 %A9
FormatStr "FLD_CHARACTER='%s' and FLD_QUEST='%s'" %A0 %A1
UpdateValueSql "TBL_StingQuests" %A9 %A8
Set  [260] 1
Break

#ELSESAY
Where is my {FCOLOR/10}GreenPotion{FCOLOR/12}\\
<[ Getting it now.. ]/@exit>\\

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;