Move towards adding in pulse laser "rifle" (like UT shock rifle)

This commit is contained in:
2025-07-25 09:12:04 +01:00
parent ff3699e6cb
commit 190068737d
17 changed files with 750 additions and 628 deletions
+19
View File
@@ -0,0 +1,19 @@
module Dodge.IsPulseLaser (
isPulseLaser,
isPulseCapacitor,
) where
import Control.Lens
import Dodge.Data.ComposedItem
import Dodge.Data.DoubleTree
import Dodge.Data.Item
isPulseLaser :: LocationDT OItem -> Bool
isPulseLaser loc =
loc ^. locDT . dtValue . _1 . itType == HELD LASER
&& (loc ^? locDT . dtLeft . ix 0 . dtValue . _1 . itType == Just (CRAFT CAPACITOR))
isPulseCapacitor :: LocationDT OItem -> Bool
isPulseCapacitor loc =
loc ^. locDT . dtValue . _1 . itType == HELD LASER
&& (loc ^? locDT . dtLeft . ix 0 . dtValue . _1 . itType == Just (CRAFT CAPACITOR))