diff options
-rw-r--r-- | Spear/Math/Spatial.hs | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/Spear/Math/Spatial.hs b/Spear/Math/Spatial.hs index bfab6c2..b6a3ede 100644 --- a/Spear/Math/Spatial.hs +++ b/Spear/Math/Spatial.hs | |||
@@ -88,22 +88,22 @@ class (Positional a v, Rotational a v r) => Spatial a v r t | a -> t where | |||
88 | move :: Positional a v => Float -> (a -> v) -> a -> a | 88 | move :: Positional a v => Float -> (a -> v) -> a -> a |
89 | move delta axis a = translate (axis a * delta) a | 89 | move delta axis a = translate (axis a * delta) a |
90 | 90 | ||
91 | -- | Move the spatial upwards. | 91 | -- | Move the spatial along its right axis. |
92 | moveRight delta = move delta right | 92 | moveRight delta = move delta right |
93 | 93 | ||
94 | -- | Move the spatial downwards. | 94 | -- | Move the spatial along its left axis. |
95 | moveLeft delta = moveRight (-delta) | 95 | moveLeft delta = moveRight (-delta) |
96 | 96 | ||
97 | -- | Move the spatial upwards. | 97 | -- | Move the spatial along its up axis. |
98 | moveUp delta = move delta up | 98 | moveUp delta = move delta up |
99 | 99 | ||
100 | -- | Move the spatial downwards. | 100 | -- | Move the spatial along its down axis. |
101 | moveDown delta = moveUp (-delta) | 101 | moveDown delta = moveUp (-delta) |
102 | 102 | ||
103 | -- | Move the spatial forwards. | 103 | -- | Move the spatial along its forward axis. |
104 | moveFwd delta = move delta forward | 104 | moveFwd delta = move delta forward |
105 | 105 | ||
106 | -- | Move the spatial backwards. | 106 | -- | Move the spatial along its backward axis. |
107 | moveBack delta = moveFwd (-delta) | 107 | moveBack delta = moveFwd (-delta) |
108 | 108 | ||
109 | -- | Make the spatial look at the given point. | 109 | -- | Make the spatial look at the given point. |