Better check for wall collisions when expanding creature
This commit is contained in:
@@ -8,7 +8,7 @@ module Dodge.Creature.Action
|
||||
, dropUnselected
|
||||
, startReloadingWeapon
|
||||
, blinkAction
|
||||
, maybeSizeSelf
|
||||
, sizeSelf
|
||||
, crAutoReload
|
||||
, copyInvItemToFloor
|
||||
, youDropItem
|
||||
@@ -295,9 +295,10 @@ pickUpItem cid flit w = case maybeInvSlot of
|
||||
Nothing -> w'
|
||||
Just j -> w' & itemPositions . ix j .~ InInv 0 invid
|
||||
|
||||
maybeSizeSelf :: Float -> Creature -> World -> Maybe World
|
||||
maybeSizeSelf x cr w
|
||||
| _crPos cr1 == _crPos cr2 = Just $ w
|
||||
sizeSelf :: Float -> Creature -> World -> Maybe World
|
||||
sizeSelf x cr w
|
||||
-- | _crPos cr1 == _crPos cr2 = Just $ w
|
||||
| not (crOnWall cr1 w) = Just $ w
|
||||
& soundMultiFrom [TeleSound 0,TeleSound 1] cpos teleS Nothing
|
||||
& over distortions (distortionBulge :)
|
||||
& creatures . ix cid %~
|
||||
|
||||
Reference in New Issue
Block a user