[@main]
#IF
CHECK [150] 1
#ACT
goto @inst1
break
#IF
CHECK [152] 1
#ACT
goto @inst2
break
#IF
CHECK [153] 1
#ACT
goto @inst3
break
#IF
CHECK [154] 1
#ACT
goto @inst4
break
#IF
CHECK [155] 1
#ACT
goto @inst5
break
#ELSEACT
goto @main1

[@inst1]
#IF
CheckVar Human c1 >= 3000
#SAY
Well done <$USERNAME> you have sucssesfully completed the\
instance!\
\
\
<Collect your reward!/@rwd1>\ \
#ELSEACT
goto @fail

[@rwd1]
#ACT
DELNAMELIST ..\QuestDiary\Instance1\inst1d.txt
DELNAMELIST ..\QuestDiary\Instance1\2500.txt
DELNAMELIST ..\QuestDiary\Instance1\1500.txt
DELNAMELIST ..\QuestDiary\Instance1\1000.txt
DELNAMELIST ..\QuestDiary\Instance1\500.txt
SET [150] 0
CalcVar Human c1 = 0
give winneritem 1
#SAY
Enjoy your reward!\
<Close/@exit>\ \

[@fail]
#ACT
DELNAMELIST ..\QuestDiary\Instance1\2500.txt
DELNAMELIST ..\QuestDiary\Instance1\1500.txt
DELNAMELIST ..\QuestDiary\Instance1\1000.txt
DELNAMELIST ..\QuestDiary\Instance1\500.txt
SET [150] 0
CalcVar Human c1 = 0
give failureitem 1
#SAY
Too bad you did not get the required amount of points to complete it\
here is a failureitem anyway\
<Thanks/@exit>\ \

[@inst2]
#IF
CheckVar Human c2 >= 5000
#SAY
Well done <$USERNAME> you have sucssesfully completed the\
instance!\
\
\
<Collect your reward!/@rwd2>\ \
#ELSEACT
goto @fail1

[@rwd2]
#ACT
DELNAMELIST ..\QuestDiary\Instance2\inst1d.txt
DELNAMELIST ..\QuestDiary\Instance2\4000.txt
DELNAMELIST ..\QuestDiary\Instance2\2500.txt
DELNAMELIST ..\QuestDiary\Instance2\1000.txt
DELNAMELIST ..\QuestDiary\Instance2\500.txt
SET [152] 0
CalcVar Human c2 = 0
give winneritem 2
#SAY
Enjoy your reward!\
<Close/@exit>\ \

[@fail1]
#ACT
DELNAMELIST ..\QuestDiary\Instance2\4000.txt
DELNAMELIST ..\QuestDiary\Instance2\2500.txt
DELNAMELIST ..\QuestDiary\Instance2\1000.txt
DELNAMELIST ..\QuestDiary\Instance2\500.txt
SET [152] 0
CalcVar Human c2 = 0
give failureitem 2
#SAY
Too bad you did not get the required amount of points to complete it\
here is a failureitem anyway\
<Thanks/@exit>\ \

[@inst3]
#IF
CheckVar Human c3 >= 8000
#SAY
Well done <$USERNAME> you have sucssesfully completed the\
instance!\
\
\
<Collect your reward!/@rwd3>\ \
#ELSEACT
goto @fail2

[@rwd3]
#ACT
DELNAMELIST ..\QuestDiary\Instance3\inst1d.txt
DELNAMELIST ..\QuestDiary\Instance3\6500.txt
DELNAMELIST ..\QuestDiary\Instance3\4000.txt
DELNAMELIST ..\QuestDiary\Instance3\1000.txt
DELNAMELIST ..\QuestDiary\Instance3\500.txt
SET [153] 0
CalcVar Human c3 = 0
give winneritem 3
#SAY
Enjoy your reward!\
<Close/@exit>\ \

[@fail2]
#ACT
DELNAMELIST ..\QuestDiary\Instance3\6500.txt
DELNAMELIST ..\QuestDiary\Instance3\4000.txt
DELNAMELIST ..\QuestDiary\Instance3\1000.txt
DELNAMELIST ..\QuestDiary\Instance3\500.txt
SET [153] 0
CalcVar Human c3 = 0
give failureitem 2
#SAY
Too bad you did not get the required amount of points to complete it\
here is a failureitem anyway\
<Thanks/@exit>\ \

[@inst4]
#IF
CheckVar Human c4 >= 12000
#SAY
Well done <$USERNAME> you have sucssesfully completed the\
instance!\
\
\
<Collect your reward!/@rwd4>\ \
#ELSEACT
goto @fail3

[@rwd4]
#ACT
DELNAMELIST ..\QuestDiary\Instance4\inst1d.txt
DELNAMELIST ..\QuestDiary\Instance4\10000.txt
DELNAMELIST ..\QuestDiary\Instance4\6000.txt
DELNAMELIST ..\QuestDiary\Instance4\1000.txt
DELNAMELIST ..\QuestDiary\Instance4\500.txt
SET [154] 0
CalcVar Human c4 = 0
give winneritem 4
#SAY
Enjoy your reward!\
<Close/@exit>\ \

[@fail3]
#ACT
DELNAMELIST ..\QuestDiary\Instance4\10000.txt
DELNAMELIST ..\QuestDiary\Instance4\6000.txt
DELNAMELIST ..\QuestDiary\Instance4\1000.txt
DELNAMELIST ..\QuestDiary\Instance4\500.txt
SET [154] 0
CalcVar Human c4 = 0
give failureitem 2
#SAY
Too bad you did not get the required amount of points to complete it\
here is a failureitem anyway\
<Thanks/@exit>\ \

[@inst5]
#IF
CheckVar Human c5 >= 12000
#SAY
Well done <$USERNAME> you have sucssesfully completed the\
instance!\
\
\
<Collect your reward!/@rwd5>\ \
#ELSEACT
goto @fail4

[@rwd5]
#ACT
DELNAMELIST ..\QuestDiary\Instance5\inst1d.txt
DELNAMELIST ..\QuestDiary\Instance5\15000.txt
DELNAMELIST ..\QuestDiary\Instance5\10000.txt
DELNAMELIST ..\QuestDiary\Instance5\1000.txt
DELNAMELIST ..\QuestDiary\Instance5\500.txt
SET [155] 0
CalcVar Human c5 = 0
give winneritem 6
#SAY
Enjoy your reward!\
<Close/@exit>\ \

[@fail4]
#ACT
DELNAMELIST ..\QuestDiary\Instance5\15000.txt
DELNAMELIST ..\QuestDiary\Instance5\10000.txt
DELNAMELIST ..\QuestDiary\Instance5\1000.txt
DELNAMELIST ..\QuestDiary\Instance5\500.txt
SET [155] 0
CalcVar Human c5 = 0
give failureitem 3
#SAY
Too bad you did not get the required amount of points to complete it\
here is a failureitem anyway\
<Thanks/@exit>\ \

[@main1]
#IF
CHECKLEVELEX > 59
#ACT
Var Integer Human c5
goto @insta4
break
#IF
CHECKLEVELEX > 49
#ACT
Var Integer Human c4
goto @insta3
break
#IF
CHECKLEVELEX > 39
#ACT
Var Integer Human c3
goto @insta2
break
#IF
CHECKLEVELEX > 29
#ACT
Var Integer Human c2
goto @insta1
break
#IF
CHECKLEVELEX > 19
#ACT
Var Integer Human c1
goto @insta
break

[@info]
#SAY
An instance is an area that changes depending on your\
level, monsters health and damage are increased the higher\
level you are and the amount of points need'd goes higher also\
but the higher the instance the better the <rewards/@rewardli>\ 
<Ok thanks/@main1>\\

[@rewardli]
#SAY
Succsesful prize are as follows randomly:\
ItemName       and        Amount\
Item1                           xx\
Item2                           xx\
Item3                           xx\
Item4                           xx\
Item5                           xx\
<And if I fail?/@rewardfa>\
<Ok thanks/@main1>\ \   

[@rewardfa]
#SAY
Failure prize are as follows randomly:\
ItemName       and        Amount\
Item1                           xx\
Item2                           xx\
Item3                           xx\
<Ok thanks/@main1>\ \    

;#########Instance level 20-29########
[@insta]
#SAY
Hello <$USERNAME> would you like to take on the\
instance challange? <Yes/@chall1> <No thanks/@exit>\ 
<What is an instant challange?/@info>\ \

[@chall1]
#SAY
You must kill as many mobs as you can to earn 3,000 points\
in 25 minutes as soon as you enter the instance cave\
<Start/@start1> <Never mined/@exit>\ \

[@start1]
#IF
CHECKHUM inst1 1
#ACT
goto @start11
#ELSEACT
CalcVar Human c1 = 0
MAPMOVE inst1 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 3,000 points!"
close

[@start11]
#IF
CHECKHUM inst6 1
#ACT
goto @start12
#ELSEACT
CalcVar Human c1 = 0
MAPMOVE inst6 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 3,000 points!"
close

[@start12]
#IF
CHECKHUM inst11 1
#ACT
goto @start13
#ELSEACT
CalcVar Human c1 = 0
MAPMOVE inst11 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 3,000 points!"
close

[@start13]
#IF
CHECKHUM inst16 1
#ACT
goto @start14
#ELSEACT
CalcVar Human c1 = 0
MAPMOVE inst16 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 3,000 points!"
close

[@start14]
#IF
CHECKHUM inst21 1
#SAY
All maps are currently occupied please try later!
#ELSEACT
CalcVar Human c1 = 0
MAPMOVE inst21 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 3,000 points!"
close
#ELSESAY
All maps are currently occupied!\ \



;###########Instance 30-39########
[@insta1]
#SAY
Hello <$USERNAME> would you like to take on the\
instance challange? <Yes/@chall2> <No thanks/@exit>\ 
<What is an instant challange?/@info>\ \

[@chall2]
#SAY
You must kill as many mobs as you can to earn 5,000 points\
in 25 minutes as soon as you enter the instance cave\
<Start/@start2> <Never mined/@exit>\ \

[@start2]
#IF
CHECKHUM inst2 1
#ACT
goto @start111
#ELSEACT
CalcVar Human c2 = 0
MAPMOVE inst2 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 5,000 points!"
close

[@start111]
#IF
CHECKHUM inst7 1
#ACT
goto @start112
#ELSEACT
CalcVar Human c2 = 0
MAPMOVE inst7 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 5,000 points!"
close

[@start112]
#IF
CHECKHUM inst12 1
#ACT
goto @start113
#ELSEACT
CalcVar Human c2 = 0
MAPMOVE inst12 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 5,000 points!"
close

[@start113]
#IF
CHECKHUM inst17 1
#ACT
goto @start114
#ELSEACT
CalcVar Human c2 = 0
MAPMOVE inst17 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 5,000 points!"
close

[@start114]
#IF
CHECKHUM inst22 1
#SAY
All maps are currently occupied please try later!
#ELSEACT
CalcVar Human c2 = 0
MAPMOVE inst22 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 5,000 points!"
close
#ELSESAY
All maps are currently occupied!\ \

;############Instance level 40-49#############
[@insta2]
#SAY
Hello <$USERNAME> would you like to take on the\
instance challange? <Yes/@chall3> <No thanks/@exit>\ 
<What is an instant challange?/@info>\ \

[@chall3]
#SAY
You must kill as many mobs as you can to earn 8,000 points\
in 25 minutes as soon as you enter the instance cave\
<Start/@start3> <Never mined/@exit>\ \

[@start3]
#IF
CHECKHUM inst3 1
#ACT
goto @start111
#ELSEACT
CalcVar Human c3 = 0
MAPMOVE inst3 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 8,000 points!"
close

[@start111]
#IF
CHECKHUM inst8 1
#ACT
goto @start112
#ELSEACT
CalcVar Human c3 = 0
MAPMOVE inst8 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 8,000 points!"
close

[@start112]
#IF
CHECKHUM inst13 1
#ACT
goto @start113
#ELSEACT
CalcVar Human c3 = 0
MAPMOVE inst13 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 8,000 points!"
close

[@start113]
#IF
CHECKHUM inst18 1
#ACT
goto @start114
#ELSEACT
CalcVar Human c3 = 0
MAPMOVE inst18 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 8,000 points!"
close

[@start114]
#IF
CHECKHUM inst23 1
#SAY
All maps are currently occupied please try later!
#ELSEACT
CalcVar Human c3 = 0
MAPMOVE inst23 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 8,000 points!"
close
#ELSESAY
All maps are currently occupied!\ \

;############Instance level 50-59##############
[@insta3]
#SAY
Hello <$USERNAME> would you like to take on the\
instance challange? <Yes/@chall4> <No thanks/@exit>\ 
<What is an instant challange?/@info>\ \

[@chall4]
#SAY
You must kill as many mobs as you can to earn 12,000 points\
in 25 minutes as soon as you enter the instance cave\
<Start/@start4> <Never mined/@exit>\ \

[@start3]
#IF
CHECKHUM inst4 1
#ACT
goto @start1111
#ELSEACT
CalcVar Human c4 = 0
MAPMOVE inst4 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 12,000 points!"
close

[@start1111]
#IF
CHECKHUM inst9 1
#ACT
goto @start1112
#ELSEACT
CalcVar Human c4 = 0
MAPMOVE inst9 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 12,000 points!"
close

[@start1112]
#IF
CHECKHUM inst14 1
#ACT
goto @start1113
#ELSEACT
CalcVar Human c4 = 0
MAPMOVE inst14 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 12,000 points!"
close

[@start1113]
#IF
CHECKHUM inst19 1
#ACT
goto @start1114
#ELSEACT
CalcVar Human c4 = 0
MAPMOVE inst19 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 12,000 points!"
close

[@start1114]
#IF
CHECKHUM inst24 1
#SAY
All maps are currently occupied please try later!
#ELSEACT
CalcVar Human c4 = 0
MAPMOVE inst24 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 12,000 points!"
close
#ELSESAY
All maps are currently occupied!\ \

;###########Instance level 60+###############
[@insta4]
#SAY
Hello <$USERNAME> would you like to take on the\
instance challange? <Yes/@chall5> <No thanks/@exit>\ 
<What is an instant challange?/@info>\ \

[@chall5]
#SAY
You must kill as many mobs as you can to earn 20,000 points\
in 25 minutes as soon as you enter the instance cave\
<Start/@start5> <Never mined/@exit>\ \

[@start5]
#IF
CHECKHUM inst5 1
#ACT
goto @start11111
#ELSEACT
CalcVar Human c5 = 0
MAPMOVE inst5 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 20,000 points!"
close

[@start11111]
#IF
CHECKHUM inst10 1
#ACT
goto @start11112
#ELSEACT
CalcVar Human c5 = 0
MAPMOVE inst10 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 20,000 points!"
close

[@start11112]
#IF
CHECKHUM inst15 1
#ACT
goto @start11113
#ELSEACT
CalcVar Human c5 = 0
MAPMOVE inst15 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 20,000 points!"
close

[@start11113]
#IF
CHECKHUM inst20 1
#ACT
goto @start11114
#ELSEACT
CalcVar Human c5 = 0
MAPMOVE inst20 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 20,000 points!"
close

[@start11114]
#IF
CHECKHUM inst25 1
#SAY
All maps are currently occupied please try later!
#ELSEACT
CalcVar Human c5 = 0
MAPMOVE inst25 10 10
DELAYGOTO 2500000 @rex
sendmsg 6 "You have 25 minutes to earn 20,000 points!"
close
#ELSESAY
All maps are currently occupied!\ \

[@rex]
#ACT
MAPMOVE 0 329 269
break
