Quest Npc Not Working

Mu online season 21 - grand opening

noisound

Golden Oldie
Golden Oldie
Jul 23, 2004
1,335
10
175
My quest npc isnt working properly, u can just keep talking to him and reciving the prize without needing the items to gain the prize.

can some1 edit the script im gna post so u can only do quest once, and it has to take items b4 giving the prize.

[@main]
#IF
CHECKLEVEL 30
#SAY
Help <$USERNAME>, My precious book was lost while\
i was hunting many years ago, please get it back?\
<Ill help, whats the name of this book/@items>\ <No/@exit>
#ELSESAY
you are too low <$USERNAME>

[@items]
The book is called "Book".\\
<I have your items/@prize>\ <i will go get your Book/@hurry>

[@hurry]
please hurry <$USERNAME> i will reward u kindly\ \
<Bye/@exit>

[@prize]
#IF
CHECKITEM Book
#ACT
TAKE Book
GIVE ExpPotion
SET [5] 1
#SAY
thank you <$USERNAME> you really helped me.\ \
<bye/@exit>
#ELSESAY
You have already done this quest <$USERNAME>
 

TravisW

LOMCN Veteran
Veteran
Sep 4, 2007
737
17
105
[@main]
#IF
CHECK [5] 1
#ACT
goto @cant
#ELSEACT
goto @check1
[@check1]
#IF
CHECKLEVEL 30
#ACT
goto @main-1
#ELSEACT
goto @cant
[@cant]
Sorry <$USERNAME>, either you've helped me already,\
or you aren't level 30 or higher.\
< Close/@exit >
[@main-1]
Help <$USERNAME>, My precious book was lost while\
i was hunting many years ago, please get it back?\
<Ill help, whats the name of this book/@items>\ <No/@exit>

[@items]
The book is called "Book".\\
<I have your items/@prize>\ <i will go get your Book/@hurry>

[@hurry]
please hurry <$USERNAME> i will reward u kindly\ \
<Bye/@exit>

[@prize]
#IF
CHECKITEM Book 1
#ACT
TAKE Book 1
GIVE ExpPotion 1
SET [5] 1
#SAY
thank you <$USERNAME> you really helped me.\ \
bye/@exit
#ELSESAY
You don't have the Book!\
< Close/@exit >
 
Upvote 0

Neptune

Golden Oldie
Golden Oldie
Nov 19, 2003
1,473
9
175
Chester :P
[@main]
#IF
CHECKLEVEL 30
#SAY
Help <$USERNAME>, My precious book was lost while\
i was hunting many years ago, please get it back?\
<Ill help, whats the name of this book/@items>\ <No/@exit>
#ELSESAY
you are too low <$USERNAME>

[@items]
The book is called "Book".\\
<I have your items/@prize>\ <i will go get your Book/@hurry>

[@hurry]
please hurry <$USERNAME> i will reward u kindly\ \
<Bye/@exit>

[@prize]
#IF
CHECK [5] 1
CHECKITEM Book 1
#ACT
TAKE Book 1
GIVE ExpPotion 1
SET [5] 1
#SAY
thank you <$USERNAME> you really helped me.\ \
<bye/@exit>
#ELSESAY
You have already done this quest <$USERNAME>
 
Last edited:
Upvote 0

JealY

LOMCN VIP
VIP
Nov 28, 2004
5,357
55
335
England
That looks right Nep but just looking at it there's something wrong I think :P

Code:
[@prize]
#IF
[COLOR=Red]CHECK [5] 1[/COLOR]
CHECKITEM Book
#ACT
TAKE Book
GIVE ExpPotion
SET [5] 1
#SAY
thank you <$USERNAME> you really helped me.\ \
<bye/@exit>
#ELSESAY
You have already done this quest <$USERNAME>

So basically, check 5 1, if they have that done then they have already done it, but it shouldn't be like that if you think about it. I can't seem to be able to explain it correctly though, I think
CHECK [5] 0
should work, that way if you haven't done the quest (and the flag is set at 0) it will goto the #ACT, whereas if you have done the quest (and it's set at 1) you will get the #ELSE, does anyone else get any sense of this?

Code:
[@prize]
 #IF
 [COLOR=Red]CHECK [5] 0[/COLOR]
 CHECKITEM Book
 #ACT
 TAKE Book
 GIVE ExpPotion
 SET [5] 1
 #SAY
 thank you <$USERNAME> you really helped me.\ \
 <bye/@exit>
 #ELSESAY
 You have already done this quest <$USERNAME>
 
Upvote 0

Neptune

Golden Oldie
Golden Oldie
Nov 19, 2003
1,473
9
175
Chester :P
no because if u have it to check [5] 0 that means its off, so it wont look for the [5] 1 (meaning on)

u can do the quest first time because u dont have the [5] 1 set on your body. if its set to [5] 0 (again meaning off) it will never check for [5] meaning u can still do it time and time again
 
Upvote 0

JealY

LOMCN VIP
VIP
Nov 28, 2004
5,357
55
335
England
If it checks for [5] 0, it means you have never done the quest, and lets you do it, then sets it 1 so you have done the quest.

Your character now has [5] 1, and clicks the npc again and can't, because they don't have [5] 0.

You start with all flags at 0, how could anyone do the quest if you get asked to be [5] 1 to do it?

Short from being a GM and setting it, I don't think anyone could get past that #IF.
 
Upvote 0

Neptune

Golden Oldie
Golden Oldie
Nov 19, 2003
1,473
9
175
Chester :P
TravisW has kinda got it set up the same way as what i did, just a bit more round the bush before it gets to the point lol
 
Upvote 0

JealY

LOMCN VIP
VIP
Nov 28, 2004
5,357
55
335
England
Yeah and if you look at his;

Code:
[@main]
#IF
CHECK [5] 1
#ACT
goto @cant

If 5 is set it means you have done the quest already, I hope your seeing my point i'm not just doing it to annoy ya, I help people. Even at times where I have college work to do! :D
 
Upvote 0

Neptune

Golden Oldie
Golden Oldie
Nov 19, 2003
1,473
9
175
Chester :P
i know ur not doing it to annoy me lol, anyways thats the way i normally do it, and not had a problem with it, but test it b4 u try it ^_^
 
Upvote 0

noisound

Golden Oldie
Golden Oldie
Jul 23, 2004
1,335
10
175
still can do quest without having the item, can sskip thru everything without giving the required items and just get prize for nowt lol. ne ideas

/dan
 
Upvote 0

Neptune

Golden Oldie
Golden Oldie
Nov 19, 2003
1,473
9
175
Chester :P
[@main]
#IF
CHECK [5] 1
CHECKLEVEL 30
#SAY
Help <$USERNAME>, My precious book was lost while\
i was hunting many years ago, please get it back?\
<Ill help, whats the name of this book/@items>\ <No/@exit>
#ELSESAY
you are too low <$USERNAME>

[@items]
The book is called "Book".\\
<I have your items/@prize>\ <i will go get your Book/@hurry>

[@hurry]
please hurry <$USERNAME> i will reward u kindly\ \
<Bye/@exit>

[@prize]
#IF
CHECKITEM Book 1
#ACT
TAKE Book 1
GIVE ExpPotion 1
SET [5] 1
#SAY
thank you <$USERNAME> you really helped me.\ \
<bye/@exit>
#ELSESAY
You have already done this quest <$USERNAME>

try this 1 m8
 
Upvote 0