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

Add handedness enum for is_polygon_clockwise #89635

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Commits on Mar 20, 2024

  1. Add handedness enum for is_polygon_clockwise

    When this was originally implemented in
    16022da, the implementation treated the
    vertices as being in a space where the y-axis is positive in the up
    direction. This causes it to return the incorrect value for 2D games,
    since Godot treats the y-axis as being positive in the down direction.
    
    This change maintains compatibility with existing uses of
    `is_polygon_clockwise` by adding an optional parameter which allows the
    user to select which handedness their coordinate system uses. The
    documentation for `is_polygon_clockwise` has also been updated to
    describe the difference.
    
    Fixes godotengine#49716.
    exodrifter committed Mar 20, 2024
    Configuration menu
    Copy the full SHA
    8e679d7 View commit details
    Browse the repository at this point in the history