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

Function clear_bypass

src/worn.c:1054–1064  ·  view source on GitHub ↗

clear bypass bits for an object chain, plus contents if applicable */

Source from the content-addressed store, hash-verified

1052
1053/* clear bypass bits for an object chain, plus contents if applicable */
1054staticfn void
1055clear_bypass(struct obj *objchn)
1056{
1057 struct obj *o;
1058
1059 for (o = objchn; o; o = o->nobj) {
1060 o->bypass = 0;
1061 if (Has_contents(o))
1062 clear_bypass(o->cobj);
1063 }
1064}
1065
1066/* all objects with their bypass bit set should now be reset to normal;
1067 this can be a relatively expensive operation so is only called if

Callers 1

clear_bypassesFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected