Partially working mounts on lerp doors
This commit is contained in:
@@ -3,6 +3,7 @@
|
||||
module Dodge.ShiftPoint where
|
||||
|
||||
import Geometry
|
||||
import Linear
|
||||
|
||||
shiftPointBy :: Point2A -> Point2 -> Point2
|
||||
shiftPointBy (pos, rot) !p = pos +.+ rotateV rot p
|
||||
@@ -10,6 +11,9 @@ shiftPointBy (pos, rot) !p = pos +.+ rotateV rot p
|
||||
compP2A :: Point2A -> Point2A -> Point2A
|
||||
compP2A (p1,r1) (p2,r2) = (p1 +.+ rotateV r1 p2, r1 + r2)
|
||||
|
||||
lerpP2A :: Point2A -> Point2A -> Float -> Point2A
|
||||
lerpP2A (p1,a1) (p2,a2) x = (p1 + x *^ (p2 - p1), a1 + x * diffAngles a2 a1)
|
||||
|
||||
invShiftPointBy :: (Point2, Float) -> Point2 -> Point2
|
||||
invShiftPointBy (p1, r) p2 = rotateV (- r) $ p2 -.- p1
|
||||
|
||||
|
||||
Reference in New Issue
Block a user