Skip to content

KinematicBody2D stop_on_slope is broken only in release builds #24841

Description

@timoschwarzer

Godot version:
3.1 master

OS/device including version:
At least Linux/X11

Issue description:
Okay, this one is a bit strange. The stop_on_slope parameter in move_and_slide does only work in debug builds. I don't know if it's a precision error or whatever. (Maybe -ffast-math?)

Demonstration
https://youtu.be/qk1NBRa5DtI

As you can see, I output the X and Y coordinates of lv_n + p_floor_direction.
(Here: https://github.com/godotengine/godot/blob/master/scene/2d/physics_body_2d.cpp#L1293)
This for some reason gives (0, 0) on debug builds and something else on release_debug builds.

Minimal reproduction project:
Test.zip

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions