- d = get_map_object_def(world, o->type);
- c = d->char_on_map;
- mvwaddch(win->frame.curses_win,
- o->pos.y - map->offset.y, o->pos.x - map->offset.x, c);
+ if ( ( (0 == i && 0 == o->lifepoints) /* Draw in-animate */
+ || (1 == i && 0 < o->lifepoints)) /* objects first. */
+ && o->pos.y >= map->offset.y
+ && o->pos.y < map->offset.y + win->frame.size.y
+ && o->pos.x >= map->offset.x
+ && o->pos.x < map->offset.x + win->frame.size.x)
+ {
+ d = get_map_object_def(world, o->type);
+ c = d->char_on_map;
+ mvwaddch(win->frame.curses_win,
+ o->pos.y - map->offset.y, o->pos.x - map->offset.x, c);
+ }