diff options
Diffstat (limited to 'npc')
-rw-r--r-- | npc/006-7/ctrl.txt | 26 |
1 files changed, 23 insertions, 3 deletions
diff --git a/npc/006-7/ctrl.txt b/npc/006-7/ctrl.txt index d18513046..892253b92 100644 --- a/npc/006-7/ctrl.txt +++ b/npc/006-7/ctrl.txt @@ -51,8 +51,8 @@ OnRw: .@mlt = (.hard ? 15 : 10); // Basic attributes - setunitdata(.BOSS, UDT_MAXHP, 1000000 * .@mlt / 10); // 1M ~ 1.5M - setunitdata(.BOSS, UDT_HP, 1000000 * .@mlt / 10); + setunitdata(.BOSS, UDT_MAXHP, 750000 * .@mlt / 10); // 750k ~ 1250k + setunitdata(.BOSS, UDT_HP, 750000 * .@mlt / 10); setunitdata(.BOSS, UDT_ATKRANGE, (.hard ? 7 : 6)); // Reconfigure the AI @@ -110,11 +110,30 @@ OnTimer5000: npctalk "The battle is over!"; .ticks = min(.ticks, gettimetick(2) + 1800); // Min. Cooldown: 30 min .beats = 0; + .warn = 0; $@ICICLE_CHALLENGE = false; stopnpctimer; end; } + /* Warn players when time is about to end */ + if (.ticks - 1800 < gettimetick(2) && .warn < 1) { + mapannounce("006-7", "Warning : ##1##BTime left: 30 minutes##b", 0); + .warn = 1; + } + else if (.ticks - 900 < gettimetick(2) && .warn < 2) { + mapannounce("006-7", "Warning : ##1##BTime left: 15 minutes##b", 0); + .warn = 2; + } + else if (.ticks - 600 < gettimetick(2) && .warn < 3) { + mapannounce("006-7", "Warning : ##1##BTime left: 10 minutes##b", 0); + .warn = 3; + } + else if (.ticks - 300 < gettimetick(2) && .warn < 4) { + mapannounce("006-7", "Warning : ##1##BTime left: 5 minutes##b", 0); + .warn = 4; + } + /* Prepare some data */ .@hp = getunitdata(.BOSS, UDT_HP) * 10 / getunitdata(.BOSS, UDT_MAXHP); getmapxy(.@m$, .@x, .@y, UNITTYPE_MOB, .BOSS); @@ -172,7 +191,7 @@ OnTimer5000: unittalk(.BOSS, sprintf("This battle is over, %s! ##BNapalm Beat##b!", strcharinfo(0, "cursed player", .@mvp))); .@PW=35; .@SPW=5; .@RG=2; } - .@mtk = calcdmg(.BOSS, .@mvp, HARM_MAGI) * 2; + .@mtk = calcdmg(.BOSS, .@mvp, HARM_MAGI); .@dmg = .@mtk * .@PW / 100; .@dsb = .@mtk * .@SPW / 100; sleep(1000); @@ -320,6 +339,7 @@ OnInit: .ticks = gettimetick(2); .beats = 0; .hard = 0; + .warn = 0; end; } |