Add ladders in the map
This commit is contained in:
parent
ad5ae22e5f
commit
8636d571b5
@ -1,8 +1,8 @@
|
||||
1 6
|
||||
####### #############
|
||||
#.....# #...........#
|
||||
#.H...# #...........#
|
||||
#.....# #####...........#
|
||||
#.....# #...............#
|
||||
#.....# #............H..#
|
||||
#.##### #.###...........#
|
||||
#.# #.# #...........#
|
||||
#.# #.# #############
|
||||
|
@ -1,6 +1,6 @@
|
||||
1 17
|
||||
########### #########
|
||||
#.........# #.......#
|
||||
#....H....# #.......#
|
||||
#.........# ############.......#
|
||||
#.........###############..........#.......##############
|
||||
#.........#........................#....................#
|
||||
@ -13,7 +13,7 @@
|
||||
########.##########......# #.........# #.........#
|
||||
#...........##......# #.........# #.........#
|
||||
#...........##......# #.........# #.........#
|
||||
#...........##......# #.........# ################.######
|
||||
#...........##..H...# #.........# ################.######
|
||||
#...........##......# #.........# #.................############
|
||||
#...........##......# ########.########.......#.........#..........#
|
||||
#...........##......# #...............#.......#.........#..........#
|
||||
|
@ -64,6 +64,7 @@ TexturePack.ASCII_PACK = TexturePack(
|
||||
EMPTY=' ',
|
||||
EXPLOSION='%',
|
||||
FLOOR='.',
|
||||
LADDER='H',
|
||||
HAZELNUT='¤',
|
||||
HEART='❤',
|
||||
HEDGEHOG='*',
|
||||
@ -90,6 +91,7 @@ TexturePack.SQUIRREL_PACK = TexturePack(
|
||||
EMPTY=' ',
|
||||
EXPLOSION='💥',
|
||||
FLOOR='██',
|
||||
LADDER='🪜',
|
||||
HAZELNUT='🌰',
|
||||
HEART='💜',
|
||||
HEDGEHOG='🦔',
|
||||
|
@ -198,6 +198,7 @@ class Tile(Enum):
|
||||
EMPTY = auto()
|
||||
WALL = auto()
|
||||
FLOOR = auto()
|
||||
LADDER = auto()
|
||||
|
||||
@staticmethod
|
||||
def from_ascii_char(ch: str) -> "Tile":
|
||||
@ -222,6 +223,12 @@ class Tile(Enum):
|
||||
"""
|
||||
return self == Tile.WALL
|
||||
|
||||
def is_ladder(self) -> bool:
|
||||
"""
|
||||
Is this Tile a ladder?
|
||||
"""
|
||||
return self == Tile.LADDER
|
||||
|
||||
def can_walk(self) -> bool:
|
||||
"""
|
||||
Check if an entity (player or not) can move in this tile.
|
||||
|
Loading…
Reference in New Issue
Block a user