summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--db/const.txt33
-rw-r--r--db/questvars.txt19
-rw-r--r--npc/000-1/chest.txt4
-rw-r--r--npc/000-1/darlin.txt4
-rw-r--r--npc/000-2-0/doors.txt2
-rw-r--r--npc/000-2-0/julia.txt6
-rw-r--r--npc/000-2-1/alige.txt10
-rw-r--r--npc/000-2-1/arpan.txt20
-rw-r--r--npc/000-2-1/chest.txt4
-rw-r--r--npc/000-2-1/knife.txt4
-rw-r--r--npc/000-2-1/peter.txt20
-rw-r--r--npc/000-2-3/box.txt6
-rw-r--r--npc/000-2-3/elmo.txt2
-rw-r--r--npc/000-2-3/nard.txt6
-rw-r--r--npc/000-2-3/sailors.txt12
15 files changed, 77 insertions, 75 deletions
diff --git a/db/const.txt b/db/const.txt
index 5af9051a..ac293803 100644
--- a/db/const.txt
+++ b/db/const.txt
@@ -200,30 +200,13 @@ SKILL_GUILD 500
SKILL_CRAFT 501
SKILL_DYE 502
-// ShipQuests
-// 0011 2233 4455 6677 8899
-// 0000 1111 2222 3333 4444
-// 0123 4567 8901 2345 6789
-// JJAA PPPP AAKA D-NN D
-// uull eeee rrnM o-AA a
-
-// 2
ShipQuests_Julia 0
-// 4
ShipQuests_Peter 1
-// 2
-ShipQuests_Alige 1
-// 2
-ShipQuests_Arpan 4
-// 2
-ShipQuests_Nardbox 7
-// 1
-ShipQuests_Knife 10
-// 1
-ShipQuests_ArpanMoney 11
-// 1
-ShipQuests_Door 12
-// 1
-ShipQuests_TreasureChest 13
-// 1
-ShipQuests_Darlin 16
+ShipQuests_Alige 2
+ShipQuests_Arpan 3
+ShipQuests_Nardbox 4
+ShipQuests_Knife 5
+ShipQuests_ArpanMoney 6
+ShipQuests_Door 7
+ShipQuests_TreasureChest 8
+ShipQuests_Darlin 9
diff --git a/db/questvars.txt b/db/questvars.txt
new file mode 100644
index 00000000..b4e5c4eb
--- /dev/null
+++ b/db/questvars.txt
@@ -0,0 +1,19 @@
+//var,mask,div
+
+// ShipQuests
+// 0011 2233 4455 6677 8899
+// 0000 1111 2222 3333 4444
+// 0123 4567 8901 2345 6789
+// JJAA PPPP AAKA DTNN D
+// uull eeee rrnM oCAA a
+
+ShipQuests,3,1 // ShipQuests_Julia 0
+ShipQuests,15,16 // ShipQuests_Peter 1
+ShipQuests,3,4 // ShipQuests_Alige 2
+ShipQuests,3,256 // ShipQuests_Arpan 3
+ShipQuests,3,16384 // ShipQuests_Nardbox 4
+ShipQuests,1,1024 // ShipQuests_Knife 5
+ShipQuests,1,2048 // ShipQuests_ArpanMoney 6
+ShipQuests,1,4096 // ShipQuests_Door 7
+ShipQuests,1,8192 // ShipQuests_TreasureChest 8
+ShipQuests,1,65536 // ShipQuests_Darlin 9
diff --git a/npc/000-1/chest.txt b/npc/000-1/chest.txt
index 346664be..3aa3dbe7 100644
--- a/npc/000-1/chest.txt
+++ b/npc/000-1/chest.txt
@@ -13,7 +13,7 @@
000-1.gat,58,31,0 script Chest#1 316;2,{
- set @q, geta(ShipQuests, ShipQuests_TreasureChest);
+ set @q, getq(ShipQuests_TreasureChest);
if (getnpcdir ("") == 4) goto l_Give;
setnpcdir 2;
@@ -23,7 +23,7 @@
l_Give:
if (@q > 0) goto l_Close;
- seta ShipQuests, ShipQuests_TreasureChest, 1;
+ setq ShipQuests_TreasureChest, 1;
set zeny, zeny + 400;
getitem 508, 1;
getitem 509, 1;
diff --git a/npc/000-1/darlin.txt b/npc/000-1/darlin.txt
index 7d7bf58c..8becdd48 100644
--- a/npc/000-1/darlin.txt
+++ b/npc/000-1/darlin.txt
@@ -12,7 +12,7 @@
000-1.gat,25,26,0,1 script Darlin 103,{
mesn;
- set @q, geta(ShipQuests, ShipQuests_Darlin);
+ set @q, getq(ShipQuests_Darlin);
if (@q > 0) goto l_QuestGiven;
mesq l("HEY! HEY YOU!");
@@ -106,7 +106,7 @@ l_GoDown:
mesn;
if (@q > 0) goto l_DangerAround;
- seta ShipQuests, ShipQuests_Darlin, 1;
+ setq ShipQuests_Darlin, 1;
mesq l("Oh no, but I've noticed a weird light on the other edge of this island, I wonder what it can be...");
next;
diff --git a/npc/000-2-0/doors.txt b/npc/000-2-0/doors.txt
index 3c8e46e4..f5b0f3aa 100644
--- a/npc/000-2-0/doors.txt
+++ b/npc/000-2-0/doors.txt
@@ -7,7 +7,7 @@
000-2-0.gat,20,27,0,1 script AreaNPC 0,0,0,{
OnTouch:
- set @q, geta2(ShipQuests, ShipQuests_Nardbox);
+ set @q, getq(ShipQuests_Nardbox);
if (@q == 1) goto l_Warp;
if (@q == 2) goto l_GotoNard;
if (@q == 3) goto l_End;
diff --git a/npc/000-2-0/julia.txt b/npc/000-2-0/julia.txt
index 48320d27..f5cc8810 100644
--- a/npc/000-2-0/julia.txt
+++ b/npc/000-2-0/julia.txt
@@ -72,7 +72,7 @@ l_First:
mesn;
mesq l("Ok, Done.");
- set @q, geta(ShipQuests, ShipQuests_Julia);
+ set @q, getq(ShipQuests_Julia);
if (@q == 1) goto l_NoRules;
next;
@@ -105,7 +105,7 @@ l_First:
mesq l("I think that I'm done, do you have a question now?");
next;
- seta ShipQuests, ShipQuests_Julia, 1;
+ setq ShipQuests_Julia, 1;
goto l_Menu;
l_NoRules:
@@ -174,7 +174,7 @@ l_Rules:
goto l_YNMenu;
OnTouch:
- set @q, geta(ShipQuests, ShipQuests_Julia);
+ set @q, getq(ShipQuests_Julia);
if (@q == 0) goto l_First;
close;
diff --git a/npc/000-2-1/alige.txt b/npc/000-2-1/alige.txt
index c3212ddc..cf121931 100644
--- a/npc/000-2-1/alige.txt
+++ b/npc/000-2-1/alige.txt
@@ -16,7 +16,7 @@
000-2-1.gat,33,32,0,1 script AligeTrigger 0,1,1,{
OnTouch:
- if (geta2(ShipQuests, ShipQuests_Alige) > 0) close;
+ if (getq(ShipQuests_Alige) > 0) close;
doevent "Alige::OnFirstEncounter";
close;
@@ -46,13 +46,13 @@ OnTimer190:
000-2-1.gat,33,31,0,1 script Alige 301;2,{
- set @q, geta2(ShipQuests, ShipQuests_Alige);
+ set @q, getq(ShipQuests_Alige);
if (@q == 2) goto l_AskForFood;
goto OnFirstEncounter;
OnFirstEncounter:
- seta2 ShipQuests, ShipQuests_Alige, 1;
+ setq ShipQuests_Alige, 1;
mesn "Hidden Person";
mesq l("Hey, psst! You're not a sailor, right?");
@@ -107,7 +107,7 @@ l_CanHelp:
mesq l("Please don't tell people that you've seen me. I don't want to be thrown in the sea as food for sharks or decapitated. At least not again!");
next;
- if (geta2(ShipQuests, ShipQuests_Alige) == 2) goto l_SoAskForFood;
+ if (getq(ShipQuests_Alige) == 2) goto l_SoAskForFood;
goto l_Accept;
l_AboutReward:
@@ -132,7 +132,7 @@ l_Artis:
goto l_Accept;
l_Accepted:
- seta2 ShipQuests, ShipQuests_Alige, 2;
+ setq ShipQuests_Alige, 2;
mes "";
mesn;
diff --git a/npc/000-2-1/arpan.txt b/npc/000-2-1/arpan.txt
index af90979a..4ef180c2 100644
--- a/npc/000-2-1/arpan.txt
+++ b/npc/000-2-1/arpan.txt
@@ -12,7 +12,7 @@
// 3 Has and equipped the clothes.
000-2-1.gat,39,36,0,1 script LeftDoorCheck 0,0,0,{
- set @q, geta2(ShipQuests, ShipQuests_Arpan);
+ set @q, getq(ShipQuests_Arpan);
if (@q == 0) doevent "Magic Arpan::OnTalk";
close;
@@ -20,7 +20,7 @@
}
000-2-1.gat,44,36,0,1 script RightDoorCheck 0,0,0,{
- set @q, geta2(ShipQuests, ShipQuests_Arpan);
+ set @q, getq(ShipQuests_Arpan);
if (@q == 0) doevent "Magic Arpan::OnTalk";
close;
@@ -28,7 +28,7 @@
}
000-2-1.gat,37,32,0,1 script LeftBarrierCheck 0,0,2,{
- set @q, geta2(ShipQuests, ShipQuests_Arpan);
+ set @q, getq(ShipQuests_Arpan);
if (@q > 2) close;
if (@q == 2 && getequipid(equip_torso) == 1300 && getequipid(equip_legs) == 2200) goto l_EquipDone;
if (@q == 1) goto l_GetCloth;
@@ -46,14 +46,14 @@ l_GetCloth:
close;
l_EquipDone:
- seta2 ShipQuests, ShipQuests_Arpan, 3;
+ setq ShipQuests_Arpan, 3;
close;
}
000-2-1.gat,46,32,0,1 script RightBarrierCheck 0,0,2,{
- set @q, geta2(ShipQuests, ShipQuests_Arpan);
+ set @q, getq(ShipQuests_Arpan);
if (@q > 2) close;
if (@q == 2 && getequipid(equip_torso) == 1300 && getequipid(equip_legs) == 2200) goto l_EquipDone;
if (@q == 1) goto l_GetCloth;
@@ -71,7 +71,7 @@ l_GetCloth:
close;
l_EquipDone:
- seta2 ShipQuests, ShipQuests_Arpan, 3;
+ setq ShipQuests_Arpan, 3;
close;
@@ -81,7 +81,7 @@ l_EquipDone:
000-2-1.gat,39,33,0,1 script Magic Arpan 307;5,{
OnTalk:
- set @q, geta2(ShipQuests, ShipQuests_Arpan);
+ set @q, getq(ShipQuests_Arpan);
mesn;
@@ -89,7 +89,7 @@ OnTalk:
mesq lg("Yeye, you are really lucky to be alive. You are in good enough shape for walking, do you remember what happened?");
next;
- seta2 ShipQuests, ShipQuests_Arpan, 1;
+ setq ShipQuests_Arpan, 1;
menu
lg("I only remember I was rescued by you."), l_Story,
@@ -135,7 +135,7 @@ l_Menu:
lg("Could you tell me where I am?"), l_Where,
lg("Where can I find Julia?"), l_Julia,
l("Who are you?"), l_Who,
- rif(geta(ShipQuests, ShipQuests_ArpanMoney) == 0, l("Where are my old clothes?")), l_WhereOldClothes,
+ rif(getq(ShipQuests_ArpanMoney) == 0, l("Where are my old clothes?")), l_WhereOldClothes,
rif(!@equipped, lg("What should I do after taking these clothes?")), l_WhatCloth,
rif(!@equipped, l("Thank you, I'll take them."), l("Nothing, sorry.")), l_Quit;
close;
@@ -179,7 +179,7 @@ l_WhereOldClothes:
mesq lg("We tried to clean them but the sea water mostly killed them. It's why we gave you these cloths, they are not very good but it's all that we got.");
next;
mes lg("Oh, now that I remember, we've also found some money in your pockets, here it is!");
- seta ShipQuests, ShipQuests_ArpanMoney, 1;
+ setq ShipQuests_ArpanMoney, 1;
set zeny, zeny+25;
next;
diff --git a/npc/000-2-1/chest.txt b/npc/000-2-1/chest.txt
index a2c7b90c..130b2c1a 100644
--- a/npc/000-2-1/chest.txt
+++ b/npc/000-2-1/chest.txt
@@ -12,7 +12,7 @@
000-2-1.gat,41,37,0 script Chest#0 317;2,{
- set @q, geta2(ShipQuests, ShipQuests_Arpan);
+ set @q, getq(ShipQuests_Arpan);
if (getnpcdir ("") == 4) goto l_Give;
setnpcdir 2;
@@ -22,7 +22,7 @@
l_Give:
if (@q > 1) goto l_Close;
- seta2 ShipQuests, ShipQuests_Arpan, 2;
+ setq ShipQuests_Arpan, 2;
getitem "WornShirt", 1;
getitem "WornShorts", 1;
message strcharinfo(0), l("You take the clothes from the chest.");
diff --git a/npc/000-2-1/knife.txt b/npc/000-2-1/knife.txt
index 37f342ca..c7ca1a55 100644
--- a/npc/000-2-1/knife.txt
+++ b/npc/000-2-1/knife.txt
@@ -11,7 +11,7 @@
000-2-1.gat,40,24,0,2 script #name 100;2,{
- set @q, geta(ShipQuests, ShipQuests_Knife);
+ set @q, getq(ShipQuests_Knife);
if (@q) close;
mesn "Narrator";
@@ -25,7 +25,7 @@
close;
l_Give:
- seta ShipQuests, ShipQuests_Knife, 1;
+ setq ShipQuests_Knife, 1;
getitem "Knife", 1;
mes "";
diff --git a/npc/000-2-1/peter.txt b/npc/000-2-1/peter.txt
index 47c4c23a..e2821ba4 100644
--- a/npc/000-2-1/peter.txt
+++ b/npc/000-2-1/peter.txt
@@ -37,7 +37,7 @@
OnTouch:
if (BaseLevel < 5) goto L_Stop;
if ($@RAT_SAILOR_HELPER$ != "") goto L_Occupied;
- set @q, geta4(ShipQuests, ShipQuests_Peter);
+ set @q, getq(ShipQuests_Peter);
if (@q < 1) goto L_Task;
if (@q == 1 || @q == 2) goto L_Rfail;
if (@q == 3 || @q == 4) goto L_Rwin;
@@ -74,11 +74,11 @@ L_Rwin:
000-2-1.gat,60,35,0,1 script Peter 303;3,{
- set @q_julia, geta2(ShipQuests, ShipQuests_Julia);
+ set @q_julia, getq(ShipQuests_Julia);
if (@q_julia == 0) goto L_TalkToJulia;
if (BaseLevel < 5) goto OnTooWeak;
- set @q, geta4(ShipQuests, ShipQuests_Peter);
+ set @q, getq(ShipQuests_Peter);
if (@q == 1 || @q == 2) goto OnReturnFail;
if (@q >= 3) goto OnReturnWin;
@@ -176,15 +176,15 @@ L_BonusTask:
l("What? This reward is too small!"), L_Close;
if ($@RAT_SAILOR_HELPER$ != "") goto OnDontneedHelp;
- if (@q == 0) seta4 ShipQuests, ShipQuests_Peter, 2;
- if (@q == 3) seta4 ShipQuests, ShipQuests_Peter, 4;
+ if (@q == 0) setq ShipQuests_Peter, 2;
+ if (@q == 3) setq ShipQuests_Peter, 4;
goto L_Start;
L_Task:
mes "";
if ($@RAT_SAILOR_HELPER$ != "") goto OnDontneedHelp;
- if (@q == 0) seta4 ShipQuests, ShipQuests_Peter, 1;
+ if (@q == 0) setq ShipQuests_Peter, 1;
goto L_Start;
L_Start:
@@ -251,7 +251,7 @@ L_Dead:
L_Done:
warp "000-2-1", 61, 36;
- set @q, geta4(ShipQuests, ShipQuests_Peter);
+ set @q, getq(ShipQuests_Peter);
if (@q == 2 || @q == 4) goto L_Reward;
goto L_Thanks;
@@ -285,15 +285,15 @@ L_Reward:
mesq l("Good job!") + " " + l("Here's your reward!");
getexp 100, 0;
set zeny, zeny + 500;
- seta4 ShipQuests, ShipQuests_Peter, 5;
+ setq ShipQuests_Peter, 5;
goto L_CleaningClose;
L_Thanks:
mesn;
mesq l("Thanks for helping me!");
- set @q, geta4(ShipQuests, ShipQuests_Peter);
- if (@q == 1) seta4 ShipQuests, ShipQuests_Peter, 3;
+ set @q, getq(ShipQuests_Peter);
+ if (@q == 1) setq ShipQuests_Peter, 3;
goto L_CleaningClose;
diff --git a/npc/000-2-3/box.txt b/npc/000-2-3/box.txt
index 5dd91f3d..c15c0e50 100644
--- a/npc/000-2-3/box.txt
+++ b/npc/000-2-3/box.txt
@@ -17,7 +17,7 @@
000-2-3.gat,25,24,0 script Box 102;1,{
- set @q, geta2(ShipQuests, ShipQuests_Nardbox);
+ set @q, getq(ShipQuests_Nardbox);
mesn "Narrator";
mes col(l("Some Bandanas and Sailor Hats are inside this box."), 9);
@@ -60,7 +60,7 @@
next;
mesq l("Go outside and talk with Gugli, he will tell you what we need.");
- seta2 ShipQuests, ShipQuests_Nardbox, 1;
+ setq ShipQuests_Nardbox, 1;
close;
@@ -80,7 +80,7 @@ l_Give:
mesn "Nard";
mesq l("You are now part of the crew. Thanks again for your help.");
- seta2 ShipQuests, ShipQuests_Nardbox, 3;
+ setq ShipQuests_Nardbox, 3;
getitem "Bandana", 1;
// Need to add a skill for the crew at this line.
diff --git a/npc/000-2-3/elmo.txt b/npc/000-2-3/elmo.txt
index f5b58ed5..871c2170 100644
--- a/npc/000-2-3/elmo.txt
+++ b/npc/000-2-3/elmo.txt
@@ -6,7 +6,7 @@
000-2-3.gat,27,27,0,1 script Elmo 309;5,{
- set @q, geta(ShipQuests, ShipQuests_ArpanMoney);
+ set @q, getq(ShipQuests_ArpanMoney);
if (@q == 1) goto l_GotMoney;
mesn;
diff --git a/npc/000-2-3/nard.txt b/npc/000-2-3/nard.txt
index c5972586..daa5f6ca 100644
--- a/npc/000-2-3/nard.txt
+++ b/npc/000-2-3/nard.txt
@@ -17,7 +17,7 @@
000-2-3.gat,25,26,0,1 script Nard 306;5,{
- set @q, geta2(ShipQuests, ShipQuests_Nardbox);
+ set @q, getq(ShipQuests_Nardbox);
l_Checker:
if (@q == 1) goto l_NotYet;
@@ -85,7 +85,7 @@ l_NeedContent:
mesq l("Go outside and talk with Gugli, he'll tell you what we need.");
next;
- seta2 ShipQuests, ShipQuests_Nardbox, 1;
+ setq ShipQuests_Nardbox, 1;
close;
@@ -128,7 +128,7 @@ l_Give:
next;
mesq l("You are now part of the crew! Thanks again for your help.");
- seta2 ShipQuests, ShipQuests_Nardbox, 3;
+ setq ShipQuests_Nardbox, 3;
getitem "Bandana", 1;
// Need to add a skill for the crew at this line.
diff --git a/npc/000-2-3/sailors.txt b/npc/000-2-3/sailors.txt
index 52eba82f..ebcded78 100644
--- a/npc/000-2-3/sailors.txt
+++ b/npc/000-2-3/sailors.txt
@@ -8,8 +8,8 @@
000-2-3.gat,20,26,0,0 script AreaTop 0,1,0,{
OnTouch:
- if (geta(ShipQuests, ShipQuests_Door) == 1) end;
- seta ShipQuests, ShipQuests_Door, 1;
+ if (getq(ShipQuests_Door) == 1) end;
+ setq ShipQuests_Door, 1;
mesn "Elmo";
mesq g(l("So that's why we wanted to warn you, maybe she comes from that guild, as that sign was on her raft."),
@@ -48,8 +48,8 @@ OnTouch:
000-2-3.gat,21,27,0,0 script AreaMiddle 0,0,0,{
OnTouch:
- if (geta(ShipQuests, ShipQuests_Door) == 1) end;
- seta ShipQuests, ShipQuests_Door, 1;
+ if (getq(ShipQuests_Door) == 1) end;
+ setq ShipQuests_Door, 1;
mesn "Elmo";
mesq g(l("So that's why we wanted to warn you, maybe she comes from that guild, as that sign was on her raft."),
@@ -86,8 +86,8 @@ OnTouch:
000-2-3.gat,20,28,0,0 script AreaBottom 0,1,0,{
OnTouch:
- if (geta(ShipQuests, ShipQuests_Door) == 1) end;
- seta ShipQuests, ShipQuests_Door, 1;
+ if (getq(ShipQuests_Door) == 1) end;
+ setq ShipQuests_Door, 1;
mesn "Elmo";
mesq g(l("So that's why we wanted to warn you, maybe she comes from that guild, as that sign was on her raft."),