Skip to content

Commit

Permalink
Fixed problem with blood etc covering up items
Browse files Browse the repository at this point in the history
  • Loading branch information
Whales committed Sep 25, 2012
1 parent b5924a2 commit 16331bb
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
# DEBUG is best turned on if you plan to debug in gdb -- please do!
# PROFILE is for use with gprof or a similar program -- don't bother generally
#WARNINGS = -Wall -Wextra -Wno-switch -Wno-sign-compare -Wno-missing-braces -Wno-unused-parameter -Wno-char-subscripts
DEBUG = -g
#DEBUG = -g
#PROFILE = -pg
#OTHERS = -O3
OTHERS = -O3

ODIR = obj
DDIR = .deps
Expand Down
7 changes: 5 additions & 2 deletions map.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1800,7 +1800,8 @@ void map::draw(game *g, WINDOW* w, point center)
{
for (int i = 0; i < my_MAPSIZE * my_MAPSIZE; i++) {
if (!grid[i])
debugmsg("grid %d (%d, %d) is null! mapbuffer size = %d", i, i % my_MAPSIZE, i / my_MAPSIZE, MAPBUFFER.size());
debugmsg("grid %d (%d, %d) is null! mapbuffer size = %d",
i, i % my_MAPSIZE, i / my_MAPSIZE, MAPBUFFER.size());
}
int t = 0;
int light = g->u.sight_range(g->light_level());
Expand Down Expand Up @@ -1878,8 +1879,10 @@ void map::drawsq(WINDOW* w, player &u, int x, int y, bool invert,
case 4: sym = '&'; break;
case 5: sym = '+'; break;
}
} else if (fieldlist[field_at(x, y).type].sym != '%')
} else if (fieldlist[field_at(x, y).type].sym != '%') {
sym = fieldlist[field_at(x, y).type].sym;
drew_field = false;
}
}
// If there's items here, draw those instead
if (show_items && i_at(x, y).size() > 0 && !drew_field) {
Expand Down

0 comments on commit 16331bb

Please sign in to comment.