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

Function is_worn

src/invent.c:2155–2161  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2153}
2154
2155boolean
2156is_worn(struct obj *otmp)
2157{
2158 return (otmp->owornmask & (W_ARMOR | W_ACCESSORY | W_SADDLE | W_WEAPONS))
2159 ? TRUE
2160 : FALSE;
2161}
2162
2163/* is 'obj' being used by the hero? worn, wielded, active lamp or leash;
2164 not to be confused with obj->in_use, which finishes using up an item

Callers 4

accessory_or_armor_onFunction · 0.85
is_inuseFunction · 0.85
askchainFunction · 0.85
is_worn_by_typeFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected