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

Function lantern_message

src/timeout.c:1359–1376  ·  view source on GitHub ↗

Print a dimming message for brass lanterns. Only called if seen. */

Source from the content-addressed store, hash-verified

1357
1358/* Print a dimming message for brass lanterns. Only called if seen. */
1359staticfn void
1360lantern_message(struct obj *obj)
1361{
1362 /* from adventure */
1363 switch (obj->where) {
1364 case OBJ_INVENT:
1365 Your("lantern is getting dim.");
1366 if (Hallucination)
1367 pline("Batteries have not been invented yet.");
1368 break;
1369 case OBJ_FLOOR:
1370 You_see("a lantern getting dim.");
1371 break;
1372 case OBJ_MINVENT:
1373 pline("%s lantern is getting dim.", s_suffix(Monnam(obj->ocarry)));
1374 break;
1375 }
1376}
1377
1378/*
1379 * Timeout callback for objects that are burning. E.g. lamps, candles.

Callers 1

burn_objectFunction · 0.85

Calls 5

YourFunction · 0.85
You_seeFunction · 0.85
s_suffixFunction · 0.85
MonnamFunction · 0.85
plineFunction · 0.70

Tested by

no test coverage detected