Don't move creatures when they're attacking

This may have resulted in a double-attack per turn
This commit is contained in:
Griffin Smith 2019-10-05 16:25:43 -04:00
parent 5c6ba40019
commit 262fc7fb41

View file

@ -36,7 +36,7 @@ stepGormlak pe@(Positioned pos creature) = do
then do
charPos <- use characterPosition
if isUnit (pos `diffPositions` charPos)
then attackCharacter $> charPos
then attackCharacter $> pos
else pure $ pos `stepTowards` charPos
else do
lines <- uses entities $ linesOfSight pos (Creature.visionRadius creature)