示例#1
0
        private void createWindow()
        {
            int fontflags = (int)TCODFontFlags.Greyscale | (int)TCODFontFlags.LayoutAsciiInRow;

            TCODConsole.setCustomFont(FONT, fontflags);
            TCODConsole.setKeyboardRepeat(500, 5000 / TARGET_FPS);
            TCODConsole.initRoot(WINDOW_WIDTH / FONT_WIDTH, WINDOW_HEIGHT / FONT_HEIGHT, windowName, false, TCODRendererType.SDL);
            TCODSystem.setFps(CONTROL_FPS);

            terminalManager = new TerminalManager(WINDOW_WIDTH / FONT_WIDTH, WINDOW_HEIGHT / FONT_HEIGHT);
        }
示例#2
0
        public GameTerminal(TerminalManager manager, string name)
        {
            this.manager = manager;
            this.name    = name;

            this.x      = manager.DefaultX;
            this.y      = manager.DefaultY;
            this.width  = manager.DefaultWidth;
            this.height = manager.DefaultHeight;

            terminal = new TCODConsole(width, height);

            cursorX = 0;
            cursorY = 0;

            glyphs    = new Tile[width, height];
            oldGlyphs = new Tile[width, height];

            clear();
        }
示例#3
0
        public GameTerminal(TerminalManager manager, string name, int x, int y, int width, int height)
        {
            this.manager = manager;
            this.name    = name;

            this.x      = x;
            this.y      = y;
            this.width  = width;
            this.height = height;

            terminal = new TCODConsole(width, height);

            cursorX = 0;
            cursorY = 0;

            glyphs    = new Tile[width, height];
            oldGlyphs = new Tile[width, height];

            clear();
        }
示例#4
0
 public Screen(Engine p, TerminalManager manager)
 {
     parent          = p;
     terminalManager = manager;
 }