Simplify creature stride length
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
|
||||
module Dodge.Creature.State.WalkCycle (updateWalkCycle) where
|
||||
|
||||
import Dodge.Creature.HandPos
|
||||
import Linear
|
||||
import Control.Lens
|
||||
import Dodge.Data.World
|
||||
@@ -12,7 +13,7 @@ updateWalkCycle :: Int -> World -> World
|
||||
updateWalkCycle cid w
|
||||
| Just cr <- w ^? cWorld . lWorld . creatures . ix cid
|
||||
, Walking x ff <- cr ^. crStance . carriage
|
||||
, x >= cr ^. crStance . strideLength =
|
||||
, x >= strideLength cr =
|
||||
w
|
||||
& soundMultiFrom
|
||||
[FootstepSound i | i <- [0 .. 10]]
|
||||
|
||||
Reference in New Issue
Block a user