Broken but funny bouncing.
This commit is contained in:
@@ -8,4 +8,9 @@ impl Direction {
|
||||
pub fn new(x: isize, y: isize) -> Self {
|
||||
Self { x, y }
|
||||
}
|
||||
|
||||
pub fn invert(&mut self) {
|
||||
self.x *= -1;
|
||||
self.y *= -1;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user