Noob Help On Quest Scripts

smoochy boys on tour

MythRohan

LOMCN Veteran
Veteran
Nov 18, 2011
2,147
82
135
Northant's Town : Serious Gamer
What can I use flags for?

Flags are usful for a variety of different things. Triggers and Quests mostly. This lesson will show you how to make a basic flag quest, and will touch on usingMapQuest.txt.

Simple Item Quest
[@Main]
#IF
#SAY
I collect Bones if you bring me some and I'll pay you well!\
I buy in 10's\
< Where can I find them?/@wherebone>\
< Here I have some!/@givebone>\
< I'm good../@Exit>

[@wherebone]
#SAY
You can get Bones by killing mobs in BoneCave\
< back/@Main>

[@givebone]
#IF
checkitem Bone 10 <<checks the amount of bone you have
#ACT
take Bone 10 <<takes the amount of bones you have
give gold 10000
#SAY
Thanks, here take this!\< Thanks!/@Main>


As you can see in the above, this is a repeatable Item Quest, there are no triggers or flags to say once its done that you cannot do it again. But that is ok for a repeatable quest. These would proberly be good for basic town quests or whatever you feel is necesery.

IF you need a bigger advance system,say you want a Job type system where once you have done a quest you don't want the user to be able to do it again. But you would like to keep track of what you have and haven't done. this should help give you an idea of how to go about it.

Bigger Item Quest - (Using Flags)

[@Main]
#IF
#SAY
Hi there < $USERNAME>, how can I help you today?\
\
< Do you have any jobs for me?/@joblist> (Quests)\
< I'm good../@Exit>

[@joblist]
#SAY
Current Jobs:\
#IF
CHECK [381] 0
#SAY
< Bone Quest/@bone> - {FCOLOR/10}Reward!{FCOLOR/12} - 50,000 Gold\
#IF
CHECK [381] 1
#SAY
{FCOLOR/12}Bone Quest - {FCOLOR/10}Completed!{FCOLOR/12}\
#SAY
\
< Exit/@Exit>

[@bone]
#SAY
Objective:\
Collect 50x Bone's\
\
Reward:\
50,000 Gold\
\
#IF
CHECK [380] 0
#SAY
< Accept Job/@bone1>\
#IF
CHECK [380] 1
#SAY
Job in Progress!\
< I have the stuff!/@bone2>\
#SAY
< Exit/@Exit>

[@bone1]
#IF
CHECK [380] 0
#ACT
SET [380] 1
goto @bone
break
#ELSEACT
break

[@bone2]
#IF
checkitem Bone 50
#ACT
take Bone 50
give gold 50000
SET [381] 1
#SAY
Items Recieved\
Reward Given\
\
< Thanks!/@joblist>
#ELSESAY
Not enough Bones!\
< Dammit!/@Exit>



Using flags. Above is an example of a Job Quest system. Everytime you complete a quest you will see 'Completed' next to it in the Job List Menu. Quests done this way can only be activated once. Once you get the hang of it you can add more Jobs quickly and others easily.


if u do decide to make a quest script, start small and simple to get the hang of it, and create it from there :D good luck to all

---------- Post added 06-04-2012 at 03:41 PM ---------- Previous post was 05-04-2012 at 08:53 PM ----------




Oh and regarding scripts

it would be great if people could add there kool scripts to share here to help the community

Many Thanks
regards

MythRohan
 
Last edited: