Difference between revisions of "Search"

From NetHackWiki
Jump to navigation Jump to search
(Restructured, more about chance of success)
(Gritty details for those who like numbers; auto-search doesn't find monsters)
Line 9: Line 9:
 
No other factors affect the success rate of searching.
 
No other factors affect the success rate of searching.
  
The [[automatic searching]] property will cause you to automatically search (just like using the command) every turn.  Some roles can gain this as an [[intrinsic]], and it is granted by wielding [[Excalibur]] or wearing a [[ring of searching]].
+
The [[automatic searching]] property will cause you to automatically search (just like using the command, except that it does not find monsters) every turn.  Some roles can gain this as an [[intrinsic]], and it is granted by wielding [[Excalibur]] or wearing a [[ring of searching]].
 +
 
 +
== Details ==
 +
 
 +
{{for2|source reference|{{function|detect.c|dosearch0}}}}
 +
 
 +
=== Secret Doors and Corridors ===
 +
 
 +
* Lenses give a searching bonus of +2 if you are not blind.
 +
* Excalibur gives a searching bonus equal to its enchantment. (Nothing prevents this from being a penalty if Excalibur is negatively enchanted.)
 +
* Your bonus cannot exceed 5.
 +
* You will find a secret door or corridor if [[rnl]](7-bonus) is zero.
 +
 
 +
=== Traps ===
 +
 
 +
* You will find a trap if [[rnl]](8) is zero.
 +
* This will activate statue traps (exercising wisdom), and reveal other traps.
  
 
[[Category:Commands]]
 
[[Category:Commands]]

Revision as of 18:05, 4 December 2008

The search command, which is used by pressing the [s] key, causes you to search the 8 squares surrounding you for secret doors, secret corridors, hidden monsters, and hidden traps. It may require more than one attempt to locate many of these.

Searching will always reveal hidden or invisible monsters which are in any square adjacent to you.

Your chance of success for other forms of searching is primarily dependent on Luck.

Wielding Excalibur improves your chance of finding secret doors and secret corridors based on its enchantment. Wearing any sort of lenses also improves your chance of finding these.

No other factors affect the success rate of searching.

The automatic searching property will cause you to automatically search (just like using the command, except that it does not find monsters) every turn. Some roles can gain this as an intrinsic, and it is granted by wielding Excalibur or wearing a ring of searching.

Details

For source reference, see dosearch0 in detect.c.

Secret Doors and Corridors

  • Lenses give a searching bonus of +2 if you are not blind.
  • Excalibur gives a searching bonus equal to its enchantment. (Nothing prevents this from being a penalty if Excalibur is negatively enchanted.)
  • Your bonus cannot exceed 5.
  • You will find a secret door or corridor if rnl(7-bonus) is zero.

Traps

  • You will find a trap if rnl(8) is zero.
  • This will activate statue traps (exercising wisdom), and reveal other traps.