You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-04 12:00:25 +00:00
Several fixes to make GLES2 on HTML5 work much better.
Changed math class error reporting to be a bit less paranoid.
This commit is contained in:
@@ -65,7 +65,7 @@ Vector2 Vector2::normalized() const {
|
||||
|
||||
bool Vector2::is_normalized() const {
|
||||
// use length_squared() instead of length() to avoid sqrt(), makes it more stringent.
|
||||
return Math::is_equal_approx(length_squared(), 1.0);
|
||||
return Math::is_equal_approx(length_squared(), 1.0, UNIT_EPSILON);
|
||||
}
|
||||
|
||||
real_t Vector2::distance_to(const Vector2 &p_vector2) const {
|
||||
|
||||
Reference in New Issue
Block a user