Commit before attempting to fix placement shifting bug

This commit is contained in:
2022-03-04 13:13:21 +00:00
parent 2961923534
commit d219f42640
4 changed files with 55 additions and 6 deletions
+1 -1
View File
@@ -9,7 +9,7 @@ import Control.Lens
shiftPSBy :: (Point2,Float) -> PlacementSpot -> PlacementSpot
shiftPSBy (pos,rot) ps = ps
& psPos %~ shiftPointBy (pos,rot)
& psRot %~ (+ rot)
& psRot +~ rot
shiftPlacement :: (Point2,Float) -> Placement -> Placement
shiftPlacement shift plmnt = case plmnt of
Placement {} -> plmnt & plSpot %~ shiftPSBy shift