fix(combat): summon spawns only on passable cells
This commit is contained in:
@@ -2040,8 +2040,7 @@ class CombatEngine:
|
||||
if dr == 0 and dc == 0:
|
||||
continue
|
||||
pos = (center[0] + dr, center[1] + dc)
|
||||
if (0 <= pos[0] < self._grid.height and
|
||||
0 <= pos[1] < self._grid.width and
|
||||
if (self._grid.passable(pos) and
|
||||
not any(s.pos == pos for s in self._states if s.active)):
|
||||
spawn_pos = pos
|
||||
break
|
||||
|
||||
Reference in New Issue
Block a user