| 327 | } |
| 328 | |
| 329 | staticfn void |
| 330 | set_entity( |
| 331 | coordxy x, coordxy y, /* location of span or portcullis */ |
| 332 | struct entity *etmp) /* pointer to occupants[0] or occupants[1] */ |
| 333 | { |
| 334 | if (u_at(x, y)) |
| 335 | u_to_e(etmp); |
| 336 | else /* m_at() might yield Null; that's ok */ |
| 337 | m_to_e(m_at(x, y), x, y, etmp); |
| 338 | } |
| 339 | |
| 340 | #define is_u(etmp) (etmp->emon == &gy.youmonst) |
| 341 | #define e_canseemon(etmp) (is_u(etmp) || canseemon(etmp->emon)) |
no test coverage detected