Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Collisions still need to exist while a mesh rebuilds. #33

Open
ChillBoxServers opened this issue Oct 18, 2024 · 0 comments
Open

Collisions still need to exist while a mesh rebuilds. #33

ChillBoxServers opened this issue Oct 18, 2024 · 0 comments

Comments

@ChillBoxServers
Copy link

ChillBoxServers commented Oct 18, 2024

I know its a mesh rebuild so of course there are no collisions.

Problem is when force is applied to an object when a mesh rebuilds the object has no ground, this goes unnoticed with basic player controllers but props & anything else with free gravity will bounce a bit, this even happens in the sdf worlds demo when you spawn a prop in and make an edit next to it .

My current solution:
before a mesh edit fire traces to detect where each physics body is currently touching the ground, spawn a plane collider at contact point that matches obb's and angs to simulate touching ground then remove it after rebuild.

This seems like a bit of a jank fix but it works as long as I can find a reliable way to pool & remove the planes .

I have yet to actually really study this repos code fully to know exactly what it does but caching the current collision mesh before an edit and keeping it until a rebuild is finished might solve this, not sure how hard that would be.

1.mp4
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant