| 1507 | } |
| 1508 | |
| 1509 | staticfn void |
| 1510 | reset_oattached_mids(boolean ghostly) |
| 1511 | { |
| 1512 | struct obj *otmp; |
| 1513 | unsigned oldid, nid; |
| 1514 | |
| 1515 | for (otmp = fobj; otmp; otmp = otmp->nobj) { |
| 1516 | if (ghostly && has_omonst(otmp)) { |
| 1517 | struct monst *mtmp = OMONST(otmp); |
| 1518 | |
| 1519 | mtmp->m_id = 0; |
| 1520 | mtmp->mpeaceful = mtmp->mtame = 0; /* pet's owner died! */ |
| 1521 | } |
| 1522 | if (ghostly && has_omid(otmp)) { |
| 1523 | oldid = OMID(otmp); |
| 1524 | if (lookup_id_mapping(oldid, &nid)) |
| 1525 | OMID(otmp) = nid; |
| 1526 | else |
| 1527 | free_omid(otmp); |
| 1528 | } |
| 1529 | } |
| 1530 | } |
| 1531 | |
| 1532 | #ifdef SELECTSAVED |
| 1533 | /* put up a menu listing each character from this player's saved games; |
no test coverage detected