diff options
author | Adam Borowski <kilobyte@angband.pl> | 2012-05-04 16:54:41 +0200 |
---|---|---|
committer | Adam Borowski <kilobyte@angband.pl> | 2012-05-05 02:35:56 +0200 |
commit | f859cfa822abd9410a003f8ff7b8470bb67c798c (patch) | |
tree | d4c87b986b0663240f7e02343136bc7b48becbfd /crawl-ref/source/skills.cc | |
parent | 88d4e91b7baca1f156d6a41f5f5b53027365e497 (diff) | |
download | crawl-ref-f859cfa822abd9410a003f8ff7b8470bb67c798c.tar.gz crawl-ref-f859cfa822abd9410a003f8ff7b8470bb67c798c.zip |
Roll only once for identifying weapons by use.
You could tediously id anything by bashing a plant or throwing it at a wall,
with as little as 0.1 skill. This is no more: every weapon has a secret
skill level needed to auto-id it. You must know enough about the weapon to
possibly id it under the old system -- having wielded it once is enough, so
are certain other ways. I intentionally didn't go into the complexity of
checking current curse status or blocking distortion/vamp.
Save compat: on training a weapon skill and certain other events for the
first time, you'll get unsightly ids of a bunch of items. Probably not
worth any effort, you are very unlikely to get multiple ids at once during
normal play.
This commit does not handle missiles: they are mergeable and thus don't have
an unique random number, it would be enough to id one with the smallest
number and then merge stacks, you are currently encouraged to keep one of
every missile with different enchantments, etc.
Diffstat (limited to 'crawl-ref/source/skills.cc')
-rw-r--r-- | crawl-ref/source/skills.cc | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/crawl-ref/source/skills.cc b/crawl-ref/source/skills.cc index a411f28867..d1e5be98bd 100644 --- a/crawl-ref/source/skills.cc +++ b/crawl-ref/source/skills.cc @@ -22,6 +22,7 @@ #include "invent.h" #include "itemprop.h" #include "message.h" +#include "misc.h" #include "notes.h" #include "output.h" #include "player.h" @@ -216,6 +217,10 @@ void redraw_skill(skill_type exsk, skill_type old_best_skill) // The player symbol depends on best skill title. update_player_symbol(); } + + // Identify weapon pluses. + if (exsk <= SK_THROWING) + auto_id_inventory(); } void check_skill_level_change(skill_type sk, bool do_level_up) |