change boundaries based on orientation

This commit is contained in:
nek0 2019-02-16 02:21:07 +01:00
parent bbd57c8ed1
commit 414dd39c00

View file

@ -295,7 +295,10 @@ loadMapFork ud ad future progress = do
{ pos = Just (fmap ((+ 0.5) . fromIntegral) coord)
, clearanceLvl = Just (maximum $ 0 : Prelude.map clearance (Prelude.map snd rooms))
, anim = Just $ AnimState (AnimId AnimDoor0 "shut" orientation) 0 0
, obstacle = Just $ Boundaries (4/9, 0) (5/9, 1)
, obstacle = Just $ case orientation of
NE -> Boundaries (4/9, 0) (5/9, 1)
NW -> Boundaries (0, 4/9) (1, 5/9)
_ -> error "strange orientation for door"
, ignoreObstacle = Just ()
}
) doors