diff options
author | ultramage <ultramage@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2008-01-03 21:36:40 +0000 |
---|---|---|
committer | ultramage <ultramage@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2008-01-03 21:36:40 +0000 |
commit | 1b241817a93f892a24379866a06e046e7e6c5e86 (patch) | |
tree | 72e6e27d29b8eca173b32b64d3b31592de7208c6 /src/map/npc.c | |
parent | 50418d820226fbcdf7609fb619028e3b75a2fa9e (diff) | |
download | hercules-1b241817a93f892a24379866a06e046e7e6c5e86.tar.gz hercules-1b241817a93f892a24379866a06e046e7e6c5e86.tar.bz2 hercules-1b241817a93f892a24379866a06e046e7e6c5e86.tar.xz hercules-1b241817a93f892a24379866a06e046e7e6c5e86.zip |
Map cell mechanism rewrite
- defined a data structure for map cells (replaces 3 various cell arrays)
- both terrain (gat) and dynamic (cell) information is now stored as C-style bit flags instead of #defines and bitmasks
- added map_gat2cell() and map_cell2gat() for terrain type conversions
- changing terrain information via 'setcell' is temporarily disabled
- mapserver startup now takes longer, as it needs to adapt mapcache data to internal representation, cell by cell (new mapcache format anyone?)
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@12003 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/npc.c')
-rw-r--r-- | src/map/npc.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/map/npc.c b/src/map/npc.c index ca4201428..6514fbb6a 100644 --- a/src/map/npc.c +++ b/src/map/npc.c @@ -2555,9 +2555,9 @@ static const char* npc_parse_mapcell(char* w1, char* w2, char* w3, char* w4, con swap(y0, y1); for( x = x0; x <= x1; ++x ) - for( y = y0; y <= y1; ++y ) { - int type = map_getcell(m, x, y, CELL_GETTYPE); - if (type == 1 || type == 5) //TODO: use defines for the cell types. + for( y = y0; y <= y1; ++y ) + { + if( map_getcell(m, x, y, CELL_CHKWALL) || map_getcell(m, x, y, CELL_CHKCLIFF) ) continue; map_setcell(m, x, y, cell); } |