Coder Social home page Coder Social logo

Comments (3)

Jondolf avatar Jondolf commented on June 2, 2024 1

Unfortunately, this isn't really something I can fix. The sign is negative there because of Bevy's right-handed Y-up coordinate system. In Bevy, +Z is "pointing towards the screen", while "forward" is -Z, which you can see from Transform::forward:

pub fn forward(&self) -> Direction3d {
    -self.local_z()
}

There's a lot of reasons why Bevy uses this coordinate system, and it's also consistent with e.g. Godot and a lot of other tools. Cart (the lead dev of Bevy) has some reasons listed here: bevyengine/bevy#10488

Here's also Freya's chart on coordinate systems: (copied from the discussion)

281936146-3f2d1284-95f8-4f90-a8c9-64c83be5bcb8

(Unreal sitting alone in the corner lol)

from bevy_xpbd.

Cassumbra avatar Cassumbra commented on June 2, 2024

yeah, i cant really think of any sort of thing that would fix it, maybe the best thing to do would be to simply add a comment next to the code to point out the inverted sign?

from bevy_xpbd.

MiniaczQ avatar MiniaczQ commented on June 2, 2024

Inverse left and right buttons...
The inversion has to happen, but it should happen in player local coordinate system, not world coordinate system

from bevy_xpbd.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.