-
Notifications
You must be signed in to change notification settings - Fork 331
Buoyancy demo nitpick #262
Copy link
Copy link
Closed
Description
In the buoyancy demo, if I put the "water" plane at a different Y position, the objects float at a different depth. Try setting plane.position[1] to -1 or 1, and see where the shapes come to rest.
I believe this is because of a bug on line 89:
var height = 0 - aabb.lowerBound[1];
This is meant to compute the height of the portion of the shape's bounding box that is "underwater". I think that 0 should actually be planePosition[1], so like this:
var height = planePosition[1] - aabb.lowerBound[1];
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels