summaryrefslogtreecommitdiff
path: root/npc
diff options
context:
space:
mode:
Diffstat (limited to 'npc')
-rw-r--r--npc/007-1_Woodland/_import.txt1
-rw-r--r--npc/007-1_Woodland/voltain.txt363
-rw-r--r--npc/009-2_Hurnscald/_import.txt1
-rw-r--r--npc/009-2_Hurnscald/lena.txt105
-rw-r--r--npc/009-2_Hurnscald/peter.txt6
-rw-r--r--npc/009-4/_import.txt7
-rw-r--r--npc/009-4/_mobs.txt29
-rw-r--r--npc/009-4/_warps.txt46
-rw-r--r--npc/009-4/barriers.txt229
-rw-r--r--npc/009-4/orum.txt652
-rw-r--r--npc/009-4/torches.txt358
-rw-r--r--npc/009-4/waric.txt95
-rw-r--r--npc/011-1_Woodland/_warps.txt1
-rw-r--r--npc/011-4_Lake_cave/_import.txt1
-rw-r--r--npc/011-4_Lake_cave/_warps.txt9
-rw-r--r--npc/011-4_Lake_cave/bl_barrier.txt16
-rw-r--r--npc/011-6/_import.txt4
-rw-r--r--npc/011-6/_mobs.txt31
-rw-r--r--npc/011-6/_warps.txt25
-rw-r--r--npc/011-6/bryant.txt53
-rw-r--r--npc/012-3_Cave/_import.txt1
-rw-r--r--npc/012-3_Cave/warningsigns.txt18
-rw-r--r--npc/019-1_Snow_field/_warps.txt3
-rw-r--r--npc/019-3_Snow_field/_import.txt3
-rw-r--r--npc/019-3_Snow_field/_mobs.txt7
-rw-r--r--npc/019-3_Snow_field/_warps.txt4
-rwxr-xr-xnpc/020-1_Nivalis/KrickKrackKrock.txt109
-rw-r--r--npc/020-1_Nivalis/_import.txt4
-rw-r--r--npc/020-1_Nivalis/_warps.txt2
-rw-r--r--npc/020-1_Nivalis/mapflags.txt9
-rwxr-xr-xnpc/020-1_Nivalis/rockscissor.txt89
-rw-r--r--npc/020-1_Nivalis/startrek.txt20
-rwxr-xr-xnpc/020-1_Nivalis/well.txt117
-rw-r--r--npc/020-2_Nivalis/_import.txt2
-rwxr-xr-xnpc/020-2_Nivalis/baktar.txt389
-rw-r--r--npc/020-2_Nivalis/shops.txt8
-rw-r--r--npc/020-3_Ice_cave/_warps.txt7
-rw-r--r--npc/027-3/_import.txt3
-rw-r--r--npc/027-3/_mobs.txt7
-rw-r--r--npc/027-3/_warps.txt4
-rw-r--r--npc/030-1_Snow_field/_import.txt3
-rw-r--r--npc/030-1_Snow_field/_mobs.txt7
-rw-r--r--npc/030-1_Snow_field/_warps.txt3
-rw-r--r--npc/031-1_NivalisPort/_import.txt3
-rw-r--r--npc/031-1_NivalisPort/_mobs.txt7
-rw-r--r--npc/031-1_NivalisPort/_warps.txt4
-rw-r--r--npc/031-3/_import.txt4
-rw-r--r--npc/031-3/_mobs.txt7
-rw-r--r--npc/031-3/_warps.txt3
-rw-r--r--npc/031-3/labyrinth.txt342
-rw-r--r--npc/_import.txt8
-rw-r--r--npc/scripts.conf3
-rw-r--r--npc/xmas/2010/_import.txt2
-rw-r--r--npc/xmas/2010/golbanez.txt194
-rw-r--r--npc/xmas/2010/santa.txt160
55 files changed, 3551 insertions, 37 deletions
diff --git a/npc/007-1_Woodland/_import.txt b/npc/007-1_Woodland/_import.txt
index 0b239a93..717c476b 100644
--- a/npc/007-1_Woodland/_import.txt
+++ b/npc/007-1_Woodland/_import.txt
@@ -1,3 +1,4 @@
map: 007-1.gat
npc: npc/007-1_Woodland/_mobs.txt
npc: npc/007-1_Woodland/_warps.txt
+npc: npc/007-1_Woodland/voltain.txt
diff --git a/npc/007-1_Woodland/voltain.txt b/npc/007-1_Woodland/voltain.txt
new file mode 100644
index 00000000..76e49f1b
--- /dev/null
+++ b/npc/007-1_Woodland/voltain.txt
@@ -0,0 +1,363 @@
+// # NPC Name: Voltain
+// # LEAD AUTHOR: Pjotr Orial
+// # AUTHORS: MrDudle, tarq, Salmondine, Jenalya, Pjotr Orial
+// # REVIEWERS: Jenalya
+// #
+// # Basic Idea: A Person with lots of dark minds requires different stuff.
+// # Basically he tries to figure out, how to poison moobous, since he doesn't like the nature at all
+// #
+// # The variables are not attached to a player but to an npc variable, so it is more or less random, which
+// # quest comes up, when a player asks him.
+// #
+// # used Variables: global variable $state
+// # $state = 0: bring bottles
+// # $state = 1: bring black scorpion stinger
+// # $state = 2: bring bug legs
+// # $state = 3: bring another black scorpion stinger
+// # $state = 4: bring mauve herbs
+// # $state = 5: bring raw logs
+// # $state = 6: bring red apples
+// # $state = 7: bring cobalt herbs
+// # $state = 8: bring snake tongues
+// # $state = 9: bring alizarin herbs
+// # $state = 10:bring steak
+// # $state = 11: bring arrows
+// # $state = 12: bring gamboge herbs
+// # $state = 13 bring chocolate cake
+
+007-1.gat,37,21,0 script Voltain 103, {
+
+set @BOTTLE_NEEDED, 3;
+set @BOTTLE_REWARD_XP, 100;
+set @BOTTLE_REWARD_GOLD, 450;
+
+set @BLACK_SC_ST_NEEDED, 5;
+set @BLACK_SC_ST_REWARD_XP, 500;
+set @BLACK_SC_ST_REWARD_GOLD, 250;
+
+set @BUGLEG_NEEDED, 10;
+set @BUGLEG_REWARD_XP, 200;
+set @BUGLEG_REWARD_GOLD, 150;
+
+set @HERBS_NEEDED, 7;
+set @HERBS_REWARD_XP, 200;
+set @HERBS_REWARD_GOLD, 250;
+
+set @RAWLOG_NEEDED, 5;
+set @RAWLOG_REWARD_XP, 330;
+set @RAWLOG_REWARD_GOLD, 300;
+
+set @REDAPPLE_NEEDED, 7;
+set @REDAPPLE_REWARD_XP, 330;
+set @REDAPPLE_REWARD_GOLD, 300;
+
+set @STEAK_NEEDED, 2;
+set @STEAK_REWARD_XP, 330;
+set @STEAK_REWARD_GOLD, 280;
+
+set @ARROW_NEEDED, 25;
+set @ARROW_REWARD_XP, 330;
+set @ARROW_REWARD_GOLD, 100;
+
+set @SNAKETONGUE_NEEDED, 3;
+set @SNAKETONGUE_REWARD_XP, 330;
+set @SNAKETONGUE_REWARD_GOLD, 100;
+
+set @CHOCOLATECAKE_NEEDED, 3;
+set @CHOCOLATECAKE_REWARD_XP, 330;
+set @CHOCOLATECAKE_REWARD_GOLD, 180;
+
+if ($state == 1) goto state1;
+if ($state == 2) goto state2;
+if ($state == 3) goto state3;
+if ($state == 4) goto state4;
+if ($state == 5) goto state5;
+if ($state == 6) goto state6;
+if ($state == 7) goto state7;
+if ($state == 8) goto state8;
+if ($state == 9) goto state9;
+if ($state == 10) goto state10;
+if ($state == 11) goto state11;
+if ($state == 12) goto state12;
+if ($state == 13) goto state13;
+// default: trap through to state0!
+
+state0:
+mes "[Voltain]";
+mes "\"What are you doing bothering me? Can't you see I'm busy! Oh, I'm sorry, I thought you were my assistant. Never mind that... would you care to help me?\"";
+next;
+
+menu
+ "Sure I do!", -,
+ "No, you creep me out.", L_NOHELP;
+
+mes "[Voltain]";
+mes "\"I'm working on a very special potion. I need some empty bottles to keep the ingredients in. Care to go find me " + @BOTTLE_NEEDED + " empty bottles?!\"";
+next;
+
+menu
+ "I've got the bottles.", -,
+ "I don't feel like helping you get garbage...", L_CLOSE;
+
+if (countitem("EmptyBottle") < @BOTTLE_NEEDED) goto L_NOT_ENOUGH;
+ delitem "EmptyBottle", @BOTTLE_NEEDED;
+ set zeny, zeny + @BOTTLE_REWARD_GOLD;
+ getexp @BOTTLE_REWARD_XP, 0;
+ set $state, 1;
+ mes "\"Thanks for the bottles. Much easier to carry liquid in them.\"";
+ close;
+
+state1:
+mes "[Voltain]";
+mes "\"I'm making a potion that requires lots of venom. I'm in need of " + @BLACK_SC_ST_NEEDED + " black scorpion stingers.\"";
+next;
+
+menu
+ "I've got the stingers!", -,
+ "I'll go search for the them.", L_CLOSE;
+
+mes "[Voltain]";
+ if (countitem("BlackScorpionStinger") < @BLACK_SC_ST_NEEDED) goto L_NOT_ENOUGH;
+ delitem "BlackScorpionStinger", @BLACK_SC_ST_NEEDED;
+ set zeny, zeny + @BLACK_SC_ST_REWARD_GOLD;
+ getexp @BLACK_SC_ST_REWARD_XP, 0;
+ set $state, 2;
+ mes "\"Well, since you went to the trouble of getting me these here's a little something for your time...\"";
+ close;
+
+
+state2:
+mes "[Voltain]";
+mes "\"Care to to help me with my potion? I need " + @BUGLEG_NEEDED + " bug legs so that I can thicken the potion.\"";
+next;
+
+menu
+ "I've got the bug legs.", -,
+ "I'd rather not carry around dead bugs for you.", L_NOHELP ;
+
+mes "[Voltain]";
+ if (countitem("BugLeg") < @BUGLEG_NEEDED) goto L_NOT_ENOUGH;
+ delitem "BugLeg", @BUGLEG_NEEDED;
+ set zeny, zeny + @BUGLEG_REWARD_GOLD;
+ getexp @BUGLEG_REWARD_XP, 0;
+ set $state, 3;
+ mes "\"Great! My potion is ready to poison the moub...I mean cure scorpion stings. \"";
+ close;
+
+state3:
+mes "[Voltain]";
+mes "\"I find myself in need of a black scorpion stinger... Damn mouboo are hard to kill...forget you heard that.\"";
+next;
+
+menu
+ "Here's the stinger.", -,
+ "I DID HEAR THAT! I will not help you KILL mouboo!", L_CLOSE;
+
+mes "[Voltain]";
+ if (countitem("BlackScorpionStinger") < 1) goto L_NOT_ENOUGH;
+ delitem "BlackScorpionStinger", 1;
+ getexp @BLACK_SC_ST_REWARD_XP, 0;
+ set $state, 0;
+ mes "\"Great! Now I can really kill that monster!\"";
+ close;
+
+state4:
+mes "[Voltain]";
+mes "\"I need to thicken a veno.. Oh a potion actually. I want to try mauve herbs for that, so can you bring me " + @HERBS_NEEDED + ", please?\"";
+next;
+
+menu
+ "Here are the herbs.", -,
+ "So you want to do a venom? I will not help you!", L_CLOSE;
+
+mes "[Voltain]";
+ if (countitem("MauveHerb") < @HERBS_NEEDED) goto L_NOT_ENOUGH;
+ delitem "MauveHerb", @HERBS_NEEDED;
+ getexp @HERBS_REWARD_XP, 0;
+ set zeny, zeny + @HERBS_REWARD_GOLD;
+ set $state, 5;
+ mes "\"Great! Now I can thicken the potion! I will try directly.\"";
+ close;
+
+
+state5:
+mes "[Voltain]";
+mes "\"Hello I am looking for " + @RAWLOG_NEEDED + " raw logs, maybe you could help me, getting some? I want to try if i can build a mouboo trap.. Uhm actually no! I want to build a device to destroy these traps. So can you help me?\"";
+next;
+
+menu
+ "Here are the raw logs.", -,
+ "So you want build traps for mouboos? NO WAY!", L_CLOSE;
+
+mes "[Voltain]";
+ if (countitem("RawLog") < @RAWLOG_NEEDED) goto L_NOT_ENOUGH;
+ delitem "RawLog", @RAWLOG_NEEDED;
+ getexp @RAWLOG_REWARD_XP, 0;
+ set zeny, zeny + @RAWLOG_REWARD_GOLD;
+ set $state, 6;
+ mes "\"Great! Now I can thicken the potion! I will try directly.\"";
+ close;
+
+state6:
+mes "[Voltain]";
+mes "\"Hello I am looking for " + @REDAPPLE_NEEDED + " red apples, maybe I can inject some venoms.. DOH not this again! Of course I meant a strength potion. Did you hear about the new potions from Caul? He is a pretty good alchimist. He can do strength potions, can't he?\"";
+next;
+
+menu
+ "Here are the red apples.", -,
+ "I am not sure...", L_CLOSE;
+
+mes "[Voltain]";
+ if (countitem("RedApple") < @REDAPPLE_NEEDED) goto L_NOT_ENOUGH;
+ delitem "RedApple", @REDAPPLE_NEEDED;
+ getexp @REDAPPLE_REWARD_XP, 0;
+ set zeny, zeny + @REDAPPLE_REWARD_GOLD;
+ set $state,7;
+ mes "\"Very well, this will be useful.\"";
+ close;
+
+state7:
+mes "[Voltain]";
+mes "\"I need to thicken a veno.. Oh a potion actually. Cobalt herbs might be good for that, so can you bring me " + @HERBS_NEEDED + ", please?\"";
+next;
+
+menu
+ "Here are the herbs.", -,
+ "So you want to do a venom? I will not help you!", L_CLOSE;
+
+mes "[Voltain]";
+ if (countitem("CobaltHerb") < @HERBS_NEEDED) goto L_NOT_ENOUGH;
+ delitem "CobaltHerb", @HERBS_NEEDED;
+ getexp @HERBS_REWARD_XP, 0;
+ set zeny, zeny + @HERBS_REWARD_GOLD;
+ set $state, 8;
+ mes "\"Great! Now I can go on with the ven- the experiments for the welfare of humanity, i mean.\"";
+ close;
+
+state8:
+mes "[Voltain]";
+mes "\"I am in need of snake tongues. They can help me getting very strong venom extracts. So I would like you to bring me " + @SNAKETONGUE_NEEDED + " snake tongues.\"";
+next;
+
+menu
+ "Sure, here you go!", -,
+ "Maybe you will find someone else, I got stuff to do on my own!", L_CLOSE;
+
+mes "[Voltain]";
+ if (countitem("SnakeTounge") < @SNAKETONGUE_NEEDED) goto L_NOT_ENOUGH;
+ delitem "SnakeTounge", @SNAKETONGUE_NEEDED;
+ getexp @SNAKETONGUE_REWARD_XP, 0;
+ set zeny, zeny + @SNAKETONGUE_REWARD_GOLD;
+ set $state, 9;
+ mes "\"Excellent, now I can extract the venom to- uhm, nevermind, thanks for your help.\"";
+ close;
+
+state9:
+mes "[Voltain]";
+mes "\"I need to thicken a veno.. Oh a potion actually. I want to try alizarin herbs for that, so can you bring me " + @HERBS_NEEDED + ", please?\"";
+next;
+
+menu
+ "Here are the herbs.", -,
+ "So you want to do a venom? I will not help you!", L_CLOSE;
+
+mes "[Voltain]";
+ if (countitem("AlizarinHerb") < @HERBS_NEEDED) goto L_NOT_ENOUGH;
+ delitem "AlizarinHerb", @HERBS_NEEDED;
+ getexp @HERBS_REWARD_XP, 0;
+ set zeny, zeny + @HERBS_REWARD_GOLD;
+ set $state, 10;
+ mes "\"Great! Now I can thicken the potion! I will try directly.\"";
+ close;
+
+state10:
+mes "[Voltain]";
+mes "\"Oh I am hungry. Maybe I can eat some steaks. Could you bring me a steak, please?\"";
+next;
+mes "\"Oh, I just wonder, if i can inject some ven... Forget about that! Bring me " + @STEAK_NEEDED + "steaks!\"";
+next;
+
+menu
+ "Here you go.", -,
+ "Help yourself! In the Hurnscald Inn you get some meal for sure!", L_CLOSE;
+
+mes "[Voltain]";
+ if (countitem("Steak") < @STEAK_NEEDED) goto L_NOT_ENOUGH;
+ delitem "Steak", @STEAK_NEEDED;
+ getexp @STEAK_REWARD_XP, 0;
+ set zeny, zeny + @STEAK_REWARD_GOLD;
+ set $state, 11;
+ mes "\"Thanks a lot. I will really enjoy my meal.\"";
+ close;
+
+state11:
+mes "[Voltain]";
+mes "\"Could I have some arrows please? I have lost my hunting equipment when I was in the caves. Some dark creatures were chasing me!\"";
+next;
+mes "\"Acually I wonder if I can use these arrows for building a mouboo trap.... Oh wait! I need some" + @ARROW_NEEDED + " arrows for my self defence right? So do not talk about it!\"";
+
+menu
+ "Here you go.", -,
+ "Sorry I don't have arrows here!", L_CLOSE;
+
+mes "[Voltain]";
+ if (countitem("Arrow") < @ARROW_NEEDED) goto L_NOT_ENOUGH;
+ delitem "Arrow", @ARROW_NEEDED;
+ getexp @ARROW_REWARD_XP, 0;
+ set zeny, zeny + @ARROW_REWARD_GOLD;
+ set $state, 12;
+ mes "\"Thanks a lot. Now I feel more secure here in outdoors.\"";
+ close;
+
+state12:
+mes "[Voltain]";
+mes "\"I need to thicken a veno.. Oh a potion actually. I want to try gamboge herbs for that, so can you bring me " + @HERBS_NEEDED + ", please?\"";
+next;
+
+menu
+ "Here are the herbs.", -,
+ "So you want to do a venom? I will not help you!", L_CLOSE;
+
+mes "[Voltain]";
+ if (countitem("GambogeHerb") < @HERBS_NEEDED) goto L_NOT_ENOUGH;
+ delitem "GambogeHerb", @HERBS_NEEDED;
+ getexp @HERBS_REWARD_XP, 0;
+ set zeny, zeny + @HERBS_REWARD_GOLD;
+ set $state, 13;
+ mes "\"Great! Now I can thicken the potion! I will try directly.\"";
+ close;
+
+state13:
+mes "[Voltain]";
+mes "\"Doing so many ev- good things makes me hungry. I feel in the mood for a Chocolate Cake. Can you bring me " + @CHOCOLATECAKE_NEEDED + " , please? \"";
+next;
+
+menu
+ "Here it is.", -,
+ "I don't feel in the mood to bring you a cake.", L_CLOSE;
+
+mes "[Voltain]";
+ if (countitem("ChocolateCake") < @CHOCOLATECAKE_NEEDED) goto L_NOT_ENOUGH;
+ delitem "ChocolateCake", @CHOCOLATECAKE_NEEDED;
+ getexp @CHOCOLATECAKE_REWARD_XP, 0;
+ set zeny, zeny + @CHOCOLATECAKE_REWARD_GOLD;
+ set $state, 0;
+ mes "\"I love chocolate cakes. I wonder, if I can use my ven- \"";
+ emotion 5;
+ close;
+
+L_NOHELP:
+mes "\"If you don't want to help me, then away with you. Bothering me won't help me get my work done.\"";
+mes "Voltain than mumbles something under his breath that you cannot quite make out";
+mes "\"... These damn kids. \"";
+close;
+
+L_CLOSE:
+close;
+
+L_NOT_ENOUGH:
+mes "\"Can't you count!? I need more. \"";
+close;
+}
+
+
diff --git a/npc/009-2_Hurnscald/_import.txt b/npc/009-2_Hurnscald/_import.txt
index 25d4868d..1ee969c2 100644
--- a/npc/009-2_Hurnscald/_import.txt
+++ b/npc/009-2_Hurnscald/_import.txt
@@ -7,6 +7,7 @@ npc: npc/009-2_Hurnscald/doctor.txt
npc: npc/009-2_Hurnscald/drunks.txt
npc: npc/009-2_Hurnscald/inspector.txt
npc: npc/009-2_Hurnscald/kfahr.txt
+npc: npc/009-2_Hurnscald/lena.txt
npc: npc/009-2_Hurnscald/mapflags.txt
npc: npc/009-2_Hurnscald/misc.txt
npc: npc/009-2_Hurnscald/nicholas.txt
diff --git a/npc/009-2_Hurnscald/lena.txt b/npc/009-2_Hurnscald/lena.txt
new file mode 100644
index 00000000..a88da8da
--- /dev/null
+++ b/npc/009-2_Hurnscald/lena.txt
@@ -0,0 +1,105 @@
+// Quest for Fairy Hat and Forest Armor
+
+009-2.gat,146,43,0 script Lena 182,{
+
+ if (TMW_Quest >= 46) goto L_Lena_Done;
+ if (TMW_Quest == 45) goto L_Lena_Success;
+ if (TMW_Quest == 44) goto L_Lena_Bandit_Leader_Fail;
+ if (TMW_Quest == 43) goto L_Lena_Bandit_Leader_Fail;
+ if (TMW_Quest == 42) goto L_Lena_Bandit_Leader;
+ if (TMW_Quest == 41) goto L_Lena_Fairy_Hat;
+ if (TMW_Quest == 40) && (baselevel >= 30) goto L_Lena_Start;
+
+ mes "[Lena]";
+ mes "\"I got ambushed by a group of bandits and one of them stabbed me pretty good. Hopefully I heal up soon so I can fight this menace.\"";
+ close;
+
+L_Lena_Start:
+ mes "[Lena]";
+ mes "\"While wandering through the forest, I was ambushed by bandits. Though I got them all, one of them stabbed me pretty good. I'm still healing from that encounter. I'm worried that the bandit threat may spread.\"";
+ menu
+ "Don't worry, I can take out some of these scumbags.", L_Lena_Approves,
+ "I think I left my courage in another pair of pants. See you later!", L_Lena_No_Fan;
+ close;
+
+L_Lena_Approves:
+ set TMW_Quest, 41;
+ mes "[Lena]";
+ mes "\"You look like you can handle yourself in a fight. If you can take on this scourge I'll reward you with a hat like mine. In order to prove your mettle, bring me 10 [Bandit Hood]s so I know they've met their match.\"";
+ areamonster "008-1.gat",25,60,40,65,"Bandit",1063,3, "::";
+ areamonster "011-1.gat",35,40,65,60,"Bandit",1063,3, "::";
+ close;
+
+L_Lena_No_Fan:
+ mes "[Lena]";
+ mes "\"What will Hurnscald do if these bandits overrun the town? I hope you reconsider.\"";
+ close;
+
+L_Lena_Fairy_Hat:
+ if (countitem("BanditHood") < 10) goto L_Lena_NotEnough;
+ getinventorylist;
+ if (@inventorylist_count - (countitem("BanditHood")== 10) > 99) goto L_TooMany;
+ set TMW_Quest, 42;
+ delitem "BanditHood", 10;
+ getitem "FairyHat", 1;
+ mes "[Lena]";
+ mes "\"Ah, you've brought me the [Bandit Hood]s. As promised, here is a hat like mine.\"";
+ next;
+ mes "\"Unfortunately, I feel this bandit threat may of grown. Perhaps they are being lead? I noticed many of them seem to hang around a cave just west of Hurnscald. If you could defeat their leader I know they will become less of a threat to Hurnscald. I'll reward you with armor like mine if you do. Sound like something you could do?\"";
+ menu
+ "Consider it done!", L_Lena_Bandit_Leader_Yes,
+ "Woah there, that sounds a bit harder than what I can suceed at.", L_Lena_NoWay;
+ close;
+
+L_Lena_NotEnough:
+ mes "[Lena]";
+ mes "\"You don't have enough [Bandit Hood]s to prove you are taking care of this threat. Please come back with 10 [Bandit Hood]s to show you are taking care of these bandits.\"";
+ close;
+
+L_Lena_Bandit_Leader:
+ mes "[Lena]";
+ mes "\"I feel this bandit threat may of grown. Perhaps they are being lead? I noticed many of them seem to hang around a cave just west of Hurnscald. If you could defeat their leader I know they will become less of a threat to Hurnscald. I'll reward you with armor like mine if you do. Sound like something you could do?\"";
+ menu
+ "Consider it done!", L_Lena_Bandit_Leader_Yes,
+ "Woah there, that sounds a bit harder than what I can succeed at.", L_Lena_NoWay;
+ close;
+
+L_Lena_Bandit_Leader_Yes:
+ set TMW_Quest, 43;
+ areamonster "008-1.gat",25,60,40,65,"Bandit",1063,3, "::";
+ areamonster "011-1.gat",35,40,65,60,"Bandit",1063,3, "::";
+ mes "[Lena]";
+ mes "\"You have a brave heart. Though I know you can suceed on your own, I recommend finding others to help you defeat the bandit leader. I believe he could pose a significant threat to solitary individuals seeking to challenge him. Good luck!\"";
+ close;
+
+L_Lena_NoWay:
+ mes "[Lena]";
+ mes "\"That is too bad. Feel free to return at any time. This bandit threat needs to be pushed back.\"";
+ close;
+
+L_Lena_Bandit_Leader_Fail:
+ set TMW_Quest, 43;
+ mes "[Lena]";
+ mes "\"You haven't killed the bandit leader yet. This is a big problem. Please be careful.\"";
+ close;
+
+L_Lena_Success:
+ getinventorylist;
+ if (@inventorylist_count == 100) goto L_TooMany;
+ set TMW_Quest, 46;
+ getitem "ForestArmor", 1;
+ mes "[Lena]";
+ mes "\"Excellent! You killed the bandit leader. Here is the armor as I promised you. Safe journeys!\"";
+ close;
+
+L_Lena_Done:
+ mes "[Lena]";
+ mes "\"Thank you for all your help. With your efforts, we can only hope this scourge doesn't see a resurgence.\"";
+ close;
+
+L_TooMany:
+ mes "[Lena]";
+ mes "\"You have too many items in your inventory. Please get rid of something so I can reward you.\"";
+ close;
+
+}
diff --git a/npc/009-2_Hurnscald/peter.txt b/npc/009-2_Hurnscald/peter.txt
index 85e31dc9..995bfc31 100644
--- a/npc/009-2_Hurnscald/peter.txt
+++ b/npc/009-2_Hurnscald/peter.txt
@@ -30,26 +30,28 @@ L_Peter_Chain_Mail:
close;
L_Peter_Light_Plate:
- if (zeny < 20000) goto L_Peter_NotEnough_Zeny;
+ if (zeny < 50000) goto L_Peter_NotEnough_Zeny;
if (countitem("IngotIron") < 10) goto L_Peter_NotEnough_Ingot;
if (countitem("Coal") < 20) goto L_Peter_NotEnough_Coal;
getinventorylist;
if (@inventorylist_count == 100) goto L_Peter_TooMany;
set zeny, zeny - 50000;
delitem "IngotIron", 10;
+ delitem "Coal", 20;
getitem "LightPlatemail", 1;
mes "[Peter]";
mes "\"Here you go!\"";
close;
L_Peter_Warlord_Plate:
- if (zeny < 20000) goto L_Peter_NotEnough_Zeny;
+ if (zeny < 100000) goto L_Peter_NotEnough_Zeny;
if (countitem("IngotIron") < 15) goto L_Peter_NotEnough_Ingot;
if (countitem("Coal") < 30) goto L_Peter_NotEnough_Coal;
getinventorylist;
if (@inventorylist_count == 100) goto L_Peter_TooMany;
set zeny, zeny - 100000;
delitem "IngotIron", 15;
+ delitem "Coal", 30;
getitem "WarlordPlate", 1;
mes "[Peter]";
mes "\"Here you go!\"";
diff --git a/npc/009-4/_import.txt b/npc/009-4/_import.txt
new file mode 100644
index 00000000..0af62468
--- /dev/null
+++ b/npc/009-4/_import.txt
@@ -0,0 +1,7 @@
+map: 009-4.gat
+npc: npc/009-4/_mobs.txt
+npc: npc/009-4/_warps.txt
+npc: npc/009-4/barriers.txt
+npc: npc/009-4/orum.txt
+npc: npc/009-4/torches.txt
+npc: npc/009-4/waric.txt
diff --git a/npc/009-4/_mobs.txt b/npc/009-4/_mobs.txt
new file mode 100644
index 00000000..71cf010f
--- /dev/null
+++ b/npc/009-4/_mobs.txt
@@ -0,0 +1,29 @@
+// 009-4 Cave mobs
+// # see detailed description at orum.txt
+// Cavern
+009-4.gat,107,88,19,28 monster Silkworm 1035,3,20000,14000,Mob009-4::OnSilkworm
+009-4.gat,107,88,19,28 monster Cave Snake 1021,5,20000,14000,Mob009-4::OnCaveSnake
+
+009-4.gat,119,45,5,3 monster Silkworm 1035,3,20000,14000,Mob009-4::OnSilkworm
+009-4.gat,103,28,6,4 monster Cave Snake 1021,3,20000,14000,Mob009-4::OnCaveSnake
+009-4.gat,103,28,6,4 monster Silkworm 1035,2,20000,14000,Mob009-4::OnSilkworm
+
+009-4.gat,36,117,4,4 monster Maggot 1002,3,20000,14000,Mob009-4::OnMaggot
+009-4.gat,71,130,4,4 monster Maggot 1002,3,20000,14000,Mob009-4::OnMaggot
+
+009-4.gat,0,0,0 script Mob009-4 -1,{
+OnCaveSnake:
+ set @mobID, 1021;
+ callfunc "MobPoints";
+ break;
+OnMaggot:
+ set @mobID, 1002;
+ callfunc "MobPoints";
+ break;
+OnSilkworm:
+ set @mobID, 1035;
+ callfunc "MobPoints";
+ break;
+
+ end;
+}
diff --git a/npc/009-4/_warps.txt b/npc/009-4/_warps.txt
new file mode 100644
index 00000000..f7c99ff0
--- /dev/null
+++ b/npc/009-4/_warps.txt
@@ -0,0 +1,46 @@
+// 009-4 Cave Warps
+
+// Entrances
+009-4.gat,37,112 warp to Outside -1,-1,009-3.gat,162,114
+009-4.gat,37,123 warp to Lair -1,-1,009-4.gat,36,27
+
+009-4.gat,72,125 warp to Outside -1,-1,009-3.gat,162,114
+009-4.gat,72,136 warp to Lair -1,-1,009-4.gat,36,27
+
+// Caverns
+009-4.gat,103,22 warp to Lair -1,-1,009-4.gat,51,46
+009-4.gat,103,76 warp to Lair -1,-1,009-4.gat,51,46
+
+009-3.gat,162,113,0 script #OrumQuestEnter 0,0,0,{
+ if (OrumQuest >= 12) goto L_Second_Entrance;
+ warp "009-4.gat", 37, 113;
+ close;
+
+L_Second_Entrance:
+ warp "009-4.gat", 72, 126;
+ close;
+}
+009-4.gat,36,26,0 script #LairExit 0,0,0,{
+ if (OrumQuest >= 12) goto L_Second_Entrance;
+ warp "009-4.gat", 37, 122;
+ close;
+
+L_Second_Entrance:
+ warp "009-4.gat", 72, 135;
+ close;
+}
+
+009-4.gat,51,47,0 script #CavernEnter 0,0,0,{
+ if (OrumQuest >= 14) goto L_Second_Cavern;
+ if (OrumQuest < 12) goto L_See_Orum;
+ warp "009-4.gat", 103, 23;
+ close;
+
+L_Second_Cavern:
+ warp "009-4.gat", 103, 77;
+ close;
+
+L_See_Orum:
+ mes "Right as you are entering you hear Orum call out for you.. Perhaps you should see what he wants first..";
+ close;
+}
diff --git a/npc/009-4/barriers.txt b/npc/009-4/barriers.txt
new file mode 100644
index 00000000..0185a2fd
--- /dev/null
+++ b/npc/009-4/barriers.txt
@@ -0,0 +1,229 @@
+//# see detailed description at orum.txt
+function script GetBarrierColor {
+ if (@Barrier < 0 || @Barrier > 2) goto L_Error;
+
+ set @Mask, 15;
+ set @Shift, 4 * @Barrier;
+ set @BarrierColor, (OrumQuestBarrier >> @Shift) & @Mask;
+ return;
+
+L_Error:
+ mes "Barrier number is out of range.";
+ close;
+}
+
+function script SetBarrierColor {
+ if (@Barrier < 0 || @Barrier > 2) goto L_Error;
+ if (@Color < 0 || @Color > 12) goto L_Error2;
+
+ set @Mask, (15 << (4 * @Barrier));
+ set OrumQuestBarrier, (OrumQuestBarrier & (~(@Mask))) | @Color << (4 * @Barrier);
+ return;
+
+L_Error:
+ mes "Barrier number is out of range.";
+ close;
+
+L_Error2:
+ mes "Barrier color is out of range.";
+ close;
+}
+
+
+// Starting Barrier / Quest Entrance
+009-4.gat,37,120,0 script #OrumCaveStartBarrier 0,1,0,{
+
+ if (OrumQuest >= 3) close;
+ if (OrumQuest == 2) goto L_Started;
+
+ warp "009-4.gat", 37, 118;
+ mes "As you try to pass, two torches begin to flare and push you back. They seem to form some kind of barrier..";
+ close;
+
+L_Started:
+ message strcharinfo(0), "The torches dim as you approach, granting you passage.";
+ set OrumQuest, 3;
+ close;
+}
+
+// First Barrier
+009-4.gat,57,29,0 script #OrumCaveFirstBarrier 0,1,0,{
+
+ if (OrumQuest >= 5) close;
+
+ message strcharinfo(0), "Nothing seems to happen as you enter this room.. The barrier must need both of its torches to function properly..";
+ set OrumQuest, 5;
+ close;
+}
+
+// Second Barrier
+009-4.gat,61,54,0 script #OrumCaveSecondBarrier 0,1,0,{
+
+ if (OrumQuest == 3) set OrumQuest, 4;
+
+ set @Barrier, 0;
+ callfunc("GetBarrierColor");
+ set @Torch, 0;
+ callfunc("GetTorchColor");
+ if (OrumQuest > 7 && @TorchColor == @BarrierColor) goto L_Allow_Second_Passage;
+
+ warp "009-4.gat", 61, 56;
+ mes "As you try to pass, the torches begin to flare and push you back. Perhaps there's a way to get past it..";
+ mes "";
+ setarray @colors$,"transparent","red","dark orange","orange","light orange","yellow","light green","green","dark green","blue","dark purple","purple","light purple";
+ mes "Looking closely between the two torches you can see the barrier has a " + @colors$[@BarrierColor] + " tint to it..";
+ close;
+
+L_Allow_Second_Passage:
+ if (OrumQuest < 9) goto L_Advance_Quest;
+ close;
+
+L_Advance_Quest:
+ message strcharinfo(0), "The torches dim as you enter like the first. You must be on the right trail..";
+ set OrumQuest, 9;
+ close;
+}
+
+// Third Barrier
+009-4.gat,24,66,0 script #OrumCaveThirdBarrier 0,1,0,{
+
+ if (OrumQuest == 3) set OrumQuest, 4;
+
+ set @Barrier, 1;
+ callfunc("GetBarrierColor");
+
+ set @Torch, 0;
+ callfunc("GetTorchColor");
+ set @Torch1Color, @TorchColor;
+
+ set @Torch, 1;
+ callfunc("GetTorchColor");
+ set @Torch2Color, @TorchColor;
+
+ set @firstColor, @BarrierColor - 2;
+ set @secondColor, @BarrierColor + 2;
+ if (@firstColor < 1) set @firstColor, 12;
+ if (@secondColor > 12) set @secondColor, 1;
+
+ if (OrumQuest > 8 && @Torch1Color == @firstColor && @Torch2Color == @secondColor)
+ goto L_Allow_Third_Passage;
+ if (OrumQuest > 8 && @Torch2Color == @firstColor && @Torch1Color == @secondColor)
+ goto L_Allow_Third_Passage;
+
+ warp "009-4.gat", 24, 64;
+ mes "As you try to pass, the torches begin to flare and push you back. Perhaps there is a way to get past it..";
+ mes "";
+ setarray @colors$,"transparent","red","dark orange","orange","light orange","yellow","light green","green","dark green","blue","dark purple","purple","light purple";
+ mes "Looking closely between the two torches you can see the barrier has a " + @colors$[@BarrierColor] + " tint to it..";
+ close;
+
+L_Allow_Third_Passage:
+if (OrumQuest < 10) goto L_Advance_Quest;
+ close;
+
+L_Advance_Quest:
+ set OrumQuest, 10;
+ close;
+}
+
+// Ending Barrier
+009-4.gat,48,38,0 script #OrumCaveEndBarrier 0,1,0,{
+
+ if (OrumQuest >= 11) close;
+ if (OrumQuest == 3) set OrumQuest, 4;
+
+ set @Barrier, 2;
+ callfunc("GetBarrierColor");
+
+ if (OrumQuest < 10) goto L_Deny_Final_Passage;
+
+ set @Torch, 0;
+ callfunc("GetTorchColor");
+ set @Torch1Color, @TorchColor;
+
+ set @Torch, 1;
+ callfunc("GetTorchColor");
+ set @Torch2Color, @TorchColor;
+
+ set @Torch, 2;
+ callfunc("GetTorchColor");
+ set @Torch3Color, @TorchColor;
+
+ // Extract the secondary color
+ set @secondary, @BarrierColor - 1;
+ if (@secondary != 3 && @secondary != 7 && @secondary != 11)
+ set @secondary, @BarrierColor + 1;
+
+ // Make sure it's in bounds
+ if (@secondary > 12) set @secondary, @secondary - 12;
+ if (@secondary < 1) set @secondary, @secondary + 12;
+
+ // Extract first 2 required colors
+ set @firstColor, @secondary - 2;
+ set @secondColor, @secondary + 2;
+ if (@firstColor > 12) set @firstColor, @firstColor - 12;
+ if (@firstColor < 1) set @firstColor, @firstColor + 12;
+ if (@secondColor > 12) set @secondColor, @secondColor - 12;
+ if (@secondColor < 1) set @secondColor, @secondColor + 12;
+
+ set @thirdColor, 12;
+ set @offsetOne, @BarrierColor + 1;
+ set @offsetTwo, @BarrierColor - 1;
+
+ // Make sure they in bounds
+ if (@offsetOne > 12) set @offsetOne, @offsetOne - 12;
+ if (@offsetOne < 1) set @offsetOne, @offsetOne + 12;
+ if (@offsetTwo > 12) set @offsetTwo, @offsetTwo - 12;
+ if (@offsetTwo < 1) set @offsetTwo, @offsetTwo + 12;
+
+ // Extract third needed color
+ if (@secondary == @offsetOne)
+ set @thirdColor, @firstColor;
+ if (@secondary == @offsetTwo)
+ set @thirdColor, @secondColor;
+
+ set @firstDone, 0;
+ set @secondDone, 0;
+ set @thirdDone, 0;
+
+ if (@firstDone == 0 && @secondDone != 1 && @thirdDone != 1 && @Torch1Color == @firstColor)
+ set @firstDone, 1;
+ if (@firstDone != 1 && @secondDone == 0 && @thirdDone != 1 && @Torch1Color == @secondColor)
+ set @secondDone, 1;
+ if (@firstDone != 1 && @secondDone != 1 && @thirdDone == 0 && @Torch1Color == @thirdColor)
+ set @thirdDone, 1;
+
+ if (@firstDone == 0 && @secondDone != 2 && @thirdDone != 2 && @Torch2Color == @firstColor)
+ set @firstDone, 2;
+ if (@firstDone != 2 && @secondDone == 0 && @thirdDone != 2 && @Torch2Color == @secondColor)
+ set @secondDone, 2;
+ if (@firstDone != 2 && @secondDone != 2 && @thirdDone == 0 && @Torch2Color == @thirdColor)
+ set @thirdDone, 2;
+
+ if (@firstDone == 0 && @secondDone != 3 && @thirdDone != 3 && @Torch3Color == @firstColor)
+ set @firstDone, 3;
+ if (@firstDone != 3 && @secondDone == 0 && @thirdDone != 3 && @Torch3Color == @secondColor)
+ set @secondDone, 3;
+ if (@firstDone != 3 && @secondDone != 3 && @thirdDone == 0 && @Torch3Color == @thirdColor)
+ set @thirdDone, 3;
+
+ if (@firstDone != 0 && @secondDone != 0 && @thirdDone != 0) goto L_Allow_Final_Passage;
+ goto L_Deny_Final_Passage;
+
+L_Deny_Final_Passage:
+ warp "009-4.gat", 48, 36;
+ mes "As you try to pass, the torches begin to flare and push you back. Perhaps there is a way to get past it..";
+ mes "";
+ setarray @colors$,"transparent","red","dark orange","orange","light orange","yellow","light green","green","dark green","blue","dark purple","purple","light purple";
+ mes "Looking closely between the two torches you can see the barrier has a " + @colors$[@BarrierColor] + " tint to it..";
+ close;
+
+L_Allow_Final_Passage:
+ if (OrumQuest < 11) goto L_Advance_Quest;
+ close;
+
+L_Advance_Quest:
+ message strcharinfo(0), "The torches dim as you enter. At last you finally have access!";
+ set OrumQuest, 11;
+ close;
+}
diff --git a/npc/009-4/orum.txt b/npc/009-4/orum.txt
new file mode 100644
index 00000000..cbc5e12f
--- /dev/null
+++ b/npc/009-4/orum.txt
@@ -0,0 +1,652 @@
+//#################################################################################
+//# Orum/Waric Quest Part 1 - By Liana, reviewed by Stefan Beller #
+//# GPL v.2 #
+//# #
+//# The first quest is to find Waric in the Caves with lots of torches. #
+//# These torches must be set in the right color to have access to the next #
+//# room, guarded by a magical barrier of other torches. #
+//# #
+//# The second quest is an easy, but background-story telling quest. #
+//# Just visit the cave again, find what is really in there. #
+//# #
+//# #
+//# Used variables: #
+//# #
+//# OrumQuest stores the progress of the quest #
+//# OrumQuestTorch In nibble (0,1,2) the color of the torches is stored #
+//# In nibble (3,4,5) the intensity of the torches is stored #
+//# OrumQuestBarrier nibble (0,1,2) stores the color of the barriers #
+//#################################################################################
+
+009-4.gat,37,115,0 script Orum 158,{
+ // needed to pass the very first barrier
+ set @B0_WISPPOWDER, 4;
+ set @B0_POLTERGEISTPOWDER, 2;
+ set @B0_SPECTREPOWDER, 1;
+ set @B0_HARDSPIKES, 1;
+
+ // needed stuff to get colorful powders
+ set @BT_IRONPOWDER, 10;
+ set @BT_PILESOFASH, 10;
+ set @BT_HERBS, 15;
+
+ // how many colorful powders each do you get as reward?
+ set @BT_REWARDCOUNT, 10;
+
+ // no exp for breaking the barrier ?
+ set @EXP_BREAK_BARRIERS, 0;
+
+ if (OrumQuest > 0) goto L_Started;
+
+ mes "[Orum]";
+ mes "\"It's not wise to venture around this place! Well hmm.. I guess since you're here, maybe you can lend a little help?\"";
+ next;
+
+ menu
+ "What exactly is 'this place'?", L_Explain,
+ "Umm.. what kind of help?", L_Explain,
+ "You're right, I'll be on my way.", -;
+
+ mes "[Orum]";
+ mes "\"Very smart thinking!\"";
+ close;
+
+L_Explain:
+ mes "[Orum]";
+ mes "\"Recently a woman claiming to be a witch came to my village seeking help from my mentor Woric, who is a very powerful wizard, but he refused and she left. But..\"";
+ next;
+
+ mes "[Orum]";
+ mes "\"The next day he went missing! I'm no wizard yet, but from what I overheard.. I think that witch is attempting some very foul magic and has kidnapped him for some reason!\"";
+ next;
+
+ mes "[Orum]";
+ mes "\"I traveled in the direction she left until I came accross this cave, but it appears to be protected by some type of magical barrier and I haven't been able to get further than this room.\"";
+ next;
+
+ menu
+ "So where would I come in?", L_Explain_Barriers,
+ "I'd like to help but I have to go..", -;
+
+ mes "[Orum]";
+ mes "\"Thats too bad.. well if you ever have some free time I probably won't figure this out any time soon.\"";
+ close;
+
+L_Explain_Barriers:
+ mes "[Orum]";
+ mes "\"I've examined this room and it appears that the barrier is made up of two torches on each side. The flame on them has a strange glow.. They must be inbued with magical properties.\"";
+ next;
+
+ mes "[Orum]";
+ mes "\"I've never come across anything like this barrier before.. It must be drawing it's power from the torches. I tried putting them out with conventional means but I had no luck..\"";
+ next;
+
+ menu
+ "Have any other ideas on how we get past it?", L_Explain_Note,
+ "I think its meant to keep us out.. bye.", -;
+
+ mes "[Orum]";
+ mes "\"You may be right.. but she kidnapped Woric. I know it! So I must do something! If you ever change your mind I could sure use the help.\"";
+ close;
+
+L_Explain_Note:
+ mes "[Orum]";
+ mes "\"Actually! After Woric went missing I looked around at his house a bit and came across a note the witch must have dropped. I skimmed over it and didn't pay much attention but I think it mentioned something about this barrier!\"";
+ next;
+
+ mes "He pulls it out of his pocket and begins examining it..";
+ next;
+
+ mes "[Orum]";
+ mes "\"Ah! Here it is! If I'm reading this right we may have found a way past it after all.. I guess she would need a way to come and go unaffected while everyone else is kept from entering.\"";
+ next;
+
+ menu
+ "What does it say??", L_Explain_Aura,
+ "Looks like you can do this without me.", -;
+
+ mes "[Orum]";
+ mes "\"Eh... well I guess I can't force you to stay..\"";
+ close;
+
+L_Explain_Aura:
+ mes "[Orum]";
+ mes "\"Appears to be some kind of spell to place a magical aura around someone... Hmm, with these materials listed on here I'm going to guess this aura makes the wearer partly incorporeal..\"";
+ next;
+
+ mes "[Orum]";
+ mes "\"It looks like the barrier requires substances from 3 different incorporeal creatures.. I've heard of Wisps, Poltergeists, and Spectres before but I've never seen such a thing.\"";
+ next;
+
+ mes "[Orum]";
+ mes "\"Luckily I happen to be skilled in this field of magic! I'm pretty sure if I can get my hands on the materials listed on here I'll be able to cast this aura on us, and hopefully then we can get past this barrier!\"";
+ next;
+
+ menu
+ "Let me guess.. that is my job?", L_Offer_Quest,
+ "I think someone is calling me.. Bye", -;
+ close;
+
+L_Offer_Quest:
+ mes "[Orum]";
+ mes "\"Well you would probably do better than me since I don't know this area very well.. It's not too much stuff so I'm sure you won't have any trouble at all.\"";
+ next;
+
+ menu
+ "Alright alright, just give me a list.", L_Start_Quest,
+ "I'm not your servant! Bye.", -;
+
+ mes "[Orum]";
+ mes "\"Everyone answers to someone.. that's just how the world is. If you ever change your mind I'll probably be here forever gathering these materials on my own..\"";
+ close;
+
+L_Start_Quest:
+ mes "He pulls a crumpled piece of paper from his pocket, smooths it out and writes a list on it before handing it to you..";
+ next;
+
+ mes "" + @B0_WISPPOWDER + " Wisp Powders,";
+ mes "" + @B0_POLTERGEISTPOWDER + " Poltergeist Powders,";
+ mes "" + @B0_SPECTREPOWDER + " Spectre Powders,";
+ mes "" + @B0_HARDSPIKES + " Hard Spikes";
+ next;
+
+ menu
+ "Alright, I'll go get these.", L_Start_Gathering,
+ "You can forget it! I quit!", -;
+
+ mes "[Orum]";
+ mes "\"I know you'll be back... they always come back!\"";
+ close;
+
+L_Start_Gathering:
+ mes "[Orum]";
+ mes "\"That's the spirit! But try not to take too long.\"";
+ set OrumQuest, 1;
+ close;
+
+L_Started:
+ if (OrumQuest == 1) goto L_Gathering;
+ if (OrumQuest == 2) goto L_Use_First_Barrier;
+ if (OrumQuest == 3) goto L_Explore;
+ if (OrumQuest == 4) goto L_Found_Barriers;
+ if (OrumQuest == 5) goto L_Found_Barriers;
+ if (OrumQuest == 6) goto L_Found_Torches;
+ if (OrumQuest == 7) goto L_Still_Gathering;
+ if (OrumQuest == 8) goto L_Finish_Up;
+ if (OrumQuest >= 9) goto L_Finished_Up;
+ close;
+
+L_Gathering:
+ mes "[Orum]";
+ mes "\"Got all the things I asked for yet?\"";
+ next;
+
+ menu
+ "Yep I have every last one of them!", L_Check_Materials,
+ "Can I get another list?", L_List_Materials,
+ "I still need a few things..", -;
+
+ mes "Orum shakes his head in frustration..";
+ next;
+
+ mes "[Orum]";
+ mes "\"You'd better get that stuff soon!\"";
+ close;
+
+L_List_Materials:
+ mes "He scavenges around in his pocket for another piece of paper then writes a new list..";
+ next;
+
+ mes @B0_WISPPOWDER + " Wisp Powders,";
+ mes @B0_POLTERGEISTPOWDER + " Poltergeist Powders,";
+ mes @B0_SPECTREPOWDER + " Spectre Powders,";
+ mes @B0_HARDSPIKES + " Hard Spikes";
+ next;
+
+ mes "[Orum]";
+ mes "\"And try not to lose this one.. I'm running out of stuff to write on!\"";
+ close;
+
+L_Check_Materials:
+ if (countitem("WispPowder") < @B0_WISPPOWDER ||
+ countitem("PoltergeistPowder") < @B0_POLTERGEISTPOWDER ||
+ countitem("SpectrePowder") < @B0_SPECTREPOWDER ||
+ countitem("HardSpike") < @B0_HARDSPIKES) goto L_Missing_Materials;
+
+ // check directly before deleting the objects.
+ delitem "WispPowder", @B0_WISPPOWDER;
+ delitem "PoltergeistPowder", @B0_POLTERGEISTPOWDER;
+ delitem "SpectrePowder", @B0_SPECTREPOWDER;
+ delitem "HardSpike", @B0_HARDSPIKES;
+
+ mes "Orum carefully looks over all of the items then grins..";
+ next;
+
+ mes "[Orum]";
+ mes "\"Well done! And you did not even take as long as I thought you would!\"";
+ next;
+
+ mes "Orum takes the hard spikes in his hand and begins chanting some words..";
+ next;
+
+ mes "You watch as they begin mold together glowing brightly. He sprinkles in the powder you gathered and presses his hands together.";
+
+ misceffect sfx_magic_transmute;
+ next;
+
+ mes "Suddenly a feeling of dizzyness hits you and you begin to feel weightless.. It passes after a moment..";
+ misceffect sfx_magic_nature;
+ misceffect 11, strcharinfo(0);
+ next;
+
+ mes "[Orum]";
+ mes "\"Well we are both still in one piece so that is a good sign! Now we'll have to see if I did it right.. mind going first?\"";
+ goto L_Setup_Lair;
+ close;
+
+L_Missing_Materials:
+ mes "Orum carefully looks over all of the items then squints his eyes at you..";
+ next;
+
+ mes "[Orum]";
+ mes "\"I'm not going to attempt this spell until I have ALL the items on this note.. Go gather the missing materials!\"";
+ close;
+
+L_Setup_Lair:
+ set OrumQuest, 2;
+
+ // Second Barrier
+ set @temp, rand(1,6);
+ set @Color, 1;
+ if (@temp == 1 || @temp == 4) set @Color, 1;
+ if (@temp == 2 || @temp == 5) set @Color, 5;
+ if (@temp == 3 || @temp == 6) set @Color, 9;
+ set @Barrier, 0;
+ callfunc("SetBarrierColor");
+
+ set @Torch, 0;
+ set @Color, rand(1, 12);
+ set @Intensity, 0;
+ callfunc("SetTorchColor");
+ callfunc("SetTorchIntensity");
+
+ // Third Barrier
+ set @temp, rand(1,6);
+ set @Color, 3;
+ if (@temp == 1 || @temp == 4) set @Color, 3;
+ if (@temp == 2 || @temp == 5) set @Color, 7;
+ if (@temp == 3 || @temp == 6) set @Color, 11;
+ set @Barrier, 1;
+ callfunc("SetBarrierColor");
+
+ set @Torch, 1;
+ set @Color, rand(1, 12);
+ callfunc("SetTorchColor");
+ callfunc("SetTorchIntensity");
+
+ // End Barrier
+ set @temp, rand(1,12);
+ set @Color, 2;
+ if (@temp == 1 || @temp == 7) set @Color, 2;
+ if (@temp == 2 || @temp == 8) set @Color, 4;
+ if (@temp == 3 || @temp == 9) set @Color, 6;
+ if (@temp == 4 || @temp == 10) set @Color, 8;
+ if (@temp == 5 || @temp == 11) set @Color, 10;
+ if (@temp == 6 || @temp == 12) set @Color, 12;
+ set @Barrier, 2;
+ callfunc("SetBarrierColor");
+
+ set @Torch, 2;
+ set @Color, rand(1, 12);
+ callfunc("SetTorchColor");
+ callfunc("SetTorchIntensity");
+ close;
+
+L_Use_First_Barrier:
+ mes "[Orum]";
+ mes "\"Casting that aura took a lot out of me.. Why don't you go explore the cave a bit while I rest?\"";
+ close;
+
+L_Explore:
+ mes "Orum looks up as you approach..";
+ next;
+
+ mes "[Orum]";
+ mes "\"Find anything interesting in this place?\"";
+ next;
+
+ menu
+ "Yep.. a whole mess of torches!", L_Explain_Objective,
+ "I'm not sure what to look for..", L_Explain_Objective,
+ "Going to explore more, bye.", -;
+
+ mes "[Orum]";
+ mes "\"Be sure to let me know if you find anything. I've almost gained my energy back.\"";
+ close;
+
+L_Explain_Objective:
+ mes "[Orum]";
+ mes "\"I'm positive this is where that witch took Woric, so this cave must lead to somewhere. Try looking around for another exit. I've almost gained my energy back and then I can help.\"";
+ close;
+
+L_Found_Barriers:
+ mes "Orum looks up as you approach..";
+ next;
+
+ mes "[Orum]";
+ mes "\"Find anything interesting in this place?\"";
+ next;
+
+ menu
+ "Yep.. a whole mess of torches!", L_Explain_Objective,
+ "I'm not sure what to look for..", L_Explain_Objective,
+ "I found more barriers.. but..", L_Explain_Barriers_More,
+ "Going to explore more, bye.", -;
+
+ mes "[Orum]";
+ mes "\"Be sure to let me know if you find anything. I'm still gaining my energy back.\"";
+ close;
+
+L_Explain_Barriers_More:
+ mes "[Orum]";
+ mes "\"Hm let me guess.. the aura is ineffective on the rest of the barriers here?\"";
+ next;
+
+ menu
+ "How did you know..?", L_Explain_Note_More,
+ "I'm not sure, I'll go try again.", -;
+
+ mes "[Orum]";
+ mes "\"Always a good idea to double check things!\"";
+ close;
+
+L_Explain_Note_More:
+ mes "[Orum]";
+ mes "\"Well while I was resting I spent more time looking over the note that witch dropped.. And I think the aura is only to get past the entrance..\"";
+ next;
+
+ mes "[Orum]";
+ mes "\"It mentions some sort of security system to keep people from entering the actual lair but it doesn't explain in great detail. Try exploring more maybe we will find some answers.\"";
+ next;
+
+ mes "Orum continues examining the note..";
+ close;
+
+L_Found_Torches:
+ mes "Orum looks up as you approach..";
+ next;
+
+ mes "[Orum]";
+ mes "\"Find something interesting?\"";
+ next;
+
+ menu
+ "Yep.. a whole mess of torches!", L_Explain_Objective,
+ "I'm not sure what to look for..", L_Explain_Objective,
+ "I found more barriers.. but..", L_Explain_Barriers_More,
+ "I found a strange torch by itself.", L_Explain_Torches,
+ "Going to explore more, bye.", -;
+
+ mes "[Orum]";
+ mes "\"Be sure to let me know if you find anything new.\"";
+ close;
+
+L_Explain_Torches:
+ mes "Orum has you direct him to the torch and he walks off to examine it before returning shortly after..";
+ next;
+
+ mes "[Orum]";
+ mes "\"Ah yes! I was hoping we would find something like this!\"";
+ next;
+
+ mes "[Orum]";
+ mes "\"While examining the note I found another set of spells to create some type of powder and with them was a few notes on using it with some type of torch..\"";
+ next;
+
+ mes "[Orum]";
+ mes "\"I'll bet this torch has something to do with the rest of these barriers which are probably the security system this note mentions.\"";
+ next;
+
+ mes "[Orum]";
+ mes "\"We will probably need to transmute this powder before we can get any further past these barriers.. Would you mind gathering a few more materials?\"";
+ next;
+
+ menu
+ "It better be the last time.", L_Gather_More,
+ "I'm done doing stuff for you!", -;
+
+ mes "[Orum]";
+ mes "\"I'm surprised you give up after we've gotten so far.. Shame.\"";
+ close;
+
+L_Gather_More:
+ mes "Orum begins writing down another list of materials..";
+ next;
+
+ mes @BT_IRONPOWDER + " Piles of Iron Powder,";
+ mes @BT_PILESOFASH + " Piles of Sand or Ash,";
+ mes @BT_HERBS + " Gamboge Herbs,";
+ mes @BT_HERBS + " Alizarin Herbs,";
+ mes @BT_HERBS + " Cobalt herbs";
+ next;
+
+ menu
+ "Yikes! I'll try..", L_Gathering_More,
+ "No way! Too much stuff!", -;
+
+ mes "[Orum]";
+ mes "\"The note says to get these and I'm not going to attempt this spell until I have what the note says.\"";
+ close;
+
+L_Gathering_More:
+ set OrumQuest, 7;
+ mes "[Orum]";
+ mes "\"Wonderful! Try to make it quick, we must save Waric!\"";
+ close;
+
+L_Still_Gathering:
+ mes "[Orum]";
+ mes "\"Have you finished gathering those things yet?\"";
+ next;
+
+ menu
+ "I believe I have!", L_Finished_Gathering_More,
+ "I lost my list.. again..", L_List_Materials_More,
+ "I've almost got them all..", -;
+
+ mes "[Orum]";
+ mes "\"Don't make me remind you again! Waric's life is on the line here! Hurry up!\"";
+ close;
+
+L_List_Materials_More:
+ mes "He scavenges around in his pocket for another piece of paper then writes a new list..";
+ next;
+
+ mes @BT_IRONPOWDER + " Piles of Iron Powder,";
+ mes @BT_PILESOFASH + " Piles of Sand or Ash,";
+ mes @BT_HERBS + " Gamboge Herbs,";
+ mes @BT_HERBS + " Alizarin Herbs,";
+ mes @BT_HERBS + " Cobalt herbs";
+ next;
+
+ mes "[Orum]";
+ mes "\"And try not to lose this one.. I don't have much more to write on!\"";
+ close;
+
+L_Finished_Gathering_More:
+ if (countitem("IronPowder") < @BT_IRONPOWDER ||
+ countitem("PileOfAsh") < @BT_PILESOFASH ||
+ countitem("GambogeHerb") < @BT_HERBS ||
+ countitem("AlizarinHerb") < @BT_HERBS ||
+ countitem("CobaltHerb") < @BT_HERBS) goto L_Missing_Materials_More;
+
+ delitem "IronPowder", @BT_IRONPOWDER;
+ delitem "PileOfAsh", @BT_PILESOFASH;
+ delitem "GambogeHerb", @BT_HERBS;
+ delitem "AlizarinHerb", @BT_HERBS;
+ delitem "CobaltHerb", @BT_HERBS;
+
+ mes "[Orum]";
+ mes "\"Excellent work! And once again you did not take as long as I was expecting. I guess I will get started..\"";
+ next;
+
+ mes "You watch as Orum takes the iron powder and ash and begins chanting some words.. The two start to glow and mold together turning into a light metalic looking powder..";
+ next;
+ misceffect sfx_magic_transmute;
+
+ mes "He then splits the powder into three piles and performs separate spells on each using the herbs. After he finishes you see 3 piles of colored metalic powder that appear to be red, yellow, and blue..";
+ next;
+ misceffect sfx_magic_transmute;
+
+ mes "[Orum]";
+ mes "\"Well if I did it right.. These three powders are hopefully the key to getting past these barriers!\"";
+ next;
+
+ mes "[Orum]";
+ mes "\"I'm weary, I must take some time to rest. Why don't you go ahead and experiment with these powders on that torch and let me know if you figure what they have to do with it.\"";
+
+ getitem "RedPowder", @BT_REWARDCOUNT;
+ getitem "YellowPowder", @BT_REWARDCOUNT;
+ getitem "BluePowder", @BT_REWARDCOUNT;
+ set OrumQuest, 8;
+ close;
+
+L_Missing_Materials_More:
+ mes "Orum carefully looks over all of the items then squints his eyes at you..";
+ next;
+
+ mes "[Orum]";
+ mes "\"You really enjoy playing games with Warics' life don't you! Come back when you have ALL of the items I told you.\"";
+ close;
+
+L_Finish_Up:
+ mes "Orum seems to be sitting around doing nothing as you approach.";
+ next;
+
+ mes "[Orum]";
+ mes "\"Did you find a way past any of the barriers yet?\"";
+ next;
+
+ menu
+ "No I'm still not sure how..", L_Explain_Torches_More,
+ "I need more of that powder.", L_More_Powder,
+ "I'm still trying..", -;
+
+ mes "[Orum]";
+ mes "\"Excellent! Let me know when you've made any progress.\"";
+ close;
+
+L_Explain_Torches_More:
+ mes "[Orum]";
+ mes "\"Most of the barriers here have a certain color radiating from them and so do the torches. The torches seem to react with this powder so maybe we have to make these torches turn a certain color in order to lower the barriers.\"";
+ next;
+
+ mes "[Orum]";
+ mes "\"Also while looking around I saw that behind one of the barriers was a cave. Maybe Waric is in there.. we should try to get that barrier dropped\"";
+ close;
+
+L_More_Powder:
+ mes "[Orum]";
+ mes "\"You really used up that powder fast.. Luckily I can make more as long as you can bring me those materials again.\"";
+ next;
+
+ menu
+ "I have them right here!", L_More_Powder_Make,
+ "Hmmm.. what are they again?", L_List_Materials_More,
+ "I'll go get those for you..", -;
+
+ mes "[Orum]";
+ mes "\"You better not waste any time gathering those materials!\"";
+ close;
+
+L_More_Powder_Make:
+ if (countitem("IronPowder") < @BT_IRONPOWDER ||
+ countitem("PileOfAsh") < @BT_PILESOFASH ||
+ countitem("GambogeHerb") < @BT_HERBS ||
+ countitem("AlizarinHerb") < @BT_HERBS ||
+ countitem("CobaltHerb") < @BT_HERBS) goto L_Missing_Materials_More;
+
+ delitem "IronPowder", @BT_IRONPOWDER;
+ delitem "PileOfAsh", @BT_PILESOFASH;
+ delitem "GambogeHerb", @BT_HERBS;
+ delitem "AlizarinHerb", @BT_HERBS;
+ delitem "CobaltHerb", @BT_HERBS;
+
+ mes "[Orum]";
+ mes "\"Hmm all of the items appear to be here.. Give me a moment to make that powder for you.\"";
+ next;
+
+ mes "Orum begins chanting the same words as he did when he made the powder before.. He seems to be quicker at it this time..";
+ misceffect sfx_magic_transmute;
+ next;
+
+ mes "[Orum]";
+ mes "\"Here you are. And try to conserve this time! The more powder I have to make the more time and resources we use up that we could be using to save Waric!\"";
+
+ getitem "RedPowder", @BT_REWARDCOUNT;
+ getitem "YellowPowder", @BT_REWARDCOUNT;
+ getitem "BluePowder", @BT_REWARDCOUNT;
+ close;
+
+L_Finished_Up:
+ mes "As you approch you think you see Orum rolling his eyes.. maybe your imagining it..";
+ next;
+
+ mes "[Orum]";
+ mes "\"I hope you finally dropped that barrier we need to get past!\"";
+ next;
+
+ menu
+ "Actually.. I have!", L_Enter_Cavern,
+ "I need more of that powder.", L_More_Powder,
+ "Cut me some slack! I'm working on it!", -;
+
+ mes "[Orum]";
+ mes "\"Just hurry it up! Warics life is on the line here!\"";
+ close;
+
+L_Enter_Cavern:
+ if (OrumQuest >= 10) goto L_Ready_Cavern;
+
+ mes "Orum heads to the barrier then gives you a look as if he does not believe you before walking forward..";
+ next;
+
+ mes "He is suddently thrown againt the wall behind him! Angered, he gets up, brushes himself off, and heads back to the entrance without speaking.";
+ close;
+
+L_Ready_Cavern:
+ // you should not get that twice ;)
+ if (OrumQuest == 12) goto L_Got_Reward;
+
+ mes "Orum heads to the barrier then gives you a look as if he does not believe you before walking forward..";
+ next;
+
+ mes "He makes it through without any problems and grins.";
+ next;
+
+ mes "[Orum]";
+ mes "\"Very good work you have done! Please take this for your efforts.\"";
+ next;
+
+ getexp @EXP_BREAK_BARRIERS, 0;
+ // TODO put item name and remove following line and this line as well!
+ getitem "", 1;
+ mes "[Insert reward here...]";
+ next;
+
+ mes "\"You've done enough here to help. I will go the rest of the way alone so that your life is not endangered.. You must promise me not to go any further!\"";
+ next;
+
+ menu
+ "Sure, I promise!", -,
+ "I thought this would never be over!", -;
+
+ mes "[Orum]";
+ mes "\"Well I guess this is farewell!\"";
+ set OrumQuest, 12;
+ close;
+
+L_Got_Reward:
+ mes "\"You've done enough here to help. I will go the rest of the way alone so that your life is not endangered..\"";
+ next;
+}
diff --git a/npc/009-4/torches.txt b/npc/009-4/torches.txt
new file mode 100644
index 00000000..d1ea73be
--- /dev/null
+++ b/npc/009-4/torches.txt
@@ -0,0 +1,358 @@
+//# see detailed description at orum.txt
+function script GetTorchColor {
+ if (@Torch < 0 || @Torch > 2) goto L_Error;
+
+ set @Mask, 15;
+ set @Shift, 4 * @Torch;
+ set @TorchColor, (OrumQuestTorch >> @Shift) & @Mask;
+ return;
+
+L_Error:
+ mes "Torch number is out of range.";
+ close;
+}
+
+function script SetTorchColor {
+ if (@Torch < 0 || @Torch > 2) goto L_Error;
+ if (@Color < 0 || @Color > 12) goto L_Error2;
+
+ set @Mask, (15 << (4 * @Torch));
+ set OrumQuestTorch, (OrumQuestTorch & (~(@Mask))) | @Color << (4 * @Torch);
+ return;
+
+L_Error:
+ mes "Torch number is out of range.";
+ close;
+
+L_Error2:
+ mes "Torch color is out of range.";
+ close;
+}
+
+function script GetTorchIntensity {
+ if (@Torch < 0 || @Torch > 2) goto L_Error;
+
+ set @Mask, 15;
+ set @Shift, 4 * (@Torch + 3);
+ set @TorchIntensity, (OrumQuestTorch >> @Shift) & @Mask;
+ return;
+
+L_Error:
+ mes "Torch number is out of range.";
+ close;
+}
+
+function script SetTorchIntensity {
+ if (@Torch < 0 || @Torch > 2) goto L_Error;
+ if (@Intensity < 0 || @Intensity > 2) goto L_Error2;
+
+ set @Mask, (15 << (4 * (@Torch + 3)));
+ set OrumQuestTorch, (OrumQuestTorch & (~(@Mask))) | @Intensity << (4 * (@Torch + 3));
+ return;
+
+L_Error:
+ mes "Torch number is out of range.";
+ close;
+
+L_Error2:
+ mes "Torch intensity is out of range.";
+ close;
+}
+
+function script DoneWithTorches {
+ if (OrumQuest < 11 && OrumQuest >= 8)
+ return;
+
+ if (OrumQuest < 7) goto L_Different;
+
+ if (OrumQuest >= 11)
+ mes "The flame on the torch looks ordinary.. Lowering the final barrier seems to have drained them of their magic.";
+
+ if (OrumQuest < 8)
+ mes "Without that powder the note mentions there isn't much you can do with this torch..";
+
+ close;
+
+L_Different:
+ mes "The flame on this torch looks different than the rest.. You better tell Orum about it before doing anything.";
+ set OrumQuest, 6;
+ close;
+}
+
+// To make sure in range of torches
+function script InRangeTorch1 {
+ if (isin("009-4.gat",67,20,69,25))
+ return;
+
+ mes "Your too far away to do anything with that torch.";
+ close;
+}
+function script InRangeTorch2 {
+ if (isin("009-4.gat",65,41,69,46))
+ return;
+
+ mes "Your too far away to do anything with that torch.";
+ close;
+}
+function script InRangeTorch3 {
+ if (isin("009-4.gat",33,84,37,88))
+ return;
+
+ mes "Your too far away to do anything with that torch.";
+ close;
+}
+
+// First Torch
+009-4.gat,68,21,0 script Torch 127,{
+ callfunc "InRangeTorch1";
+ callfunc "DoneWithTorches";
+
+ set @Torch, 0;
+ callfunc("GetTorchColor");
+ callfunc("GetTorchIntensity");
+
+ set @lastColor, @TorchColor;
+ setarray @colors$,"transparent","red","dark orange","orange","light orange","yellow","light green","green","dark green","blue","dark purple","purple","light purple";
+ setarray @intensities$,"calm","bright","blinding";
+ mes "Looking closely you notice that this torch is not like the others.. This one has a " + @intensities$[@TorchIntensity] + " " + @colors$[@TorchColor] + " tint to it.";
+ goto L_Color_Loop;
+
+L_Color_Loop:
+ callfunc("GetTorchColor");
+ menu
+ "Add Red Powder", L_Use_Red,
+ "Add Yellow Powder", L_Use_Yellow,
+ "Add Blue Powder", L_Use_Blue,
+ "Leave it alone.", -;
+
+ mes "The flame flickers as if it's laughing at you..";
+ close;
+
+L_Use_Red:
+ if (countitem("RedPowder") < 1) goto L_No_Powder;
+ if (@TorchColor > 6 && @TorchColor < 12) set @Color, @TorchColor + 1;
+ if (@TorchColor < 6 && @TorchColor > 1) set @Color, @TorchColor - 1;
+ if (@TorchColor == 12) set @Color, 1;
+ callfunc("SetTorchColor");
+ delitem "RedPowder", 1;
+ goto L_Show_Color;
+
+L_Use_Yellow:
+ if (countitem("YellowPowder") < 1) goto L_No_Powder;
+ if (@TorchColor < 10 && @TorchColor > 5) set @Color, @TorchColor - 1;
+ if (@TorchColor >= 1 && @TorchColor < 5) set @Color, @TorchColor + 1;
+ callfunc("SetTorchColor");
+ delitem "YellowPowder", 1;
+ goto L_Show_Color;
+
+L_Use_Blue:
+ if (countitem("BluePowder") < 1) goto L_No_Powder;
+ if (@TorchColor > 4 && @TorchColor < 9) set @Color, @TorchColor + 1;
+ if (@TorchColor <= 12 && @TorchColor > 9) set @Color, @TorchColor - 1;
+ if (@TorchColor == 1) set @Color, 12;
+ callfunc("SetTorchColor");
+ delitem "BluePowder", 1;
+ goto L_Show_Color;
+
+L_No_Powder:
+ mes "You notice your all out of that color of powder.. Perhaps Orum can make you some more.";
+ close;
+
+L_Show_Color:
+ callfunc("GetTorchColor");
+ callfunc("GetTorchIntensity");
+ if (@TorchColor == @lastColor) goto L_Wrong_Color;
+ misceffect 5;
+ set @lastColor, @TorchColor;
+ mes "As your pour the powder into the flame you can see it's tint transform to a " + @intensities$[@TorchIntensity] + " " + @colors$[@TorchColor] + "..";
+ goto L_Color_Loop;
+
+L_Wrong_Color:
+ set @Intensity, @TorchIntensity + 1;
+ if (@Intensity > 2) goto L_Failed;
+ callfunc("SetTorchIntensity");
+ callfunc("GetTorchIntensity");
+ misceffect 5;
+ mes "As you pour the powder into the flame it flares violently for a moment and then turns into a " + @intensities$[@TorchIntensity] + " " + @colors$[@TorchColor] + "..";
+ goto L_Color_Loop;
+
+L_Failed:
+ mes "As you pour the powder into the flame it flares violently before bursting into your face!";
+ misceffect 5;
+ misceffect 16;
+ set @Intensity, 0;
+ callfunc("SetTorchIntensity");
+ heal -Hp, 0;
+ close;
+}
+
+// Second Torch
+009-4.gat,67,42,0 script Torch 127,{
+ callfunc "InRangeTorch2";
+ callfunc "DoneWithTorches";
+
+ set @Torch, 1;
+ callfunc("GetTorchColor");
+ callfunc("GetTorchIntensity");
+
+ set @lastColor, @TorchColor;
+ setarray @colors$,"transparent","red","dark orange","orange","light orange","yellow","light green","green","dark green","blue","dark purple","purple","light purple";
+ mes "Looking closely you notice that this torch is not like the others.. This one has a " + @intensities$[@TorchIntensity] + " " + @colors$[@TorchColor] + " tint to it.";
+ goto L_Color_Loop;
+
+L_Color_Loop:
+ callfunc("GetTorchColor");
+ menu
+ "Add Red Powder", L_Use_Red,
+ "Add Yellow Powder", L_Use_Yellow,
+ "Add Blue Powder", L_Use_Blue,
+ "Leave it alone.", -;
+
+ mes "The flame flickers as if it's laughing at you..";
+ close;
+
+L_Use_Red:
+ if (countitem("RedPowder") < 1) goto L_No_Powder;
+ if (@TorchColor > 6 && @TorchColor < 12) set @Color, @TorchColor + 1;
+ if (@TorchColor < 6 && @TorchColor > 1) set @Color, @TorchColor - 1;
+ if (@TorchColor == 12) set @Color, 1;
+ callfunc("SetTorchColor");
+ delitem "RedPowder", 1;
+ goto L_Show_Color;
+
+L_Use_Yellow:
+ if (countitem("YellowPowder") < 1) goto L_No_Powder;
+ if (@TorchColor < 10 && @TorchColor > 5) set @Color, @TorchColor - 1;
+ if (@TorchColor >= 1 && @TorchColor < 5) set @Color, @TorchColor + 1;
+ callfunc("SetTorchColor");
+ delitem "YellowPowder", 1;
+ goto L_Show_Color;
+
+L_Use_Blue:
+ if (countitem("BluePowder") < 1) goto L_No_Powder;
+ if (@TorchColor > 4 && @TorchColor < 9) set @Color, @TorchColor + 1;
+ if (@TorchColor <= 12 && @TorchColor > 9) set @Color, @TorchColor - 1;
+ if (@TorchColor == 1) set @Color, 12;
+ callfunc("SetTorchColor");
+ delitem "BluePowder", 1;
+ goto L_Show_Color;
+
+L_No_Powder:
+ mes "You notice your all out of that color powder.. Perhaps Orum can make you some more.";
+ close;
+
+L_Show_Color:
+ callfunc("GetTorchColor");
+ callfunc("GetTorchIntensity");
+ if (@TorchColor == @lastColor) goto L_Wrong_Color;
+ misceffect 5;
+ set @lastColor, @TorchColor;
+ mes "As your pour the powder into the flame you can see it's tint transform to a " + @intensities$[@TorchIntensity] + " " + @colors$[@TorchColor] + "..";
+ goto L_Color_Loop;
+
+L_Wrong_Color:
+ set @Intensity, @TorchIntensity + 1;
+ if (@Intensity > 2) goto L_Failed;
+ callfunc("SetTorchIntensity");
+ callfunc("GetTorchIntensity");
+ misceffect 5;
+ mes "As you pour the powder into the flame it flares violently for a moment and then turns into a " + @intensities$[@TorchIntensity] + " " + @colors$[@TorchColor] + "..";
+ goto L_Color_Loop;
+
+L_Failed:
+ mes "As you pour the powder into the flame it flares violently before bursting into your face!";
+ misceffect 5;
+ misceffect 16;
+ set @Intensity, 0;
+ callfunc("SetTorchIntensity");
+ heal -Hp, 0;
+ close;
+}
+
+// Third Torch
+009-4.gat,33,86,0 script Torch 127,{
+ callfunc "InRangeTorch3";
+ callfunc "DoneWithTorches";
+
+ set @Torch, 2;
+ callfunc("GetTorchColor");
+ callfunc("GetTorchIntensity");
+
+ set @lastColor, @TorchColor;
+ setarray @colors$,"transparent","red","dark orange","orange","light orange","yellow","light green","green","dark green","blue","dark purple","purple","light purple";
+ setarray @intensities$,"calm","bright","blinding";
+ mes "Looking closely you notice that this torch is not like the others.. This one has a " + @intensities$[@TorchIntensity] + " " + @colors$[@TorchColor] + " tint to it.";
+ goto L_Color_Loop;
+
+L_Too_Far:
+ mes "Your too far away to do anything with that torch.";
+ close;
+
+L_Color_Loop:
+ callfunc("GetTorchColor");
+ menu
+ "Add Red Powder", L_Use_Red,
+ "Add Yellow Powder", L_Use_Yellow,
+ "Add Blue Powder", L_Use_Blue,
+ "Leave it alone.", -;
+
+ mes "The flame flickers as if it's laughing at you..";
+ close;
+
+L_Use_Red:
+ if (countitem("RedPowder") < 1) goto L_No_Powder;
+ if (@TorchColor > 6 && @TorchColor < 12) set @Color, @TorchColor + 1;
+ if (@TorchColor < 6 && @TorchColor > 1) set @Color, @TorchColor - 1;
+ if (@TorchColor == 12) set @Color, 1;
+ callfunc("SetTorchColor");
+ delitem "RedPowder", 1;
+ goto L_Show_Color;
+
+L_Use_Yellow:
+ if (countitem("YellowPowder") < 1) goto L_No_Powder;
+ if (@TorchColor < 10 && @TorchColor > 5) set @Color, @TorchColor - 1;
+ if (@TorchColor >= 1 && @TorchColor < 5) set @Color, @TorchColor + 1;
+ callfunc("SetTorchColor");
+ delitem "YellowPowder", 1;
+ goto L_Show_Color;
+
+L_Use_Blue:
+ if (countitem("BluePowder") < 1) goto L_No_Powder;
+ if (@TorchColor > 4 && @TorchColor < 9) set @Color, @TorchColor + 1;
+ if (@TorchColor <= 12 && @TorchColor > 9) set @Color, @TorchColor - 1;
+ if (@TorchColor == 1) set @Color, 12;
+ callfunc("SetTorchColor");
+ delitem "BluePowder", 1;
+ goto L_Show_Color;
+
+L_No_Powder:
+ mes "You notice your all out of that color powder.. Perhaps Orum can make you some more.";
+ close;
+
+L_Show_Color:
+ callfunc("GetTorchColor");
+ callfunc("GetTorchIntensity");
+ if (@TorchColor == @lastColor) goto L_Wrong_Color;
+ misceffect 5;
+ set @lastColor, @TorchColor;
+ mes "As your pour the powder into the flame you can see it's tint transform to a " + @intensities$[@TorchIntensity] + " " + @colors$[@TorchColor] + "..";
+ goto L_Color_Loop;
+
+L_Wrong_Color:
+ set @Intensity, @TorchIntensity + 1;
+ if (@Intensity > 2) goto L_Failed;
+ callfunc("SetTorchIntensity");
+ callfunc("GetTorchIntensity");
+ misceffect 5;
+ mes "As you pour the powder into the flame it flares violently for a moment and then turns into a " + @intensities$[@TorchIntensity] + " " + @colors$[@TorchColor] + "..";
+ goto L_Color_Loop;
+
+L_Failed:
+ mes "As you pour the powder into the flame it flares violently before bursting into your face!";
+ misceffect 5;
+ misceffect 16;
+ set @Intensity, 0;
+ callfunc("SetTorchIntensity");
+ heal -Hp, 0;
+ close;
+}
diff --git a/npc/009-4/waric.txt b/npc/009-4/waric.txt
new file mode 100644
index 00000000..b160dfbb
--- /dev/null
+++ b/npc/009-4/waric.txt
@@ -0,0 +1,95 @@
+//# see detailed description at orum.txt
+
+009-4.gat,99,33,0 script #WizardTrap 0,2,1,{
+ set @gender$, "They're";
+ if (Sex == 0) set @gender$, "She's";
+ if (Sex == 1) set @gender$, "He's";
+
+ mes "As you explore further into the cave you see a figure looking at you who appears angry.. but as you begin to speak, he quickly chants some words and you start to lose conciousness!";
+ next;
+ warp "009-4.gat", 117, 40;
+ mes "When you awake you find yourself unable to move.. You seem to be held in place by something.. As your eyes regain focus you see Orum talking with the figure you saw earlier.. Orum looks over at you and mumbles";
+ mes "";
+ mes "[Orum]";
+ mes "\"Be quiet Waric.. " + @gender$ + " awake..\"";
+ close;
+}
+
+009-4.gat,120,43,0 script Orum 158,{
+ mes "[Orum]";
+ mes "\"I told you to forget about this place but you did not heed my advice!\"";
+ next;
+ mes "[Orum]";
+ mes "\"Your fate is up to Waric now.. don't expect me to do anything else for you.\"";
+ close;
+}
+
+009-4.gat,118,42,0 script Waric 153,{
+ set @EXP_LEARNED_ALOT, 10000;
+ if (OrumQuest >= 13) goto L_Behave;
+ mes "Waric looks toward you rubbing his chin..";
+ next;
+ mes "[Waric]";
+ mes "\"So... Orum tells me your the one that helped him break me out of this dreadful place, so I guess I must thank you for that.\"";
+ next;
+ menu
+ "My pleasure! Mind letting me out of here?", L_Explain,
+ "This doesn't look like a thank you!", L_Explain,
+ "Let me out of here at once!", -;
+
+ mes "Waric turns toward Orum..";
+ next;
+ mes "[Waric]";
+ mes "\"We've got a feisty one here Orum!\"";
+ next;
+ mes "They begin discussing plans of some sort..";
+ set OrumQuest, 13;
+ close;
+
+L_Behave:
+ mes "Waric looks toward you shaking his finger..";
+ next;
+ mes "[Waric]";
+ mes "\"So... are you ready to behave yourself now?\"";
+ next;
+ menu
+ "Yes mister..", L_Explain,
+ "No I'm not ready yet!", -;
+
+ mes "[Waric]";
+ mes "\"Having fun I take it?\"";
+ next;
+ mes "They continue discussing their plans..";
+ close;
+
+L_Explain:
+ mes "[Waric]";
+ mes "\"I'm not sure what Orum told you but I was not kidnapped and brought here.. I was in fact imprisoned here very long ago by a witch for practicing spells on the insignificant forest life.\"";
+ next;
+ mes "[Waric]";
+ mes "\"She cared about the forest and all of that stuff you see. Now this cave is not bad.. I actually enjoyed it the first nights, but after a few years...\"";
+ next;
+ mes "Waric gets a bitter look and his face and pauses for a moment..";
+ next;
+ mes "[Waric]";
+ mes "\"So now you can see my motive to get out of here. The only air and water I get is what's given to me through that cave over there. And as for food.. theres only so many recipes for cave snakes and silk worms...\"";
+ next;
+ mes "Waric shivers in disgust..";
+ next;
+ mes "[Woric]";
+ mes "\"I'm sorry I had to constrain you like this but now that I'm free, I'm not about to let anyone stand in my way!\"";
+ next;
+ mes "[Waric]";
+ mes "\"Now if you'll excuse us, Orum and I have some things to attend to.. And don't bother coming back to stop us because we'll be long gone.\"";
+ next;
+ mes "Waric raises his hands and begins chanting some words.. You watch as streams of energy begin swirling around you..";
+ next;
+ mes "Once more you start to lose conciousness as your surroundings begin to fade..";
+ next;
+ set OrumQuest, 14;
+ misceffect 10;
+ warp "008-1.gat", 65, 90;
+ mes "You awake on your back with a squrrel sitting on top of you arranging it's acorns.. It quickly gathers them up and runs off as it sees you looking at it them..";
+ getexp @EXP_LEARNED_ALOT, 0;
+ close;
+}
diff --git a/npc/011-1_Woodland/_warps.txt b/npc/011-1_Woodland/_warps.txt
index 2cb1fd80..5a700e22 100644
--- a/npc/011-1_Woodland/_warps.txt
+++ b/npc/011-1_Woodland/_warps.txt
@@ -5,3 +5,4 @@
011-1.gat,49,104 warp ToWoodland 0,-1,010-1.gat,50,25
011-1.gat,125,62 warp ToWoodland -1,2,008-1.gat,27,61
011-1.gat,73,11 warp ToWoodlandHills 0,-1,012-1.gat,131,162
+011-1.gat,38,36 warp affenpeter -1,-1,011-6.gat,49,99
diff --git a/npc/011-4_Lake_cave/_import.txt b/npc/011-4_Lake_cave/_import.txt
index f2cfbc87..fe6c5cfd 100644
--- a/npc/011-4_Lake_cave/_import.txt
+++ b/npc/011-4_Lake_cave/_import.txt
@@ -1,4 +1,5 @@
map: 011-4.gat
npc: npc/011-4_Lake_cave/_mobs.txt
npc: npc/011-4_Lake_cave/_warps.txt
+npc: npc/011-4_Lake_cave/bl_barrier.txt
npc: npc/011-4_Lake_cave/monsters.txt
diff --git a/npc/011-4_Lake_cave/_warps.txt b/npc/011-4_Lake_cave/_warps.txt
index e0fe5a00..7f1c1b2a 100644
--- a/npc/011-4_Lake_cave/_warps.txt
+++ b/npc/011-4_Lake_cave/_warps.txt
@@ -2,3 +2,12 @@
011-4.gat,73,8 warp ToHermitsCave 0,-1,011-3.gat,31,24
011-4.gat,129,86 warp ToCaveBeneathHurnscald -1,-1,009-3.gat,21,55
+011-4.gat,39,35 warp warp -1,-1,011-6.gat,47,183
+011-4.gat,16,57 warp warp -1,-1,011-6.gat,24,204
+011-4.gat,89,20 warp warp -1,-1,011-6.gat,97,168
+011-4.gat,105,32 warp warp -1,-1,011-6.gat,113,184
+011-4.gat,114,61 warp warp -1,-1,011-6.gat,122,213
+011-4.gat,86,75 warp warp -1,-1,011-6.gat,94,227
+011-4.gat,62,86 warp warp -1,-1,011-6.gat,68,233
+011-4.gat,32,5 warp warp 0,-1,011-6.gat,186,180
+011-4.gat,45,118 warp warp -1,-1,011-6.gat,266,180
diff --git a/npc/011-4_Lake_cave/bl_barrier.txt b/npc/011-4_Lake_cave/bl_barrier.txt
new file mode 100644
index 00000000..07b44999
--- /dev/null
+++ b/npc/011-4_Lake_cave/bl_barrier.txt
@@ -0,0 +1,16 @@
+//bandit lord barrier
+
+011-4.gat,111,121,0 script #BL_Barrier 127,0,0,{
+
+ if (TMW_Quest >= 44) goto L_Bandit_Lord_Barrier_Open;
+
+ message strcharinfo(0), "This entrance appears to be locked.";
+ end;
+
+
+L_Bandit_Lord_Barrier_Open:
+ message strcharinfo(0), "You insert the silver arrow key and unlock the entrance.";
+ warp "011-6.gat",251,275;
+ end;
+
+}
diff --git a/npc/011-6/_import.txt b/npc/011-6/_import.txt
new file mode 100644
index 00000000..ae38662c
--- /dev/null
+++ b/npc/011-6/_import.txt
@@ -0,0 +1,4 @@
+map: 011-6.gat
+npc: npc/011-6/_mobs.txt
+npc: npc/011-6/_warps.txt
+npc: npc/011-6/bryant.txt
diff --git a/npc/011-6/_mobs.txt b/npc/011-6/_mobs.txt
new file mode 100644
index 00000000..9b6fc0a5
--- /dev/null
+++ b/npc/011-6/_mobs.txt
@@ -0,0 +1,31 @@
+// 011-6 mobs
+
+011-6.gat,0,0,0,0 monster Spiky Mushroom 1019,30,30000,100000,Mob011-6::On1019
+011-6.gat,0,0,0,0 monster Evil Mushroom 1013,15,30000,100000,Mob011-6::On1013
+011-6.gat,115,79,191,110 monster Bandit 1063,8,30000,100000,Mob011-6::On1063
+011-6.gat,0,0,0,0 monster Bat 1017,30,30000,100000,Mob011-6::On1017
+
+
+011-6.gat,0,0,0 script Mob011-6 -1,{
+On1013:
+ set @mobID, 1013;
+ callfunc "MobPoints";
+ break;
+
+On1017:
+ set @mobID, 1017;
+ callfunc "MobPoints";
+ break;
+
+On1019:
+ set @mobID, 1019;
+ callfunc "MobPoints";
+ break;
+
+On1063:
+ set @mobID, 1063;
+ callfunc "MobPoints";
+ break;
+
+ end;
+}
diff --git a/npc/011-6/_warps.txt b/npc/011-6/_warps.txt
new file mode 100644
index 00000000..545bc386
--- /dev/null
+++ b/npc/011-6/_warps.txt
@@ -0,0 +1,25 @@
+// 011-6 warps
+
+011-6.gat,51,75 warp toMiddleCave1 -1,-1,011-6.gat,260,125
+011-6.gat,61,71 warp toMiddleCave2 -1,-1,011-6.gat,270,122
+011-6.gat,270,125 warp toMainCave -1,-1,011-6.gat,61,73
+011-6.gat,260,128 warp toMiddleCave2 -1,-1,011-6.gat,51,77
+011-6.gat,145,118 warp ToMainCave3 -1,-1,011-6.gat,47,119
+011-6.gat,196,26 warp toSmallCave1 -1,-1,011-6.gat,261,44
+011-6.gat,261,47 warp toPassage1 -1,-1,011-6.gat,196,28
+011-6.gat,271,52 warp toMainCave4 -1,-1,011-6.gat,98,32
+011-6.gat,98,30 warp toSmallCave -1,-1,011-6.gat,271,50
+011-6.gat,47,120 warp toPassage -1,-1,011-6.gat,145,115
+011-6.gat,49,101 warp toOutside -1,-1,011-1.gat,38,37
+011-6.gat,24,206 warp warp -1,-1,011-4.gat,17,59
+011-6.gat,47,185 warp warp -1,-1,011-4.gat,39,38
+011-6.gat,97,170 warp warp -1,-1,011-4.gat,89,21
+011-6.gat,113,182 warp warp -1,-1,011-4.gat,105,34
+011-6.gat,122,211 warp warp -1,-1,011-4.gat,114,63
+011-6.gat,94,225 warp warp -1,-1,011-4.gat,86,77
+011-6.gat,68,235 warp warp -1,-1,011-4.gat,62,87
+011-6.gat,251,278 warp warp -1,-1,011-4.gat,111,123
+011-6.gat,186,182 warp warp -1,-1,011-4.gat,31,7
+011-6.gat,266,182 warp warp -1,-1,011-4.gat,45,120
+011-6.gat,174,256 warp warp -1,-1,011-6.gat,264,238
+011-6.gat,264,236 warp warp -1,-1,011-6.gat,174,252
diff --git a/npc/011-6/bryant.txt b/npc/011-6/bryant.txt
new file mode 100644
index 00000000..07c5453d
--- /dev/null
+++ b/npc/011-6/bryant.txt
@@ -0,0 +1,53 @@
+//NPC to set the state for killing the bandit lord.
+
+011-6.gat,27,200,0 script Bryant 126,{
+
+ if (TMW_Quest >= 45) goto L_Bryant_Quiet;
+ if (TMW_Quest == 44) goto L_Bryant_Waits;
+ if (TMW_Quest == 43) goto L_Bryant_Summon;
+
+ mes "[Bryant]";
+ mes "\"I'm looking everywhere for the bandit leader. I can't seem to find him.\"";
+ close;
+
+L_Bryant_Summon:
+ mes "[Bryant]";
+ mes "\"I ran into that bandit lord and he got me good. I'm going to stay here for a while and heal. He dropped this key. Take it. You might be able to handle him better than I could.\"";
+ next;
+ mes "Bryant gives you a key, shaped to look like a small silver arrow.";
+ next;
+ mes "\"I believe I saw him run into a cave south and east of here. There is a red carpet in front of the cave entrance. Be careful and good luck.\"";
+ set TMW_Quest, 44;
+ monster "011-6.gat",260,250,"BanditLord",1064,1, "Bryant::onBanditLordDead";
+ close;
+
+onBanditLordDead:
+ set TMW_Quest, 45;
+ message strcharinfo(0), "You killed the bandit lord.";
+ end;
+
+L_Bryant_Waits:
+ mes "[Bryant]";
+ mes "\"I think the bandit lord is still around. I fear this could be dangerous for the people of Hurnscald. When you went to the cave with the red carpet in front of it, did you find him and kill him?\"";
+ menu
+ "No.", L_Bryant_No,
+ "Yes.", L_Bryant_Yes;
+ close;
+
+L_Bryant_No:
+ mes "[Bryant]";
+ mes "\"Well, maybe he ran off. I'm pretty sure he should be there now.\"";
+ killmonster "011-6.gat", "Bryant::onBanditLordDead";
+ monster "011-6.gat",260,250,"BanditLord",1064,1, "Bryant::onBanditLordDead";
+ close;
+
+L_Bryant_Yes:
+ mes "[Bryant]";
+ mes "\"I don't think you killed him. Please try to find and kill him. He should be in the cave south and east of here with the red carpet in front of it.\"";
+ close;
+
+L_Bryant_Quiet:
+ mes "[Bryant]";
+ mes "\"Glad that bandit leader got what was coming to him.\"";
+ close;
+}
diff --git a/npc/012-3_Cave/_import.txt b/npc/012-3_Cave/_import.txt
index 7d427ad8..09310f6e 100644
--- a/npc/012-3_Cave/_import.txt
+++ b/npc/012-3_Cave/_import.txt
@@ -3,3 +3,4 @@ npc: npc/012-3_Cave/_mobs.txt
npc: npc/012-3_Cave/_warps.txt
npc: npc/012-3_Cave/mana-seed.txt
npc: npc/012-3_Cave/monsters.txt
+npc: npc/012-3_Cave/warningsigns.txt
diff --git a/npc/012-3_Cave/warningsigns.txt b/npc/012-3_Cave/warningsigns.txt
new file mode 100644
index 00000000..6a71ad7e
--- /dev/null
+++ b/npc/012-3_Cave/warningsigns.txt
@@ -0,0 +1,18 @@
+//warning signs at pvp entrance!
+
+
+012-3.gat,445,61,0 script sign 187, {
+ mes "Your are about to enter a dangerous area!";
+ next;
+ mes "This area has a great distance to town. So the protection spell of the town is not active in that cave!";
+ mes "That is why other players are able to attack you.";
+ close;
+}
+
+012-3.gat,451,61,0 script sign 186, {
+ mes "Your are about to enter a dangerous area!";
+ next;
+ mes "This area has a great distance to town. So the protection spell of the town is not active in that cave!";
+ mes "That is why other players are able to attack you.";
+ close;
+}
diff --git a/npc/019-1_Snow_field/_warps.txt b/npc/019-1_Snow_field/_warps.txt
index 63b04561..1cc4b7ae 100644
--- a/npc/019-1_Snow_field/_warps.txt
+++ b/npc/019-1_Snow_field/_warps.txt
@@ -1,3 +1,6 @@
// 019-1 Snow field warps
019-1.gat,70,21 warp ToVillage 2,-1,020-1.gat,70,126
+019-1.gat,61,102 warp toRomanticPlace 2,-1,030-1.gat,60,29
+019-1.gat,96,40 warp toCave -1,-1,019-3.gat,98,27
+019-1.gat,38,75 warp toCave2 -1,-1,019-3.gat,40,97
diff --git a/npc/019-3_Snow_field/_import.txt b/npc/019-3_Snow_field/_import.txt
new file mode 100644
index 00000000..3c5b1edc
--- /dev/null
+++ b/npc/019-3_Snow_field/_import.txt
@@ -0,0 +1,3 @@
+map: 019-3.gat
+npc: npc/019-3_Snow_field/_mobs.txt
+npc: npc/019-3_Snow_field/_warps.txt
diff --git a/npc/019-3_Snow_field/_mobs.txt b/npc/019-3_Snow_field/_mobs.txt
new file mode 100644
index 00000000..d5d272ab
--- /dev/null
+++ b/npc/019-3_Snow_field/_mobs.txt
@@ -0,0 +1,7 @@
+// 019-3 Snow field mobs
+
+
+
+019-3.gat,0,0,0 script Mob019-3 -1,{
+ end;
+}
diff --git a/npc/019-3_Snow_field/_warps.txt b/npc/019-3_Snow_field/_warps.txt
new file mode 100644
index 00000000..fb2637a3
--- /dev/null
+++ b/npc/019-3_Snow_field/_warps.txt
@@ -0,0 +1,4 @@
+// 019-3 Snow field warps
+
+019-3.gat,40,99 warp WarpOutside1 -1,-1,019-1.gat,38,73
+019-3.gat,98,25 warp warpOutside2 -1,-1,019-1.gat,96,38
diff --git a/npc/020-1_Nivalis/KrickKrackKrock.txt b/npc/020-1_Nivalis/KrickKrackKrock.txt
new file mode 100755
index 00000000..e2f4746c
--- /dev/null
+++ b/npc/020-1_Nivalis/KrickKrackKrock.txt
@@ -0,0 +1,109 @@
+// author: Lien
+// reviewed by Pjotr Orial and Jenalya
+020-1.gat,82,82,0 script Criker 183, {
+
+L_Main:
+//Var
+
+ set @NPC_NAME$, "[Criker]";
+ set @BET, 50;
+//lots of array ;(
+ setarray @KRICK$, "Krick", "Krack", "Krock";
+ setarray @ITEM_RAND, 613, 537, 631, 775, 703, 640, 641, 4006, 700;
+ setarray @ITEM_HEALTH, 684, 685, 686, 687;
+
+//ends of var
+
+ mes @NPC_NAME$;
+ mes "\"Hello " + strcharinfo(0) + ", do you want to play Krick-Krack-Krock?\"";
+ menu "Let's start!", L_Start,
+ "What's this?", L_info,
+ "Well, not for the moment.", -;
+ close;
+L_Start:
+ mes @NPC_NAME$;
+ mes "\"Well, how many do you want to bet?\"";
+ input @BET;
+ if(@BET < 50 ) goto L_poor;
+ if(@BET > 2000) goto L_Too_rich;
+ if(zeny < @BET) goto L_No_Money;
+ set zeny, zeny - @BET;
+
+
+
+ set @NPC_KRICK, rand(2);
+ mes "\"Choose Krick, Krack or Krock.\"";
+ menu
+ @KRICK$[0], -,
+ @KRICK$[1], -,
+ @KRICK$[2], -;
+
+ //menu = min 1 & not 0 so I change it
+ set @menu, @menu - 1;
+
+ mes @NPC_NAME$;
+ mes "\" "+ @KRICK$[@NPC_KRICK] +" !\"";
+ if( @menu == @NPC_KRICK ) goto L_Work;
+ mes @NPC_NAME$;
+ mes "\"Too bad! You were not lucky!\"";
+ close;
+L_Work:
+ mes @NPC_NAME$;
+ mes "\"Wow amazing... What kind of present do you want?\"";
+ menu
+ "Money!", L_Money,
+ "An item!", L_Item,
+ "Some healing potions would be cool!", L_Health_item;
+ close;
+
+L_Money:
+ mes @NPC_NAME$;
+ mes "\"Here is your money.\"";
+ set zeny, zeny + (@BET*2);
+ close;
+L_Item:
+//item
+
+if( @BET > 50) getitem @ITEM_RAND[rand(1)], 1;
+if( @BET > 200) getitem @ITEM_RAND[1 + rand(1)], 1;
+if( @BET > 500) getitem @ITEM_RAND[2 + rand(1)], 1;
+if( @BET > 1000) getitem @ITEM_RAND[3 + rand(1)], 1;
+if( @BET > 1200) getitem @ITEM_RAND[4 + rand(1)], 1;
+if( @BET > 1500) getitem @ITEM_RAND[5 + rand(1)], 1;
+if( @BET == 2000) getitem @ITEM_RAND[6 + rand(1)], 1;
+ mes @NPC_NAME$;
+ mes "\"Here it is !\"";
+ close;
+
+L_Health_item:
+// health item
+
+if( @BET > 50) getitem @ITEM_HEALTH[rand(1)], 1;
+if( @BET > 200) getitem @ITEM_HEALTH[ 1 +rand(1)], 1 + rand(1);
+if( @BET > 500) getitem @ITEM_HEALTH[2 + rand(1)], 1 + rand(3);
+if( @BET > 1000) getitem @ITEM_HEALTH[3], 2 + rand(1);
+if( @BET > 1500) getitem @ITEM_HEALTH[3], 3 + rand(2);
+if( @BET == 2000) getitem @ITEM_HEALTH[3], 5 + rand(10);
+ mes @NPC_NAME$;
+ mes "\"Here it is !\"";
+ close;
+
+
+L_poor:
+ mes @NPC_NAME$;
+ mes "\"Erm... if you want to play you HAVE to bet, and you can't bet "+ @BET +" gold pieces. You need at least 50gp.\"";
+ close;
+L_Too_rich:
+ mes @NPC_NAME$;
+ mes "\"Mh... I have to bet too. How I'll get a present which is "+ @BET +"? No, that's too much.\"";
+ close;
+L_No_Money:
+ mes @NPC_NAME$;
+ mes "\"Oh? You don't have "+ @BET +" gold pieces.\"";
+ close;
+L_info:
+ mes @NPC_NAME$;
+ mes "\"Well, if you want to play Krick Krack Krock with me, you need to bet some money. We will both say a word (Krack, Krick or Krock). If we say the same, you can win the double of your money or an item worth of what you bet. \"";
+ goto L_Main;
+}
+
diff --git a/npc/020-1_Nivalis/_import.txt b/npc/020-1_Nivalis/_import.txt
index 4b64cf8d..d76777a4 100644
--- a/npc/020-1_Nivalis/_import.txt
+++ b/npc/020-1_Nivalis/_import.txt
@@ -1,6 +1,8 @@
map: 020-1.gat
+npc: npc/020-1_Nivalis/KrickKrackKrock.txt
+npc: npc/020-1_Nivalis/rockscissor.txt
npc: npc/020-1_Nivalis/_mobs.txt
npc: npc/020-1_Nivalis/_warps.txt
npc: npc/020-1_Nivalis/mapflags.txt
npc: npc/020-1_Nivalis/soul-menhir.txt
-npc: npc/020-1_Nivalis/startrek.txt
+npc: npc/020-1_Nivalis/well.txt
diff --git a/npc/020-1_Nivalis/_warps.txt b/npc/020-1_Nivalis/_warps.txt
index c9578dfc..a8e5b772 100644
--- a/npc/020-1_Nivalis/_warps.txt
+++ b/npc/020-1_Nivalis/_warps.txt
@@ -7,3 +7,5 @@
020-1.gat,64,82 warp toInn -1,-1,020-2.gat,111,31
020-1.gat,86,46 warp toWeaponShop -1,-1,020-2.gat,32,72
020-1.gat,56,90 warp ToPotionsShop -1,-1,020-2.gat,66,25
+020-1.gat,70,127 warp toSnowField 2,-1,019-1.gat,70,22
+020-1.gat,107,55 warp toPort -1,-1,031-1.gat,38,55
diff --git a/npc/020-1_Nivalis/mapflags.txt b/npc/020-1_Nivalis/mapflags.txt
index b96ea2f6..203cf649 100644
--- a/npc/020-1_Nivalis/mapflags.txt
+++ b/npc/020-1_Nivalis/mapflags.txt
@@ -1,7 +1,2 @@
-//
-
-019-1.gat mapflag nosave 009-1,54,39;
-020-1.gat mapflag nosave 009-1,54,39;
-020-2.gat mapflag nosave 009-1,54,39;
-020-3.gat mapflag nosave 009-1,54,39;
-020-4.gat mapflag nosave 009-1,54,39;
+020-1.gat mapflag no_player_drops
+020-1.gat mapflag town
diff --git a/npc/020-1_Nivalis/rockscissor.txt b/npc/020-1_Nivalis/rockscissor.txt
new file mode 100755
index 00000000..db813518
--- /dev/null
+++ b/npc/020-1_Nivalis/rockscissor.txt
@@ -0,0 +1,89 @@
+// author: Lien
+// reviewed by Pjotr Orial and Jenalya
+//#####################################
+//== NPC [Player] #
+// anyone want to do a funny bet #
+// ------------------------ #
+// Rock-Paper-Scissors can be playing #
+// I hope that'll make fun #
+// ------------------------ #
+//#####################################
+
+020-1.gat,74,78,0 script Gobmel 183, {
+ //var
+ set @NPC_name$, "[Gobmel]";
+ set @NPC_point, 0;
+ set @PC_point, 0;
+ set @gamblerun, 0;
+ setarray @CHOOSE_PC$, "Scissors", "Paper", "Rock";
+ setarray @CHOSE_ID, 0, 1, 2;
+ //0 : scissors; 1: Paper; 2: Rock;
+ // 0 cut 1 and 1 cover 3 and break 0 ...
+ //var ends
+
+ mes @NPC_name$;
+ mes "\"Hello " + strcharinfo(0) + "! Do you want to do a little party of Rock-Paper-Scissors and bet some gold?\"";
+ menu
+ "Yes, I want.", L_RPS,
+ "Well, maybe later.", -;
+ close;
+
+L_RPS:
+
+ mes @NPC_name$;
+ mes "\"How much money do you want to bet?\"";
+ input @MONEY_BET;
+ if(zeny < @MONEY_BET) goto L_poor;
+ set zeny, zeny - @MONEY_BET;
+
+L_Start:
+ if(@gamblerun == 3) goto L_finish;
+ //what chose the NPC ?
+
+ set @CHOOSE_NPCID, rand(2);
+
+ mes @NPC_name$;
+ mes "[ " + @gamblerun + "/3 ]";
+ mes "\"1... 2... 3...\"";
+ mes"[chose what sign you do]";
+ menu
+ @CHOOSE_PC$[0], -,
+ @CHOOSE_PC$[1], -,
+ @CHOOSE_PC$[2], -;
+
+ set @CHOSEN, @menu -1;
+ mes @CHOOSE_PC$[@CHOOSE_NPCID];
+ mes strcharinfo(0)+" " + strcharinfo(0)+ ":" +@CHOOSE_PC$[@CHOSEN];
+ if(@CHOSEN == @CHOOSE_NPCID) goto L_Start;
+ if(@CHOSEN == 0 && @CHOOSE_NPCID == 2) goto L_Lost;
+ if(@CHOSEN == 1 && @CHOOSE_NPCID == 0) goto L_Lost;
+ if(@CHOSEN == 2 && @CHOOSE_NPCID == 1) goto L_Lost;
+L_Win:
+ set @PC_point, @PC_point + 1;
+ set @gamblerun, @gamblerun + 1;
+ mes "Oh no! I have lost.";
+ goto L_Start;
+
+L_poor:
+ mes @NPC_name$;
+ mes "\"Go away from me...\"";
+ close;
+
+L_Lost:
+ set @NPC_point, @NPC_point + 1;
+ set @gamblerun, @gamblerun + 1;
+ mes "I have won!";
+ goto L_Start;
+
+L_finish:
+ if(@PC_point > @NPC_point ) goto L_Won;
+ mes @NPC_name$;
+ mes "\"Nice ! I have won, give your gp!\"";
+ close;
+L_Won:
+ mes @NPC_name$;
+ mes "\"Here is my money\"";
+ set zeny, zeny + @MONEY_BET*2;
+ close;
+}
+
diff --git a/npc/020-1_Nivalis/startrek.txt b/npc/020-1_Nivalis/startrek.txt
deleted file mode 100644
index 5c8847ad..00000000
--- a/npc/020-1_Nivalis/startrek.txt
+++ /dev/null
@@ -1,20 +0,0 @@
-//
-
-020-1.gat,79,77,0 script Kirk 133,{
- mes "[Capt. Kirk]";
- mes "\"Spock: We're breaking the prime directive.";
- mes "This is not the right way to have the first contact.\"";
- close;
-}
-
-020-1.gat,81,77,0 script Spock 134,{
- mes "[Spock]";
- mes "\"Live long and prosper captain.\"";
- next;
-
- mes "[Spock]";
- mes "\"trr...Spock to Scotty...";
- mes "Beam me to the elves village...";
- mes "I will hide there.\"";
- close;
-}
diff --git a/npc/020-1_Nivalis/well.txt b/npc/020-1_Nivalis/well.txt
new file mode 100755
index 00000000..4c200be8
--- /dev/null
+++ b/npc/020-1_Nivalis/well.txt
@@ -0,0 +1,117 @@
+//############################################
+//# NPC Well & Miler
+//# Authors: Lien, PjotrOrial
+//# Review:
+//#
+//# There is someone in the well. This can be found out by throwing some stuff
+//# in there.
+//#
+//# When the npc in the well is detected they can be rescued by asking Miler
+//# for help.
+//#
+//# The experience reward given by Miler is 111 * Baselevel
+//#
+//# used variables: QUEST_Nivalis_state Nibble4
+//############################################
+
+020-1.gat,99,83,0 script #Well 127, {
+
+ set @Q_MASK, NIBBLE_4_MASK;
+ set @Q_SHIFT, NIBBLE_4_SHIFT;
+ set @Q_status, ((QUEST_Nivalis_state) & @Q_MASK) >> @Q_SHIFT;
+
+if(@Q_status == 2) goto L_Finished;
+ set @item_ID, 0;
+ setarray @quote_item$, "Yuck! Who has thrown that on me?","Ouch! Who hurts me?","White powder!? What's going on up there?","Ahw! It's raining ","","","";
+
+ mes "...";
+ menu "Throw something in the well.", L_trew,
+ "Leave it alone.", -;
+ close;
+
+L_trew:
+ mes "What do you want to throw?";
+ menu "Maggot slime", -,
+ "A raw log", -,
+ "Pile of ash", -,
+ "Bottle of water", -,
+ "Leave it alone", L_Close;
+
+ set @menu, @menu - 1;
+
+ // little IF to do @quote$ & @Item_ID
+ set @quote$, @quote_item$[@menu];
+ if(@menu == 0) set @item_ID, 505;
+ if(@menu == 1) set @item_ID, 569;
+ if(@menu == 2) set @item_ID, 701;
+ if(@menu == 3) set @item_ID, 541;
+
+ if(countitem(@item_ID) < 1) goto L_NO_ITEM;
+ if(@menu == 3) getitem 540, 1;
+ delitem @item_ID, 1;
+
+ mes "[Mysterious voice inside the well]";
+ mes "\" "+ @quote$ +"\"";
+ next;
+ menu "Who are you?", -,
+ "How did you get there?", -,
+ "Do you need help?", -;
+
+ set @menu, @menu - 1;
+ if(@menu == 0) set @quote$, "I'll talk about who I am after leaving the well.";
+ if(@menu == 1) set @quote$, "Well, someone has pushed me in the well, I don't know who did that.";
+ if(@menu == 2) set @quote$, "";
+ mes "[Mysterious voice inside the well]";
+ mes "\" "+ @quote$ +". So if you can call help for me... please do so!\"";
+ set @Q_status, 1;
+ callsub S_Update_Var;
+ close;
+
+L_NO_ITEM:
+ mes "You don't have such an item... Come back when you have it.";
+ close;
+
+L_Finished:
+ mes "This is a well.";
+ close;
+
+L_Close:
+ close;
+
+S_Update_Var:
+ set QUEST_Nivalis_state,
+ (QUEST_Nivalis_state & ~(@Q_MASK)
+ | (@Q_status << @Q_SHIFT));
+ return;
+}
+
+020-2.gat,100,28,0 script Miler 100, {
+ set @Q_MASK, NIBBLE_4_MASK;
+ set @Q_SHIFT, NIBBLE_4_SHIFT;
+ set @Q_status, ((QUEST_Nivalis_state) & @Q_MASK) >> @Q_SHIFT;
+
+ mes "[Miler]";
+ mes "\"Hello!\"";
+ if(@Q_status == 2) close;
+ if(@Q_status == 1)
+ menu "Hello.", -,
+ "Hello, Can you help me?", L_HELP;
+ close;
+L_HELP:
+ mes "[Miler]";
+ mes "\"What's the problem?\"";
+ menu "Someone has fallen in the well.", -;
+ mes "[Miler]";
+ mes "\"Ho! I'll help him!\"";
+ getexp (BaseLevel * 111), 0;
+ set @Q_status, 2;
+ callsub S_Update_Var;
+ close;
+
+S_Update_Var:
+ set QUEST_Nivalis_state,
+ (QUEST_Nivalis_state & ~(@Q_MASK)
+ | (@Q_status << @Q_SHIFT));
+ return;
+}
+
diff --git a/npc/020-2_Nivalis/_import.txt b/npc/020-2_Nivalis/_import.txt
index 807bc1a0..04feb1ae 100644
--- a/npc/020-2_Nivalis/_import.txt
+++ b/npc/020-2_Nivalis/_import.txt
@@ -1,6 +1,6 @@
map: 020-2.gat
npc: npc/020-2_Nivalis/_mobs.txt
npc: npc/020-2_Nivalis/_warps.txt
+npc: npc/020-2_Nivalis/baktar.txt
npc: npc/020-2_Nivalis/mapflags.txt
npc: npc/020-2_Nivalis/shops.txt
-npc: npc/020-2_Nivalis/taro.txt
diff --git a/npc/020-2_Nivalis/baktar.txt b/npc/020-2_Nivalis/baktar.txt
new file mode 100755
index 00000000..b037d7bb
--- /dev/null
+++ b/npc/020-2_Nivalis/baktar.txt
@@ -0,0 +1,389 @@
+//#=========================
+//#== NPC Baktar
+//# Authors: Lien, PjotrOrial
+//# Review: BigCrunch, Mistakes, Jenalya
+//# This NPC has two stages:
+//#
+//# In the first stage you need to bring 7 different items, but only one of each kind.
+//#
+//#
+//# In the second stage he tells you what hard life he is living. He will be very aggressive telling you some stuff.
+//# He will send you to kill Scroticular. That npc will be located in the labyrinth caves.
+//# (its a mob actually, to be spawned only, if the players knows his name and his location)
+//#
+//# variables used:
+//# @QUEST_Nivalis_state: NIBBLE0, NIBBLE1, NIBBLE2, NIBBLE3:
+//# BYTE0 ( == NIBBLE0 | NIBBLE1) stores in each bit information if that item was already brought.
+//# bits:
+//# bit 0 if you have met the npc already
+//# bit 1 Desert Hat
+//# bit 2 Desert Shirt
+//# bit 3 Serf Hat
+//# bit 4 tongue_Item
+//# bit 5 eggs_Item
+//# bit 6 skin_Item
+//# bit 7 bugleg
+//# NIBBLE2 store the progress after the item collecting stage:
+//# =0 he will thank you for bringing all stuff.
+//# =1 talking about his youth
+//# =2 talking, you get the mission to hunt down Scroticular
+//# =3 you get information where Scroticular can be found.
+//# NIBBLE3 a bitmasking nibble for stage 2 again
+//# bit 0 knows the name/location of the opponent
+//# bit 1 killed the ugly opponent
+//#=========================
+020-2.gat,70,61,0 script Baktar 183,{
+ set @npcname$, "[Baktar]";
+
+ set @Q_MASK, BYTE_0_MASK;
+ set @Q_SHIFT, BYTE_0_SHIFT;
+ set @Q_status, ((QUEST_Nivalis_state) & @Q_MASK) >> @Q_SHIFT;
+
+ set @Q_MASK2, NIBBLE_2_MASK;
+ set @Q_SHIFT2, NIBBLE_2_SHIFT;
+ set @Q_status2, ((QUEST_Nivalis_state) & @Q_MASK2) >> @Q_SHIFT2;
+
+ set @Q_MASK2_BITS, NIBBLE_3_MASK;
+ set @Q_SHIFT2_BITS, NIBBLE_3_SHIFT;
+ set @Q_status2_bits, ((QUEST_Nivalis_state) & @Q_MASK2_BITS) >> @Q_SHIFT2_BITS;
+
+ // if all bits are set, you brought him everything! Now we continue in Phase 2 of this npc.
+ mes @Q_status;
+ if(@Q_status == @Q_MASK) goto L_2_init;
+
+ set @BIT_KNOWHIM, 0;
+
+ set @BIT_DESERTHAT,1;
+ set @MONEY_DESERTHAT, 1500;
+ set @XP_DESERTHAT, 500;
+
+ set @BIT_DESERTSHIRT,2;
+ set @MONEY_DESERTSHIRT, 1500;
+ set @XP_DESERTSHIRT, 600;
+
+ set @BIT_SERFHAT,3;
+ set @MONEY_SERFHAT, 800;
+ set @XP_SERFHAT, 350;
+
+ set @BIT_MS_TONGUE,4;
+ set @MONEY_MS_TONGUE, 800;
+ set @XP_MS_TONGUE, 350;
+
+ set @BIT_MS_EGG,5;
+ set @MONEY_MS_EGG, 800;
+ set @XP_MS_EGG, 350;
+
+ set @BIT_SNAKESKIN,6;
+ set @MONEY_SNAKESKIN, 800;
+ set @XP_SNAKESKIN, 350;
+
+ set @BIT_BUGLEG,7;
+ set @MONEY_BUGLEG, 20;
+ set @XP_BUGLEG, 130;
+
+ if(sex)
+ set @type$, "man";
+ if(!sex)
+ set @type$, "woman";
+
+ if(@Q_status & (1<<@BIT_KNOWHIM)) goto L_KnowAlready;
+ mes @npcname$;
+ mes "\"Hello, " + @type$ + ", did you come from Tulimshar? Because you have a nice tan. \"";
+ menu
+ "Yes, I'm from Tulimshar", L_exotic,
+ "Well, I just like sunbathing", -,
+ "Good bye", -;
+ close;
+
+L_KnowAlready:
+ mes @npcname$;
+ mes "\"So, you have a new item?\"";
+ goto L_startitem;
+close;
+
+L_exotic:
+ mes @npcname$;
+ mes "\"I said that because I love Tulimshar's stuff ... if you give me an interesting item maybe I can give you a nice reward. But I don't need lots of stuff, I need only one example of each item.\"";
+ menu "I have some items on me maybe you'll like them ", L_startitem,
+ "Don't touch my stuff!", -,
+ "I'll get them. Bye.", -;
+ close;
+
+L_startitem:
+ setarray @exotic_item$, "", "", "", "", "", "", "";
+ set @c, 0;
+ set @Q_status, @Q_status | (1<<@BIT_KNOWHIM);
+ callsub S_Update_Var;
+ if (countitem("DesertHat") < 1 || @Q_status & (1<<@BIT_DESERTHAT) ) goto L_DesertShirt;
+ set @exotic_item$[@c], "a Desert Hat ?";
+ set @menuid[@c], 0;
+ set @c, @c + 1;
+
+L_DesertShirt:
+ if (countitem("DesertShirt") < 1 || @Q_status & (1<<@BIT_DESERTSHIRT) ) goto L_SerfHat;
+ set @exotic_item$[@c], "a Desert Shirt ?";
+ set @menuid[@c], 1;
+ set @c, @c + 1;
+
+L_SerfHat:
+ if (countitem("SerfHat") < 1 || @Q_status & (1<<@BIT_SERFHAT) ) goto L_tongue;
+ set @exotic_item$[@c], "a Serf Hat ?";
+ set @menuid[@c], 2;
+ set @c, @c + 1;
+
+L_tongue:
+ if (countitem("MountainSnakeTongue") < 1 || @Q_status & (1<<@BIT_MS_TONGUE)) goto L_egg;
+ set @exotic_item$[@c], "a Mountain Snake Tongue ?";
+ set @menuid[@c], 3;
+ set @c, @c + 1;
+
+L_egg:
+ if (countitem("MountainSnakeEgg") < 1 || @Q_status & (1<<@BIT_MS_EGG)) goto L_Skin;
+ set @exotic_item$[@c], "a Mountain Snake Egg?";
+ set @menuid[@c], 4;
+ set @c, @c + 1;
+
+L_Skin:
+ if (countitem("SnakeSkin") < 1 || @Q_status & (1<<@BIT_SNAKESKIN)) goto L_bugleg;
+ set @exotic_item$[@c], "a Snake Skin?";
+ set @menuid[@c], 5;
+ set @c, @c + 1;
+
+L_bugleg:
+ if (countitem("BugLeg") < 1 || @Q_status & (1<<@BIT_BUGLEG)) goto L_NeverMind;
+ set @exotic_item$[@c], "a Bug Leg?";
+ set @menuid[@c], 6;
+ set @c, @c + 1;
+
+L_NeverMind:
+ set @exotic_item$[@c], "Nevermind";
+ set @menuid[@c], 6;
+//menu for the item
+ menu
+ @exotic_item$[0], -,
+ @exotic_item$[1], -,
+ @exotic_item$[2], -,
+ @exotic_item$[3], -,
+ @exotic_item$[4], -,
+ @exotic_item$[5], -,
+ @exotic_item$[6], -;
+
+ set @menu, @menu -1;
+
+ if (@menuid[@menu] == 0) goto L_DesertHat_Item;
+ if (@menuid[@menu] == 1) goto L_DesertShirt_Item;
+ if (@menuid[@menu] == 2) goto L_SerfHat_Item;
+ if (@menuid[@menu] == 3) goto L_tongue_Item;
+ if (@menuid[@menu] == 4) goto L_egg_Item;
+ if (@menuid[@menu] == 5) goto L_skin_Item;
+ if (@menuid[@menu] == 6) goto L_BugLegItem;
+//if Never mind
+ mes @npcname$;
+ mes "\"Ok, goodbye then.\"";
+ close;
+L_DesertHat_Item:
+ if(@Q_status & (1<<@BIT_DESERTHAT)) goto L_havealready;
+ if (countitem("DesertHat") < 1) goto L_Noitem;
+ delitem "DesertHat", 1;
+ set zeny, zeny + @MONEY_DESERTHAT;
+ getexp @XP_DESERTHAT,0;
+ set @Q_status, @Q_status | (1<<@BIT_DESERTHAT);
+ callsub S_Update_Var;
+ close;
+L_DesertShirt_Item:
+ if(@Q_status & (1<<@BIT_DESERTSHIRT)) goto L_havealready;
+ if (countitem("DesertShirt") < 1) goto L_Noitem;
+ delitem "DesertShirt", 1;
+ set zeny, zeny + @MONEY_DESERTSHIRT;
+ getexp @XP_DESERTSHIRT,0;
+ set @Q_status, @Q_status | (1<<@BIT_DESERTSHIRT);
+ callsub S_Update_Var;
+ close;
+L_SerfHat_Item:
+ if(@Q_status & (1<<@BIT_SERFHAT)) goto L_havealready;
+ if (countitem("SerfHat") < 1) goto L_Noitem;
+ delitem "SerfHat", 1;
+ set zeny, zeny + @MONEY_SERFHAT;
+ getexp @XP_SERFHAT,0;
+ set @Q_status, @Q_status | (1<<@BIT_SERFHAT);
+ callsub S_Update_Var;
+ close;
+L_tongue_Item:
+ if(@Q_status & (1<<@BIT_MS_TONGUE)) goto L_havealready;
+ if (countitem("MountainSnakeTongue") < 1) goto L_Noitem;
+ delitem "MountainSnakeTongue", 1;
+ set zeny, zeny + @MONEY_MS_TONGUE;
+ getexp @XP_MS_TONGUE,0;
+ set @Q_status, @Q_status | (1<<@BIT_MS_TONGUE);
+ callsub S_Update_Var;
+close;
+L_egg_Item:
+ if(@Q_status & (1<<@BIT_MS_EGG)) goto L_havealready;
+ if (countitem("MountainSnakeEgg") < 1) goto L_Noitem;
+ delitem "MountainSnakeEgg", 1;
+ set zeny, zeny + @MONEY_MS_EGG;
+ getexp @XP_MS_EGG,0;
+ set @Q_status, @Q_status | (1<<@BIT_MS_EGG);
+ callsub S_Update_Var;
+close;
+L_skin_Item:
+ if(@Q_status & (1<<@BIT_SNAKESKIN)) goto L_havealready;
+ if (countitem("SnakeSkin") < 1) goto L_Noitem;
+ delitem "SnakeSkin", 1;
+ set zeny, zeny + @MONEY_SNAKESKIN;
+ getexp @XP_SNAKESKIN,0;
+ set @Q_status, @Q_status | (1<<@BIT_SNAKESKIN);
+ callsub S_Update_Var;
+close;
+L_BugLegItem:
+ if(@Q_status & (1<<@BIT_BUGLEG)) goto L_havealready;
+ if (countitem("BugLeg") < 1) goto L_Noitem;
+ delitem "BugLeg", 1;
+ set zeny, zeny + @MONEY_BUGLEG;
+ getexp @XP_BUGLEG,0;
+ set @Q_status, @Q_status | (1<<@BIT_BUGLEG);
+ callsub S_Update_Var;
+close;
+
+L_Noitem:
+ mes @npcname$;
+ mes "\"Where is your item?\"";
+ close;
+
+L_havealready:
+ mes @npcname$;
+ mes "\"Well, I already have one of those.\"";
+ close;
+
+S_Update_Var:
+ set QUEST_Nivalis_state,
+ (QUEST_Nivalis_state & ~(@Q_MASK)
+ | (@Q_status << @Q_SHIFT));
+ return;
+
+
+
+//# The following stage is completely cutoff the first.
+//# So there is no linking between the upper and lower part, except for one goto at the very beginning
+//
+
+L_2_init:
+
+//# NIBBLE3 a bitmasking nibble for stage 2 again
+//# bit 0 knows the name of the opponent
+//# bit 1 killed the ugly opponent
+ set @BIT_KNOWS_NAME, 0;
+ set @BIT_KILLED_HIM, 1;
+
+ if (@Q_status2 == 1) goto L_2_talk1;
+ if (@Q_status2 == 2) goto L_2_talk2;
+ if (@Q_status2 == 3) goto L_2_talk3;
+ if (@Q_status2 == 4) goto L_2_talk4;
+ // fall through @Q_status2==0:
+ // need to thank for bringing all stuff.
+ mes @npcname$;
+ mes "\"Thanks a lot for bringing me all this nice stuff!\"";
+ next;
+ mes "\"That helps me a lot. You see over there is already another set I collected: There are some pieces of the Hurnscald town. That sign there has been stolen from the inn.\"";
+ next;
+ mes "\"But do not tell anyone, please! I really like collecting things. And that sign is one of the first things I organized.\"";
+ next;
+ mes "\"So thank you for bringing me that stuff for my desert collection\"";
+ next;
+ mes "\"Do you have an idea how to arrange that to make it cool looking for my admirers?\"";
+ next;
+ set @Q_status2, 1;
+ callsub S_Update_Var2;
+ close;
+
+L_2_talk1:
+ mes @npcname$;
+ mes "\"In my childhood I was called a packrat, because I collected old cans.\"";
+ next;
+ mes "\"But everybody does collect things right?\"";
+ next;
+ mes "\"So after I had collected way over 1000 cans, I started collecting snail-shells. Nice? Do you like that?\"";
+ next;
+ mes "\"Not many people like me. And I don't know why. It is nice to talk about such nice things. What did you collect in your childhood?\"";
+ next;
+ mes "He picks in his nose";
+ next;
+ mes @npcname$;
+ mes "\"Ok erm, talk to you later.\"";
+ next;
+ mes "\"Ok.\"";
+ set @Q_status2, 2;
+ callsub S_Update_Var2;
+ close;
+
+L_2_talk2:
+ mes @npcname$;
+ mes "\"Could you do me a favor? This ugly guy, who always attacked me....\"";
+ next;
+ mes "\"*sob*\"";
+ next;
+ mes "\"I was always bullied by him. You know in the early childhood we were very nice friends. We played some roleplaying. He was the captain, and I was the soldier.";
+ next;
+ mes "\"Or another day he was the chieftain and I was the redskin.\"";
+ next;
+ mes "\"but to tell you the truth, HE was ALWAYS the one who directed me.\"";
+ next;
+ mes "\"I DO NOT LIKE THAT!\"";
+ next;
+ mes "\"I WANT TO BE THE LEADER!\"";
+ next;
+ mes "\"STOP HIM DOING NASTY THINGS\"";
+ next;
+ mes "\"I WANT YOU TO KILL THAT BASTARD!!\"";
+ set @Q_status2, 3;
+ callsub S_Update_Var2;
+ close;
+
+L_2_talk3:
+ menu "Ok, I am a professional in doing such things", L_2_professional,
+ "Hey do you really mean it? ", L_2_professional,
+ "You calmed down again?", -,
+ "Oh a packrat! By the way, is that trash over there yours?", L_2_name,
+ "Nevermind", -;
+ mes @npcname$;
+ mes "\"Get out of my way, prank!\"";
+ close;
+
+L_2_professional:
+ mes @npcname$;
+ mes "\"What are you talking about?\"";
+ goto L_2_talk3;
+
+L_2_name:
+ mes @npcname$;
+ mes "\"ONE DAY I WILL GET A HUGE REVENGE!\"";
+ next;
+ mes "\"AND I MEAN IT!\"";
+ next;
+ mes "\"You see I am a dangerous killer. Last week I killed five slimes and a pinkie!\"";
+ next;
+ mes "He takes out a piece of paper... mumbling";
+ mes "\"Ok Scroticular first, and then ...\"";
+ set @Q_status2, 4;
+ set @Q_status2_bits, @Q_status2_bits | (1<<@BIT_KNOWS_NAME);
+ callsub S_Update_Var2;
+
+ mes @npcname$;
+ mes "\"What is your name again?\"";
+
+ menu "I am sorry for the joke... Please forgive me", -,
+ "They call me Mistakes. I am a professional killer as well. You heard about that business in the terranite cave?", -;
+ mes @npcname$;
+ mes "\"Alright, I see. Ok maybe I really need to calm down. Please let me alone... I will try to calm down, ok?\"";
+ close;
+
+S_Update_Var2:
+ set QUEST_Nivalis_state,
+ (QUEST_Nivalis_state & ~(@Q_MASK2)
+ | (@Q_status2 << @Q_SHIFT2));
+ set QUEST_Nivalis_state,
+ (QUEST_Nivalis_state & ~(@Q_MASK2_BITS)
+ | (@Q_status2_bits << @Q_SHIFT2_BITS));
+ return;
+}
+
diff --git a/npc/020-2_Nivalis/shops.txt b/npc/020-2_Nivalis/shops.txt
index f1b452b5..1d863a00 100644
--- a/npc/020-2_Nivalis/shops.txt
+++ b/npc/020-2_Nivalis/shops.txt
@@ -3,7 +3,7 @@
// Clothes shop
020-2.gat,27,26,0 shop Taylor 137,523:2000,524:1600,543:800,544:5000,546:10000,586:1000,741:-1
// Weapons shop
-020-2.gat,25,65,0 shop Bracco 135,1201:50,521:1000,522:100,545:20000,529:5
+020-2.gat,25,65,0 shop Bracco 135,1201:50,521:1000,522:100,529:5,530:-1
// Potions shop
020-2.gat,75,26,0 shop Mede 103,501:50,502:70,567:500,568:500
@@ -13,9 +13,9 @@
set @cost, 100;
mes "[" + @npcName$ + "]";
- mes "\"Welcome strangers.";
- mes "What? You've already seen an INN like mine?";
- mes "That's impossible!\"";
+ mes "\"Welcome stranger!\"";
+ mes "\"What? You've already seen an INN like mine?\"";
+ mes "\"That's impossible!\"";
next;
callfunc "Inn";
close;
diff --git a/npc/020-3_Ice_cave/_warps.txt b/npc/020-3_Ice_cave/_warps.txt
index 51539391..3b4babf7 100644
--- a/npc/020-3_Ice_cave/_warps.txt
+++ b/npc/020-3_Ice_cave/_warps.txt
@@ -1,4 +1,9 @@
// 020-3 Ice cave warps
020-3.gat,31,25 warp toOutside -1,-1,020-1.gat,76,37
-020-3.gat,25,22 warp toIceCave2 -1,-1,020-4.gat,36,34
+020-3.gat,25,22 warp toRightLowerCave -1,-1,020-3.gat,97,101
+020-3.gat,97,99 warp toLeftUpperCave -1,-1,020-3.gat,25,24
+020-3.gat,28,57 warp toLeftLowerCave -1,-1,020-3.gat,33,100
+020-3.gat,49,33 warp ToRightUpperCave -1,-1,020-3.gat,110,55
+020-3.gat,33,98 warp toLeftUpperCave -1,-1,020-3.gat,28,54
+020-3.gat,110,57 warp ToLeftUpperCave -1,-1,020-3.gat,49,35
diff --git a/npc/027-3/_import.txt b/npc/027-3/_import.txt
new file mode 100644
index 00000000..0d6c8819
--- /dev/null
+++ b/npc/027-3/_import.txt
@@ -0,0 +1,3 @@
+map: 027-3.gat
+npc: npc/027-3/_mobs.txt
+npc: npc/027-3/_warps.txt
diff --git a/npc/027-3/_mobs.txt b/npc/027-3/_mobs.txt
new file mode 100644
index 00000000..dcf52c02
--- /dev/null
+++ b/npc/027-3/_mobs.txt
@@ -0,0 +1,7 @@
+// 027-3 mobs
+
+
+
+027-3.gat,0,0,0 script Mob027-3 -1,{
+ end;
+}
diff --git a/npc/027-3/_warps.txt b/npc/027-3/_warps.txt
new file mode 100644
index 00000000..650f6e5a
--- /dev/null
+++ b/npc/027-3/_warps.txt
@@ -0,0 +1,4 @@
+// 027-3 warps
+
+027-3.gat,127,44 warp toCryptLevel2 1,-1,027-4.gat,37,21
+027-3.gat,41,75 warp toGraveyard 2,-1,027-1.gat,28,69
diff --git a/npc/030-1_Snow_field/_import.txt b/npc/030-1_Snow_field/_import.txt
new file mode 100644
index 00000000..97064443
--- /dev/null
+++ b/npc/030-1_Snow_field/_import.txt
@@ -0,0 +1,3 @@
+map: 030-1.gat
+npc: npc/030-1_Snow_field/_mobs.txt
+npc: npc/030-1_Snow_field/_warps.txt
diff --git a/npc/030-1_Snow_field/_mobs.txt b/npc/030-1_Snow_field/_mobs.txt
new file mode 100644
index 00000000..a614f4a2
--- /dev/null
+++ b/npc/030-1_Snow_field/_mobs.txt
@@ -0,0 +1,7 @@
+// 030-1 Snow field mobs
+
+
+
+030-1.gat,0,0,0 script Mob030-1 -1,{
+ end;
+}
diff --git a/npc/030-1_Snow_field/_warps.txt b/npc/030-1_Snow_field/_warps.txt
new file mode 100644
index 00000000..73106d6d
--- /dev/null
+++ b/npc/030-1_Snow_field/_warps.txt
@@ -0,0 +1,3 @@
+// 030-1 Snow field warps
+
+030-1.gat,61,28 warp toSnowfield 0,-1,019-1.gat,61,100
diff --git a/npc/031-1_NivalisPort/_import.txt b/npc/031-1_NivalisPort/_import.txt
new file mode 100644
index 00000000..d256e273
--- /dev/null
+++ b/npc/031-1_NivalisPort/_import.txt
@@ -0,0 +1,3 @@
+map: 031-1.gat
+npc: npc/031-1_NivalisPort/_mobs.txt
+npc: npc/031-1_NivalisPort/_warps.txt
diff --git a/npc/031-1_NivalisPort/_mobs.txt b/npc/031-1_NivalisPort/_mobs.txt
new file mode 100644
index 00000000..dc109dc5
--- /dev/null
+++ b/npc/031-1_NivalisPort/_mobs.txt
@@ -0,0 +1,7 @@
+// 031-1 NivalisPort mobs
+
+
+
+031-1.gat,0,0,0 script Mob031-1 -1,{
+ end;
+}
diff --git a/npc/031-1_NivalisPort/_warps.txt b/npc/031-1_NivalisPort/_warps.txt
new file mode 100644
index 00000000..ca2bdc30
--- /dev/null
+++ b/npc/031-1_NivalisPort/_warps.txt
@@ -0,0 +1,4 @@
+// 031-1 NivalisPort warps
+
+031-1.gat,37,55 warp toNivalis -1,-1,020-1.gat,106,55
+031-1.gat,76,24 warp toLabyrinth -1,-1,031-3.gat,212,298
diff --git a/npc/031-3/_import.txt b/npc/031-3/_import.txt
new file mode 100644
index 00000000..4562f635
--- /dev/null
+++ b/npc/031-3/_import.txt
@@ -0,0 +1,4 @@
+map: 031-3.gat
+npc: npc/031-3/_mobs.txt
+npc: npc/031-3/_warps.txt
+npc: npc/031-3/labyrinth.txt
diff --git a/npc/031-3/_mobs.txt b/npc/031-3/_mobs.txt
new file mode 100644
index 00000000..a86150c7
--- /dev/null
+++ b/npc/031-3/_mobs.txt
@@ -0,0 +1,7 @@
+// 031-3 mobs
+
+
+
+031-3.gat,0,0,0 script Mob031-3 -1,{
+ end;
+}
diff --git a/npc/031-3/_warps.txt b/npc/031-3/_warps.txt
new file mode 100644
index 00000000..a15033a1
--- /dev/null
+++ b/npc/031-3/_warps.txt
@@ -0,0 +1,3 @@
+// 031-3 warps
+
+031-3.gat,212,300 warp toOutside -1,-1,031-1.gat,76,26
diff --git a/npc/031-3/labyrinth.txt b/npc/031-3/labyrinth.txt
new file mode 100644
index 00000000..9bcae434
--- /dev/null
+++ b/npc/031-3/labyrinth.txt
@@ -0,0 +1,342 @@
+//#################################################################################
+//#
+//# Warps for the labyrinth on christmas 2010
+//#
+//# Authors: alastrim, PjotrOrial
+//#
+//# reviewed by:
+//#
+//# This is a labyrinth, having lots of warps in there.
+//# These warps are activated on different days.
+//# For each way there are 2 warps: one way and its way back.
+//#
+//#################################################################################
+
+
+// Debug Script
+
+031-3.gat,219,294,0 script Debug 144,{
+ menu
+ "Test a specific date",-,
+ "Clean $Golbenez_Santa_Free",L_Clean;
+ mes "Which date you want to test?";
+ input $Golbenez_Santa_Free;
+ close;
+
+L_Clean:
+ set $Golbenez_Santa_Free, 0;
+ close;
+}
+
+// 16/12 - 1 warp
+031-3.gat,205,264,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 16 ) end;
+ warp "031-3.gat", 149, 261;
+ end;
+}
+
+031-3.gat,149,259,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 16 ) end;
+ warp "031-3.gat", 205, 266;
+ end;
+}
+
+// 17/12 - 3 Warps
+
+// First Warp
+
+031-3.gat,225,282,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 17 ) end;
+ warp "031-3.gat", 274, 299;
+ end;
+}
+
+031-3.gat,274,300,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 17 ) end;
+ warp "031-3.gat", 225, 283;
+ end;
+}
+
+// Second Warp
+
+031-3.gat,283,271,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 17 ) end;
+ warp "031-3.gat", 269, 244;
+ end;
+}
+
+031-3.gat,269,245,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 17 ) end;
+ warp "031-3.gat", 283, 272;
+ end;
+}
+
+// Third Warp
+031-3.gat,139,258,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 17 ) end;
+ warp "031-3.gat", 155, 196;
+ end;
+}
+
+031-3.gat,155,195,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 17 ) end;
+ warp "031-3.gat", 139, 259;
+ end;
+}
+
+// 18/12 - 4 Warps
+
+// First Warp
+031-3.gat,142,301,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 18 ) end;
+ warp "031-3.gat", 97, 299;
+ end;
+}
+
+031-3.gat,97,301,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 18 ) end;
+ warp "031-3.gat", 142, 299;
+ end;
+}
+
+// Second Warp
+031-3.gat,135,196,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 18 ) end;
+ warp "031-3.gat", 106, 231;
+ end;
+}
+
+031-3.gat,106,232,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 18 ) end;
+ warp "031-3.gat", 135, 197;
+ end;
+}
+
+// Third Warp
+031-3.gat,286,190,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 18 ) end;
+ warp "031-3.gat", 227, 241;
+ end;
+}
+
+031-3.gat,227,242,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 18 ) end;
+ warp "031-3.gat", 286, 191;
+ end;
+}
+
+// Fourth Warp
+
+031-3.gat,236,211,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 18 ) end;
+ warp "031-3.gat", 187, 227;
+ end;
+}
+
+031-3.gat,187,228,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 18 ) end;
+ warp "031-3.gat", 236, 212;
+ end;
+}
+
+// 19/12 - 4 Warps
+
+// First Warp
+031-3.gat,94,254,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 19 ) end;
+ warp "031-3.gat", 54, 252;
+ end;
+}
+
+031-3.gat,54,250,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 19 ) end;
+ warp "031-3.gat", 94, 256;
+ end;
+}
+
+// Second Warp
+
+031-3.gat,103,199,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 19 ) end;
+ warp "031-3.gat", 52, 175;
+ end;
+}
+
+031-3.gat,52,177,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 19 ) end;
+ warp "031-3.gat", 103, 201;
+ end;
+}
+
+// Third Warp
+
+031-3.gat,212,193,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 19 ) end;
+ warp "031-3.gat", 207, 165;
+ end;
+}
+
+031-3.gat,207,168,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 19 ) end;
+ warp "031-3.gat", 212, 195;
+ end;
+}
+
+// Fourth Warp
+
+031-3.gat,235,167,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 19 ) end;
+ warp "031-3.gat", 195, 124;
+ end;
+}
+
+031-3.gat,195,122,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 19 ) end;
+ warp "031-3.gat", 235, 165;
+ end;
+}
+
+# // 4 warps on dec 20
+# // first warp
+031-3.gat,296,97,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 20 ) end;
+ warp "031-3.gat", 292, 125;
+ end;
+}
+031-3.gat,292,123,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 20 ) end;
+ warp "031-3.gat", 296, 95;
+ end;
+}
+# // second warp
+031-3.gat,289,164,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 20 ) end;
+ warp "031-3.gat", 228, 123;
+ end;
+}
+031-3.gat,228,121,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 20 ) end;
+ warp "031-3.gat", 289, 162;
+ end;
+}
+# // third warp
+031-3.gat,24,157,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 20 ) end;
+ warp "031-3.gat", 31, 142;
+ end;
+}
+031-3.gat,31,144,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 20 ) end;
+ warp "031-3.gat", 24, 159;
+ end;
+}
+# // forth warp
+031-3.gat,36,249,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 20 ) end;
+ warp "031-3.gat", 35, 224;
+ end;
+}
+031-3.gat,35,226,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 20 ) end;
+ warp "031-3.gat", 36, 251;
+ end;
+}
+
+
+# // 3 warps on dec 21
+# // first warp
+031-3.gat,34,25,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 21 ) end;
+ warp "031-3.gat", 281, 24;
+ end;
+}
+031-3.gat,281,22,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 21 ) end;
+ warp "031-3.gat", 34, 27;
+ end;
+}
+// # second warp
+031-3.gat,283,48,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 21 ) end;
+ warp "031-3.gat", 275, 74;
+ end;
+}
+031-3.gat,275,73,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 21 ) end;
+ warp "031-3.gat", 283, 47;
+ end;
+}
+// # third warp
+031-3.gat,26,178,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 21 ) end;
+ warp "031-3.gat", 36, 202;
+ end;
+}
+031-3.gat,36,200,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 21 ) end;
+ warp "031-3.gat", 26, 176;
+ end;
+}
+
+
+# // 2 warps on dec 22
+# // first warp
+031-3.gat,91,125,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 22 ) end;
+ warp "031-3.gat", 36, 78;
+ end;
+}
+031-3.gat,36,80,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 22 ) end;
+ warp "031-3.gat", 91, 127;
+ end;
+}
+// # second warp
+031-3.gat,52,78,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 22 ) end;
+ warp "031-3.gat", 192, 72;
+ end;
+}
+031-3.gat,192,70,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 22 ) end;
+ warp "031-3.gat", 52, 76;
+ end;
+}
+
+
+# // 2 warps on dec 23
+# // first warp
+031-3.gat,128,135,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 23 ) end;
+ warp "031-3.gat", 148, 152;
+ end;
+}
+031-3.gat,148,150,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 23 ) end;
+ warp "031-3.gat", 128, 134;
+ end;
+}
+// # second warp
+031-3.gat,232,93,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 23 ) end;
+ warp "031-3.gat", 200, 48;
+ end;
+}
+031-3.gat,200,50,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 23 ) end;
+ warp "031-3.gat", 232, 95;
+ end;
+}
+
+
+# // 1 warp on dec 24
+031-3.gat,120,81,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 24 ) end;
+ warp "031-3.gat", 46, 22;
+ end;
+}
+031-3.gat,46,24,0 script #ChristmasBarrier 127,1,1,{
+ if ($Golbenez_Santa_Free < 24 ) end;
+ warp "031-3.gat", 120, 80;
+ end;
+}
diff --git a/npc/_import.txt b/npc/_import.txt
index 3639d180..09c7de0a 100644
--- a/npc/_import.txt
+++ b/npc/_import.txt
@@ -18,12 +18,14 @@ import: npc/008-1_Hurnscald_outskirts/_import.txt
import: npc/009-1_Hurnscald/_import.txt
import: npc/009-2_Hurnscald/_import.txt
import: npc/009-3_Cave_beneath_Hurnscald/_import.txt
+import: npc/009-4/_import.txt
import: npc/010-1_Woodland/_import.txt
import: npc/010-2_Dimonds_Cove/_import.txt
import: npc/011-1_Woodland/_import.txt
import: npc/011-3_Hermits_cave/_import.txt
import: npc/011-4_Lake_cave/_import.txt
import: npc/011-5/_import.txt
+import: npc/011-6/_import.txt
import: npc/012-1_Woodland_Hills/_import.txt
import: npc/012-3_Cave/_import.txt
import: npc/012-4_Cave/_import.txt
@@ -42,10 +44,10 @@ import: npc/018-1_Woodland_mining_camp/_import.txt
import: npc/018-2_Woodland_mining_camp/_import.txt
import: npc/018-3_Cave/_import.txt
import: npc/019-1_Snow_field/_import.txt
+import: npc/019-3_Snow_field/_import.txt
import: npc/020-1_Nivalis/_import.txt
import: npc/020-2_Nivalis/_import.txt
import: npc/020-3_Ice_cave/_import.txt
-import: npc/020-4_Ice_cave/_import.txt
import: npc/021-1_Tulimshar/_import.txt
import: npc/021-2_Tulimshar/_import.txt
import: npc/022-1_Tulimshar/_import.txt
@@ -55,8 +57,12 @@ import: npc/025-1_Woodland_Swamp/_import.txt
import: npc/026-1_Swamp/_import.txt
import: npc/027-1_Graveyard/_import.txt
import: npc/027-2_Caretakers_House/_import.txt
+import: npc/027-3/_import.txt
import: npc/028-1/_import.txt
import: npc/028-3/_import.txt
import: npc/029-1_Candor/_import.txt
import: npc/029-3_Fight_Cave/_import.txt
+import: npc/030-1_Snow_field/_import.txt
+import: npc/031-1_NivalisPort/_import.txt
+import: npc/031-3/_import.txt
import: npc/botcheck/_import.txt
diff --git a/npc/scripts.conf b/npc/scripts.conf
index acda50a6..660dedb7 100644
--- a/npc/scripts.conf
+++ b/npc/scripts.conf
@@ -73,3 +73,6 @@ import: npc/_import.txt
// Easter 2010
// When enabling, some entries in 028-1 would also need to be uncommented, the warp from 028-1 would need to be commented out. The changes to the old woman and some other NPCs weren't able to be preserved, but are recorded in the git repository.
//import: npc/easter/2010/_import.txt
+
+import: npc/xmas/2010/_import.txt
+
diff --git a/npc/xmas/2010/_import.txt b/npc/xmas/2010/_import.txt
new file mode 100644
index 00000000..e68c6992
--- /dev/null
+++ b/npc/xmas/2010/_import.txt
@@ -0,0 +1,2 @@
+npc: npc/xmas/2010/santa.txt
+npc: npc/xmas/2010/golbanez.txt
diff --git a/npc/xmas/2010/golbanez.txt b/npc/xmas/2010/golbanez.txt
new file mode 100644
index 00000000..5ee9999d
--- /dev/null
+++ b/npc/xmas/2010/golbanez.txt
@@ -0,0 +1,194 @@
+//#################################################################################
+//#
+//# Golbanez for Christmas 2010
+//#
+//# Authors: alastrim, PjotrOrial
+//#
+//# reviewed by:
+//#
+//# This is Golbanez, he took Santa Claus as a hostage.
+//# Santa will be freed on Dec24, so players need to pass a labyrinth
+//# if the players bring Golbanez stuff, santa will donate some other stuff to the players.
+//#
+//#################################################################################
+019-1.gat,96,41,0 script Golbenez-Debug 204,{
+
+ mes "What you want to do?";
+ menu
+ "Change $Golbenez_Santa_Free(Date of the Month)",-,
+ "Change Golbenez_Inn_Cost(Your Donations)",_cost,
+ "Clean all variables.",_clean,
+ "Nothing",_end;
+
+ mes "Old Value: " + $Golbenez_Santa_Free;
+ input $Golbenez_Santa_Free;
+ mes "New Value: " + $Golbenez_Santa_Free;
+ close;
+
+_cost:
+ mes "Old Value: " + Golbenez_Inn_Cost;
+ input Golbenez_Inn_Cost;
+ mes "New Value: " + Golbenez_Inn_Cost;
+ close;
+
+_clean:
+ mes "Golbenez_Inn_Cost Old Value: " + Golbenez_Inn_Cost;
+ set Golbenez_Inn_Cost, 0;
+ mes "Golbenez_Inn_Cost New Value: " + Golbenez_Inn_Cost;
+ mes "$Golbenez_Santa_Free Old Value: " + $Golbenez_Santa_Free;
+ set $Golbenez_Santa_Free, 0;
+ mes "$Golbenez_Santa_Free New Value: " + $Golbenez_Santa_Free;
+ close;
+
+_end:
+ close;
+
+}
+
+019-1.gat,93,41,0 script #Golbenez#_M 204,{
+ set $Golbenez_Santa_Free, gettime(5);
+
+ if (gettime(7) > 2010) set $Golbenez_Santa_Free, 25;
+
+ if ($Golbenez_Santa_Free >= 24 || gettime(7) > 2010) goto Glb_Inn_Enough;
+
+ mes "[Golbenez]";
+ mes "\"Mortal! I am Golbenez! I have broken through the barriers of space and time!\"";
+ next;
+ mes "\"Well to let you know, I am taking Santa Claus and rudolph and the fellow rendiers as hostages.\"";
+ next;
+ mes "\"This sounds hard to you maybe... But I need lots of stuff for building the way to the leisure place.";
+ next;
+ mes "\"So if you want to have donations at christmas... we should make a deal: Bring me money or presents.";
+ next;
+ mes "\"Maybe I will release Santa Claus and the rendiers then.\"";
+ next;
+ mes "\"Do you really expect a promise to let him free on christmas?\"";
+ next;
+ mes "\"Uhm well, then you should get away!\"";
+ next;
+ mes "\"So far, you have brought stuff and money in a total value of " + Golbenez_Inn_Cost + " gold pieces. The people of your world have brought me " + $Golbenez_Inn_Cost + " gold pieces. What do you like to give?\"";
+
+ menu
+ "I'd like to spend some money.", Glb_money,
+ "I'd like to give some blue presents.", -,
+ "I'd like to give some green presents.", -,
+ "I'd like to give some pink presents.", -,
+ "Why do you want present boxes?",Glb_whypresents,
+ "Can I bring other items?", Glb_otheritems,
+ "Nevermind.", Glb_nvm;
+
+ // in this array the items should be filled in
+ setarray @menuitem[2], 516, 538, 515;
+ setarray @menuvalue[2], 2000, 5000, 1000;
+
+ mes "\"How many presents do you want to give?\"";
+
+ input @count;
+
+ if (countitem(@menuitem[@menu]) < @count ) goto Glb_noitems;
+ delitem @menuitem[@menu], @count;
+ set @Give, (@count * @menuvalue[@menu]);
+ set @Gave_Presents, 1;
+ goto Glb_checkGlAn;
+
+Glb_money:
+ input @Give;
+
+ set @Give, @Give;
+
+ if (@Give <= 0) close;
+ if (zeny < @Give) goto Glb_Inn_NotEnoughZeny;
+
+Glb_checkGlAn:
+
+ // if the @Give amount is below 30% of the players money, just let him pay
+ if( @Give<10000 || ( 100 * @Give / zeny )<30 ) goto Golbenez_pay;
+
+ set @glob_an$ , "Golbenez: " + strcharinfo(0) + " accounted to free santa";
+
+ // depending on the absolute amount setup another global announcement.
+ if( @Give >1000000 ) goto Golbenez_an_5;
+ if( @Give > 500000 ) goto Golbenez_an_4;
+ if( @Give > 100000 ) goto Golbenez_an_3;
+ if( @Give > 72000 ) goto Golbenez_an_2;
+ if( @Give > 35500 ) goto Golbenez_an_1;
+
+ goto Golbenez_an;
+
+Golbenez_an_1:
+ set @glob_an$, @glob_an$ + " with a great effort.";
+ goto Golbenez_an;
+
+Golbenez_an_2:
+ set @glob_an$, @glob_an$ + " with a honest contribution.";
+ goto Golbenez_an;
+
+Golbenez_an_3:
+ set @glob_an$, @glob_an$ + " with a great effort. Such a generous person.";
+ goto Golbenez_an;
+
+Golbenez_an_4:
+ set @glob_an$, @glob_an$ + " with a remarkable effort. Impressive!";
+ goto Golbenez_an;
+
+Golbenez_an_5:
+ set @glob_an$, @glob_an$ + " with a huge effort. What a honorable donation!";
+ goto Golbenez_an;
+
+Golbenez_an:
+ announce @glob_an$, 0;
+
+Golbenez_pay:
+ set Golbenez_Inn_Cost, Golbenez_Inn_Cost + @Give;
+ set $Golbenez_Inn_Cost, $Golbenez_Inn_Cost + @Give;
+ if (@Gave_Presents == 1) close;
+ set zeny, zeny - @Give;
+ close;
+
+Glb_Inn_NotEnoughZeny:
+ mes "[Golbenez]";
+ mes "\"You don't have as much as you say you do. Come back when you can give the gold pieces you say you can.\"";
+ close;
+
+Glb_noitems:
+ mes "[Golbenez]";
+ mes "\"You don't have as many as you say you do. Come back when you have enough.\"";
+ close;
+
+Glb_nvm:
+ mes "[Golbenez]";
+ mes "\"That's too bad.\"";
+ close;
+
+Glb_whypresents:
+ mes "[Golbenez]";
+ mes "\"The presents contain some sort of spiritual attachment that aids in the creation of dimensional connections to this plane of existence. The green ones contain the stronger spiritual attachment, followed by the blue and then pink present boxes.\"";
+ next;
+ mes "\"Im willing to consider a conversion of each Present Box donated to an amount in Gold Pieces. So, a Green Present is equivalent to 5000 Gold Pieces, a Blue Present, 2000 Gold Pieces and a Pink Present, 1000 Gold Pieces.\"";
+ close;
+
+Glb_otheritems:
+ mes "[Golbenez]";
+ mes "\"No you cannot!\"";
+ next;
+ mes "\"I will not discuss any further, mortal!\"";
+ next;
+ mes "\"So bring me the needed stuff and maybe you get some stuff as a reward, little coward!\"";
+ close;
+
+Glb_Inn_Enough:
+ mes "[Golbenez]";
+ mes "\"Ok mortal!\"";
+ next;
+ mes "\"I have collected enough for now.\"";
+ next;
+ mes "\"This helps me working on the leisure place.\"";
+ next;
+ mes "\"Although I did not promise I let Santa be free again!\"";
+ next;
+ mes "\"He can be found in some cave around here.\"";
+ close;
+}
+
+
diff --git a/npc/xmas/2010/santa.txt b/npc/xmas/2010/santa.txt
new file mode 100644
index 00000000..4b95a142
--- /dev/null
+++ b/npc/xmas/2010/santa.txt
@@ -0,0 +1,160 @@
+//#################################################################################
+//#
+//# Santa for Christmas 2010
+//#
+//# Authors: alastrim, PjotrOrial
+//#
+//# reviewed by:
+//#
+//# This is Santa Claus.
+//# He was taken as hostage by golbanez, and now that he is free, he would like to
+//# give a reward for those who helped him.
+//#
+//#################################################################################
+
+031-3.gat,122,55,0 script Debug 105,{
+
+ mes "What do you want to do?";
+
+ menu
+ "Change Golbenez_Inn_Cost.",-,
+ "Change Xmas2010.",_xmas,
+ "Nothing.",_end;
+
+ mes "Old Value: " + Golbenez_Inn_Cost;
+ input Golbenez_Inn_Cost;
+ mes "New Value: " + Golbenez_Inn_Cost;
+ close;
+_xmas:
+ mes "Old Value: " + Xmas2010;
+ input Xmas2010;
+ mes "New Value: " + Xmas2010;
+ close;
+_end:
+ close;
+}
+
+031-3.gat,122,51,0 script Santa 105,{
+
+ if (Sex) set @honorific$, "young hero";
+ if (Sex) set @gender$, "boy";
+ if (!Sex) set @honorific$, "young heroine";
+ if (!Sex) set @gender$, "girl";
+ if (Xmas2010 == 1) goto L_Returning;
+ if (Xmas2010 == 2) goto L_Elfhat_Prize;
+ if (Xmas2010 == 3) goto L_Stocking_Prize;
+ if (Xmas2010 == 4) goto L_Event_Done;
+ if (Golbenez_Inn_Cost < 50000) goto L_No_Prizes;
+
+L_start:
+ mes "The old man's eyes open wide as he sees you.";
+ next;
+ mes "[Santa Claus]";
+ mes "\"Ho-Ho-ho! It is so good to see you here " +@honorific$+ "!\"";
+ next;
+ menu
+ "Im " + strcharinfo(0) + " and I am here to save you from Golbenez.",-;
+ mes "\"I cant believe it... are you really " +strcharinfo(0)+ "? I remember all the comments that... 'Thing' was making about building his way to a 'Leisure Place' and how your donations would really help him.\"";
+ next;
+ mes "\"What is his name again? Erh... Golbinos? Galvanis? Ho-hum... All I know is that it was keeping me and my fellow rendiers as hostages in this cold labyrinth. And you proved yourself a good " +@gender$+ " by helping me with all those donations!\"";
+ next;
+ if (gettime(6) != 12 || gettime(5) >= 25) goto L_Skip_Dialogue;
+ mes "\"Well, we are really late! In a few hours we have to start our usual present giving routine... But not before I give you a special gift for all you did.\"";
+ next;
+L_Skip_Dialogue:
+ mes "\"Let me see... From what I can remember, Galvenio said a " +@gender$+ " called " +strcharinfo(0)+ " donated a total of " +Golbenez_Inn_Cost+ " Golden Pieces!\"";
+ next;
+
+L_Calculate_Prizes:
+ getinventorylist;
+ if (@inventorylist_count == 100) goto L_full;
+ if (Golbenez_Inn_Cost >= 500000 && Golbenez_Inn_Cost < 1000000) goto L_Elfhat_Prize;
+ if (Golbenez_Inn_Cost >= 50000 && Golbenez_Inn_Cost < 500000) goto L_Stocking_Prize;
+ setarray @prizes[1], 1206, 1216, 629, 630, 634, 1214, 633, 628, 627, 621;
+ setarray @prizesnames$[1], "Santa Beard Hat", "Mouboo Head", "Mush Hat", "Shroom Hat", "Face Mask", "Bunny Ears", "Christmas Elf Hat", "Funky Hat", "Top Hat", "Eyepatch";
+ mes "\"You are so generous! I believe I can give you one of the hats from this bag. I know you like these silly hats. Yes, Santa knows this kind of thing... Ho-Ho-Ho! Which one would you like to get?\"";
+
+L_Menu_Choices:
+ menu
+ @prizesnames$[1],-,
+ @prizesnames$[2],-,
+ @prizesnames$[3],-,
+ @prizesnames$[4],-,
+ @prizesnames$[5],-,
+ @prizesnames$[6],-,
+ @prizesnames$[7],-,
+ @prizesnames$[8],-,
+ @prizesnames$[9],-,
+ @prizesnames$[10],-;
+
+ getitem @prizes[@menu], 1;
+ set Xmas2010, 1;
+ set Golbenez_Inn_Cost, 0;
+ next;
+
+L_Returning:
+ mes "[Santa Claus]";
+ mes "\"I hope you liked your gift.\"";
+ next;
+ menu
+ "Yes Santa, you are the best!",L_Close,
+ "Ehh, it is not what I expected.",L_Bad,
+ "I loved it! Can I have one more, please, please?",-;
+
+ mes "[Santa Claus]";
+ mes "\"Hmm... Why not? It would be terrible to deny a request from such a generous person.\"";
+ next;
+ set Xmas2010, 3;
+ goto L_Stocking_Prize;
+
+L_Elfhat_Prize:
+ set Xmas2010, 2;
+ getinventorylist;
+ if (@inventorylist_count == 100) goto L_full;
+ mes "[Santa Claus]";
+ mes "\"You worked really hard to help us... So, here, take this hat. It belongs to one of my assistants. No, no... No problem at all, I am sure he will be happy to know such a great person is going to use it.\"";
+ getitem 633, 1;
+ set Golbenez_Inn_Cost, 0;
+ set Xmas2010, 3;
+ next;
+
+L_Stocking_Prize:
+ getinventorylist;
+ if (@inventorylist_count == 100) goto L_full;
+ mes "[Santa Claus]";
+ mes "\"I would like to give you a personal item. It is not a hat, but something that will always make you remember how grateful I am.\"";
+ next;
+ mes "\"Here, take this. I have been using it for the last three months... It means a lot to me.\"";
+ getitem 1207, 1;
+ set Golbenez_Inn_Cost, 0;
+ set Xmas2010, 4;
+ close2;
+ percentheal -20, 0;
+ message strcharinfo(0), "You suddenly get dizzy... Something is not right with you. Maybe you shouldnt have put the Red Stocking so close to your face!";
+ end;
+
+L_Full:
+ mes "[Santa Claus]";
+ mes "\"Your backpack seems to be full. You should get rid of some unused stuff before you get my gifts, or maybe try one super resistant red bag, my personal favorite! Hoh-hoh!\"";
+ close;
+
+L_Close:
+ mes "[Santa Claus]";
+ mes "\"Ho, Ho... Ok, see you later " +@honorific$+ "!\"";
+ close;
+
+L_Bad:
+ mes "[Santa Claus]";
+ mes "\"Hmm... and I was thinking you were a good " +@gender$+ "! Dont be ungrateful and next time, think before you get a gift.\"";
+ close;
+
+L_Event_Done:
+ mes "[Santa Claus]";
+ mes "\"Hello again " +strcharinfo(0)+ "! I cant chat with you right now, because we are really late for Christmas, but, when it is over, you will always be welcome in my house for a hot chocolate.\"";
+ close;
+
+L_No_Prizes:
+ mes "[Santa Claus]";
+ mes "\"Hi " +strcharinfo(0)+ "... Looks like you did not work really hard to set me free...\"";
+ close;
+}