| 3463 | |
| 3464 | /* returns first matching monster */ |
| 3465 | staticfn struct monst * |
| 3466 | monstinroom(struct permonst *mdat, int roomno) |
| 3467 | { |
| 3468 | struct monst *mtmp; |
| 3469 | |
| 3470 | for (mtmp = fmon; mtmp; mtmp = mtmp->nmon) { |
| 3471 | if (DEADMONSTER(mtmp)) |
| 3472 | continue; |
| 3473 | if (mtmp->data == mdat |
| 3474 | && strchr(in_rooms(mtmp->mx, mtmp->my, 0), roomno + ROOMOFFSET)) |
| 3475 | return mtmp; |
| 3476 | } |
| 3477 | return (struct monst *) 0; |
| 3478 | } |
| 3479 | |
| 3480 | /* check whether room contains a particular type of furniture */ |
| 3481 | staticfn boolean |
no test coverage detected