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

Unexpected result of .normalize() on already Zero vector #3171

Closed
eonarheim opened this issue Aug 7, 2024 · 0 comments · Fixed by #3179
Closed

Unexpected result of .normalize() on already Zero vector #3171

eonarheim opened this issue Aug 7, 2024 · 0 comments · Fixed by #3179
Labels
bug This issue describes undesirable, incorrect, or unexpected behavior

Comments

@eonarheim
Copy link
Member

eonarheim commented Aug 7, 2024

Steps to Reproduce

Attempt to normalize a vector of length zero

image

Other prior art is that Godot/Unity/Unreal all return a zero vector

Expected Result

Return a vector copy that is also zero

Actual Result

Arbitrary direction is returned

Environment

Latest

Current Workaround

Check for zero vectors before normalizing

@eonarheim eonarheim added the bug This issue describes undesirable, incorrect, or unexpected behavior label Aug 7, 2024
Autsider666 added a commit to Autsider666/Excalibur that referenced this issue Aug 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug This issue describes undesirable, incorrect, or unexpected behavior
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant