summaryrefslogtreecommitdiff
path: root/npc/012-1_Woodland_Hills
diff options
context:
space:
mode:
authorJared Adams <jaxad0127@gmail.com>2009-01-25 14:47:52 +0000
committerJared Adams <jaxad0127@gmail.com>2009-01-25 14:47:52 +0000
commit4b353e978cccec57dc4bc1a065c86642dd6d936d (patch)
treecf2fbe87bd2067344ab22cca66a1e87ba60b666e /npc/012-1_Woodland_Hills
parentbb7285c15066499c68f7d56cdc97020559058ccc (diff)
downloadserverdata-4b353e978cccec57dc4bc1a065c86642dd6d936d.tar.gz
serverdata-4b353e978cccec57dc4bc1a065c86642dd6d936d.tar.bz2
serverdata-4b353e978cccec57dc4bc1a065c86642dd6d936d.tar.xz
serverdata-4b353e978cccec57dc4bc1a065c86642dd6d936d.zip
Fix bugs in the injured mouboo's script
Diffstat (limited to 'npc/012-1_Woodland_Hills')
-rw-r--r--npc/012-1_Woodland_Hills/injured-mouboo.txt42
1 files changed, 20 insertions, 22 deletions
diff --git a/npc/012-1_Woodland_Hills/injured-mouboo.txt b/npc/012-1_Woodland_Hills/injured-mouboo.txt
index 0c32aaf3..efa68ad5 100644
--- a/npc/012-1_Woodland_Hills/injured-mouboo.txt
+++ b/npc/012-1_Woodland_Hills/injured-mouboo.txt
@@ -102,9 +102,9 @@ L_give:
setarray @items$, "CactusDrink", "CactusPotion", "ChocolateBar", "Milk", "OrangeCupcake", "Apple", "Beer", "BottleOfWater", "TinyHealingPotion", "SmallHealingPotion", "MediumHealingPotion", "LargeHealingPotion";
setarray @itemeat, 0, 0, 1, 0, 1, 1, 0, 1, 0, 0, 0, 0;
- setarray @choice$, "", "", "", "", "", "", "", "", "", "", "", "";
+ setarray @menuItems$, "", "", "", "", "", "", "", "", "", "", "", "";
set @choices_nr, 0;
- setarray @choice_idx, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0;
+ setarray @menuNames$, "", "", "", "", "", "", "", "", "", "", "", "";
setarray @choice_eat, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0;
set @n, 0;
@@ -114,9 +114,9 @@ L_nloop:
if (countitem(@k$) == 0)
goto L_nloop_skip;
- set @name$, getitemname(@k);
- set @choice$[@ct], @name$;
- set @choice_idx$[@ct], @k$;
+ set @name$, getitemname(@k$);
+ set @menuItems$[@ct], @name$;
+ set @menuNames$[@ct], @k$;
set @choice_eat[@ct], @itemeat[@n];
set @ct, @ct + 1;
@@ -126,34 +126,32 @@ L_nloop_skip:
if (@n < @items_nr)
goto L_nloop;
- menu @choice$[0], -,
- @choice$[1], -,
- @choice$[2], -,
- @choice$[3], -,
- @choice$[4], -,
- @choice$[5], -,
- @choice$[6], -,
- @choice$[7], -,
- @choice$[8], -,
- @choice$[9], -,
- @choice$[10], -,
- @choice$[11], -;
+ menu @menuItems$[0], -,
+ @menuItems$[1], -,
+ @menuItems$[2], -,
+ @menuItems$[3], -,
+ @menuItems$[4], -,
+ @menuItems$[5], -,
+ @menuItems$[6], -,
+ @menuItems$[7], -,
+ @menuItems$[8], -,
+ @menuItems$[9], -,
+ @menuItems$[10], -,
+ @menuItems$[11], -;
set @menu, @menu - 1;
- set @choice$, @choice_idx[@menu];
- set @choice_e, @choice_eat[@menu];
+ set @choice$, @menuNames$[@menu];
set @verb$, "drinks";
- if (@choice_e)
+ if (@choice_eat[@menu])
set @verb$, "eats";
- if (@choice$ && countitem(@choice$))
+ if (@choice$ != "" && countitem(@choice$))
goto L_consume;
goto L_menu;
L_consume:
mes "[Injured Mouboo]";
-
mes "The mouboo " + @verb$ + " your " + getitemname(@choice$) + ".";
delitem @choice$, 1;
next;