Godot version:
3.1
OS/device including version:
Windows - 1080TI
Issue description:
The move_and_slide function will crash the game if a "zero" vector is passed into it. It should throw a warning when such a value is passed rather than kill the process.
I managed to fix the issue by using if vec.length() < 0.00001: move_and_slide(...). After doing some research, the bullet library will crash the client upon normalising a vector that has a "zero" value (the length being less than the epsilon they provide). I can safeguard our software by checking the vector length but feel this should be done elsewhere.
Steps to reproduce:
move_and_slide(Vector3(), Vector3(0,1,0))
What "3.1" build?
f32c826
@AndreaCatania That might be another issue due to me enabling BT_DEBUG, it probably assets where it used to go fine before.
Would be good to fix, but given this and #25431 I think I'll disable BT_DEBUG again for now, and reenable it after 3.1 is released so that we can work on those issues.
@akien-mga Yeah, the bullet library only throws this exception in debug mode so it sound like this is the most likely cause.
Thanks for moving so quickly on the issue.
Ran into this aswell last night but had no time to look into it.
On Thu, 31 Jan 2019 at 3:55 am, JustJoey notifications@github.com wrote:
@akien-mga https://github.com/akien-mga Yeah, the bullet library only
throws this exception in debug mode so it sound like this is the most
likely cause.Thanks for moving so quickly on the issue.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/godotengine/godot/issues/25476#issuecomment-459021196,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AB2vaR445-gIbTq_9rRGahZ7_hYwKY9iks5vIc6UgaJpZM4aY0Ep
.>
Kindest regards,
Bastiaan Olij
https://www.facebook.com/bastiaan.olij
https://twitter.com/mux213
https://www.youtube.com/BastiaanOlij
https://www.youtube.com/channel/UCrbLJYzJjDf2p-vJC011lYw
https://github.com/BastiaanOlij
@akien-mga I agree with that
It should no longer crash after #25500. I'll keep this open as it's still a bug that needs to be fixed (for 3.2).
Most helpful comment
@AndreaCatania That might be another issue due to me enabling
BT_DEBUG, it probably assets where it used to go fine before.Would be good to fix, but given this and #25431 I think I'll disable
BT_DEBUGagain for now, and reenable it after 3.1 is released so that we can work on those issues.