#3 Restrict player going places

This commit is contained in:
Tibo De Peuter 2022-12-21 14:49:42 +01:00
parent 5c8cee8104
commit 0786a41006
6 changed files with 78 additions and 21 deletions

View file

@ -14,9 +14,10 @@ data Game = Game {
------------------------------- Level --------------------------------
data Level = Level {
layout :: Layout,
items :: [Item],
entities :: [Entity]
layout :: Layout,
coordlayout :: [(X, Y, Physical)],
items :: [Item],
entities :: [Entity]
} deriving (Eq, Show)
type Layout = [Strip]
@ -37,7 +38,7 @@ type Y = Int
data Player = Player {
playerHp :: Maybe Int,
inventory :: [Item],
coord :: (X, Y)
position :: (X, Y)
} deriving (Eq, Show)
instance Living Player where