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

Function count_webbing_walls

src/monmove.c:1243–1248  ·  view source on GitHub ↗

returns the number of walls in the four cardinal directions that could hold up a web */

Source from the content-addressed store, hash-verified

1241/* returns the number of walls in the four cardinal directions that could
1242 hold up a web */
1243staticfn int
1244count_webbing_walls(coordxy x, coordxy y)
1245{
1246 return (holds_up_web(x, y - 1) + holds_up_web(x + 1, y)
1247 + holds_up_web(x, y + 1) + holds_up_web(x - 1, y));
1248}
1249
1250/* reject webs which interfere with solving Sokoban */
1251staticfn boolean

Callers 1

maybe_spin_webFunction · 0.85

Calls 1

holds_up_webFunction · 0.85

Tested by

no test coverage detected