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

Function find_pmmonst

src/monmove.c:374–388  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

372}
373
374struct monst *
375find_pmmonst(int pm)
376{
377 struct monst *mtmp = 0;
378
379 if ((svm.mvitals[pm].mvflags & G_GENOD) == 0)
380 for (mtmp = fmon; mtmp; mtmp = mtmp->nmon) {
381 if (DEADMONSTER(mtmp))
382 continue;
383 if (mtmp->data == &mons[pm])
384 break;
385 }
386
387 return mtmp;
388}
389
390/* killer bee 'mon' is on a spot containing lump of royal jelly 'obj' and
391 will eat it if there is no queen bee on the level; return 1: mon died,

Callers 2

dogfoodFunction · 0.85
bee_eat_jellyFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected