summaryrefslogtreecommitdiff
path: root/npc/009-2_Hurnscald
diff options
context:
space:
mode:
authorJared Adams <jaxad0127@gmail.com>2008-12-23 17:16:49 +0000
committerJared Adams <jaxad0127@gmail.com>2008-12-23 17:18:37 +0000
commitb1ced66321ffed02cde1a9ccd39fa2c9ba004125 (patch)
tree87b2f8639b8e1b79125ebdd77f71d19305d0084c /npc/009-2_Hurnscald
parent2ac5f8a1dfa5482dc1fee2bbd41b5e0eb0928abd (diff)
downloadserverdata-b1ced66321ffed02cde1a9ccd39fa2c9ba004125.tar.gz
serverdata-b1ced66321ffed02cde1a9ccd39fa2c9ba004125.tar.bz2
serverdata-b1ced66321ffed02cde1a9ccd39fa2c9ba004125.tar.xz
serverdata-b1ced66321ffed02cde1a9ccd39fa2c9ba004125.zip
Fixeds to check for invy room before giving items
Diffstat (limited to 'npc/009-2_Hurnscald')
-rw-r--r--npc/009-2_Hurnscald/alan.txt7
-rw-r--r--npc/009-2_Hurnscald/kfahr.txt40
-rw-r--r--npc/009-2_Hurnscald/nicholas.txt16
-rw-r--r--npc/009-2_Hurnscald/waitress.txt10
4 files changed, 69 insertions, 4 deletions
diff --git a/npc/009-2_Hurnscald/alan.txt b/npc/009-2_Hurnscald/alan.txt
index 0235ad33..6d8a1770 100644
--- a/npc/009-2_Hurnscald/alan.txt
+++ b/npc/009-2_Hurnscald/alan.txt
@@ -174,6 +174,8 @@ L_State_4:
L_State_4_pay:
if (zeny < 10000) goto L_State_4_nocash;
+ getinventorylist;
+ if (@inventorylist_count == 100) goto L_State_4_TooMany;
set zeny, zeny - 10000;
getitem 545, 1;
set @Q_status, 5;
@@ -187,6 +189,11 @@ L_State_4_nocash:
mes "\"Seems like you are out of cash.\"";
close;
+L_State_4_TooMany:
+ mes "[Alan]";
+ mes "\"Seems like you don't have room for this bow. Come back later.\"";
+ close;
+
L_State_5:
mes "[Alan]";
mes "\"I hope you are statisfied with your forest bow. It is one of my best works.\"";
diff --git a/npc/009-2_Hurnscald/kfahr.txt b/npc/009-2_Hurnscald/kfahr.txt
index cd5bc3b7..5d847ea0 100644
--- a/npc/009-2_Hurnscald/kfahr.txt
+++ b/npc/009-2_Hurnscald/kfahr.txt
@@ -810,12 +810,19 @@ L_knife_quest_completecheck:
mes "I had the nomads make me a few of them, and I hardly use them nowadays, so I think I can part with this one.";
next;
+ if (countitem(@BLACK_STINGER) < @BLACK_STINGERS_NR)
+ goto L_knife_quest_missing_stingers_2;
+
+ if (countitem(@MUSHROOM) < @MUSHROOMS_NR)
+ goto L_knife_quest_missing_mushrooms_2;
+ getinventorylist;
+ if (@inventorylist_count == 100) goto L_Knife_TooMany;
+
mes "[Kfahr the Warrior]";
mes "He hands you the knife.";
mes "\"Oh, and I think I'll keep those in return; I know someone who will trade them for antidote potions.\"";
mes "He pockets the stingers and mushrooms.";
mes "[" + @KNIFE_QUEST_XP + " experience points]";
- next;
set @Q_status, @QS_KNIFE_QUEST_DONE;
callsub L_Update_Var;
@@ -828,6 +835,11 @@ L_knife_quest_completecheck:
goto L_main_menu;
+L_Knife_TooMany:
+ mes "[Kfahr the Warrior]";
+ mes "\"You don't have room for this. Come back when you do.\"";
+ close;
+
L_knife_quest_missing_stingers:
mes "[Kfahr the Warrior]";
mes "\"No, no... I said " + @BLACK_STINGERS_NR + " black scorpion stingers.";
@@ -838,6 +850,16 @@ L_knife_quest_missing_stingers:
next;
close;
+L_knife_quest_missing_stingers_2:
+ mes "[Kfahr the Warrior]";
+ mes "\"You just had " + @BLACK_STINGERS_NR + " black scorpion stingers. What happened to them?";
+ if (countitem(@BLACK_STINGER))
+ mes "You will need " + (@BLACK_STINGERS_NR - (countitem (@BLACK_STINGER))) + " more of those.\"";
+ if (countitem(@BLACK_STINGER) == 0)
+ mes "You didn't bring even a single one!\"";
+ next;
+ close;
+
L_knife_quest_missing_mushrooms:
mes "[Kfahr the Warrior]";
mes "\"No, no... I said " + @MUSHROOMS_NR + " small mushrooms.";
@@ -848,6 +870,16 @@ L_knife_quest_missing_mushrooms:
next;
close;
+L_knife_quest_missing_mushrooms_2:
+ mes "[Kfahr the Warrior]";
+ mes "\"You just had " + @MUSHROOMS_NR + " small mushrooms. What happened to them?";
+ if (countitem(@MUSHROOM))
+ mes "You will need " + (@MUSHROOMS_NR - (countitem (@MUSHROOM))) + " more of those.\"";
+ if (countitem(@MUSHROOM) == 0)
+ mes "You didn't bring me even a single little mushroom!\"";
+ next;
+ close;
+
L_stinger_quest_check:
mes "[Kfahr the Warrior]";
mes "Kfahr grins at you.";
@@ -863,6 +895,8 @@ L_stinger_quest_check:
L_snakeskins_completecheck:
if (countitem(@SNAKE_SKIN) < @SNAKE_SKINS_NR)
goto L_snakeskins_missing;
+ getinventorylist;
+ if (@inventorylist_count == 100) goto L_SnakeSkins_TooMany;
delitem @SNAKE_SKIN, @SNAKE_SKINS_NR;
getitem @GOLDEN_STINGER, 1;
@@ -890,6 +924,10 @@ L_snakeskins_missing:
next;
close;
+L_SnakeSkins_TooMany:
+ mes "[Kfahr the Warrior]";
+ mes "\"YOu don't have room for this. Come back when you do.\"";
+ close;
L_give_beer:
if (countitem(@BEER) < 1)
diff --git a/npc/009-2_Hurnscald/nicholas.txt b/npc/009-2_Hurnscald/nicholas.txt
index 30d48594..3962bee0 100644
--- a/npc/009-2_Hurnscald/nicholas.txt
+++ b/npc/009-2_Hurnscald/nicholas.txt
@@ -189,13 +189,17 @@ L_NoMoney:
L_YesKnight:
if (zeny < 10000) goto L_NoMoney;
- set zeny, zeny-10000;
- delitem @IRON_ORE,5;
- getitem 637,1;
+ getinventorylist;
+ if (@inventorylist_count == 100) goto L_TooMany;
+ set zeny, zeny - 10000;
+ delitem @IRON_ORE, 5;
+ getitem 637, 1;
goto L_Done;
L_YesCrusade:
if (zeny < 10000) goto L_NoMoney;
+ getinventorylist;
+ if (@inventorylist_count == 100) goto L_TooMany;
set zeny, zeny-10000;
delitem @IRON_ORE,10;
getitem 639,1;
@@ -203,6 +207,8 @@ L_YesCrusade:
L_YesWarlord:
if (zeny < 10000) goto L_NoMoney;
+ getinventorylist;
+ if (@inventorylist_count == 100) goto L_TooMany;
set zeny, zeny-10000;
delitem @IRON_ORE,15;
getitem 636,1;
@@ -401,4 +407,8 @@ L_Update_Var:
| (@Q_SHIELD_status << @Q_SHIELD_SHIFT)
| (@Q_SETZER_status << @Q_SETZER_SHIFT));
return;
+
+L_TooMany:
+ mes "[Nicholas]";
+ mes "\"You don't have room for it. Come back later when you do.\"";
}
diff --git a/npc/009-2_Hurnscald/waitress.txt b/npc/009-2_Hurnscald/waitress.txt
index cf2778fd..bcf2f434 100644
--- a/npc/009-2_Hurnscald/waitress.txt
+++ b/npc/009-2_Hurnscald/waitress.txt
@@ -2,6 +2,10 @@
009-2.gat,60,52,0 script Melinda 140,{
if (zeny < 180) goto L_NoMoney;
+ getinventorylist;
+ set @beerCount, countitem(539);
+ if (@inventorylist_count == 100 && beerCount < 0) goto L_TooMany;
+
mes "[Melinda]";
mes "\"Hi sweety! Want a fresh beer for 170gp?\"";
next;
@@ -46,6 +50,12 @@ L_No:
close;
L_NoMoney:
+ mes "[Melinda]";
mes "\"You look broke. Don't think that you can dine and dash here!\"";
close;
+
+L_TooMany:
+ mes "[Melinda]";
+ mes "\"You don't have room for a beer!\"";
+ close;
}