MCPcopy Index your code
hub / github.com/NetHack/NetHack / wiz_map

Function wiz_map

src/wizcmds.c:175–199  ·  view source on GitHub ↗

the #wizmap command - reveal the level map and any traps or engravings on it */

Source from the content-addressed store, hash-verified

173/* the #wizmap command - reveal the level map
174 and any traps or engravings on it */
175int
176wiz_map(void)
177{
178 if (wizard) {
179 struct trap *t;
180 struct engr *ep;
181 long save_Hconf = HConfusion, save_Hhallu = HHallucination;
182
183 notice_mon_off();
184 HConfusion = HHallucination = 0L;
185 for (t = gf.ftrap; t != 0; t = t->ntrap) {
186 t->tseen = 1;
187 map_trap(t, TRUE);
188 }
189 for (ep = head_engr; ep != 0; ep = ep->nxt_engr) {
190 map_engraving(ep, TRUE);
191 }
192 do_mapping();
193 notice_mon_on();
194 HConfusion = save_Hconf;
195 HHallucination = save_Hhallu;
196 } else
197 pline(unavailcmd, ecname_from_fn(wiz_map));
198 return ECMD_OK;
199}
200
201/* #wizgenesis - generate monster(s); a count prefix will be honored */
202int

Callers

nothing calls this directly

Calls 5

map_trapFunction · 0.85
map_engravingFunction · 0.85
do_mappingFunction · 0.85
ecname_from_fnFunction · 0.85
plineFunction · 0.70

Tested by

no test coverage detected