Fix many compiler warnings.
There should only be two changes in behavior: arogue7/fight.c, arogue7/fight.c: a to-hit bonus is now correctly applied to characters who are not monks instead of monks who are not empty-handed. urogue/fight.c: fixed an interaction with the "debug" macro that could cause the wrong message to be displayed.
This commit is contained in:
parent
6f21b5b88a
commit
6c3cd116ff
122 changed files with 374 additions and 280 deletions
|
|
@ -297,7 +297,7 @@ fallpos(coord *pos, bool be_clear, int range)
|
|||
ret.y < 1 || ret.y > lines - 3)
|
||||
continue; /* off the screen? */
|
||||
|
||||
ch = winat(ret.y, ret.x);
|
||||
ch = winat(ret.y, ret.x) & A_CHARTEXT;
|
||||
|
||||
/*
|
||||
* Check to make certain the spot is valid
|
||||
|
|
@ -692,7 +692,7 @@ look(bool wakeup, bool runend)
|
|||
if (y < 1 || y > lines - 3) continue;
|
||||
|
||||
/* See what's there -- ignore monsters, just see what they're on */
|
||||
savech = mvwinch(mw, y, x);
|
||||
savech = mvwinch(mw, y, x) & A_CHARTEXT;
|
||||
waddch(mw, ' ');
|
||||
ch = show(y, x);
|
||||
mvwaddch(mw, y, x, savech); /* Restore monster */
|
||||
|
|
@ -750,7 +750,8 @@ look(bool wakeup, bool runend)
|
|||
mvwaddch(cw, y, x, in_room ? ' ' : PASSAGE);
|
||||
|
||||
/* If we found a monster, set it to darkness! */
|
||||
if (it) (THINGPTR(it))->t_oldch = mvwinch(cw, y, x);
|
||||
if (it) (THINGPTR(it))->t_oldch = mvwinch(cw, y, x) &
|
||||
A_CHARTEXT;
|
||||
}
|
||||
|
||||
/* Moving out of a corridor? */
|
||||
|
|
@ -794,7 +795,7 @@ look(bool wakeup, bool runend)
|
|||
|
||||
if (it) {
|
||||
tp = THINGPTR(it);
|
||||
tp->t_oldch = mvinch(y, x);
|
||||
tp->t_oldch = mvinch(y, x) & A_CHARTEXT;
|
||||
if (isatrap(tp->t_oldch)) {
|
||||
register struct trap *trp = trap_at(y, x);
|
||||
|
||||
|
|
@ -818,7 +819,7 @@ look(bool wakeup, bool runend)
|
|||
*/
|
||||
if (off(player, ISBLIND))
|
||||
{
|
||||
if (y == hero.y && x == hero.x
|
||||
if ((y == hero.y && x == hero.x)
|
||||
|| (inpass && (ch == HORZWALL || ch == VERTWALL)))
|
||||
continue;
|
||||
|
||||
|
|
@ -1011,7 +1012,7 @@ move_hero(int why)
|
|||
msg("Where do you wish to %s to? (* for help) ", action);
|
||||
c = get_coordinates();
|
||||
mpos = 0;
|
||||
which = winat(c.y, c.x);
|
||||
which = winat(c.y, c.x) & A_CHARTEXT;
|
||||
switch (which) {
|
||||
default:
|
||||
if (!isrock(which) || off(player, CANINWALL)) break;
|
||||
|
|
@ -1169,12 +1170,14 @@ secretdoor(int y, int x)
|
|||
cp.y = y;
|
||||
cp.x = x;
|
||||
cpp = &cp;
|
||||
for (rp = rooms, i = 0; i < MAXROOMS; rp++, i++)
|
||||
if (inroom(rp, cpp))
|
||||
for (rp = rooms, i = 0; i < MAXROOMS; rp++, i++) {
|
||||
if (inroom(rp, cpp)) {
|
||||
if (y == rp->r_pos.y || y == rp->r_pos.y + rp->r_max.y - 1)
|
||||
return(HORZWALL);
|
||||
else
|
||||
return(VERTWALL);
|
||||
}
|
||||
}
|
||||
|
||||
return('p');
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue