comparison rogue3/misc.c @ 304:e52a8a7ad4c5

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.
author John "Elwin" Edwards
date Wed, 14 Apr 2021 18:55:33 -0400
parents e7862a021609
children
comparison
equal deleted inserted replaced
303:e06ebc407615 304:e52a8a7ad4c5
99 /* 99 /*
100 * Don't show room walls if he is in a passage 100 * Don't show room walls if he is in a passage
101 */ 101 */
102 if (off(player, ISBLIND)) 102 if (off(player, ISBLIND))
103 { 103 {
104 if (y == hero.y && x == hero.x 104 if ((y == hero.y && x == hero.x)
105 || (inpass && (ch == '-' || ch == '|'))) 105 || (inpass && (ch == '-' || ch == '|')))
106 continue; 106 continue;
107 } 107 }
108 else if (y != hero.y || x != hero.x) 108 else if (y != hero.y || x != hero.x)
109 continue; 109 continue;
182 182
183 cp.y = y; 183 cp.y = y;
184 cp.x = x; 184 cp.x = x;
185 cpp = &cp; 185 cpp = &cp;
186 for (rp = rooms, i = 0; i < MAXROOMS; rp++, i++) 186 for (rp = rooms, i = 0; i < MAXROOMS; rp++, i++)
187 {
187 if (inroom(rp, cpp)) 188 if (inroom(rp, cpp))
189 {
188 if (y == rp->r_pos.y || y == rp->r_pos.y + rp->r_max.y - 1) 190 if (y == rp->r_pos.y || y == rp->r_pos.y + rp->r_max.y - 1)
189 return('-'); 191 return('-');
190 else 192 else
191 return('|'); 193 return('|');
192 194 }
195 }
193 return('p'); 196 return('p');
194 } 197 }
195 198
196 /* 199 /*
197 * find_obj: 200 * find_obj: