Refactor damages in circles

This commit is contained in:
2025-06-20 21:52:42 +01:00
parent edcd947c90
commit b2d64ce698
6 changed files with 56 additions and 56 deletions
+5 -2
View File
@@ -1,9 +1,9 @@
module Dodge.Zoning.Creature where
import Dodge.Creature.Radius
import Control.Lens
import qualified Data.IntSet as IS
import Data.Maybe
import Dodge.Creature.Radius
import Dodge.Data.World
import Dodge.Zoning.Base
import Dodge.Zoning.Common
@@ -16,7 +16,10 @@ crIXsNearPoint :: Point2 -> World -> IS.IntSet
crIXsNearPoint = nearPoint crZoneSize _crZoning
crsNearPoint :: Point2 -> World -> [Creature]
crsNearPoint p w = mapMaybe (\cid -> w ^? cWorld . lWorld . creatures . ix cid) . IS.toList $ crIXsNearPoint p w
crsNearPoint p w =
mapMaybe (\cid -> w ^? cWorld . lWorld . creatures . ix cid)
. IS.toList
$ crIXsNearPoint p w
crsNearSeg :: Point2 -> Point2 -> World -> [Creature]
crsNearSeg sp ep w =