Skip to content

Commit 40d668b

Browse files
committed
♻️ @sim/n-body-mt: Update for new API
1 parent 5429677 commit 40d668b

File tree

1 file changed

+10
-8
lines changed

1 file changed

+10
-8
lines changed

benches/sims/n-body-mt/world.ts

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { createWorld, World as IWorld } from '@bitecs/classic';
1+
import { createWorld, World as IWorld, enableBufferedQueries } from '@bitecs/classic';
22

33
export type World = IWorld & {
44
workers: Record<string, Worker[]>;
@@ -8,10 +8,12 @@ export type World = IWorld & {
88
};
99
};
1010

11-
export const world = createWorld({
12-
workers: {},
13-
time: {
14-
then: performance.now(),
15-
delta: 0,
16-
},
17-
});
11+
export const world = enableBufferedQueries(
12+
createWorld({
13+
workers: {},
14+
time: {
15+
then: performance.now(),
16+
delta: 0,
17+
},
18+
})
19+
);

0 commit comments

Comments
 (0)