summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--npc/012-1/_import.txt1
-rw-r--r--npc/012-1/jack.txt213
-rw-r--r--npc/012-3/_import.txt1
-rw-r--r--npc/012-3/alan.txt63
-rw-r--r--npc/commands/warp.txt1
5 files changed, 226 insertions, 53 deletions
diff --git a/npc/012-1/_import.txt b/npc/012-1/_import.txt
index cbcb25def..71dd2ab9d 100644
--- a/npc/012-1/_import.txt
+++ b/npc/012-1/_import.txt
@@ -4,6 +4,7 @@
"npc/012-1/_warps.txt",
"npc/012-1/andrei.txt",
"npc/012-1/dyrinthetraveler.txt",
+"npc/012-1/jack.txt",
"npc/012-1/mapflags.txt",
"npc/012-1/richard.txt",
"npc/012-1/soul-menhir.txt",
diff --git a/npc/012-1/jack.txt b/npc/012-1/jack.txt
new file mode 100644
index 000000000..3e5ca7845
--- /dev/null
+++ b/npc/012-1/jack.txt
@@ -0,0 +1,213 @@
+// TMW-2 Script
+// Originals: TMW Org.
+//
+// Author:
+// Jesusalva
+// Description:
+// Jack is Hurnscald Lumberjack
+
+012-1,69,93,0 script Jack NPC_LUMBERJACK,{
+ .@q1=getq(HurscaldQuest_ForestBow);
+ //.@q2=getq(HurscaldQuest_WoodShield);
+
+ mesn "Jack, the Lumberjack";
+ mesq l("Hello there! I'm Jack, the Lumberjack, and enemy of all trees. If you need some firewood, just let me know.");
+ select
+ l("Nothing at the moment, thanks."),
+ rif(.@q1 == 1, l("I need a sturdy wood piece for a Forest Bow.");
+
+ switch (@menu) {
+ case 1:
+ close;
+ break;
+ case 2:
+ goto L_ForestBow;
+ break;
+ }
+
+ close;
+
+L_ForestBow:
+ .@k=getq2(HurscaldQuest_ForestBow);
+
+ switch (.@k) {
+ case 0:
+ mesn;
+ mesq l("Ah, don't bother me with that. That wood must be special, it must bend and cannot break. Too difficult to find!");
+ next;
+ mesn;
+ mesq l("I also do not keep any stock of them. If you really want it, you can bring me some Raw Logs. I'll show you which one is the good one. Deal?");
+ next;
+ mesn strcharinfo(0);
+ mesq l("I'm railroaded here, I cannot say no. I'll bring you some @@. Break them until one of them fit.", getitemlink(RawLog));
+ setq2 HurscaldQuest_ForestBow, 1;
+ close;
+ break;
+ case 99:
+ mesn;
+ mesq l("Good luck...");
+ break;
+ default:
+ goto L_Loop;
+ }
+ goto L_Close;
+
+L_Loop:
+ .@k=getq2(HurscaldQuest_ForestBow);
+ mesn;
+ mesq l("Bring me your wood, and I'll show you which one is sturdy, yet flexible enough to make a good Forest Bow.");
+ mes "";
+ select
+ l("Don't break my stuff."),
+ rif(countitem(RawLog) > 0, l("Try this one."));
+
+ if (@menu == 1)
+ close;
+
+ mes col("Jack bends the log over his knee.", 9);
+ delitem RawLog, 1;
+ .@success=rand(6,26)-.@k; // You will never need more than 20 logs nor less than 5 logs
+
+ if (.@success == 1) {
+ mes col("The wood bends a little, but doesn't breaks.", 9);
+ getexp 0, 100;
+ setq2 HurscaldQuest_ForestBow, 99;
+ next;
+ mesn;
+ mesq lg("That's the right wood, my son. Here, I'll wrap it so you don't accidentaly lose it. Good luck with your quest!");
+ close;
+ } else {
+ mes col("However, the log breaks with a loud crack.", 9);
+ setq2 HurscaldQuest_ForestBow, .@k+1;
+ next;
+ mesn;
+ mesq lg("Sorry, son. I know how hard this is. But this is teaching you a valuable lesson, your eye will be more sharp for quality wood from now on.");
+ next;
+ }
+
+ goto L_Loop;
+
+/* Copy-paste from TMW Org.
+ I'll uncomment and rewrite when time comes.
+
+L_Shield_state_0:
+ mesn "Jack, the Lumberjack";
+ mes "\"I have an idea. What would you say about a new shield?\"";
+ next;
+ menu
+ "No thanks.", L_Close,
+ "Yes, please!", L_Yes;
+
+L_Yes:
+ mesn "Jack, the Lumberjack";
+ mes "\"All I need is " + @RAWLOGS_AMOUNT + " raw logs. This needn't be high quality wood; pretty much any log you can find should work. Oh, and I'll also need " + @SHIELD_COST + " GP for other materials.\"";
+ next;
+ @Q_Woodenshield = 2;
+ goto L_Close;
+
+L_Shield_state_2:
+ mesn "Jack, the Lumberjack";
+ mes "\"Do you have the " + @RAWLOGS_AMOUNT + " raw logs and " + @SHIELD_COST + " GP for the shield?\"";
+ menu
+ "Here it is.", L_Next10,
+ "I'll come back later.", L_Close;
+
+L_Next10:
+ if (countitem("RawLog") < @RAWLOGS_AMOUNT)
+ goto L_Not_enough_logs;
+ if (Zeny < @SHIELD_COST)
+ goto L_Not_enough_money;
+ getinventorylist;
+ if (@inventorylist_count == 100)
+ goto L_TooMany;
+ delitem "RawLog", @RAWLOGS_AMOUNT;
+ Zeny = Zeny - @SHIELD_COST;
+ getexp @QUEST_SHIELD_EXP, 0;
+ getitem "WoodenShield", 1;
+ @Q_Woodenshield = 3;
+ mesn "Jack, the Lumberjack";
+ mes "\"Have a seat.\"";
+ mes "Jack saws the logs into pieces and then sands them until they are smooth to the touch.";
+ mes "Applying some strong-smelling liquid, he tans them to a darker hue.";
+ next;
+ mesn "Jack, the Lumberjack";
+ mes "Grabbing one of two leftover pieces, he begins to carve it into a round shape, then repeats this with the second piece – shield handles from what you can tell.";
+ next;
+ mesn "Jack, the Lumberjack";
+ mes "Meanwhile, the sun has dried the other pieces. Jack places them next to each other, adds a frame, and nails everything together.";
+ mes "The resulting shield looks usable already, but Jack applies another liquid to it and leaves it to dry for a few moments.";
+ next;
+ mesn "Jack, the Lumberjack";
+ mes "Finally, he hands the shield to you.";
+ mes "\"Enjoy your new shield!\"";
+ mes "[" + @QUEST_SHIELD_EXP + " experience points]";
+ next;
+ goto L_Close;
+
+L_Not_enough_logs:
+ mesn "Jack, the Lumberjack";
+ mes "\"You don't have enough wood for me to craft this shield; I need a total of " + @RAWLOGS_AMOUNT + " raw logs.\"";
+ goto L_Close;
+
+L_Not_enough_money:
+ mesn "Jack, the Lumberjack";
+ mes "\"I'm afraid that you don't have enough gold. I need " + @SHIELD_COST + " GP to finish your shield.\"";
+ goto L_Close;
+
+L_TooMany:
+ mesn "Jack, the Lumberjack";
+ mes "\"You don't have enough room to carry the shield. Come back when you do.\"";
+ goto L_Close;
+
+L_Shield_state_3:
+ mesn "Jack, the Lumberjack";
+ mes "\"I hope that my shield will serve you well!\"";
+ next;
+ if (@inspector != 1)
+ goto L_Made_Shield;
+ menu
+ "Me too.", L_Made_Shield,
+ "Have you seen anything that might be connected to the recent robberies in town?", L_NohMask_Answer;
+
+L_NohMask_Ask:
+ menu
+ "I'll keep that in mind.", L_Close,
+ "I heard you aren't delivering any more living wood. Why not?", L_Next,
+ "Have you seen anything that might be connected to the recent robberies in town?", L_NohMask_Answer;
+
+L_NohMask_Answer:
+ mesn "Jack, the Lumberjack";
+ mes "\"Sorry, no.\"";
+ goto L_Close;
+
+L_Made_Shield:
+ mesn "Jack, the Lumberjack";
+ mes "\"Speaking of that shield...\"";
+ mes "\"It has put me behind on all these new Nivalis orders, now that the ship is running there.\"";
+ next;
+ mes "\"Care to help out? I'll pay you for your time.\"";
+ goto L_Daily;
+
+L_Daily:
+ @dq_level = 30;
+ @dq_cost = 25;
+ @dq_count = 30;
+ @dq_name$ = "RawLog";
+ @dq_friendly_name$ = "raw logs";
+ @dq_money = 4000;
+ @dq_exp = 4000;
+
+ callfunc "DailyQuest";
+
+ next;
+
+ mesn "Jack, the Lumberjack";
+ mes "\"Check back with me tomorrow, and I'll let you know if I need any help with that shipment.\"";
+
+ goto L_Close;
+*/
+
+L_Close:
+ close;
+
+}
diff --git a/npc/012-3/_import.txt b/npc/012-3/_import.txt
index d27bc10f1..1f94b49b5 100644
--- a/npc/012-3/_import.txt
+++ b/npc/012-3/_import.txt
@@ -1,3 +1,4 @@
// Map 012-3: Archery Shop
// This file is generated automatically. All manually added changes will be removed when running the Converter.
"npc/012-3/_warps.txt",
+"npc/012-3/alan.txt",
diff --git a/npc/012-3/alan.txt b/npc/012-3/alan.txt
index 23fb07f59..6493c6c61 100644
--- a/npc/012-3/alan.txt
+++ b/npc/012-3/alan.txt
@@ -4,8 +4,10 @@
// Description:
// Alan is Hurnscald's bowmaster. He may craft the Forest Bow, and sell ammo.
-012-3,99,23,0 script Alan NPC_RAIJIN,{
+012-3,99,23,0 script Alan NPC_BOWMASTER,{
.@q=getq(HurscaldQuest_ForestBow);
+ .@q2=getq2(HurscaldQuest_ForestBow);
+ .@q3=getq3(HurscaldQuest_ForestBow);
switch (.@q) {
case 1:
npctalk3 l("The Forest Bow is my specialty. I wish I could keep crafting them forever...");
@@ -23,7 +25,7 @@
l("Ok, thanks."), L_Close,
l("I want to trade."), L_Shop,
rif(.@q == 0, l("Do you accept special requests? Could you make me a really good bow?"), L_ForestBow,
- rif(.@q == 2, l("I have the sturdy wood and the string."), L_Craft;
+ rif(.@q == 1 && .@q2 == .@q3 && .@q2 == 99, l("I have the sturdy wood and the string."), L_Craft;
L_Shop:
openshop;
@@ -53,48 +55,11 @@ L_Next:
l("Right'o, I'll arrange the material!"), L_Start;
L_Start:
- setq HurscaldQuest_ForestBow, 1, 0;
+ // q2 → Wood Part
+ // q3 → String Part
+ setq HurscaldQuest_ForestBow, 1, 0, 0;
goto L_Close;
-L_State_3:
- mesn;
- mes "\"How is the hunt going? Did you bring me any wood?\"";
- if (countitem("RawLog") < 1)
- goto L_Close;
- next;
- menu
- "Here, take a look!", L_State_3_try,
- "Yes, but I need it for something else.", L_Close;
-
-L_State_3_try:
- if (countitem("RawLog") < 1)
- goto L_No_Log;
- delitem "RawLog", 1;
- mesn;
- mes "\"Hmmm... looks ok, but is it strong enough?\"";
- mes "Alan bends the log over his knee.";
- next;
- @Temp1 = rand(20);
- if (@Temp1 == 0) goto L_State_3_success;
- mes "The log breaks with a loud crack.";
- getexp @BROKENLOG_EXP, 0;
- next;
- mesn;
- mes "\"Sorry, this log was too weak for one of my forest bows. Now it is junk. Give me another.\"";
- if (countitem("RawLog") < 1)
- goto L_Close;
- next;
- menu
- "Sure, here you go.", L_State_3_try,
- "Hey! Stop breaking my stuff!", L_Close;
-
-L_State_3_success:
- mes "Alan tries as hard as he can but the log won't bend.";
- next;
- mesn;
- mes "\"Aaah! Yes! That is a really fine piece of wood you brought me. It will make an excellent bow!\"";
- close;
-
L_Craft:
inventoryplace ForestBow, 1;
getitem ForestBow, 1;
@@ -110,14 +75,8 @@ L_Close:
close;
OnInit:
- .@npcId = getnpcid(0, .name$);
- setunitdata(.@npcId, UDT_HEADTOP, Boots);
- setunitdata(.@npcId, UDT_HEADMIDDLE, CottonShirt);
- setunitdata(.@npcId, UDT_HEADBOTTOM, JeanChaps);
- setunitdata(.@npcId, UDT_WEAPON, WoodenBow);
- setunitdata(.@npcId, UDT_HAIRSTYLE, 7);
- setunitdata(.@npcId, UDT_HAIRCOLOR, 17);
-
+ .sex = G_MALE;
+ .distance = 5;
tradertype(NST_MARKET);
sellitem ShortBow, 9000, 1;
@@ -126,11 +85,9 @@ OnInit:
sellitem TrainingArrow, -1, 2000;
sellitem Arrow, -1, 1000;
sellitem IronArrow, -1, 500;
-
- .sex = G_MALE;
- .distance = 5;
end;
+
OnClock2357:
OnClock1151:
restoreshopitem ShortBow, 9000, 1;
diff --git a/npc/commands/warp.txt b/npc/commands/warp.txt
index cc2c4e434..1d9b1123b 100644
--- a/npc/commands/warp.txt
+++ b/npc/commands/warp.txt
@@ -69,6 +69,7 @@ OnInit:
"^TULIM", "003-1 41 48", // Tulishmar
"^CANDOR", "005-1 28 92", // Candor
"^HALI", "009-1 28 33", // Halinarzo
+ "^HURN", "012-1 83 63", // Hurnscald
// TBR - To Be Removed
"^BOSS", "boss 45 45", // (TBR) Jesusalva Boss Arena