MCPcopy Create free account
hub / github.com/NetHack/NetHack / fix_curse_trouble

Function fix_curse_trouble

src/pray.c:348–370  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

346}
347
348staticfn void
349fix_curse_trouble(struct obj *otmp, const char *what)
350{
351 if (!otmp) {
352 impossible("fix_curse_trouble: nothing to uncurse.");
353 return;
354 }
355 if (otmp == uarmg && Glib) {
356 make_glib(0);
357 Your("%s are no longer slippery.", gloves_simple_name(uarmg));
358 if (!otmp->cursed)
359 return;
360 }
361 if (!Blind || (otmp == ublindf && Blindfolded_only)) {
362 pline("%s %s.",
363 what ? what : (const char *) Yobjnam2(otmp, "softly glow"),
364 hcolor(NH_AMBER));
365 iflags.last_msg = PLNMSG_OBJ_GLOWS;
366 otmp->bknown = !Hallucination; /* ok to skip set_bknown() */
367 }
368 uncurse(otmp);
369 update_inventory();
370}
371
372staticfn void
373fix_worst_trouble(int trouble)

Callers 1

fix_worst_troubleFunction · 0.85

Calls 9

make_glibFunction · 0.85
YourFunction · 0.85
gloves_simple_nameFunction · 0.85
Yobjnam2Function · 0.85
hcolorFunction · 0.85
uncurseFunction · 0.85
update_inventoryFunction · 0.85
impossibleFunction · 0.70
plineFunction · 0.70

Tested by

no test coverage detected