diff --git a/src/math/Vector2.php b/src/math/Vector2.php index e5c27f47..406cd95b 100644 --- a/src/math/Vector2.php +++ b/src/math/Vector2.php @@ -47,9 +47,7 @@ class Vector2{ if(($x instanceof Vector2) === true){ return $this->add($x->x, $x->y); }else{ - $this->x += $x; - $this->y += $y; - return new Vector3($this->x + $x, $this->y + $y); + return new Vector2($this->x + $x, $this->y + $y); } }