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

[BUG] Fix collision detection algorithm #57

Open
1 task done
rayzchen opened this issue May 22, 2022 · 3 comments
Open
1 task done

[BUG] Fix collision detection algorithm #57

rayzchen opened this issue May 22, 2022 · 3 comments
Assignees
Labels
OS: Any Occurs on any platform Topic: Module Bugs or enhancements to do with PyUnity code Type: Bug Something isn't working
Milestone

Comments

@rayzchen
Copy link
Collaborator

Is there an existing issue for this?

  • I have searched the existing issues

System info

Loaded config
Detected settings.json entry
Using window provider GLFW
Loaded PyUnity version 0.9.0
##############################
         VERSION INFO
##############################
PyUnity version: v0.9.0
Python version: v3.10.4-final
Operating system: Windows 10
Machine: AMD64
Python architecture: 64bit
Dependencies:
- pyopengl version: 3.1.6
- pillow version: 9.1.1
- pysdl2 version: 0.9.11
- pysdl2-dll version: 2.0.20
- pyglm version: 2.5.7
- importlib-resources version: None
- glfw version: 2.5.3

Describe the bug

Physics is broken, when two cubes collide head-on they collide into each other
Collision point is offset by 1 unit in the Z axis in example 2
Example 3, red cube has infinite inertia yet it still rotates

To reproduce

Run examples 2 and 3, observe
For example 2 pressing Space and R starts and resets the cubes respectively

Code

No response

Traceback

No response

Additional context

Using GJK and EPA algorithm, pretty expensive and still doesnt work

@rayzchen rayzchen added the Type: Bug Something isn't working label May 22, 2022
@rayzchen rayzchen self-assigned this May 22, 2022
@rayzchen rayzchen added this to the 0.9.0 milestone May 22, 2022
@rayzchen rayzchen added the Topic: Module Bugs or enhancements to do with PyUnity code label Jun 4, 2022
@rayzchen
Copy link
Collaborator Author

Fixed infinite inertia problem

@rayzchen
Copy link
Collaborator Author

Looking into HPP-FCL, but it requires NumPy and isn't crossplatform

@rayzchen
Copy link
Collaborator Author

hppfcl seems to be working perfectly fine, not too laggy either

@rayzchen rayzchen added the OS: Any Occurs on any platform label May 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
OS: Any Occurs on any platform Topic: Module Bugs or enhancements to do with PyUnity code Type: Bug Something isn't working
Projects
Status: In progress
Development

No branches or pull requests

1 participant