summaryrefslogtreecommitdiff
path: root/npc/001-1/eventmaster.txt
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2019-05-18 19:13:15 -0300
committerJesusaves <cpntb1@ymail.com>2019-05-18 19:13:15 -0300
commit65791dcd1f757fffd41db0469f83f690b7a61bab (patch)
tree5e42b1d28ad91a0567c0e8f082321f5123bdf835 /npc/001-1/eventmaster.txt
parent523a2f203dac5264476d6db3775afc8e4ab32ba5 (diff)
downloadserverdata-65791dcd1f757fffd41db0469f83f690b7a61bab.tar.gz
serverdata-65791dcd1f757fffd41db0469f83f690b7a61bab.tar.bz2
serverdata-65791dcd1f757fffd41db0469f83f690b7a61bab.tar.xz
serverdata-65791dcd1f757fffd41db0469f83f690b7a61bab.zip
Rewrite boss loop on Aeros Event Master for easier maintenance
Diffstat (limited to 'npc/001-1/eventmaster.txt')
-rw-r--r--npc/001-1/eventmaster.txt54
1 files changed, 23 insertions, 31 deletions
diff --git a/npc/001-1/eventmaster.txt b/npc/001-1/eventmaster.txt
index 866a4c3f6..f4d422ba6 100644
--- a/npc/001-1/eventmaster.txt
+++ b/npc/001-1/eventmaster.txt
@@ -720,45 +720,31 @@ L_EventOnly:
L_Boss:
- select
- "Abort", // 1
- "Giant Mutated Bat", // 2
- "Murderer Scorpion" , // 3
- "Night Scorpion", // 4
- "Saxso Ghost", // 5
- "Bandit Lord", // 6
- "Fafi Dragon", // 7
- "Psi Conscience", // 8
- "The Yeti King"; // default
+ // Boss option preparatives
+ .@opt$="Abort";
+ debugmes "Found %d entries", getarraysize(.ML_Boss);
+ for (.@i=0;.@i < getarraysize(.ML_Boss);.@i++) {
+ .@opt$+=":"+strmobinfo(1, .ML_Boss[.@i]);
+ debugmes "Found monster: "+strmobinfo(1, .ML_Boss[.@i]);
+ }
+ select .@opt$;
+ // Select handler
if (@menu != 1)
input .@c, 0, 100;
if (.@c == 0 && @menu != 1)
@menu=99;
- switch (@menu) {
- case 1:
- goto L_Spawn;
- break;
- case 2:
- spawner(("GiantMutatedBat"), GiantMutatedBat, .@c); break;
- case 3:
- spawner(("MurdererScorpion"), MurdererScorpion, .@c); break;
- case 4:
- spawner(("NightScorpion"), NightScorpion, .@c); break;
- case 5:
- spawner(("SaxsoGhost"), SaxsoGhost, .@c); break;
- case 6:
- spawner(("BanditLord"), BanditLord, .@c); break;
- case 7:
- spawner(("Fafi"), FafiDragon, .@c); break;
- case 8:
- spawner(("Psi"), PsiConscience, .@c); break;
- default:
- spawner(("TheYetiKing"), TheYetiKing, .@c); break;
+ if (@menu == 1)
+ goto L_Spawn;
+ if (@menu == 99)
+ goto L_Boss;
- }
+ // Spawn if needed
+ .@i=@menu-2;
+ spawner(("BOSS Monster"), .ML_Boss[.@i], .@c);
+ // Log the spawn and resume
@log_spawns=@log_spawns+.@c;
mes "";
mes "Completed.";
@@ -873,6 +859,11 @@ OnAerosMobDeath:
OnInit:
if ($coinsrate == 0)
$coinsrate=400; // Default value is 4% + mob str bonus
+
+ // Monster lists
+ setarray .ML_Boss,
+ GiantMutatedBat, MurdererScorpion, NightScorpion, SaxsoGhost, BanditLord,
+ FafiDragon, PsiConscience, TerraniteKing, Yetifly, YetiKing;
end;
}
@@ -915,4 +906,5 @@ OnCall:
OnInit:
bindatcmd "aeros", "@aeros::OnCall", 99, 99, 0;
+ end;
}