This commit is contained in:
2025-08-26 18:51:14 +01:00
parent b87c3380b8
commit 1ebdbdd8ae
34 changed files with 210 additions and 246 deletions
+3 -3
View File
@@ -18,7 +18,7 @@ import Shape
import ShapePicture
import Linear.V3
worldSPic :: Configuration -> Universe -> SPic
worldSPic :: Config -> Universe -> SPic
worldSPic cfig u =
(mempty :!: extraPics cfig u)
<> foldup propSPic (filtOn _prPos _props)
@@ -87,12 +87,12 @@ shiftDraw' fpos fdir fdraw x =
. rotateSP (fdir x)
$ fdraw x
cullPoint :: Configuration -> World -> Point2 -> Bool
cullPoint :: Config -> World -> Point2 -> Bool
cullPoint cfig w p
| debugOn Close_shape_culling cfig = pointInPolygon p (w ^. wCam . camBoundBox)
| otherwise = dist (w ^. wCam . camCenter) p < (w ^. wCam . camViewDistance)
extraPics :: Configuration -> Universe -> Picture
extraPics :: Config -> Universe -> Picture
extraPics cfig u =
setLayer FixedCoordLayer (fixedCoordPictures u)
<> foldMap drawTractorBeam (_tractorBeams lw)