summaryrefslogtreecommitdiff
path: root/npc
diff options
context:
space:
mode:
Diffstat (limited to 'npc')
-rw-r--r--npc/001-8/hub.txt29
-rw-r--r--npc/003-10/quirino.txt37
2 files changed, 66 insertions, 0 deletions
diff --git a/npc/001-8/hub.txt b/npc/001-8/hub.txt
index c6a9ea294..3fae0afab 100644
--- a/npc/001-8/hub.txt
+++ b/npc/001-8/hub.txt
@@ -8,9 +8,38 @@
001-8,0,0,0 script #QuirinoHUB NPC_HIDDEN,{
end;
+OnStart:
+ maptimer("001-8", 5000, "#QuirinoHUB::OnCount10");
+ announce("##1HUNGRY QUIRIN EVENT: ##3##BCountdown: 15 seconds!", bc_all|bc_npc);
+ end;
+
+OnCount10:
+ misceffect(4);
+ addtimer(5000, "#QuirinoHUB::OnCount5");
+ dispbottom l("10 seconds!");
+ end;
+
+OnCount5:
+ misceffect(4);
+ addtimer(5000, "#QuirinoHUB::OnBegin");
+ dispbottom l("5 seconds!");
+ end;
+
+OnBegin:
+ setpcblock(PCBLOCK_ATTACK|PCBLOCK_SKILL|PCBLOCK_ITEM|PCBLOCK_MOVE|PCBLOCK_COMMANDS, false);
+ misceffect(60);
+ misceffect(11);
+ dispbottom col("Run! Event started!", 1);
+ end;
+
+OnSendWave:
+ end;
+
OnPCLogoutEvent:
OnPCDieEvent:
+ if (checkpcblock() & PCBLOCK_ATTACK)
+ setpcblock(PCBLOCK_ATTACK|PCBLOCK_SKILL|PCBLOCK_ITEM|PCBLOCK_MOVE|PCBLOCK_COMMANDS, false);
getmapxy(.@mapa$, .@a,.@b, 0);
if (.@mapa$ == "001-8") {
clearitem();
diff --git a/npc/003-10/quirino.txt b/npc/003-10/quirino.txt
index 0ebea21c8..3f845b022 100644
--- a/npc/003-10/quirino.txt
+++ b/npc/003-10/quirino.txt
@@ -5,8 +5,14 @@
// Description:
// Hunger Games™ version for The Mana World Brazil v2, created by Ernando Quirino.
// Entrance to Hungry Quirin Arena
+// Variables:
+// $@EQ_STATUS
+// 0: Register open
+// 1: Fight happening
+// 2: Event finished
001-8,0,0,0 script Quirin NPC_ERNANDO,{
+ if (is_gm()) goto L_Hub;
if ($EVENT$ != "Hunger") goto L_NoSeason;
if ($@EQ_STATUS == 0)
goto L_Register;
@@ -75,6 +81,37 @@ L_Full:
mesq l("You cannot bring anything to the arena. Please put everything on the storage.");
close;
+L_Hub:
+ mesn;
+ mes col("Welcome to HUNGRY QUIRIN ARENA mangment panel.", 9);
+ mes col("Current Event: "+$EVENT$,9);
+ mes col("Event stage: "+$@EQ_STATUS, 9);
+ mes l("Current player count: @@/5 must be online.", getusers(1));
+ mes l("Current arena player count: @@ on map. (Min. 3 to begin event)", getmapusers("001-8"));
+
+ // Open event? Minimum 5 connections or GM_OVERRIDE flag.
+ if ($EVENT$ != "Hunger" && (getusers(1) >= 5 || $@GM_OVERRIDE)) {
+ next;
+ mes col("Activate event?", 1);
+ if (askyesno() == ASK_YES)
+ $EVENT$="Hunger";
+ close;
+ }
+
+ // Main Control menu. Not using l() on purpose.
+
+ select
+ rif($@EQ_STATUS == 0 && (getmapusers("001-8") >= 3 || $@GM_OVERRIDE), "Start Event!"),
+ rif($@EQ_STATUS == 1, "Send wave of items and monsters!"),
+ "I'm done.";
+
+ if (@menu == 1)
+ donpcevent("#QuirinoHUB::OnStart");
+ if (@menu == 2)
+ donpcevent("#QuirinoHUB::OnSendWave");
+
+ close;
+
OnInit:
.sex=G_MALE;
.distance=5;