summaryrefslogtreecommitdiff
path: root/npc
diff options
context:
space:
mode:
Diffstat (limited to 'npc')
-rw-r--r--npc/000-2-0/julia.txt505
-rw-r--r--npc/commands/debug-quest.txt166
-rw-r--r--npc/commands/debug.txt2
-rw-r--r--npc/functions/quest-debug/000-ShipQuests_Julia.txt26
-rw-r--r--npc/functions/quest-debug/001-ShipQuests_Arpan.txt27
-rw-r--r--npc/functions/quest-debug/002-ShipQuests_Alige.txt27
-rw-r--r--npc/functions/quest-debug/003-ShipQuests_Peter.txt30
-rw-r--r--npc/functions/quest-debug/004-ShipQuests_Nard.txt38
-rw-r--r--npc/functions/quest-debug/005-ShipQuests_Knife.txt25
-rw-r--r--npc/functions/quest-debug/006-ShipQuests_ArpanMoney.txt26
-rw-r--r--npc/functions/quest-debug/007-ShipQuests_Door.txt25
-rw-r--r--npc/functions/quest-debug/008-ShipQuests_Couwan.txt26
-rw-r--r--npc/functions/quest-debug/009-ShipQuests_TreasureChest.txt25
-rw-r--r--npc/functions/quest-debug/010-ShipQuests_Ale.txt25
-rw-r--r--npc/functions/quest-debug/011-ShipQuests_Astapolos.txt25
-rw-r--r--npc/functions/quest-debug/012-ShipQuests_Gulukan.txt25
-rw-r--r--npc/functions/quest-debug/013-ShipQuests_Jalad.txt25
-rw-r--r--npc/functions/quest-debug/014-ShipQuests_QMuller.txt25
-rw-r--r--npc/functions/quest-debug/015-ShipQuests_Tibbo.txt25
-rw-r--r--npc/functions/quest-debug/016-ShipQuests_Gugli.txt46
-rw-r--r--npc/functions/quest-debug/017-ShipQuests_ChefGado.txt30
-rw-r--r--npc/functions/quest-debug/018-General_Cookies.txt25
-rw-r--r--npc/functions/quest-debug/019-ArtisQuests_LazyBrother.txt28
-rw-r--r--npc/functions/quest-debug/020-ArtisQuests_Urchin.txt26
-rw-r--r--npc/functions/quest-debug/021-ArtisQuests_CatchPiou.txt26
-rw-r--r--npc/functions/quest-debug/022-ArtisQuests_Fishman.txt26
-rw-r--r--npc/functions/quest-debug/023-ArtisQuests_QOnan.txt27
-rw-r--r--npc/functions/quest-debug/026-General_Rumly.txt27
-rw-r--r--npc/functions/quest-debug/027-ArtisQuests_Enora.txt35
-rw-r--r--npc/functions/quest-debug/028-General_Narrator.txt25
-rw-r--r--npc/functions/quest-debug/029-ArtisQuests_Fexil.txt27
-rw-r--r--npc/functions/quest-debug/030-ArtisQuests_Lloyd.txt25
-rw-r--r--npc/functions/quest-debug/031-General_Janus.txt31
-rw-r--r--npc/functions/quest-debug/032-ArtisQuests_MonaDad.txt25
-rw-r--r--npc/functions/quest-debug/functions.txt73
-rw-r--r--npc/scripts.conf36
36 files changed, 1398 insertions, 238 deletions
diff --git a/npc/000-2-0/julia.txt b/npc/000-2-0/julia.txt
index 3be81c53..e17d93da 100644
--- a/npc/000-2-0/julia.txt
+++ b/npc/000-2-0/julia.txt
@@ -33,6 +33,266 @@
// 25 Reward taken from the box.
000-2-0,27,24,0 script Julia NPC_JULIA,2,10,{
+
+ function ynMenu {
+ if (select(l("Yes, I do."), l("No, none.")) == 1) {
+ return;
+ }
+ closedialog;
+ }
+
+ function poisonJulia {
+ mes "";
+ mesn;
+ mesq l("Seems yummy! Let me taste it!");
+ next;
+ mesq l("Hmmm, hm... *cough*, *cough*, *burp*, *cough*. What... What is that?!... *cough*, *burp*... Damn Gado... *cough*");
+ if (countitem(PoisonedDish) > 0) delitem PoisonedDish, 1;
+ setq ShipQuests_ChefGado, 3;
+ close;
+ }
+
+ function gotoSleep {
+ speech 5,
+ l("You already did enough for us, follow Nard's advice and get some rest."),
+ 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!"),
+ l("Do you have any other questions for me?");
+ ynMenu;
+ return;
+ }
+
+ function heardRumors {
+ mes "";
+ mesn;
+ mesq l("You shouldn't believe every tale drunken sailors tell you.");
+ next;
+
+ select
+ l("Let's say the person who told me about that is well respected on this ship and never drunk.");
+
+ mes "";
+ mesn;
+ mesq l("Hahaha! All sailors aboard this ship are always drunk... Well... Except... Wait, what?! Nard told you?!");
+ next;
+ mesq l("Doesn't he like the way I'm taking care of his ship? Everything is clean and tidy with me, rightful lieutenant of La Johanne.");
+ next;
+ mesq l("I give tasks to every single sailor, all day long. That should make him happy!");
+ next;
+
+ select
+ l("Well... I don't think it is the best way to rule a ship. Think about it."),
+ l("In fact, everything seems to work perfectly under your guidance. Nard has made the right choice.");
+
+ if (@menu == 1)
+ {
+ closedialog;
+ end;
+ }
+
+ mes "";
+ mesn;
+ mesq l("I'm glad you're on my side.");
+ next;
+ mesq l("Take this money as a reward for your nice words.");
+
+ setq ShipQuests_ChefGado, 6;
+ Zeny += 100;
+ message strcharinfo(0), l("You receive @@ E!", 100);
+ getexp 8, 0;
+ close;
+ }
+
+ function gotRegrets {
+ mes "";
+ mesn;
+ mesq l("Why? And who should you bring it back to?");
+ next;
+
+ select
+ l("Ehm... He was really upset because of some past stories.");
+
+ mes "";
+ mesn;
+ mesq l("Gado! That coward lives in the past, I will ask Nard to punish him, again!");
+ next;
+ mesq l("Take this money for your wise choice. But do not try it again. The open sea has been merciful with you once... Do not further tempt the fates!");
+
+ setq ShipQuests_ChefGado, 5;
+ Zeny += 200;
+ message strcharinfo(0), l("You receive @@ E!", 200);
+ getexp 15, 0;
+ close;
+ }
+
+ function basicSkill {
+ mes "";
+ mesn;
+ mesq l("Let me check into it...");
+ next;
+ adddefaultskills;
+ mesq l("Here you go, everything is fixed.");
+ emotion E_HAPPY;
+ next;
+ mesq l("Do you have any other questions for me?");
+ next;
+ ynMenu;
+ return;
+ }
+
+ function chooseLang {
+ mes "";
+ mesn;
+ mesq l("Of course! Tell me which language you speak and I will change the note on the ship board list.");
+ next;
+
+ select
+ menuimage("flags/en", l("I speak English.") + " (English)"),
+ menuimage("flags/fr", l("I speak French.") + " (Français)"),
+ menuimage("flags/ru", l("I speak Russian.") + " (Русский)"),
+ menuimage("flags/es", l("I speak Spanish.") + " (Español)"),
+ menuimage("flags/pt_BR", l("I speak Portuguese.") + " (Português)"),
+ menuimage("flags/de", l("I speak German.") + " (Deutsch)"),
+ menuimage("flags/vls", l("I speak Flemish.") + " (Vlaams)"),
+ menuimage("flags/pl", l("I speak Polish.") + " (Polski)"),
+ menuimage("flags/it", l("I speak Italian.") + " (Italiano)"),
+ menuimage("flags/nl_BE", l("I speak Dutch.") + " (Nederlands)"),
+ menuimage("flags/ca", l("I speak Catalan.") + " (Català)"),
+ getarg(0, "");
+
+ .@lang = @menu-1;
+ if (.@lang < 0 || .@lang > 10)
+ {
+ mes "";
+ mesn;
+ mesq l("No problem, do you have any other questions for me?");
+ next;
+ ynMenu;
+ return;
+ }
+ Lang = .@lang;
+
+ mes "";
+ mesn;
+ mesq l("Ok, done.");
+
+ if (getq(ShipQuests_Julia) == 2)
+ {
+ next;
+ mesq l("Do you have any other questions for me?");
+ next;
+ ynMenu;
+ return;
+ }
+
+ next;
+ mesq l("I'm sure that you've got some questions for me, feel free to ask them, but first I need to tell you the rules of proper social conduct on board.");
+
+ mesq l("Here they are.");
+ next;
+
+ narrator 0x4,
+ l("There is a paper with some rules written on it."),
+ l("1. ##BDo not bot##b, this means you are not allowed to perform any AFK (away from keyboard) activity, apart from standing idle."),
+ l("2. ##BDo not use offensive/rude language##b in the chats or in your character(s) name(s)."),
+ l("3. ##BDo not spam/flood other players.##b This includes chat spam and spam by trade requests."),
+ l("4. ##BSpeak only English in public areas.##b You can speak whatever language you want through whispers or whenever everyone in the area can speak said language."),
+ l("5. ##BDo not beg others##b for money, items or favours of any kind. If you want to ask for something, do it politely and only once. Try not to annoy other players."),
+ l("6. ##BFollow the [@@http://wiki.evolonline.org/rules/esc|ESC@@]##b (Evol Social Convention)."),
+ l("7. ##BDo not multibox.##b You are not allowed to engage in combat while controlling more than one character at a time.");
+
+ mesn;
+ mesq l("Oh, and I almost forgot! Do not give the password of your room to anybody! I am the only one who has the other key and I won't ask for yours so keep it secret and try not to use the same password for any other room in the future.");
+ next;
+ mesq l("If you want to read this page again, there is a copy up on the left wall.");
+ next;
+ mesq l("I think I'm done with that now. Do you have any questions?");
+ next;
+
+ setq ShipQuests_Julia, 2;
+ return;
+ }
+
+ function whereAmI {
+ mes "";
+ mesn;
+ mesq l("You're on a ship, we're on our way to the commercial capital of Artis.");
+ next;
+ mesq l("We should be there in a few days, once we arrive, I will warn the Legion of Aemil about what happened, I'm sure they can help.");
+ next;
+ mesq l("But for now, you can relax on the ship, or visit the island we're docked at! Its a small island, but a good place to get some exercise and stretch your legs.");
+ next;
+ mesq l("Do you have any other questions for me?");
+ next;
+ ynMenu;
+ return;
+ }
+
+ function whatHappened {
+ mes "";
+ mesn;
+ mesq l("We thought that you could help us understand this, all we know is that we found you cast in the sea, adrift on your raft.");
+ next;
+ mesq lg("You were in bad shape, you should be happy we found you before the sea killed you.");
+ next;
+ mesq l("Oh, and there was this inscription on your raft. It represents the Legion of Aemil, the largest and biggest guild of the whole new world. Does that make you remember anything, anything at all?");
+ next;
+
+ select
+ l("Sorry, but I can't tell you anything about that."),
+ l("Nothing, sorry.");
+
+ mes "";
+ mesn;
+ mesq l("No problem, do you have any other questions for me?");
+ next;
+ ynMenu;
+ return;
+ }
+
+ function readRules {
+ mes "";
+ mesn;
+ mesq l("Of course, they are on the left wall, go have a look at them.");
+ next;
+ mesq l("Do you have any other questions for me?");
+ next;
+ ynMenu;
+ return;
+ }
+
+ function mainMenu {
+ do
+ {
+ menuint
+ rif(debug, menuaction(l("debug"))), 11,
+ rif(.@q3 == 5 && .@q4 < 1, l("What can I do now?")), 1,
+ rif(.@q3 == 3 && .@q2 == 0, l("I heard rumors about some old hostilities between you and Gado. Are they true?")), 2,
+ rif(.@q2 == 2 && countitem(PoisonedDish), l("Well... No wait, I have something for you but you shouldn't eat it... I'm taking it back to the kitchen.")), 3,
+ rif(.@q2 == 2 && countitem(PoisonedDish), l("I have brought you a tasty present for your delicate mouth.")), 4,
+ rif(getskilllv(NV_BASIC) < 6, l("Something is wrong with me, I can't smile nor sit.")), 5,
+ lg("I made a mistake, I would like to change my language."), 6,
+ l("Could you explain to me where I am?"), 7,
+ l("What happened to me?"), 8,
+ l("Can I read these rules again?"), 9,
+ l("Nothing, sorry."), 10;
+
+ switch (@menuret)
+ {
+ case 1: gotoSleep; break;
+ case 2: heardRumors; break;
+ case 3: gotRegrets; break;
+ case 4: poisonJulia; break;
+ case 5: basicSkill; break;
+ case 6: chooseLang .@s$; break;
+ case 7: whereAmI; break;
+ case 8: whatHappened; break;
+ case 9: readRules; break;
+ case 10: closedialog; end;
+ case 11: QuestDebug0; closedialog; end;
+ }
+ } while (1);
+ }
+
mesn;
mesq lg("Hello dear!");
next;
@@ -43,21 +303,12 @@
.@q3 = getq(ShipQuests_Nard);
.@q4 = getq(General_Narrator);
.@s$ = l("I don't want to change my language, sorry.");
+ mainMenu;
+
+OnTouch:
+ .@q = getq(ShipQuests_Julia);
+ if (.@q > 1) end;
-L_Menu:
- menu
- rif(.@q3 == 5 && .@q4 < 1, l("What can I do now?")), L_GotoSleep,
- rif(.@q3 == 3 && .@q2 == 0, l("I heard rumors about some old hostilities between you and Gado. Are they true?")), L_Rumors,
- rif(.@q2 == 2 && countitem(PoisonedDish), l("Well... No wait, I have something for you but you shouldn't eat it... I'm taking it back to the kitchen.")), L_Regret,
- rif(.@q2 == 2 && countitem(PoisonedDish), l("I have brought you a tasty present for your delicate mouth.")), L_PoisonJulia,
- rif(getskilllv(NV_BASIC) < 6, l("Something is wrong with me, I can't smile nor sit.")), L_BasicSkill,
- lg("I made a mistake, I would like to change my language."), L_ChooseLang,
- l("Could you explain to me where I am?"), L_WhereIam,
- l("What happened to me?"), L_What,
- l("Can I read these rules again?"), L_Rules,
- l("Nothing, sorry."), L_Quit;
-
-L_First:
checkclientversion;
mesn;
@@ -69,231 +320,11 @@ L_First:
next;
mesq lg("Could I ask you what your native language is? A sailor told me you're russian, but another one told me you're french... I'm a bit lost. I will register you on the ship boarding list just after that.");
next;
- .@s$ = "";
- goto L_ChooseLang;
-
- L_ChooseLang:
- mes "";
- mesn;
- mesq l("Of course! Tell me which language you speak and I will change the note on the ship board list.");
- next;
-
- menu
- menuimage("flags/en", l("I speak English.") + " (English)"), -,
- menuimage("flags/fr", l("I speak French.") + " (Français)"), -,
- menuimage("flags/ru", l("I speak Russian.") + " (Русский)"), -,
- menuimage("flags/es", l("I speak Spanish.") + " (Español)"), -,
- menuimage("flags/pt_BR", l("I speak Portuguese.") + " (Português)"), -,
- menuimage("flags/de", l("I speak German.") + " (Deutsch)"), -,
- menuimage("flags/vls", l("I speak Flemish.") + " (Vlaams)"), -,
- menuimage("flags/pl", l("I speak Polish.") + " (Polski)"), -,
- menuimage("flags/it", l("I speak Italian.") + " (Italiano)"), -,
- menuimage("flags/nl_BE", l("I speak Dutch.") + " (Nederlands)"), -,
- menuimage("flags/ca", l("I speak Catalan.") + " (Català)"), -,
- .@s$, L_NoChanges;
- .@lang = @menu-1;
- if (.@lang < 0 || .@lang > 10) close;
- Lang = .@lang;
-
- mes "";
- mesn;
- mesq l("Ok, done.");
-
- .@q = getq(ShipQuests_Julia);
- if (.@q == 2) goto L_NoRules;
-
- next;
- mesq l("I'm sure that you've got some questions for me, feel free to ask them, but first I need to tell you the rules of proper social conduct on board.");
-
- mesq l("Here they are.");
- next;
-
- mesn "Narrator";
- mes col(l("There is a paper with some rules written on it."), 9);
- next;
- mesq col(l("1. ##BDo not bot##b, this means you are not allowed to perform any AFK (away from keyboard) activity, apart from standing idle."), 9);
- next;
- mesq col(l("2. ##BDo not use offensive/rude language##b in the chats or in your character(s) name(s)."), 9);
- next;
- mesq col(l("3. ##BDo not spam/flood other players.##b This includes chat spam and spam by trade requests."), 9);
- next;
- mesq col(l("4. ##BSpeak only English in public areas.##b You can speak whatever language you want through whispers or whenever everyone in the area can speak said language."), 9);
- next;
- mesq col(l("5. ##BDo not beg others##b for money, items or favours of any kind. If you want to ask for something, do it politely and only once. Try not to annoy other players."), 9);
- next;
- mesq col(l("6. ##BFollow the [@@http://wiki.evolonline.org/rules/esc|ESC@@]##b (Evol Social Convention)."), 9);
- next;
- mesq col(l("7. ##BDo not multibox.##b You are not allowed to engage in combat while controlling more than one character at a time."), 9);
- next;
-
- mesn;
- mesq l("Oh, and I almost forgot! Do not give the password of your room to anybody! I am the only one who has the other key and I won't ask for yours so keep it secret and try not to use the same password for any other room in the future.");
- next;
- mesq l("If you want to read this page again, there is a copy up on the left wall.");
- next;
- mesq l("I think I'm done with that now. Do you have any questions?");
- next;
-
- setq ShipQuests_Julia, 2;
- goto L_Menu;
-
-L_NoRules:
- next;
- mesq l("Do you have any other questions for me?");
- next;
-
- goto L_YNMenu;
-
-L_NoChanges:
- mes "";
- mesn;
- mesq l("No problem, do you have any other questions for me?");
- next;
-
-L_YNMenu:
- menu
- l("Yes, I do."), L_Menu,
- l("No, none."), L_Quit;
-
-L_WhereIam:
- mes "";
- mesn;
- mesq l("You're on a ship, we're on our way to the commercial capital of Artis.");
- next;
- mesq l("We should be there in a few days, once we arrive, I will warn the Legion of Aemil about what happened, I'm sure they can help.");
- next;
- mesq l("But for now, you can relax on the ship, or visit the island we're docked at! Its a small island, but a good place to get some exercise and stretch your legs.");
- next;
- mesq l("Do you have any other questions for me?");
- next;
-
- goto L_YNMenu;
-
-L_What:
- mes "";
- mesn;
- mesq l("We thought that you could help us understand this, all we know is that we found you cast in the sea, adrift on your raft.");
- next;
- mesq lg("You were in bad shape, you should be happy we found you before the sea killed you.");
- next;
- mesq l("Oh, and there was this inscription on your raft. It represents the Legion of Aemil, the largest and biggest guild of the whole new world. Does that make you remember anything, anything at all?");
- next;
-
- menu
- l("Sorry, but I can't tell you anything about that."), L_NoChanges,
- l("Nothing, sorry."), L_NoChanges;
-
-L_Rules:
- mes "";
- mesn;
- mesq l("Of course, they are on the left wall, go have a look at them.");
- next;
- mesq l("Do you have any other questions for me?");
- next;
-
- goto L_YNMenu;
-
-OnTouch:
- .@q = getq(ShipQuests_Julia);
- if (.@q == 0 || .@q == 1) goto L_First;
-
- close;
-
-L_PoisonJulia:
- mes "";
- mesn;
- mesq l("Seems yummy! Let me taste it!");
- next;
- mesq l("Hmmm, hm... *cough*, *cough*, *burp*, *cough*. What... What is that?!... *cough*, *burp*... Damn Gado... *cough*");
- if (countitem(PoisonedDish) > 0) delitem PoisonedDish, 1;
- setq ShipQuests_ChefGado, 3;
-
- close;
-
-L_Regret:
- mes "";
- mesn;
- mesq l("Why? And who should you bring it back to?");
- next;
-
- select
- l("Ehm... He was really upset because of some past stories.");
-
- mes "";
- mesn;
- mesq l("Gado! That coward lives in the past, I will ask Nard to punish him, again!");
- next;
- mesq l("Take this money for your wise choice. But do not try it again. The open sea has been merciful with you once... Do not further tempt the fates!");
-
- setq ShipQuests_ChefGado, 5;
- Zeny = Zeny + 200;
- message strcharinfo(0), l("You receive @@ E!", 200);
- getexp 15, 0;
-
- close;
-
-L_Rumors:
- mes "";
- mesn;
- mesq l("You shouldn't believe every tale drunken sailors tell you.");
- next;
-
- select
- l("Let's say the person who told me about that is well respected on this ship and never drunk.");
-
- mes "";
- mesn;
- mesq l("Hahaha! All sailors aboard this ship are always drunk... Well... Except... Wait, what?! Nard told you?!");
- next;
- mesq l("Doesn't he like the way I'm taking care of his ship? Everything is clean and tidy with me, rightful lieutenant of La Johanne.");
- next;
- mesq l("I give tasks to every single sailor, all day long. That should make him happy!");
- next;
-
- menu
- l("Well... I don't think it is the best way to rule a ship. Think about it."), L_Quit,
- l("In fact, everything seems to work perfectly under your guidance. Nard has made the right choice."), -;
-
- mes "";
- mesn;
- mesq l("I'm glad you're on my side.");
- next;
- mesq l("Take this money as a reward for your nice words.");
-
- setq ShipQuests_ChefGado, 6;
- Zeny = Zeny + 100;
- message strcharinfo(0), l("You receive @@ E!", 100);
- getexp 8, 0;
-
- close;
-
-L_BasicSkill:
- mes "";
- mesn;
- mesq l("Let me check into it...");
- next;
- adddefaultskills;
- mesq l("Here you go, everything is fixed.");
- emotion E_HAPPY;
- next;
- mesq l("Do you have any other questions for me?");
- next;
-
- goto L_YNMenu;
-
-L_GotoSleep:
- speech 5,
- l("You already did enough for us, follow Nard's advice and get some rest."),
- 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!"),
- l("Do you have any other questions for me?");
-
- goto L_YNMenu;
+ chooseLang "";
+ mainMenu;
+ end;
OnInit:
.sex = G_FEMALE;
.distance = 10;
- end;
-
-L_Quit:
- goodbye;
}
diff --git a/npc/commands/debug-quest.txt b/npc/commands/debug-quest.txt
new file mode 100644
index 00000000..a7cb9fab
--- /dev/null
+++ b/npc/commands/debug-quest.txt
@@ -0,0 +1,166 @@
+function script GlobalQuestDebug {
+
+ function qDebugShip {
+ function qDebugGugli {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug") + " - " + l("Prologue") + " - Gugli";
+ mes l("This menu gives access to quest debug menus for @@ quest subquests.", "Gugli");
+ next;
+ mes l("Please select a quest:");
+
+ menuint
+ menuimage("actions/back", l("Go back")), 32766,
+ l("Gugli (main quest)"), 16,
+ "Ale", 10,
+ "Astapolos", 11,
+ "Gulukan", 12,
+ "Jalad", 13,
+ "QMuller", 14,
+ "Tibbo", 15,
+ menuimage("actions/exit", l("Close")), 32767;
+
+ switch (@menuret)
+ {
+ case 32766: return;
+ case 32767: closedialog; end;
+ default: callfunc "QuestDebug" + @menuret;
+ }
+ } while (1);
+ }
+
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug") + " - " + l("Prologue");
+ mes l("This menu gives access to quest debug menus for @@ quests.", l("Prologue"));
+ next;
+ mes l("Please select a quest:");
+
+ menuint
+ menuimage("actions/back", l("Go back")), 32766,
+ "Julia", 0,
+ "Arpan", 1,
+ "Alige", 2,
+ "Peter", 3,
+ "Nard", 4,
+ l("Knife"), 5,
+ l("Money"), 6,
+ l("Door"), 7,
+ "Couwan", 8,
+ l("Treasure Chest"), 9,
+ "Gugli", 16,
+ "Gado", 17,
+ menuimage("actions/exit", l("Close")), 32767;
+
+ switch (@menuret)
+ {
+ case 16: qDebugGugli; break;
+ case 32766: return;
+ case 32767: closedialog; end;
+ default: callfunc "QuestDebug" + @menuret;
+ }
+ } while (1);
+ }
+
+ function qDebugArtis {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug") + " - " + l("Artis");
+ mes l("This menu gives access to quest debug menus for @@ quests.", "Artis");
+ next;
+ mes l("Please select a quest:");
+
+ menuint
+ menuimage("actions/back", l("Go back")), 32766,
+ l("Lazy Brother"), 19,
+ l("Urchin"), 20,
+ l("Catching a piou"), 21,
+ "Eugene (" + l("fisherman") + ")", 22,
+ "Q'Onan", 23,
+ "Enora", 27,
+ "Fexil", 29,
+ "Lloyd", 30,
+ l("Mona's dad"), 32,
+ menuimage("actions/exit", l("Close")), 32767;
+
+ switch (@menuret)
+ {
+ case 32766: return;
+ case 32767: closedialog; end;
+ default: callfunc "QuestDebug" + @menuret;
+ }
+ } while (1);
+ }
+
+ function qDebugGeneral {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug") + " - " + l("Other");
+ mes l("This menu gives access to quest debug menus for @@ quests.", strtolower(l("Other")));
+ next;
+ mes l("Please select a quest:");
+
+ menuint
+ menuimage("actions/back", l("Go back")), 32766,
+ l("Cookies"), 18,
+ "Rumly", 26,
+ l("Narrator"), 28,
+ "Janus", 31,
+ menuimage("actions/exit", l("Close")), 32767;
+
+ switch (@menuret)
+ {
+ case 32766: return;
+ case 32767: closedialog; end;
+ default: callfunc "QuestDebug" + @menuret;
+ }
+ } while (1);
+ }
+
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes l("This menu gives access to all quest debug menus.");
+ next;
+ mes l("Please select a category:");
+
+ select
+ l("Prologue"),
+ "Artis",
+ l("Other"),
+ rif(getarg(0,0), menuimage("actions/back", l("Return to Debug menu"))),
+ menuimage("actions/exit", l("Close"));
+
+ switch (@menu)
+ {
+ case 1: qDebugShip; break;
+ case 2: qDebugArtis; break;
+ case 3: qDebugGeneral; break;
+ case 4: return;
+ default: closedialog; end;
+ }
+ } while (1);
+}
+
+
+
+- script @qdebug 32767,{
+ end;
+
+OnCall:
+ if (!debug && getgroupid() < 1)
+ {
+ end;
+ }
+ GlobalQuestDebug;
+ closedialog;
+ end;
+
+OnInit:
+ bindatcmd "qdebug", "@qdebug::OnCall", 0, 99, 0;
+}
diff --git a/npc/commands/debug.txt b/npc/commands/debug.txt
index 5af689b2..1a5cdec9 100644
--- a/npc/commands/debug.txt
+++ b/npc/commands/debug.txt
@@ -116,7 +116,7 @@ function script GlobalDebugMenu {
case 2: changeStats; break;
case 3: GlobalSkillDebug .@c; break;
case 4: BarberDebug .@c; break;
- //case 5: changeQuests; break;
+ case 5: GlobalQuestDebug .@c; break;
case 6: DebugPresets "m"; break;
case 7: resetAll; break;
case 8: return;
diff --git a/npc/functions/quest-debug/000-ShipQuests_Julia.txt b/npc/functions/quest-debug/000-ShipQuests_Julia.txt
new file mode 100644
index 00000000..00e0120a
--- /dev/null
+++ b/npc/functions/quest-debug/000-ShipQuests_Julia.txt
@@ -0,0 +1,26 @@
+// Julia quest debug
+// Authors:
+// gumi
+
+function script QuestDebug0 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ShipQuests_Julia";
+ mes "---";
+ mes l("Quest state: @@", getq(ShipQuests_Julia));
+ next;
+
+ GenericQuestDebug ShipQuests_Julia,
+ l("Does not have the quest"), 0,
+ l("Got the quest"), 1,
+ l("Completed"), 2;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/001-ShipQuests_Arpan.txt b/npc/functions/quest-debug/001-ShipQuests_Arpan.txt
new file mode 100644
index 00000000..777d58b4
--- /dev/null
+++ b/npc/functions/quest-debug/001-ShipQuests_Arpan.txt
@@ -0,0 +1,27 @@
+// Arpan quest debug
+// Authors:
+// gumi
+
+function script QuestDebug1 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ShipQuests_Arpan";
+ mes "---";
+ mes l("Quest state: @@", getq(ShipQuests_Arpan));
+ next;
+
+ GenericQuestDebug ShipQuests_Arpan,
+ l("Arpan is waiting for you"), 0,
+ l("Arpan told you to open the chest"), 1,
+ l("You opened the chest"), 2,
+ l("Completed"), 3;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/002-ShipQuests_Alige.txt b/npc/functions/quest-debug/002-ShipQuests_Alige.txt
new file mode 100644
index 00000000..abbd506d
--- /dev/null
+++ b/npc/functions/quest-debug/002-ShipQuests_Alige.txt
@@ -0,0 +1,27 @@
+// Alige quest debug
+// Authors:
+// gumi
+
+function script QuestDebug2 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ShipQuests_Alige";
+ mes "---";
+ mes l("Quest state: @@", getq(ShipQuests_Alige));
+ next;
+
+ GenericQuestDebug ShipQuests_Alige,
+ l("Does not have the quest"), 0,
+ l("First encounter"), 1,
+ l("Alige asks for food"), 2,
+ l("Completed"), 3;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/003-ShipQuests_Peter.txt b/npc/functions/quest-debug/003-ShipQuests_Peter.txt
new file mode 100644
index 00000000..f5d87abb
--- /dev/null
+++ b/npc/functions/quest-debug/003-ShipQuests_Peter.txt
@@ -0,0 +1,30 @@
+// Peter quest debug
+// Authors:
+// gumi
+
+function script QuestDebug3 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ShipQuests_Peter";
+ mes "---";
+ mes l("Quest state: @@", getq(ShipQuests_Peter));
+ next;
+
+ GenericQuestDebug ShipQuests_Peter,
+ l("Does not have the quest"), 0,
+ l("Peter needs help"), 6,
+ l("Peter asks to kill rattos"), 1,
+ l("Killed rattos"), 2,
+ l("Got no reward"), 3,
+ l("Peter asks to kill rattos again"), 4,
+ l("Peter gave reward"), 5;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/004-ShipQuests_Nard.txt b/npc/functions/quest-debug/004-ShipQuests_Nard.txt
new file mode 100644
index 00000000..3431fd23
--- /dev/null
+++ b/npc/functions/quest-debug/004-ShipQuests_Nard.txt
@@ -0,0 +1,38 @@
+// Nard quest debug
+// Authors:
+// gumi
+
+function script QuestDebug4 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ShipQuests_Nard";
+ mes "---";
+ mes l("Quest state: @@", getq(ShipQuests_Nard));
+ mes "---";
+ mes l("Subquests:");
+ mes "ShipQuests_Gugli: " + getq(ShipQuests_Gugli);
+ mes "ShipQuests_ChefGado: " + getq(ShipQuests_ChefGado);
+ next;
+
+ GenericQuestDebug ShipQuests_Nard,
+ l("Does not have the quest"), 0,
+ l("Nard asks to help crew"), 1,
+ menuimage("actions/manage", l("Debug Gugli quest")), 32700,
+ l("Completed Gugli's task"), 2,
+ l("Nard asks to solve conflict"), 3,
+ menuimage("actions/manage", l("Debug Gado quest")), 32701,
+ l("Solved conflict"), 4,
+ l("Official crew member"), 5,
+ l("Talked to narrator"), 6;
+
+ switch (@menuret)
+ {
+ case 32700: callfunc "QuestDebug16"; break;
+ case 32701: callfunc "QuestDebug17"; break;
+ case 32766: return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/005-ShipQuests_Knife.txt b/npc/functions/quest-debug/005-ShipQuests_Knife.txt
new file mode 100644
index 00000000..f192a126
--- /dev/null
+++ b/npc/functions/quest-debug/005-ShipQuests_Knife.txt
@@ -0,0 +1,25 @@
+// Knife quest debug
+// Authors:
+// gumi
+
+function script QuestDebug5 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ShipQuests_Knife";
+ mes "---";
+ mes l("Quest state: @@", getq(ShipQuests_Knife));
+ next;
+
+ GenericQuestDebug ShipQuests_Knife,
+ l("Does not have the quest"), 0,
+ l("Got the knife"), 1;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/006-ShipQuests_ArpanMoney.txt b/npc/functions/quest-debug/006-ShipQuests_ArpanMoney.txt
new file mode 100644
index 00000000..0e00d0d9
--- /dev/null
+++ b/npc/functions/quest-debug/006-ShipQuests_ArpanMoney.txt
@@ -0,0 +1,26 @@
+// Money quest debug
+// Authors:
+// gumi
+
+function script QuestDebug6 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ShipQuests_ArpanMoney";
+ mes "---";
+ mes l("Quest state: @@", getq(ShipQuests_ArpanMoney));
+ next;
+
+ GenericQuestDebug ShipQuests_ArpanMoney,
+ l("Does not have the quest"), 0,
+ l("Elmo told about money"), 1,
+ l("Arpan gave money"), 2;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/007-ShipQuests_Door.txt b/npc/functions/quest-debug/007-ShipQuests_Door.txt
new file mode 100644
index 00000000..bc29888e
--- /dev/null
+++ b/npc/functions/quest-debug/007-ShipQuests_Door.txt
@@ -0,0 +1,25 @@
+// Door quest debug
+// Authors:
+// gumi
+
+function script QuestDebug7 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ShipQuests_Door";
+ mes "---";
+ mes l("Quest state: @@", getq(ShipQuests_Door));
+ next;
+
+ GenericQuestDebug ShipQuests_Door,
+ l("Does not have the quest"), 0,
+ l("Heard conversation"), 1;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/008-ShipQuests_Couwan.txt b/npc/functions/quest-debug/008-ShipQuests_Couwan.txt
new file mode 100644
index 00000000..e9763a56
--- /dev/null
+++ b/npc/functions/quest-debug/008-ShipQuests_Couwan.txt
@@ -0,0 +1,26 @@
+// Couwan quest debug
+// Authors:
+// gumi
+
+function script QuestDebug8 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ShipQuests_Couwan";
+ mes "---";
+ mes l("Quest state: @@", getq(ShipQuests_Couwan));
+ next;
+
+ GenericQuestDebug ShipQuests_Couwan,
+ l("Does not have the quest"), 0,
+ l("Couwan asks to deliver box"), 1,
+ l("Delivered box, got reward"), 2;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/009-ShipQuests_TreasureChest.txt b/npc/functions/quest-debug/009-ShipQuests_TreasureChest.txt
new file mode 100644
index 00000000..ea2e1dec
--- /dev/null
+++ b/npc/functions/quest-debug/009-ShipQuests_TreasureChest.txt
@@ -0,0 +1,25 @@
+// Treasure chest quest debug
+// Authors:
+// gumi
+
+function script QuestDebug9 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ShipQuests_TreasureChest";
+ mes "---";
+ mes l("Quest state: @@", getq(ShipQuests_TreasureChest));
+ next;
+
+ GenericQuestDebug ShipQuests_TreasureChest,
+ l("Does not have the quest"), 0,
+ l("Opened treasure chest"), 1;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/010-ShipQuests_Ale.txt b/npc/functions/quest-debug/010-ShipQuests_Ale.txt
new file mode 100644
index 00000000..67aed1fb
--- /dev/null
+++ b/npc/functions/quest-debug/010-ShipQuests_Ale.txt
@@ -0,0 +1,25 @@
+// Part of Gugli quest debug
+// Authors:
+// gumi
+
+function script QuestDebug10 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ShipQuests_Ale";
+ mes "---";
+ mes l("Quest state: @@", getq(ShipQuests_Ale));
+ next;
+
+ GenericQuestDebug ShipQuests_Ale,
+ l("Does not have the quest"), 0,
+ l("Got the package"), 1;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/011-ShipQuests_Astapolos.txt b/npc/functions/quest-debug/011-ShipQuests_Astapolos.txt
new file mode 100644
index 00000000..9e4d6e2b
--- /dev/null
+++ b/npc/functions/quest-debug/011-ShipQuests_Astapolos.txt
@@ -0,0 +1,25 @@
+// Part of Gugli quest debug
+// Authors:
+// gumi
+
+function script QuestDebug11 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ShipQuests_Astapolos";
+ mes "---";
+ mes l("Quest state: @@", getq(ShipQuests_Astapolos));
+ next;
+
+ GenericQuestDebug ShipQuests_Astapolos,
+ l("Does not have the quest"), 0,
+ l("Got the package"), 1;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/012-ShipQuests_Gulukan.txt b/npc/functions/quest-debug/012-ShipQuests_Gulukan.txt
new file mode 100644
index 00000000..878b536f
--- /dev/null
+++ b/npc/functions/quest-debug/012-ShipQuests_Gulukan.txt
@@ -0,0 +1,25 @@
+// Part of Gugli quest debug
+// Authors:
+// gumi
+
+function script QuestDebug12 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ShipQuests_Gulukan";
+ mes "---";
+ mes l("Quest state: @@", getq(ShipQuests_Gulukan));
+ next;
+
+ GenericQuestDebug ShipQuests_Gulukan,
+ l("Does not have the quest"), 0,
+ l("Got the package"), 1;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/013-ShipQuests_Jalad.txt b/npc/functions/quest-debug/013-ShipQuests_Jalad.txt
new file mode 100644
index 00000000..d5640411
--- /dev/null
+++ b/npc/functions/quest-debug/013-ShipQuests_Jalad.txt
@@ -0,0 +1,25 @@
+// Part of Gugli quest debug
+// Authors:
+// gumi
+
+function script QuestDebug13 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ShipQuests_Jalad";
+ mes "---";
+ mes l("Quest state: @@", getq(ShipQuests_Jalad));
+ next;
+
+ GenericQuestDebug ShipQuests_Jalad,
+ l("Does not have the quest"), 0,
+ l("Got the package"), 1;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/014-ShipQuests_QMuller.txt b/npc/functions/quest-debug/014-ShipQuests_QMuller.txt
new file mode 100644
index 00000000..1f69efdd
--- /dev/null
+++ b/npc/functions/quest-debug/014-ShipQuests_QMuller.txt
@@ -0,0 +1,25 @@
+// Part of Gugli quest debug
+// Authors:
+// gumi
+
+function script QuestDebug14 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ShipQuests_QMuller";
+ mes "---";
+ mes l("Quest state: @@", getq(ShipQuests_QMuller));
+ next;
+
+ GenericQuestDebug ShipQuests_QMuller,
+ l("Does not have the quest"), 0,
+ l("Got the package"), 1;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/015-ShipQuests_Tibbo.txt b/npc/functions/quest-debug/015-ShipQuests_Tibbo.txt
new file mode 100644
index 00000000..f963a0f0
--- /dev/null
+++ b/npc/functions/quest-debug/015-ShipQuests_Tibbo.txt
@@ -0,0 +1,25 @@
+// Part of Gugli quest debug
+// Authors:
+// gumi
+
+function script QuestDebug15 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ShipQuests_Tibbo";
+ mes "---";
+ mes l("Quest state: @@", getq(ShipQuests_Tibbo));
+ next;
+
+ GenericQuestDebug ShipQuests_Tibbo,
+ l("Does not have the quest"), 0,
+ l("Got the package"), 1;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/016-ShipQuests_Gugli.txt b/npc/functions/quest-debug/016-ShipQuests_Gugli.txt
new file mode 100644
index 00000000..70c5a441
--- /dev/null
+++ b/npc/functions/quest-debug/016-ShipQuests_Gugli.txt
@@ -0,0 +1,46 @@
+// Part of Gugli quest debug
+// Authors:
+// gumi
+
+function script QuestDebug16 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ShipQuests_Gugli";
+ mes "---";
+ mes l("Quest state: @@", getq(ShipQuests_Gugli));
+ mes "---";
+ mes l("Subquests:");
+ mes "ShipQuests_Ale: " + getq(ShipQuests_Ale);
+ mes "ShipQuests_Astapolos: " + getq(ShipQuests_Astapolos);
+ mes "ShipQuests_Gulukan: " + getq(ShipQuests_Gulukan);
+ mes "ShipQuests_Jalad: " + getq(ShipQuests_Jalad);
+ mes "ShipQuests_QMuller: " + getq(ShipQuests_QMuller);
+ mes "ShipQuests_Tibbo: " + getq(ShipQuests_Tibbo);
+ next;
+
+ GenericQuestDebug ShipQuests_Gugli,
+ l("Does not have the quest"), 0,
+ l("Gugli asks to collect packages"), 1,
+ menuimage("actions/manage", l("Reset subquests")), 32700,
+ menuimage("actions/manage", l("Set subquests as completed")), 32701,
+ l("Got reward from gugli"), 2;
+
+ switch (@menuret)
+ {
+ case 0:
+ case 32700:
+ case 32701:
+ setq ShipQuests_Ale, (@menuret == 32701 ? 1 : 0);
+ setq ShipQuests_Astapolos, (@menuret == 32701 ? 1 : 0);
+ setq ShipQuests_Gulukan, (@menuret == 32701 ? 1 : 0);
+ setq ShipQuests_Jalad, (@menuret == 32701 ? 1 : 0);
+ setq ShipQuests_QMuller, (@menuret == 32701 ? 1 : 0);
+ setq ShipQuests_Tibbo, (@menuret == 32701 ? 1 : 0);
+ break;
+ case 32766: return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/017-ShipQuests_ChefGado.txt b/npc/functions/quest-debug/017-ShipQuests_ChefGado.txt
new file mode 100644
index 00000000..8bf5ea6f
--- /dev/null
+++ b/npc/functions/quest-debug/017-ShipQuests_ChefGado.txt
@@ -0,0 +1,30 @@
+// Gado quest debug
+// Authors:
+// gumi
+
+function script QuestDebug17 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ShipQuests_ChefGado";
+ mes "---";
+ mes l("Quest state: @@", getq(ShipQuests_ChefGado));
+ next;
+
+ GenericQuestDebug ShipQuests_ChefGado,
+ l("Does not have the quest"), 0,
+ l("Nard asks to solve conflict"), 1,
+ l("Got poison from Gado"), 2,
+ l("Poisoned Julia"), 3,
+ l("Completed, Gado wins"), 4,
+ l("Completed, Julia wins (returned poison)"), 5,
+ l("Completed, Julia wins"), 6;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/018-General_Cookies.txt b/npc/functions/quest-debug/018-General_Cookies.txt
new file mode 100644
index 00000000..43bf44af
--- /dev/null
+++ b/npc/functions/quest-debug/018-General_Cookies.txt
@@ -0,0 +1,25 @@
+// Cookie quest debug
+// Authors:
+// gumi
+
+function script QuestDebug18 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "General_Cookies";
+ mes "---";
+ mes l("Quest state: @@", getq(General_Cookies));
+ next;
+
+ GenericQuestDebug General_Cookies,
+ l("Does not have the quest"), 0,
+ l("Got a cookie"), 1;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/019-ArtisQuests_LazyBrother.txt b/npc/functions/quest-debug/019-ArtisQuests_LazyBrother.txt
new file mode 100644
index 00000000..02d674b0
--- /dev/null
+++ b/npc/functions/quest-debug/019-ArtisQuests_LazyBrother.txt
@@ -0,0 +1,28 @@
+// Lazy brother quest debug
+// Authors:
+// gumi
+
+function script QuestDebug19 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ArtisQuests_LazyBrother";
+ mes "---";
+ mes l("Quest state: @@", getq(ArtisQuests_LazyBrother));
+ next;
+
+ GenericQuestDebug ArtisQuests_LazyBrother,
+ l("Does not have the quest"), 0,
+ l("Katja asked for help"), 1,
+ l("Found bobo, didn't tell Katja"), 2,
+ l("Told bobo to go home"), 3,
+ l("Katja gave reward"), 4;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/020-ArtisQuests_Urchin.txt b/npc/functions/quest-debug/020-ArtisQuests_Urchin.txt
new file mode 100644
index 00000000..a7f73a5d
--- /dev/null
+++ b/npc/functions/quest-debug/020-ArtisQuests_Urchin.txt
@@ -0,0 +1,26 @@
+// Urchin quest debug
+// Authors:
+// gumi
+
+function script QuestDebug20 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ArtisQuests_Urchin";
+ mes "---";
+ mes l("Quest state: @@", getq(ArtisQuests_Urchin));
+ next;
+
+ GenericQuestDebug ArtisQuests_Urchin,
+ l("Does not have the quest"), 0,
+ l("Moon needs @@", l("Croc Claw")), 1,
+ l("Found @@, got exp", l("Croc Claw")), 2;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/021-ArtisQuests_CatchPiou.txt b/npc/functions/quest-debug/021-ArtisQuests_CatchPiou.txt
new file mode 100644
index 00000000..9548ef9b
--- /dev/null
+++ b/npc/functions/quest-debug/021-ArtisQuests_CatchPiou.txt
@@ -0,0 +1,26 @@
+// Piou quest debug
+// Authors:
+// gumi
+
+function script QuestDebug21 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ArtisQuests_CatchPiou";
+ mes "---";
+ mes l("Quest state: @@", getq(ArtisQuests_CatchPiou));
+ next;
+
+ GenericQuestDebug ArtisQuests_CatchPiou,
+ l("Does not have the quest"), 0,
+ l("Salem asks to catch piou"), 1,
+ l("Returned piou to Salem"), 2;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/022-ArtisQuests_Fishman.txt b/npc/functions/quest-debug/022-ArtisQuests_Fishman.txt
new file mode 100644
index 00000000..65c6ff44
--- /dev/null
+++ b/npc/functions/quest-debug/022-ArtisQuests_Fishman.txt
@@ -0,0 +1,26 @@
+// Eugene quest debug
+// Authors:
+// gumi
+
+function script QuestDebug22 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ArtisQuests_Fishman";
+ mes "---";
+ mes l("Quest state: @@", getq(ArtisQuests_Fishman));
+ next;
+
+ GenericQuestDebug ArtisQuests_Fishman,
+ l("Does not have the quest"), 0,
+ l("Eugene needs tentacles"), 1,
+ l("Gave tentacles, got reward"), 2;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/023-ArtisQuests_QOnan.txt b/npc/functions/quest-debug/023-ArtisQuests_QOnan.txt
new file mode 100644
index 00000000..6028604c
--- /dev/null
+++ b/npc/functions/quest-debug/023-ArtisQuests_QOnan.txt
@@ -0,0 +1,27 @@
+// Q'Onan quest debug
+// Authors:
+// gumi
+
+function script QuestDebug23 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ArtisQuests_QOnan";
+ mes "---";
+ mes l("Quest state: @@", getq(ArtisQuests_QOnan));
+ next;
+
+ GenericQuestDebug ArtisQuests_QOnan,
+ l("Does not have the quest"), 0,
+ l("Q'Onan asks to find chest"), 1,
+ l("Found the chest"), 2,
+ l("Gave to Q'Onan, got reward"), 3;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/026-General_Rumly.txt b/npc/functions/quest-debug/026-General_Rumly.txt
new file mode 100644
index 00000000..ad245420
--- /dev/null
+++ b/npc/functions/quest-debug/026-General_Rumly.txt
@@ -0,0 +1,27 @@
+// Rumly quest debug
+// Authors:
+// gumi
+
+function script QuestDebug26 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "General_Rumly";
+ mes "---";
+ mes l("Quest state: @@", getq(General_Rumly));
+ next;
+
+ GenericQuestDebug General_Rumly,
+ l("Does not have the quest"), 0,
+ l("Rumly needs your help"), 1,
+ l("Rumly wants @@", l("Plushroom")), 2,
+ l("Gave @@ to Rumly", l("Plushroom")), 3;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/027-ArtisQuests_Enora.txt b/npc/functions/quest-debug/027-ArtisQuests_Enora.txt
new file mode 100644
index 00000000..ef8c7d43
--- /dev/null
+++ b/npc/functions/quest-debug/027-ArtisQuests_Enora.txt
@@ -0,0 +1,35 @@
+// Newbie quest debug
+// Authors:
+// gumi
+
+function script QuestDebug27 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ArtisQuests_Enora";
+ mes "---";
+ mes l("Quest state: @@", getq(ArtisQuests_Enora));
+ next;
+
+ GenericQuestDebug ArtisQuests_Enora,
+ l("Does not have the quest"), 0,
+ l("Enora asks to visit Chelios"), 1,
+ l("Chelios asks to visit Lloyd"), 2,
+ l("Lloyd gave package"), 3,
+ l("Chelios made sword"), 4,
+ l("Enora asks to visit Resa"), 5,
+ l("Resa gave package"), 6,
+ l("Enora asks to visit Q'Pid"), 7,
+ l("Lost the riddle"), 8,
+ l("Ivan gave package"), 9,
+ l("Enora asks to kill fluffys"), 10,
+ l("Completed, got reward"), 11;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/028-General_Narrator.txt b/npc/functions/quest-debug/028-General_Narrator.txt
new file mode 100644
index 00000000..e5c19c7f
--- /dev/null
+++ b/npc/functions/quest-debug/028-General_Narrator.txt
@@ -0,0 +1,25 @@
+// Narrator debug
+// Authors:
+// gumi
+
+function script QuestDebug28 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "General_Narrator";
+ mes "---";
+ mes l("Quest state: @@", getq(General_Narrator));
+ next;
+
+ GenericQuestDebug General_Narrator,
+ l("Game introduction"), 0,
+ l("Visited Artis at least once"), 1;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/029-ArtisQuests_Fexil.txt b/npc/functions/quest-debug/029-ArtisQuests_Fexil.txt
new file mode 100644
index 00000000..b8cf6283
--- /dev/null
+++ b/npc/functions/quest-debug/029-ArtisQuests_Fexil.txt
@@ -0,0 +1,27 @@
+// Fexil quest debug
+// Authors:
+// gumi
+
+function script QuestDebug29 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ArtisQuests_Fexil";
+ mes "---";
+ mes l("Quest state: @@", getq(ArtisQuests_Fexil));
+ next;
+
+ GenericQuestDebug ArtisQuests_Fexil,
+ l("Does not have the quest"), 0,
+ l("Lloyd gave pass"), 1,
+ l("Fexil needs help"), 2,
+ l("Fexil wants to buy fur"), 3;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/030-ArtisQuests_Lloyd.txt b/npc/functions/quest-debug/030-ArtisQuests_Lloyd.txt
new file mode 100644
index 00000000..4ac85cc5
--- /dev/null
+++ b/npc/functions/quest-debug/030-ArtisQuests_Lloyd.txt
@@ -0,0 +1,25 @@
+// Lloyd quest debug
+// Authors:
+// gumi
+
+function script QuestDebug30 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ArtisQuests_Lloyd";
+ mes "---";
+ mes l("Quest state: @@", getq(ArtisQuests_Lloyd));
+ next;
+
+ GenericQuestDebug ArtisQuests_Lloyd,
+ l("Does not have the quest"), 0,
+ l("Registered"), 1;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/031-General_Janus.txt b/npc/functions/quest-debug/031-General_Janus.txt
new file mode 100644
index 00000000..797e3357
--- /dev/null
+++ b/npc/functions/quest-debug/031-General_Janus.txt
@@ -0,0 +1,31 @@
+// Janus quest debug
+// Authors:
+// gumi
+
+function script QuestDebug31 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "General_Janus";
+ mes "---";
+ mes l("Quest state: @@", getq(General_Janus));
+ next;
+
+ GenericQuestDebug General_Janus,
+ l("Does not have the quest"), 0,
+ l("Talked to Janus"), 1,
+ l("Can create party"), 2,
+ l("Can create guild"), 3;
+
+ switch (@menuret)
+ {
+ case 0:
+ case 1: skill NV_BASIC, min(6, getskilllv(NV_BASIC)), 0; break;
+ case 2:
+ case 3: skill NV_BASIC, max(7, getskilllv(NV_BASIC)), 0; break;
+ case 32766: return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/032-ArtisQuests_MonaDad.txt b/npc/functions/quest-debug/032-ArtisQuests_MonaDad.txt
new file mode 100644
index 00000000..f1b142f9
--- /dev/null
+++ b/npc/functions/quest-debug/032-ArtisQuests_MonaDad.txt
@@ -0,0 +1,25 @@
+// Mona quest debug
+// Authors:
+// gumi
+
+function script QuestDebug32 {
+ do
+ {
+ clear;
+ setnpcdialogtitle l("Quest debug");
+ mes "ArtisQuests_MonaDad";
+ mes "---";
+ mes l("Quest state: @@", getq(ArtisQuests_MonaDad));
+ next;
+
+ GenericQuestDebug ArtisQuests_MonaDad,
+ l("Does not have the quest"), 0,
+ l("Mona's dad is missing"), 1;
+
+ if (@menuret == 32766)
+ {
+ return;
+ }
+
+ } while (1);
+}
diff --git a/npc/functions/quest-debug/functions.txt b/npc/functions/quest-debug/functions.txt
new file mode 100644
index 00000000..c193f9f8
--- /dev/null
+++ b/npc/functions/quest-debug/functions.txt
@@ -0,0 +1,73 @@
+// generic quest debug functions
+
+function script GenericQuestDebug {
+ if (!debug)
+ {
+ select
+ menuimage("actions/back", l("Go back")),
+ menuimage("actions/exit", l("Close"));
+
+ if (@menu == 1)
+ {
+ @menuret = 32766;
+ return 32766;
+ }
+
+ closedialog;
+ end;
+ }
+
+ mes l("Choose desired quest state:");
+
+ deletearray .@vals;
+ .@menustr$ = menuimage("actions/abort", l("Do nothing")) + ":";
+ .@vals[0] = 32766;
+ .@cnt = 1;
+
+ for (.@f = 1; .@f < getargcount(); .@f += 2)
+ {
+ if (getarg(.@f) != "")
+ {
+ .@qv = getarg(.@f + 1);
+ .@s$ = menuimage("actions/" + (.@qv ? "edit" : "reset"), "[" + .@qv + "] " + getarg(.@f));
+ .@menustr$ += (.@qv >= 32700 ? getarg(.@f) : .@s$) + ":";
+ .@vals[.@cnt] = .@qv;
+ ++.@cnt;
+ }
+ }
+
+ if (getgroupid() >= 99)
+ {
+ .@menustr$ += menuimage("actions/nuke", l("Set state manually")) + ":";
+ .@vals[.@cnt] = 32765;
+ ++.@cnt;
+ }
+
+ .@menustr$ += menuimage("actions/exit", l("Close"));
+ .@vals[.@cnt] = 32767;
+
+ @menu = 255;
+ @menuret = -1;
+ select(.@menustr$);
+ if (@menu == 255)
+ return -1;
+
+ --@menu;
+ if (@menu < 0 || @menu >= getarraysize(.@vals))
+ return -1;
+
+ @menuret = .@vals[@menu];
+
+ switch (@menuret)
+ {
+ case 32765: input .@w; setq getarg(0,0), .@w;
+ case 32766: return 1;
+ case 32767: closedialog; end;
+ }
+
+ if (@menuret < 32700)
+ {
+ setq getarg(0,0), @menuret;
+ }
+ return;
+}
diff --git a/npc/scripts.conf b/npc/scripts.conf
index 1efd1291..bab98e83 100644
--- a/npc/scripts.conf
+++ b/npc/scripts.conf
@@ -32,6 +32,41 @@
"npc/functions/mouboofunc.txt",
"npc/functions/string.txt",
+// quest debug
+"npc/functions/quest-debug/functions.txt",
+"npc/functions/quest-debug/000-ShipQuests_Julia.txt",
+"npc/functions/quest-debug/001-ShipQuests_Arpan.txt",
+"npc/functions/quest-debug/002-ShipQuests_Alige.txt",
+"npc/functions/quest-debug/003-ShipQuests_Peter.txt",
+"npc/functions/quest-debug/004-ShipQuests_Nard.txt",
+"npc/functions/quest-debug/005-ShipQuests_Knife.txt",
+"npc/functions/quest-debug/006-ShipQuests_ArpanMoney.txt",
+"npc/functions/quest-debug/007-ShipQuests_Door.txt",
+"npc/functions/quest-debug/009-ShipQuests_TreasureChest.txt",
+"npc/functions/quest-debug/010-ShipQuests_Ale.txt",
+"npc/functions/quest-debug/011-ShipQuests_Astapolos.txt",
+"npc/functions/quest-debug/012-ShipQuests_Gulukan.txt",
+"npc/functions/quest-debug/013-ShipQuests_Jalad.txt",
+"npc/functions/quest-debug/014-ShipQuests_QMuller.txt",
+"npc/functions/quest-debug/015-ShipQuests_Tibbo.txt",
+"npc/functions/quest-debug/016-ShipQuests_Gugli.txt",
+"npc/functions/quest-debug/017-ShipQuests_ChefGado.txt",
+"npc/functions/quest-debug/018-General_Cookies.txt",
+"npc/functions/quest-debug/019-ArtisQuests_LazyBrother.txt",
+"npc/functions/quest-debug/020-ArtisQuests_Urchin.txt",
+"npc/functions/quest-debug/021-ArtisQuests_CatchPiou.txt",
+"npc/functions/quest-debug/022-ArtisQuests_Fishman.txt",
+"npc/functions/quest-debug/023-ArtisQuests_QOnan.txt",
+// 24: quest removed (Halloween_VisitArtis)
+// 25: quest removed (Halloween_BarrelQuest)
+"npc/functions/quest-debug/026-General_Rumly.txt",
+"npc/functions/quest-debug/027-ArtisQuests_Enora.txt",
+"npc/functions/quest-debug/028-General_Narrator.txt",
+"npc/functions/quest-debug/029-ArtisQuests_Fexil.txt",
+"npc/functions/quest-debug/030-ArtisQuests_Lloyd.txt",
+"npc/functions/quest-debug/031-General_Janus.txt",
+"npc/functions/quest-debug/032-ArtisQuests_MonaDad.txt",
+
// custom atcommands
"npc/commands/music.txt",
"npc/commands/warp.txt",
@@ -40,6 +75,7 @@
"npc/commands/scheduled-broadcasts.txt",
"npc/commands/event.txt",
"npc/commands/debug-look.txt",
+"npc/commands/debug-quest.txt",
"npc/commands/debug-skill.txt",
"npc/commands/debug-preset.txt",
"npc/commands/debug.txt",