dimforge / dimforge/bevy_rapier

Rotated cylinder RevoluteJoint gives entire joint strange rotation

Open
#569 3 comments 0 reactions 0 assignees View on GitHub
Dominant language
Rust
Stars
1.6k
Forks
282
PR merge metrics
No merged PRs in 30d

Description

I am attempting to work around #457 and encountered what I think may be a separate bug. I suspect it might be a separate bug because there are no non-default transforms involved in this repro.

Here's a super simple little playground with a vehicle approximating a "onewheel", consisting of:

- A cuboid
- A rotated cylinder
- A joint

https://github.com/rparrett/rapier_wheel_nonsense/blob/e22e10a22183209c1821979b62fc03bfe699e0d9/src/main.rs

https://github.com/user-attachments/assets/ed056282-ded2-440c-bef0-015ca305d788

The only rotation in the code is this line:
```rust
joint.set_local_basis2(Quat::from_rotation_z(std::f32::consts::FRAC_PI_2));
```
So the 15 degree rotation seems quite odd.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.