summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--maps/re/guilds.mcachebin164 -> 170 bytes
-rw-r--r--npc/009-1/guards.txt231
-rw-r--r--npc/014-3/_mobs.txt2
-rw-r--r--npc/020-1/_import.txt1
-rw-r--r--npc/020-1/guards.txt141
5 files changed, 237 insertions, 138 deletions
diff --git a/maps/re/guilds.mcache b/maps/re/guilds.mcache
index cdca1351d..59a02212a 100644
--- a/maps/re/guilds.mcache
+++ b/maps/re/guilds.mcache
Binary files differ
diff --git a/npc/009-1/guards.txt b/npc/009-1/guards.txt
index d652cc37b..bb6260046 100644
--- a/npc/009-1/guards.txt
+++ b/npc/009-1/guards.txt
@@ -48,181 +48,138 @@
L_MKControl:
mesn;
mes l("Oh noes! You've found the Halinarzo control panel!");
- menu
- l("Initiate small siege (lv. 20)"), L_MKSmall,
- l("Initiate medium siege (lv. 30)"), L_MKMedium,
- l("Initiate huge siege (lv. 40)"), L_MKHuge,
- l("Abort"), -;
- close;
-
-L_MKSmall:
- addmapmask "009-1", MASK_MATTACK;
- changemusic "009-1", "mythica.ogg";
- disablenpc("Mana Stone");
- $@SIEGE_HALI=0; // factor zero
- pvpon("009-1");
- pvpon("010-2");
- announce(l("##1WARNING! WARNING! Siege starting at Halinarzo!!"), bc_all);
- areamonster("010-2", 0, 0, 79, 81, l("Black Scorpion"), 1074, 15, "Lieutenant Jacob::OnBlackScorpionDeath");
- initnpctimer;
- close;
-
-L_MKMedium:
- addmapmask "009-1", MASK_MATTACK;
- changemusic "009-1", "eric matyas - ghoulish fun.ogg";
- disablenpc("Mana Stone");
- $@SIEGE_HALI=1; // factor one
- pvpon("009-1");
- pvpon("010-2");
- announce(l("##1WARNING! WARNING! Siege starting at Halinarzo!!"), bc_all);
- areamonster("010-2", 0, 0, 79, 81, l("Black Scorpion"), 1074, 25, "Lieutenant Jacob::OnBlackScorpionDeath");
- initnpctimer;
+ next;
+ select
+ l("Abort"),
+ l("Initiate a siege");
+ mes "";
+ if (@menu == 2) {
+ doevent "Lieutenant Jacob::OnStartSiege";
+ closedialog;
+ }
close;
-L_MKHuge:
- addmapmask "009-1", MASK_MATTACK;
- changemusic "009-1", "misuse.ogg";
- disablenpc("Mana Stone");
- $@SIEGE_HALI=5; // factor five
- pvpon("009-1");
- pvpon("010-2");
- announce(l("##1WARNING! WARNING! Siege starting at Halinarzo!!"), bc_all);
- areamonster("010-2", 0, 0, 79, 81, l("Black Scorpion"), 1074, 40, "Lieutenant Jacob::OnBlackScorpionDeath");
+// Respawn monster from $@SIEGE_TMPMOBS memory
+OnRespawn:
+ getmapxy(.@m$,.@x,.@y,0);
+ siege_spawn(.@m$, any_of($@SIEGE_TMPMOBS), 1, .name$+"::OnRespawn");
+ if (rand(10000) <= $coinsrate+($@SIEGE_HURNS*50))
+ makeitem StrangeCoin, 1, .@m$, .@x, .@y;
+ end;
+
+OnMKSiege:
+ $@SIEGE_HALIN=rand(1,10);
+OnStartSiege:
+ siege_setup("010-2");
+ kamibroadcast(col("WARNING! WARNING! Monster Army marching towards Halinarzo!!",1));
+ siege_cast("010-2", .name$, 0, TP_TULIM);
+ disablenpc "Sawis";
initnpctimer;
- close;
-
-OnBlackScorpionDeath:
- areamonster("010-2", 0, 0, 79, 81, l("Black Scorpion"), 1074, 1, "Lieutenant Jacob::OnBlackScorpionDeath");
- if (rand(10000) <= 90+($@SIEGE_HALI*10))
- getitem StrangeCoin, 1;
- end;
-
-OnBlackScorpion2Death:
- areamonster("009-1", 0, 0, 120, 155, l("Black Scorpion"), 1074, 1, "Lieutenant Jacob::OnBlackScorpion2Death");
- if (rand(10000) <= 850+($@SIEGE_HALI*100))
- getitem StrangeCoin, 1;
- end;
-
-OnGreenSlimeDeath:
- areamonster("009-1", 0, 0, 120, 155, l("Green Slime"), 1085, 1, "Lieutenant Jacob::OnGreenSlimeDeath");
- if (rand(10000) <= 200+($@SIEGE_HALI*100))
- getitem StrangeCoin, 1;
- end;
-
-OnCandiedSlimeDeath:
- areamonster("009-1", 0, 0, 120, 155, l("Candied Slime"), 1089, 1, "Lieutenant Jacob::OnCandiedSlimeDeath");
- if (rand(10000) <= 150+($@SIEGE_HALI*100))
- getitem StrangeCoin, 1;
- end;
-
-OnManaGhostDeath:
- areamonster("009-1", 0, 0, 120, 155, l("Mana Ghost"), 1068, 1, "Lieutenant Jacob::OnManaGhostDeath");
- if (rand(10000) <= 900+($@SIEGE_HALI*100))
- getitem StrangeCoin, 1;
- end;
-
-OnLieutenantDeath:
- getitem StrangeCoin, 1;
- Karma=Karma+1;
- mapannounce("009-1", l("##2The Monster Lieutenant was defeated by @@!", strcharinfo(0)), bc_map);
end;
-OnColonelDeath:
- getitem StrangeCoin, 1;
- Karma=Karma+1;
- $MOST_HEROIC$=strcharinfo(0);
- mapannounce("009-1", l("##2The Monster Colonel was defeated by @@!", strcharinfo(0)), bc_map);
- end;
-OnTimer5000:
- areamonster("010-2", 0, 0, 79, 81, "Black Scorpion", 1074, 5+$@SIEGE_HALI, "Lieutenant Jacob::OnBlackScorpionDeath");
- areamonster("009-1", 0, 0, 120, 155, "Black Scorpion", 1074, 5+$@SIEGE_HALI, "Lieutenant Jacob::OnBlackScorpion2Death");
+// Timers
+OnTimer35000:
+ siege_setup("009-1");
+ siege_cast("010-2", .name$, $@SIEGE_HALIN, TP_TULIM);
mapannounce("009-1", "##2Message to all Halinarzo NPCs: Take shelter!", bc_map);
+ disablenpc "Fisherman";
+ disablenpc "Charles, Trader King";
disablenpc "Lynn The Traveler";
+ disablenpc "Enliven Reva Foxhound";
+ disablenpc "Ryan";
+ disablenpc "Bella, the Scholar";
+ disablenpc "Book Keeper";
+ disablenpc "Yumi";
+ disablenpc "Halinarzo's Nurse";
+ disablenpc "Joaquim";
+ disablenpc "Alvasus";
+ disablenpc "Luanna";
end;
-OnTimer15000:
- areamonster("010-2", 0, 0, 79, 81, ("Black Scorpion"), 1074, 5, "Lieutenant Jacob::OnBlackScorpionDeath");
- areamonster("009-1", 0, 0, 120, 155, ("Black Scorpion"), 1074, 10, "Lieutenant Jacob::OnBlackScorpion2Death");
- end;
-
-OnTimer60000:
- if ($@SIEGE_HALI == 1) {
- mapannounce("009-1", "##1The Monster Lieutenant arrived!", bc_map);
- areamonster("009-1", 0, 0, 120, 155, ("Monster Lieutenant"), 1077, 1, "Lieutenant Jacob::OnLieutenantDeath");
- }
- areamonster("009-1", 0, 0, 120, 155, ("Black Scorpion"), 1074, 3, "Lieutenant Jacob::OnBlackScorpion2Death");
- areamonster("009-1", 0, 0, 120, 155, ("Green Slime"), 1085, 10+$@SIEGE_HALI, "Lieutenant Jacob::OnGreenSlimeDeath");
- areamonster("009-1", 0, 0, 120, 155, ("Candied Slime"), 1089, 1+$@SIEGE_HALI, "Lieutenant Jacob::OnCandiedSlimeDeath");
+OnTimer65000:
+ siege_cast("009-1", .name$, 0, TP_TULIM);
+ siege_cast("010-2", .name$, $@SIEGE_HALIN, TP_TULIM);
+ disablenpc "Dang Rostra";
+ disablenpc "Kevin";
+ disablenpc "Barzil";
end;
-OnTimer120000:
- if ($@SIEGE_HALI == 5) {
- mapannounce("009-1", "##1The Monster Colonel arrived!", bc_map);
- areamonster("009-1", 0, 0, 120, 155, ("Monster Colonel"), 1036, 1, "Lieutenant Jacob::OnColonelDeath");
- }
- areamonster("009-1", 0, 0, 120, 155, ("Slime Blast"), 1090, 15);
- areamonster("009-1", 0, 0, 120, 155, ("Black Scorpion"), 1074, 1, "Lieutenant Jacob::OnBlackScorpion2Death");
- areamonster("009-1", 0, 0, 120, 155, ("Green Slime"), 1085, 10, "Lieutenant Jacob::OnGreenSlimeDeath");
- areamonster("009-1", 0, 0, 120, 155, ("Mana Ghost"), 1068, 2, "Lieutenant Jacob::OnManaGhostDeath");
+OnTimer96000:
+ siege_cast("009-1", .name$, $@SIEGE_HALIN, TP_TULIM);
end;
OnTimer180000:
- areamonster("009-1", 0, 0, 120, 155, ("Slime Blast"), 1090, 25);
- areamonster("009-1", 0, 0, 120, 155, ("Black Scorpion"), 1074, 1, "Lieutenant Jacob::OnBlackScorpion2Death");
- areamonster("009-1", 0, 0, 120, 155, ("Candied Slime"), 1089, 10, "Lieutenant Jacob::OnCandiedSlimeDeath");
- areamonster("009-1", 0, 0, 120, 155, ("Mana Ghost"), 1068, 2, "Lieutenant Jacob::OnManaGhostDeath");
+ siege_boss("009-1", $@SIEGE_HALIN);
+ siege_cast("009-1", .name$, $@SIEGE_HALIN, TP_TULIM);
end;
-OnTimer240000:
- areamonster("009-1", 0, 0, 120, 155, ("Slime Blast"), 1090, 25);
- areamonster("009-1", 0, 0, 120, 155, ("Black Scorpion"), 1074, 1, "Lieutenant Jacob::OnBlackScorpion2Death");
- areamonster("009-1", 0, 0, 120, 155, ("Mana Ghost"), 1068, 2, "Lieutenant Jacob::OnManaGhostDeath");
- end;
-
-OnTimer300000:
- areamonster("009-1", 0, 0, 120, 155, ("Slime Blast"), 1090, 5);
- areamonster("009-1", 0, 0, 120, 155, ("Candied Slime"), 1089, 1, "Lieutenant Jacob::OnCandiedSlimeDeath");
- areamonster("009-1", 0, 0, 120, 155, ("Mana Ghost"), 1068, 1, "Lieutenant Jacob::OnManaGhostDeath");
- end;
-
-OnTimer360000:
+// At certain moments, the difficulty rises
+OnTimer210000:
OnTimer420000:
+OnTimer540000:
+ $@SIEGE_HALIN+=1;
+// Spawn each 45s after timer 120, difficulty raisers exempt (same for boss)
+OnTimer120000:
+OnTimer165000:
+//Timer 180000: BOSS WAVE
+//OnTimer210000: difficulty raiser
+OnTimer255000:
+OnTimer300000:
+OnTimer345000:
+OnTimer390000:
+//Timer 420000: difficulty raiser
+OnTimer435000:
OnTimer480000:
- areamonster("009-1", 0, 0, 120, 155, ("Slime Blast"), 1090, 5+$@SIEGE_HALI);
- areamonster("009-1", 0, 0, 120, 155, ("Red Slime"), 1092, 1+$@SIEGE_HALI);
+OnTimer525000:
+//OnTimer540000: difficulty raiser
+OnTimer570000:
+ siege_cast("009-1", .name$, $@SIEGE_HALIN, TP_TULIM);
end;
-OnTimer540000:
+OnTimer600000:
mapannounce("009-1", "##1The Monster Army is getting tired of resistance!", bc_map);
- areamonster("009-1", 0, 0, 120, 155, ("Slime Blast"), 1090, 5+$@SIEGE_HALI);
- areamonster("009-1", 0, 0, 120, 155, ("Mana Ghost"), 1068, 1, "Lieutenant Jacob::OnManaGhostDeath");
+ siege_cast("009-1", .name$, $@SIEGE_HALIN, TP_TULIM);
end;
-OnTimer600000:
+OnTimer660000:
+ $@MK_SCENE=MK_NONE;
+ $@MK_AGGRO=$@MK_AGGRO/20;
mapannounce("009-1", "##1The Monster King army is preparing to withdraw!", bc_map);
end;
-OnTimer630000:
- removemapmask "009-1", MASK_MATTACK;
- changemusic "009-1", "dragon_and_toast.ogg"; // Restore to default
+OnTimer690000:
+ siege_revert("009-1");
+ siege_revert("010-2");
enablenpc("Mana Stone");
- $@SIEGE_HALI$=0;
- killmonsterall("009-1", 0);
- killmonsterall("010-2", 0);
- pvpoff("009-1");
+ $@SIEGE_HALIN=0;
announce(("Halinarzo siege is over!"), bc_all);
+ enablenpc "Sawis";
+ enablenpc "Fisherman";
+ enablenpc "Charles, Trader King";
enablenpc "Lynn The Traveler";
+ enablenpc "Enliven Reva Foxhound";
+ enablenpc "Ryan";
+ enablenpc "Bella, the Scholar";
+ enablenpc "Book Keeper";
+ enablenpc "Yumi";
+ enablenpc "Halinarzo's Nurse";
+ enablenpc "Joaquim";
+ enablenpc "Alvasus";
+ enablenpc "Luanna";
+ enablenpc "Dang Rostra";
+ enablenpc "Kevin";
+ enablenpc "Barzil";
stopnpctimer;
end;
+
OnInit:
.sex = G_MALE;
.distance = 4;
// Check items.xml for info about this.
- // NOTE: Why Dausen item list is on Philip...?
- .@npcId = getnpcid("Lieutenant Jacob");
+ .@npcId = getnpcid(.name$);
setunitdata(.@npcId, UDT_HEADTOP, Bull);
setunitdata(.@npcId, UDT_HEADMIDDLE, LieutenantArmor);
setunitdata(.@npcId, UDT_HEADBOTTOM, RaidTrousers);
diff --git a/npc/014-3/_mobs.txt b/npc/014-3/_mobs.txt
index 50bb6dbfa..54539889d 100644
--- a/npc/014-3/_mobs.txt
+++ b/npc/014-3/_mobs.txt
@@ -1,6 +1,6 @@
// This file is generated automatically. All manually added changes will be removed when running the Converter.
// Map 014-3: Woodlands Central Area mobs
-014-3,115,75,91,52 monster Mouboo 1023,28,30000,45000
+014-3,115,75,91,52 monster Mouboo 1023,22,30000,45000
014-3,96,102,70,21 monster Forest Mushroom 1060,10,60000,45000
014-3,104,102,90,35 monster Squirrel 1032,26,30000,42000
014-3,44,82,37,32 monster Centaur 1139,3,80000,90000
diff --git a/npc/020-1/_import.txt b/npc/020-1/_import.txt
index 9dc8a5df6..ca7a3e6a9 100644
--- a/npc/020-1/_import.txt
+++ b/npc/020-1/_import.txt
@@ -2,6 +2,7 @@
// This file is generated automatically. All manually added changes will be removed when running the Converter.
"npc/020-1/_mobs.txt",
"npc/020-1/_warps.txt",
+"npc/020-1/guards.txt",
"npc/020-1/mapflags.txt",
"npc/020-1/misc.txt",
"npc/020-1/serge.txt",
diff --git a/npc/020-1/guards.txt b/npc/020-1/guards.txt
new file mode 100644
index 000000000..15d8b2122
--- /dev/null
+++ b/npc/020-1/guards.txt
@@ -0,0 +1,141 @@
+// TMW2 scripts.
+// Authors:
+// Jesusalva
+// Description:
+// Protect Nivalis
+
+020-1,49,48,0 script Lieutenant Joshua NPC_PLAYER,{
+ // The Monster King guild have a special menu
+ if (strcharinfo(2) == "Monster King") goto L_MKControl;
+
+ if ($NIVALIS_LIBDATE) {
+ mesn;
+ mesq l("Nivalis was liberated @@ ago.", FuzzyTime($NIVALIS_LIBDATE));
+ close;
+ } else {
+ legiontalk; end;
+ }
+
+// Respawn monster from $@SIEGE_TMPMOBS memory
+OnRespawn:
+ getmapxy(.@m$,.@x,.@y,0);
+ siege_spawn(.@m$, any_of($@SIEGE_TMPMOBS), 1, .name$+"::OnRespawn");
+ if (rand(10000) <= $coinsrate+($@SIEGE_NIVAL*50))
+ makeitem StrangeCoin, 1, .@m$, .@x, .@y;
+ end;
+
+
+L_MKControl:
+ mesn;
+ mes "Oh noes! You've found the Nivalis control panel!";
+ next;
+ select
+ l("Abort"),
+ l("Initiate a siege");
+ mes "";
+ if (@menu == 2) {
+ doevent "Lieutenant Joshua::OnStartSiege";
+ closedialog;
+ }
+ close;
+
+
+OnMKSiege:
+ $@SIEGE_NIVAL=rand(1,10);
+OnStartSiege:
+ siege_setup("019-2");
+ kamibroadcast(col("WARNING! WARNING! Monster Army marching towards Nivalis!!",1));
+ siege_cast("019-2", .name$, 0, TP_NIVAL);
+ initnpctimer;
+ end;
+
+// Timers
+OnTimer35000:
+ siege_setup("020-1");
+ siege_cast("019-2", .name$, $@SIEGE_NIVAL, TP_NIVAL);
+ mapannounce("020-1", "##2Message to all Nivalis NPCs: Take shelter!", bc_map);
+ disablenpc "Serge";
+ disablenpc "Knox The Traveler";
+ disablenpc "Camilot";
+ disablenpc "Mede";
+ disablenpc "Gambler#020-4";
+ disablenpc "Gambling Xan";
+ disablenpc "Baktar";
+ disablenpc "Bracco";
+ disablenpc "Agostine";
+ end;
+
+OnTimer65000:
+ siege_cast("020-1", .name$, 0, TP_NIVAL);
+ siege_cast("019-2", .name$, $@SIEGE_NIVAL, TP_NIVAL);
+ disablenpc "Ben#NivBanker";
+ end;
+
+OnTimer96000:
+ siege_cast("020-1", .name$, $@SIEGE_NIVAL, TP_NIVAL);
+ end;
+
+OnTimer180000:
+ siege_boss("020-1", $@SIEGE_NIVAL);
+ siege_cast("020-1", .name$, $@SIEGE_NIVAL, TP_NIVAL);
+ end;
+
+// At certain moments, the difficulty rises
+OnTimer210000:
+OnTimer420000:
+OnTimer540000:
+ $@SIEGE_NIVAL+=1;
+// Spawn each 45s after timer 120, difficulty raisers exempt (same for boss)
+OnTimer120000:
+OnTimer165000:
+//Timer 180000: BOSS WAVE
+//OnTimer210000: difficulty raiser
+OnTimer255000:
+OnTimer300000:
+OnTimer345000:
+OnTimer390000:
+//Timer 420000: difficulty raiser
+OnTimer435000:
+OnTimer480000:
+OnTimer525000:
+//OnTimer540000: difficulty raiser
+OnTimer570000:
+ siege_cast("020-1", .name$, $@SIEGE_NIVAL, TP_NIVAL);
+ end;
+
+OnTimer600000:
+ mapannounce("020-1", "##1The Monster Army is getting tired of resistance!", bc_map);
+ siege_cast("020-1", .name$, $@SIEGE_NIVAL, TP_NIVAL);
+ end;
+
+OnTimer660000:
+ $@MK_SCENE=MK_NONE;
+ $@MK_AGGRO=$@MK_AGGRO/20;
+ mapannounce("020-1", "##1The Monster King army is preparing to withdraw!", bc_map);
+ end;
+
+OnTimer690000:
+ siege_revert("020-1");
+ siege_revert("019-2");
+ enablenpc("Mana Stone");
+ $@SIEGE_NIVAL=0;
+ announce(("Nivalis siege is over!"), bc_all);
+ enablenpc "Serge";
+ enablenpc "Knox The Traveler";
+ enablenpc "Camilot";
+ enablenpc "Mede";
+ enablenpc "Gambler#020-4";
+ enablenpc "Gambling Xan";
+ enablenpc "Baktar";
+ enablenpc "Bracco";
+ enablenpc "Agostine";
+ enablenpc "Ben#NivBanker";
+ stopnpctimer;
+ end;
+
+OnInit:
+ end;
+
+
+}
+