Skip to content
Discussion options

You must be logged in to vote

It sounds like you're saying one new Jolt instance per game, is that correct?

Yes. Although in your example you create 2 variables in the same global address space. If you use a WebWorker per game then each WebWorker would have it's own physics system and not share the jolt variable with any other workers.

Each tick is synchronous, but WebWorkers run async

If 1 game happens in 1 WebWorker (including all comms) then there's nothing that needs to be communicated with other workers so you can see it as a synchronous process.

If we run the Jolt WASM without multithreading that sim stays synchronous on the same thread right?

Yes.

Disclaimer: I haven't tried running multiple instances of …

Replies: 3 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by gigablox
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #232 on March 03, 2025 20:16.