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

Function e_at

src/dbridge.c:285–301  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

283}
284
285staticfn struct entity *
286e_at(coordxy x, coordxy y)
287{
288 int entitycnt;
289
290 for (entitycnt = 0; entitycnt < ENTITIES; entitycnt++)
291 if (go.occupants[entitycnt].edata
292 && go.occupants[entitycnt].ex == x
293 && go.occupants[entitycnt].ey == y)
294 break;
295 debugpline1("entitycnt = %d", entitycnt);
296#ifdef D_DEBUG
297 wait_synch();
298#endif
299 return (entitycnt == ENTITIES) ? (struct entity *) 0
300 : &(go.occupants[entitycnt]);
301}
302
303staticfn void
304m_to_e(struct monst *mtmp, coordxy x, coordxy y, struct entity *etmp)

Callers 1

do_entityFunction · 0.85

Calls 1

wait_synchFunction · 0.85

Tested by

no test coverage detected