Start to create debug datatypes
This commit is contained in:
@@ -5,6 +5,7 @@ module Dodge.Base.Window (
|
||||
screenPolygon,
|
||||
screenPolygonBord,
|
||||
screenBox,
|
||||
pointIsOnScreen,
|
||||
) where
|
||||
|
||||
import Control.Lens
|
||||
@@ -54,3 +55,6 @@ screenBox w = rectNSWE hh (- hh) (- hw) hw
|
||||
where
|
||||
hw = halfWidth w
|
||||
hh = halfHeight w
|
||||
|
||||
pointIsOnScreen :: Configuration -> Camera -> Point2 -> Bool
|
||||
pointIsOnScreen cfig w p = pointInPolygon p $ screenPolygon cfig w
|
||||
|
||||
Reference in New Issue
Block a user