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

Function artifact_light

src/artifact.c:2263–2275  ·  view source on GitHub ↗

WAC return TRUE if artifact is always lit */

Source from the content-addressed store, hash-verified

2261
2262/* WAC return TRUE if artifact is always lit */
2263boolean
2264artifact_light(struct obj *obj)
2265{
2266 /* not artifacts but treat them as if they were because they emit
2267 light without burning */
2268 if (obj && (obj->otyp == GOLD_DRAGON_SCALE_MAIL
2269 || obj->otyp == GOLD_DRAGON_SCALES)
2270 && (obj->owornmask & W_ARM) != 0L)
2271 return TRUE;
2272
2273 return (boolean) ((get_artifact(obj) != &artilist[ART_NONARTIFACT])
2274 && is_art(obj, ART_SUNSWORD));
2275}
2276
2277/* KMH -- Talking artifacts are finally implemented */
2278int

Callers 15

setuwepFunction · 0.85
ready_weaponFunction · 0.85
uwepgoneFunction · 0.85
drop_upon_deathFunction · 0.85
Armor_onFunction · 0.85
Armor_offFunction · 0.85
Armor_goneFunction · 0.85
hmon_hitmon_weapon_meleeFunction · 0.85
hmon_hitmon_do_hitFunction · 0.85
snuff_light_sourceFunction · 0.85
obj_is_burningFunction · 0.85
arti_light_radiusFunction · 0.85

Calls 2

get_artifactFunction · 0.85
is_artFunction · 0.85

Tested by

no test coverage detected