summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-06-08 15:44:04 +0000
committerskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-06-08 15:44:04 +0000
commitfebdcd8873ad1198e80f6a3a4a4f55f2cc557911 (patch)
tree4e9755411e79ddf5bbf7a3c9cb18761007c32dba
parent3b364715dc1b63738c6684194d1e2481ccbd6256 (diff)
downloadhercules-febdcd8873ad1198e80f6a3a4a4f55f2cc557911.tar.gz
hercules-febdcd8873ad1198e80f6a3a4a4f55f2cc557911.tar.bz2
hercules-febdcd8873ad1198e80f6a3a4a4f55f2cc557911.tar.xz
hercules-febdcd8873ad1198e80f6a3a4a4f55f2cc557911.zip
- Updated mob_npc_warp to a three-state config switch. 0 disables. 1 enable only on warps that don't lead to nobranch maps. 2 - enable on all warps.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@7048 54d463be-8e91-2dee-dedb-b68131a5f0ec
-rw-r--r--Changelog-Trunk.txt10
-rw-r--r--conf-tmpl/battle/monster.conf8
-rw-r--r--src/map/npc.c4
3 files changed, 16 insertions, 6 deletions
diff --git a/Changelog-Trunk.txt b/Changelog-Trunk.txt
index ee3fdf8d4..11505388d 100644
--- a/Changelog-Trunk.txt
+++ b/Changelog-Trunk.txt
@@ -3,13 +3,17 @@ Date Added
AS OF SVN REV. 5091, WE ARE NOW USING TRUNK. ALL UNTESTED BUGFIXES/FEATURES GO INTO TRUNK.
IF YOU HAVE A WORKING AND TESTED BUGFIX PUT IT INTO STABLE AS WELL AS TRUNK.
-2006/06/07
- - Adjusted Don't Forget Me, Defender, Longing to use all val entries, and
+2006/06/08
+ * Updated mob_npc_warp to a three-state config switch. 0 disables. 1 enable
+ only on warps that don't lead to nobranch maps. 2 - enable on all warps.
+ [Skotlex]
+ * Adjusted Don't Forget Me, Defender, Longing to use all val entries, and
to hold the speed adjustment value rather than speed penalty (eg: 125
instead of 25). [Skotlex]
- - Cleaned up status_calc_speed so that speed penalties are correctly
+ * Cleaned up status_calc_speed so that speed penalties are correctly
handled (eg: 25% penalty is speed*100/75, not +speed*25/100). Thanks to
Euph for pointing it out and Belle for the speed mechanics. [Skotlex]
+2006/06/07
* Fixed Sense using mdef instead of mdef2 [Skotlex]
* Fixed item-skills not showing up on login. [Skotlex]
* Cleaned up clif_parseLoadEndAck, by testing which packets are required
diff --git a/conf-tmpl/battle/monster.conf b/conf-tmpl/battle/monster.conf
index 59cd67b0d..beb14ed49 100644
--- a/conf-tmpl/battle/monster.conf
+++ b/conf-tmpl/battle/monster.conf
@@ -66,9 +66,11 @@ monster_max_aspd: 199
// any npc-warps in it's sight of view (use with mob_npc_warp below)
monster_ai: 0
-// Should mobs that stand on an npc warp be warped to the destination cell?
-// (Note 1)
-mob_npc_warp: no
+// Should mobs that stand on an npc warp be warped to the destination cell?
+// 0: Disable.
+// 1: Enable on all warps except those that lead to 'nobranch' maps.
+// 2: Enable on all warps.
+mob_npc_warp: 0
// Mobs and Pets view-range adjustment (range2 column in the mob_db) (Note 2)
view_range_rate: 100
diff --git a/src/map/npc.c b/src/map/npc.c
index e9e472721..e9ddb3e53 100644
--- a/src/map/npc.c
+++ b/src/map/npc.c
@@ -996,6 +996,10 @@ int npc_touch_areanpc2(struct block_list *bl)
xs = map_mapindex2mapid(map[m].npc[i]->u.warp.mapindex);
if (xs < 0) // Can't warp object between map servers...
return 0;
+
+ if(battle_config.mob_npc_warp<2 && map[xs].flag.nobranch)
+ return 0; //Disable warps to nobranch maps.
+
unit_warp(bl, xs, map[m].npc[i]->u.warp.x,map[m].npc[i]->u.warp.y,0);
return 1;
}