Fix tile rendering

This commit is contained in:
2021-09-07 10:53:39 +01:00
parent 6ecd739d6f
commit 45bbf9b005
14 changed files with 66 additions and 100 deletions
+2 -2
View File
@@ -9,7 +9,7 @@ import Control.Lens
addTile :: Float -> Room -> Room
addTile z r
| not (null (_rmFloor r)) || null rp = r
| otherwise = r & rmFloor .~ [oTile poly z]
| otherwise = r & rmFloor .~ [makeTileFromPoly poly z]
where
rp = _rmPolys r
poly = convexHull $ concat rp
poly = orderPolygon . convexHull $ concat rp