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

Function stagger

src/mondata.c:1394–1407  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1392}
1393
1394const char *
1395stagger(const struct permonst *ptr, const char *def)
1396{
1397 int locoindx = (*def != highc(*def)) ? 2 : 3;
1398
1399 return (is_floater(ptr) ? levitate[locoindx]
1400 : (is_flyer(ptr) && ptr->msize <= MZ_SMALL) ? flys[locoindx]
1401 : (is_flyer(ptr) && ptr->msize > MZ_SMALL) ? flyl[locoindx]
1402 : slithy(ptr) ? slither[locoindx]
1403 : amorphous(ptr) ? ooze[locoindx]
1404 : !ptr->mmove ? immobile[locoindx]
1405 : nolimbs(ptr) ? crawl[locoindx]
1406 : def);
1407}
1408
1409/* return phrase describing the effect of fire attack on a type of monster */
1410const char *

Callers 7

make_stunnedFunction · 0.85
hmon_hitmon_staggerFunction · 0.85
mhitm_ad_stunFunction · 0.85
passivemmFunction · 0.85
encumber_msgFunction · 0.85
chest_trapFunction · 0.85
passiveumFunction · 0.85

Calls 1

highcFunction · 0.85

Tested by

no test coverage detected