Closed simonghales closed 3 years ago
Unfortunately I couldn't get the examples folder to work locally, so I haven't managed to verify this myself just yet. I should be able to do so tonight, but figured I'd make the PR request now in case somebody wanted to review it before then.
Hey Simon, thanks for this PR.
If you get your branch up to date with master
and jump straight to the chain demo, you'll see this unfortunately breaks things with bodies[uuid] is undefined. I'd tried what you'd written in the discord and simply thought I was implementing it wrong when I saw the same result.
I will take a look!
@stockHuman the chain demo is working for me now
Awesome, thanks for the fix.
This should resolve this issue: https://github.com/pmndrs/use-cannon/discussions/96
fixes a small bug where whenever the bodies need to be synchronized, the next 'frame' update might arrive before the 'sync' update is received and processed.
This is fixed by bundling the data originally sent via the 'sync' update, as part of the 'frame' update.