Add randomness to multiple crab evasions
This commit is contained in:
@@ -106,7 +106,7 @@ tryEvadeSideways :: Creature -> World -> ActionUpdate
|
||||
tryEvadeSideways _ w = jumpleft -- (mv,mempty)
|
||||
where
|
||||
jumpleft = (mv,DoReplicate 5 (DoImpulses mv))
|
||||
mv = [Walk (V2 0 d)]
|
||||
mv = [Walk (V2 0 d),UpdateRandGen]
|
||||
d = evalState (takeOne [3,-3]) (w ^. randGen)
|
||||
|
||||
performAimAt :: Creature -> World -> Int -> Point2 -> ActionUpdate
|
||||
|
||||
Reference in New Issue
Block a user