Skip to content

Commit

Permalink
Merge pull request #10 from ineka-dev/fix/raf-perf
Browse files Browse the repository at this point in the history
fix: fixed scope issues with fixedStep calls
  • Loading branch information
ColinEspinas authored Oct 2, 2022
2 parents c29c222 + 04c1bd3 commit 19a150d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/core/Engine.ts
Original file line number Diff line number Diff line change
Expand Up @@ -93,9 +93,9 @@ export class Engine {
// Fix timestep of fixedStep methods
this.time.fixTimestep(() => {
this.systems.forEach((system) => {
Promise.resolve().then(system.fixedStep);
Promise.resolve().then(() => system.fixedStep);
});
Promise.resolve().then(this.rootNode.fixedStep);
Promise.resolve().then(() => this.rootNode.fixedStep);
});
// Do non fixed steps
this.systems.forEach((system) => {
Expand Down

0 comments on commit 19a150d

Please sign in to comment.