diff options
author | Jesusaves <cpntb1@ymail.com> | 2022-10-23 21:44:22 -0300 |
---|---|---|
committer | Jesusaves <cpntb1@ymail.com> | 2022-10-23 21:44:22 -0300 |
commit | a7c45a192268da2601cef47a4cdba987ae2327ca (patch) | |
tree | c5fb5b97db109fe7106496dd96498c475881046b /npc/012-2 | |
download | serverdata-a7c45a192268da2601cef47a4cdba987ae2327ca.tar.gz serverdata-a7c45a192268da2601cef47a4cdba987ae2327ca.tar.bz2 serverdata-a7c45a192268da2601cef47a4cdba987ae2327ca.tar.xz serverdata-a7c45a192268da2601cef47a4cdba987ae2327ca.zip |
Initial commit (Moubootaur Legends fork)
Diffstat (limited to 'npc/012-2')
-rw-r--r-- | npc/012-2/GonzoDark.txt | 25 | ||||
-rw-r--r-- | npc/012-2/Saulc.txt | 25 | ||||
-rw-r--r-- | npc/012-2/_import.txt | 11 | ||||
-rw-r--r-- | npc/012-2/_warps.txt | 4 | ||||
-rw-r--r-- | npc/012-2/door.txt | 59 | ||||
-rw-r--r-- | npc/012-2/helena.txt | 284 | ||||
-rw-r--r-- | npc/012-2/khafar.txt | 137 | ||||
-rw-r--r-- | npc/012-2/melina.txt | 73 | ||||
-rw-r--r-- | npc/012-2/note.txt | 29 | ||||
-rw-r--r-- | npc/012-2/rakinorf.txt | 335 |
10 files changed, 982 insertions, 0 deletions
diff --git a/npc/012-2/GonzoDark.txt b/npc/012-2/GonzoDark.txt new file mode 100644 index 0000000..38a74ae --- /dev/null +++ b/npc/012-2/GonzoDark.txt @@ -0,0 +1,25 @@ +// TMW2 Script +// Author: +// Jesusalva +// Description: +// Monthly Sponsor Quest +// Variable: +// SQuest_Sponsor +// Quest ID: 2 + +012-2,50,81,0 script GonzoDark Sponsor NPC_LUCAS,{ + mesn; + mesq lg("Yo, girl.", "Yo, man."); + next; + mesn; + mesq l("I sponsor the alliance and all I got was a NPC and access to this ugly room."); + next; + mesn; + mesq l("Well, I don't want to be an snob."); + close; + +OnInit: + .sex = G_MALE; + .distance = 5; + end; +} diff --git a/npc/012-2/Saulc.txt b/npc/012-2/Saulc.txt new file mode 100644 index 0000000..3b5cadc --- /dev/null +++ b/npc/012-2/Saulc.txt @@ -0,0 +1,25 @@ +// TMW2 Script +// Author: +// Jesusalva +// Description: +// Monthly Sponsor Quest +// Variable: +// SQuest_Sponsor +// Quest ID: 1 + +012-2,46,81,0 script Saulc Sponsor NPC_HUMAN_MALE_CHIEF,{ + mesn; + mesq lg("Yo, girl.", "Yo, man."); + next; + mesn; + mesq l("I sponsor the alliance and all I got was a NPC and access to this ugly room."); + next; + mesn; + mesq l("Well, I don't want to be an snob."); + close; + +OnInit: + .sex = G_MALE; + .distance = 5; + end; +} diff --git a/npc/012-2/_import.txt b/npc/012-2/_import.txt new file mode 100644 index 0000000..23212c6 --- /dev/null +++ b/npc/012-2/_import.txt @@ -0,0 +1,11 @@ +// Map 012-2: Hurnscald Inn +// This file is generated automatically. All manually added changes will be removed when running the Converter. +"npc/012-2/GonzoDark.txt", +"npc/012-2/Saulc.txt", +"npc/012-2/_warps.txt", +"npc/012-2/door.txt", +"npc/012-2/helena.txt", +"npc/012-2/khafar.txt", +"npc/012-2/melina.txt", +"npc/012-2/note.txt", +"npc/012-2/rakinorf.txt", diff --git a/npc/012-2/_warps.txt b/npc/012-2/_warps.txt new file mode 100644 index 0000000..44ed24f --- /dev/null +++ b/npc/012-2/_warps.txt @@ -0,0 +1,4 @@ +// This file is generated automatically. All manually added changes will be removed when running the Converter. +// Map 012-2: Hurnscald Inn warps +012-2,36,47,0 warp #012-2_36_47 0,0,012-1,65,56 +012-2,59,83,0 warp #012-2_59_83 0,0,012-2,59,39 diff --git a/npc/012-2/door.txt b/npc/012-2/door.txt new file mode 100644 index 0000000..113a225 --- /dev/null +++ b/npc/012-2/door.txt @@ -0,0 +1,59 @@ +// TMW-2 Script. +// Author: +// Jesusalva +// Notes: +// Sponsor Area Only + +012-2,59,38,0 script Sponsors Inn NPC_HIDDEN,0,0,{ + end; + +OnTouch: + if (!getgmlevel()) + goto L_Unauthorized; + if (SP_WARN) + SP_WARN=0; + slide 59, 82; + end; + +L_Unauthorized: + // Per r8.0 Apane Invasion, there's a moment on main storyline you'll be allowed in + .@n=getq(General_Narrator); + if (.@n == 5 || .@n == 6) { + slide 59, 82; + end; + } + + if (@sp_notrespass > 0) + goto L_Warning; + dispbottom col(l("Only Sponsors are allowed past this area."),1); + slide 59,39; + @sp_notrespass=1; + end; + +L_Warning: + if (@sp_kick > 0) + goto L_Kick; + dispbottom col(l("Only Sponsors are allowed past this area."),1); + dispbottom col(l("Do not attempt to go there again."),1); + slide 60,40; + @sp_kick=1; + end; + +L_Kick: + if (SP_WARN > 5) + goto L_Ban; + dispbottom col(l("You cannot visit the Sponsor's Inn!"),1); + slide 36,46; + // Force user to disconnect + atcommand "@kick "+strcharinfo(0); + SP_WARN=SP_WARN+1; + end; + +L_Ban: + dispbottom col(l("You cannot visit the Sponsor's Inn!"),1); + slide 36,46; + // Prevent abuse and possible vulnerabilities. + atcommand "@ban 20mn "+strcharinfo(0); + SP_WARN=0; + end; +} diff --git a/npc/012-2/helena.txt b/npc/012-2/helena.txt new file mode 100644 index 0000000..cb3fdb2 --- /dev/null +++ b/npc/012-2/helena.txt @@ -0,0 +1,284 @@ +// TMW2 Script. +// Author: +// Jesusalva +// Description: +// Lena +// Variables: +// $HELENA_ST +// Tracks how many set of Treasure Keys were given by all players thus far. +// Affects beer prices on Hurnscald. +// HurnscaldQuest_Bandits +// q1 -> Current status +// q2 -> Treasure Key Timer +// q3 -> Bandit Hood Timer + +012-2,47,40,0 script Helena NPC_FEMALE,{ + .@q=getq(HurnscaldQuest_Bandits); + + // Stage 1: Level 30, collect Treasure Key + if (BaseLevel < 30) goto L_TooWeak; + if (.@q == 0) goto L_Start; + if (.@q == 1) goto L_Return; + + // Stage 2: Level 40, collect Bandit Hood + if (BaseLevel < 40) goto L_Weak; + if (.@q == 2) goto L_Quest; + if (.@q == 3) goto L_Hood; + + // Stage 3: Level 45, defeat Bandit Lord + if (BaseLevel < 45) goto L_Busy; + if (.@q == 4) goto L_BanditLord; + if (.@q == 5) goto L_Busy; + if (.@q == 6) goto L_Busy; + if (.@q == 7) goto L_Finish; + + goto L_Daily; + +L_Daily: + .@k=getq2(HurnscaldQuest_Bandits); + .@h=getq3(HurnscaldQuest_Bandits); + mesn; + mesq l("Ah, @@, my friend! Are you here to help us with 5 @@? Or perhaps you have 5 more @@ to show that Hurnscald is getting safer?", strcharinfo(0), getitemlink(TreasureKey), getitemlink(BanditHood)); + mes ""; + select + rif((.@k < santime()) && countitem(TreasureKey) >= 5, l("I have 5 Treasure keys with me.")), + rif((.@h < santime()) && countitem(BanditHood) >= 5, l("I have 5 Bandit Hoods with me.")), + l("Nothing at the moment."); + mes ""; + switch (@menu) { + case 1: + setq2 HurnscaldQuest_Bandits, santime()+(60*60*24); + delitem TreasureKey, 5; + Zeny=Zeny+600; // 600/550 = 9.09% bonus + //Zeny=Zeny+800; // 800/550 = 45.45% bonus + getexp 2000, 0; + $HELENA_ST=$HELENA_ST+2; + mesn; + mesq l("Many thanks! %%s"); + next; + goto L_Daily; + case 2: + setq3 HurnscaldQuest_Bandits, santime()+(60*60*24); + delitem BanditHood, 5; + Zeny=Zeny+250; // 250/155 = 61.29% bonus + getexp 3000, 5; + $HELENA_ST=$HELENA_ST+1; + mesn; + mesq l("Many thanks! %%s"); + next; + goto L_Daily; + } + close; + +L_TooWeak: + mesn; + mesq lg("Hello, madam!", "Hello, sir!"); + next; + mesn; + mesq l("Ah, we have serious problems of robbery. I need someone really strong to help me, and you don't qualify."); + close; + +L_Weak: + mesn; + mesq l("You still need to grow a few levels more before being able to help me out again."); + close; + +L_Busy: + mesn; + mesq l("Ah, @@! I'm busy now, can we talk again later?", strcharinfo(0)); + close; + +L_DoIt: + mesn; + mesq l("@@, we are counting on you! We, the whole Hurnscald town!", strcharinfo(0)); + close; + +///////////////////////// Stage 1 +L_Start: + mesn; + mesq l("Ah, hello."); + next; + mesn; + mesq l("We actually have a problem. Bandits ransacked this tavern, and took a huge loot."); + next; + mesn; + mesq l("We pursued them until the mines, slayed them, and took the chests where they locked our stuff into."); + next; + mesn; + mesq l("The problem is... The slimes ate the keys for the chests. This is not the first time such thing happens."); + next; + // 5 ÷ 4.5% = 112 Copper Slimes. You can kill Yellow Slimes too + mesn; + mesq l("If you bring us 5 @@, we'll be forever grateful.", getitemlink(TreasureKey)); + select + l("Don't worry ma'm, I'll recover the Treasure Keys at once."), + l("Ah... Slimes... Sorry, not my cup of tea..."); + mes ""; + if (@menu == 2) + close; + setq HurnscaldQuest_Bandits, 1; + mesn; + mesq l("Wonderful! I'll be expecting you back."); + close; + +L_Return: + mesn; + mesq lg("Adventurer, did you brought me what I asked? I see you have @@/5 @@.","Adventurer, did you brought me what I asked? I see you have @@/5 @@.", countitem(TreasureKey), getitemlink(TreasureKey)); + mes ""; + select + rif(countitem(TreasureKey) >= 5, l("Yes, take it.")), + rif(countitem(TreasureKey) < 5, l("No, I'll be back with them.")), + l("Hm, can we talk again later?"); + mes ""; + if (@menu != 1) + close; + delitem TreasureKey, 5; + Zeny=Zeny+1000; + getexp 1599,0; // 20% from needed exp + setq HurnscaldQuest_Bandits, 2; + mesn; + mesq l("Hey hey... Good job! We can now use again the stuff we recovered from the bandits."); + next; + mesn; + mesq l("Here is 1000 GP for your efforts. Thanks for making Hurnscald a better place to live."); + next; + mesn; + mesq l("This happens quite often, too. My friends and I are always collecting keys to reduce beer price on Hurnscald. %%2"); + close; + + +///////////////////////// Stage 2 +L_Quest: + mesn; + mesq l("Ah, @@, good thing you are here.", strcharinfo(0)); + next; + mesn; + mesq l("Bandits are a huge threat to Hurnscald. We're just a small farming town, and they're countless."); + next; + mesn; + mesq l("I did a travel to their cave, I wondered why their faces are never seen. Reason is that they're monsters."); + next; + mesn; + mesq l("Well, perhaps a few of them are rebels, I mean, people like us, but many of them are monsters."); + next; + mesn; + mesq l("Unfortunately, I was cursed to never enter their cave again. They used a @@ to do that!", getitemlink(BlueManaPearl)); + next; + if (countitem(BlueManaPearl) >= 1) { + mesn; + mesq l("Ah... You have one too. Be careful with it, please. Many people lost their lives because they didn't handled that correctly."); + next; + } + mesn; + mesq l("Thankfully that item is too rare. I want somebody to slay the bandit leader, but if you want to do it, you must prove yourself."); + next; + mesn; + mesq l("I will reward whoever kills the current bandit leader, of course."); + select + l("I would gladly aid you to get rid of that scourge."), + l("Sorry, I forgot my courage on my other set of pants."); + mes ""; + if (@menu == 2) + close; + setq HurnscaldQuest_Bandits, 3; + mesn; + mesq l("Wonderful! So, how about a warm up?"); + next; + // 8% drop. 10 / 8% = avg. 125 bandits to kill + // And for once, I won't require these bandits to be from Hurnscald Bandit Cave. + mesn; + mesq l("Bring me 10 @@. I'll pay you some money for that, of course.", getitemlink(BanditHood)); + close; + +L_Hood: + mesn; + mesq lg("Adventurer, did you brought me what I asked? I see you have @@/10 @@.","Adventurer, did you brought me what I asked? I see you have @@/10 @@.", countitem(BanditHood), getitemlink(BanditHood)); + mes ""; + select + rif(countitem(BanditHood) >= 10, l("Yes, take it.")), + rif(countitem(BanditHood) < 10, l("No, I'll be back with them.")), + l("Hm, can we talk again later?"); + mes ""; + if (@menu != 1) + close; + inventoryplace LeatherPatch, 1; + delitem BanditHood, 10; + Zeny=Zeny+2000; + getexp 6842,0; // 20% from needed exp + getitem LeatherPatch, 1; + setq HurnscaldQuest_Bandits, 4; + mesn; + mesq l("Hey hey... Good job! I was worried you would ruin their hoods before being able to take them."); + next; + mesn; + mesq l("Here is 2000 GP for your efforts. Thanks for making Hurnscald a better place to live."); + next; + mesc l("You also gained a @@. Bows are very slow, so you should talk to the Blacksmith to make a Quiver.", getitemlink(LeatherPatch)); + close; + + +///////////////////////// Stage 3 +L_BanditLord: + mesn; + mesq l("So... I won't say you can't do it, @@. I will just say killing the Bandit Lord is no easy task.", strcharinfo(0)); + next; + mesn; + mesq l("The @@ is not only a fearsome and ruthless leader. He is strong, and he have tricks on his sleeve.", getmonsterlink(BanditLord)); + next; + mesn; + mesq l("He will summon allies if he think you have the upper hand. So take care if you are going ranged."); + next; + mesn; + mesq l("I know another Bandit Lord will take up his place, but the loss of their leader will make bandits scatter long enough."); + next; + mesn; + mesq l("Will you help me- no, I mean, will you help us, the whole town of Hurnscald?"); + next; + select + l("Sorry, I need to better prepare myself."), + l("I would gladly give my life for such noble goal."); + mes ""; + if (@menu == 1) + close; + setq HurnscaldQuest_Bandits, 5; + mesn; + mesq l("...You have courage. Many people tried and failed."); + next; + mesn; + mesq l("I know where the Bandit Lord room is, and I have a guard stationed not far from there. Ask him for the key."); + next; + mesn; + mesq l("One last thing... Good luck. This is a long shot, so don't hesit in running away."); + close; + +L_Finish: + mesn; + mesq l("Ah... You did it!"); + next; + mesn; + mesq l("That's easy to know, because the bandits are less coordinated. Perhaps we will be able to sleep in peace this night!"); + next; + inventoryplace ForestArmor, 1; + getitem ForestArmor, 1; + getexp 5842,93; // 10% from needed exp + JExp level 6 + setq HurnscaldQuest_Bandits, 8; + mesn; + mesq l("Here is the @@, like my armor, and one of the best for rangers.", getitemlink(ForestArmor)); + next; + mesn; + mesq l("Any friend of Hurnscald is my friend too. Come to me again, if you want to do daily quests!"); + close; + +OnInit: + .@npcId = getnpcid(.name$); + setunitdata(.@npcId, UDT_HEADTOP, FairyHat); + setunitdata(.@npcId, UDT_HEADMIDDLE, ForestArmor); + setunitdata(.@npcId, UDT_HEADBOTTOM, CottonSkirt); + setunitdata(.@npcId, UDT_WEAPON, LousyMoccasins); + setunitdata(.@npcId, UDT_HAIRSTYLE, 17); + setunitdata(.@npcId, UDT_HAIRCOLOR, 7); + + .sex = G_FEMALE; + .distance = 5; + end; +} diff --git a/npc/012-2/khafar.txt b/npc/012-2/khafar.txt new file mode 100644 index 0000000..084ac29 --- /dev/null +++ b/npc/012-2/khafar.txt @@ -0,0 +1,137 @@ +// TMW2 Script. +// Author: +// Jesusalva +// Description: +// Kfahr - Placeholder +// Quests: +// HurnscaldQuest_Khafar +// .@q1 = when even, must buy a beer +// when odd, can ask another story +// .@q2 = Temporary variable, holds last story +// Secrets Unlocked: +// NivalisQuest_Baktar (status 1→2) +// Win arm wrestling to unlock Braknar Shield Secrets + +012-2,54,46,2 script Khafar NPC_ORC,{ + function MustDrink; + mesc l("You stand before a battle-scarred, darkly tanned warrior, brimming with muscles."); + mesc l("Just looking at him you smell danger, adventure, excitement..."); + next; + mesc l("On second thought, he really could use a bath."); + next; + mesc l("The warrior turns towards you, grinning broadly."); + next; + mesn; + mesq l("Why, hello there! Come to visit me to hear Kfahr the Warrior or Andrei Sakar's exploits, have you?"); + mesc l("He laughs heartily and gives you a slap on the back."); + next; + mesn; + mesq l("Can't blame you, can't blame you at all! Here, take a seat!"); + next; + goto L_Menu; + +L_Menu: + do + { + .@q=getq(HurnscaldQuest_Khafar); + if (.@q % 2 == 0) + MustDrink(); + select + l("Don't you have any exploit of your own?"), + l("Who is Kfahr the Warrior?"), + l("Who is Andrei Sakar?"), + l("Nah, see you later."); + mes ""; + switch (@menu) { + case 1: + mesn; + mesq l("I once killed a Giant Maggot alone!"); + next; + break; + case 2: + mesn; + mesq l("He is my grand-grand-grandfather! The might Kfahr, with his friend Braknar, and heroes from Tulimshar legends."); + next; + mesn; + mesq l("Together, they wrote legends. They slayed Toby Rick the Desert Worm, the mightiest desert beast."); + next; + mesn; + mesq l("Braknar also used a pseudonym - Arvek. If you hear that name in some tale, it is the same person."); + next; + mesn; + mesq l("Well, that was a good fight. My grand-grand-grandfeather gave his shield to Arvek -- err, Braknar I mean."); + next; + mesn; + mesq l("The last time they were seen... They went to explore the Desert Temple. None returned alive."); + next; + select + l("Cool story, bro!"), + l("What about the Desert Temple?"), + rif(getq(NivalisQuest_Baktar), l("What about the Shield?")), + l("What about the worm?"); + mes ""; + switch (@menu) { + case 2: + mesn; + mesq l("Lost forever on the Desert Canyon, I guess."); + next; + break; + case 3: + mesn; + mesq l("Oh, the @@ might be a heirloom or something from Braknar family. I dunno who could have it.", getitemlink(BraknarShield)); + if (getq(NivalisQuest_Baktar) == 1) + setq1 NivalisQuest_Baktar, 2; + next; + break; + case 4: + mesn; + mesq l("It is a boss. I don't know how to summon one, and to be honest - You won't want to see one either."); + next; + break; + } + break; + default: + mesn; + mesq lg("See you later, my friend! Thanks for the drink!"); + close; + break; + } + setq1 HurnscaldQuest_Khafar, .@q+1; + getexp 50, 0; // Beer is now lost - get 50xp + } while (true); + close; + +function MustDrink { + mesn; + mesq l("But first... My throat is dry. Can you bring me a beer?"); + if (!countitem(Beer)) + close; + next; + select + l("Here, you can have a glass."), + l("Sorry, I have nothing."); + mes ""; + if (@menu == 1) { + delitem Beer, 1; + .@q=getq(HurnscaldQuest_Khafar); + setq1 HurnscaldQuest_Khafar, .@q+1; + return; + } + close; +} + +OnInit: + .@npcId = getnpcid(.name$); + setunitdata(.@npcId, UDT_HEADTOP, FairyHat); + setunitdata(.@npcId, UDT_HEADMIDDLE, ForestArmor); + setunitdata(.@npcId, UDT_HEADBOTTOM, CottonShorts); + setunitdata(.@npcId, UDT_WEAPON, LousyMoccasins); + setunitdata(.@npcId, UDT_HAIRSTYLE, 24); + setunitdata(.@npcId, UDT_HAIRCOLOR, 7); + + .sex = G_MALE; + .distance = 5; + npcsit; + end; +} + diff --git a/npc/012-2/melina.txt b/npc/012-2/melina.txt new file mode 100644 index 0000000..ac183a9 --- /dev/null +++ b/npc/012-2/melina.txt @@ -0,0 +1,73 @@ +// TMW-2 Script +// Author: +// Jesusalva +// Description: +// Sells beer +// Variables: +// $HELENA_ST +// Controls stock and beer prices + +012-2,54,43,0 script Melina NPC_FEMALE,{ + +hello; +npcshopattach(.name$); +shop .name$; +close; + +OnTimer1000: + domovestep; + +OnInit: + .@npcId = getnpcid(.name$); + setunitdata(.@npcId, UDT_HEADTOP, CottonGloves); + setunitdata(.@npcId, UDT_HEADMIDDLE, CottonShirt); + setunitdata(.@npcId, UDT_HEADBOTTOM, AssassinBoots); + setunitdata(.@npcId, UDT_WEAPON, MiniSkirt); + setunitdata(.@npcId, UDT_HAIRSTYLE, 20); + setunitdata(.@npcId, UDT_HAIRCOLOR, 4); + + tradertype(NST_MARKET); + if ($HELENA_ST < 700) + sellitem Beer, 500-($HELENA_ST/2), ($HELENA_ST/3)+1; + else + sellitem Beer, 150, ($HELENA_ST/3)+1; + + initpath "move", 54, 43, + "dir", DOWN, 0, + "wait", 27, 0, + "move", 43, 43, + "dir", DOWN, 0, + "wait", 27, 0, + "move", 48, 45, + "dir", DOWN, 0, + "wait", 27, 0, + "move", 58, 42, + "dir", DOWN, 0, + "wait", 27, 0, + "move", 35, 43, + "dir", DOWN, 0, + "wait", 20, 0; + initialmove; + initnpctimer; + + .sex = G_FEMALE; + .distance = 5; + end; + +OnClock2358: + if ($HELENA_ST < 700) + restoreshopitem Beer, 500-($HELENA_ST/2), ($HELENA_ST/3)+1; + else + restoreshopitem Beer, 150, ($HELENA_ST/3)+1; + end; +// Pay your taxes! +OnBuyItem: + PurchaseTaxes("Hurns"); + end; + +OnSellItem: + debugmes("Sale confirmed"); + SaleTaxes("Hurns"); + end; + +} diff --git a/npc/012-2/note.txt b/npc/012-2/note.txt new file mode 100644 index 0000000..721fe6c --- /dev/null +++ b/npc/012-2/note.txt @@ -0,0 +1,29 @@ +// TMW2 Script. +// Author: +// Jesusalva +// Description: +// Lena +// Variables: +// $HELENA_ST +// Tracks how many set of Treasure Keys were given by all players thus far. +// Affects beer prices on Hurnscald. +// HurnscaldQuest_Bandits +// q1 -> Current status +// q2 -> Treasure Key Timer +// q3 -> Bandit Hood Timer + +012-2,40,41,0 script Note#012-2 NPC_NO_SPRITE,{ + HallOfSponsor(); + next; + if (.t > gettimetick(2)) + close; + .t=gettimetick(2)+2; + HallOfGMLog(); + close; + +OnInit: + .sex = G_OTHER; + .distance = 3; + .t=gettimetick(2); + end; +} diff --git a/npc/012-2/rakinorf.txt b/npc/012-2/rakinorf.txt new file mode 100644 index 0000000..8e0554a --- /dev/null +++ b/npc/012-2/rakinorf.txt @@ -0,0 +1,335 @@ +// TMW2/LoF scripts. +// Authors: +// Jesusalva +// Description: +// Current Hurnscald Mayor +// Variable: +// SQuest_Sponsor +// Quest ID: 4 + +012-2,34,79,0 script Rakinorf, Mayor NPC_ANSELMO_BR,{ + function resetSQS { + setq SQuest_Sponsor, 0, gettime(GETTIME_MONTH); + } + // Check monthly quest + .@d=getq2(SQuest_Sponsor); + if (.@d != gettime(GETTIME_MONTH)) resetSQS(); + + .@n=getq(General_Narrator); + .@q=getq(SQuest_Sponsor); + mesn; + mesq l("Ah... I need more beer to keep going... This is so awful..."); + // Handle main storyline + if (.@n >= 5 && .@n <= 6) + goto L_MainStory; + // Handle main storyline + + // Core + .@q=getq(SQuest_Sponsor); + if (!(.@q & .questID) && getgmlevel()) goto L_Menu; + close; + +L_Menu: + if (!(.@q & .questID)) + close; + + mesq l("I will reward you for 7 @@.", getitemlink(.itemID)); + mes ""; + menu + rif(countitem(.itemID) >= 7, l("Here they are!")), L_Finish, + l("Where can I find them?"),L_Where, + l("No, thanks."),L_Close; + +L_Finish: + .@q=getq(SQuest_Sponsor); + if (!(.@q & .questID)) + close; + + delitem .itemID, 7; + getitem StrangeCoin, rand2(2,4); + setq1 SQuest_Sponsor, .@q | .questID; + mes ""; + mesn; + mesq l("Many thanks! Come back later to bring me extra @@!", getitemlink(.itemID)); + close; + +L_Where: + mes ""; + mesq l("Ah, there are lots with Melina, downstairs."); + next; + +L_Close: + closedialog; + goodbye; + close; + +// Main Storyline +L_MainStory: + next; + // 5 - First time speaking + // setq2 + // 0 - Not Assigned + // 1 - Need to bring Beer + // 2 - Need to find out how Arkim is doing + // 3 - Complete, Reluctancy node + // 4 - Told about Hurnscald Liberation Day, but didn't told where previous mayor is + // 5 - Told you to tell Airlia about. + // 6 - Airlia told you what she knew, must talk to Rakinorf + // 7 - Need to get levels (standard quest) + // 6 - Must visit Halinarzo Library + // Note: Expires on logout: @returnpotion_expiredate + + if (.@n == 5) + .@n2=getq2(General_Narrator); + else + .@n2=99; + + if (.@n2 == 5) { + mesn; + mesq l("You should talk to Airlia again to understand what Lua wants me to do."); + mes ""; + } + + .@rk=(!(getq(SQuest_Sponsor) & .questID)); + + select + rif(.@rk && getgmlevel(), l("Maybe I could give you more beer?")), + rif(.@n2 == 0, l("I know it may sound silly, but I need your help to find out who I am.")), + rif(.@n2 == 1, l("I have brought you the beer.")), + rif(.@n2 == 2, l("I know how many bat teeth and wings Arkim collected.")), + rif(.@n2 == 3, l("I know it may sound silly, but I need your help to find out who I am.")), + rif(.@n2 == 4, l("Where can I find the previous mayor?")), + rif(.@n2 == 6, l("Airlia told me you should lend me a Return Potion.")), + rif(.@n2 == 7, l("I think I'm ready.")), + rif(.@n == 6 && countitem(BrokenWarpCrystal), l("The warp crystal broke.")), + //rif(.@n == 6 && (!countitem(ReturnPotion)||@returnpotion_expiredate<gettimetick(2)), l("I need more return potions.")), + l("Ok, thanks."); + + mes ""; + switch (@menu) { + case 1: + goto L_Menu; break; + case 2: + mesn; + mesq l("Not now... *hic* I need @@... *hic* Bring me @@ if you *hic* can...", getitemlink(Beer), l("four")); + setq2 General_Narrator, 1; + break; + case 3: + if (countitem(Beer) < 4) { + mesn; + mesq l("That's not *hic*... That's not what I asked you for..."); + next; + mesn; + mesq l("Please bring me *hic*... Bring me @@ @@!", 4, getitemlink(Beer)); + close; + } + delitem Beer, 4; + getexp BaseLevel*10, JobLevel*3; + setq2 General_Narrator, 2; + mesn; + mesq l("Aaaaaaaahhhhh.... Much better now *hic*."); + next; + mesn; + mesq l("Could you *hic* do me a favor? Arkim, on a cave southeast of *hic* here, is collecting some stuff."); + next; + mesn; + mesq l("He's an *hic* hermit, and collects *hic* Bat teeth and wings... Tell me how many he collected!"); + break; + case 4: + mesn; + mesq l("So? How many *hic* he collect?"); + mesc l("Protip: Arkim is in a cave southeast of here and is an hermit."); + input .@am; + mes ""; + // If players give up to 10 wings/teeths since you check, I don't mind + if (.@am < ($ARKIM_ST-10) || .@am > $ARKIM_ST) + goto L_Fail; + mesn; + mesq l("Thanks. You can go, now."); + getexp BaseLevel*2, JobLevel; + setq2 General_Narrator, 3; + break; + case 5: + mesn; + mesq lg("Aaaaaaah, gal... Just let me drink in peace.", "Aaaaaaah, boy... Just let me drink in peace."); + next; + mesn strcharinfo(0); + mes l("T.T \"Why I think you are withdrawing information all along?\""); + next; + mesn; + mesq l("Sure, sure... Why are you even *hic* asking me this, anyway? Do I look like your... *hic* your father or something?!"); + next; + select + l("Maybe you do, your jerk! Stop drinking! Lua told me that you could help me! DO YOUR JOB!!"), + l("Sorry, Mister Rakinorf, but it was Lua that said you could help me."); + next; + /* + if (@menu == 1) + Karma=Karma+1; + else + Karma=Karma-1; + */ + setq2 General_Narrator, 4; + mesn strcharinfo(0); + mesq l("All she told me was that I needed to visit Halinarzo, but was too weak, and should look for you instead."); + next; + // Rakinorf gets somber after that + mesn; + mesq l("Ah, Halinarzo... Dangerous place. Tulimshar route is plagued with snakes, Hurnscald route is more often than not flooded."); + next; + mesn; + mes l(">.> \"Sorry pal, I have no idea what she meant by that.\""); + next; + mesn; + mesq l("You see, just @@ ago, Hurnscald was liberated from a massive monster attack.", FuzzyTime($HURNS_LIBDATE)); + mesq l("Dragonstar and Aisen did their best along many others, and managed to liberate Hurnscald, though!"); + next; + mesn; + mesq l("Well, problem is, after that, there was demand for an election. The previous mayor lost. I won."); + next; + mesn; + mesq l("That's basically how democracy works. You are warranted to stay on the office until something goes gravely wrong."); + mesq l("Now I just drink down my worries and hope for the best."); + next; + mesn; + mesq l("The previous mayor was an amazing mayor, but even so, he lost the office after the Monster King attacked."); + next; + mesn; + mesq l("I'm afraid I can't be of any help to you."); + next; + mesn; + mesq l("And now... Somber time is over! Time to get back to drinking! Yaaaay!!"); + break; + case 6: + setq2 General_Narrator, 5; + mesn; + mesq l("His daughter, Airlia, is not air-headed as her mother Lia. Try asking her instead."); + break; + case 7: + mesn; + mesq l("Whaaaaaaat *hic* is she *hic* have she gotten crazy? *hic*"); + next; + mesn; + mesq l("That's a *hic* precious item, and you're *hic* not nearly *hic* strong or worth enough to use it!"); + next; + mesn; + mesq l("You will need to *hic* prove yourself to *hic* me and the town first..."); + next; + mesc b(l(".:: Main Quest 3-2 ::.")), 3; + msObjective(BaseLevel >= 35, l("* @@/@@ Base Level", BaseLevel, 35)); + + if (JobLevel >= 15) + mesc l("* @@/@@ Job Level", JobLevel, 15), 2; + else + mesc l("* @@/@@ Job Level", JobLevel, 15), 9; + + if (countitem(Scythe)) + mesc l("* @@/@@ @@", countitem(Scythe), 1, getitemlink(Scythe)), 2; + else + mesc l("* @@/@@ @@", countitem(Scythe), 1, getitemlink(Scythe)), 9; + + if (getq(HurnscaldQuest_BloodDonor)) + mesc l("* Donate blood at least once."), 2; + else + mesc l("* Donate blood at least once."), 9; + + setq2 General_Narrator, 7; + next; + //mesn; + if (!countitem(Scythe)) + mes l("- Help the farmers. We rely a lot on agriculture."); + if (!getq(HurnscaldQuest_BloodDonor)) + mes l("- To donate blood, go to the hospital and ask about it."); + if (JobLevel < 15) + mes l("- Boss give more Job experience, but as long that you keep killing, you'll keep gaining."); + if (BaseLevel < 35) + mes l("I think Lieutenant Paul had a bounty for extra experience."); + break; + + case 8: + mesc b(l(".:: Main Quest 3-2 ::.")), 3; + msObjective(BaseLevel >= 35, l("* @@/@@ Base Level", BaseLevel, 35)); + + msObjective(JobLevel >= 15, l("* @@/@@ Job Level", JobLevel, 15)); + + msObjective(countitem(Scythe), l("* @@/@@ @@", countitem(Scythe), 1, getitemlink(Scythe))); + + msObjective(getq(HurnscaldQuest_BloodDonor), l("* Donate blood at least once.")); + + next; + if (BaseLevel >= 35 && + JobLevel >= 15 && + countitem(Scythe) && + getq(HurnscaldQuest_BloodDonor)) + goto L_Complete; + mesn; + if (!countitem(Scythe)) + mes l("- Help the farmers. We rely a lot on agriculture."); + if (!getq(HurnscaldQuest_BloodDonor)) + mes l("- To donate blood, go to the hospital and ask about it."); + if (JobLevel < 15) + mes l("- Boss give more Job experience, but as long that you keep killing, you'll keep gaining."); + break; + + case 9: + mesn; + mesq l("I don't have a spare. They're *hic* done by ANISE INC., their headquarters are in Frostia."); + next; + mesn; + mesq l("Frostia is a *hic* town way way north of here. They *hic* hate humans, so... Good luck?"); + break; + /* + case 10: + if (countitem(ReturnPotion)) + delitem ReturnPotion, countitem(ReturnPotion); + inventoryplace ReturnPotion, 5; + getitem ReturnPotion, rand(2,5); + @returnpotion_expiredate=gettimetick(2)+1200+rand(300,1200); // 20 minutes + 5~20 minutes == last 25~40 minutes + mesn; + mesq l("There... *hic* They will expire *hic* in just @@... Or on logout.", FuzzyTime(@returnpotion_expiredate)); + break; + */ + } + close; + +L_Fail: + mesn; + mes l("Eh? You sure?"); + if (.@am > $ARKIM_ST) + mes l("I don't think he could have collected that many!"); + else + mes l("Last time they told me he collected more than that..."); + next; + mesn; + mesq l("Could you try again, please?"); + // No penalty? Really?? + close; + +L_Complete: + inventoryplace ReturnPotion, 5, HalinWarpCrystal, 1, HurnsWarpCrystal, 1; + mesn; + mesq l("Good, you *hic* proved your *hic* worth. I'll give you them."); + next; + mesn; + mesq l("Here are EXTREMELY VALUABLE warp crystals, and the *hic* fabled return potions."); + next; + mesn; + mesq l("Halinarzo is a *hic* level 50 area. So please *hic* be careful!"); + mesc l("WARNING: Warp Crystals can break after use and have a cooldown."); + mesc l("Return Potions works instantly. Talk to Wyara to get more."); + setq General_Narrator, 6, 0; + getitem ReturnPotion, 10; + getitem TulimWarpCrystal, 1; + getitem HurnsWarpCrystal, 1; + getexp BaseLevel*400, JobLevel*50;// Reference Levels: (35, 15) + getvaultexp(10); + close; + +OnInit: + .questID=4; + .itemID=Beer; + .sex=G_MALE; + .distance=5; + end; +} + |