… | |
… | |
1616 | * difficult to see what object is magical/cursed, so the |
1616 | * difficult to see what object is magical/cursed, so the |
1617 | * effect wouldn't be as apparent. |
1617 | * effect wouldn't be as apparent. |
1618 | */ |
1618 | */ |
1619 | |
1619 | |
1620 | /* detect magic */ |
1620 | /* detect magic */ |
1621 | if (spell->flag [FLAG_KNOWN_MAGICAL] && |
1621 | if (spell->flag [FLAG_KNOWN_MAGICAL] |
1622 | !tmp->flag [FLAG_KNOWN_MAGICAL] && !tmp->flag [FLAG_IDENTIFIED] && is_magical (tmp)) |
1622 | && !tmp->flag [FLAG_KNOWN_MAGICAL] |
|
|
1623 | && !tmp->flag [FLAG_IDENTIFIED] |
|
|
1624 | && tmp->need_identify () |
|
|
1625 | && is_magical (tmp)) |
1623 | { |
1626 | { |
1624 | tmp->set_flag (FLAG_KNOWN_MAGICAL); |
1627 | tmp->set_flag (FLAG_KNOWN_MAGICAL); |
1625 | /* make runes more visible */ |
1628 | /* make runes more visible */ |
1626 | if (tmp->type == RUNE && tmp->attacktype & AT_MAGIC) |
1629 | if (tmp->type == RUNE && tmp->attacktype & AT_MAGIC) |
1627 | tmp->stats.Cha /= 4; |
1630 | tmp->stats.Cha /= 4; |
… | |
… | |
1650 | |
1653 | |
1651 | if (!detect) |
1654 | if (!detect) |
1652 | detect = tmp; |
1655 | detect = tmp; |
1653 | } |
1656 | } |
1654 | |
1657 | |
1655 | if (spell->flag [FLAG_KNOWN_CURSED] && !tmp->flag [FLAG_KNOWN_CURSED] && |
1658 | if (spell->flag [FLAG_KNOWN_CURSED] |
|
|
1659 | && !tmp->flag [FLAG_KNOWN_CURSED] |
|
|
1660 | && tmp->need_identify () |
1656 | (tmp->flag [FLAG_CURSED] || tmp->flag [FLAG_DAMNED])) |
1661 | && (tmp->flag [FLAG_CURSED] || tmp->flag [FLAG_DAMNED])) |
1657 | { |
1662 | { |
1658 | tmp->set_flag (FLAG_KNOWN_CURSED); |
1663 | tmp->set_flag (FLAG_KNOWN_CURSED); |
1659 | done_one = 1; |
1664 | done_one = 1; |
1660 | } |
1665 | } |
1661 | |
1666 | |