Implement viewport tracking for the MapWindow
As the player moves the hero, the MapWindow will try to keep the hero in the middle of the view.
This commit is contained in:
parent
402e910915
commit
356e205f2c
3 changed files with 58 additions and 25 deletions
|
|
@ -87,7 +87,7 @@ class MainGameEventHandler(EventHandler):
|
|||
case tcod.event.KeySym.ESCAPE:
|
||||
action = ExitAction()
|
||||
case tcod.event.KeySym.SPACE:
|
||||
action = RegenerateRoomsAction(hero)
|
||||
action = RegenerateRoomsAction()
|
||||
case tcod.event.KeySym.PERIOD:
|
||||
if not is_shift_pressed:
|
||||
action = WaitAction(hero)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue