diff options
| author | Silver1063 <brickbrickerson1063@gmail.com> | 2020-10-11 15:47:01 -0700 |
|---|---|---|
| committer | Silver1063 <brickbrickerson1063@gmail.com> | 2020-10-11 15:47:01 -0700 |
| commit | a733457285f26dae629e9625fcb13475a28577b7 (patch) | |
| tree | 21b62aec4ac7c35dabcb6ac5468a4c286d2cd07d /include/core | |
| parent | c9a740be34438ce999402b7b76304a38daaaa811 (diff) | |
| download | redot-cpp-a733457285f26dae629e9625fcb13475a28577b7.tar.gz | |
Update Vector3 slide to match godot implementation
It wasn't the same before and resulted in weird behavior, its better now.
Diffstat (limited to 'include/core')
| -rw-r--r-- | include/core/Vector3.hpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/core/Vector3.hpp b/include/core/Vector3.hpp index d879097..16c2a10 100644 --- a/include/core/Vector3.hpp +++ b/include/core/Vector3.hpp @@ -264,7 +264,7 @@ struct Vector3 { void rotate(const Vector3 &p_axis, real_t p_phi); inline Vector3 slide(const Vector3 &by) const { - return by - *this * this->dot(by); + return *this - by * this->dot(by); } void snap(real_t p_val); |
