Open gabrielbrunop opened 3 years ago
I think I found the problem.
The coordinates of the heightfield were in the same spot as another polyline. And that polyline was created as a dynamic body. I thought it doesn't matter but it seems that if a dynamic polyline or heightfield intersects with a static body, it crashes.
Although making it static will work just fine for me, I guess that's not intended behaviour?
I have the same problem, even though the heightfield is fixed and it does not intersect with anything. No matter what params I feed into the heightfield, it crashes. The only difference from the official example is that it runs in a worker, but I don't see any reason why it shouldn't work in a worker.
I'm trying to create a 2D heightfield but it throws a unreachable error at runtime for no apparent reason.
Also, on the testbed
heightfield.js
example it passes an array to theheights
parameters, but on Typescript it requires aFloat32Array
. Anyway, the testbed example also doesn't work:I'm using the latest version of Rapier2D (0.7.6).