some refactoring and readded IsDoor to enable contious walls

This commit is contained in:
Lukas Nöllemeyer 2024-08-17 20:06:21 +02:00
parent 1fff168df0
commit 675e4a6af7
3 changed files with 46 additions and 33 deletions

View file

@ -10,7 +10,7 @@ from tcod.map import Map
import g
from game.components import Action, Gold, Graphic, Position
from game.tags import IsActor, IsItem, IsPlayer
from game.tags import IsActor, IsItem, IsPlayer, IsDoor
world_center: Final = Position(50, 50)
@ -32,7 +32,8 @@ def add_door(world, pos):
Position: pos,
Graphic: Graphic(ord('\\')),
Action: unlock_door
}
},
tags=[IsDoor]
)
add_wall(world, pos)