summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2021-01-13 19:05:20 -0300
committerJesusaves <cpntb1@ymail.com>2021-01-13 19:05:20 -0300
commitc3d9873fbf3a5076a3b435e312e748e7e440353c (patch)
tree42050c69cbc6751c259c517412f11b625b779a09
parentb225b6db0ce92d35f78c8c64b426fe0e06aff2ec (diff)
downloadserverdata-c3d9873fbf3a5076a3b435e312e748e7e440353c.tar.gz
serverdata-c3d9873fbf3a5076a3b435e312e748e7e440353c.tar.bz2
serverdata-c3d9873fbf3a5076a3b435e312e748e7e440353c.tar.xz
serverdata-c3d9873fbf3a5076a3b435e312e748e7e440353c.zip
Add some progress to Fortress Island. Kinda. Okay, that is a half lie.
-rw-r--r--db/re/mob_db.conf6
-rw-r--r--npc/025-1/ctrl.c39
2 files changed, 42 insertions, 3 deletions
diff --git a/db/re/mob_db.conf b/db/re/mob_db.conf
index dc0a229d6..3a6300f3e 100644
--- a/db/re/mob_db.conf
+++ b/db/re/mob_db.conf
@@ -10140,6 +10140,9 @@ mob_db: (
Mdef: 100
Race: 3
Element: (2, 1)
+ Stats: {
+ Luk: 127
+ }
Mode: {
CanMove: false
CanAttack: false
@@ -10160,6 +10163,9 @@ mob_db: (
Mdef: 100
Race: 3
Element: (2, 1)
+ Stats: {
+ Luk: 127
+ }
Mode: {
CanMove: false
CanAttack: false
diff --git a/npc/025-1/ctrl.c b/npc/025-1/ctrl.c
index 7c0090069..483f70c5f 100644
--- a/npc/025-1/ctrl.c
+++ b/npc/025-1/ctrl.c
@@ -11,9 +11,9 @@
// 0 - Locked
// 1 - Unlocked
// $@FORTRESS_STATUE = bitmask
-// 1,2,4,8... broken statues
+// 1,2,4,8,16 - broken statues
+// 1024 - Fortress Gate
// TODO: Use bg() - maybe with dummysd? What will increase allies count?
-// mapwarp() everyone outside when FTCleanup(false)
// TODO: Gate control during siege (not $FORTRESS_STATE). Gate monster.
// TODO: Spawn the monster general for each statue. Count their deaths.
// TODO: Spawn Monster Governor (and add it) once statue is broken. ::OnConquest
@@ -119,19 +119,52 @@ function script FTStatue {
// Hey, you can assault the town!
mesc ".:: "+l("THE FORTRESS ISLAND TOWN") + " ::.", 1;
mes l("Behind this gate, lies the Fortress Island Town.");
- //monster(FortressGate, ::OnOpenGate)
+ next;
+ mesc ".:: "+l("THE FORTRESS ISLAND TOWN") + " ::.", 1;
+ mes l("Assault?");
+ mesc l("Lorem ipsum dolor sit amet"), 1;
+ next;
+ if (askyesno() == ASK_NO)
+ close;
+
+ // FIRE THE EVENT
+ disablenpc .name$;
+ initnpctimer;
+
+ // Spawn the gate
+ monster("025-1", 99, 113, "Fortress Gate", FortressGate, 1, .name$+"::OnOpenGate");
+ // TODO: Initial defending waves
+ // TODO: Enable the statues
+ // TODO: Summon reinforcements
close;
+/////////////////////////////////////////////////////////
+OnOpenGate:
+ // FIXME Broken
+ $@FORTRESS_STATUE = $@FORTRESS_STATUE|1024;
+ donpcevent "#025-1_99_112::OnDisable";
+ kamibroadcast("The Fortress Town Gate has been breached!");
+ close;
+
+OnTimer30000:
+ // TODO: Spawn mobs
+ .@breach=($@FORTRESS_STATUE & 1024);
+ initnpctimer;
+ end;
+
+/////////////////////////////////////////////////////////
OnInit:
FTCleanup($FORTRESS_STATE);
end;
OnTue0000:
FTCleanup(false);
+ enablenpc .name$;
end;
OnConquest:
FTCleanup(true);
+ disablenpc .name$;
end;
}