summaryrefslogtreecommitdiff
path: root/npc/031-3_Cave
diff options
context:
space:
mode:
authorJessica Tölke <jtoelke@mail.upb.de>2010-12-29 21:20:39 +0100
committerJessica Tölke <jtoelke@mail.upb.de>2010-12-29 21:20:39 +0100
commitc884add9efd2a76072a0be64c6c84c73dc0bb2bc (patch)
tree80549fa09463a90f789f482cd72ceac8be46538d /npc/031-3_Cave
parentd029a77cc27e27caa18a5cbd1015e4bdeac971d2 (diff)
downloadserverdata-c884add9efd2a76072a0be64c6c84c73dc0bb2bc.tar.gz
serverdata-c884add9efd2a76072a0be64c6c84c73dc0bb2bc.tar.bz2
serverdata-c884add9efd2a76072a0be64c6c84c73dc0bb2bc.tar.xz
serverdata-c884add9efd2a76072a0be64c6c84c73dc0bb2bc.zip
Rescue Cindy quest
works, except: rewards, yeti battle, npc sprites
Diffstat (limited to 'npc/031-3_Cave')
-rw-r--r--npc/031-3_Cave/_import.txt1
-rw-r--r--npc/031-3_Cave/cindyCave.txt123
2 files changed, 124 insertions, 0 deletions
diff --git a/npc/031-3_Cave/_import.txt b/npc/031-3_Cave/_import.txt
index d28ddba7..1f56c50d 100644
--- a/npc/031-3_Cave/_import.txt
+++ b/npc/031-3_Cave/_import.txt
@@ -2,3 +2,4 @@ map: 031-3.gat
npc: npc/031-3_Cave/_mobs.txt
npc: npc/031-3_Cave/_warps.txt
npc: npc/031-3_Cave/labyrinth.txt
+npc: npc/031-3_Cave/cindyCave.txt
diff --git a/npc/031-3_Cave/cindyCave.txt b/npc/031-3_Cave/cindyCave.txt
new file mode 100644
index 00000000..738868d6
--- /dev/null
+++ b/npc/031-3_Cave/cindyCave.txt
@@ -0,0 +1,123 @@
+// author: Jenalya
+// reviewed by:
+// state0: Cindy is totally scared and does nothing helpful
+// state1: you are able to open the cage
+// state2 and greater: Cindy is saved, she asks you to visit them
+//
+
+//TODO: picture
+031-3.gat,122,51,0 script Cindy 114, {
+ set @KEYS_AMOUNT, 10;
+
+ set @Q_Nivalis_state_MASK, NIBBLE_5_MASK;
+ set @Q_Nivalis_state_SHIFT, NIBBLE_5_SHIFT;
+
+ set @rescue_Cindy, ((QUEST_Nivalis_state & @Q_Nivalis_state_MASK) >> @Q_Nivalis_state_SHIFT);
+
+ if (Sex == 0) set @title$, "Misses";
+ if (Sex == 1) set @title$, "Mister";
+
+ if (@rescue_Cindy >= 3) goto L_Please_Visit;
+ if (@rescue_Cindy == 2) goto L_Reward;
+ if (@rescue_Cindy == 1) goto L_Please_Help;
+
+ mes "There is a little girl in a cage. As you come near, she starts to shiver and back off from you as far as she can in that small cage.";
+ next;
+ mes "You don't know, what to do.";
+ close;
+
+L_Please_Help:
+ mes "There is a little girl in a cage. As you come near, she starts to shiver and back off from you as far as she can in that small cage.";
+ next;
+ menu
+ "Hello Cindy, I'm here to save you.", - ;
+ mes "Cindy doesn't look so scared anymore.";
+ next;
+ mes "[Cindy]";
+ mes "\"Hello, dear " + @title$ + " adventurer. Did my mother send you?\"";
+ next;
+ mes "\"It's so cold in here! Can you please open the cage?\"";
+ next;
+ mes "\"But be careful, if the Yetis hear you, they will come!\"";
+ menu
+ "Try to open the cage", L_Try_Cage,
+ "Leave", -;
+ close;
+
+L_Try_Cage:
+ if (countitem("TreasureKey") < @KEYS_AMOUNT) goto L_Not_Enough_Keys;
+ delitem "TreasureKey", @KEYS_AMOUNT;
+ mes "As you try to open the door of the cage, there is a loudly squeaking noise.";
+ next;
+ mes "You get an uncomfortable feeling and Cindy starts to shiver.";
+ next;
+ mes "\"Oh no, the Yetis...\"";
+//TODO: start the battle and set state2 in case of success
+ mes "DEBUG: ADD YETIFIGHT HERE, QUEST VARIABLE INCREASED";
+ set @rescue_Cindy, 2;
+ callsub S_Update_Mask;
+ close;
+
+L_Reward:
+ mes "[Cindy]";
+ mes "\"You are a hero! All this strong monsters!\"";
+ next;
+ mes "\"I've found this thing in the cave - it looks valuable. I want you to have it.\"";
+ next;
+ getinventorylist;
+ if (@inventorylist_count == 100) goto L_Full_Inv;
+
+ set @reward, rand(1);
+ if (@reward == 1) goto L_Wizard_Hat;
+ //TODO: set right, when quarterstaff is in item_db
+ //getitem "QuarterStaff", 1;
+ mes "DEBUG: GET ACORN INSTEAD OF QUARTERSTAFF";
+ getitem "acorn", 1;
+ goto L_Visit;
+
+L_Wizard_Hat:
+ //TODO: set right, when quarterstaff is in item_db
+ //getitem "WizardHat", 1;
+ mes "DEBUG: GET ACORN INSTEAD OF WIZARDHAT";
+ getitem "acorn", 1;
+
+L_Visit:
+ mes "\"Thank you so much, please come to my home. It's the house at the beach.\"";
+ next;
+ mes "\"I'm sure, my mother want to thank you as well.\"";
+ set @rescue_Cindy, 3;
+ callsub S_Update_Mask;
+ close;
+
+L_Please_Visit:
+ mes "[Cindy]";
+ mes "\"Thank you, thank you! You're a hero! Please come home with me to our house at the beach!\"";
+ close;
+
+L_Not_Enough_Keys:
+ mes "You don't have enough keys to open the cage.";
+ close;
+
+L_Full_Inv:
+ mes "\"Oh, it seems you carry so much stuff - I will keep it for you until you can take it.\"";
+ close;
+
+S_Update_Mask:
+ set QUEST_Nivalis_state,
+ (QUEST_Nivalis_state & ~(@Q_Nivalis_state_MASK))
+ | (@rescue_Cindy << @Q_Nivalis_state_SHIFT);
+ return;
+}
+
+
+
+
+
+
+
+
+
+
+
+
+