summaryrefslogtreecommitdiff
path: root/npc/000-2-1
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2021-04-09 11:00:49 -0300
committerJesusaves <cpntb1@ymail.com>2021-04-09 11:00:49 -0300
commit8a4bf716002a017de77fe7df301ef8e4aaf00a2e (patch)
tree4947d0b015baad639fa07133369e9a09c8a468bc /npc/000-2-1
downloadserverdata-8a4bf716002a017de77fe7df301ef8e4aaf00a2e.tar.gz
serverdata-8a4bf716002a017de77fe7df301ef8e4aaf00a2e.tar.bz2
serverdata-8a4bf716002a017de77fe7df301ef8e4aaf00a2e.tar.xz
serverdata-8a4bf716002a017de77fe7df301ef8e4aaf00a2e.zip
Initial commit
Diffstat (limited to 'npc/000-2-1')
-rw-r--r--npc/000-2-1/_import.txt17
-rw-r--r--npc/000-2-1/_mobs.txt3
-rw-r--r--npc/000-2-1/_savepoints.txt54
-rw-r--r--npc/000-2-1/_warps.txt3
-rw-r--r--npc/000-2-1/alige.txt321
-rw-r--r--npc/000-2-1/arpan.txt304
-rw-r--r--npc/000-2-1/chefgado.txt226
-rw-r--r--npc/000-2-1/chest.txt72
-rw-r--r--npc/000-2-1/dan.txt93
-rw-r--r--npc/000-2-1/devis.txt16
-rw-r--r--npc/000-2-1/hammock.txt125
-rw-r--r--npc/000-2-1/knife.txt47
-rw-r--r--npc/000-2-1/mapflags.txt1
-rw-r--r--npc/000-2-1/peter.txt302
-rw-r--r--npc/000-2-1/q'onan.txt15
-rw-r--r--npc/000-2-1/story_save.txt30
16 files changed, 1629 insertions, 0 deletions
diff --git a/npc/000-2-1/_import.txt b/npc/000-2-1/_import.txt
new file mode 100644
index 00000000..ba87b23e
--- /dev/null
+++ b/npc/000-2-1/_import.txt
@@ -0,0 +1,17 @@
+// Map 000-2-1: Second Deck
+// This file is generated automatically. All manually added changes will be removed when running the Converter.
+"npc/000-2-1/_mobs.txt",
+"npc/000-2-1/_savepoints.txt",
+"npc/000-2-1/_warps.txt",
+"npc/000-2-1/alige.txt",
+"npc/000-2-1/arpan.txt",
+"npc/000-2-1/chefgado.txt",
+"npc/000-2-1/chest.txt",
+"npc/000-2-1/dan.txt",
+"npc/000-2-1/devis.txt",
+"npc/000-2-1/hammock.txt",
+"npc/000-2-1/knife.txt",
+"npc/000-2-1/mapflags.txt",
+"npc/000-2-1/peter.txt",
+"npc/000-2-1/q'onan.txt",
+"npc/000-2-1/story_save.txt",
diff --git a/npc/000-2-1/_mobs.txt b/npc/000-2-1/_mobs.txt
new file mode 100644
index 00000000..e4b38bfc
--- /dev/null
+++ b/npc/000-2-1/_mobs.txt
@@ -0,0 +1,3 @@
+// This file is generated automatically. All manually added changes will be removed when running the Converter.
+// Map 000-2-1: Second Deck mobs
+000-2-1,52,32,21,9 monster Piou 1002,3,30000,20000
diff --git a/npc/000-2-1/_savepoints.txt b/npc/000-2-1/_savepoints.txt
new file mode 100644
index 00000000..da074f25
--- /dev/null
+++ b/npc/000-2-1/_savepoints.txt
@@ -0,0 +1,54 @@
+// This file is generated automatically. All manually added changes will be removed when running the Converter.
+// Map 000-2-1: Second Deck saves
+000-2-1,40,37,0 script #save_000-2-1_40_37 NPC_SAVE_POINT,0,0,{
+ savepointparticle .map$, .x, .y, NO_INN;
+ close;
+
+OnInit:
+ .distance = 2;
+ .sex = G_OTHER;
+ end;
+
+OnTouch:
+ bedTouch();
+ end;
+}
+000-2-1,46,37,0 script #save_000-2-1_46_37 NPC_SAVE_POINT,0,0,{
+ savepointparticle .map$, .x, .y, NO_INN;
+ close;
+
+OnInit:
+ .distance = 2;
+ .sex = G_OTHER;
+ end;
+
+OnTouch:
+ bedTouch();
+ end;
+}
+000-2-1,50,38,0 script #save_000-2-1_50_38 NPC_SAVE_POINT,0,0,{
+ savepointparticle .map$, .x, .y, NO_INN;
+ close;
+
+OnInit:
+ .distance = 2;
+ .sex = G_OTHER;
+ end;
+
+OnTouch:
+ bedTouch();
+ end;
+}
+000-2-1,55,40,0 script #save_000-2-1_55_40 NPC_SAVE_POINT,0,0,{
+ savepointparticle .map$, .x, .y, NO_INN;
+ close;
+
+OnInit:
+ .distance = 2;
+ .sex = G_OTHER;
+ end;
+
+OnTouch:
+ bedTouch();
+ end;
+}
diff --git a/npc/000-2-1/_warps.txt b/npc/000-2-1/_warps.txt
new file mode 100644
index 00000000..db3a1c8e
--- /dev/null
+++ b/npc/000-2-1/_warps.txt
@@ -0,0 +1,3 @@
+// This file is generated automatically. All manually added changes will be removed when running the Converter.
+// Map 000-2-1: Second Deck warps
+000-2-1,72,30,0 warp #000-2-1_72_30 0,0,000-2-0,31,26
diff --git a/npc/000-2-1/alige.txt b/npc/000-2-1/alige.txt
new file mode 100644
index 00000000..919b712d
--- /dev/null
+++ b/npc/000-2-1/alige.txt
@@ -0,0 +1,321 @@
+// Evol scripts.
+// Authors:
+// Ablu
+// Alige
+// Qwerty Dragon
+// Reid
+// Vasily_Makarov
+// Description:
+// Hidden in a ship's hole.
+// 2 bits array:
+// ShipQuests
+// Variable:
+// ShipQuests_Alige
+// Values:
+// 0 Never talk.
+// 1 First talk.
+// 2 Accept the task.
+// 3 Bring first food.
+
+000-2-1,43,32,0 script AligeTrigger NPC_HIDDEN,1,1,{
+
+OnTouch:
+ if (getareausers() <= 1)
+ {
+ setnpcdir "Alige", 2;
+ stopnpctimer;
+ initnpctimer;
+ }
+
+ if (getq(ShipQuests_Alige) > 0) close;
+ doevent "Alige::OnFirstEncounter";
+
+ close;
+
+OnUnTouch:
+ if (getareausers() == 0)
+ {
+ setnpcdir "Alige", 4;
+ stopnpctimer;
+ initnpctimer;
+ }
+ close;
+
+OnTimer190:
+ stopnpctimer;
+
+ if (getnpcdir("Alige") == 2) setnpcdir "Alige", 6;
+ if (getnpcdir("Alige") == 4) setnpcdir "Alige", 8;
+
+ end;
+}
+
+000-2-1,43,31,0 script Alige NPC_ALIGE,{
+ .@q = getq(ShipQuests_Alige);
+ if (.@q > 1) goto L_AskForFood;
+
+ goto OnFirstEncounter;
+
+OnFirstEncounter:
+ setq ShipQuests_Alige, 1;
+
+ setcamnpc;
+ mesn "Hidden Person";
+ mesq l("Hey, psst! You're not a sailor, right?");
+ next;
+ restorecam;
+
+ menu
+ l("I am, who are you?"), -,
+ l("Indeed, I am not."), L_NeedHelp;
+
+ mes "";
+ mesn "Narrator";
+ mesc(l("The stowaway doesn't answer."), 9);
+
+ close;
+
+L_NeedHelp:
+ setcamnpc;
+ mes "";
+ mesn "Hidden Person";
+ mesq l("Good, good... Hey, could you help me please? I beg you, please, pleeeease...");
+ next;
+ restorecam;
+
+ menu
+ l("Why not, but who are you, and what kind of help do you need?"), L_CanHelp;
+ l("Sorry but I have no time for this."), -;
+
+ closeclientdialog;
+ close;
+
+L_CanHelp:
+ setcamnpc;
+ mes "";
+ mesn;
+ mesq l("My name is Alige, I've been hiding here for weeks. All I have to eat are these berries... berries... berries...");
+ next;
+ mesq l("I'm losing my mind here, I need something else to eat!");
+ next;
+ mesq l("Could you please bring me something which isn't a berry, and I'm not big on vegetables either. I need proteins!");
+ next;
+ restorecam;
+
+ menu
+ l("Sure, but what will you give me in exchange?"), L_AboutReward,
+ l("Why don't you come out?"), -;
+
+L_ExplainHiding:
+ setcamnpc;
+ mes "";
+ mesn;
+ mesq l("No, I can't. I won't! All I wanted was to travel across the seas for fun, growl... sniff. And in this hole in the floor, as you can see, I have lots of fun.");
+ next;
+ mesq l("Oh... um... actually... all I wanted was to get to Artis. Err... but I didn't, uhm... have enough money to pay for the ferry!");
+ next;
+ mesq l("Please don't tell people you saw me. I don't want to be decapitated or get thrown into the sea as food for sharks, or get my hair mussed!");
+ next;
+ restorecam;
+
+ if (getq(ShipQuests_Alige) == 2) goto L_SoAskForFood;
+ goto L_Accept;
+
+L_AboutReward:
+ setcamnpc;
+ mes "";
+ mesn;
+ mesq l("I'll share my berries with you if you help me.");
+ next;
+ restorecam;
+
+L_Accept:
+ menu
+ l("Understood, I will help you."), L_FirstAccepted,
+ l("What is Artis?"), L_Artis,
+ l("I think I should report you to the crew members."), -;
+
+ setcamnpc;
+ mesq l("Growl, sniff, grr! You'd better not tell anyone you saw me!");
+
+ close;
+
+L_Artis:
+ setcamnpc;
+ mes "";
+ mesn;
+ mesq l("It's a commercial port of Andorra, it's weird that you don't know about it since it is one of the most famous cities throughout the whole world. But hey, back to me. Remember me telling you that I'm hun...grrr...eee!");
+ next;
+ restorecam;
+
+ if (.@q == 2) goto L_SoAskForFood;
+ goto L_Accept;
+
+L_FirstAccepted:
+ if (getq(ShipQuests_Alige) >= 2) goto L_Accepted;
+ setq ShipQuests_Alige, 2;
+
+ goto L_Accepted;
+
+L_Accepted:
+ setcamnpc;
+ mes "";
+ mesn;
+ mesq l("Great, what food do you have for me today?");
+ next;
+ restorecam;
+
+L_GiveFood:
+ mes "";
+
+ mes "##B" + l("Drag and drop an item from your inventory.") + "##b";
+ .@id = requestitem();
+ if (.@id <= 0) goto L_Quit; // Quit message.
+ if (countitem(.@id) == 0) goto L_Quit; // If don't have the food
+
+ if (array_find(.vegetables, .@id) >= 0) goto L_NoReward; // In case of wrong food.
+ if (array_find(.poisonable, .@id) >= 0) goto L_Poison; // In case of poisoned food (or food with effects).
+ if (.@id == Piberries) goto L_NoMore; // In case of Piberries.
+ if (.@id == RedPlushWine) goto L_Drunk; // In case of Alcohol.
+
+ // Default message for non food
+ if (array_find(.commonfood, .@id) == -1) goto L_NoFood;
+
+ inventoryplace Piberries, 3;
+ delitem .@id, 1;
+
+ setcamnpc;
+ mes "";
+ mesn;
+ mesq l("Thank you so much! Here, have some of my berries.");
+
+ setq ShipQuests_Alige, 3;
+ getitem Piberries, rand(1, 3);
+ next;
+
+ goto L_ReturnMenu;
+
+L_NoReward:
+ setcamnpc;
+ mes "";
+ mesn;
+ mesq l("You don't expect me to eat that, do you? Give me something else!");
+ next;
+ restorecam;
+
+ goto L_GiveFood;
+
+L_Drunk:
+ setcamnpc;
+ speech S_FIRST_BLANK_LINE | S_LAST_NEXT,
+ l("I asked for food but... *hips* Ah, that'll do!");
+ restorecam;
+
+ goto L_GiveFood;
+
+L_NoFood:
+ setcamnpc;
+ // We must first determine if it is at least edible (IT_HEALING)
+ if (getiteminfo(.@id, ITEMINFO_TYPE) == IT_HEALING)
+ {
+ speech S_FIRST_BLANK_LINE | S_LAST_NEXT,
+ l("That looks too exotic for me to eat!");
+ }
+ else
+ {
+ speech S_FIRST_BLANK_LINE | S_LAST_NEXT,
+ l("That doesn't looks edible to me!");
+ }
+ restorecam;
+
+ goto L_GiveFood;
+
+L_ReturnMenu:
+ setcamnpc;
+ mesq l("Do you have anything else for me?");
+ next;
+ restorecam;
+
+ goto L_GiveFood;
+
+L_NoMore:
+ setcamnpc;
+ mes "";
+ mesn;
+ mesq l("Grr, don't give me more berries! I don't want them, stupid berries, stupid... Stupid... Stupid!");
+ next;
+
+ goto L_ReturnMenu;
+
+L_Poison:
+ setcamnpc;
+ mes "";
+ mesn;
+ mesq l("Don't try to poison me! I know what that does!");
+ next;
+ restorecam;
+ goto L_ReturnMenu;
+
+L_SoAskForFood:
+ setcamnpc;
+ mesn;
+ mesq l("So, do you have anything for me today?");
+ next;
+ restorecam;
+ goto L_IntroMenu;
+
+L_AskForFood:
+ setcamnpc;
+ mesn;
+ mesq l("Do you have anything for me today?");
+ next;
+ restorecam;
+
+L_IntroMenu:
+ menu
+ l("Yes."), L_GiveFood,
+ l("Where can I find some food?"), L_FindFood,
+ l("Why are you hiding?") + " " + l("Why don't you come out?"), L_ExplainHiding,
+ l("What is Artis?"), L_Artis,
+ l("I think I should report you to the crew members."), -;
+
+ setcamnpc;
+ mesq l("Growl, sniff, grr! You'd better not tell anyone you saw me!");
+
+ close;
+
+L_FindFood:
+ setcamnpc;
+ mes "";
+ mesn;
+ mesq l("There are some flying yellow plushes around you. They're called pious. Getting a roasted leg of one of them would be perfect.");
+ next;
+ mesq l("I'd like to catch one of them, but they fly away when I try.");
+ next;
+ mesq l("Walking around a bit, it'll be easy for you to catch one, I bet. Impale one of them for me please.");
+ next;
+ restorecam;
+ mesn "Narrator";
+ mesc(l("You can attack a monster by clicking on it, or from your keyboard you can press the 'A' key to select the monster followed by 'Ctrl' to attack it."), 9);
+ next;
+ mesc(l("Once the monster is dead, click on the dropped items to add them to your inventory. You can also use the 'Z' key to claim the drops."), 9);
+
+ close;
+
+L_Quit:
+ setcamnpc;
+ mes "";
+ mesn;
+ mesq l("Too bad... Come back when you'll have some nice food for me. Growl... grumble... grumble.");
+
+ close;
+
+OnInit:
+ .distance = 2;
+
+ // Array of foods (remember to update in 001-2-22 as well)
+ setarray .commonfood, Bread, Fungus, Cheese, PiouLegs, Aquada, HalfCroconut, Plushroom, PumpkinJuice, Manana, Curshroom, Carrot, CarpSandwich, PioulegSandwich;
+ setarray .vegetables, Acorn, LettuceLeaf, Croconut, MananaSandwich;
+ setarray .poisonable, SeaDrops, PinkBlobime, PumpkinSeeds, UrchinMeat, EasterEgg;
+ end;
+}
diff --git a/npc/000-2-1/arpan.txt b/npc/000-2-1/arpan.txt
new file mode 100644
index 00000000..106d9aaa
--- /dev/null
+++ b/npc/000-2-1/arpan.txt
@@ -0,0 +1,304 @@
+// Evol scripts.
+// Authors:
+// Ablu
+// Qwerty Dragon
+// Description:
+// Explains to the player how he got here.
+// Variable:
+// 0 ShipQuests_Arpan
+// 1 ShipQuests_Julia
+// 2 ShipQuests_ArpanMoney
+// Values:
+// 00 Has not talked to Arpan yet.
+// 01 Talked to Arpan and needs to get the clothes.
+// 02 Has the clothes.
+// 03 Has and equipped the clothes.
+// 10 Has not talked to Julia
+// 11 Need to see Julia
+// 12 Has been registered by Julia
+// 20 Does not knows about money
+// 21 Has not taken possession from Arpan
+// 22 Took money from Arpan
+// 23 Took money and clothes (Legacy only)
+
+000-2-1,49,36,0 script LeftDoorCheck NPC_HIDDEN,0,0,{
+ .@q = getq(ShipQuests_Arpan);
+ if (.@q == 0) doevent "Magic Arpan::OnTalk";
+
+ close;
+}
+
+000-2-1,54,36,0 script RightDoorCheck NPC_HIDDEN,0,0,{
+ .@q = getq(ShipQuests_Arpan);
+ if (.@q == 0) doevent "Magic Arpan::OnTalk";
+
+ close;
+}
+
+000-2-1,47,32,0 script LeftBarrierCheck NPC_HIDDEN,0,2,{
+ .@q = getq(ShipQuests_Arpan);
+ if (.@q > 2) close;
+ if (.@q == 2 && getequipid(equip_torso) == 1300 && getequipid(equip_legs) == 2200) goto L_EquipDone;
+ if (.@q == 2) goto L_Equip;
+ if (.@q == 1) goto L_GetCloth;
+
+ doevent "Magic Arpan::OnClothNotTaken";
+
+L_Equip:
+ slide 49, 32;
+ doevent "Magic Arpan::OnEquip";
+
+ close;
+
+L_GetCloth:
+ slide 49, 32;
+ doevent "Magic Arpan::OnClothNotTaken";
+
+ close;
+
+L_EquipDone:
+ setq ShipQuests_Arpan, 3;
+
+ close;
+}
+
+000-2-1,56,32,0 script RightBarrierCheck NPC_HIDDEN,0,2,{
+ .@q = getq(ShipQuests_Arpan);
+ if (.@q > 2) close;
+ if (.@q == 2 && getequipid(equip_torso) == 1300 && getequipid(equip_legs) == 2200) goto L_EquipDone;
+ if (.@q == 2) goto L_Equip;
+ if (.@q == 1) goto L_GetCloth;
+
+ doevent "Magic Arpan::OnClothNotTaken";
+
+L_Equip:
+ slide 55, 32;
+ doevent "Magic Arpan::OnEquip";
+
+ close;
+
+L_GetCloth:
+ slide 55, 32;
+ doevent "Magic Arpan::OnClothNotTaken";
+
+ close;
+
+L_EquipDone:
+ setq ShipQuests_Arpan, 3;
+
+ close;
+}
+
+/////////////////////////////////////////////////////////////////////////////
+000-2-1,49,33,0 script Magic Arpan NPC_MAGIC_ARPAN,{
+ .@q = getq(ShipQuests_Arpan);
+ .@q_nard = getq(ShipQuests_Nard);
+ .@q_julia = getq(ShipQuests_Julia);
+ if (.@q == 2 && getequipid(equip_torso) == 1300 && getequipid(equip_legs) == 2200) goto L_EquipDone;
+
+OnTalk:
+ mesn;
+
+ if (.@q > 0) goto L_Menu;
+ setq ShipQuests_Arpan, 1;
+ deltimer("Magic Arpan::OnSlow");
+
+ mesq l("Yeye, you are really lucky to be alive. You are in good enough shape for walking, do you remember what happened?");
+ next;
+
+ menu
+ l("I only remember I was rescued by you."), L_Story,
+ l("I can't remember anything."), L_OhWell;
+
+OnClothNotTaken:
+ mesn;
+ mesq l("Yeye, you still did not get your new clothes from the chest next to your bed!");
+
+ close;
+
+OnEquip:
+ mesn "Narrator";
+ mesc(l("To open your inventory, use the F3 key or use your mouse to select it in the above menu in your client."), 9);
+ next;
+ mesc(l("When your inventory is open, you can equip an item by selecting it and clicking 'Equip'. You can do the same to remove an item by clicking on 'Unequip'."), 9);
+ next;
+ mesc(l("Items have different effects. Some will heal you, some can be used as weapons or armor, and some can be sold for gold."), 9);
+
+ close;
+
+L_OhWell:
+ mes "";
+ mesq l("Oh well, we rescued you when you were yaying adrift in the sea.");
+ next;
+
+ select
+ l("And then what happened?");
+
+L_Story:
+ mes "";
+ mesq l("You were yaying sleeping for quite some time there. Our shipkeeper, Julia, was here with you, and she did her best to heal your injuries.");
+ next;
+ if (.@q_julia == 0) setq ShipQuests_Julia, 1;
+ mesq l("Yaya, you should go see her! She'll be happy to see you.");
+ next;
+ mesq l("Also, we took your yayed clothes, as they were... Yeyeye... In a bad shape. Go check the chest near your bed, there are some other ones inside.");
+ setcamnpc "Chest";
+
+ close;
+
+L_Menu:
+ mesq l("What yeye could I do for you today?");
+ next;
+ .@equipped = getequipid(equip_torso) == 1300 && getequipid(equip_legs) == 2200;
+
+ menu
+ rif(.@q_nard == 5 && getq(General_Narrator) < 1, l("What can I do now?")), L_GotoSleep,
+ l("Could you tell me where I am?"), L_Where,
+ l("Where can I find Julia?"), L_Julia,
+ l("Who are you?"), L_Who,
+ rif(getq(ShipQuests_ArpanMoney) == 1, l("Do you know what happened to the gold I had when you guys saved me?")), L_WhereMoney,
+ rif(getq(ShipQuests_ArpanMoney) < 2, l("Where are my old clothes?")), L_WhereOldClothes,
+ rif(getq(ShipQuests_ArpanMoney) == 2 && islegacyaccount(), l("About my my old clothes...")), L_LegacyClothes,
+ rif(!.@equipped, l("What should I do after taking these clothes?")), L_WhatCloth,
+ rif(!.@equipped, l("Thank you, I'll take them and put them on.")), -,
+ l("Nothing, sorry."), -;
+
+ closeclientdialog;
+ close;
+
+L_Where:
+ mes "";
+ mesn;
+ mesq l("You're on our ship, we made port to a little island and we're actually yeyending our long merchant traveling adventure at the city of Artis.");
+ next;
+ mesq l("We will be yaying there in a few days, so we will drop you off there.");
+ next;
+ mesq l("You will see, citizens are polite and you can still ask for help in the Legion of Aemil. They can help find a job for you or maybe help you find out what happened to you out at sea!");
+ next;
+
+ goto L_Menu;
+
+L_Julia:
+ mes "";
+ mesn;
+ mesq l("She's on the upper level, yeye can't miss her. She's the only girl in this crew so far.");
+ next;
+
+ mesn "Narrator";
+ mesc(l("Julia is on the upper level of the ship, use the arrow keys to walk to the stairs or click on the stairs at the top right of your screen."), 9);
+ next;
+
+ goto L_Menu;
+
+L_Who:
+ mes "";
+ mesn;
+ mesq l("Sorry! I forgot to introduce myself. My name is Arpan, but other sailors call me Magic Arpan because I know one or two yaing magic spells.");
+ next;
+
+ goto L_Menu;
+
+L_WhereOldClothes:
+ mes "";
+ mesn;
+ mesq l("We tried to clean them but the sea water mostly destroyed them. It's why we gave you these clothes. They're not very nice, but that's all that we have for you.");
+ next;
+ mes l("Oh, now that I remember, we also found some money in your pockets, here it is!");
+ next;
+
+ setq ShipQuests_ArpanMoney, 2;
+ .@q = getq(ShipQuests_Arpan);
+ Zeny += 10;
+ message strcharinfo(0), l("You receive @@ E!", 10);
+
+ if (islegacyaccount())
+ goto L_LegacyClothes;
+
+ goto L_BeforeMenu;
+
+L_LegacyClothes:
+ if (islegacyaccount()) {
+ mesn strcharinfo(0);
+ select
+ l("But... I remember that my clothes were very dear to me..."),
+ l("Oh okay.");
+ mes "";
+ if (@menu == 1) {
+ mesn;
+ mesq l("Well, you can have them back, but they're yayaya, mostly destroyed. Not sure what yeye are going to do with that.");
+ getitem ClothesPack, 1;
+ setq ShipQuests_ArpanMoney, 3;
+ }
+ }
+ goto L_BeforeMenu;
+
+L_WhereMoney:
+ mes "";
+ mesn;
+ mesq l("Oh right, I totally forgot about that, here you go.");
+ next;
+
+ setq ShipQuests_ArpanMoney, 2;
+ .@q = getq(ShipQuests_Arpan);
+ Zeny += 10;
+ message strcharinfo(0), l("You receive @@ E!", 10);
+
+ goto L_BeforeMenu;
+
+L_WhatCloth:
+ mes "";
+ mesn;
+ mesq l("Oh yeyeye... As they are not edible, you can maybe try to equip them?");
+ next;
+
+ mesn "Narrator";
+ mesc(l("To open your inventory, use the F3 key or use your mouse to select it in the above menu in your client."), 9);
+ next;
+ mesc(l("When your inventory is open, you can equip an item by selecting it and clicking 'Equip'. You can do the same to unequip an item by clicking on 'Unequip'."), 9);
+ next;
+ mesc(l("Items have different effects. Some will heal you, some can be used as weapons or armor, and some can be sold for gold."), 9);
+ next;
+
+L_BeforeMenu:
+ mesn;
+ goto L_Menu;
+
+L_EquipDone:
+ setq ShipQuests_Arpan, 3;
+ goto L_Menu;
+
+L_GotoSleep:
+ speech S_FIRST_BLANK_LINE | S_LAST_NEXT,
+ l("You already did enough for us, do you want to follow Nard's advice and get some rest?");
+
+ switch (select(l("Yes."), l("No.")))
+ {
+ case 1:
+ speech S_FIRST_BLANK_LINE | S_LAST_NEXT,
+ l("Fine."),
+ l("We are at half a day from our final destination, by the time that you wake up I'm sure that we will be there!");
+
+ closeclientdialog;
+ doevent "#name3::OnClick";
+ close;
+
+ break;
+ case 2:
+ speech S_FIRST_BLANK_LINE | S_LAST_NEXT,
+ l("Alright, take your time we are not in a hurry.");
+
+ break;
+ }
+
+ goto L_Menu;
+
+OnSlow:
+ dispbottom(l("Use arrow keys to walk around and leave this room."));
+ npctalk3(l("Please come talk to me, I'll help you get dressed."));
+ addtimer(90000,"Magic Arpan::OnSlow");
+ close;
+
+OnInit:
+ .distance = 5;
+ end;
+}
diff --git a/npc/000-2-1/chefgado.txt b/npc/000-2-1/chefgado.txt
new file mode 100644
index 00000000..0e3a71be
--- /dev/null
+++ b/npc/000-2-1/chefgado.txt
@@ -0,0 +1,226 @@
+// Evol scripts.
+// Authors:
+// Hal9000
+// Qwerty Dragon
+// Description:
+// La Johanne Chef.
+// Variable:
+// ShipQuests_ChefGado
+// ShipQuests_Nard
+// Values:
+// 0 Default, no quest given.
+// 1 Quest accepted.
+// 2 Ingredients collected, ready to poison Julia.
+// 3 Julia poisoned.
+// 4 Quest complete. Chef Gago wins.
+// 5 Quest complete. Julia wins (poison dish returned).
+// 6 Quest complete. Julia wins.
+
+000-2-1,27,28,0 script Chef Gado NPC_CHEF_GADO,{
+ .@q = getq(ShipQuests_ChefGado);
+ .@n = getq(ShipQuests_Nard);
+ if (.@q == 1) goto L_QuestAccepted;
+ if (.@q == 2) goto L_PoisonAccepted;
+ if (.@q == 3) goto L_PoisonJulia;
+ if (.@q == 4) goto L_QuestComplete;
+ if (.@q == 5 && countitem(PoisonedDish) > 0) goto L_Aborting;
+ if (.@q > 4) goto L_QuestAborted;
+ if (.@n == 3) goto L_QuestStart;
+
+ mesn;
+ .@r = rand(3);
+ if (.@r == 0) mesq l("What are you doing in my kitchen?! Get out, it's not a place for kids!");
+ if (.@r == 1) mesq l("Where is the damn salt?! Give me the salt, I know you have it!");
+ if (.@r == 2) mesq l("Are you going to stand here all day long? Do the dishes or go away.");
+
+ if (getq(General_SmearedHands) < 3) {
+ next;
+ select
+ l("I'll get moving, sorry!"),
+ //rif(.@r == 1 && countitem(Salt), l("Offer him the salt")),
+ l("Can you teach me cooking?");
+ mes "";
+ if (@menu == 2) {
+ mesn;
+ mesq l("NO! I am busy, can't you see?!");
+ next;
+ mesn;
+ mesq l("When we reach Artis, maybe, but not now!");
+ }
+ }
+ close;
+
+L_QuestStart:
+ mesn;
+ mesq l("So it seems I have another stomach to fill. Those bastards have no respect for who feeds them every damn day!");
+ next;
+
+ menu
+ l("How rude! What is the reason behind your malice?"), L_Rude,
+ l("I swear, I do not eat so much."), -;
+
+ mes "";
+ mesn;
+ mesq l("Yeah, yeah, of course you don't...");
+
+ close;
+
+L_Rude:
+ mes "";
+ mesn;
+ mesq l("UAHAHAHAAH! I am the cook of that bunch of donkeys, and I can be rude with everyone from this bossy captain to that harpy-lady!");
+ next;
+
+ select
+ l("Harpy-lady?");
+
+ mes "";
+ mesn;
+ mesq l("I am sure you know her. Nice dress, large smile and a constant flux of orders and rules. Julia they call her!");
+ next;
+ mesq l("You have to know that there was a time during which I was the unopposed lieutenant of this crew. Then one day one of those damn sailors brought that 'nice' lady here.");
+ next;
+ mesq l("I will not tell you all the details, but after a month, she was ruling the ship and I was sent down here, cooking for those traitors!");
+ next;
+ mesq l("But I swear that one day... Oh... My tasty revenge! Hhm, actually I wonder if... Maybe...");
+ next;
+
+ select
+ l("M... Maybe?");
+
+ mes "";
+ mesn;
+ mesq l("Well, eh-heh... Welcome aboard, young fellow!");
+ next;
+ mesq l("I just realized I am lacking some common things, and one key ingredient, to prepare a... A special recipe.");
+ next;
+ mesq l("I only need 2 @@, 2 @@s, 1 @@...", getitemlink(PiouLegs), getitemlink(HalfCroconut), getitemlink(Aquada));
+ next;
+ mesq l("... and 1 @@.", getitemlink(SeaDrops));
+ next;
+
+ menu
+ l("Sea water?! I will not help you with your evil plan!"), L_Quit,
+ l("Sure, why not?"), -;
+
+ setq ShipQuests_ChefGado, 1;
+ mes "";
+ mesn;
+ mesq l("Well done! Collect all the ingredients and then come back here. You will be rewarded once I am satisfied that they understand who rules this ship!");
+ next;
+ mesq l("Before you go, let me tell you how to get @@s, because you don't look very smart.", getitemlink(HalfCroconut));
+
+ goto L_OpenCroconut;
+
+L_QuestAccepted:
+ mesn;
+ mesq l("Have you collected all the ingredients for my recipe? The special one too?");
+ next;
+
+ menu
+ rif(countitem(PiouLegs) > 1 && countitem(HalfCroconut) > 1 && countitem(Aquada) > 0 && countitem(SeaDrops) > 0, l("All your... Fresh ingredients are ready to be cooked.")), L_GotAll,
+ l("What are your needs?"), L_Need,
+ l("Where can I find a half croconut?"), L_OpenCroconut,
+ l("Not yet. I will be back soon."), L_Quit;
+
+L_OpenCroconut:
+ mes "";
+ mesn;
+ mesq l("Take a @@ and try opening it using something like a sharp knife. I doubt you'll succeed, you're being so weak in everything.", getitemlink(Croconut));
+ next;
+ mesq l("Now move!");
+
+ close;
+
+L_GotAll:
+ mes "";
+
+ inventoryplace PoisonedDish, 1;
+
+ delitem PiouLegs, 2;
+ delitem HalfCroconut, 1;
+ delitem Aquada, 1;
+ delitem SeaDrops, 1;
+
+ mesn;
+ mesq l("Let me see... Crispy legs, disgusting liquids... Let's start!");
+ next;
+ mesq l("Water, salt, spicy herbs and meat stuffed with my special surprise!");
+ next;
+ mesq l("Done. Here, take it! Now, here is the plan. Go talk to her and offer our beautiful lady a bite of her arrogance!");
+
+ setq ShipQuests_ChefGado, 2;
+ getitem PoisonedDish, 1;
+ close;
+
+L_Need:
+ mes "";
+ mesn;
+ mesq l("Shhht, don't say it that loud...");
+ next;
+ mesq l("I only need 2 @@, 2 @@s, 1 @@...", getitemlink(PiouLegs), getitemlink(HalfCroconut), getitemlink(Aquada));
+ next;
+ mesq l("... and 1 @@.", getitemlink(SeaDrops));
+
+ close;
+
+L_PoisonAccepted:
+ mesn;
+ mesq l("Fool! Just come back here when you'll be done with our little... 'Secret mission'.");
+
+ close;
+
+L_PoisonJulia:
+ mesn;
+ mesq l("The usurper has been punished! This is a great day! Take this reward as a prize for your loyalty to the old commander!");
+
+ setq ShipQuests_ChefGado, 4;
+ Zeny += 200;
+ message strcharinfo(0), l("You receive @@ E!", 200);
+ inventoryplace Bread, 1;
+ getitem Bread, 1;
+ getexp 15, 0;
+
+ close;
+
+L_QuestComplete:
+ mesn;
+ mesq l("Oh, it's you. I think it's better we do not talk for a while. They suspect something.");
+
+ close;
+
+L_Aborting:
+ mesn;
+ mesq l("Wait, why do you still have the dish with you?!");
+ next;
+
+ select
+ l("I informed Julia about your monstrous plan.");
+
+ mes "";
+ mesn;
+ mesq l("Are you mad?!");
+ next;
+ mesq l("Give me back this dish, you dirty liar!");
+
+ if (countitem(PoisonedDish) > 0) delitem PoisonedDish, 1;
+
+ next;
+ mesq l("You're like the rest of this filthy crew, I can't trust you!");
+
+ close;
+
+L_QuestAborted:
+ mesn;
+ mesq l("You're like the rest of this filthy crew. Your name is now on the traitors list!");
+
+ close;
+
+L_Quit:
+ closeclientdialog;
+ close;
+
+OnInit:
+ .distance = 2;
+ end;
+}
diff --git a/npc/000-2-1/chest.txt b/npc/000-2-1/chest.txt
new file mode 100644
index 00000000..f9ec2742
--- /dev/null
+++ b/npc/000-2-1/chest.txt
@@ -0,0 +1,72 @@
+// Evol scripts.
+// Authors:
+// 4144
+// gumi
+// omatt
+// Reid
+// Description:
+// A box with clothes for new players.
+// Variable:
+// ShipQuests_Arpan
+// Values:
+// 1 Talked to Arpan and needs to get clothes.
+// 2 Has the clothes.
+
+000-2-1,51,37,0 script Chest#000-2-1 NPC_CHEST_BIG,2,4,{
+
+ .@questState = getq(ShipQuests_Arpan);
+
+ if (.@questState == 0)
+ {
+ npctalk3 l("You should talk to Magic Arpan first.");
+ end;
+ }
+
+ if (.busy == false)
+ {
+ if (.@questState <= 1)
+ {
+ inventoryplace CreasedShirt, 2;
+ setq ShipQuests_Arpan, 2;
+ getitem CreasedShirt, 1;
+ getitem CreasedShorts, 1;
+ npctalk3 l("You take the clothes from the chest.");
+ }
+
+ specialeffect(.dir == 0 ? 24 : 25, AREA, getnpcid()); // closed ? opening : closing
+ .dir = .dir == 0 ? 2 : 6; // closed ? opening : closing
+ .busy = true; // lock the animation
+ initnpctimer;
+ }
+ end;
+
+OnTimer220:
+ .dir = .dir == 6 ? 0 : 4; // closing ? closed : open
+ end;
+
+OnTimer500:
+ .busy = false; // unlock
+
+ if (.dir == 0)
+ {
+ stopnpctimer; // stop here if the chest is closed
+ }
+ end;
+
+OnUnTouch:
+ if (getareausers(.x - 2, .y - 4, .x + 2, .y + 6) > 0 || .dir == 0)
+ {
+ end;
+ }
+OnTimer30000:
+ .busy = true;
+ .dir = 6; // closing
+ specialeffect(25, AREA, getnpcid()); // closing
+ setnpctimer 0;
+OnTouch:
+ end;
+
+OnInit:
+ .distance = 2;
+ end;
+}
diff --git a/npc/000-2-1/dan.txt b/npc/000-2-1/dan.txt
new file mode 100644
index 00000000..f336402d
--- /dev/null
+++ b/npc/000-2-1/dan.txt
@@ -0,0 +1,93 @@
+// Evol scripts.
+// Authors:
+// Qwerty Dragon
+// Reid
+// Description:
+// There are two kinds of dialogues in this script.
+// Dan will randomly choose between a useless sentence, and a quest in Artis.
+
+000-2-1,32,31,0 script Dan#000-2-1 NPC_DEMON_MAN,{
+ if (getq(General_Narrator) > 0)
+ {
+ sailortalk;
+ close;
+ }
+
+ mesn;
+ .@q = rand(3);
+ if (.@q == 0) goto L_QuestStory;
+
+ mesq l("You see these pious around us?");
+ next;
+ mesq l("It seems that we are close to an island, we should take a look at the upper level.");
+
+ close;
+
+L_QuestStory:
+ mesq l("It's so hard to find the motivation...");
+ next;
+
+ menu
+ l("Why?"), -,
+ l("I guess so... I will leave you alone."), L_Quit;
+
+ mes "";
+ mesn;
+ mesq l("Oh, it's you.");
+ next;
+ mesq l("So, you finally woke up? We all thought you were in something like... You know, one of these long comas.");
+ next;
+
+ menu
+ l("I'm still in a coma, but my ghost is haunting you!"), L_Quit,
+ l("It was something like a long nap."), -;
+
+ mes "";
+ mesn;
+ mesq l("It's good, good... I have a friend who is still in a coma, but I can't be with her without working...");
+ next;
+ mesq l("The fear to see her sleeping on this quiet and lonely bed is becoming more and more unbearable, I think that I won't get the bravery to see her this time...");
+ next;
+
+ menu
+ l("Who is she?"), L_She,
+ l("Do you want me to go see her instead of you?"), L_Quest,
+ l("I don't know what to say..."), -;
+
+ mes "";
+ mesn;
+ mesq l("There's nothing to say, don't worry.");
+
+ close;
+
+L_She:
+ mes "";
+ mesn;
+ mesq l("She is a good friend of mine... We wanted to move together a few weeks before her accident but...");
+ next;
+
+ goto L_Quit2;
+
+L_Quest:
+ mes "";
+ mesn;
+ mesq l("I don't think that we are in a good place to talk about this...");
+ next;
+
+L_Quit:
+ mes "";
+ mesn "Narrator";
+ mesc(l("Dan keeps silent since your last question."), 9);
+
+ close;
+
+L_Quit2:
+ mesn "Narrator";
+ mesc(l("Dan ends the conversation and resumes to write his letter."), 9);
+
+ close;
+
+OnInit:
+ .distance = 2;
+ end;
+}
diff --git a/npc/000-2-1/devis.txt b/npc/000-2-1/devis.txt
new file mode 100644
index 00000000..5071dfb7
--- /dev/null
+++ b/npc/000-2-1/devis.txt
@@ -0,0 +1,16 @@
+// Evol scripts.
+// Authors:
+// Alige
+// Reid
+// Vasily_Makarov
+// Description:
+// Sleeping and grumbling NPC.
+
+000-2-1,32,38,0 script Devis NPC_HAMMOC,{
+ asleep;
+ close;
+
+OnInit:
+ .distance = 2;
+ end;
+}
diff --git a/npc/000-2-1/hammock.txt b/npc/000-2-1/hammock.txt
new file mode 100644
index 00000000..3e188eed
--- /dev/null
+++ b/npc/000-2-1/hammock.txt
@@ -0,0 +1,125 @@
+// Evol scripts.
+// Author:
+// Reid
+// Description:
+// Animated hammock at the mid level of the ship.
+
+000-2-1,32,27,0 script #hammock1 NPC_LEFT_HAMMOCK,1,0,{
+
+OnTouch:
+ hamTouchLeft;
+
+OnUnTouch:
+ hamUnTouch;
+
+OnTimer5440:
+ hamTimerLeft;
+}
+
+000-2-1,32,25,0 script #hammock2 NPC_LEFT_HAMMOCK,1,0,{
+
+OnTouch:
+ hamTouchLeft;
+
+OnUnTouch:
+ hamUnTouch;
+
+OnTimer5440:
+ hamTimerLeft;
+}
+
+000-2-1,37,25,0 script #hammock3 NPC_RIGHT_HAMMOCK,1,0,{
+
+OnTouch:
+ hamTouchLeft;
+
+OnUnTouch:
+ hamUnTouch;
+
+OnTimer5440:
+ hamTimerLeft;
+}
+
+000-2-1,37,27,0 script #hammock4 NPC_RIGHT_HAMMOCK,1,0,{
+
+OnTouch:
+ hamTouchLeft;
+
+OnUnTouch:
+ hamUnTouch;
+
+OnTimer5440:
+ hamTimerLeft;
+}
+
+000-2-1,37,29,0 script #hammock5 NPC_RIGHT_HAMMOCK,1,0,{
+
+OnTouch:
+ hamTouchLeft;
+
+OnUnTouch:
+ hamUnTouch;
+
+OnTimer5440:
+ hamTimerLeft;
+}
+
+000-2-1,37,34,0 script #hammock6 NPC_RIGHT_HAMMOCK,1,0,{
+
+OnTouch:
+ hamTouchLeft;
+
+OnUnTouch:
+ hamUnTouch;
+
+OnTimer5440:
+ hamTimerLeft;
+}
+
+000-2-1,37,36,0 script #hammock7 NPC_RIGHT_HAMMOCK,1,0,{
+
+OnTouch:
+ hamTouchLeft;
+
+OnUnTouch:
+ hamUnTouch;
+
+OnTimer5440:
+ hamTimerLeft;
+}
+
+000-2-1,37,38,0 script #hammock8 NPC_RIGHT_HAMMOCK,1,0,{
+
+OnTouch:
+ hamTouchLeft;
+
+OnUnTouch:
+ hamUnTouch;
+
+OnTimer5440:
+ hamTimerLeft;
+}
+
+000-2-1,32,40,0 script #hammock9 NPC_LEFT_HAMMOCK,1,0,{
+
+OnTouch:
+ hamTouchLeft;
+
+OnUnTouch:
+ hamUnTouch;
+
+OnTimer5440:
+ hamTimerLeft;
+}
+
+000-2-1,37,40,0 script #hammock10 NPC_RIGHT_HAMMOCK,1,0,{
+
+OnTouch:
+ hamTouchLeft;
+
+OnUnTouch:
+ hamUnTouch;
+
+OnTimer5440:
+ hamTimerLeft;
+}
diff --git a/npc/000-2-1/knife.txt b/npc/000-2-1/knife.txt
new file mode 100644
index 00000000..b3e44eef
--- /dev/null
+++ b/npc/000-2-1/knife.txt
@@ -0,0 +1,47 @@
+// Evol scripts.
+// Authors:
+// Ablu
+// Qwerty Dragon
+// Description:
+// Knife on the table.
+// Variable:
+// ShipQuests_Knife
+// Values:
+// 0 Default, not taken.
+// 1 Knife taken.
+
+000-2-1,50,24,0 script #knife NPC_KNIVES,{
+ .@q = getq(ShipQuests_Knife);
+ if (.@q) close;
+
+ mesn "Narrator";
+ mesc(l("There are some knives on the table. Would you like to take one?"), 9);
+ next;
+
+ menu
+ l("Yes."), L_Give,
+ l("No."), -;
+
+ closeclientdialog;
+ close;
+
+L_Give:
+ mes "";
+ inventoryplace Knife, 1;
+
+ setq ShipQuests_Knife, 1;
+ getitem Knife, 1;
+
+ mesn "Narrator";
+ mesc(l("To open your inventory, use the F3 key or use your mouse to select it in the above menu in your client."), 9);
+ next;
+ mesc(l("When your inventory is open, you can equip an item by selecting it and clicking 'Equip'. You can do the same to unequip an item by clicking on 'Unequip'."), 9);
+ next;
+ mesc(l("Items have different effects. Some will heal you, some can be used as weapons or armor, and some can be sold for gold."), 9);
+
+ close;
+
+OnInit:
+ .distance = 2;
+ end;
+}
diff --git a/npc/000-2-1/mapflags.txt b/npc/000-2-1/mapflags.txt
new file mode 100644
index 00000000..1543b585
--- /dev/null
+++ b/npc/000-2-1/mapflags.txt
@@ -0,0 +1 @@
+000-2-1 mapflag town
diff --git a/npc/000-2-1/peter.txt b/npc/000-2-1/peter.txt
new file mode 100644
index 00000000..499304c4
--- /dev/null
+++ b/npc/000-2-1/peter.txt
@@ -0,0 +1,302 @@
+// Evol scripts.
+// Authors:
+// 4144
+// Ablu
+// Alastrim
+// Jesusalva
+// Qwerty Dragon
+// Reid
+// Vasily_Makarov
+// Description:
+// Rat hunter.
+// 4+2 bits array:
+// ShipQuests
+// Variable:
+// ShipQuests_Peter
+// Values is a bitmask:
+// 0 Doesn't know the quest.
+// 1 Task given. (To prevent bugs because zero is a valid instance id)
+// 2 Already completed the first stage
+// 4 Already completed the second stage
+// 8 Already completed the third stage
+// ...
+// =15 Completed every stage.
+// Setq2:
+// Number of killed Rattos:
+// & 1 - Ratto 1
+// & 2 - Ratto 2
+// & 4 - Ratto 3
+// & 8 - Ratto 4
+// = 15: All rattos killed
+// (Adding more monsters etc. is possible, but be careful with the == 15 checks)
+// Setq3:
+// Instance ID (so we can destroy it later if needed, and check it too)
+// Others:
+// .@q = Peter variable.
+// PETER_TIME = gettimetick(2) for daily
+// @peter = Control Variable
+// @pt_mob = Control Variable
+// @MAP_NAME$ = Control Variable
+// "000-2-2" - map with mobs.
+
+000-2-1,72,34,0 script AreaNPC NPC_HIDDEN,0,1,{
+ end;
+OnTouch:
+ doevent "Peter::OnPeterMain";
+ close;
+}
+
+000-2-1,70,35,0 script Peter NPC_RATTO_SAILOR,{
+ goto L_Main;
+
+OnPeterMain:
+L_Main:
+ .@q = getq(ShipQuests_Peter);
+ .@q2 = getq2(ShipQuests_Peter);
+ .@q3 = getq3(ShipQuests_Peter);
+ if (BaseLevel < 5) goto OnTooWeak;
+
+ if (!.@q || !isinstance(.@q3) || .@q3 <= 0) goto L_Task;
+ if (.@q2 < 15) goto L_ReturnFail;
+ dispbottom l("I am broken?! Please report! Debug data: @@ (@@)", .@q, .@q2);
+ close;
+
+OnGiveTask:
+L_Task:
+ if (!.@q)
+ setq ShipQuests_Peter, 1, 0, -1;
+ mesn;
+ mesq l("Hey there!");
+ next;
+ mesq l("I need somebody who can rid the hold of the ship of these rattos. Can you help me?");
+ next;
+
+ menu
+ l("Yeah, but what reward will I get?"), L_BonusTask,
+ l("Why not, I need to train anyway."), L_BonusTask,
+ l("No, they are way too dangerous for me!"), -;
+
+ mes "";
+ mesn;
+ mesq l("Hehe, hehe. Well, come back if you change your mind.");
+
+ close;
+
+// Friendly reminder that you have about 20 secs to finish
+OnLowTime:
+ if ((getmap() ~= "000-2-1") || (getmap() ~= "nard*"))
+ dispbottom l("I'm starting to feel dizzy... I shouldn't stay here much longer.");
+ end;
+
+// Minimum Quest Level (any difficulty setting) is on L_Main (and currently is 5)
+OnTooWeak:
+ mesn;
+ mesq l("I need someone to help me clean the edge of the ship, but you aren't strong enough for now.");
+
+ close;
+
+/*
+OnStop:
+ slide 72, 36;
+
+ mesn;
+ mesq l("You can't go there!");
+
+ close;
+*/
+
+// This is cast if player dies in Basement, but not automatically (bad design?)
+// instance_destroy() is being recklessy called here, some sanity check is good.
+OnReturnFail:
+L_ReturnFail:
+ .@q3 = getq3(ShipQuests_Peter);
+ //instance_destroy(.@q3); // This would allow players to try again at once, but is DANGEROUS!
+ setq2 ShipQuests_Peter, 0;
+ setq3 ShipQuests_Peter, -1;
+ mesn;
+ mesq l("I see it's not so easy to get rid of these rattos. Do you want to try again?");
+ next;
+
+ menu
+ l("Yeah, but I would like to make sure I get a reward."), L_BonusTask,
+ l("Why not, I need to train anyway."), L_BonusTask,
+ l("No, they are way too dangerous for me!"), -;
+
+ mes "";
+ mesn;
+ mesq l("Hehe, hehe. Well, come back if you change your mind.");
+
+ close;
+
+
+L_BonusTask:
+ mes "";
+ mesn;
+ mesq l("There are three kind of monsters which frequently or seldomly attacks our fair vessel.");
+ next;
+ mesn;
+ .@q = getq(ShipQuests_Peter);
+ if (!(.@q & 2)) {
+ mes l("- I currently need your help with @@.", getmonsterlink(Tortuga));
+ mes l("I'll give you @@ GP for this job.", 500);
+ mes "";
+ }
+ if (!(.@q & 4)) {
+ mes l("- I currently need your help with @@.", getmonsterlink(Ratto));
+ mes l("I'll give you @@ GP for this job.", 1000);
+ mes "";
+ }
+ if (!(.@q & 8)) {
+ mes l("- I currently need your help with @@.", getmonsterlink(Croc));
+ mes l("I'll give you @@ GP for this job.", 1500);
+ mes "";
+ }
+ // If you already took all three bounties, you can only repeat the quest daily
+ if (.@q == 15 && PETER_TIME <= gettimetick(2)) {
+ mes l("- I currently need your help with @@.", getmonsterlink(Ratto));
+ mes l("I'll give you @@ GP for this job.", 750);
+ } else if (.@q == 15) {
+ mes l("I don't need your help right now, but maybe tomorrow, who knows?");
+ close;
+ }
+ next;
+
+ select
+ l("I'm not feeling like it today... Sorry."),
+ rif(!(.@q & 2), l("I will take the @@ Bounty.", "Tortuga")),
+ rif(!(.@q & 4), l("I will take the @@ Bounty.", "Ratto")),
+ rif(!(.@q & 8), l("I will take the @@ Bounty.", "Croc")),
+ rif(.@q == 15, l("Why not, I need to train anyway."));
+
+ if (@menu == 1)
+ close;
+
+ @peter=@menu;
+
+ goto L_Start;
+
+// In Moubootaur Legends, there's a small tutorial about Hit'n'run here
+// I didn't add it here but that can be arranged
+L_Start:
+// Init Instance
+OnStartOutside:
+ .@ID=getcharid(0);
+ @MAP_NAME$="nard@"+str(.@ID); // Max 4 chars for map name
+ .@INSTID = instance_create("ratto@a"+(.@ID), getcharid(3), IOT_CHAR);
+ .@instanceMapName$ = instance_attachmap("000-2-2", .@INSTID, 0, @MAP_NAME$);
+
+ // Instance already exists, or something went wrong
+ if (.@instanceMapName$ == "") {
+ mesn;
+ mesq l("Actually, you just took a bounty, right?");
+ next;
+ mesn;
+ mesq l("Why don't you take a break? Breath in some fresh air. The basement is pretty damp.");
+ close;
+ }
+
+ setq2 ShipQuests_Peter, 0;
+ setq3 ShipQuests_Peter, .@INSTID;
+
+ // It'll be self-destroyed when time runs out (3 minutes)
+ instance_set_timeout(180, 180, .@INSTID);
+ instance_init(.@INSTID);
+
+ // Save in a less reliable way the challenge you took
+ if (@peter == 2) {
+ @peter=2;
+ @pt_mob=Tortuga;
+ } else if (@peter == 3) {
+ @peter=4;
+ @pt_mob=Ratto;
+ } else if (@peter == 4) {
+ @peter=8;
+ @pt_mob=Croc;
+ } else {
+ @peter=0;
+ @pt_mob=Ratto;
+ }
+
+ warp @MAP_NAME$, 48, 28;
+ // Control how much time you have left
+ addtimer(120000, "Peter::OnLowTime");
+ addtimer(140000, "Peter::OnTimeout");
+
+ // Spawn the Monsters
+ areamonster @MAP_NAME$, 23, 19, 57, 40, strmobinfo(1, @pt_mob), @pt_mob, 1, "RattosControl::OnRatto1Death";
+ areamonster @MAP_NAME$, 23, 19, 57, 40, strmobinfo(1, @pt_mob), @pt_mob, 1, "RattosControl::OnRatto2Death";
+ areamonster @MAP_NAME$, 23, 19, 57, 40, strmobinfo(1, @pt_mob), @pt_mob, 1, "RattosControl::OnRatto3Death";
+ areamonster @MAP_NAME$, 23, 19, 57, 40, strmobinfo(1, @pt_mob), @pt_mob, 1, "RattosControl::OnRatto4Death";
+
+ dispbottom l("Okay, you can start!");
+ closeclientdialog;
+ close;
+
+// TODO: This is very reckless, instance_destroy() could possibly affect others
+// If you agree with me, we can force player to wait until instance expire on its
+// own (3 minutes after start) instead of allowing immediate retry. That's safer,
+// and code will end up looking like Mundane (exploiting attach_map failures)
+
+// (Or if you are set in disregarding this, just uncomment instance_destroy.)
+// (Don't blame me if server SIGSEGV's because that, though)
+OnTimeout:
+ if (!(getmap() ~= "000-2-2") && !(getmap() ~= "nard*"))
+ end;
+ warp "000-2-1", 72, 36;
+ .@q3 = getq3(ShipQuests_Peter);
+ //instance_destroy(.@q3);
+ setq2 ShipQuests_Peter, 0;
+ setq3 ShipQuests_Peter, -1;
+ mesn;
+ mesq l("Hey! Be careful. You can't stay in this basement for so long, you're going to get sick. Come outside and take a break, maybe you can try again later.");
+ close;
+
+// This is called by npc/000-2-2/ratto.txt and completes the quest
+// Just like OnReturnFail and OnTimeout, this recklessy destroys the instance
+// It's not _buggy_, it is just reckless. I would like a setting to restrict it
+// to destroy only instances owned by the char, or to destroy by name :p
+OnDone:
+ warp "000-2-1", 72, 36;
+ .@q3 = getq3(ShipQuests_Peter);
+ //instance_destroy(.@q3);
+ if (@peter)
+ setq ShipQuests_Peter, getq(ShipQuests_Peter)|@peter, 0, -1;
+
+ .@q = getq(ShipQuests_Peter);
+ mesn;
+ mesq l("Good job!") + " " + l("Here's your reward!");
+
+
+ // Before handling the rewards, we should be sure we'll handle daily loop.
+ // You're already in daily phase if @peter is zero.
+ // PS. This is not exactly "daily", this is actually a forced 24-hours wait.
+ if (!@peter) {
+ PETER_TIME=gettimetick(2)+24*60*60;
+ @peter=1; // This allows you to get 32 EXP from daily repeat. Tweak as needed.
+ }
+
+ // You get some EXP based on difficulty taken
+ getexp @peter*32, @peter;
+
+ // We don't need @peter anymore, so reuse it to give you GP rewards
+ switch (@peter) {
+ case 2: @peter=500; break;
+ case 4: @peter=1000; break;
+ case 8: @peter=1500; break;
+ default: @peter=750; break;
+ }
+
+ Zeny += @peter;
+ message strcharinfo(0), l("You receive @@ E!", @peter);
+
+ // Some cleanup. Shouldn't cause bugs but it's absence causes a ugly behavior.
+ deltimer("Peter::OnLowTime");
+ deltimer("Peter::OnTimeout");
+ @peter=0;
+ close;
+
+
+OnInit:
+ .distance = 3;
+ end;
+}
diff --git a/npc/000-2-1/q'onan.txt b/npc/000-2-1/q'onan.txt
new file mode 100644
index 00000000..c5ef0951
--- /dev/null
+++ b/npc/000-2-1/q'onan.txt
@@ -0,0 +1,15 @@
+// Evol scripts.
+// Authors:
+// Alige
+// Vasily_Makarov
+// Description:
+// Sleeping and snoring NPC.
+
+000-2-1,53,38,0 script Q'Onan#000-2-1 NPC_ORC_SAILOR,{
+ asleep;
+ close;
+
+OnInit:
+ .distance = 2;
+ end;
+}
diff --git a/npc/000-2-1/story_save.txt b/npc/000-2-1/story_save.txt
new file mode 100644
index 00000000..68aacf60
--- /dev/null
+++ b/npc/000-2-1/story_save.txt
@@ -0,0 +1,30 @@
+// Evol scripts.
+// Author:
+// Reid
+// Description:
+// Scritpted save locations in 000-2-1 map.
+
+000-2-1,50,38,0 script #name3 NPC_FINAL_POINT,{
+ .@q_nard = getq(ShipQuests_Nard);
+ .@q_narr = getq(General_Narrator);
+
+ if(.@q_nard == 5 && .@q_narr < 1)
+ {
+OnClick:
+ narrator S_LAST_NEXT,
+ l("You lie in the bed."),
+ l("Your head is suddently heavy, your eyes are closing..."),
+ l("You fell asleep.");
+
+ warp "000-0-1", 26, 28;
+ }
+ else
+ {
+ savepointparticle "000-2-1", 50, 38;
+ }
+ close;
+
+OnInit:
+ .distance = 2;
+ end;
+}