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/001-1_Tulimshar/guide.txt | 17 ++++--- npc/001-1_Tulimshar/sandra.txt | 107 +++++++++++++++++++++++----------------- npc/001-1_Tulimshar/vincent.txt | 37 +++++++------- 3 files changed, 92 insertions(+), 69 deletions(-) (limited to 'npc/001-1_Tulimshar') diff --git a/npc/001-1_Tulimshar/guide.txt b/npc/001-1_Tulimshar/guide.txt index 1efc79fe..d4367616 100644 --- a/npc/001-1_Tulimshar/guide.txt +++ b/npc/001-1_Tulimshar/guide.txt @@ -140,12 +140,7 @@ L_Key: L_Laws: mes "[Ian the Guide]"; - mes "\"Lady Platyna, the Overseer, has decreed the following rules:"; - mes "1. Do not abuse others (insult, swear etc.)"; - mes "2. No bots."; - mes "3. No spamming/flooding."; - mes "4. No begging."; - mes "5. Speak English."; + mes "\"The constable can help you with them.\""; next; goto L_Menu_A; @@ -153,12 +148,20 @@ L_Know: close; S_Grad: + getinventorylist; + if (@inventorylist_count == 100) goto L_TooMany; mes "[Ian the Guide]"; mes "\"Hey, you've been doing good, let me give you this.\""; - next; getitem 675, 1; set TUT_var, TUT_var | 2; + next; + + return; +L_TooMany: + mes "[Ian the Guide]"; + mes "\"I wanted to give you something, but you don't have room for it.\""; + next; return; } diff --git a/npc/001-1_Tulimshar/sandra.txt b/npc/001-1_Tulimshar/sandra.txt index eb1ebdf0..048bfa19 100644 --- a/npc/001-1_Tulimshar/sandra.txt +++ b/npc/001-1_Tulimshar/sandra.txt @@ -1,83 +1,102 @@ // 001-1.gat,110,71,0 script Sandra 114,{ - if(Scorp == 2) goto done; - if(Scorp == 1) goto reas; + if(Scorp == 2) goto L_Done; + if(Scorp == 1) goto L_Progress; + set @TEMP,rand(3); - if(@TEMP == 1) goto L_1; - if(@TEMP == 2) goto L_2; - if(@TEMP == 3) goto L_3; - if(@TEMP == 0) goto L_4; -L_1: + if(@TEMP == 1) goto L_Opening1; + if(@TEMP == 2) goto L_Opening2; + if(@TEMP == 3) goto L_Opening3; + if(@TEMP == 0) goto L_Opening4; + +L_Opening1: mes "[Sandra]"; - mes "\"In the outskirts of Tulimshar, there wanders a red scorpion. I need a favor, please help me.\""; + mes "\"In the outskirts of Tulimshar, there wanders a red scorpion. I need a favor, please help me. Will you?\""; next; - goto red; -L_2: + goto L_Ask; + +L_Opening2: mes "[Sandra]"; mes "\"When you venture in the outskirts of Tulimshar, you can spot a red scorpion. Will you help me kill one?\""; next; - goto red; -L_3: + goto L_Ask; + +L_Opening3: mes "[Sandra]"; - mes "\"The red scorpion stinger carries many properties used in potions.\""; + mes "\"The red scorpion stinger carries many properties used in potions. Will you get some for me?\""; next; - goto red; -L_4: + goto L_Ask; + +L_Opening4: mes "[Sandra]"; mes "\"You look sturdy enough, will you help me get something?\""; next; - goto red; -red: - menu "Yes",L_kl,"No",L_N; -L_kl: - if(@TEMP == 1) goto K_1; - if(@TEMP == 2) goto K_2; - if(@TEMP == 3) goto K_3; - if(@TEMP == 0) goto K_1; -K_1: + goto L_Ask; + +L_Ask: + menu + "Yes", L_Yes, + "No", L_No; + +L_Yes: + if(@TEMP == 1) goto L_Req1; + if(@TEMP == 2) goto L_Req2; + if(@TEMP == 3) goto L_Req3; + if(@TEMP == 0) goto L_Req1; + +L_Req1: mes "[Sandra]"; mes "\"I need you to slaughter the red scorpion found outside of Tulimshar and bring me 5 [Red Stingers].\""; next; - goto set1; -K_2: + goto L_Set; + +L_Req2: mes "[Sandra]"; mes "\"I heard a while ago that the stinger of a red scorpion can be used for medical purposes. I need you to help me get 5 [Red Stingers].\""; next; - goto set1; -K_3: + goto L_Set; + +L_Req3: mes "[Sandra]"; mes "\"Bring me 5 [Red Stingers] and i will reward you greatly.\""; next; - goto set1; -set1: + goto L_Set; + +L_Set: set Scorp,1; mes "[Sandra]"; mes "\"Please bring me them!\""; close; -reas: - if(countitem(517) >= 5) goto have; + +L_Progress: + if (countitem(517) >= 5) goto L_Have; mes "[Sandra]"; mes "\"Please hurry and bring me 5 [Red Stingers].\""; close; -have: + +L_Have: mes "[Sandra]"; mes "\"Excellent!"; mes "You brought me 5 [Red Stingers]!\""; - delitem 517,5; - next; - mes "[Sandra]"; - mes "\"Here you go, your reward!\""; - mes "+Got Bow"; - mes "+Got Arrows 100"; - getitem 1200,1; - getitem 1199,100; - set Scorp,2; + getinventorylist; + if (@inventorylist_count == 100 && countitem(517) > 5) goto L_TooMany; + delitem 517, 5; + getitem 1200, 1; + getitem 1199, 100; + set Scorp, 2; close; -done: + +L_Done: mes "[Sandra]"; mes "\"Thank you for all your help!\""; close; -L_N: + +L_No: close; + +L_TooMany: + next; + mes "[Sandra]"; + mes "\"You don't have room for my reward. I'll wait until you do.\""; } diff --git a/npc/001-1_Tulimshar/vincent.txt b/npc/001-1_Tulimshar/vincent.txt index ef17ba18..b0412517 100644 --- a/npc/001-1_Tulimshar/vincent.txt +++ b/npc/001-1_Tulimshar/vincent.txt @@ -1,32 +1,33 @@ // 001-1.gat,135,42,0 script Vincent 113,{ - if(Bugleg == 1) goto L_Reas; if(Bugleg == 2) goto L_Done; + if(Bugleg == 1) goto L_Progress; + set @TEMP, rand(4); - if(@TEMP == 0) goto L_1; - if(@TEMP == 1) goto L_2; - if(@TEMP == 2) goto L_3; - if(@TEMP == 3) goto L_4; + if(@TEMP == 0) goto L_Opening1; + if(@TEMP == 1) goto L_Opening2; + if(@TEMP == 2) goto L_Opening3; + if(@TEMP == 3) goto L_Opening4; -L_1: +L_Opening1: mes "[Vincent]"; mes "\"I just need 30 more [Bug Legs] to finish my action figure!\""; next; goto L_Ask; -L_2: +L_Opening2: mes "[Vincent]"; mes "\"This maggot action figure is awesome! I just need to attach [30 Part A{Bug Leg}]\""; next; goto L_Ask; -L_3: +L_Opening3: mes "[Vincent]"; mes "\"This is a great action figure! A must have! All I need is a few parts...\""; goto L_Ask; -L_4: +L_Opening4: mes "[Vincent]"; mes "\"Can you get me 30 [Bug Legs]? I need them to replace the action figure parts.\""; next; @@ -44,30 +45,30 @@ L_Ask: L_Sure: set Bugleg, 1; set @TEMP,rand(4); - if(@TEMP == 0) goto J_1; - if(@TEMP == 1) goto J_2; - if(@TEMP == 2) goto J_3; - if(@TEMP == 3) goto J_4; + if(@TEMP == 0) goto L_Req1; + if(@TEMP == 1) goto L_Req2; + if(@TEMP == 2) goto L_Req3; + if(@TEMP == 3) goto L_Req4; -J_1: +L_Req1: mes "[Vincent]"; mes "\"Thank you!\""; next; goto L_Wait; -J_2: +L_Req2: mes "[Vincent]"; mes "\"I don't know how to thank you enough!\""; next; goto L_Wait; -J_3: +L_Req3: mes "[Vincent]"; mes "\"I will thank you when I get them!\""; next; goto L_Wait; -J_4: +L_Req4: mes "[Vincent]"; mes "\"I'm sure I will give a small reward. :D\""; next; @@ -78,7 +79,7 @@ L_Wait: mes "\"Now please go get me 30 [Bug Legs]\""; close; -L_Reas: +L_Progress: if(countitem(518) >= 30) goto L_Have; mes "[Vincent]"; mes "\"Please help me collect 30 [Bug Legs]!\""; -- cgit v1.2.3-70-g09d2