summaryrefslogtreecommitdiff
path: root/world/map/npc/008-1
diff options
context:
space:
mode:
Diffstat (limited to 'world/map/npc/008-1')
-rw-r--r--world/map/npc/008-1/_mobs.txt3
-rw-r--r--world/map/npc/008-1/andra.txt4
-rw-r--r--world/map/npc/008-1/annualeaster.txt33
-rw-r--r--world/map/npc/008-1/diryn.txt17
-rw-r--r--world/map/npc/008-1/dock.txt3
-rw-r--r--world/map/npc/008-1/george.txt3
-rw-r--r--world/map/npc/008-1/hinnak.txt3
7 files changed, 46 insertions, 20 deletions
diff --git a/world/map/npc/008-1/_mobs.txt b/world/map/npc/008-1/_mobs.txt
index 433f4ee4..1f64f55f 100644
--- a/world/map/npc/008-1/_mobs.txt
+++ b/world/map/npc/008-1/_mobs.txt
@@ -12,7 +12,8 @@
008-1.gat,0,0,0,0|monster|Butterfly|1055,10,30,20,Mob008-1::On1055
-008-1.gat,0,0,0|script|Mob008-1|-1,{
+008-1.gat,0,0,0|script|Mob008-1|-1,
+{
On1014:
set @mobID, 1014;
callfunc "MobPoints";
diff --git a/world/map/npc/008-1/andra.txt b/world/map/npc/008-1/andra.txt
index a58e465a..d86a32a1 100644
--- a/world/map/npc/008-1/andra.txt
+++ b/world/map/npc/008-1/andra.txt
@@ -1,7 +1,7 @@
// Andra asks for your help to keep the soil fertile. The best way to do it is planting, so she asks for water and seeds. When she plants the seeds, some plants are spawned.
-008-1.gat,36,26,0|script|Andra|201,{
-
+008-1.gat,36,26,0|script|Andra|201,
+{
set @water_amount, 1;
set @seeds_amount, 4;
if ($@andra_status == 1) goto L_Planting;
diff --git a/world/map/npc/008-1/annualeaster.txt b/world/map/npc/008-1/annualeaster.txt
index 510ee9d3..66c1c746 100644
--- a/world/map/npc/008-1/annualeaster.txt
+++ b/world/map/npc/008-1/annualeaster.txt
@@ -9,8 +9,8 @@
// the event in these days.
-function|script|AnnualEasterEvent|{
-
+function|script|AnnualEasterEvent|,
+{
if ((gettimetick(2)-TUT_var < 5*7*86400) || (BaseLevel < 40)) //player must be created at least 5 weeks ago
goto L_EndTooYoung;
@@ -110,26 +110,30 @@ L_End1:
return;
}
-008-1.gat,65,40,0|script|#TestEgg0|375,{
+008-1.gat,65,40,0|script|#TestEgg0|375,
+{
set @EasterEggID, 0;
callfunc("AnnualEasterEvent");
}
-008-1.gat,65,40,0|script|#TestEgg1|375,{
+008-1.gat,65,40,0|script|#TestEgg1|375,
+{
set @EasterEggID, 1;
callfunc("AnnualEasterEvent");
}
-008-1.gat,65,40,0|script|#TestEgg2|375,{
+008-1.gat,65,40,0|script|#TestEgg2|375,
+{
set @EasterEggID, 2;
callfunc("AnnualEasterEvent");
}
-008-1.gat,59,38,0|script|#AnnualEaster|-1,{
+008-1.gat,59,38,0|script|#AnnualEaster|-1,
+{
end;
-onInit:
+OnInit:
set $@EASTER_FOUND_WAIT_TIME, 15;
set $@EASTER_FINAL_REW_INV_CHANCE, 70;
set $@EASTER_EGG_INV_CHANCE, 750;
@@ -148,6 +152,7 @@ onInit:
setarray $@FinalAnnualEasterReward$, "RedEggshellHat", "BlueEggshellHat", "YellowEggshellHat", "GreenEggshellHat", "OrangeEggshellHat", "DarkEggshellHat";
callsub S_disableEggs;
+ if (debug >= 2) end;
initnpctimer;
end;
@@ -167,10 +172,20 @@ OnTimer1000:
set $@isEaster, 1;
if (!$@wasEaster && $@isEaster)
- callsub S_enableEggs;
+ goto L_do_update_enable;
if ($@wasEaster && !$@isEaster)
- callsub S_disableEggs;
+ goto L_do_update_disable;
+ goto L_done_update;
+
+L_do_update_enable:
+ callsub S_enableEggs;
+ goto L_done_update;
+
+L_do_update_disable:
+ callsub S_disableEggs;
+ goto L_done_update;
+L_done_update:
set $@wasEaster, $@isEaster;
if (!$@isEaster)
diff --git a/world/map/npc/008-1/diryn.txt b/world/map/npc/008-1/diryn.txt
index 21767c29..ae3368ac 100644
--- a/world/map/npc/008-1/diryn.txt
+++ b/world/map/npc/008-1/diryn.txt
@@ -2,7 +2,8 @@
// Author: Wombat
// cost depending on level and adapted to new scripting guidelines: Jenalya
-008-1.gat,81,82,0|script|Diryn the Traveler|103,{
+008-1.gat,81,82,0|script|Diryn the Traveler|103,
+{
if (BaseLevel < 45)
goto L_LowerCost;
@@ -11,7 +12,7 @@
set @cost_magichouse, 1000;
set @cost_terranitecave, 1500;
set @cost_tulimshar, 1000;
- set @cost_nivalis, 1000;
+ set @cost_nivalis, 1500;
L_Start:
mes "[Diryn]";
@@ -31,7 +32,7 @@ L_Diryn_Yes:
"Magic House (" + @cost_magichouse + " GP)", L_Diryn_Magic_House,
"Terranite Cave (" + @cost_terranitecave + " GP)", L_Diryn_Terranite,
"Tulimshar Town Square (" + @cost_tulimshar + " GP)", L_Diryn_Tulimshar,
- "Nivalis (" + @cost_nivalis + " GP)", L_Diryn_Nivalis,
+ "Sage Nikolai's Mansion (" + @cost_nivalis + " GP)", L_Diryn_Nivalis,
"I'm not interested.", L_Diryn_No;
L_Diryn_Druid_Tree:
@@ -39,6 +40,7 @@ L_Diryn_Druid_Tree:
goto L_NoMoney;
mes "[Diryn]";
mes "\"Be fearless!\"";
+ close2;
set Zeny, Zeny - @cost_druidtree;
warp "005-1.gat",73,36;
goto L_Clearvars;
@@ -48,6 +50,7 @@ L_Diryn_Graveyard:
goto L_NoMoney;
mes "[Diryn]";
mes "\"Be fearless!\"";
+ close2;
set Zeny, Zeny - @cost_graveyard;
warp "027-1.gat",70,85;
goto L_Clearvars;
@@ -57,6 +60,7 @@ L_Diryn_Magic_House:
goto L_NoMoney;
mes "[Diryn]";
mes "\"Be fearless!\"";
+ close2;
set Zeny, Zeny - @cost_magichouse;
warp "013-1.gat",45,92;
goto L_Clearvars;
@@ -66,6 +70,7 @@ L_Diryn_Terranite:
goto L_NoMoney;
mes "[Diryn]";
mes "\"Be fearless!\"";
+ close2;
set Zeny, Zeny - @cost_terranitecave;
warp "012-3.gat",445,65;
goto L_Clearvars;
@@ -75,6 +80,7 @@ L_Diryn_Tulimshar:
goto L_NoMoney;
mes "[Diryn]";
mes "\"Be fearless!\"";
+ close2;
set Zeny, Zeny - @cost_tulimshar;
warp "001-1.gat",44,70;
goto L_Clearvars;
@@ -84,8 +90,9 @@ L_Diryn_Nivalis:
goto L_NoMoney;
mes "[Diryn]";
mes "\"Be fearless!\"";
+ close2;
set Zeny, Zeny - @cost_nivalis;
- warp "020-1.gat",71,100;
+ warp "048-1.gat",65,45;
goto L_Clearvars;
L_Diryn_No:
@@ -114,5 +121,5 @@ L_Clearvars:
set @cost_terranitecave, 0;
set @cost_tulimshar, 0;
set @cost_nivalis, 0;
- close;
+ end;
}
diff --git a/world/map/npc/008-1/dock.txt b/world/map/npc/008-1/dock.txt
index c944fe71..2d6be3fe 100644
--- a/world/map/npc/008-1/dock.txt
+++ b/world/map/npc/008-1/dock.txt
@@ -1,6 +1,7 @@
// The ferry dock
-008-1.gat,140,64,0|script|#hurnscalddock|45,2,1,{
+008-1.gat,140,64,0|script|#hurnscalddock|45,2,1,
+{
set @loc, DOCK_hurnscald;
callfunc "Ferry";
}
diff --git a/world/map/npc/008-1/george.txt b/world/map/npc/008-1/george.txt
index 70725432..fb7406bb 100644
--- a/world/map/npc/008-1/george.txt
+++ b/world/map/npc/008-1/george.txt
@@ -1,6 +1,7 @@
//
-008-1.gat,136,36,0|script|George|138,{
+008-1.gat,136,36,0|script|George|138,
+{
set @hw2011_npc_id, $@hw2011_npc_george;
if (gettime(7) == $@hw2011_year && gettime(6) == 10 && gettime(5) >= $@hw2011_start_day)
goto L_TrickOrTreat;
diff --git a/world/map/npc/008-1/hinnak.txt b/world/map/npc/008-1/hinnak.txt
index d2551e5a..8deb8263 100644
--- a/world/map/npc/008-1/hinnak.txt
+++ b/world/map/npc/008-1/hinnak.txt
@@ -5,7 +5,8 @@
//
// Variables used: Nibble 1 of QUEST_Hurnscald (previously QUEST_Scythe_state)
-008-1.gat,101,30,0|script|Hinnak|142,{
+008-1.gat,101,30,0|script|Hinnak|142,
+{
callfunc "ClearVariables";
set @inspector, ((QUEST_Hurnscald & NIBBLE_3_MASK) >> NIBBLE_3_SHIFT);