fix: not immutable
This commit is contained in:
parent
906997eeee
commit
42c9221c49
|
@ -30,7 +30,7 @@ export class World extends AbstractWorld {
|
||||||
const aabb = body.aabb;
|
const aabb = body.aabb;
|
||||||
const points = Rectangle.toPoints(aabb);
|
const points = Rectangle.toPoints(aabb);
|
||||||
const nodes = points.map((point) => [...point, body]);
|
const nodes = points.map((point) => [...point, body]);
|
||||||
this.quadTreeNodes = this.quadTreeNodes.set(body, nodes);
|
this.quadTreeNodes.set(body, nodes);
|
||||||
for (const node of nodes) {
|
for (const node of nodes) {
|
||||||
this.quadTree.add(node);
|
this.quadTree.add(node);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user