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

Function newepri

src/priest.c:15–25  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

13staticfn boolean has_shrine(struct monst *);
14
15void
16newepri(struct monst *mtmp)
17{
18 if (!mtmp->mextra)
19 mtmp->mextra = newmextra();
20 if (!EPRI(mtmp)) {
21 EPRI(mtmp) = (struct epri *) alloc(sizeof(struct epri));
22 (void) memset((genericptr_t) EPRI(mtmp), 0, sizeof(struct epri));
23 EPRI(mtmp)->parentmid = mtmp->m_id;
24 }
25}
26
27void
28free_epri(struct monst *mtmp)

Callers 3

restmonFunction · 0.70
copy_mextraFunction · 0.70
makemonFunction · 0.70

Calls 2

newmextraFunction · 0.70
allocFunction · 0.70

Tested by

no test coverage detected