21 lines
614 B
Python
Raw Normal View History

2020-11-06 15:34:24 +01:00
import curses
from .mapdisplay import MapDisplay
2020-11-06 17:43:30 +01:00
from .texturepack import TexturePack
2020-11-06 15:34:24 +01:00
class Display:
def __init__(self, game, screen):
self.screen = screen
self.game = game
2020-11-06 20:24:19 +01:00
self.map_display = MapDisplay(game.m,
TexturePack.get_pack(
2020-11-06 17:43:30 +01:00
game.settings.TEXTURE_PACK),
2020-11-06 20:24:19 +01:00
curses.LINES,
curses.COLS * 4 // 5)
2020-11-06 17:43:30 +01:00
2020-11-06 15:34:24 +01:00
def refresh(self):
2020-11-06 20:24:19 +01:00
self.map_display.update_pad()
def display(self, y, x):
self.map_display.display(y, x)