summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-04-12 17:30:04 +0000
committerskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-04-12 17:30:04 +0000
commitabf4cb1ae6eeaabd9fc9020160e985fff105f73f (patch)
tree98a4231025d9190457483054331469ddd5b79379
parentbcc52789b31adc1357935fb347ee78f9f43dda19 (diff)
downloadhercules-abf4cb1ae6eeaabd9fc9020160e985fff105f73f.tar.gz
hercules-abf4cb1ae6eeaabd9fc9020160e985fff105f73f.tar.bz2
hercules-abf4cb1ae6eeaabd9fc9020160e985fff105f73f.tar.xz
hercules-abf4cb1ae6eeaabd9fc9020160e985fff105f73f.zip
- Expanded the warp warning so that it also warns when a warps takes you to a non-walkable tile.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@6019 54d463be-8e91-2dee-dedb-b68131a5f0ec
-rw-r--r--Changelog-Trunk.txt2
-rw-r--r--src/map/npc.c23
2 files changed, 16 insertions, 9 deletions
diff --git a/Changelog-Trunk.txt b/Changelog-Trunk.txt
index c9332fac5..66701af41 100644
--- a/Changelog-Trunk.txt
+++ b/Changelog-Trunk.txt
@@ -4,6 +4,8 @@ AS OF SVN REV. 5091, WE ARE NOW USING TRUNK. ALL UNTESTED BUGFIXES/FEATURES GO
IF YOU HAVE A WORKING AND TESTED BUGFIX PUT IT INTO STABLE AS WELL AS TRUNK.
2006/04/12
+ * Expanded the warp warning so that it also warns when a warps takes you to
+ a non-walkable tile. [Skotlex]
* Simplified the mob-drops structure by using a single timer with a linked
list of drops instead of separate timers for each drop. [Skotlex]
2006/04/11
diff --git a/src/map/npc.c b/src/map/npc.c
index da1487809..cfe3a31a6 100644
--- a/src/map/npc.c
+++ b/src/map/npc.c
@@ -2680,15 +2680,20 @@ static void npc_debug_warps_sub(struct npc_data *nd)
m = map_mapindex2mapid(nd->u.warp.mapindex);
if (m < 0) return; //Warps to another map, nothing to do about it.
- if (!map_getcell(m, nd->u.warp.x, nd->u.warp.y, CELL_CHKNPC))
- return;
-
- ShowWarning("Warp %s/%s at %s(%d,%d) warps directly on top of an area npc at %s(%d,%d)\n",
- nd->name, nd->exname,
- map[nd->bl.m].name, nd->bl.x, nd->bl.y,
- map[m].name, nd->u.warp.x, nd->u.warp.y
- );
-
+ if (map_getcell(m, nd->u.warp.x, nd->u.warp.y, CELL_CHKNPC)) {
+ ShowWarning("Warp %s at %s(%d,%d) warps directly on top of an area npc at %s(%d,%d)\n",
+ nd->name,
+ map[nd->bl.m].name, nd->bl.x, nd->bl.y,
+ map[m].name, nd->u.warp.x, nd->u.warp.y
+ );
+ }
+ if (map_getcell(m, nd->u.warp.x, nd->u.warp.y, CELL_CHKNOPASS)) {
+ ShowWarning("Warp %s at %s(%d,%d) warps to a non-walkable tile at %s(%d,%d)\n",
+ nd->name,
+ map[nd->bl.m].name, nd->bl.x, nd->bl.y,
+ map[m].name, nd->u.warp.x, nd->u.warp.y
+ );
+ }
}
static void npc_debug_warps(void)