MCPcopy Create free account
hub / github.com/melonjs/melonJS / countAll

Function countAll

packages/melonjs/tests/quadtree.spec.js:953–959  ·  view source on GitHub ↗
(node)

Source from the content-addressed store, hash-verified

951 * remove pass, this must return 0.
952 */
953 const countAll = (node) => {
954 let n = node.objects.length;
955 for (const sub of node.nodes) {
956 n += countAll(sub);
957 }
958 return n;
959 };
960
961 /**
962 * Walk the tree and return the maximum depth that contains

Callers 1

quadtree.spec.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected