Add objects based on walls, called machines
This commit is contained in:
@@ -138,9 +138,8 @@ lineOnScreen w p1 p2 = pointInPolygon p1 sp
|
||||
sp = screenPolygon w
|
||||
sps = zip sp (tail sp ++ [head sp])
|
||||
|
||||
|
||||
drawWallFloor :: Wall -> Picture
|
||||
drawWallFloor wl = if _wlIsSeeThrough wl
|
||||
drawWallFloor wl = if _wlOpacity wl == SeeThrough
|
||||
then setDepth 0.9 . color c $ polygon [x,x +.+ n2,y+.+n2, y]
|
||||
else blank
|
||||
where
|
||||
@@ -159,7 +158,8 @@ wallsAndWindows w
|
||||
= (map f wls, map f wins)
|
||||
where
|
||||
f wl = (_wlLine wl, _wlColor wl)
|
||||
(wins,wls) = partition _wlIsSeeThrough . IM.elems . IM.filter _wlDraw $ wallsDoubleScreen w
|
||||
(wins,wls) = partition theTest . IM.elems . IM.filter _wlDraw $ wallsDoubleScreen w
|
||||
theTest wl = _wlOpacity wl /= Opaque
|
||||
|
||||
lightsForGloom :: World -> [(Point3,Float,Point3)]
|
||||
lightsForGloom w = mapMaybe getLS (IM.elems $ _lightSources w) ++ mapMaybe getTLS (_tempLightSources w)
|
||||
|
||||
Reference in New Issue
Block a user