Revert mouse input changes to occur during your creature evaluation

This commit is contained in:
jgk
2021-03-26 17:35:29 +01:00
parent e1716615c0
commit 7ef4e5d415
2 changed files with 4 additions and 2 deletions
+3 -1
View File
@@ -10,6 +10,8 @@ import Dodge.RandomHelp
import Dodge.WorldEvent
import Dodge.CreatureState
import Dodge.Update.UsingInput
import Geometry
import Picture
@@ -1871,7 +1873,7 @@ splitCritCorpse x = color (greyN 0.2) $ circleSolid x
spCrRadFac = 8^2
yourControl :: World -> (World -> World,StdGen) -> Creature -> ((World -> World,StdGen), Maybe Creature)
yourControl w (f,g) cr = ( (f, g)
yourControl w (f,g) cr = ( (updateUsingInput . f, g)
, Just . crAutoReload . mouseActionsCr (_mouseButtons w) $ wasdWithAiming w speed strafeSpeed 0 cr
)
where strafeSpeed = 8 * equipFactor * (fromMaybe 1 $ yourItem w ^? itAimingSpeed)
+1 -1
View File
@@ -35,7 +35,7 @@ update w
. updateBlocks -- . zoning
. updateSeenWalls
. updateSoundQueue
. updateUsingInput
-- . updateUsingInput
$ updateCloseObjects w
in checkEndGame . ppEvents
. updateCamera