From b1ced66321ffed02cde1a9ccd39fa2c9ba004125 Mon Sep 17 00:00:00 2001 From: Jared Adams Date: Tue, 23 Dec 2008 17:16:49 +0000 Subject: Fixeds to check for invy room before giving items --- npc/009-2_Hurnscald/nicholas.txt | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) (limited to 'npc/009-2_Hurnscald/nicholas.txt') 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.\""; } -- cgit v1.2.3-70-g09d2