diff options
author | Jesusaves <cpntb1@ymail.com> | 2019-05-06 20:43:07 -0300 |
---|---|---|
committer | Jesusaves <cpntb1@ymail.com> | 2019-05-06 20:43:07 -0300 |
commit | be79c5220d6c1f7114f9497d39b19104b08a38ec (patch) | |
tree | a0d289ef54fd49bf827d488e49f7264d71588d13 | |
parent | 775a9189eef5c5c87363566f4bb13e450791f6e4 (diff) | |
download | serverdata-be79c5220d6c1f7114f9497d39b19104b08a38ec.tar.gz serverdata-be79c5220d6c1f7114f9497d39b19104b08a38ec.tar.bz2 serverdata-be79c5220d6c1f7114f9497d39b19104b08a38ec.tar.xz serverdata-be79c5220d6c1f7114f9497d39b19104b08a38ec.zip |
During Sieges, change map zone from <town> to <MMO>, limiting what GMs can do
during sieges.
-rw-r--r-- | npc/functions/siege.txt | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/npc/functions/siege.txt b/npc/functions/siege.txt index 4fe0bebf7..3c8b61d37 100644 --- a/npc/functions/siege.txt +++ b/npc/functions/siege.txt @@ -156,10 +156,15 @@ function script siege_selectmob { function script siege_setup { .@m$=getarg(0); + // Save old map zone + $@MZONE$[getmapinfo(MAPINFO_ID, .@m$)]=getmapinfo(MAPINFO_ZONE, .@m$); + + // Apply changes addmapmask .@m$, MASK_MATTACK; changemusic .@m$, any("mythica.ogg", "eric_matyas_ghouls.ogg", "misuse.ogg", "Arabesque.ogg"); disablenpc("Mana Stone"); pvpon(.@m$); + setmapflag(.@m$,mf_zone,"MMO"); // MMO Zone: Overrides GM Commands setmapflag(.@m$,mf_bexp,rand(120,140)); // 20~40% EXP UP on siege maps return; } @@ -169,6 +174,10 @@ function script siege_setup { function script siege_revert { .@m$=getarg(0); + // Revert map zone and delete backup + setmapflag(.@m$,mf_zone,$@MZONE$[getmapinfo(MAPINFO_ID, .@m$)]); + $@MZONE$[getmapinfo(MAPINFO_ID, .@m$)]=""; + removemapmask .@m$, MASK_MATTACK; changemusic .@m$, "caketown.ogg"; // :> enablenpc("Mana Stone"); |