diff options
| author | Elizabeth Hunt <elizabeth.hunt@simponic.xyz> | 2023-08-13 16:47:58 -0600 |
|---|---|---|
| committer | Elizabeth Hunt <elizabeth.hunt@simponic.xyz> | 2023-08-13 16:47:58 -0600 |
| commit | 98e795029bcc404463ed151ff5255a72498bc641 (patch) | |
| tree | 48e50d896d00761eae18c89f89e5dd0ef353b660 /engine/systems/Collision.ts | |
| parent | c6e9baa0009f7cce0f6ff156a3957ef04a8cb684 (diff) | |
| download | jumpstorm-98e795029bcc404463ed151ff5255a72498bc641.tar.gz jumpstorm-98e795029bcc404463ed151ff5255a72498bc641.zip | |
Create network component and system
Diffstat (limited to 'engine/systems/Collision.ts')
| -rw-r--r-- | engine/systems/Collision.ts | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/engine/systems/Collision.ts b/engine/systems/Collision.ts index 2bba03b..1366ef4 100644 --- a/engine/systems/Collision.ts +++ b/engine/systems/Collision.ts @@ -63,7 +63,11 @@ export class Collision extends System { dimension = boundingBox.getOutscribedBoxDims(); } - this.quadTree.insert(entity.id, dimension, boundingBox.center); + this.quadTree.insert({ + id: entity.id, + dimension, + center: boundingBox.center, + }); }); // find colliding entities and perform collisions |
