Vector2: Fixed ceil() and floor() totally broken logic

"So if I Vector2->ceil()->ceil() my vector2 magically gets incrementing values..." @Sandertv 2018
This commit is contained in:
Dylan K. Taylor 2018-01-01 12:57:34 +00:00
parent a0a2ea01bc
commit 50f273c041

View File

@ -65,11 +65,11 @@ class Vector2{
}
public function ceil(){
return new Vector2((int) ($this->x + 1), (int) ($this->y + 1));
return new Vector2((int) ceil($this->x), (int) ceil($this->y));
}
public function floor(){
return new Vector2((int) $this->x, (int) $this->y);
return new Vector2((int) floor($this->x), (int) floor($this->y));
}
public function round(){