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

Rotate Collision shape is wrong #2027

Closed
Mavhod opened this issue Jun 3, 2015 · 4 comments
Closed

Rotate Collision shape is wrong #2027

Mavhod opened this issue Jun 3, 2015 · 4 comments

Comments

@Mavhod
Copy link
Contributor

Mavhod commented Jun 3, 2015

I create CollsionObject from code and add CollisionShape to it, I rotate collision shape but it worng.

I made project for demonstrate about it there:
https://www.dropbox.com/s/d0pr1kd5ko1dfm2/testColShapeCode.zip?dl=0

@akien-mga
Copy link
Member

The issue shown in the test project above is still valid in the current master branch.

To be more explicit about the issue, it appears that setting a rotation of (0, 80, 0) in the editor-defined CollisionShape works as expected (rotates counter-clockwise by +80° around the Y+ axis), but the equivalent code does not work as expected:

    #trans.basis = trans.basis.rotated(Vector3(0, 1, 0), deg2rad(80)) # It should be this
    trans.basis = trans.basis.rotated(Vector3(0, 1, 0), deg2rad(-80)) # But must negative angle...

@reduz
Copy link
Member

reduz commented Jan 4, 2016

rotation via properties in 3D is broken, will be rewritten in 3.0

@reduz reduz added this to the 3.0 milestone Jan 4, 2016
@akien-mga
Copy link
Member

Potentially a duplicate of #1479.

@reduz
Copy link
Member

reduz commented Aug 4, 2017

we solved this already in 3.0, so closing this issue

@reduz reduz closed this as completed Aug 4, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants