From 9b8d3185fe6cee9231ed20a1dbf0240d0c459a39 Mon Sep 17 00:00:00 2001 From: Griffin Smith Date: Fri, 3 Jul 2020 20:32:36 -0400 Subject: refactor(xan): Switch to V2 over tuples most places These are generally rather nicer to work due to some typeclass instances, and integrate better with other ecosystems for things like linear algebra etc. Change-Id: I546c8da7b17234648f3d612b28741c1fded25447 Reviewed-on: https://cl.tvl.fyi/c/depot/+/910 Tested-by: BuildkiteCI Reviewed-by: glittershark --- users/glittershark/xanthous/src/Xanthous/Data/EntityMap/Graphics.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'users/glittershark/xanthous/src/Xanthous/Data/EntityMap') diff --git a/users/glittershark/xanthous/src/Xanthous/Data/EntityMap/Graphics.hs b/users/glittershark/xanthous/src/Xanthous/Data/EntityMap/Graphics.hs index 5a73bd393848..19e7b0cdf086 100644 --- a/users/glittershark/xanthous/src/Xanthous/Data/EntityMap/Graphics.hs +++ b/users/glittershark/xanthous/src/Xanthous/Data/EntityMap/Graphics.hs @@ -44,7 +44,7 @@ linesOfSight (view _Position -> pos) visionRadius em lines = line pos <$> radius entitiesOnLines :: [[(Position, Vector (EntityID, e))]] entitiesOnLines = lines <&> map getPositionedAt - getPositionedAt :: (Int, Int) -> (Position, Vector (EntityID, e)) + getPositionedAt :: V2 Int -> (Position, Vector (EntityID, e)) getPositionedAt p = let ppos = _Position # p in (ppos, over _2 (view positioned) <$> atPositionWithIDs ppos em) -- cgit 1.4.1