diff options
34 files changed, 746 insertions, 83 deletions
diff --git a/client-data b/client-data -Subproject 15ff3ba1a4d1480acb1b97630dc811d8f14d08f +Subproject 082602abeed3ac6d29e1eb549aa184d72e48832 diff --git a/login/save/.gitignore b/login/save/.gitignore index 253bca5b..82cfa276 100644 --- a/login/save/.gitignore +++ b/login/save/.gitignore @@ -1,2 +1,2 @@ -/account.txt -/gm_account.txt +/account.txt* +/gm_account.txt* diff --git a/tools/_news_colors.py b/tools/_news_colors.py index 36f97b60..8b0c00b9 100644 --- a/tools/_news_colors.py +++ b/tools/_news_colors.py @@ -110,7 +110,8 @@ class TxtLink(object): def __init__(self, stack): self.stack = stack def __format__(self, target): - return '##3' + target + self.stack[-1] + # the field labeled 'bug' should not be necessary ... + return '@@{link}|{text}@@{bug}'.format(link=target, text=target, bug=self.stack[-1]) class TxtSignature(object): __slots__ = ('stack') diff --git a/world/conf/char_athena.conf b/world/conf/char_athena.conf index 8ea1f99f..38b494e6 100644 --- a/world/conf/char_athena.conf +++ b/world/conf/char_athena.conf @@ -31,7 +31,7 @@ max_connect_user: 0 check_ip_flag: yes // How often should the server save all files? (In seconds) -autosave_time: 15 +autosave_time: 300 // Character server flatfile database char_txt: save/athena.txt diff --git a/world/map/conf/magic.conf.template b/world/map/conf/magic.conf.template index cf3094c7..eb4f590d 100644 --- a/world/map/conf/magic.conf.template +++ b/world/map/conf/magic.conf.template @@ -568,6 +568,7 @@ SPELL lay-on-hands (target : STRING) : "#L10" = && (rdistance(location(caster), location(pc(target))) < 2 + (12 * sqrt(spellpower) + spellpower) / 100) && not (running_status_update(pc(target), SC_HALT_REGENERATE)) + && not (is_equipped(pc(target), "MagicGMTopHat")) )) => EFFECT CALL adjust_spellpower(school); IF (not (target)) THEN ABORT; @@ -715,6 +716,7 @@ SPELL protect (target : PC) : "#N11" = IN (MANA 14, CASTTIME 1500, REQUIRE skill(caster, MAGIC) > level, REQUIRE skill(caster, school) > level, + REQUIRE not(is_equipped(pc(target), "MagicGMTopHat")), (REQUIRE skill(caster, school) > 3 OR COMPONENTS ["HardSpike"]), REQUIRE rdistance(location(target), location(caster)) < 2 + spellpower / 30) => EFFECT CALL adjust_spellpower(school); @@ -814,7 +816,7 @@ SPELL shear : "#N14" = place = random_location(rbox(location(target), 1)); IF running_status_update(target, SC_SHEARED) THEN ABORT; - status_change(target, SC_SHEARED, 1, 1, 1, 1, 600000); # 10 minutes + status_change(target, SC_SHEARED, 0, 0, 0, 0, 600000); # 10 minutes CALL shear-drop("Fluffy", "Fluffy", "WhiteFur", 300); CALL shear-drop("EasterFluffy", "Easter Fluffy", "WhiteFur", 300); CALL shear-drop("SpikyMushroom", "Spiky Mushroom", "HardSpike", 250); @@ -836,6 +838,7 @@ SPELL barrier (target : PC) : "#A10" = IN (MANA 16, CASTTIME 1000, REQUIRE skill(caster, MAGIC) > level, REQUIRE skill(caster, school) > level, + REQUIRE not(is_equipped(pc(target), "MagicGMTopHat")), (REQUIRE skill(caster, school) > 3 OR COMPONENTS ["SmallMushroom"]), REQUIRE rdistance(location(target), location(caster)) < 2 + spellpower / 30) => EFFECT CALL adjust_spellpower(school); @@ -1718,3 +1721,12 @@ NONMAGIC SPELL illia0 : "#catalazuli" = REQUIRE ((rdistance(location(caster), lo => EFFECT { callfunc "StartChannelling"; }; + +#-------------------------------------------------------------------------------- +# Kill the GM event spell +#-------------------------------------------------------------------------------- + +NONMAGIC SPELL killgm0 : "#pullrabbit" = REQUIRE (is_equipped(caster, "MagicGMTopHat")) + => EFFECT { + callfunc "ActivateMagicGMTophat"; + }; diff --git a/world/map/data/resnametable.txt b/world/map/data/resnametable.txt index b1796af5..a865b707 100644 --- a/world/map/data/resnametable.txt +++ b/world/map/data/resnametable.txt @@ -75,6 +75,7 @@ 029-1.gat#029-1.wlk# 029-3.gat#029-3.wlk# 030-1.gat#030-1.wlk# +030-2.gat#030-2.wlk# 031-1.gat#031-1.wlk# 031-2.gat#031-2.wlk# 031-3.gat#031-3.wlk# diff --git a/world/map/db/const.txt b/world/map/db/const.txt index e50dfb24..6bed62d2 100644 --- a/world/map/db/const.txt +++ b/world/map/db/const.txt @@ -150,7 +150,7 @@ bAspdRate 1015 // +n% attack speed (bAspdRate,n;). bHPrecovRate 1016 // Natural HP recovery ratio increased of n% (bHPrecovRate,n;). //bSPrecovRate 1017 // Natural SP recovery ratio increased of n% (bSPrecovRate,n;). //bSpeedRate 1018 // Moving speed increased of n% and only the highest among all is applied (bSpeedRate,n;). -//bCriticalDef 1019 // Decreases the chance of being hit by critical hits of n% (bCriticalDef,n;). +bCriticalDef 1019 // Decreases the chance of being hit by critical hits of n% (bCriticalDef,n;). //bNearAtkDef 1020 // Adds n% damage reduction against melee physical attacks (bNearAtkDef,n;). //bLongAtkDef 1021 // Adds n% damage reduction against ranged physical attacks (bLongAtkDef,n;). //bDoubleRate 1022 // Adds a n% probability of doing a double attack (bDoubleRate,n;). @@ -534,6 +534,8 @@ FLAG_TUTORIAL_DONE 256 // player completed tutorial (or entered the tutor FLAG_SNOWMAN 512 // player gave candy to the snowman FLAG_SANTAS_HELPER 1024 // player gave presents to Santa's helper FLAG_HURNSMINE_CHEST 2048 // player opened the chest with the short sword in Hurnscald mines +FLAG_GOT_BEANIEHAT 4096 // player got Beanie Copter Hat from Milly +FLAG_DECLINED_BEANIEHAT 8192 // player declined Beanie Copter Hat from Milly DOCK_tulimshar 1 DOCK_hurnscald 2 diff --git a/world/map/db/item_db.txt b/world/map/db/item_db.txt index 6529ce25..8deda424 100644 --- a/world/map/db/item_db.txt +++ b/world/map/db/item_db.txt @@ -402,6 +402,9 @@ 885, GreenEggshellHat, Green Eggshell Hat, 5, 7000, 5000, 15, , 9, , 3, 0, 2, 256, , 1, 0, {}, {} 886, OrangeEggshellHat, Orange Eggshell Hat, 5, 7000, 5000, 15, , 9, , 3, 0, 2, 256, , 1, 0, {}, {} 887, DarkEggshellHat, Dark Eggshell Hat, 5, 7000, 5000, 15, , 9, , 3, 0, 2, 256, , 1, 0, {}, {} +888, MagicGMTopHat, Magic GM Top Hat, 5, 4200, 1900, 30, , 60, , 20, 0, 2, 256, , 0, 0, {}, {set @minLvl, 60; callfunc "RestrictedItem"; bonus bMaxHP, 31000; bonus bFlee, -200; bonus bHPrecovRate, -400; bonus bCriticalDef, 250; bonus bMdef, 89;} +889, MurdererCrown, Murderer Crown, 5, 75000, 12000, 240, , 4, , 0, 0, 2, 256, , 0, 0, {}, {} +890, BeanieCopter, Beanie Copter, 5, 8000, 2000, 20, , 4, , 2, 0, 2, 256, , 0, 0, {}, {} // Add new entries above here. For dyed entries,add to the bottom of the 2000s. diff --git a/world/map/news.d/13-lpc.txt b/world/map/news.d/13-lpc.txt new file mode 100644 index 00000000..1ab530ca --- /dev/null +++ b/world/map/news.d/13-lpc.txt @@ -0,0 +1,39 @@ +{date:2013-02-18} + +This is a really exciting news entry! + +Congratulations to our sister project Mana ({link:http://manasource.org}) +on winning the Liberated Pixel Cup ({link:http://lpc.opengameart.org/content/code-judging-is-in}). + +The project can be found at {link:http://www.sourceoftales.org/news.html} +and the irc channel at {link:irc://chat.freenode.net#sourceoftales}. + +We will undoubtedly experience an influx of both +ordinary players and potential developers since we +were linked as a related project. + +As a developer, it is my goal and expectation that +new players can figure things out on their own. +After all, I once did - though there wasn't as +much content back then (I feel old ...). + +As for new contributors, they will necessarily need +to coordinary with us, the developers. We're always +in need of pixel artists, have great capacity for +quest writers, and currently have need for a bit of +web development and people crazy enough to touch +insides of the server code. + +Be aware that people have different time zones and +busy schedules, so it may be a while before anyone +responds. + +Now, the links: + +Server coding: {link:irc://chat.freenode.net#tmwa} + +Everything else: {link:irc://irc.themanaworld.org#tmw-dev} or {link:irc://chat.freenode.net#themanaworld-dev} + +Forums: {link:http://forums.themanaworld.org/} + +{author:o11c and Jenalya} diff --git a/world/map/news.d/14-bugfix-killthegmevent.txt b/world/map/news.d/14-bugfix-killthegmevent.txt new file mode 100644 index 00000000..24cb9b90 --- /dev/null +++ b/world/map/news.d/14-bugfix-killthegmevent.txt @@ -0,0 +1,12 @@ +{date:2013-02-21} + +Today we'll have a small content release. + +Among code cleaning and bug fixes, the +Tulimshar quests can be done in any order now. +Their completion isn't necessary anymore +to start the Bandit quest. + +Also, GMs may have a surprise for you someday. + +{author:V0id} diff --git a/world/map/news.html b/world/map/news.html index b07b5801..eea0afe5 100644 --- a/world/map/news.html +++ b/world/map/news.html @@ -1,6 +1,63 @@ <!-- Generated by tools/news.py for index.php --> <div> <p/> +<font color="#0000ff">2013-02-21</font> +<p/> +Today we'll have a small content release. +<p/> +Among code cleaning and bug fixes, the +Tulimshar quests can be done in any order now. +Their completion isn't necessary anymore +to start the Bandit quest. +<p/> +Also, GMs may have a surprise for you someday. +<p/> +-<font color="#009000">V0id</font> +</div> +<div> +<p/> +<font color="#0000ff">2013-02-18</font> +<p/> +This is a really exciting news entry! +<p/> +Congratulations to our sister project Mana (<a href="http://manasource.org">http://manasource.org</a>) +on winning the Liberated Pixel Cup (<a href="http://lpc.opengameart.org/content/code-judging-is-in">http://lpc.opengameart.org/content/code-judging-is-in</a>). +<p/> +The project can be found at <a href="http://www.sourceoftales.org/news.html">http://www.sourceoftales.org/news.html</a> +and the irc channel at <a href="irc://chat.freenode.net#sourceoftales">irc://chat.freenode.net#sourceoftales</a>. +<p/> +We will undoubtedly experience an influx of both +ordinary players and potential developers since we +were linked as a related project. +<p/> +As a developer, it is my goal and expectation that +new players can figure things out on their own. +After all, I once did - though there wasn't as +much content back then (I feel old ...). +<p/> +As for new contributors, they will necessarily need +to coordinary with us, the developers. We're always +in need of pixel artists, have great capacity for +quest writers, and currently have need for a bit of +web development and people crazy enough to touch +insides of the server code. +<p/> +Be aware that people have different time zones and +busy schedules, so it may be a while before anyone +responds. +<p/> +Now, the links: +<p/> +Server coding: <a href="irc://chat.freenode.net#tmwa">irc://chat.freenode.net#tmwa</a> +<p/> +Everything else: <a href="irc://irc.themanaworld.org#tmw-dev">irc://irc.themanaworld.org#tmw-dev</a> or <a href="irc://chat.freenode.net#themanaworld-dev">irc://chat.freenode.net#themanaworld-dev</a> +<p/> +Forums: <a href="http://forums.themanaworld.org/">http://forums.themanaworld.org/</a> +<p/> +-<font color="#009000">o11c and Jenalya</font> +</div> +<div> +<p/> <font color="#0000ff">2013-01-31</font> <p/> ManaPlus Support diff --git a/world/map/news.php b/world/map/news.php index 23786bb4..3338e9f4 100644 --- a/world/map/news.php +++ b/world/map/news.php @@ -32,7 +32,12 @@ if (substr($agent, 0, 5) == "Mana/" "##1 TMW Staff\n \n"; } -echo "##9 Latest client version: ##6$cur_version\n##0\n"; +echo "##9 Latest client version: ##6$cur_version\n \n"; +echo "##7 TMW Staff will never ask you for your password.\n"; +echo "##7 Anyone doing so is trying to scam you.\n \n"; + +echo "##1 Sharing an account to a computer system is like sharing\n"; +echo "##1 your underwear.##0\n \n##0\n"; print file_get_contents("news.txt"); ?> diff --git a/world/map/news.txt b/world/map/news.txt index a8e9b0ce..d84afadb 100644 --- a/world/map/news.txt +++ b/world/map/news.txt @@ -1,3 +1,58 @@ +##32013-02-21##0 + +Today we'll have a small content release. + +Among code cleaning and bug fixes, the +Tulimshar quests can be done in any order now. +Their completion isn't necessary anymore +to start the Bandit quest. + +Also, GMs may have a surprise for you someday. + +-##2V0id##0 + + +##32013-02-18##0 + +This is a really exciting news entry! + +Congratulations to our sister project Mana (@@http://manasource.org|http://manasource.org@@##0) +on winning the Liberated Pixel Cup (@@http://lpc.opengameart.org/content/code-judging-is-in|http://lpc.opengameart.org/content/code-judging-is-in@@##0). + +The project can be found at @@http://www.sourceoftales.org/news.html|http://www.sourceoftales.org/news.html@@##0 +and the irc channel at @@irc://chat.freenode.net#sourceoftales|irc://chat.freenode.net#sourceoftales@@##0. + +We will undoubtedly experience an influx of both +ordinary players and potential developers since we +were linked as a related project. + +As a developer, it is my goal and expectation that +new players can figure things out on their own. +After all, I once did - though there wasn't as +much content back then (I feel old ...). + +As for new contributors, they will necessarily need +to coordinary with us, the developers. We're always +in need of pixel artists, have great capacity for +quest writers, and currently have need for a bit of +web development and people crazy enough to touch +insides of the server code. + +Be aware that people have different time zones and +busy schedules, so it may be a while before anyone +responds. + +Now, the links: + +Server coding: @@irc://chat.freenode.net#tmwa|irc://chat.freenode.net#tmwa@@##0 + +Everything else: @@irc://irc.themanaworld.org#tmw-dev|irc://irc.themanaworld.org#tmw-dev@@##0 or @@irc://chat.freenode.net#themanaworld-dev|irc://chat.freenode.net#themanaworld-dev@@##0 + +Forums: @@http://forums.themanaworld.org/|http://forums.themanaworld.org/@@##0 + +-##2o11c and Jenalya##0 + + ##32013-01-31##0 ManaPlus Support @@ -30,9 +85,9 @@ support, depending on exactly how old it is: Of course, if a particular client release is buggy, we may not be able to support it at all. -For more details, see ##3http://forums.themanaworld.org/viewtopic.php?f=4&t=16867##0. +For more details, see @@http://forums.themanaworld.org/viewtopic.php?f=4&t=16867|http://forums.themanaworld.org/viewtopic.php?f=4&t=16867@@##0. -ManaPlus is available at ##3http://manaplus.evolonline.org/##0 +ManaPlus is available at @@http://manaplus.evolonline.org/|http://manaplus.evolonline.org/@@##0 -##2o11c##0 @@ -150,7 +205,7 @@ But what is he doing there? And where is Easter Bunny? Three pieces of news today. First, Mana 0.6.0 got released today. You can find it at -##3http://manasource.org##0, or wait for your distribution. +@@http://manasource.org|http://manasource.org@@##0, or wait for your distribution. Second, we will be completely dropping support for the old TMW 0.0.29.1 client soon - unless there is further reason diff --git a/world/map/npc/002-1/lieutenant_dausen.txt b/world/map/npc/002-1/lieutenant_dausen.txt index 515cd76a..47fb0c57 100644 --- a/world/map/npc/002-1/lieutenant_dausen.txt +++ b/world/map/npc/002-1/lieutenant_dausen.txt @@ -22,7 +22,7 @@ set @vincent, ((QUEST_SouthTulimshar & NIBBLE_2_MASK) >> NIBBLE_2_SHIFT); set @sandra, ((QUEST_SouthTulimshar & NIBBLE_3_MASK) >> NIBBLE_3_SHIFT); - if ((@bermik >= 6) && (@sarah >= 2) && (@vincent >= 2) && (@sandra >= 2)) + if ((@state == 0) && (@bermik >= 6) && (@sarah >= 2) && (@vincent >= 2) && (@sandra >= 2)) goto L_LD_Start; mes "[Lieutenant Dausen]"; diff --git a/world/map/npc/002-4/chest.txt b/world/map/npc/002-4/chest.txt index c2fec840..61b59109 100644 --- a/world/map/npc/002-4/chest.txt +++ b/world/map/npc/002-4/chest.txt @@ -44,4 +44,8 @@ L_TooMany: L_Close: set @state, 0; close; + +S_Update_Var: + set QUEST_SouthTulimshar, (QUEST_SouthTulimshar & ~(BYTE_2_MASK) | (@state << BYTE_2_SHIFT)); + return; } diff --git a/world/map/npc/002-4/miners.txt b/world/map/npc/002-4/miners.txt index 401a7bbc..fdb20306 100644 --- a/world/map/npc/002-4/miners.txt +++ b/world/map/npc/002-4/miners.txt @@ -69,4 +69,8 @@ L_Sema_Done: L_Close: set @state, 0; close; + +S_Update_Var: + set QUEST_SouthTulimshar, (QUEST_SouthTulimshar & ~(BYTE_2_MASK) | (@state << BYTE_2_SHIFT)); + return; } diff --git a/world/map/npc/007-1/witch.txt b/world/map/npc/007-1/witch.txt index fa81c8d8..354df9a0 100644 --- a/world/map/npc/007-1/witch.txt +++ b/world/map/npc/007-1/witch.txt @@ -788,7 +788,7 @@ L_WarpHelper: L_DoWarpHelper: // At this point, the player has been attached if ($@illia_progress >= 5) - message strcharinfo(0), "You feel dizzy, and that your memory is being rewritten... Who is Luvia? Something isn't alright."; + message strcharinfo(0), "You feel dizzy, and that your memory is being rewritten... Who is Luvia? Something isn't right."; warp "007-1.gat",85 + rand(0,2),75 + rand(0,2); detachrid; goto L_NextHelperToWarp; @@ -843,7 +843,7 @@ L_HeroEscape: L_WarpHero: // At this point, the player has been attached if ($@illia_progress >= 5) - message strcharinfo(0), "You feel dizzy, and that your memory is being rewritten... Who is Luvia? Something isn't alright."; + message strcharinfo(0), "You feel dizzy, and that your memory is being rewritten... Who is Luvia? Something isn't right."; warp "007-1.gat",85 + rand(0,2),75 + rand(0,2); detachrid; end; diff --git a/world/map/npc/009-1/milly.txt b/world/map/npc/009-1/milly.txt index df0d31be..a6b505cc 100644 --- a/world/map/npc/009-1/milly.txt +++ b/world/map/npc/009-1/milly.txt @@ -1,30 +1,467 @@ +// Milly is involved in: +// Beanie-Copter quest +// Story and dialogs: veryape +// Scripting: Jenalya +// Spelling, grammar and phrasing changes: Qwerty Dragon +// +// Inspector quest + 009-1.gat,81,41,0|script|Milly|114,{ callfunc "ClearVariables"; set @inspector, ((QUEST_Hurnscald & NIBBLE_3_MASK) >> NIBBLE_3_SHIFT); + set @got_boneknife, ((QUEST_Forestbow_state & NIBBLE_2_MASK) >> NIBBLE_2_SHIFT) >= 4; + set @got_setzer, ((QUEST_Forestbow_state & NIBBLE_3_MASK) >> NIBBLE_3_SHIFT) >= 8; + set @saved_rossy, (FLAGS & FLAG_ROSSI_COMPLETED); + set @saved_cindy, ((QUEST_Nivalis_state & NIBBLE_5_MASK) >> NIBBLE_5_SHIFT) >= 4; + + if (FLAGS & FLAG_GOT_BEANIEHAT) goto L_FinishedGood; + if (FLAGS & FLAG_DECLINED_BEANIEHAT) goto L_FinishedBad; + + if (@saved_rossy && @saved_cindy && @got_setzer && (BOSS_POINTS >= 5000)) goto L_OfferCap; + if (@got_setzer) goto L_GotSetzer; + if (@saved_cindy) goto L_SavedCindy; + if (@saved_rossy) goto L_SavedRossy; + if (@got_boneknife) goto L_GotBoneKnife; + if (BaseLevel > 40) goto L_NoKnifeYet; + + mes "[Milly]"; + mes "\"Hello traveler, welcome to Hurnscald.\""; + next; + if (@inspector == 1) + callsub S_InspectorQuest; + + mes "\"Have you met Kfahr yet? He is the greatest hero that ever walked the land of Hurnscald!\""; + menu + "Hi! No, I haven't seen him yet.", L_Where, + "Where can I find him?", L_Where, + "Mh, I don't care for heroes.", L_Care, + "Hello, yes I have met him.", L_MetKfahr; + +L_Where: + mes "[Milly]"; + mes "\"I highly recommend you seek him out! He is a regular at the inn, located in the north-west part of town. If you are lucky he might tell you a story about his adventures.\""; + goto L_Close; + +L_Care: + mes "[Milly]"; + mes "\"What? Surely you do not appreciate what a hero he is! Mh, or perhaps honor is dead in you; for you to be so slow to comprehend the good that his exploits have wrought for us. Put on your thinking cap and be propelled into high adventure! Go to Kfahr, and listen to his stories.\""; + next; + mes "\"You can't have met him. No one who has met him would say such silly things.\""; + next; + goto L_Where; + +L_MetKfahr: + mes "[Milly]"; + mes "\"Oh, I hope you stayed and listened to his stories about his adventures.\""; + goto L_Close; + +L_NoKnifeYet: + mes "[Milly]"; + mes "\"Hi again.\""; + next; + if (@inspector == 1) + callsub S_InspectorQuest; + + mes "\"Have you talked to Kfahr lately?\""; + menu + "Yes.", L_TalkKfahr, + "No.", L_HintKnife; + +L_TalkKfahr: + mes "[Milly]"; + mes "\"Is it true as the rumors say? ...\""; + next; + goto L_HintKnife; + +L_HintKnife: + mes "[Milly]"; + mes "\"You really should go meet him.\""; + next; + mes "\"I've heard that he is helping adventurers such as yourself with some exotic gear.\""; + menu + "I am not sure, I'd better go talk to him again.", L_Unsure, + "Yes, it is true.", L_True; + +L_Unsure: + mes "[Milly]"; + mes "\"You better hurry up before he changes his mind!\""; + goto L_Close; + +L_True: + mes "[Milly]"; + mes "\"So, why haven't you accepted his generous offer?\""; + menu + "I was just about to...", L_Unsure, + "I don't need any help.", L_NoHelp; + +L_NoHelp: + mes "[Milly]"; + mes "\"You must be kidding me.\""; + next; + mes "\"I am just a kid but not as silly as you. My pigtails possess more wisdom than you. You fooled me, you are no adventurer!\""; + next; + mes "\"You better learn from the wise and accept help from those who offer it.\""; + goto L_Unsure; + +L_GotBoneKnife: + mes "[Milly]"; + mes "\"Hi there.\""; + next; + if (@inspector == 1) + callsub S_InspectorQuest; + + mes "\"I heard that you got an exotic knife from Kfahr."; + mes "Would you kindly show it to me?\""; + menu + "Sure.", L_ShowKnife, + "Haven't I already?", L_ShowKnifeAgain; + +L_ShowKnife: + if (countitem("BoneKnife") < 1) + goto L_ShowKnifeNo; + mes "[Milly]"; + mes "\"Wow! That is a knife fitting a real adventurer!\""; + next; + mes "\"Kfahr ain't just a hero, he is also a stand up guy.\""; + next; + mes "\"You should be proud that he is honoring you with his knife like this.\""; + next; + mes "\"What a hero...\""; + goto L_Close; + +L_ShowKnifeAgain: + mes "[Milly]"; + mes "\"What possible objection could you have? It's so exiting to see such a fine knife.\""; + next; + mes "\"It is like cake, sure I might have had it before...\""; + next; + mes "\"... but does that stop me from wanting it once more?\""; + next; + mes "\"NO!\""; + next; + mes "\"Please let me see it!\""; + menu + "Okay.", L_ShowKnife, + "Enough is enough.", L_ShowKnifeNo; + +L_ShowKnifeNo: + mes "[Milly]"; + mes "\"I hope that the reason that you don't show it to me is because you have it tucked away somewhere safe.\""; + next; + mes "\"Otherwise you are just a bore...\""; + next; + mes "\"Don't be boring!\""; + goto L_Close; + +L_SavedRossy: + mes "[Milly]"; + mes "\"Hi friend!\""; + next; + if (@inspector == 1) + callsub S_InspectorQuest; + + mes "\"Word of your fame has spread throughout all Hurnscald of your great heroism by helping my friends Rossy and Julia!\""; + next; + mes "\"Not only did you help Rossy, you saved her sister Julia from that nefarious Fey Element. That was a real act of valor!\""; + next; + mes "\"You are shaping up to be something of a hero yourself.\""; + next; + mes "\"I am so happy that you came to Hurnscald, without you I'm not so sure that Julia would have been saved.\""; + menu + "You're right, I am a hero!", L_Loudmouth, + "I'm doing my best!", L_Modesty; + +L_Loudmouth: + mes "[Milly]"; + mes "\"You surely are not...\""; + next; + mes "\"First and foremost you are a loudmouth. You need to learn actions speak better for themselves without your boasting.\""; + next; + mes "\"A little modesty would be a distinguishing trait for you to cultivate. You are talking as if you think that you are equal with Kfahr.\""; + next; + mes "\"I think you should show a little more respect when you are this close to legendary heroes.\""; + goto L_Close; + +L_Modesty: + mes "[Milly]"; + mes "\"Wow, you have been very helpful and unselfish risking your own safety for the sake of others! Thanks to that Julia is back and Olana is able to sleep at night.\""; + next; + mes "\"If you continue with these valiant deeds you might earn your place in the history books of Hurnscald!\""; + goto L_Close; + +L_SavedCindy: + mes "[Milly]"; + mes "\"Hi!\""; + next; + if (@inspector == 1) + callsub S_InspectorQuest; + + mes "\"Are the rumors true?\""; + next; + mes "\"Word is going around that you saved a girl called Cindy who was captured by Yetis in Nivalis, and that you arranged a rescue party getting her back from a deep Yeti inhibited cave.\""; + menu + "Thanks to the party, yes.", L_Party, + "Yes, it is true!", L_Cindy; + +L_Party: + mes "[Milly]"; + mes "\"Wow! Not only are you brave, you also have the wisdom to seek help when needed!\""; + next; + mes "\"Being a skilled fighter is good. But being a skilled fighter coupled with your wits and organizational skill, now that is something special!\""; + goto L_HeroGrowing; + +L_Cindy: + mes "[Milly]"; + mes "\"Once again you have done good!\""; + goto L_HeroGrowing; + +L_HeroGrowing: + mes "[Milly]"; + mes "\"You have saved two kids about my own age from horrible situations, it is just like the stories I heard growing up.\""; + next; + mes "\"Things certainly are shaping up for you. My schoolmates play a game with you as the hero. And poets admire you in verse and song...\""; + next; + mes "\"Since you have proven yourself with your great acts, I will let you in on an exciting rumor I have heard.\""; + next; + mes "\"I have heard that Nicholas has learned new techniques in forging and weapon smithing. He is now able to improve a small sword into what is called a Setzer.\""; + next; + mes "\"Go talk to him and hear if he can help you get hold of one of these weapons.\""; + goto L_Close; + +L_GotSetzer: mes "[Milly]"; - mes "\"Hello.\""; + mes "\"Hello!\""; + next; + if (@inspector == 1) + callsub S_InspectorQuest; + + mes "\"I heard that you got hold of a Setzer!\""; + next; + mes "\"And the fact that Kfahr helped you means he really rates you as a fellow adventurer!\""; next; - if (@inspector != 1) + mes "\"Praise does not get much better than that around here. He knows a good adventurer when he see one, you must have impressed him!\""; + if (!@saved_cindy || !@saved_rossy) goto L_Close; + next; + mes "\"To be honest you are fast becoming my favored hero, even... dare I say it? Even more so than Kfahr.\""; + next; + mes "\"Your skill and good deeds are indisputable! However...\""; + next; + mes "\"Somehow I feel that you still need to establish your courage. The elders say that although they find you an admirable person, a hero of renown; that you can't be considered as great as Kfahr till you have proven yourself fearless.\""; + next; + mes "\"You could prove yourself as the greatest hero who has walked the land by accepting Paruas challenge at Candor. Stare death in the eyes, show no fear and conquer! Show everyone that you are worthy of the title: The Greatest Hero Ever!\""; + next; + mes "\"I myself already consider you my favorite hero, sure Kfahr has done great things, but...\""; + next; + mes "\"Nowadays he mostly sits around with that sad bunch of drunkards in the Inn, drinking beer and talking about past glory.\""; + next; + mes "\"For my generation you are the true hero, please prove the stony hearted elders wrong by showing them that you are fearless!\""; + next; + mes "\"Good luck and good bye! Health, mana, and wealth be yours! \""; + goto L_Close; + +L_OfferCap: + mes "[Milly]"; + mes "\"Hi there, hero of Hurnscald!\""; + next; + if (@inspector == 1) + callsub S_InspectorQuest; + + mes "\"You really have proven yourself over and over. There is no way anyone could possibly say, you are not the equal of Kfahr!\""; + next; + mes "\"Now, even the stones of Hurnscald praise you as a hero as great as Kfahr!\""; + next; + mes "\"I have something I want to give you...\""; + next; + mes "\"I was given two of those helicopter beanie caps at my birthday. I told everyone that it was what I really wanted so I got two of them...\""; + next; + mes "\"And some other kids are picking on me for wearing it, they say it is for nerds... I would be happy to give you one of them.\""; + next; + mes "\"It would be great if you wore a cap just like mine, that would sure shut them up! Also, please accept this rare hat as a token of my gratitude for everything you have done.\""; + next; + mes "\"It would be an honor to have the same cap as my hero!\""; + menu + "Thank you!", L_Cap, + "No, thanks.", L_Idiot; + +L_Cap: + mes "[Milly]"; + mes "\"Wow, thanks for accepting my gift, it is so pleasing to know that you have the exact same cap as me! Friends forever!\""; + getinventorylist; + if (@inventorylist_count == 100 || (checkweight("BeanieCopter", 1) == 0)) + goto L_TooMany; + getitem "BeanieCopter", 1; + set FLAGS, FLAGS | FLAG_GOT_BEANIEHAT; + next; + mes "She is giggling with excitement."; + next; + mes "[Milly]"; + mes "\"Come see me anytime! Goodbye!\""; + goto L_Close; +L_Idiot: + mes "[Milly]"; + mes "\"Are you really sure? It is such a neat cap.\""; + menu + "Yes, no nerd hat for me!", L_BadBye, + "Just kidding, I want one!", L_Cap; + +L_BadBye: + mes "Tears are forming in her eyes."; + mes "[Milly]"; + mes "\"I guess they were right, you're not any great hero! I'll give it to Kfahr instead!\""; + next; + mes "\"Please keep on traveling so I don't have to see you around here. It makes me sad to see you, every time I do I'll remember how wrong I was about you.\""; + set FLAGS, FLAGS | FLAG_DECLINED_BEANIEHAT; + goto L_Close; + +L_TooMany: + mes "[Milly]"; + mes "\"You don't have any space left to carry it, go put some stuff in the storage and come back!\""; + goto L_Close; + +L_FinishedGood: + mes "[Milly]"; + mes "\"Hi there friend, my hero!\""; + next; + if (@inspector == 1) + callsub S_InspectorQuest; + + mes "\"Wear the copter beany cap in good health, mana and wealth! See you around!\""; + goto L_Close; + +L_FinishedBad: + mes "[Milly]"; + mes "\"Oh, it's you. I suppose you're here to make fun of my hat again.\""; + next; + if (@inspector == 1) + callsub S_InspectorQuest; + mes "\"Won't you continue your travels soon?\""; + menu + "That's what I'm going to do.", -, + "I'm really sorry. Of course I want your hat!", L_Apologize; + + mes "Milly looks away sadly."; + goto L_Close; + +L_Apologize: + getinventorylist; + if (@inventorylist_count == 100 || (checkweight("BeanieCopter", 1) == 0)) + goto L_TooMany; + getitem "BeanieCopter", 1; + set FLAGS, FLAGS | FLAG_GOT_BEANIEHAT; + set FLAGS, FLAGS & ~FLAG_DECLINED_BEANIEHAT; + + mes "Milly looks surprised."; + next; + mes "[Milly]"; + mes "\"Oh, I... uh, thank you! I knew it! I knew such a heroic person as you can't be that mean.\""; + goto L_Close; + +L_Close: + set @got_boneknife, 0; + set @got_setzer, 0; + set @saved_rossy, 0; + set @saved_cindy, 0; + set @inspector, 0; + close; + +S_InspectorQuest: menu "Have you seen anything strange lately?", L_NohMask_Strange, "Do you know anything about the recent robberies?", L_NohMask_Robbery, - "Hello.", L_Close; + "Hello.", L_Return; L_NohMask_Strange: mes "[Milly]"; mes "\"I haven't seen anything strange.\""; - goto L_Close; + next; + goto L_Return; L_NohMask_Robbery: mes "[Milly]"; mes "\"No, sorry.\""; - goto L_Close; + next; + goto L_Return; + +L_Return: + return; +} + +009-1.gat,82,41,0|script|MillyDebugHelper|114,{ + + mes "You can set certain quests as finished or not finished. What would you like to do?"; + menu + "Bone Knife Quest done.", L_DBoneKnife, + "Rossy Quest done.", L_DRossy, + "Cindy Quest done.", L_DCindy, + "Setzer Quest done.", L_DSetzer, + "Gain 5000 Boss Points.", L_DBossPoints, + "Bone Knife and Setzer Quest not done.", L_NBoneKnife, + "Rossy Quest not done.", L_NRossy, + "Cindy Quest not done.", L_NCindy, + "Setzer Quest not done.", L_NSetzer, + "Remove all Boss Points.", L_NBossPoints, + "Nothing.", L_Close; + +L_DBoneKnife: + set QUEST_Forestbow_state, (QUEST_Forestbow_state & ~(NIBBLE_2_MASK)) | (4 << NIBBLE_2_SHIFT); + mes "Bone Knife quest set to completed."; + close; + +L_DSetzer: + set QUEST_Forestbow_state, (QUEST_Forestbow_state & ~(NIBBLE_2_MASK)) | (4 << NIBBLE_2_SHIFT); + set QUEST_Forestbow_state, (QUEST_Forestbow_state & ~(NIBBLE_3_MASK)) | (8 << NIBBLE_3_SHIFT); + mes "Setzer quest set to completed. This includes the Bone Knife quest."; + close; + +L_DRossy: + set FLAGS, FLAGS | FLAG_ROSSI_COMPLETED; + mes "Rossy quest set to completed."; + close; + +L_DCindy: + set QUEST_Nivalis_state, (QUEST_Nivalis_state & ~(NIBBLE_5_MASK)) | (4 << NIBBLE_5_SHIFT); + mes "Cindy quest set to completed."; + close; + +L_DBossPoints: + set BOSS_POINTS, 5000; + mes "Boss Points set to 5000."; + close; + +L_NBoneKnife: + set QUEST_Forestbow_state, (QUEST_Forestbow_state & ~(NIBBLE_2_MASK)) | (0 << NIBBLE_2_SHIFT); + set QUEST_Forestbow_state, (QUEST_Forestbow_state & ~(NIBBLE_3_MASK)) | (0 << NIBBLE_3_SHIFT); + mes "Bone Knife and Setzer quest set to not completed."; + close; + +L_NSetzer: + set QUEST_Forestbow_state, (QUEST_Forestbow_state & ~(NIBBLE_3_MASK)) | (0 << NIBBLE_3_SHIFT); + mes "Bone Knife and Setzer quest set to not completed."; + close; + +L_NRossy: + set FLAGS, FLAGS & ~FLAG_ROSSI_COMPLETED; + mes "Rossy quest set to not completed."; + close; + +L_NCindy: + set QUEST_Nivalis_state, (QUEST_Nivalis_state & ~(NIBBLE_5_MASK)) | (0 << NIBBLE_5_SHIFT); + mes "Cindy quest set to not completed."; + close; + +L_NBossPoints: + set BOSS_POINTS, 0; + mes "Boss Points set to 0."; + close; L_Close: - set @inspector, 0; close; + +OnInit: + if (!debug) + disablenpc "MillyDebugHelper"; } diff --git a/world/map/npc/009-2/kfahr.txt b/world/map/npc/009-2/kfahr.txt index 5be800b8..0df90c34 100644 --- a/world/map/npc/009-2/kfahr.txt +++ b/world/map/npc/009-2/kfahr.txt @@ -369,7 +369,7 @@ L_tale_desert_temple: mes "\"Inside it felt moist, as if it was a real ear-- not that I've climbed inside a real ear, mind you! But that feeling of cool and dampness and water was like a magical healing potion; we suddenly felt strength in our legs again.\""; next; mes "[Kfahr the Warrior]"; - mes "\"When we looked aorund, we noticed that there was a passage leading further underground, and long-spent torches on the wall. Fortunately I still had my tinderbox, so I wrapped my shirt around a torch and lighted it.\""; + mes "\"When we looked around, we noticed that there was a passage leading further underground, and long-spent torches on the wall. Fortunately I still had my tinderbox, so I wrapped my shirt around a torch and lighted it.\""; next; mes "[Kfahr the Warrior]"; mes "\"We climbed down, and soon we heard the dripping of water-- we had found an underground water-hole! More than that, we had found a gigantic underground cave, and, at the end of it, a huge portal.\""; diff --git a/world/map/npc/009-6/brodomir.txt b/world/map/npc/009-6/brodomir.txt index eab5d790..f001efa4 100644 --- a/world/map/npc/009-6/brodomir.txt +++ b/world/map/npc/009-6/brodomir.txt @@ -85,8 +85,6 @@ L_Item: "I changed my mind, forget it.", L_Close; if ($@BRODOMIR_PVP_STATUS == 1) goto L_Wait; - if (getareausers("009-6.gat", 20, 20, 80, 80, 1) < 3) - goto L_NotEnoughPlayers; if (countitem(@brodomir_item$) < @brodomir_item_amount) goto L_NoItem; delitem @brodomir_item$, @brodomir_item_amount; @@ -111,8 +109,6 @@ L_Pay: goto L_TooCheap; if ($@BRODOMIR_PVP_STATUS == 1) goto L_Wait; - if (getareausers("009-6.gat", 20, 20, 80, 80, 1) < 3) - goto L_NotEnoughPlayers; if (Zeny < @brodomir_money) goto L_NotEnoughMoney; set Zeny, Zeny - @brodomir_money; @@ -122,15 +118,17 @@ L_Go: set $@BRODOMIR_ITEM$, @brodomir_item$; set $@BRODOMIR_ITEM_AMOUNT, @brodomir_item_amount; set $@BRODOMIR_MONEY, @brodomir_money; + set $@brodomir_delay_seconds, 600; set $@BRODOMIR_PVP_STATUS, 1; - mapannounce "009-6.gat", "In 5 minutes I will bring you all to the PvP cave. If there are less than 3 players here the event will not start.", 0; + announce "Brodomir: In "+$@brodomir_delay_seconds/60+" minutes, I will start a PvP tournament, if at least 3 fighters are present. Make your way in Hurnscald Underground Caves!", 0; if ($@BRODOMIR_ITEM_AMOUNT > 0) - mapannounce "009-6.gat", "The winner will receive 150GP per player and " + $@BRODOMIR_ITEM_AMOUNT + $@BRODOMIR_ITEM$ + ".", 0; + announce "Brodomir: The winner will receive 150GP per fighter and " + $@BRODOMIR_ITEM_AMOUNT + " " + $@BRODOMIR_ITEM$ + ".", 0; if ($@BRODOMIR_MONEY > 0) - mapannounce "009-6.gat", "The winner will receive " + $@BRODOMIR_MONEY + "GP and additionally 150GP per player.", 0; + announce "Brodomir: The winner will receive " + $@BRODOMIR_MONEY + "GP and additionally 150GP per fighter.", 0; mes "[Brodomir]"; - mes "\"In 5 minutes I will bring you all to the PvP cave. If there are less than 3 players here the event will not start and your money will be lost.\""; - set $@BRODOMIR_START_TIME, gettimetick(2) + 300; + mes "\"In "+$@brodomir_delay_seconds/60+" minutes I will bring you all to the PvP cave. If there are less than 3 players here the event will not start and your money will be lost.\""; + set $@BRODOMIR_START_TIME, gettimetick(2) + $@brodomir_delay_seconds; + set $@brodomir_delay_seconds, 0; initnpctimer; goto L_Close; @@ -141,6 +139,7 @@ L_Wait: mes "\"Just a little longer. I will bring you there in " + $@brodomir_seconds + " seconds.\""; if ($@brodomir_seconds/60 > 0) mes "\"Just a little longer. I will bring you there in " + $@brodomir_seconds/60 + " minute(s).\""; + set $@brodomir_seconds, 0; goto L_Close; OnTimer5000: @@ -157,8 +156,6 @@ L_Warp: set $@BRODOMIR_PVP_STATUS, $@BRODOMIR_PVP_STATUS + 1; set $@BRODOMIR_PLAYERS, getareausers("009-6.gat", 20, 20, 80, 80, 1); mapwarp "009-6.gat", "009-5.gat", 0, 0; - if ($@BRODOMIR_ITEM_AMOUNT > 0) - mapannounce "009-6.gat", "The last one standing will receive 150GP per player and " + $@BRODOMIR_ITEM_AMOUNT + $@BRODOMIR_ITEM$ + ".", 0; mapannounce "009-5.gat", "PvP On!", 0; pvpon "009-5.gat"; end; @@ -201,11 +198,6 @@ L_End: mapwarp "009-5.gat", "009-6.gat", 36, 42; goto L_Cleanup; -L_NotEnoughPlayers: - mes "[Brodomir]"; - mes "\"There aren't enough players here to start.\""; - goto L_Close; - L_Alreadystarted: mes "[Brodomir]"; mes "\"Please wait until the cave is clear again.\""; diff --git a/world/map/npc/011-1/oscar.txt b/world/map/npc/011-1/oscar.txt index 46fe637d..d85bd67b 100644 --- a/world/map/npc/011-1/oscar.txt +++ b/world/map/npc/011-1/oscar.txt @@ -45,6 +45,7 @@ function|script|HalloweenQuestWaterPumpkins|{ goto L_Init; L_AdjustYear: + set Quest_Halloween, 0; set @halloween_year, gettime(7) - 2000; callsub S_Update_Annual_Quest; goto L_Init; diff --git a/world/map/npc/018-1/_mobs.txt b/world/map/npc/018-1/_mobs.txt index 336e823b..334b02bb 100644 --- a/world/map/npc/018-1/_mobs.txt +++ b/world/map/npc/018-1/_mobs.txt @@ -5,7 +5,7 @@ 018-1.gat,108,87,53,25|monster|Log Head|1025,10,100000,30000,Mob018-1::On1025 018-1.gat,116,44,6,7|monster|Sea Slime|1033,3,100000,30000,Mob018-1::On1033 018-1.gat,119,56,13,6|monster|Pink Flower|1014,2,100000,30000,Mob018-1::On1014 -018-1.gat,175,28,17,19|monster|Jack O|1022,1,300000,240000,Mob018-1::On1022 +018-1.gat,175,28,17,19|monster|Jack O|1022,1,180000,120000,Mob018-1::On1022 018-1.gat,78,59,3,1|monster|Yellow Slime|1007,1,100000,30000,Mob018-1::On1007 018-1.gat,57,63,14,7|monster|Silkworm|1035,2,100000,30000,Mob018-1::On1035 018-1.gat,43,63,31,28|monster|Bat|1017,10,100000,30000,Mob018-1::On1017 diff --git a/world/map/npc/021-2/heathin.txt b/world/map/npc/021-2/heathin.txt index acfff47f..526e64e0 100644 --- a/world/map/npc/021-2/heathin.txt +++ b/world/map/npc/021-2/heathin.txt @@ -19,7 +19,7 @@ if (HEATHIN_QUEST == 4) && (BaseLevel >= 80) goto L_Heathin_Terranite_Hood_Ready; if (HEATHIN_QUEST == 3) && (BaseLevel >= 80) goto L_Heathin_Terranite_Hood_Forge; if (HEATHIN_QUEST == 2) && (BaseLevel >= 80) goto L_Heathin_Terranite_Hood; - if (HEATHIN_QUEST == 2) && (BaseLevel >= 60)goto L_Heathin_Ring_Thanks; + if (HEATHIN_QUEST == 2) && (BaseLevel >= 60) goto L_Heathin_Ring_Thanks; if (HEATHIN_QUEST == 1) && (BaseLevel >= 60) goto L_Heathin_Ring_Award; if (BaseLevel >= 60) goto L_Heathin_Start; @@ -69,8 +69,11 @@ L_Heathin_Interested: L_Heathin_Ring_Award: if ( (Zeny < 100000) - | (countitem ("Coal") < 50) ) + || (countitem ("Coal") < 50) ) goto L_Heathin_Ring_Wait; + getinventorylist; + if ((checkweight("SimpleRing", 1) == 0) || (@inventorylist_count == 100)) + goto L_InventoryNoSpace; set HEATHIN_QUEST, 2; set Zeny, Zeny - 100000; delitem "Coal", 50; @@ -132,8 +135,8 @@ L_Heathin_Terranite_Yes: L_Heathin_Terranite_Hood_Forge: if ( (Zeny < 200000) - | (countitem("Coal") < 100) - | (countitem("TerraniteOre") < 10) ) + || (countitem("Coal") < 100) + || (countitem("TerraniteOre") < 10) ) goto L_Heathin_Terranite_Hood_Wait; set HEATHIN_QUEST, 4; delitem "Coal", 100; @@ -149,6 +152,9 @@ L_Heathin_Terranite_Hood_Wait: close; L_Heathin_Terranite_Hood_Ready: + getinventorylist; + if ((checkweight("TerraniteHelmet", 1) == 0) || (@inventorylist_count == 100)) + goto L_InventoryNoSpace; set HEATHIN_QUEST, 5; getitem "TerraniteHelmet", 1; mes "[Heathin]"; @@ -165,8 +171,8 @@ L_Heathin_Terranite_Legs: L_Heathin_Terranite_Legs_Forge: if ( (Zeny < 400000) - | (countitem("Coal") < 200) - | (countitem("TerraniteOre") < 30) ) + || (countitem("Coal") < 200) + || (countitem("TerraniteOre") < 30) ) goto L_Heathin_Terranite_Legs_Wait; set HEATHIN_QUEST, 7; delitem "Coal", 200; @@ -182,6 +188,9 @@ L_Heathin_Terranite_Legs_Wait: close; L_Heathin_Terranite_Legs_Ready: + getinventorylist; + if ((checkweight("TerraniteLegs", 1) == 0) || (@inventorylist_count == 100)) + goto L_InventoryNoSpace; set HEATHIN_QUEST, 8; getitem "TerraniteLegs", 1; mes "[Heathin]"; @@ -198,8 +207,8 @@ L_Heathin_Terranite_Chest_Armor: L_Heathin_Terranite_Chest_Armor_Forge: if ( (Zeny < 500000) - | (countitem("Coal") < 250) - | (countitem("TerraniteOre") < 40) ) + || (countitem("Coal") < 250) + || (countitem("TerraniteOre") < 40) ) goto L_Heathin_Terranite_Chest_Armor_Wait; set HEATHIN_QUEST, 10; delitem "Coal", 250; @@ -215,6 +224,9 @@ L_Heathin_Terranite_Chest_Armor_Wait: close; L_Heathin_Terranite_Chest_Armor_Ready: + getinventorylist; + if ((checkweight("TerraniteChestArmor", 1) == 0) || (@inventorylist_count == 100)) + goto L_InventoryNoSpace; set HEATHIN_QUEST, 11; getitem "TerraniteChestArmor", 1; mes "[Heathin]"; @@ -246,8 +258,8 @@ L_Heathin_Terranite_Arrows_Yes: L_Heathin_Terranite_Arrows_Forge: if ( (Zeny < @TARROW_REQ_GP) - | (countitem("Coal") < @TARROW_REQ_COAL) - | (countitem("TerraniteOre") < @TARROW_REQ_TERRA_ORE) ) + || (countitem("Coal") < @TARROW_REQ_COAL) + || (countitem("TerraniteOre") < @TARROW_REQ_TERRA_ORE) ) goto L_Heathin_Terranite_Arrows_Wait; set HEATHIN_QUEST, 13; delitem "Coal", @TARROW_REQ_COAL; @@ -263,8 +275,11 @@ L_Heathin_Terranite_Arrows_Wait: close; L_Heathin_Terranite_Arrows_Ready: - getitem "TerraniteArrow", 1000; + getinventorylist; + if ((checkweight("TerraniteArrow", 1000) == 0) || (@inventorylist_count == 100)) + goto L_InventoryNoSpace; set HEATHIN_QUEST, 14; + getitem "TerraniteArrow", 1000; mes "[Heathin]"; mes "\"All done, here you go! I hope you like them. I am still working on my commission, but if you ever need any more Terranite Arrows, just come on by with "+@TARROW_REQ_COAL+" Coal, "+@TARROW_REQ_TERRA_ORE+" Terranite Ore and "+@TARROW_REQ_GP+" gold pieces and I will make another 1,000 arrows for you. By now I have enough Terranite Ore in reserve that you can just trade me my requirements to keep my resources up. Thank you for all your efforts!\""; close; @@ -284,9 +299,12 @@ L_Heathin_Terranite_Arrows_Trade_No: L_Heathin_Terranite_Arrows_Trade_Yes: if ( (Zeny < @TARROW_REQ_GP) - | (countitem("Coal") < @TARROW_REQ_COAL) - | (countitem("TerraniteOre") < @TARROW_REQ_TERRA_ORE) ) + || (countitem("Coal") < @TARROW_REQ_COAL) + || (countitem("TerraniteOre") < @TARROW_REQ_TERRA_ORE) ) goto L_Heathin_Terranite_Arrows_Trade_Wait; + getinventorylist; + if ((checkweight("TerraniteArrow", 1500) == 0) || (@inventorylist_count == 100)) + goto L_InventoryNoSpace; delitem "Coal", @TARROW_REQ_COAL; delitem "TerraniteOre", @TARROW_REQ_TERRA_ORE; set Zeny, Zeny - @TARROW_REQ_GP; @@ -300,4 +318,10 @@ L_Heathin_Terranite_Arrows_Trade_Wait: mes "[Heathin]"; mes "\"It seems that you do not have the necessary resources for me to trade you. Please come back with "+@TARROW_REQ_COAL+" Coal, "+@TARROW_REQ_TERRA_ORE+" Terranite Ore and "+@TARROW_REQ_GP+" gold pieces if you want another 1,000 Terranite Arrows.\""; close; + +L_InventoryNoSpace: + mes "[Heathin]"; + mes "\"Hm no. You can't carry this right now. Make some room and come back.\""; + close; + } diff --git a/world/map/npc/029-3/parua.txt b/world/map/npc/029-3/parua.txt index 69507ebd..78014e98 100644 --- a/world/map/npc/029-3/parua.txt +++ b/world/map/npc/029-3/parua.txt @@ -166,11 +166,8 @@ L_NextRound: goto L_CleanUp; set $@FIGHT_CAVE_POINTS, $@FIGHT_CAVE_LEVEL; - if ($@FIGHT_CAVE_LAST + 30 < $@FIGHT_CAVE_LEVEL) - goto L_Announce; - -L_Return_2: - mapannounce "029-3.gat", "Parua: The next round (level " + $@FIGHT_CAVE_LEVEL + ") is starting with " + $@FIGHT_CAVE_PLAYER_COUNT + " player(s) left alive." , 0; + mapannounce "029-1.gat", "Parua: The next round (level " + $@FIGHT_CAVE_LEVEL + ") is starting with " + $@FIGHT_CAVE_PLAYER_COUNT + " player(s) left alive." , 0; + mapannounce "029-3.gat", "Parua: The next round (level " + $@FIGHT_CAVE_LEVEL + ") is starting with " + $@FIGHT_CAVE_PLAYER_COUNT + " player(s) left alive." , 0; set $@MOB_1_SUMMON, 0; set $@MOB_2_SUMMON, 0; @@ -200,11 +197,6 @@ L_Summon: goto L_MOB6; goto L_Return_1; -L_Announce: - mapannounce "029-1.gat", "Parua: The next round (level " + $@FIGHT_CAVE_LEVEL + ") is starting with " + $@FIGHT_CAVE_PLAYER_COUNT + " player(s) left alive." , 0; - set $@FIGHT_CAVE_LAST, $@FIGHT_CAVE_LAST + 30; - goto L_Return_2; - L_GlobalAnnounce: if ($@FIGHT_CAVE_STATUS == 3) goto L_Five_Minutes; diff --git a/world/map/npc/031-4/cindyCave.txt b/world/map/npc/031-4/cindyCave.txt index 6e6e143b..c724733a 100644 --- a/world/map/npc/031-4/cindyCave.txt +++ b/world/map/npc/031-4/cindyCave.txt @@ -54,18 +54,15 @@ L_Try_Cage: mes "As you try to open the door of the cage, there is a loud squeaking noise."; next; mes "You get an uncomfortable feeling and Cindy starts to shiver."; - next; - mes "\"Oh no, the Yetis...\""; if ($@FIGHT_YETI_STATUS != 0) goto L_Yeti; + npctalk "Oh no, the Yetis..."; // initialize fight set $@FIGHT_YETI_STATUS, 1; set $@FIGHT_YETI_WAVE, 0; set $@YETI_COUNT, 1; set $@FIGHT_YETI_PLAYER_COUNT, getmapusers("031-4.gat"); - // this yeti is spawned because of some timing problems - // without it, the first and second wave start nearly the same time areamonster "031-4.gat", 0, 0, 95, 91, "", 1072, 1, "Cindy::onPetDeath"; initnpctimer; @@ -154,7 +151,7 @@ L_CaveLogic: if ($@FIGHT_YETI_PLAYER_COUNT <= 0) goto L_CleanUp; set $@FIGHT_YETI_ROUND_TIMER, $@FIGHT_YETI_ROUND_TIMER + 5; // Advance 5 seconds - if (mobcount("031-4.gat", "Cindy::onPetDeath") <= 0) + if (mobcount("031-4.gat", "Cindy::onPetDeath") < 0) goto L_NextWave; if ($@FIGHT_YETI_ROUND_TIMER + $@FIGHT_YETI_ROUND_PEN >= 120) goto L_NextWave; @@ -173,7 +170,7 @@ L_NextWave: areamonster "031-4.gat", 0, 0, 95, 91, "", 1072, $@FIGHT_YETI_WAVE*2 + $@FIGHT_YETI_PLAYER_COUNT*5, "Cindy::onPetDeath"; if ($@FIGHT_YETI_WAVE > 22) set $@YETI_COUNT, $@YETI_COUNT + $@FIGHT_YETI_WAVE*2 + $@FIGHT_YETI_PLAYER_COUNT*5; - set $@FIGHT_YETI_NUMBER, (1 + (1 * $@FIGHT_YETI_WAVE) + (2 * $@FIGHT_YETI_PLAYER_COUNT))/4; + set $@FIGHT_YETI_NUMBER, (5 + (1 * $@FIGHT_YETI_WAVE) + (2 * $@FIGHT_YETI_PLAYER_COUNT))/4; set $@YETI_COUNT, $@YETI_COUNT + $@FIGHT_YETI_NUMBER; areamonster "031-4.gat", 0, 0, 95, 91, "", 1072, $@FIGHT_YETI_NUMBER, "Cindy::onPetDeath"; @@ -236,7 +233,7 @@ L_CleanUp: areatimer "031-4.gat", 0, 0, 95, 91, 10, "Cindy::onReward"; set $@FIGHT_YETI_STATUS, 0; set $@FIGHT_YETI_PLAYER_COUNT, 0; - set $@FIGHT_YETI_WAVE, 1; + set $@FIGHT_YETI_WAVE, 0; set $@FIGHT_YETI_ROUND_TIMER, 0; set $@YETI_COUNT, 0; set $@FIGHT_YETI_ROUND_PEN, 0; diff --git a/world/map/npc/052-2/chest.txt b/world/map/npc/052-2/chest.txt index 41366e4d..d42cea48 100644 --- a/world/map/npc/052-2/chest.txt +++ b/world/map/npc/052-2/chest.txt @@ -92,7 +92,7 @@ L_GetUniqueReward2: next; mes "You find a bunch of gold pieces!"; next; - set Zeny, Zeny + 150000*($@illia_num_unique_reward_items - @illia_current_num_rewards); + set Zeny, Zeny + 100000*($@illia_num_unique_reward_items - @illia_current_num_rewards); getexp 200000*($@illia_num_unique_reward_items - @illia_current_num_rewards), 0; set @illia_current_num_rewards, $@illia_num_unique_reward_items; goto L_GetUniqueReward; @@ -151,7 +151,7 @@ onMsg1: end; onMsg2: - message strcharinfo(0), "Who is Luvia? Something isn't alright... It looks like your memory is rewritten."; + message strcharinfo(0), "Who is Luvia? Something isn't right... It looks like your memory is rewritten."; end; onMsg3: diff --git a/world/map/npc/052-2/lobby.txt b/world/map/npc/052-2/lobby.txt index 6eb56e72..b50a0273 100644 --- a/world/map/npc/052-2/lobby.txt +++ b/world/map/npc/052-2/lobby.txt @@ -174,9 +174,9 @@ L_TalkToHelper: close; L_TalkToHero: - set $@illia_level_5_progress, 4; menu "Are you Luvia? Your sister Valia sent me to save you! Where is Ismuth?", -; + set $@illia_level_5_progress, 4; initnpctimer; close; diff --git a/world/map/npc/052-2/partyroom.txt b/world/map/npc/052-2/partyroom.txt index e0a3aab7..6e16eb88 100644 --- a/world/map/npc/052-2/partyroom.txt +++ b/world/map/npc/052-2/partyroom.txt @@ -219,11 +219,11 @@ onDeath: callfunc "UpdateIlliaProgress"; // Set the number of common rewards rewards if ($Illia_Luvia_Harvest < 15) - set $@illia_num_common_reward_items, 3; + set $@illia_num_common_reward_items, 0; if ($Illia_Luvia_Harvest >= 15 && $Illia_Luvia_Harvest < 35) - set $@illia_num_common_reward_items, 5; + set $@illia_num_common_reward_items, 1; if ($Illia_Luvia_Harvest >= 35) - set $@illia_num_common_reward_items, 8; + set $@illia_num_common_reward_items, 2; // Set the number of unique rewards if ($Illia_Luvia_Harvest < 40) diff --git a/world/map/npc/functions/clear_vars.txt b/world/map/npc/functions/clear_vars.txt index 48002fa4..6cc311fe 100644 --- a/world/map/npc/functions/clear_vars.txt +++ b/world/map/npc/functions/clear_vars.txt @@ -133,6 +133,13 @@ function|script|ClearVariables|{ set QUEST_Hurnscald, (QUEST_Hurnscald & ~(NIBBLE_2_MASK)) | (QUEST_demon_mines << NIBBLE_2_SHIFT); set QUEST_demon_mines, 0; + // move Inspector quest into bitmasked variable QUEST_Hurnscald + set @inspector, ((QUEST_Hurnscald & NIBBLE_3_MASK) >> NIBBLE_3_SHIFT); + if (Inspector > @inspector) + set QUEST_Hurnscald, (QUEST_Hurnscald & ~(NIBBLE_3_MASK)) | (Inspector << NIBBLE_3_SHIFT); + set Inspector, 0; + set @inspector, 0; + //These lines are needed to migrate stuff from variables to flags if (Open_Underground_Palace_Barrier) set FLAGS, FLAGS | FLAG_OPENED_UNDERGROUND; diff --git a/world/map/npc/items/magic_gm_top_hat.txt b/world/map/npc/items/magic_gm_top_hat.txt new file mode 100644 index 00000000..cd9a0302 --- /dev/null +++ b/world/map/npc/items/magic_gm_top_hat.txt @@ -0,0 +1,17 @@ +function|script|ActivateMagicGMTophat|{ + if (getgmlevel() < 60) return; + getinventorylist; + if ((checkweight("MurdererCrown", 1) == 0) || (@inventorylist_count == 100)) + goto L_Inventory; + // Get the current reward of the event. This may be changed later + getitem "MurdererCrown", 1; + // Display an effect + misceffect FX_CHANNELLING_CAST, strcharinfo(0); + // Log the usage of this spell + gmcommand "@l "+strcharinfo(0)+" used the Magic GM Top Hat."; + return; + +L_Inventory: + message strcharinfo(0), "You cannot create this item. You're too heavy or you don't have a free slot."; + return; +} diff --git a/world/map/npc/items/require_stat.txt b/world/map/npc/items/require_stat.txt index e1d6306f..87fd9d72 100644 --- a/world/map/npc/items/require_stat.txt +++ b/world/map/npc/items/require_stat.txt @@ -21,7 +21,7 @@ function|script|RequireStat|{ if (@bStat$ == "Luk") set @bStatVal, readParam(bLuk); if (@bStatVal >= @minbStatVal) return; - message strcharinfo(0), "You do not see how to use this item properly."; - unequipbyid @slotId; + // If the requirement isn't met, then we end the script. + // Hence, subsequent item modifiers won't be applied. end; } diff --git a/world/map/npc/scripts.conf b/world/map/npc/scripts.conf index 48712aca..26a0b0b4 100644 --- a/world/map/npc/scripts.conf +++ b/world/map/npc/scripts.conf @@ -21,6 +21,7 @@ npc: npc/functions/debug.txt npc: npc/functions/lockpicking.txt // Item Functions +npc: npc/items/magic_gm_top_hat.txt npc: npc/items/purification_potion.txt npc: npc/items/scissors.txt npc: npc/items/shock_sweet.txt diff --git a/world/map/save/.gitignore b/world/map/save/.gitignore index 11d10d30..cab39708 100644 --- a/world/map/save/.gitignore +++ b/world/map/save/.gitignore @@ -1 +1 @@ -/mapreg.txt +/mapreg.txt* diff --git a/world/save/.gitignore b/world/save/.gitignore index bc445803..c18b27af 100644 --- a/world/save/.gitignore +++ b/world/save/.gitignore @@ -1,7 +1,7 @@ -/athena.txt -/accreg.txt -/party.txt -/storage.txt -/guild.txt -/castle.txt -/g_storage.txt +/athena.txt* +/accreg.txt* +/party.txt* +/storage.txt* +/guild.txt* +/castle.txt* +/g_storage.txt* |