Restrict hotkey firing to initialpress

This commit is contained in:
2024-12-19 22:45:49 +00:00
parent 2b5a81fd11
commit 83e65fb1b0
2 changed files with 2 additions and 2 deletions
+2 -1
View File
@@ -46,7 +46,8 @@ handleHotkeys w
| SDL.ScancodeLShift `M.member` _pressedKeys (_input w)
|| SDL.ScancodeRShift `M.member` _pressedKeys (_input w) =
foldl' tryAssignHotkey w allHotkeys
| otherwise = foldl' useHotkey w (M.intersection thehotkeys (w ^. input . pressedKeys))
| otherwise = foldl' useHotkey w
(M.intersection thehotkeys (M.filter (== InitialPress) (w ^. input . pressedKeys)))
where
thehotkeys = M.mapKeys hotkeyToScancode $ w ^. cWorld . lWorld . hotkeys
-1
View File
@@ -8,7 +8,6 @@ module Dodge.HeldUse (
) where
import NewInt
import Dodge.Luse
import Dodge.Creature.Action.Blink
import Dodge.RadarSweep
import Color